| Age | Commit message (Collapse) | Author | Lines |
|
print argument name in arg mismatch if possible
A bit more contextual than just `/* value */`, at least when the argument is named something related to its context.
The UI test cases are... not super convincing, but also they're minimized tests.
|
|
Add a test for #103095
closes #103095
|
|
Add tests for #41731
Closes #41731
|
|
|
|
|
|
Migrate rustc_mir_build diagnostics
Rebases https://github.com/rust-lang/rust/pull/100854
~~The remaining issue is how to better resolve https://github.com/rust-lang/rust/commit/72bea68af4ee2a41c44998916f6a789163f12e7d~~
~~The diagnostic macros seems to generate a broken diagnostic, and I couldn't figure out how to manually format the fluent message, so I hardcoded the format string for now. I'd like pointers to a better fix for this.~~
Also, I'm not 100% sure I didn't mess up a rebase somewhere 🙂
r? `@davidtwco`
|
|
|
|
docs: add long error explanation for error E0320
Continuation of #105791
r? ``@GuillaumeGomez``
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Don't copy symbols from dylibs with `-Zdylib-lto`
When `rustc_driver` started being built with `-Zdylib-lto -Clto=thin`, some libstd symbols were copied by the LTO process into the dylib. That causes duplicate local symbols that are not present otherwise.
Depending on the situation (lib loading order apparently), the duplicated symbols could cause issues: `rustc_driver` overrode the panic hook, but it didn't apply to rustc main's hook (the default from libstd). This is the cause of #105637, in some situations the panic hook installed by `rustc_driver` isn't executed, and only libstd's backtrace is shown (and a double panic). The query stack, as well as the various notes to open a GH about the ICE, don't appear.
It's not clear exactly what is needed to trigger the issue, but I have simulated a reproducer [here](https://github.com/lqd/issue-105637) with cargo involved, the incorrect panic hook is executed on my machine. It is hard to reproduce in a unit test: `cargo run` + `rustup` involves LD_LIBRARY_PATH, which is not the case for `compiletest`. cargo also adds unconditional flags that are then overridden in [`bootstrap` when building rustc with `rust.lto = thin`](https://github.com/rust-lang/rust/blob/9c07efe84f28a44f3044237696acc295aa407ee5/src/bootstrap/compile.rs#L702-L714) as done on CI).
All this to say the compilation and execution environment in `bootstrap` leading to the bug building `rustc_driver` is different from our UI tests, and I believe one of the reasons it's hard to make an exact reproducer test. Thankfully there's _still_ a difference in the behavior though: although in the unit test the correct panic hook seems to be executed compared to my repro and the current nightly, only the fix removes the double panic here.
The `7e8277aefa12f1469fb1df01418ff5846a7854a9` `try` build:
- fixes the reproducer repo linked above
- restores the ICE messages from https://github.com/rust-lang/rust/issues/105321 back to the state in its OP compared to the description in https://github.com/rust-lang/rust/issues/105637
- restores the ICE message and the query stack from https://github.com/rust-lang/rust/issues/105777 compared to nightly
While I believe this technically fixes the P-critical issue https://github.com/rust-lang/rust/issues/105637, I would not want to close it yet as we may want to backport to beta/stable (if a point release happens, it would fix the ICEs reported on 1.66.0, which is built with ThinLTO on linux). Once this PR lands, I'll also open another PR to re-enable ThinLTO on x64 darwin's dist builder.
|
|
Check AArch64 branch-protection earlier in the pipeline.
As suggested in #93516.
r? `@nagisa`
|
|
Add regression test for #55976
Closes #55976
r? `@compiler-errors`
Signed-off-by: Yuki Okushi <jtitor@2k36.org>
|
|
Rollup of 6 pull requests
Successful merges:
- #105493 (Help rust-analyzer normalize query return types)
- #105710 (Don't bug if we're trying to cast `dyn*` to another type)
- #105711 (bail in `collect_trait_impl_trait_tys` if signatures reference errors)
- #105768 (Detect inherent associated types not having CamelCase)
- #105780 (rustdoc: Don't add "Read more" link if there is no extra content)
- #105802 (Make enum-match.rs test robust against variable name changes)
Failed merges:
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
Detect inherent associated types not having CamelCase
Fixes #105341.
|
|
bail in `collect_trait_impl_trait_tys` if signatures reference errors
Fixes #105290
|
|
Don't bug if we're trying to cast `dyn*` to another type
Fixes #105097
|
|
Stabilize default_alloc_error_handler
Tracking issue: #66741
This turns `feature(default_alloc_error_handler)` on by default, which causes the compiler to automatically generate a default OOM handler which panics if `#[alloc_error_handler]` is not provided.
The FCP completed over 2 years ago but the stabilization was blocked due to an issue with unwinding. This was fixed by #88098 so stabilization can be unblocked.
Closes #66741
|
|
|
|
|
|
Rollup of 8 pull requests
Successful merges:
- #105725 (Allow `impl ~const Trait` opaque types)
- #105744 (Rewrite `E0158` error-code docs for clarity)
- #105747 (Fix ICE calling method on auto trait)
- #105748 (doc: Fix a few small issues)
- #105756 (rustdoc: simplify CSS for codeblock tooltips)
- #105757 (rustdoc: remove unused CSS `.sub-settings`)
- #105764 (rustdoc: name the source page sidebar-toggle `#src-sidebar-toggle`)
- #105774 (Remove unused stderr files)
Failed merges:
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
Fixes #105341.
|
|
|
|
Remove unused stderr files
|
|
r=compiler-errors
Fix ICE calling method on auto trait
Fixes #105732
r? `@compiler-errors`
|
|
Allow `impl ~const Trait` opaque types
|
|
Use non-ascribed type as field's type in mir
Fixes https://github.com/rust-lang/rust/issues/96514
r? `@lcnr`
|
|
|
|
Use impl's def id when calculating type to specify in UFCS
Fixes #104327
Fixes #104328
Also addresses https://github.com/rust-lang/rust/pull/102670#discussion_r987381197
|
|
|
|
Tweak output for bare `dyn Trait` in arguments
Fix #35825.
|
|
Don't create dummy if val has escaping bounds var
Skips creating/pushing obligations if val has escaping bounds vars.
Fixes #105689
|
|
Suggest constraining type parameter with `Clone`
Fix #34896.
|
|
Point at method chains on `E0271` errors
Follow up to #105332. Fix #33941. CC #9082.
r? `@oli-obk`
|
|
Do not say "Type changed to X here" when the only difference is caused
by lifetimes.
|
|
|
|
When `with_forced_trimmed_paths` is used, only print filename and start
of the closure's span, to reduce their verbosity.
|
|
|
|
|
|
|
|
Fix #34896.
|
|
always check alignment during CTFE
We originally disabled alignment checks because they got in the way -- there are some things we do with the interpreter during CTFE which does not correspond to actually running user-written code, but is purely administrative, and we didn't want alignment checks there, so we just disabled them entirely. But with `-Zextra-const-ub-checks` we anyway had to figure out how to disable those alignment checks while doing checks in regular code. So now it is easy to enable CTFE alignment checking by default. Let's see what the perf consequences of that are.
r? `@oli-obk`
|
|
|
|
|
|
|
|
|