mirror of
https://github.com/allankoechke/rust.git
synced 2026-12-03 09:32:42 +00:00
Remove AnonConstKind::GCA and reject generic anon consts
Previously, a `GCA` type const (`type const FOO<const N: usize>: usize = const { N + 1 };`) was a type-system-transparent type const whose body immediately thunked out to an opaque regular const (albeit an anon const). The fact that there was a transparent wrapper wasn't providing anything of value, now that the user can write and https://github.com/rust-lang/rust/pull/155341.
With this PR, `GCA` variant is removed from `AnonConstKind` so that generic anon consts are rejected.
Related: https://github.com/rust-lang/project-const-generics/issues/113