about summary refs log tree commit diff
path: root/tests/ui/parser/macro/trait-object-macro-matcher.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/parser/macro/trait-object-macro-matcher.rs')
-rw-r--r--tests/ui/parser/macro/trait-object-macro-matcher.rs12
1 files changed, 9 insertions, 3 deletions
diff --git a/tests/ui/parser/macro/trait-object-macro-matcher.rs b/tests/ui/parser/macro/trait-object-macro-matcher.rs
index d4ec199070e..ba61752fe40 100644
--- a/tests/ui/parser/macro/trait-object-macro-matcher.rs
+++ b/tests/ui/parser/macro/trait-object-macro-matcher.rs
@@ -1,6 +1,10 @@
 // A single lifetime is not parsed as a type.
 // `ty` matcher in particular doesn't accept a single lifetime
 
+//@ revisions: e2015 e2021
+//@[e2015] edition: 2015
+//@[e2021] edition: 2021
+
 macro_rules! m {
     ($t: ty) => {
         let _: $t;
@@ -8,8 +12,10 @@ macro_rules! m {
 }
 
 fn main() {
+    //[e2021]~vv ERROR expected type, found lifetime
+    //[e2021]~v ERROR expected type, found lifetime
     m!('static);
-    //~^ ERROR lifetime in trait object type must be followed by `+`
-    //~| ERROR lifetime in trait object type must be followed by `+`
-    //~| ERROR at least one trait is required for an object type
+    //[e2015]~^ ERROR lifetimes must be followed by `+` to form a trait object type
+    //[e2015]~| ERROR lifetimes must be followed by `+` to form a trait object type
+    //[e2015]~| ERROR at least one trait is required for an object type
 }