-
Notifications
You must be signed in to change notification settings - Fork 40
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
Avoid syntax errors. #3496
base: master
Are you sure you want to change the base?
Avoid syntax errors. #3496
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I find the old way with {}
much more clear, and it has never been a concern to me that annotations are defined using a style which only reminds of – but isn't exactly – Modelica.
We already have the big discrepancy that there is no built-in record called Documentation
, and that's not a problem.
I see two better-looking alternatives to fill("foo", 0)
:
- General use of
{}
rather thanfill("foo", 0)
when defining annotations with defaults. - General rule that array annotations always default to being empty. (Corresponding to suggestion in Define more annotations as declarations #3448 (comment).)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nothing really changed since my previous review. More discussion is needed to sort this out.
Since we now define that an array defaults to being empty we can handle it by just removing the default. |
Avoid the use of
{}
that isn't described in the grammar.