-
Notifications
You must be signed in to change notification settings - Fork 53
Closed
Description
The bodies of extension types seem to be handled gracefully, but the declaration isn't handled fully. They also support a limited version of the in-discussion primary constructor support.
Language docs: https://dart.dev/language/extension-types
Feature specification: https://github.com/dart-lang/language/blob/main/accepted/3.3/extension-types/feature-specification.md
Grammar:
<extensionTypeDeclaration> ::=
'extension' 'type' 'const'? <typeIdentifier> <typeParameters>?
<representationDeclaration> <interfaces>?
'{'
(<metadata> <extensionTypeMemberDeclaration>)*
'}'
<representationDeclaration> ::=
('.' <identifierOrNew>)? '(' <metadata> <type> <identifier> ')'
<identifierOrNew> ::= <identifier> | 'new'
<extensionTypeMemberDeclaration> ::= <classMemberDefinition>
Copilot
Metadata
Metadata
Assignees
Labels
No labels