Skip to content

Commit 4698b36

Browse files
committed
Show macro name in 'this error originates in macro' message
When there are multiple macros in use, it can be difficult to tell which one was responsible for producing an error.
1 parent f019d28 commit 4698b36

34 files changed

+90
-90
lines changed

tests/ui-internal/default_lint.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ note: the lint level is defined here
1515
LL | #![deny(clippy::internal)]
1616
| ^^^^^^^^^^^^^^^^
1717
= note: `#[deny(clippy::default_lint)]` implied by `#[deny(clippy::internal)]`
18-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
18+
= note: this error originates in the macro `$crate::declare_tool_lint` (in Nightly builds, run with -Z macro-backtrace for more info)
1919

2020
error: aborting due to previous error
2121

tests/ui-internal/if_chain_style.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ LL | | }
5656
LL | | }
5757
| |_____^
5858
|
59-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
59+
= note: this error originates in the macro `__if_chain` (in Nightly builds, run with -Z macro-backtrace for more info)
6060

6161
error: `let` expression should be above the `if_chain!`
6262
--> $DIR/if_chain_style.rs:40:9

tests/ui-internal/lint_without_lint_pass.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ note: the lint level is defined here
1515
LL | #![deny(clippy::internal)]
1616
| ^^^^^^^^^^^^^^^^
1717
= note: `#[deny(clippy::lint_without_lint_pass)]` implied by `#[deny(clippy::internal)]`
18-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
18+
= note: this error originates in the macro `declare_tool_lint` (in Nightly builds, run with -Z macro-backtrace for more info)
1919

2020
error: aborting due to previous error
2121

tests/ui/assertions_on_constants.stderr

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ LL | assert!(true);
66
|
77
= note: `-D clippy::assertions-on-constants` implied by `-D warnings`
88
= help: remove it
9-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
9+
= note: this error originates in the macro `assert` (in Nightly builds, run with -Z macro-backtrace for more info)
1010

1111
error: `assert!(false)` should probably be replaced
1212
--> $DIR/assertions_on_constants.rs:12:5
@@ -15,7 +15,7 @@ LL | assert!(false);
1515
| ^^^^^^^^^^^^^^^
1616
|
1717
= help: use `panic!()` or `unreachable!()`
18-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
18+
= note: this error originates in the macro `assert` (in Nightly builds, run with -Z macro-backtrace for more info)
1919

2020
error: `assert!(true)` will be optimized out by the compiler
2121
--> $DIR/assertions_on_constants.rs:13:5
@@ -24,7 +24,7 @@ LL | assert!(true, "true message");
2424
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2525
|
2626
= help: remove it
27-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
27+
= note: this error originates in the macro `assert` (in Nightly builds, run with -Z macro-backtrace for more info)
2828

2929
error: `assert!(false, "false message")` should probably be replaced
3030
--> $DIR/assertions_on_constants.rs:14:5
@@ -33,7 +33,7 @@ LL | assert!(false, "false message");
3333
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
3434
|
3535
= help: use `panic!("false message")` or `unreachable!("false message")`
36-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
36+
= note: this error originates in the macro `assert` (in Nightly builds, run with -Z macro-backtrace for more info)
3737

3838
error: `assert!(false, msg.to_uppercase())` should probably be replaced
3939
--> $DIR/assertions_on_constants.rs:17:5
@@ -42,7 +42,7 @@ LL | assert!(false, msg.to_uppercase());
4242
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
4343
|
4444
= help: use `panic!(msg.to_uppercase())` or `unreachable!(msg.to_uppercase())`
45-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
45+
= note: this error originates in the macro `assert` (in Nightly builds, run with -Z macro-backtrace for more info)
4646

4747
error: `assert!(true)` will be optimized out by the compiler
4848
--> $DIR/assertions_on_constants.rs:20:5
@@ -51,7 +51,7 @@ LL | assert!(B);
5151
| ^^^^^^^^^^^
5252
|
5353
= help: remove it
54-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
54+
= note: this error originates in the macro `assert` (in Nightly builds, run with -Z macro-backtrace for more info)
5555

5656
error: `assert!(false)` should probably be replaced
5757
--> $DIR/assertions_on_constants.rs:23:5
@@ -60,7 +60,7 @@ LL | assert!(C);
6060
| ^^^^^^^^^^^
6161
|
6262
= help: use `panic!()` or `unreachable!()`
63-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
63+
= note: this error originates in the macro `assert` (in Nightly builds, run with -Z macro-backtrace for more info)
6464

6565
error: `assert!(false, "C message")` should probably be replaced
6666
--> $DIR/assertions_on_constants.rs:24:5
@@ -69,7 +69,7 @@ LL | assert!(C, "C message");
6969
| ^^^^^^^^^^^^^^^^^^^^^^^^
7070
|
7171
= help: use `panic!("C message")` or `unreachable!("C message")`
72-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
72+
= note: this error originates in the macro `assert` (in Nightly builds, run with -Z macro-backtrace for more info)
7373

7474
error: `debug_assert!(true)` will be optimized out by the compiler
7575
--> $DIR/assertions_on_constants.rs:26:5
@@ -78,7 +78,7 @@ LL | debug_assert!(true);
7878
| ^^^^^^^^^^^^^^^^^^^^
7979
|
8080
= help: remove it
81-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
81+
= note: this error originates in the macro `$crate::assert` (in Nightly builds, run with -Z macro-backtrace for more info)
8282

8383
error: aborting due to 9 previous errors
8484

tests/ui/checked_unwrap/simple_conditionals.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ LL | $a.unwrap(); // unnecessary
5555
LL | m!(x);
5656
| ------ in this macro invocation
5757
|
58-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
58+
= note: this error originates in the macro `m` (in Nightly builds, run with -Z macro-backtrace for more info)
5959

6060
error: you checked before that `unwrap()` cannot fail, instead of checking and unwrapping, it's better to use `if let` or `match`
6161
--> $DIR/simple_conditionals.rs:54:9

tests/ui/collapsible_match2.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ LL | mac!(res_opt => Ok(val), val => Some(n), foo(n));
5555
| ^^^ ^^^^^^^ with this pattern
5656
| |
5757
| replace this binding
58-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
58+
= note: this error originates in the macro `mac` (in Nightly builds, run with -Z macro-backtrace for more info)
5959

6060
error: unnecessary nested match
6161
--> $DIR/collapsible_match2.rs:51:20

tests/ui/crashes/ice-6255.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ LL | extern crate std as core;
77
LL | define_other_core!();
88
| --------------------- in this macro invocation
99
|
10-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
10+
= note: this error originates in the macro `define_other_core` (in Nightly builds, run with -Z macro-backtrace for more info)
1111

1212
error: aborting due to previous error
1313

tests/ui/declare_interior_mutable_const/others.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ LL | const $name: $ty = $e;
3333
LL | declare_const!(_ONCE: Once = Once::new()); //~ ERROR interior mutable
3434
| ------------------------------------------ in this macro invocation
3535
|
36-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
36+
= note: this error originates in the macro `declare_const` (in Nightly builds, run with -Z macro-backtrace for more info)
3737

3838
error: aborting due to 4 previous errors
3939

tests/ui/declare_interior_mutable_const/traits.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ LL | const $name: $ty = $e;
1515
LL | declare_const!(ANOTHER_ATOMIC: AtomicUsize = Self::ATOMIC); //~ ERROR interior mutable
1616
| ----------------------------------------------------------- in this macro invocation
1717
|
18-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
18+
= note: this error originates in the macro `declare_const` (in Nightly builds, run with -Z macro-backtrace for more info)
1919

2020
error: a `const` item should never be interior mutable
2121
--> $DIR/traits.rs:43:5

tests/ui/deref_addrof.stderr

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ LL | *& $visitor
5757
LL | m!(self)
5858
| -------- in this macro invocation
5959
|
60-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
60+
= note: this error originates in the macro `m` (in Nightly builds, run with -Z macro-backtrace for more info)
6161

6262
error: immediately dereferencing a reference
6363
--> $DIR/deref_addrof.rs:51:9
@@ -68,7 +68,7 @@ LL | *& mut $visitor
6868
LL | m_mut!(self)
6969
| ------------ in this macro invocation
7070
|
71-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
71+
= note: this error originates in the macro `m_mut` (in Nightly builds, run with -Z macro-backtrace for more info)
7272

7373
error: aborting due to 10 previous errors
7474

tests/ui/derive_hash_xor_eq.stderr

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ LL | | true
1414
LL | | }
1515
LL | | }
1616
| |_^
17-
= note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
17+
= note: this error originates in the derive macro `Hash` (in Nightly builds, run with -Z macro-backtrace for more info)
1818

1919
error: you are deriving `Hash` but have implemented `PartialEq` explicitly
2020
--> $DIR/derive_hash_xor_eq.rs:19:10
@@ -31,7 +31,7 @@ LL | | true
3131
LL | | }
3232
LL | | }
3333
| |_^
34-
= note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
34+
= note: this error originates in the derive macro `Hash` (in Nightly builds, run with -Z macro-backtrace for more info)
3535

3636
error: you are implementing `Hash` explicitly but have derived `PartialEq`
3737
--> $DIR/derive_hash_xor_eq.rs:31:1
@@ -46,7 +46,7 @@ note: `PartialEq` implemented here
4646
|
4747
LL | #[derive(PartialEq)]
4848
| ^^^^^^^^^
49-
= note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
49+
= note: this error originates in the derive macro `PartialEq` (in Nightly builds, run with -Z macro-backtrace for more info)
5050

5151
error: you are implementing `Hash` explicitly but have derived `PartialEq`
5252
--> $DIR/derive_hash_xor_eq.rs:49:5
@@ -61,7 +61,7 @@ note: `PartialEq` implemented here
6161
|
6262
LL | #[derive(PartialEq)]
6363
| ^^^^^^^^^
64-
= note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
64+
= note: this error originates in the derive macro `PartialEq` (in Nightly builds, run with -Z macro-backtrace for more info)
6565

6666
error: aborting due to 4 previous errors
6767

tests/ui/derive_ord_xor_partial_ord.stderr

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ LL | | Some(other.cmp(self))
1414
LL | | }
1515
LL | | }
1616
| |_^
17-
= note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
17+
= note: this error originates in the derive macro `Ord` (in Nightly builds, run with -Z macro-backtrace for more info)
1818

1919
error: you are deriving `Ord` but have implemented `PartialOrd` explicitly
2020
--> $DIR/derive_ord_xor_partial_ord.rs:30:10
@@ -31,7 +31,7 @@ LL | | Some(other.cmp(self))
3131
LL | | }
3232
LL | | }
3333
| |_^
34-
= note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
34+
= note: this error originates in the derive macro `Ord` (in Nightly builds, run with -Z macro-backtrace for more info)
3535

3636
error: you are implementing `Ord` explicitly but have derived `PartialOrd`
3737
--> $DIR/derive_ord_xor_partial_ord.rs:42:1
@@ -48,7 +48,7 @@ note: `PartialOrd` implemented here
4848
|
4949
LL | #[derive(PartialOrd, PartialEq, Eq)]
5050
| ^^^^^^^^^^
51-
= note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
51+
= note: this error originates in the derive macro `PartialOrd` (in Nightly builds, run with -Z macro-backtrace for more info)
5252

