rustc 1.49.0-nightly (ffa2e7ae8 2020-10-24)
binary: rustc
commit-hash: ffa2e7ae8fbf9badc035740db949b9dae271c29f
commit-date: 2020-10-24
host: x86_64-unknown-linux-gnu
release: 1.49.0-nightly
LLVM version: 11.0
error[E0601]: `main` function not found in crate `reduced_mutant`
--> reduced_mutant.rs:1:1
|
1 | / struct S;
2 | | fn f() {
3 | | S::A::<f> {}
4 | | }
| |_^ consider adding a `main` function to `reduced_mutant.rs`
error[E0223]: ambiguous associated type
--> reduced_mutant.rs:3:5
|
3 | S::A::<f> {}
| ^^^^^^^^^ help: use fully-qualified syntax: `<S as Trait>::A`
error: internal compiler error: compiler/rustc_typeck/src/collect/type_of.rs:82:26: unexpected const parent path Expr(Expr { hir_id: HirId { owner: DefId(0:5 ~ reduced_mutant[317d]::f), local_id: 7 }, kind: Struct(TypeRelative(Ty { hir_id: HirId { owner: DefId(0:5 ~ reduced_mutant[317d]::f), local_id: 2 }, kind: Path(Resolved(None, Path { span: reduced_mutant.rs:3:5: 3:14 (#0), res: Def(Struct, DefId(0:3 ~ reduced_mutant[317d]::S)), segments: [PathSegment { ident: S#0, hir_id: Some(HirId { owner: DefId(0:5 ~ reduced_mutant[317d]::f), local_id: 1 }), res: Some(Err), args: None, infer_args: true }] })), span: reduced_mutant.rs:3:5: 3:14 (#0) }, PathSegment { ident: A#0, hir_id: Some(HirId { owner: DefId(0:5 ~ reduced_mutant[317d]::f), local_id: 6 }), res: Some(Err), args: Some(GenericArgs { args: [Const(ConstArg { value: AnonConst { hir_id: HirId { owner: DefId(0:5 ~ reduced_mutant[317d]::f), local_id: 3 }, body: BodyId { hir_id: HirId { owner: DefId(0:5 ~ reduced_mutant[317d]::f), local_id: 5 } } }, span: reduced_mutant.rs:3:12: 3:13 (#0) })], bindings: [], parenthesized: false }), infer_args: false }), [], None), attrs: ThinVec(None), span: reduced_mutant.rs:3:5: 3:17 (#0) })
thread 'rustc' panicked at 'Box<Any>', /rustc/ffa2e7ae8fbf9badc035740db949b9dae271c29f/compiler/rustc_errors/src/lib.rs:891:9
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
note: the compiler unexpectedly panicked. this is a bug.
note: we would appreciate a bug report: https://github.com/rust-lang/rust/issues/new?labels=C-bug%2C+I-ICE%2C+T-compiler&template=ice.md
note: rustc 1.49.0-nightly (ffa2e7ae8 2020-10-24) running on x86_64-unknown-linux-gnu
query stack during panic:
#0 [opt_const_param_of] computing the optional const parameter of `f::{constant#0}`
#1 [typeck] type-checking `f::{constant#0}`
end of query stack
error: aborting due to 3 previous errors
Some errors have detailed explanations: E0223, E0601.
For more information about an error, try `rustc --explain E0223`.
Code
Meta
rustc --version --verbose:Error output
Backtrace
NOTE: The bug is found by our work-in-progress compiler testing tool Kira, and the test program is reduced/minimized by Perses