Repository navigation
Tweak crate error wording and turn them into fatal errors - #165823
Conversation
|
r? @nnethercote rustbot has assigned @nnethercote. Use Why was this reviewer chosen?The reviewer was selected based on:
|
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
| // dummy. We ignore compiler-injected prelude/sysroot loads here so they don't | ||
| // suppress unrelated diagnostics, such as "unsupported targets for std library" | ||
| // etc., these maybe helpful for users to resolve crate loading failure. | ||
| // crate maybe injrected with `standard_library_imports::inject`, their span is dummy. |
There was a problem hiding this comment.
Uh, the changes here from the first commit (which were good) were undone in the second commit.
There was a problem hiding this comment.
Git rebase industrial accident 😔
|
r=me once tests are green. @rustbot author |
|
Reminder, once the PR becomes ready for a review, use |
Reduce the verbosity of compiler output by refusing to advance to later stages when a crate could not be imported.
|
This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers. |
|
@bors r+ rollup |
Tweak crate error wording and turn them into fatal errors
Reduce the verbosity of compiler output by refusing to advance to later stages when a crate could not be imported.
When crate isn't found and this rustc was invoked by cargo, mention "check the `[dependencies]` section in `Cargo.toml` for the missing crate or use `cargo add {ident}` to add it to your `Cargo.toml`".
Fix rust-lang#97685 (the case in particular in that ticket no longer happens, but this PR fixes the general case). Fix rust-lang#98318. CC rust-lang#96799. Fix rust-lang#89733.
…uwer Rollup of 12 pull requests Successful merges: - #164707 (Re-enable rustc profile generation for static linked llvm on Windows x64 builds ) - #165221 (Canonicalize more comparison operators) - #165880 (Remove dead code for returning `BackendRepr::Memory` with `PassMode::Direct`) - #164108 (Add unstable `-Zllvm-tpde` flag to `rustc_codegen_llvm`) - #165565 (view-types: lower view types from HIR) - #165771 (tests: cover MSVC ThinLTO exported symbol preservation) - #165810 (reflection: reflect attributes from adts, fields, and variants) - #165823 (Tweak crate error wording and turn them into fatal errors) - #165849 (More opt-dist improvements) - #165855 (Update `sysinfo` version to `0.40.3`) - #165861 (cg_llvm: Use an invariant lifetime brand for LLVM attributes) - #165872 (Some attribute related cleanups)
Tweak crate error wording and turn them into fatal errors
Reduce the verbosity of compiler output by refusing to advance to later stages when a crate could not be imported.
When crate isn't found and this rustc was invoked by cargo, mention "check the `[dependencies]` section in `Cargo.toml` for the missing crate or use `cargo add {ident}` to add it to your `Cargo.toml`".
Fix rust-lang#97685 (the case in particular in that ticket no longer happens, but this PR fixes the general case). Fix rust-lang#98318. CC rust-lang#96799. Fix rust-lang#89733.
Rollup of 13 pull requests Successful merges: - #164707 (Re-enable rustc profile generation for static linked llvm on Windows x64 builds ) - #165068 (Change color usage for highlights) - #165841 (Tell Miri about the alignment handling in the Windows System allocator) - #165880 (Remove dead code for returning `BackendRepr::Memory` with `PassMode::Direct`) - #164108 (Add unstable `-Zllvm-tpde` flag to `rustc_codegen_llvm`) - #165565 (view-types: lower view types from HIR) - #165622 (small cleanups in rustc_codegen_llvm) - #165771 (tests: cover MSVC ThinLTO exported symbol preservation) - #165810 (reflection: reflect attributes from adts, fields, and variants) - #165823 (Tweak crate error wording and turn them into fatal errors) - #165849 (More opt-dist improvements) - #165855 (Update `sysinfo` version to `0.40.3`) - #165872 (Some attribute related cleanups) Failed merges: - #165861 (cg_llvm: Use an invariant lifetime brand for LLVM attributes)
|
|
This pull request was unapproved. This PR was contained in a rollup (#165897), which was unapproved. |
This comment has been minimized.
This comment has been minimized.
Tweak crate error wording and turn them into fatal errors try-job: test-various
|
💔 Test for 3c036bc failed: CI. Failed job:
|
This comment has been minimized.
This comment has been minimized.
|
@bors try jobs=test-various |
This comment has been minimized.
This comment has been minimized.
Tweak crate error wording and turn them into fatal errors try-job: test-various
|
The job Click to see the possible cause of the failure (guessed by this bot) |
|
❌ Commit 9a4b54a has been unapproved due to PR CI failure. Reapprove it with |
|
PR CI flaked out. @bors r=nnethercote |
Tweak crate error wording and turn them into fatal errors
Reduce the verbosity of compiler output by refusing to advance to later stages when a crate could not be imported.
When crate isn't found and this rustc was invoked by cargo, mention "check the `[dependencies]` section in `Cargo.toml` for the missing crate or use `cargo add {ident}` to add it to your `Cargo.toml`".
Fix rust-lang#97685 (the case in particular in that ticket no longer happens, but this PR fixes the general case). Fix rust-lang#98318. CC rust-lang#96799. Fix rust-lang#89733.
…uwer Rollup of 18 pull requests Successful merges: - #164828 (When suggesting path of renamed crate, use the renamed name) - #164864 (Avoid hoisting uninitialized reads in EarlyOtherwiseBranch) - #165068 (Change color usage for highlights) - #165221 (Canonicalize more comparison operators) - #165841 (Tell Miri about the alignment handling in the Windows System allocator) - #165869 (Cleanup: Remove `path_matches` and `value_str` from `AttributeExt`) - #165880 (Remove dead code for returning `BackendRepr::Memory` with `PassMode::Direct`) - #164108 (Add unstable `-Zllvm-tpde` flag to `rustc_codegen_llvm`) - #165565 (view-types: lower view types from HIR) - #165622 (small cleanups in rustc_codegen_llvm) - #165745 (Don't ICE when a guard condition is a place of type `!`) - #165771 (tests: cover MSVC ThinLTO exported symbol preservation) - #165810 (reflection: reflect attributes from adts, fields, and variants) - #165823 (Tweak crate error wording and turn them into fatal errors) - #165849 (More opt-dist improvements) - #165855 (Update `sysinfo` version to `0.40.3`) - #165872 (Some attribute related cleanups) - #165905 (CI: Use a consistent locale when sorting docker build inputs)
…uwer Rollup of 17 pull requests Successful merges: - #164828 (When suggesting path of renamed crate, use the renamed name) - #164864 (Avoid hoisting uninitialized reads in EarlyOtherwiseBranch) - #165068 (Change color usage for highlights) - #165221 (Canonicalize more comparison operators) - #165841 (Tell Miri about the alignment handling in the Windows System allocator) - #165869 (Cleanup: Remove `path_matches` and `value_str` from `AttributeExt`) - #165880 (Remove dead code for returning `BackendRepr::Memory` with `PassMode::Direct`) - #164108 (Add unstable `-Zllvm-tpde` flag to `rustc_codegen_llvm`) - #165565 (view-types: lower view types from HIR) - #165622 (small cleanups in rustc_codegen_llvm) - #165771 (tests: cover MSVC ThinLTO exported symbol preservation) - #165810 (reflection: reflect attributes from adts, fields, and variants) - #165823 (Tweak crate error wording and turn them into fatal errors) - #165849 (More opt-dist improvements) - #165855 (Update `sysinfo` version to `0.40.3`) - #165872 (Some attribute related cleanups) - #165905 (CI: Use a consistent locale when sorting docker build inputs)
Rollup merge of #165823 - estebank:crate-errs, r=nnethercote Tweak crate error wording and turn them into fatal errors Reduce the verbosity of compiler output by refusing to advance to later stages when a crate could not be imported. When crate isn't found and this rustc was invoked by cargo, mention "check the `[dependencies]` section in `Cargo.toml` for the missing crate or use `cargo add {ident}` to add it to your `Cargo.toml`". Fix #97685 (the case in particular in that ticket no longer happens, but this PR fixes the general case). Fix #98318. CC #96799. Fix #89733.
View all comments
Reduce the verbosity of compiler output by refusing to advance to later stages when a crate could not be imported.
When crate isn't found and this rustc was invoked by cargo, mention "check the
[dependencies]section inCargo.tomlfor the missing crate or usecargo add {ident}to add it to yourCargo.toml".Fix #97685 (the case in particular in that ticket no longer happens, but this PR fixes the general case). Fix #98318. CC #96799. Fix #89733.