Removed tuples from grammar.
This commit is contained in:
@@ -106,7 +106,6 @@ atomicExpression
|
||||
: "(" expression ")"
|
||||
: literalConstant
|
||||
: functionLiteral
|
||||
: tupleLiteral
|
||||
: "this" label?
|
||||
: "super" ("<" type ">")? label?
|
||||
: if
|
||||
@@ -242,10 +241,6 @@ jump
|
||||
// yield ?
|
||||
;
|
||||
|
||||
tupleLiteral
|
||||
: "#" "(" (((SimpleName "=")? expression){","})? ")"
|
||||
;
|
||||
|
||||
// one can use "it" as a parameter name
|
||||
functionLiteral
|
||||
: "{" statements "}"
|
||||
|
||||
@@ -9,9 +9,6 @@ bq. See [Types]
|
||||
Foo<Bar<X>, T, Object> // user type
|
||||
(A, Object) -> Foo // function type
|
||||
() -> Foo // function with no arguments
|
||||
#(A, B, C) // tuple type
|
||||
#(a : A, b : B) // tuple type with named entries
|
||||
#() // 0-ary tuple type (Unit)
|
||||
|
||||
*/
|
||||
|
||||
@@ -24,7 +21,6 @@ typeDescriptor
|
||||
: selfType
|
||||
: functionType
|
||||
: userType
|
||||
: tupleType
|
||||
: nullableType
|
||||
;
|
||||
|
||||
@@ -51,9 +47,4 @@ functionType
|
||||
: (type ".")? "(" (parameter | modifiers /*lazy out ref*/ type){","} ")" "->" type?
|
||||
;
|
||||
|
||||
tupleType
|
||||
: "#" "(" type{","}? ")"
|
||||
: "#" "(" parameter{","} ")" // tuple with named entries, the names do not affect assignment compatibility
|
||||
;
|
||||
|
||||
////////////////////////////////////////
|
||||
Reference in New Issue
Block a user