rustdoc: "Unexpected predicate" when using const_generics. #74882
Labels
A-const-generics
Area: const generics (parameters and arguments)
A-traits
Area: Trait system
C-bug
Category: This is a bug.
F-const_generics
`#![feature(const_generics)]`
I-ICE
Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
requires-nightly
This issue requires a nightly compiler in some way.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Code
When running
cargo doc
within a library containing a struct holding theHasher
from theblake3
crate:It results in
rustdoc
crashing withUnexpected predicate Foo ConstEquate(Const { ty: usize, val: Unevaluated(WithOptConstParam { did: DefId(15:602 ~ blake3[dd2c]::Hasher[0]::cv_stack[0]::{{constant}}[0]), const_param_did: None }, [], None) }, Const { ty: usize, val: Value(Scalar(0x0000000000000037)) })
.The full library code (including Cargo.toml and Cargo.lock)
The behaviour is only triggered when the "Hasher" struct is encapsulated in another struct, nor does it occur if
const_generics
is not enabled. Theblake3
crate does not make use of const generics.Meta
I am running the recent nightly toolchain:
rustc --version --verbose
:Error output
The text was updated successfully, but these errors were encountered: