-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Use p* for vararg splices #11240
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
Use p* for vararg splices #11240
Changes from 6 commits
217e8dc
34afeee
2f461f8
cb47074
f78be3d
9416640
ac51c11
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
|
@@ -252,7 +252,7 @@ ExprsInParens ::= ExprInParens {‘,’ ExprInParens} | |||||
ExprInParens ::= PostfixExpr ‘:’ Type -- normal Expr allows only RefinedType here | ||||||
| Expr | ||||||
ParArgumentExprs ::= ‘(’ [‘using’] ExprsInParens ‘)’ exprs | ||||||
| ‘(’ [ExprsInParens ‘,’] PostfixExpr ‘:’ ‘_’ ‘*’ ‘)’ exprs :+ Typed(expr, Ident(wildcardStar)) | ||||||
| ‘(’ [ExprsInParens ‘,’] PostfixExpr ‘*’ ‘)’ exprs :+ Typed(expr, Ident(wildcardStar)) | ||||||
ArgumentExprs ::= ParArgumentExprs | ||||||
| BlockExpr | ||||||
BlockExpr ::= <<< (CaseClauses | Block) >>> | ||||||
|
@@ -297,7 +297,7 @@ PatVar ::= varid | |||||
| ‘_’ | ||||||
Patterns ::= Pattern {‘,’ Pattern} | ||||||
ArgumentPatterns ::= ‘(’ [Patterns] ‘)’ Apply(fn, pats) | ||||||
| ‘(’ [Patterns ‘,’] Pattern2 ‘:’ ‘_’ ‘*’ ‘)’ | ||||||
| ‘(’ [Patterns ‘,’] Pattern2 ‘*’ ‘)’ | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This syntax deviates from Scala 2. I think it would be good to change it to:
Suggested change
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think that's orthogonal to this PR. I am not sure about that. It's the same as for other ascriptions in patterns. I think they are useful to have. |
||||||
``` | ||||||
|
||||||
### Type and Value Parameters | ||||||
|
This file was deleted.
Uh oh!
There was an error while loading. Please reload this page.