rustc claims that "array lengths can't depend on generic parameters" for exactly one type of expression, while various other far more complex expressions involving const generics work perfectly #63249
Labels
A-const-generics
Area: const generics (parameters and arguments)
A-lazy-normalization
Area: Lazy normalization (tracking issue: #60471)
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Uh oh!
There was an error while loading. Please reload this page.
Quite simply:
The fact that this playground link gives an error (which is literally the only syntactic way I'm aware of to get that error), while on the other hand I was able to write this fully-working-exactly-as-written crate that depends heavily on the error message in question being simply untrue, seems.... weird to me.
I don't intend to come off as abrasive or anything. Really my point here is that const generics actually work great! Really great! As it stands I rarely encounter any problems with them. Which makes me think this overly-specific error message that only surfaces with one exact (very simple) way you can use const generics is some kind of overlooked leftover from earlier development.
Of course I might be wrong, and absolutely disregard this issue if that's the case!
The text was updated successfully, but these errors were encountered: