summaryrefslogtreecommitdiffstats
path: root/src/test/ui/modules/mod-view-items.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/ui/modules/mod-view-items.rs')
-rw-r--r--src/test/ui/modules/mod-view-items.rs14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/test/ui/modules/mod-view-items.rs b/src/test/ui/modules/mod-view-items.rs
new file mode 100644
index 000000000..db2b30366
--- /dev/null
+++ b/src/test/ui/modules/mod-view-items.rs
@@ -0,0 +1,14 @@
+// run-pass
+// Test view items inside non-file-level mods
+
+// This is a regression test for an issue where we were failing to
+// pretty-print such view items. If that happens again, this should
+// begin failing.
+
+// pretty-expanded FIXME #23616
+
+mod m {
+ pub fn f() -> Vec<isize> { Vec::new() }
+}
+
+pub fn main() { let _x = m::f(); }