Remove AnonConstKind::GCA and reject generic anon consts#157773
Remove AnonConstKind::GCA and reject generic anon consts#157773LaneAsade wants to merge 1 commit into
Conversation
|
HIR ty lowering was modified cc @fmease |
|
r? @chenyukang rustbot has assigned @chenyukang. Use Why was this reviewer chosen?The reviewer was selected based on:
|
1b770b3 to
dfcf839
Compare
|
This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers. |
|
I had to open a new PR as the other one closed for some reason and I am not able to reopen it. Sorry 😭 |
1b1b90e to
4b1a86f
Compare
|
r? BoxyUwU |
|
dont worry about needing to open the second PR 😅 what happened is github doesn't let you re-open closed PRs if they've been pushed to since closing :3 |
4b1a86f to
71523aa
Compare
Previously, a
GCAtype 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 #155341.With this PR,
GCAvariant is removed fromAnonConstKindso that generic anon consts are rejected.Related: rust-lang/project-const-generics#113