blob: 511721d92a350f4adede0e99a16c45b9373777d7 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
// sub-module in a sub-directory
use sub::sub2 as msalias;
use sub::sub2;
static yy: usize = 25;
mod sub {
pub mod sub2 {
pub mod sub3 {
pub fn hello() {
println!("hello from module 3");
}
}
pub fn hello() {
println!("hello from a module");
}
pub struct nested_struct {
pub field2: u32,
}
}
}
pub struct SubStruct {
pub name: String
}
|