-
Notifications
You must be signed in to change notification settings - Fork 13.4k
ICE: Failed to normalize Alias(Free, AliasTy {
#141380
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
Comments
Unknown labels: F-WithEmplacableForFn |
trait a {}
type b<c: a> = impl a;
enum d {
e(b),
}
fn f(g: d) {
match g {}
} |
also crashes on stable |
This may have been said before, but lowercasing all the identifier names doesn't really simplify the MCVE in a meaningful way, and on the contrary actually makes it harder to reason about since although capitalization in Rust is not semantic it does carry a lot of pragmatic weight. Furthermore, it anonymizes the fact that this test was originally reduced from a regression test for #127353, which is useful for whoever is responsible for fixing and filing a new test for this bug. An idea: It would be very cool to change whatever minimizer you're using to have capitalization-sensitive name reduction, or just skip sharing the "identifier reduced" version of the code at all unless the identifiers are really that misleading or complicated. |
I like it because it reduces the mvce into something like a Logical Form, different reproducers may still boil down to the same LF and this helps us spot and avoid duplicates. All the info (var names, comments etc) is still contained in the topmost report though, you could look at that, too. |
trait Trait;
type Alias<P : Trait> = impl;
enum UninhabitedVariants { Tuple(Alias) } fn uwu(x : UninhabitedVariants) {
match x {}
}
|
Bisection points to nightly-2024-06-05, but that doesn't look useful. PRs in range: - #125383 (Rewrite `emit`, `mixing-formats` and `bare-outfile` `run-make` tests in `rmake.rs` format) by Oneirical
- #122597 (Show files produced by `--emit foo` in json artifact notifications) by pacak
- #125380 (Make `WHERE_CLAUSES_OBJECT_SAFETY` a regular object safety violation) by compiler-errors
- #125525 (Make TLS accessors closures that return pointers) by joboet
- #125960 (Rollup of 8 pull requests) by jieyouxu
- #124486 (Add tracking issue and unstable book page for `"vectorcall"` ABI)
- #125504 (Change pedantically incorrect OnceCell/OnceLock wording)
- #125608 (Avoid follow-up errors if the number of generic parameters already doesn't match)
- #125690 (ARM Target Docs Update)
- #125750 (Align `Term` methods with `GenericArg` methods, add `Term::expect_*`)
- #125818 (Handle no values cfgs with `--print=check-cfg`)
- #125909 (rustdoc: add a regression test for a former blanket impl synthesis ICE)
- #125919 (Remove stray "this")
- #125948 (rustfmt more tests) by nnethercote
- #125976 (Rollup of 8 pull requests) by compiler-errors
- #125667 (Silence follow-up errors directly based on error types and regions)
- #125717 (Refactor `#[diagnostic::do_not_recommend]` support)
- #125795 (Improve renaming suggestion for names with leading underscores)
- #125865 (Fix ICE caused by ignoring EffectVars in type inference)
- #125953 (Streamline `nested` calls.)
- #125959 (Reduce `pub` exposure in `rustc_mir_build`)
- #125967 (Split smir `Const` into `TyConst` and `MirConst`)
- #125968 (Store the types of `ty::Expr` arguments in the `ty::Expr`)
- #123536 (Simplify `IntVarValue`/`FloatVarValue`) by compiler-errors
- #125426 (Update `compiler-builtins` test to not clear essential env vars) by jieyouxu
- #125989 (Rollup of 11 pull requests) by GuillaumeGomez
- #106186 (Add function `core::iter::chain`)
- #125596 (Convert `proc_macro_back_compat` lint to an unconditional error.)
- #125696 (Explain differences between `{Once,Lazy}{Cell,Lock}` types)
- #125917 (Create `run-make` `env_var` and `env_var_os` helpers)
- #125927 (Ignore `vec_deque_alloc_error::test_shrink_to_unwind` test on non-unwind targets)
- #125930 (feat(opt-dist): new flag `--benchmark-cargo-config`)
- #125932 (Fix typo in the docs of `HashMap::raw_entry_mut`)
- #125933 (Update books)
- #125944 (Update fuchsia maintainers)
- #125946 (Include trailing commas in wrapped function declarations [RustDoc])
- #125973 (Remove `tests/run-make-fulldeps/pretty-expanded`) My best guess would be #125608
in my experience, different reproducers boil down to different "LFs" regardless, and renaming the variables makes it harder to reason about whether two LFs are same or not. The current autorename algo probably doesn't help with automatic matching of LFs either since it's sensitive to item ordering. You would still generate two different LFs for struct MyStruct;
trait MyTrait {}
impl MyTrait for MyStruct{}
// becomes
struct a;
trait b{}
impl a for b{}
// vs
trait MyTrait {}
struct MyStruct;
impl MyTrait for MyStruct{}
// becomes
trait a {}
struct b;
impl b for a{} // different LF!! And if having automatic LF matching is desirable, then this sort of rename can be trivially done within said automatic LF matching code, not on github. I think having some sort of "canonical" represenation of a repro is valuable, but only as far as it helps understand the code better. I.e. using "standard" nomenclature of |
auto-reduced (treereduce-rust):
original:
Version information
Possibly related line of code:
rust/compiler/rustc_middle/src/ty/normalize_erasing_regions.rs
Lines 165 to 177 in 5df0f72
Command:
/home/matthias/.rustup/toolchains/master/bin/rustc
Program output
@rustbot label +F-WithEmplacableForFn
The text was updated successfully, but these errors were encountered: