rust/tests/ui/fmt
Esteban Küber 6efddac288 Provide more context on derived obligation error primary label
Expand the primary span of E0277 when the immediate unmet bound is not what the user wrote:

```
error[E0277]: the trait bound `i32: Bar` is not satisfied
 --> f100.rs:6:6
  |
6 |     <i32 as Foo>::foo();
  |      ^^^ the trait `Bar` is not implemented for `i32`, which is required by `i32: Foo`
  |
help: this trait has no implementations, consider adding one
 --> f100.rs:2:1
  |
2 | trait Bar {}
  | ^^^^^^^^^
note: required for `i32` to implement `Foo`
 --> f100.rs:3:14
  |
3 | impl<T: Bar> Foo for T {}
  |         ---  ^^^     ^
  |         |
  |         unsatisfied trait bound introduced here
```

Fix #40120.
2024-01-30 21:28:18 +00:00
..
auxiliary Properly allow macro expanded format_args invocations to uses captures 2023-03-14 13:16:52 +00:00
closing-brace-as-fill.rs Improve error message when closing bracket interpreted as formatting fill character 2023-07-19 16:37:09 +00:00
closing-brace-as-fill.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
format-args-argument-span.rs Add test for span of implicit format args captures. 2023-03-27 14:57:02 +02:00
format-args-argument-span.stderr Tweak output for 'add line' suggestion 2023-04-12 22:50:10 +00:00
format-args-capture-first-literal-is-macro.rs Properly allow macro expanded format_args invocations to uses captures 2023-03-14 13:16:52 +00:00
format-args-capture-first-literal-is-macro.stderr Properly allow macro expanded format_args invocations to uses captures 2023-03-14 13:16:52 +00:00
format-args-capture-from-pm-first-arg-macro.rs Properly allow macro expanded format_args invocations to uses captures 2023-03-14 13:16:52 +00:00
format-args-capture-from-pm-first-arg-macro.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
format-args-capture-issue-93378.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
format-args-capture-issue-93378.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
format-args-capture-issue-94010.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
format-args-capture-issue-94010.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
format-args-capture-issue-102057.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
format-args-capture-issue-102057.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
format-args-capture-issue-106408.rs Properly allow macro expanded format_args invocations to uses captures 2023-03-14 13:16:52 +00:00
format-args-capture-macro-hygiene-pass.rs Properly allow macro expanded format_args invocations to uses captures 2023-03-14 13:16:52 +00:00
format-args-capture-macro-hygiene.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
format-args-capture-macro-hygiene.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
format-args-capture-missing-variables.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
format-args-capture-missing-variables.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
format-args-capture.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
format-expanded-string.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
format-expanded-string.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
format-raw-string-error.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
format-raw-string-error.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
format-string-error-2.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
format-string-error-2.stderr Fix quotes in output 2023-07-19 16:27:28 +00:00
format-string-error.rs fixup tests wrt new normalization 2023-04-28 11:56:02 +00:00
format-string-error.stderr Fix quotes in output 2023-07-19 16:27:28 +00:00
format-string-wrong-order.rs Adding alignment to the list of cases to test for specific error message. Covers >, ^ and <. 2024-01-07 20:39:46 +01:00
format-string-wrong-order.stderr Removing redudant note from parse error 2024-01-08 19:41:01 +01:00
format-with-yield-point.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
ifmt-bad-arg.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
ifmt-bad-arg.stderr Fix quotes in output 2023-07-19 16:27:28 +00:00
ifmt-bad-format-args.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
ifmt-bad-format-args.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
ifmt-unimpl.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
ifmt-unimpl.stderr Provide more context on derived obligation error primary label 2024-01-30 21:28:18 +00:00
ifmt-unknown-trait.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
ifmt-unknown-trait.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
incorrect-separator.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
incorrect-separator.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
indoc-issue-106408.rs Revert "Improve heuristics whether format_args string is a source literal" 2023-01-18 20:33:17 +01:00
issue-75307.rs Move tests 2023-02-16 11:42:35 -03:00
issue-75307.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-86085.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-86085.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-89173.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-89173.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-91556.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-91556.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
issue-103826.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-103826.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-104142.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
issue-104142.stderr Show number in error message even for one error 2023-11-24 19:15:52 +01:00
raw-idents.rs add diagnostic for raw identifiers in format string 2023-09-06 18:55:45 +02:00
raw-idents.stderr add diagnostic for raw identifiers in format string 2023-09-06 18:55:45 +02:00
respanned-literal-issue-106191.rs Properly allow macro expanded format_args invocations to uses captures 2023-03-14 13:16:52 +00:00
respanned-literal-issue-106191.stderr Properly allow macro expanded format_args invocations to uses captures 2023-03-14 13:16:52 +00:00
send-sync.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
send-sync.stderr Provide more context on derived obligation error primary label 2024-01-30 21:28:18 +00:00
struct-field-as-captured-argument.fixed Move /src/test to /tests 2023-01-11 09:32:08 +00:00
struct-field-as-captured-argument.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
struct-field-as-captured-argument.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00
suggest-inline-args.rs Add suggestion to quote inlined format argument as string literal 2023-08-05 17:29:06 +08:00
suggest-inline-args.stderr Add suggestion to quote inlined format argument as string literal 2023-08-05 17:29:06 +08:00
unicode-escape-spans.rs Move /src/test to /tests 2023-01-11 09:32:08 +00:00
unicode-escape-spans.stderr Move /src/test to /tests 2023-01-11 09:32:08 +00:00