From cb7bcfad4ab0041aaf3fde3185e27ee46bb37788 Mon Sep 17 00:00:00 2001 From: JSDurand Date: Tue, 15 Nov 2022 12:01:28 +0800 Subject: Initial commit Basic GNU standard files are added, and we now stop worrying about monadic anamorphisms. The current focus is on testing the correctness of the algorithm, so I need convenient support for manipulating, interpreting, examining, and per chance animating nondeterministic automata. --- repcore/Cargo.toml | 8 ++++++++ repcore/src/lib.rs | 14 ++++++++++++++ 2 files changed, 22 insertions(+) create mode 100644 repcore/Cargo.toml create mode 100644 repcore/src/lib.rs (limited to 'repcore') diff --git a/repcore/Cargo.toml b/repcore/Cargo.toml new file mode 100644 index 0000000..7416ad5 --- /dev/null +++ b/repcore/Cargo.toml @@ -0,0 +1,8 @@ +[package] +name = "repcore" +version = "0.1.0" +edition = "2021" + +# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html + +[dependencies] diff --git a/repcore/src/lib.rs b/repcore/src/lib.rs new file mode 100644 index 0000000..7d12d9a --- /dev/null +++ b/repcore/src/lib.rs @@ -0,0 +1,14 @@ +pub fn add(left: usize, right: usize) -> usize { + left + right +} + +#[cfg(test)] +mod tests { + use super::*; + + #[test] + fn it_works() { + let result = add(2, 2); + assert_eq!(result, 4); + } +} -- cgit v1.2.3-18-g5258