Remove the Option part of range ends in the HIR

This commit is contained in:
Oli Scherer 2025-02-05 15:22:10 +00:00
parent 0e7b283573
commit e8f7a382be
32 changed files with 400 additions and 269 deletions

View file

@ -1173,6 +1173,8 @@ pub enum DesugaringKind {
BoundModifier,
/// Calls to contract checks (`#[requires]` to precond, `#[ensures]` to postcond)
Contract,
/// A pattern type range start/end
PatTyRange,
}
impl DesugaringKind {
@ -1190,6 +1192,7 @@ impl DesugaringKind {
DesugaringKind::WhileLoop => "`while` loop",
DesugaringKind::BoundModifier => "trait bound modifier",
DesugaringKind::Contract => "contract check",
DesugaringKind::PatTyRange => "pattern type",
}
}
}

View file

@ -308,6 +308,9 @@ symbols! {
RangeFull,
RangeInclusive,
RangeInclusiveCopy,
RangeMax,
RangeMin,
RangeSub,
RangeTo,
RangeToInclusive,
Rc,
@ -1522,6 +1525,7 @@ symbols! {
pattern_complexity_limit,
pattern_parentheses,
pattern_type,
pattern_type_range_trait,
pattern_types,
permissions_from_mode,
phantom_data,