summaryrefslogtreecommitdiffstats
path: root/src/tools/rustfmt/tests/target/mod-1.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/tools/rustfmt/tests/target/mod-1.rs')
-rw-r--r--src/tools/rustfmt/tests/target/mod-1.rs37
1 files changed, 37 insertions, 0 deletions
diff --git a/src/tools/rustfmt/tests/target/mod-1.rs b/src/tools/rustfmt/tests/target/mod-1.rs
new file mode 100644
index 000000000..4118d123d
--- /dev/null
+++ b/src/tools/rustfmt/tests/target/mod-1.rs
@@ -0,0 +1,37 @@
+// Deeply indented modules.
+
+mod foo {
+ mod bar {
+ mod baz {}
+ }
+}
+
+mod foo {
+ mod bar {
+ mod baz {
+ fn foo() {
+ bar()
+ }
+ }
+ }
+
+ mod qux {}
+}
+
+mod boxed {
+ pub use std::boxed::{Box, HEAP};
+}
+
+pub mod x {
+ pub fn freopen(
+ filename: *const c_char,
+ mode: *const c_char,
+ mode2: *const c_char,
+ mode3: *const c_char,
+ file: *mut FILE,
+ ) -> *mut FILE {
+ }
+}
+
+mod y { // sup boooooiiii
+}