-
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
compiler: Stop reexporting enum-globs from rustc_target::abi
#131424
compiler: Stop reexporting enum-globs from rustc_target::abi
#131424
Conversation
r? @chenyukang rustbot has assigned @chenyukang. Use |
Some changes occurred to the CTFE / Miri interpreter cc @rust-lang/miri Some changes occurred in compiler/rustc_codegen_cranelift cc @bjorn3 Some changes occurred in compiler/rustc_codegen_gcc These commits modify the If this was unintentional then you should revert the changes before this PR is merged. |
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.
Thank you, I have found this very confusing in the past. You can r=me after PR CI is green.
fb67968
to
43e198a
Compare
Almost forgot one. |
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.
After this, some of these types will be possible to separate out of rustc_target
, but only if we stop having absolutely everything depend on this bizarre triple-nested reexport structure.
use rustc_codegen_ssa::traits::{ | ||
BaseTypeCodegenMethods, DerivedTypeCodegenMethods, LayoutTypeCodegenMethods, | ||
}; | ||
use rustc_middle::bug; | ||
use rustc_middle::ty::layout::{LayoutOf, TyAndLayout}; | ||
use rustc_middle::ty::print::with_no_trimmed_paths; | ||
use rustc_middle::ty::{self, CoroutineArgsExt, Ty, TypeVisitableExt}; | ||
use rustc_target::abi::TyAbiInterface; |
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.
This...
@@ -18,8 +23,9 @@ use rustc_middle::ty::{ | |||
use rustc_session::{DataTypeKind, FieldInfo, FieldKind, SizeKind, VariantInfo}; | |||
use rustc_span::sym; | |||
use rustc_span::symbol::Symbol; | |||
use rustc_target::abi::*; | |||
use rustc_target::abi::{FIRST_VARIANT, FieldIdx, Layout, VariantIdx}; |
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.
...and these are the reason I bothered.
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.
Hmm, factoring these out will also be a bit of a pain. Ah well, will worry about it later.
@bors r=jieyouxu rollup |
…ob-imports, r=jieyouxu compiler: Stop reexporting enum-globs from `rustc_target::abi` Three enums had **all** their variants glob-exported into a distressingly large amount of the tree. Cease to do that, and also cease to glob import the contents of the module that contained them. Redirect relevant imports to their actual source, the `rustc_abi` crate. No functional changes.
…kingjubilee Rollup of 4 pull requests Successful merges: - rust-lang#129424 (Stabilize `Pin::as_deref_mut()`) - rust-lang#131417 (Fix methods alignment on mobile) - rust-lang#131424 (compiler: Stop reexporting enum-globs from `rustc_target::abi`) - rust-lang#131426 (Fix quotation marks around debug line in `src/ci/run.sh`) r? `@ghost` `@rustbot` modify labels: rollup
…ob-imports, r=jieyouxu compiler: Stop reexporting enum-globs from `rustc_target::abi` Three enums had **all** their variants glob-exported into a distressingly large amount of the tree. Cease to do that, and also cease to glob import the contents of the module that contained them. Redirect relevant imports to their actual source, the `rustc_abi` crate. No functional changes.
…iaskrgr Rollup of 6 pull requests Successful merges: - rust-lang#129424 (Stabilize `Pin::as_deref_mut()`) - rust-lang#131417 (Fix methods alignment on mobile) - rust-lang#131424 (compiler: Stop reexporting enum-globs from `rustc_target::abi`) - rust-lang#131426 (Fix quotation marks around debug line in `src/ci/run.sh`) - rust-lang#131429 (Rename directive `needs-profiler-support` to `needs-profiler-runtime`) - rust-lang#131435 (Ignore broken-pipe-no-ice on apple (specifically macOS) for now) r? `@ghost` `@rustbot` modify labels: rollup
…kingjubilee Rollup of 4 pull requests Successful merges: - rust-lang#129424 (Stabilize `Pin::as_deref_mut()`) - rust-lang#131417 (Fix methods alignment on mobile) - rust-lang#131424 (compiler: Stop reexporting enum-globs from `rustc_target::abi`) - rust-lang#131426 (Fix quotation marks around debug line in `src/ci/run.sh`) r? `@ghost` `@rustbot` modify labels: rollup
…ob-imports, r=jieyouxu compiler: Stop reexporting enum-globs from `rustc_target::abi` Three enums had **all** their variants glob-exported into a distressingly large amount of the tree. Cease to do that, and also cease to glob import the contents of the module that contained them. Redirect relevant imports to their actual source, the `rustc_abi` crate. No functional changes.
Rollup of 6 pull requests Successful merges: - rust-lang#131417 (Fix methods alignment on mobile) - rust-lang#131420 (Dont ICE when encountering post-mono layout cycle error) - rust-lang#131424 (compiler: Stop reexporting enum-globs from `rustc_target::abi`) - rust-lang#131426 (Fix quotation marks around debug line in `src/ci/run.sh`) - rust-lang#131429 (Rename directive `needs-profiler-support` to `needs-profiler-runtime`) - rust-lang#131435 (Ignore broken-pipe-no-ice on apple (specifically macOS) for now) r? `@ghost` `@rustbot` modify labels: rollup
…iaskrgr Rollup of 7 pull requests Successful merges: - rust-lang#131382 (Add "reference" as a known compiletest header) - rust-lang#131420 (Dont ICE when encountering post-mono layout cycle error) - rust-lang#131424 (compiler: Stop reexporting enum-globs from `rustc_target::abi`) - rust-lang#131426 (Fix quotation marks around debug line in `src/ci/run.sh`) - rust-lang#131435 (Ignore broken-pipe-no-ice on apple (specifically macOS) for now) - rust-lang#131447 (add more crash tests) - rust-lang#131456 (Fix typo in E0793) r? `@ghost` `@rustbot` modify labels: rollup
…iaskrgr Rollup of 7 pull requests Successful merges: - rust-lang#131382 (Add "reference" as a known compiletest header) - rust-lang#131420 (Dont ICE when encountering post-mono layout cycle error) - rust-lang#131424 (compiler: Stop reexporting enum-globs from `rustc_target::abi`) - rust-lang#131426 (Fix quotation marks around debug line in `src/ci/run.sh`) - rust-lang#131435 (Ignore broken-pipe-no-ice on apple (specifically macOS) for now) - rust-lang#131447 (add more crash tests) - rust-lang#131456 (Fix typo in E0793) r? `@ghost` `@rustbot` modify labels: rollup
Rollup merge of rust-lang#131424 - workingjubilee:stem-the-tyde-of-glob-imports, r=jieyouxu compiler: Stop reexporting enum-globs from `rustc_target::abi` Three enums had **all** their variants glob-exported into a distressingly large amount of the tree. Cease to do that, and also cease to glob import the contents of the module that contained them. Redirect relevant imports to their actual source, the `rustc_abi` crate. No functional changes.
Three enums had all their variants glob-exported into a distressingly large amount of the tree. Cease to do that, and also cease to glob import the contents of the module that contained them. Redirect relevant imports to their actual source, the
rustc_abi
crate.No functional changes.