5353
error: you are implementing `Ord` explicitly but have derived `PartialOrd`
5454
--> $DIR/derive_ord_xor_partial_ord.rs:62:5
@@ -65,7 +65,7 @@ note: `PartialOrd` implemented here
6565
|
6666
LL | #[derive(PartialOrd, PartialEq, Eq)]
6767
| ^^^^^^^^^^
68-
= note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)
68+
= note: this error originates in the derive macro `PartialOrd` (in Nightly builds, run with -Z macro-backtrace for more info)
6969

7070
error: aborting due to 4 previous errors
7171

tests/ui/doc_unsafe.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ LL | | }
4141
LL | very_unsafe!();
4242
| --------------- in this macro invocation
4343
|
44-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
44+
= note: this error originates in the macro `very_unsafe` (in Nightly builds, run with -Z macro-backtrace for more info)
4545

4646
error: aborting due to 5 previous errors
4747

tests/ui/eq_op_macros.stderr

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ LL | assert_in_macro_def!();
88
| ----------------------- in this macro invocation
99
|
1010
= note: `-D clippy::eq-op` implied by `-D warnings`
11-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
11+
= note: this error originates in the macro `assert_in_macro_def` (in Nightly builds, run with -Z macro-backtrace for more info)
1212

1313
error: identical args used in this `assert_ne!` macro call
1414
--> $DIR/eq_op_macros.rs:8:20
@@ -19,7 +19,7 @@ LL | assert_ne!(a, a);
1919
LL | assert_in_macro_def!();
2020
| ----------------------- in this macro invocation
2121
|
22-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
22+
= note: this error originates in the macro `assert_in_macro_def` (in Nightly builds, run with -Z macro-backtrace for more info)
2323

2424
error: identical args used in this `assert_eq!` macro call
2525
--> $DIR/eq_op_macros.rs:22:16
@@ -54,7 +54,7 @@ LL | debug_assert_eq!(a, a);
5454
LL | assert_in_macro_def!();
5555
| ----------------------- in this macro invocation
5656
|
57-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
57+
= note: this error originates in the macro `assert_in_macro_def` (in Nightly builds, run with -Z macro-backtrace for more info)
5858

5959
error: identical args used in this `debug_assert_ne!` macro call
6060
--> $DIR/eq_op_macros.rs:10:26
@@ -65,7 +65,7 @@ LL | debug_assert_ne!(a, a);
6565
LL | assert_in_macro_def!();
6666
| ----------------------- in this macro invocation
6767
|
68-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
68+
= note: this error originates in the macro `assert_in_macro_def` (in Nightly builds, run with -Z macro-backtrace for more info)
6969

7070
error: identical args used in this `debug_assert_eq!` macro call
7171
--> $DIR/eq_op_macros.rs:38:22

tests/ui/fallible_impl_from.stderr

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ note: potential failure(s)
3838
|
3939
LL | panic!();
4040
| ^^^^^^^^^
41-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
41+
= note: this error originates in the macro `$crate::panic::panic_2015` (in Nightly builds, run with -Z macro-backtrace for more info)
4242

