KT-222 Grammar Docu of objectLiteral slightly wrong

#KT-222 Fixed
This commit is contained in:
Andrey Breslav
2012-03-28 16:48:31 +04:00
parent 32e1018ace
commit 7714f84dd8
3 changed files with 7 additions and 6 deletions
@@ -1859,7 +1859,10 @@ public class JetExpressionParsing extends AbstractJetParsing {
parseExpression();
argument.done(VALUE_ARGUMENT);
}
/*
* "object" (":" delegationSpecifier{","})? classBody // Cannot make class body optional: foo(object : F, A)
*/
public void parseObjectLiteral() {
PsiBuilder.Marker literal = mark();
PsiBuilder.Marker declaration = mark();
@@ -1552,7 +1552,7 @@ public class JetParsing extends AbstractJetParsing {
/*
* functionType
* : (type ".")? "(" (parameter | modifiers type){","} ")" "->" type?
* : (type ".")? "(" (parameter | modifiers type){","}? ")" "->" type?
* ;
*/
private void parseFunctionType() {
@@ -1560,9 +1560,7 @@ public class JetParsing extends AbstractJetParsing {
}
private PsiBuilder.Marker parseFunctionTypeContents() {
// assert _at(LPAR) : tt();
if (!_at(LPAR))
System.out.println(myBuilder.getTokenText());
assert _at(LPAR) : tt();
PsiBuilder.Marker functionType = mark();
// advance(); // LPAR
+1 -1
View File
@@ -266,7 +266,7 @@ arrayAccess
;
objectLiteral
: "object" ":" delegationSpecifier{","}? classBody // Cannot make class body optional: foo(object : F, A)
: "object" (":" delegationSpecifier{","})? classBody // Cannot make class body optional: foo(object : F, A)
;
/* Factory methods: