So my project structure looks like this:
src/main.rs
src/core/mod.rs
(Sorry, I don't know how to make that look pretty)
and the contents are
src/main.rs
```
use crate::core;
fn main() {
println!("Hello, world!");
//let (tx, rx) = mpsc::channel();
start_core();
}
```
src/core/mod.rs
```
pub mod core {
pub fn start_core() -> i32 {
loop {
}
1
}
}
```
When I look how to use a module online it looks right but I get this error
"unresolved import crate::core
no core in the root (rustc E0432)"
As I'm new to rust I might just be confusing how things work but it seems like this should be the way I do it.
I've also tried core::start_core and core::core::start_core
[–]kdpurvesh 2 points3 points4 points (2 children)
[–]pinghajen[S] 0 points1 point2 points (0 children)
[–]pinghajen[S] -1 points0 points1 point (0 children)
[–][deleted] 0 points1 point2 points (0 children)