Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Keyword default für Standardwerte bei Custom Annotations #26

Open
NiklasHargarter opened this issue Jun 2, 2023 · 0 comments
Open

Comments

@NiklasHargarter
Copy link

Das Keyword default wird verwendet, um einen Standardwert zu setzen, wenn eine Annotation deklariert wird.
Using Default Values

Im Parser muss nach dem Keyword default eine assignExp folgen.
assignExp = try switchExp <|> try methodRef <|> try lambdaExp <|> try assignment <|> condExp

Laut Javaspecification wird default gefolgt von einem ElementValue.
DefaultValue:
default ElementValue
ElementValue:
ConditionalExpression
ElementValueArrayInitializer
Annotation

In IntelliJ gibt es den Hinweis "Attribute value must be constant"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant