summary refs log tree commit diff
path: root/compiler/rustc_middle/src/traits
AgeCommit message (Collapse)AuthorLines
2020-10-30Update chalk 0.32.0 -> 0.35.0Matthew Jasper-42/+26
2020-10-23Review comments: use newtype instead of `bool`Esteban Küber-2/+15
2020-10-23Account for possible boxable `impl Future` in semicolon removal suggestionsEsteban Küber-2/+2
2020-10-22Reduce diagram mess in 'match arms have incompatible types' errorDavid Tolnay-0/+1
2020-10-22Normalize when finding trait object candidatesMatthew Jasper-1/+4
2020-10-20review commentsEsteban Küber-1/+1
2020-10-20Tweak "object unsafe" errorsEsteban Küber-20/+54
Fix #77598.
2020-10-06Handle multiple applicable projection candidatesMatthew Jasper-3/+4
2020-10-06Rollup merge of #76995 - LingMan:middle_matches, r=varkorYuki Okushi-4/+1
Reduce boilerplate with the matches! macro Replaces simple bool `match`es of the form match $expr { $pattern => true _ => false } and their inverse with invocations of the matches! macro. Limited to rustc_middle for now to get my feet wet.
2020-09-24remove enum name from ImplSource variantsBastian Kauschke-56/+55
2020-09-21Reduce boilerplate with the matches! macroLingMan-4/+1
Replaces simple bool `match`es of the form match $expr { $pattern => true _ => false } and their inverse with invocations of the matches! macro.
2020-09-14Auto merge of #75608 - estebank:suggest-boxed-match-exprs, r=lcnr,varkorbors-0/+3
More structured suggestions for boxed trait objects instead of impl Trait on non-coerceable tail expressions When encountering a `match` or `if` as a tail expression where the different arms do not have the same type *and* the return type of that `fn` is an `impl Trait`, check whether those arms can implement `Trait` and if so, suggest using boxed trait objects. Use structured suggestion for `impl T` to `Box<dyn T>`. Fix https://github.com/rust-lang/rust/issues/69107
2020-09-11Add test cases and address review commentsEsteban Küber-2/+2
2020-09-11Suggest boxed trait objects in tail `match` and `if` expressionsEsteban Küber-0/+3
When encountering a `match` or `if` as a tail expression where the different arms do not have the same type *and* the return type of that `fn` is an `impl Trait`, check whether those arms can implement `Trait` and if so, suggest using boxed trait objects.
2020-09-09Remove def_id field from ParamEnvBram van den Heuvel-31/+5
2020-09-07Rollup merge of #76340 - jonas-schievink:rm-dupe, r=Mark-SimulacrumDylan DPC-68/+0
Remove unused duplicated `trivial_dropck_outlives` The copy that is actually in use now lives here: https://github.com/rust-lang/rust/blob/d2454643e137bde519786ee9e650c455d7ad6f34/compiler/rustc_trait_selection/src/traits/query/dropck_outlives.rs#L84
2020-09-04Review commentsJack Huey-23/+19
2020-09-04More chalk workJack Huey-0/+38
2020-09-04Upgrade chalk to 0.21Jack Huey-0/+15
2020-09-04Remove unused duplicated `trivial_dropck_outlives`Jonas Schievink-68/+0
2020-09-04Change ty.kind to a methodLeSeulArtichaut-1/+1
2020-08-30mv compiler to compiler/mark-0/+2060