/src/test/run-pass/inner-module.rs

http://github.com/jruderman/rust · Rust · 12 lines · 7 code · 4 blank · 1 comment · 0 complexity · 9e6b9473b2e89740b56de70cd0fa827c MD5 · raw file

  1. // -*- rust -*-
  2. mod inner {
  3. mod inner2 {
  4. fn hello() { debug!{"hello, modular world"}; }
  5. }
  6. fn hello() { inner2::hello(); }
  7. }
  8. fn main() { inner::hello(); inner::inner2::hello(); }