summary refs log tree commit diff
path: root/src/test/ui/impl-trait
AgeCommit message (Collapse)AuthorLines
2017-12-19Point at def span in "missing in impl" errorEsteban Küber-1/+1
2017-12-14Remove NOTE/HELP annotations from UI testsVadim Petrochenkov-113/+77
2017-11-27Make main span in impl-trait ciclic reference point to def_spanEsteban Küber-8/+2
2017-11-26Make impl-trait ciclical reference error point to def_spanEsteban Küber-16/+4
2017-11-26Move "auto trait leak" impl-trait cycle dependency test to uiEsteban Küber-0/+139
2017-11-24Merge cfail and ui tests into ui testsOliver Schneider-154/+129
2017-11-23Auto merge of #46024 - estebank:no-variant, r=petrochenkovbors-0/+15
Use the proper term when using non-existing variant When using a non-existing variant, function or associated item, refer to the proper term, instead of defaulting to "associated item" in diagnostics. Fix #28972. ``` error[E0599]: no variant named `Quux` found for type `Foo` in the current scope --> file.rs:7:9 | 7 | Foo::Quux(..) =>(), | ^^^^^^^^^^^^^ ```
2017-11-20Add structured suggestions for trait importsOliver Schneider-18/+36
2017-11-16Use local spans onlyEsteban Küber-136/+57
2017-11-16Remove left over dead code from suggestion diagnostic refactoringOliver Schneider-2/+0
2017-11-15Point to ADT definition when not finding variant, method, assoc typeEsteban Küber-56/+150
2017-11-15add a new test featuring two impl traits to show what it looks likeNiko Matsakis-0/+32
2017-11-15Add/Fix stderr references for impl Trait ui testsChristopher Vittal-1/+31
2017-11-15some tests featuring multiple bounds, other errorsNiko Matsakis-0/+26
2017-11-15add a UI test showing the current output from an impl trait typeNiko Matsakis-0/+32
2017-08-29remove the hacky selection impl in `method::probe`Ariel Ben-Yehuda-0/+4
2017-07-02report the total number of errors on compilation failureAriel Ben-Yehuda-4/+4
Prior to this PR, when we aborted because a "critical pass" failed, we displayed the number of errors from that critical pass. While that's the number of errors that caused compilation to abort in *that place*, that's not what people really want to know. Instead, always report the total number of errors, and don't bother to track the number of errors from the last pass that failed. This changes the compiler driver API to handle errors more smoothly, and therefore is a compiler-api-[breaking-change]. Fixes #42793.
2017-07-02Revert "Change error count messages"Ariel Ben-Yehuda-1/+1
This reverts commit 5558c64f33446225739c1153b43d2e309bb4f50e.
2017-06-05Auto merge of #42383 - estebank:candidate-newline, r=arielb1bors-0/+494
Use multiline note for trait suggestion
2017-06-04Separate suggestion in a `help` and a `note`Esteban Küber-20/+40
2017-06-04Show trait method signature when impl differsEsteban Küber-0/+65
When the trait's span is available, it is already being used, add a `note` for the cases where the span isn't available: ``` error[E0053]: method `fmt` has an incompatible type for trait --> $DIR/trait_type.rs:17:4 | 17 | fn fmt(&self, x: &str) -> () { } | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ types differ in mutability | = note: expected type `fn(&MyType, &mut std::fmt::Formatter<'_>) -> std::result::Result<(), std::fmt::Error>` found type `fn(&MyType, &str)` error[E0050]: method `fmt` has 1 parameter but the declaration in trait `std::fmt::Display::fmt` has 2 --> $DIR/trait_type.rs:21:11 | 21 | fn fmt(&self) -> () { } | ^^^^^ expected 2 parameters, found 1 | = note: `fmt` from trait: `fn(&Self, &mut std::fmt::Formatter<'_>) -> std::result::Result<(), std::fmt::Error>` error[E0186]: method `fmt` has a `&self` declaration in the trait, but not in the impl --> $DIR/trait_type.rs:25:4 | 25 | fn fmt() -> () { } | ^^^^^^^^^^^^^^^^^^ expected `&self` in impl | = note: `fmt` from trait: `fn(&Self, &mut std::fmt::Formatter<'_>) -> std::result::Result<(), std::fmt::Error>` error[E0046]: not all trait items implemented, missing: `fmt` --> $DIR/trait_type.rs:28:1 | 28 | impl std::fmt::Display for MyType4 {} | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `fmt` in implementation | = note: `fmt` from trait: `fn(&Self, &mut std::fmt::Formatter<'_>) -> std::result::Result<(), std::fmt::Error>` ```
2017-06-02Use multiline note for trait suggestionEsteban Küber-0/+474
2017-06-01tests: fix fallout from changing the span of binop errors.Eduard-Mihai Burtescu-2/+2
2017-05-24Rollup merge of #42150 - citizen428:feature/error-count-messages, ↵Mark Simulacrum-1/+1
r=Mark-Simulacrum Change error count messages See #33525 for details. r? @Mark-Simulacrum
2017-05-24Change error count messagesMichael Kohl-1/+1
See #33525 for details.
2017-05-17Add better error message when == operator is badly usedGuillaume Gomez-2/+2
2017-04-10Explicit help message for binop type missmatchEsteban Küber-0/+127
When trying to do a binary operation with missing implementation, for example `1 + Some(2)`, provide an explicit help message: ``` note: no implementation for `{integer} + std::option::Option<{integer}>` ``` Use `rustc_on_unimplemented` for the suggestions. Move cfail test to ui.