aboutsummaryrefslogtreecommitdiff
path: root/src/test/run-pass/inner-module.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/run-pass/inner-module.rs')
-rw-r--r--src/test/run-pass/inner-module.rs17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/test/run-pass/inner-module.rs b/src/test/run-pass/inner-module.rs
new file mode 100644
index 00000000..f5066b6e
--- /dev/null
+++ b/src/test/run-pass/inner-module.rs
@@ -0,0 +1,17 @@
+// -*- rust -*-
+
+mod inner {
+ mod inner2 {
+ fn hello() {
+ log "hello, modular world";
+ }
+ }
+ fn hello() {
+ inner2.hello();
+ }
+}
+
+fn main() {
+ inner.hello();
+ inner.inner2.hello();
+}