Skip to content

mGCA: remove parser special case for literals #152246

@BoxyUwU

Description

@BoxyUwU

Currently in the parser when parsing 1 as a const argument we special case it to an anon const instead of a directly represented arg. This was because we didn't have support for literals outside of anon consts. We now have some very basic support for this in order for struct expressions to work with literals as field initialisers.

Once #152139 and #152001 have landed I expect our support for directly represented literals to be "good enough" that we can just rip out this special case and always represent literals as hir::ConstArgKind::Literal under mGCA.

Metadata

Metadata

Assignees

Labels

A-const-genericsArea: const generics (parameters and arguments)F-min_generic_const_args`#![feature(min_generic_const_args)]`S-blockedStatus: Blocked on something else such as an RFC or other implementation work.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.T-typesRelevant to the types team, which will review and decide on the PR/issue.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions