about summary refs log tree commit diff
path: root/src/librustc_trait_selection
AgeCommit message (Collapse)AuthorLines
2020-07-31Move from `log` to `tracing`Oliver Scherer-1/+1
2020-07-29handle ConstEquate in rustdocBastian Kauschke-0/+32
2020-07-27Auto merge of #73503 - lcnr:forall-predicate-what-and-why-2, r=nikomatsakisbors-427/+461
convert higher ranked `Predicate`s to `PredicateKind::ForAll` implements step 2 of https://github.com/rust-lang/compiler-team/issues/285 r? @nikomatsakis
2020-07-27cleanupBastian Kauschke-1/+1
2020-07-27it works again :tada:Bastian Kauschke-34/+33
2020-07-27fix rebaseBastian Kauschke-23/+25
2020-07-27directly contain `PredicateAtom` in `PredicateKind::ForAll`Bastian Kauschke-36/+32
2020-07-27introduce PredicateAtomBastian Kauschke-322/+297
2020-07-27add reuse_or_mk_predicateBastian Kauschke-1/+1
2020-07-27this might be unqualified, but at least it's now quantifiedBastian Kauschke-24/+24
2020-07-27split ignore_qualifiersBastian Kauschke-34/+34
2020-07-27reviewBastian Kauschke-19/+11
2020-07-27fix elaborate for predicates with unbound variablesBastian Kauschke-1/+1
2020-07-27`PredicateKint` -> `PredicateKind`, the beginning of the endBastian Kauschke-162/+200
2020-07-27elaborateBastian Kauschke-5/+3
2020-07-27somewhat related cleanupBastian Kauschke-3/+3
2020-07-27wfBastian Kauschke-17/+19
2020-07-27convert trivial predicatesBastian Kauschke-2/+2
2020-07-27Handle trait/projection predicates with bound regions correctlyMatthew Jasper-69/+131
2020-07-27minimalBastian Kauschke-69/+39
2020-07-27More ensure stack to avoid segfault with increased `recursion_limit`Yuki Okushi-18/+28
2020-07-25Use the proper span when WF-checking an impl self typeAaron Hill-4/+12
2020-07-22Use `ty::Instance::resolve` to identify `'static` bound sourceEsteban Küber-1/+14
2020-07-22Increase accuracy of lifetime bound on trait object impl suggestionEsteban Küber-0/+1
2020-07-22Rollup merge of #74454 - lcnr:negative-impls, r=nikomatsakisManish Goregaokar-52/+47
small coherence cleanup r? @eddyb
2020-07-20update coherence docsBastian Kauschke-7/+7
2020-07-20reviewBastian Kauschke-1/+10
2020-07-20trait_sel: only test predicates w/ no substsDavid Wood-15/+15
This commit modifies the `substitute_normalize_and_test_predicates` query, renaming it to `impossible_predicates` and only checking predicates which do not require substs. By making this change, polymorphization doesn't have to explicitly support vtables. Signed-off-by: David Wood <david@davidtw.co>
2020-07-17refactor ty_is_non_localBastian Kauschke-15/+18
2020-07-17cleanup ty_is_~non~_local_constructorBastian Kauschke-38/+21
2020-07-17Rename TypeckTables to TypeckResults.Valentin Lazureanu-27/+27
2020-07-17Remove some `Symbol:as_str()` calls.Nicholas Nethercote-2/+2
2020-07-16Rename `sym::item_context` as `sym::ItemContext`.Nicholas Nethercote-4/+4
Because it represents the symbol `ItemContext`, and `sym` identifiers are supposed to match the actual symbol whenever possible.
2020-07-15Rollup merge of #74344 - estebank:stringly-wobbly, r=eddybManish Goregaokar-7/+11
Remove string comparison and use diagnostic item instead r? @eddyb
2020-07-15Rollup merge of #74276 - lcnr:discriminant-kind-what, r=nagisaManish Goregaokar-15/+5
improve DiscriminantKind handling Adds a lang item `discriminant_type` for the associated type `DiscriminantKind::Discriminant`. Changes the discriminant of generators from `i32` to `u32`, which should not be observable to fix an oversight where MIR was using `u32` and codegen and typeck used `i32`.
2020-07-15const_eval_resolveBastian Kauschke-5/+5
2020-07-15ConstKind::UnevaluatedBastian Kauschke-7/+7
2020-07-15improve DiscriminantKind handlingBastian Kauschke-15/+5
This now reuses `fn discriminant_ty` in project, removing some code duplication. Doing so made me realize that we previously had a disagreement about the discriminant type of generators, with MIR using `u32` and codegen and trait selection using `i32`. We now always use `u32`.
2020-07-15Auto merge of #74175 - nnethercote:more-static-symbols, r=oli-obkbors-2/+6
More static symbols These commits add some more static symbols and convert lots of places to use them. r? @oli-obk
2020-07-14Remove string comparison and use diagnostic item insteadEsteban Küber-7/+11
2020-07-15Add and use more static symbols.Nicholas Nethercote-2/+6
Note that the output of `unpretty-debug.stdout` has changed. In that test the hash values are normalized from a symbol numbers to small numbers like "0#0" and "0#1". The increase in the number of static symbols must have caused the original numbers to contain more digits, resulting in different pretty-printing prior to normalization.
2020-07-14Reword messageEsteban Küber-1/+2
2020-07-14Remove redundant explanatory `note` for type parametersEsteban Küber-1/+6
2020-07-14Suggest borrowing in more unsized fn param casesEsteban Küber-35/+31
2020-07-14Suggest boxing or borrowing unsized fieldsEsteban Küber-18/+35
2020-07-14Suggest borrowing unsized argument typesEsteban Küber-3/+15
2020-07-10Avoid "whitelist"Tamir Duberstein-1/+1
Other terms are more inclusive and precise.
2020-07-09Rollup merge of #74070 - eddyb:forall-tcx-providers, r=nikomatsakisManish Goregaokar-3/+3
Use for<'tcx> fn pointers in Providers, instead of having Providers<'tcx>. In order to work around normalization-under-HRTB (for `provide!` in `rustc_metadata`), we ended up with this: ```rust struct Providers<'tcx> { type_of: fn(TyCtxt<'tcx>, DefId) -> Ty<'tcx>, // ... } ``` But what I initially wanted to do, IIRC, was this: ```rust struct Providers { type_of: for<'tcx> fn(TyCtxt<'tcx>, DefId) -> Ty<'tcx>, // ... } ``` This PR moves to the latter, for the simple reason that only the latter allows keeping a `Providers` value, or a subset of its `fn` pointer fields, around in a `static` or `thread_local!`, which can be really useful for custom drivers that override queries. (@jyn514 and I came across a concrete usecase of that in `rustdoc`) The `provide!` macro in `rustc_metadata` is fixed by making the query key/value types available as type aliases under `ty::query::query_{keys,values}`, not just associated types (this is the first commit). r? @nikomatsakis
2020-07-06Auto merge of #73978 - Mark-Simulacrum:shrink-paramenv, r=nnethercotebors-22/+27
Shrink ParamEnv to 16 bytes r? @nnethercote x.py check passes but I haven't tried running perf or tests
2020-07-05Use for<'tcx> fn pointers in Providers, instead of having Providers<'tcx>.Eduard-Mihai Burtescu-3/+3