about summary refs log tree commit diff
path: root/compiler/rustc_trait_selection
AgeCommit message (Collapse)AuthorLines
2021-09-09tidyEllen-19/+17
2021-09-09dont support blocksEllen-42/+12
2021-09-09as casts and block exprsEllen-32/+54
2021-09-09WIP stateEllen-222/+145
2021-09-06Use index newtyping for TyVidMark Rousskov-2/+2
2021-09-05Add query `own_existential_vtable_entries`Gary Guo-45/+54
2021-09-05Stop allocating vtable entries for non-object-safe methodsGary Guo-8/+13
2021-09-04Add line that was unintentionally removedEthan Brierley-0/+1
2021-09-04Make fields on `AbstractConst` privateEthan Brierley-12/+12
2021-09-04Remove left over commentEthan Brierley-4/+1
2021-09-04Minor cleanup: make imports more consistentEthan Brierley-2/+1
2021-09-04`AbstractConst::root`: Always run `subst` when `Node` is `Leaf`Ethan Brierley-21/+22
2021-09-03Auto merge of #88618 - m-ou-se:rollup-6tss5z6, r=m-ou-sebors-30/+5
Rollup of 7 pull requests Successful merges: - #88202 (Add an example for deriving PartialOrd on enums) - #88483 (Fix LLVM libunwind build for non-musl targets) - #88507 (Add test case for using `slice::fill` with MaybeUninit) - #88557 (small const generics cleanup) - #88579 (remove redundant / misplaced sentence from docs) - #88610 (Update outdated docs of array::IntoIter::new.) - #88613 (Update primitive docs for rust 2021.) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
2021-09-03Rollup merge of #88557 - lcnr:const-generics-cleanup, r=BoxyUwUMara Bos-30/+5
small const generics cleanup
2021-09-03Auto merge of #86454 - tlyu:refactor-unsized-suggestions, r=davidtwcobors-67/+112
Refactor unsized suggestions `@rustbot` label +A-diagnostics +A-traits +A-typesystem +C-cleanup +T-compiler
2021-09-02Report cycle error using 'deepest' obligation in the cycleAaron Hill-1/+3
2021-09-02Preserve most sub-obligations in the projection cacheAaron Hill-49/+26
2021-09-01fix(rustc): suggest `items` be borrowed in `for i in items[x..]`Michael Howell-4/+13
Fixes #87994
2021-09-01cleanup const generics FIXMElcnr-30/+5
2021-08-30Enforce diverging let...elseCameron Steffen-4/+5
2021-08-30rename const_evaluatable_checked to generic_const_exprsEllen-11/+11
:sparkles:
2021-08-27fmtDeadbeef-25/+30
2021-08-27Add `ty::BoundConstness`Deadbeef-22/+23
2021-08-27Auto merge of #88371 - Manishearth:rollup-pkkjsme, r=Manishearthbors-1/+5
Rollup of 11 pull requests Successful merges: - #87832 (Fix debugger stepping behavior with `match` expressions) - #88123 (Make spans for tuple patterns in E0023 more precise) - #88215 (Reland #83738: "rustdoc: Don't load all extern crates unconditionally") - #88216 (Don't stabilize creation of TryReserveError instances) - #88270 (Handle type ascription type ops in NLL HRTB diagnostics) - #88289 (Fixes for LLVM change 0f45c16f2caa7c035e5c3edd40af9e0d51ad6ba7) - #88320 (type_implements_trait consider obligation failure on overflow) - #88332 (Add argument types tait tests) - #88340 (Add `c_size_t` and `c_ssize_t` to `std::os::raw`.) - #88346 (Revert "Add type of a let tait test impl trait straight in let") - #88348 (Add field types tait tests) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
2021-08-26Rollup merge of #88320 - sexxi-goose:issue-88103, r=nikomatsakisManish Goregaokar-1/+5
type_implements_trait consider obligation failure on overflow Fixes: #88103
2021-08-26rebaselcnr-4/+12
2021-08-26reviewlcnr-6/+6
2021-08-26shrink `ty::PredicateKind` againlcnr-7/+7
2021-08-26use `ty::Unevaluated` instead of def substs pairlcnr-47/+39
2021-08-26update `TypeFlags` to deal with missing ct substslcnr-12/+16
2021-08-26add `tcx` to `fn walk`lcnr-8/+9
2021-08-26make unevaluated const substs optionallcnr-20/+17
2021-08-26require a `tcx` for `TypeVisitor`lcnr-2/+16
2021-08-25trailing whitespaceNiko Matsakis-1/+1
2021-08-25update docs for `type_implements_trait`Niko Matsakis-0/+4
2021-08-25type_implements_trait consider obligation failure on overflowAman Arora-1/+1
2021-08-24Review commentsjackh726-39/+66
2021-08-24Normalize associated types with bound varsJack Huey-70/+115
2021-08-23Rollup merge of #88230 - steffahn:a_an, r=oli-obkMara Bos-10/+10
Fix typos “a”→“an” Fix typos in comments; found using a regex to find some easy instance of incorrect usage of a vs. an. While automation was used to find these, every change was checked manually. Changes in submodules get separate PRs: * https://github.com/rust-lang/stdarch/pull/1201 * https://github.com/rust-lang/cargo/pull/9821 * https://github.com/rust-lang/miri/pull/1874 * https://github.com/rust-lang/rls/pull/1746 * https://github.com/rust-analyzer/rust-analyzer/pull/9984 _folks @ rust-analyzer are fast at merging…_ * https://github.com/rust-analyzer/rust-analyzer/pull/9985 * https://github.com/rust-analyzer/rust-analyzer/pull/9987 * https://github.com/rust-analyzer/rust-analyzer/pull/9989 _For `clippy`, I don’t know if the changes should better better be moved to a PR to the original repo._ <hr> This has some overlap with #88226, but neither is a strict superset of the other. If you want multiple commits, I can split it up; in that case, make sure to suggest a criterion for splitting.
2021-08-22Auto merge of #88166 - BoxyUwU:const-equate-canon, r=lcnrbors-9/+2
canonicalize consts before calling try_unify_abstract_consts query Fixes #88022 Fixes #86953 Fixes #77708 Fixes #82034 Fixes #85031 these ICEs were all caused by calling the `try_unify_abstract_consts` query with inference vars in substs r? `@lcnr`
2021-08-22Fix typos “a”→“an”Frank Steffahn-10/+10
2021-08-22Auto merge of #88139 - lcnr:marker-trait-attr, r=nikomatsakisbors-3/+10
marker_traits: require `EvaluatedToOk` during winnowing closes #84955, while it doesn't really fix it in a way that makes me happy it should prevent the issue for now and this test can't be reproduced anyways, so it doesn't make much sense to keep it open. fixes #84917 as only one of the impls depends on regions, so we now drop the ambiguous one instead of the correct one. cc https://rust-lang.zulipchat.com/#narrow/stream/144729-wg-traits/topic/winnowing.20soundly/near/247899832 r? `@nikomatsakis`
2021-08-21Auto merge of #88135 - crlf0710:trait_upcasting_part_3, r=nikomatsakisbors-101/+205
Trait upcasting coercion (part 3) By using separate candidates for each possible choice, this fixes type-checking issues in previous commits. r? `@nikomatsakis`
2021-08-21Auto merge of #88149 - Mark-Simulacrum:prep-never-type, r=jackh726bors-0/+56
Refactor fallback code to prepare for never type This PR contains cherry-picks of some of `@nikomatsakis's` work from #79366, and shouldn't (AFAICT) represent any change in behavior. However, the refactoring is good regardless of the never type work being landed, and will reduce the size of those eventual PR(s) (and rebase pain). I am not personally an expert on this code, and the commits are essentially 100% `@nikomatsakis's,` but they do seem reasonable to me by my understanding. Happy to edit with review, of course. Commits are best reviewed in sequence rather than all together. r? `@jackh726` perhaps?
2021-08-20Require a box expression's type to be SizedAnton Golov-0/+3
2021-08-19introduce a Coerce predicateNiko Matsakis-0/+56
2021-08-19move code to `InferCtxt` methodEllen-16/+2
2021-08-19canonicalize const equate predicatesEllen-9/+16
2021-08-20Add assertion to ensure the query doesn't get called before type infererence ↵Charles Lew-2/+2
is done.
2021-08-18Auto merge of #86700 - lqd:matthews-nll-hrtb-errors, r=nikomatsakisbors-30/+38
Matthew's work on improving NLL's "higher-ranked subtype error"s This PR rebases `@matthewjasper's` [branch](https://github.com/matthewjasper/rust/tree/nll-hrtb-errors) which has great work to fix the obscure higher-ranked subtype errors that are tracked in #57374. These are a blocker to turning full NLLs on, and doing some internal cleanups to remove some of the old region code. The goal is so `@nikomatsakis` can take a look at this early, and I'll then do my best to help do the changes and followup work to land this work, and move closer to turning off the migration mode. I've only updated the branch and made it compile, removed a warning or two. r? `@nikomatsakis` (Here's the [zulip topic to discuss this](https://rust-lang.zulipchat.com/#narrow/stream/122657-t-compiler.2Fwg-nll/topic/.2357374.3A.20improving.20higher-ranked.20subtype.20errors.20via.20.2386700) that Niko wanted)