title: Using files from the same module in Rust
body: <p>I have this file structure:</p>
  <pre><code>src
  ├── core
  │   ├── game.rs
  │   ├── math.rs
  │   └── screen.rs
  ├── core.rs
  └── main.rs
  </code></pre>
  <p>Inside of <code>core/screen.rs</code> I have a struct <code>Screen</code>. I can use this struct and its function in <code>main.rs</code> like</p>
  <pre class="lang-rust prettyprint-override"><code>mod core;
  
  fn main() {
    let s = core::screen::Screen::new();
  }
  </code></pre>
  <p>That works, however the problem is, inside of <code>core/game.rs</code> I can't use that same struct.
  I've tried <code>use</code> and <code>mod</code> but I can't figure it out.
  Inside core/game.rs</p>
  <pre class="lang-rust prettyprint-override"><code>pub struct Game {
    screen: ?????? // Should be core::screen::Screen?
  }
  </code></pre>
  <p>And for those wondering, the contents of core.rs looks like</p>
  <pre><code>pub mod math;
  pub mod screen;
  pub mod game;
  </code></pre>
  <p>Right now the core.rs file doesn't exactly have a use except for a very weird namespace almost but it will have functions in the future.</p>