test: Add a test for mods inside functions. Closes #493
This commit is contained in:
parent
f78776e9d8
commit
f6ce2bd831
11
src/test/run-pass/mod-inside-fn.rs
Normal file
11
src/test/run-pass/mod-inside-fn.rs
Normal file
@ -0,0 +1,11 @@
|
||||
fn f() -> int {
|
||||
mod m {
|
||||
fn g() -> int { 720 }
|
||||
}
|
||||
|
||||
m::g()
|
||||
}
|
||||
|
||||
fn main() {
|
||||
assert f() == 720;
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user