-
Notifications
You must be signed in to change notification settings - Fork 12.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Uplift TypeVisitableExt
into rustc_type_ir
#120498
Conversation
@@ -63,11 +73,13 @@ impl<'tcx> Const<'tcx> { | |||
self.0.kind | |||
} | |||
|
|||
// FIXME(compiler-errors): Think about removing this. | |||
#[inline] | |||
pub fn flags(self) -> TypeFlags { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you remove them in the same PR?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not certain that it's cleaner to remove these or not...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some callsites cannot be removed, but it's kind of ugly to have to import a trait from rustc_type_ir
.
r=me after rebase and moving bounds to the |
☔ The latest upstream changes (presumably #120980) made this pull request unmergeable. Please resolve the merge conflicts. |
3d23937
to
7e80867
Compare
also pls update description |
@bors r=lcnr |
Rollup of 13 pull requests Successful merges: - rust-lang#116387 (Additional doc links and explanation of `Wake`.) - rust-lang#118738 (Netbsd10 update) - rust-lang#118890 (Clarify the lifetimes of allocations returned by the `Allocator` trait) - rust-lang#120498 (Uplift `TypeVisitableExt` into `rustc_type_ir`) - rust-lang#120530 (Be less confident when `dyn` suggestion is not checked for object safety) - rust-lang#120915 (Fix suggestion span for `?Sized` when param type has default) - rust-lang#121015 (Optimize `delayed_bug` handling.) - rust-lang#121024 (implement `Default` for `AsciiChar`) - rust-lang#121039 (Correctly compute adjustment casts in GVN) - rust-lang#121045 (Fix two UI tests with incorrect directive / invalid revision) - rust-lang#121049 (Do not point at `#[allow(_)]` as the reason for compat lint triggering) - rust-lang#121071 (Use fewer delayed bugs.) - rust-lang#121073 (Fix typos in `OneLock` doc) r? `@ghost` `@rustbot` modify labels: rollup
Rollup merge of rust-lang#120498 - compiler-errors:type-flags, r=lcnr Uplift `TypeVisitableExt` into `rustc_type_ir` This uplifts `TypeVisitableExt` into `rustc_type_ir` so it can be used in an interner-agnostic way. It also moves some `TypeSuperVisitable` bounds onto `Interner` since we don't expect to support libraries that have types which aren't foldable by default. This restores a couple of asserts in the canonicalizer code we uplifted, and also makes it so that we can use type-flags-based helpers in the solver code, which I'm interested in uplifting. r? lcnr
This uplifts
TypeVisitableExt
intorustc_type_ir
so it can be used in an interner-agnostic way. It also moves someTypeSuperVisitable
bounds ontoInterner
since we don't expect to support libraries that have types which aren't foldable by default.This restores a couple of asserts in the canonicalizer code we uplifted, and also makes it so that we can use type-flags-based helpers in the solver code, which I'm interested in uplifting.
r? lcnr