Files
rust/tests/ui/consts/const-eval
Matthias Krüger 215d7b661e Rollup merge of #148717 - estebank:macro-spans-2, r=petrochenkov
Point at span within local macros even when error happens in nested external macro

Address issue noticed at https://users.rust-lang.org/t/error-message-does-not-specify-where-in-macro/135157/1. On errors occurring within a macro expansion, point at the innermost local macro expansion point.

```
error[E0308]: mismatched types
  --> $DIR/macro-span-caller-replacement.rs:5:17
   |
LL |             s = format!("{arg}");
   |                 ^^^^^^^^^^^^^^^^ expected `&str`, found `String`
...
LL |     macro_with_format!();
   |     -------------------- in this macro invocation
   |
   = note: this error originates in the macro `format` which comes from the expansion of the macro `macro_with_format` (in Nightly builds, run with -Z macro-backtrace for more info)
```
2025-12-11 22:09:53 +01:00
..
2025-09-03 15:24:49 +02:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2025-11-27 14:13:58 -05:00
2025-11-27 14:13:58 -05:00
2025-11-02 20:12:26 +00:00
2023-01-11 09:32:08 +00:00
2024-09-15 09:51:32 +02:00
2025-11-27 14:13:58 -05:00
2025-11-27 14:13:58 -05:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2024-09-15 09:51:32 +02:00
2023-01-11 09:32:08 +00:00
2023-01-11 09:32:08 +00:00
2025-07-18 07:47:08 +00:00
2025-09-03 15:24:49 +02:00
2025-11-27 14:13:58 -05:00
2025-11-27 14:13:58 -05:00
2025-11-27 14:13:58 -05:00
2025-07-18 07:47:08 +00:00
2024-04-22 18:48:47 +02:00