diff options
| author | Gaëtan Cassiers <gaetan.cassiers@gmail.com> | 2015-07-01 21:13:10 +0200 |
|---|---|---|
| committer | Gaëtan Cassiers <gaetan.cassiers@gmail.com> | 2015-07-03 11:12:21 +0200 |
| commit | 3de366d282de6de5dd1d69c40ea32f98a051fc66 (patch) | |
| tree | 613436a1cacf9d061edeca905abd2c9ac9a20530 /tests/source/nestedmod | |
| parent | 83290f15ada755a71f3cfc0c66c3631a66d6b461 (diff) | |
Format modules into separate files
Diffstat (limited to 'tests/source/nestedmod')
| -rw-r--r-- | tests/source/nestedmod/mod.rs | 12 | ||||
| -rw-r--r-- | tests/source/nestedmod/mod2a.rs | 4 | ||||
| -rw-r--r-- | tests/source/nestedmod/mod2b.rs | 3 | ||||
| -rw-r--r-- | tests/source/nestedmod/mod2c.rs | 3 | ||||
| -rw-r--r-- | tests/source/nestedmod/submod2/a.rs | 6 | ||||
| -rw-r--r-- | tests/source/nestedmod/submod2/mod.rs | 5 |
6 files changed, 33 insertions, 0 deletions
diff --git a/tests/source/nestedmod/mod.rs b/tests/source/nestedmod/mod.rs new file mode 100644 index 00000000000..23dfa444257 --- /dev/null +++ b/tests/source/nestedmod/mod.rs @@ -0,0 +1,12 @@ + +mod mod2a; +mod mod2b; + +mod mymod1 { + use mod2a::{Foo,Bar}; +} + +#[path="mod2c.rs"] +mod mymod2; + +mod submod2; diff --git a/tests/source/nestedmod/mod2a.rs b/tests/source/nestedmod/mod2a.rs new file mode 100644 index 00000000000..5df457a8316 --- /dev/null +++ b/tests/source/nestedmod/mod2a.rs @@ -0,0 +1,4 @@ +// This is an empty file containing only +// comments + +// ................... diff --git a/tests/source/nestedmod/mod2b.rs b/tests/source/nestedmod/mod2b.rs new file mode 100644 index 00000000000..f128e2da6db --- /dev/null +++ b/tests/source/nestedmod/mod2b.rs @@ -0,0 +1,3 @@ + +#[path="mod2a.rs"] +mod c; diff --git a/tests/source/nestedmod/mod2c.rs b/tests/source/nestedmod/mod2c.rs new file mode 100644 index 00000000000..eda6b233e4b --- /dev/null +++ b/tests/source/nestedmod/mod2c.rs @@ -0,0 +1,3 @@ +// A standard mod + +fn a( ) {} diff --git a/tests/source/nestedmod/submod2/a.rs b/tests/source/nestedmod/submod2/a.rs new file mode 100644 index 00000000000..0eaf08f0d2c --- /dev/null +++ b/tests/source/nestedmod/submod2/a.rs @@ -0,0 +1,6 @@ +// Yet Another mod +// Nested + +use c::a; + +fn foo( ) { } diff --git a/tests/source/nestedmod/submod2/mod.rs b/tests/source/nestedmod/submod2/mod.rs new file mode 100644 index 00000000000..52f8be91022 --- /dev/null +++ b/tests/source/nestedmod/submod2/mod.rs @@ -0,0 +1,5 @@ +// Another mod + +mod a; + +use a::a; |
