summaryrefslogtreecommitdiffstats
path: root/src/test/ui/underscore-ident-matcher.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/ui/underscore-ident-matcher.rs')
-rw-r--r--src/test/ui/underscore-ident-matcher.rs9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/test/ui/underscore-ident-matcher.rs b/src/test/ui/underscore-ident-matcher.rs
new file mode 100644
index 000000000..bddc8c80a
--- /dev/null
+++ b/src/test/ui/underscore-ident-matcher.rs
@@ -0,0 +1,9 @@
+macro_rules! identity {
+ ($i: ident) => (
+ $i
+ )
+}
+
+fn main() {
+ let identity!(_) = 10; //~ ERROR no rules expected the token `_`
+}