]> git.lizzy.rs Git - rust.git/commitdiff
Update/Fix tests
authorJonas Schievink <jonasschievink@gmail.com>
Wed, 2 Dec 2020 16:00:48 +0000 (17:00 +0100)
committerJonas Schievink <jonasschievink@gmail.com>
Thu, 3 Dec 2020 14:48:29 +0000 (15:48 +0100)
crates/hir_def/src/body/tests.rs

index baf1179f1f4cbc329c8547d2bee5828cc869a3b7..f2b57aebe75df4421929aaeeacdde228991b8513 100644 (file)
@@ -78,21 +78,32 @@ fn f() {
 fn macro_diag_builtin() {
     check_diagnostics(
         r#"
+#[rustc_builtin_macro]
+macro_rules! env {}
+
+#[rustc_builtin_macro]
+macro_rules! include {}
+
+#[rustc_builtin_macro]
+macro_rules! format_args {
+    () => {}
+}
+
 fn f() {
     // Test a handful of built-in (eager) macros:
 
     include!(invalid);
-  //^^^^^^^^^^^^^^^^^ failed to parse or resolve macro invocation
+  //^^^^^^^^^^^^^^^^^ could not convert tokens
     include!("does not exist");
-  //^^^^^^^^^^^^^^^^^^^^^^^^^^ failed to parse or resolve macro invocation
+  //^^^^^^^^^^^^^^^^^^^^^^^^^^ could not convert tokens
 
     env!(invalid);
-  //^^^^^^^^^^^^^ failed to parse or resolve macro invocation
+  //^^^^^^^^^^^^^ could not convert tokens
 
     // Lazy:
 
     format_args!();
-  //^^^^^^^^^^^^^^ failed to parse or resolve macro invocation
+  //^^^^^^^^^^^^^^ no rule matches input tokens
 }
         "#,
     );