4343
error: consider implementing `TryFrom` instead
4444
--> $DIR/fallible_impl_from.rs:35:1
@@ -65,7 +65,7 @@ LL | } else if s.parse::<u32>().unwrap() != 42 {
6565
| ^^^^^^^^^^^^^^^^^^^^^^^^^
6666
LL | panic!("{:?}", s);
6767
| ^^^^^^^^^^^^^^^^^^
68-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
68+
= note: this error originates in the macro `$crate::panic::panic_2015` (in Nightly builds, run with -Z macro-backtrace for more info)
6969

7070
error: consider implementing `TryFrom` instead
7171
--> $DIR/fallible_impl_from.rs:53:1
@@ -87,7 +87,7 @@ LL | if s.parse::<u32>().ok().unwrap() != 42 {
8787
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
8888
LL | panic!("{:?}", s);
8989
| ^^^^^^^^^^^^^^^^^^
90-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
90+
= note: this error originates in the macro `$crate::panic::panic_2015` (in Nightly builds, run with -Z macro-backtrace for more info)
9191

9292
error: aborting due to 4 previous errors
9393

tests/ui/implicit_hasher.stderr

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ LL | impl<K: Hash + Eq, V> Foo<u8> for HashMap<K, V> {
109109
LL | gen!(impl);
110110
| ----------- in this macro invocation
111111
|
112-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
112+
= note: this error originates in the macro `gen` (in Nightly builds, run with -Z macro-backtrace for more info)
113113
help: consider adding a type parameter
114114
|
115115
LL | impl<K: Hash + Eq, V, S: ::std::hash::BuildHasher + Default> Foo<u8> for HashMap<K, V, S> {
@@ -128,7 +128,7 @@ LL | pub fn $name(_map: &mut HashMap<i32, i32>, _set: &mut HashSet<i32>)
128128
LL | gen!(fn bar);
129129
| ------------- in this macro invocation
130130
|
131-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
131+
= note: this error originates in the macro `gen` (in Nightly builds, run with -Z macro-backtrace for more info)
132132
help: consider adding a type parameter
133133
|
134134
LL | pub fn $name<S: ::std::hash::BuildHasher>(_map: &mut HashMap<i32, i32, S>, _set: &mut HashSet<i32>) {}
@@ -143,7 +143,7 @@ LL | pub fn $name(_map: &mut HashMap<i32, i32>, _set: &mut HashSet<i32>)
143143
LL | gen!(fn bar);
144144
| ------------- in this macro invocation
145145
|
146-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
146+
= note: this error originates in the macro `gen` (in Nightly builds, run with -Z macro-backtrace for more info)
147147
help: consider adding a type parameter
148148
|
149149
LL | pub fn $name<S: ::std::hash::BuildHasher>(_map: &mut HashMap<i32, i32>, _set: &mut HashSet<i32, S>) {}

tests/ui/item_after_statement.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ LL | | }
2727
LL | b!();
2828
| ----- in this macro invocation
2929
|
30-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
30+
= note: this error originates in the macro `b` (in Nightly builds, run with -Z macro-backtrace for more info)
3131

3232
error: aborting due to 3 previous errors
3333

tests/ui/match_same_arms2.stderr

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ help: consider refactoring into `(Ok(x), Some(_)) | (Ok(_), Some(x))`
121121
|
122122
LL | (Ok(x), Some(_)) => println!("ok {}", x),
123123
| ^^^^^^^^^^^^^^^^
124-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
124+
= note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
125125

126126
error: this `match` has identical arm bodies
127127
--> $DIR/match_same_arms2.rs:117:18
@@ -139,7 +139,7 @@ help: consider refactoring into `Ok(3) | Ok(_)`
139139
|
140140
LL | Ok(3) => println!("ok"),
141141
| ^^^^^
142-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
142+
= note: this error originates in the macro `println` (in Nightly builds, run with -Z macro-backtrace for more info)
143143

144144
error: this `match` has identical arm bodies
145145
--> $DIR/match_same_arms2.rs:144:14

tests/ui/mem_discriminant.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ LL | mem_discriminant_but_in_a_macro!(&rro);
7272
| | help: try dereferencing: `*rro`
7373
| in this macro invocation
7474
|
75-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
75+
= note: this error originates in the macro `mem_discriminant_but_in_a_macro` (in Nightly builds, run with -Z macro-backtrace for more info)
7676

7777
error: calling `mem::discriminant` on non-enum type `&&&&&std::option::Option<i32>`
7878
--> $DIR/mem_discriminant.rs:34:5

tests/ui/mem_replace_macro.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ LL | take!(s);
88
| --------- in this macro invocation
99
|
1010
= note: `-D clippy::mem-replace-with-default` implied by `-D warnings`
11-
= note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info)
11+
= note: this error originates in the macro `take` (in Nightly builds, run with -Z macro-backtrace for more info)
1212

1313
error: aborting due to previous error
1414

0 commit comments

Comments
 (0)