-
Notifications
You must be signed in to change notification settings - Fork 28
#1401. [Patterns] Object pattern tests #1602
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
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.
This one is heavy! ;-)
Anyway, I added a few comments about apparent issues.
The most interesting one is the one which is described in dart-lang/language#2698 in the section "'Wrapped in a unary pattern' to broad?".
The point is that we can't have any primaryPatterns
when the feature spec says that we can wrap a variable pattern in a unary pattern, in spite of the fact that unaryPattern
derives primaryPattern
.
But I think the only adjustment that makes sense is to eliminate primaryPattern
(so we can wrap a variable pattern in any unaryPattern
which isn't a primary pattern).
Let's assume that, and expect errors when that rule is violated (especially: when there is a parenthesized pattern like case Square(: (size s)):
).
If somebody really insists on interpreting this in a different way then we'll have the discussion, and we need to have that anyway.
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.
This one is heavy! ;-)
I know! :) Thank you! Let's finish with it before holidays :) Please review once again
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.
LGTM!
2022-12-20 [email protected] dart-lang/co19#1401. [Patterns] Object pattern tests (dart-lang/co19#1602) 2022-12-20 [email protected] Fixes dart-lang/co19#1539. Rename "views" experimental flag to "inline-class" (dart-lang/co19#1596) 2022-12-20 49699333+dependabot[bot]@users.noreply.github.com Bump actions/checkout from 3.1.0 to 3.2.0 (dart-lang/co19#1607) 2022-12-20 49699333+dependabot[bot]@users.noreply.github.com Bump actions/setup-java from 3.8.0 to 3.9.0 (dart-lang/co19#1608) 2022-12-19 [email protected] dart-lang/co19#1604. Update errors expectations for metadata parsing (dart-lang/co19#1605) 2022-12-19 [email protected] Fixes dart-lang/co19#1601. Expect compile-time error for elementAt() invocation on not a constant (dart-lang/co19#1603) 2022-12-16 [email protected] dart-lang/co19#1599. Expect TypeError in place of NullThrownError in co19 tests (dart-lang/co19#1600) Change-Id: I490806d7116f66dc294921561bdec350039e44f7 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/276901 Reviewed-by: Alexander Thomas <[email protected]>
No description provided.