DEV Community

loading...

Discussion on: Rust Module Essentials

Collapse
hertz4 profile image
Sam Pagenkopf Author
// main.rs
mod back_of_restaurant;

// front_of_restaurant
use back_of_restaurant;
Collapse
zinsbill profile image
zinsbill

name the file either back_of_restaurant.rs or back_of_restaurant/mod.rs inside the directory "src/front_of_restaurant"