diff --git a/Cargo.lock b/Cargo.lock index f31e457..51805ec 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -126,6 +126,10 @@ dependencies = [ "password-hash", ] +[[package]] +name = "arithmetics" +version = "0.1.0" + [[package]] name = "async-trait" version = "0.1.80" diff --git a/Cargo.toml b/Cargo.toml index 0f995d1..747b326 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -25,10 +25,13 @@ members = [ "members/diesel-demo", "members/ptlog", "members/hello-world", - "members/statusline", "members/clap-repl-demo", + "members/statusline", + "members/clap-repl-demo", + "members/arithmetics", ] default-members = [ ".", + "members/arithmetics", "members/statusline", "members/ptlog", "members/diesel-demo", diff --git a/members/arithmetics/Cargo.toml b/members/arithmetics/Cargo.toml new file mode 100644 index 0000000..a0e70d9 --- /dev/null +++ b/members/arithmetics/Cargo.toml @@ -0,0 +1,6 @@ +[package] +name = "arithmetics" +version = "0.1.0" +edition = "2021" + +[dependencies] diff --git a/members/arithmetics/src/main.rs b/members/arithmetics/src/main.rs new file mode 100644 index 0000000..a908061 --- /dev/null +++ b/members/arithmetics/src/main.rs @@ -0,0 +1,11 @@ +// If you're confused what this is: it's an annotation that tells a common linting thing to shut up +// about this program calculating things that should normally be precalculated +// +// If you're still confused, feel free to ignore this, it's not important +#![allow(clippy::eq_op)] // thats the point +#![allow(clippy::identity_op)] // thats the point + +fn main() { + println!("1^1={}", 1 ^ 1); + println!("0^1={}", 0 ^ 1); +}