summaryrefslogtreecommitdiffstats
path: root/tests/ui/parser/issues/issue-45296.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/parser/issues/issue-45296.rs')
-rw-r--r--tests/ui/parser/issues/issue-45296.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/ui/parser/issues/issue-45296.rs b/tests/ui/parser/issues/issue-45296.rs
new file mode 100644
index 000000000..d3a97e89f
--- /dev/null
+++ b/tests/ui/parser/issues/issue-45296.rs
@@ -0,0 +1,6 @@
+fn main() {
+ let unused = ();
+
+ #![allow(unused_variables)] //~ ERROR not permitted in this context
+ fn foo() {}
+}