From 8f7703b006bb35ab08959b01ed8ffb27d07f4d0b Mon Sep 17 00:00:00 2001 From: Edwin Cheng Date: Thu, 12 Mar 2020 01:57:34 +0800 Subject: Update comment Co-Authored-By: bjorn3 --- crates/ra_hir_expand/src/builtin_macro.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'crates/ra_hir_expand') diff --git a/crates/ra_hir_expand/src/builtin_macro.rs b/crates/ra_hir_expand/src/builtin_macro.rs index 01f78fc77..f9d3787f6 100644 --- a/crates/ra_hir_expand/src/builtin_macro.rs +++ b/crates/ra_hir_expand/src/builtin_macro.rs @@ -158,9 +158,9 @@ fn assert_expand( tt: &tt::Subtree, ) -> Result { // A hacky implementation for goto def and hover - // We expand `assert!("", arg1, arg2)` to + // We expand `assert!(cond, arg1, arg2)` to // ``` - // {(&(arg1), &(arg2));} + // {(cond, &(arg1), &(arg2));} // ```, // which is wrong but useful. @@ -539,8 +539,8 @@ mod tests { r#" #[rustc_builtin_macro] macro_rules! assert { - ($fmt:expr) => ({ /* compiler built-in */ }); - ($fmt:expr, $($args:tt)*) => ({ /* compiler built-in */ }) + ($cond:expr) => ({ /* compiler built-in */ }); + ($cond:expr, $($args:tt)*) => ({ /* compiler built-in */ }) } assert!(true, "{} {:?}", arg1(a, b, c), arg2); "#, -- cgit v1.2.3