about summary refs log tree commit diff
path: root/compiler/rustc_traits
AgeCommit message (Collapse)AuthorLines
2025-01-29Auto merge of #136011 - compiler-errors:query-norm-vaniquishes-us, r=jackh726bors-2/+6
Revert #135914: Remove usages of `QueryNormalizer` in the compiler Reverts #135914. r? jackh726
2025-01-25Pass spans to perform_locally_in_new_solverMichael Goulet-4/+7
2025-01-24Revert "Rollup merge of #135914 - compiler-errors:vanquish-query-norm, ↵Michael Goulet-2/+6
r=jackh726" This reverts commit 556d901c36511560e0ae8ce3058507121a2fb2f0, reversing changes made to be15391703babf217aaef3c854213a7fcd70e00b.
2025-01-23Remove query normalize from normalize type opMichael Goulet-6/+2
2024-11-23Delay a bug when encountering an impl with unconstrained generics in ↵Michael Goulet-6/+15
codegen_select
2024-11-18use `TypingEnv` when no `infcx` is availablelcnr-11/+12
the behavior of the type system not only depends on the current assumptions, but also the currentnphase of the compiler. This is mostly necessary as we need to decide whether and how to reveal opaque types. We track this via the `TypingMode`.
2024-10-29TypingMode :thinking:lcnr-4/+4
2024-10-24Implement const effect predicate in new solverMichael Goulet-0/+1
2024-10-17move `defining_opaque_types` out of `Canonical`lcnr-7/+7
2024-10-17`DropckOutlives` to `rustc_middle`lcnr-2/+2
2024-10-17`ImpliedOutlivesBounds` to `rustc_middle`lcnr-5/+6
2024-10-12Swap Vec<PredicateObligation> to type aliasGnomedDev-2/+3
2024-09-25Compiler: Rename "object safe" to "dyn compatible"León Orell Valerian Liehr-1/+1
2024-09-22Reformat using the new identifier sorting from rustfmtMichael Goulet-5/+5
2024-09-03Add `warn(unreachable_pub)` to `rustc_traits`.Nicholas Nethercote-1/+2
2024-08-14Remove redundant type opsMichael Goulet-24/+0
2024-07-29Reformat `use` declarations.Nicholas Nethercote-10/+7
The previous commit updated `rustfmt.toml` appropriately. This commit is the outcome of running `x fmt --all` with the new formatting options.
2024-07-21Move all error reporting into rustc_trait_selectionMichael Goulet-2/+2
2024-07-09Split out overflow handling into its own moduleMichael Goulet-2/+2
2024-07-08Move trait selection error reporting to its own top-level moduleMichael Goulet-2/+2
2024-06-12Use `tidy` to sort crate attributes for all compiler crates.Nicholas Nethercote-0/+2
We already do this for a number of crates, e.g. `rustc_middle`, `rustc_span`, `rustc_metadata`, `rustc_span`, `rustc_errors`. For the ones we don't, in many cases the attributes are a mess. - There is no consistency about order of attribute kinds (e.g. `allow`/`deny`/`feature`). - Within attribute kind groups (e.g. the `feature` attributes), sometimes the order is alphabetical, and sometimes there is no particular order. - Sometimes the attributes of a particular kind aren't even grouped all together, e.g. there might be a `feature`, then an `allow`, then another `feature`. This commit extends the existing sorting to all compiler crates, increasing consistency. If any new attribute line is added there is now only one place it can go -- no need for arbitrary decisions. Exceptions: - `rustc_log`, `rustc_next_trait_solver` and `rustc_type_ir_macros`, because they have no crate attributes. - `rustc_codegen_gcc`, because it's quasi-external to rustc (e.g. it's ignored in `rustfmt.toml`).
2024-06-03Align Term methods with GenericArg methodsMichael Goulet-1/+1
2024-06-03Add cycle errors to ScrubbedTraitError to remove a couple more calls to ↵Michael Goulet-26/+17
new_with_diagnostics
2024-06-03Move FulfillmentErrorCode to rustc_trait_selection tooMichael Goulet-2/+2
2024-06-03Opt-in diagnostics reporting to avoid doing extra work in the new solverMichael Goulet-13/+21
2024-05-13split out AliasTy -> AliasTermMichael Goulet-8/+2
2024-05-10Apply nits, make some bounds into supertraits on inherent traitsMichael Goulet-1/+1
2024-05-10Lift `Lift`Michael Goulet-1/+1
2024-05-02Use ObligationCtxt in favor of TraitEngine in many placesMichael Goulet-7/+6
2024-04-30Remove `extern crate tracing` from numerous crates.Nicholas Nethercote-3/+5
2024-04-29Remove `extern crate rustc_middle` from numerous crates.Nicholas Nethercote-2/+2
2024-03-07Merge `check_mod_impl_wf` and `check_mod_type_wf`Oli Scherer-1/+8
2024-02-20Rename some normalization-related itemsLeón Orell Valerian Liehr-16/+17
2024-02-19`normalize_projection_ty` is not used with next-solverlcnr-14/+13
2024-02-12Dejargnonize substShoyu Vanilla-1/+1
2024-02-06Invert diagnostic lints.Nicholas Nethercote-2/+0
That is, change `diagnostic_outside_of_impl` and `untranslatable_diagnostic` from `allow` to `deny`, because more than half of the compiler has be converted to use translated diagnostics. This commit removes more `deny` attributes than it adds `allow` attributes, which proves that this change is warranted.
2024-01-25Remove unused featuresclubby789-1/+0
2024-01-17Correctly handle normalization in implied boundsAli MJ Al-Nasrawy-1/+17
Special-case Bevy dependents to not error
2024-01-12Remove redundant Code from FulfillmentErrorCode variantsMichael Goulet-2/+2
2023-12-07add unused `NormalizesTo` predicatelcnr-0/+1
2023-11-22Auto merge of #118120 - compiler-errors:closure-kind, r=lcnrbors-1/+0
Remove `PredicateKind::ClosureKind` We don't need the `ClosureKind` predicate kind -- instead, `Fn`-family trait goals are left as ambiguous, and we only need to make progress on `FnOnce` projection goals for inference purposes. This is similar to how we do confirmation of `Fn`-family trait and projection goals in the new trait solver, which also doesn't use the `ClosureKind` predicate. Some hacky logic is added in the second commit so that we can keep the error messages the same.
2023-11-21Fix `clippy::needless_borrow` in the compilerNilstrieb-1/+1
`x clippy compiler -Aclippy::all -Wclippy::needless_borrow --fix`. Then I had to remove a few unnecessary parens and muts that were exposed now.
2023-11-21Remove ClosureKind predicate kindMichael Goulet-1/+0
2023-11-13Remove `-Zperf-stats`.Nicholas Nethercote-9/+0
The included measurements have varied over the years. At one point there were quite a few more, but #49558 deleted a lot that were no longer used. Today there's just four, and it's a motley collection that doesn't seem particularly valuable. I think it has been well and truly subsumed by self-profiling, which collects way more data.
2023-11-03Auto merge of #117507 - nnethercote:rustc_span, r=Nilstriebbors-1/+1
`rustc_span` cleanups Just some things I found while looking over this crate. r? `@oli-obk`
2023-11-02dropck_outlives check generator witness needs_droplcnr-1/+2
2023-11-02Minimize `pub` usage in `source_map.rs`.Nicholas Nethercote-1/+1
Most notably, this commit changes the `pub use crate::*;` in that file to `use crate::*;`. This requires a lot of `use` items in other crates to be adjusted, because everything defined within `rustc_span::*` was also available via `rustc_span::source_map::*`, which is bizarre. The commit also removes `SourceMap::span_to_relative_line_string`, which is unused.
2023-10-30Clean up `rustc_*/Cargo.toml`.Nicholas Nethercote-3/+5
- Sort dependencies and features sections. - Add `tidy` markers to the sorted sections so they stay sorted. - Remove empty `[lib`] sections. - Remove "See more keys..." comments. Excluded files: - rustc_codegen_{cranelift,gcc}, because they're external. - rustc_lexer, because it has external use. - stable_mir, because it has external use.
2023-09-13Detect cycle errors hidden by opaques during monomorphizationMichael Goulet-1/+25
2023-09-01remove some unused crate depsklensy-3/+0