-
-
Notifications
You must be signed in to change notification settings - Fork 933
Closed
Labels
A-astArea - ASTArea - ASTC-cleanupCategory - technical debt or refactoring. Solution not expected to change behaviorCategory - technical debt or refactoring. Solution not expected to change behavior
Description
As discussed in #3900 (comment), it'd be preferable in my view to remove the "special case" code for BindingPattern from GetSpan codegen.
I propose instead adding a #[span] attr to the kind field, and codegen can act on that to generate:
impl<'a> GetSpan for BindingPattern<'a> {
#[inline]
fn span(&self) -> Span {
self.kind.span()
}
}We can then use that same #[span] mechanism if it's required for any other types in future.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
A-astArea - ASTArea - ASTC-cleanupCategory - technical debt or refactoring. Solution not expected to change behaviorCategory - technical debt or refactoring. Solution not expected to change behavior
Type
Fields
Give feedbackPriority
None yet