about summary refs log tree commit diff
path: root/tests/ui/modules/nested-modules-basic.rs
diff options
context:
space:
mode:
authorKivooeo <Kivooeo123@gmail.com>2025-06-12 20:49:48 +0500
committerKivooeo <Kivooeo123@gmail.com>2025-06-29 15:37:33 +0500
commitd0bd27924e69084f11290e7876ee63b69c0d9667 (patch)
tree939e2aede219b3f390203ade7fbded49310a17e4 /tests/ui/modules/nested-modules-basic.rs
parent36b21637e93b038453924d3c66821089e71d8baa (diff)
downloadrust-d0bd27924e69084f11290e7876ee63b69c0d9667.tar.gz
rust-d0bd27924e69084f11290e7876ee63b69c0d9667.zip
cleaned up some tests
Diffstat (limited to 'tests/ui/modules/nested-modules-basic.rs')
-rw-r--r--tests/ui/modules/nested-modules-basic.rs19
1 files changed, 19 insertions, 0 deletions
diff --git a/tests/ui/modules/nested-modules-basic.rs b/tests/ui/modules/nested-modules-basic.rs
new file mode 100644
index 00000000000..12eccec2808
--- /dev/null
+++ b/tests/ui/modules/nested-modules-basic.rs
@@ -0,0 +1,19 @@
+//! Basic test for nested module functionality and path resolution
+
+//@ run-pass
+
+mod inner {
+    pub mod inner2 {
+        pub fn hello() {
+            println!("hello, modular world");
+        }
+    }
+    pub fn hello() {
+        inner2::hello();
+    }
+}
+
+pub fn main() {
+    inner::hello();
+    inner::inner2::hello();
+}