rust/src/test/ui/if
Mazdak Farrokhzad 12c1e9a193
Rollup merge of #66134 - estebank:unknown-formatting-trait, r=nikomatsakis
Point at formatting descriptor string when it is invalid

When a formatting string contains an invalid descriptor, point at it
instead of the argument:

```
error: unknown format trait `foo`
  --> $DIR/ifmt-bad-arg.rs:86:17
   |
LL |     println!("{:foo}", 1);
   |                 ^^^
   |
   = note: the only appropriate formatting traits are:
           - ``, which uses the `Display` trait
           - `?`, which uses the `Debug` trait
           - `e`, which uses the `LowerExp` trait
           - `E`, which uses the `UpperExp` trait
           - `o`, which uses the `Octal` trait
           - `p`, which uses the `Pointer` trait
           - `b`, which uses the `Binary` trait
           - `x`, which uses the `LowerHex` trait
           - `X`, which uses the `UpperHex` trait
```
2019-11-09 07:18:32 +01:00
..
if-branch-types.rs Remove licenses 2018-12-25 21:08:33 -07:00
if-branch-types.stderr Tweak output of type mismatch between "then" and else if arms 2019-01-13 17:35:59 -08:00
if-let-arm-types.rs Various test changes 2019-05-10 19:41:10 +02:00
if-let-arm-types.stderr Various test changes 2019-05-10 19:41:10 +02:00
if-let.rs Update error annotations positions 2019-11-03 10:20:11 +01:00
if-let.stderr Update error annotations positions 2019-11-03 10:20:11 +01:00
if-loop.rs compiletest: Remove skip-codegen 2019-06-16 12:23:22 +03:00
if-no-match-bindings.rs Make sure while-exprs require 'cond: bool' exactly. 2019-07-06 06:43:58 +02:00
if-no-match-bindings.stderr Call Expr::peel_drop_temps() from more places for more accurate suggestions 2019-10-08 08:42:26 -07:00
if-typeck.rs Remove licenses 2018-12-25 21:08:33 -07:00
if-typeck.stderr Remove licenses 2018-12-25 21:08:33 -07:00
if-without-block.rs Remove licenses 2018-12-25 21:08:33 -07:00
if-without-block.stderr Remove licenses 2018-12-25 21:08:33 -07:00
if-without-else-as-fn-expr.rs Emit a single error on if expr with expectation and no else clause 2019-08-31 18:34:50 -07:00
if-without-else-as-fn-expr.stderr Emit a single error on if expr with expectation and no else clause 2019-08-31 18:34:50 -07:00
if-without-else-result.rs Remove licenses 2018-12-25 21:08:33 -07:00
if-without-else-result.stderr Add more details to elseless if error 2019-03-07 14:37:18 -08:00
ifmt-bad-arg.rs Do not ICE whith a precision flag in formatting str and no format arguments 2019-11-05 11:01:43 -08:00
ifmt-bad-arg.stderr Rollup merge of #66134 - estebank:unknown-formatting-trait, r=nikomatsakis 2019-11-09 07:18:32 +01:00
ifmt-bad-format-args.rs Remove licenses 2018-12-25 21:08:33 -07:00
ifmt-bad-format-args.stderr Increase spacing for suggestions in diagnostics 2019-10-24 12:26:01 -07:00
ifmt-unimpl.rs Remove licenses 2018-12-25 21:08:33 -07:00
ifmt-unimpl.stderr Remove licenses 2018-12-25 21:08:33 -07:00
ifmt-unknown-trait.rs Remove licenses 2018-12-25 21:08:33 -07:00
ifmt-unknown-trait.stderr Point at formatting descriptor string when it is invalid 2019-11-05 14:06:38 -08:00