Glossary: Software Design Patterns in Rust
mod
Also written: module, mod tests
The keyword that declares a module. In a multi-file crate, `main.rs` needs a line such as `mod discounts;` for the file `discounts.rs` to count as part of the program.
Glossary: Software Design Patterns in Rust
Also written: module, mod tests
The keyword that declares a module. In a multi-file crate, `main.rs` needs a line such as `mod discounts;` for the file `discounts.rs` to count as part of the program.