@@ -138,13 +138,13 @@ syntax ImportDeclaration = importDeclaration: SingleTypeImportDeclaration
138
138
| StaticImportOnDemandDeclaration // import static br.unb.rascal.Foo.*;
139
139
;
140
140
141
- syntax SingleTypeImportDeclaration = "import" TypeName ";" ;
141
+ syntax SingleTypeImportDeclaration = "import" TypeName ";" + ;
142
142
143
- syntax TypeImportOnDemandDeclaration = "import" PackageOrTypeName "." "*" ";" ;
143
+ syntax TypeImportOnDemandDeclaration = "import" PackageOrTypeName "." "*" ";" + ;
144
144
145
- syntax SingleStaticImportDeclaration = "import" "static" TypeName "." Identifier ";" ;
145
+ syntax SingleStaticImportDeclaration = "import" "static" TypeName "." Identifier ";" + ;
146
146
147
- syntax StaticImportOnDemandDeclaration = "import" "static" TypeName "." "*" ";" ;
147
+ syntax StaticImportOnDemandDeclaration = "import" "static" TypeName "." "*" ";" + ;
148
148
149
149
150
150
syntax TypeDeclaration = ClassDeclaration ";" *
@@ -173,7 +173,7 @@ syntax Superclass = "extends" ClassType ;
173
173
174
174
syntax Superinterfaces = "implements" {InterfaceType "," }+ ;
175
175
176
- syntax ClassBody = classBody : "{" ClassBodyDeclaration* decls "}" ;
176
+ syntax ClassBody = classBody : "{" ClassBodyDeclaration* decls "}" ";" ? ;
177
177
178
178
syntax ClassBodyDeclaration = ClassMemberDeclaration
179
179
| InstanceInitializer
@@ -239,7 +239,7 @@ syntax UnannArrayType = UnannPrimitiveType Dims
239
239
// |UnannTypeVariable Dims
240
240
;
241
241
242
- syntax MethodDeclaration = methodDeclaration: MethodModifier* MethodHeader MethodBody ";" ? ;
242
+ syntax MethodDeclaration = methodDeclaration: MethodModifier* MethodHeader MethodBody ;
243
243
244
244
syntax MethodModifier = Annotation
245
245
| "public"
@@ -320,27 +320,28 @@ syntax ExceptionType = ClassType
320
320
;
321
321
322
322
323
- syntax MethodBody = Block
323
+ syntax MethodBody = Block ";" *
324
324
| ";"
325
325
;
326
326
327
327
syntax InstanceInitializer = Block ;
328
328
329
- syntax StaticInitializer = "static" Block ;
329
+ syntax StaticInitializer = "static" Block ";" * ;
330
330
331
331
syntax ConstructorDeclaration = ConstructorModifier* ConstructorDeclarator Throws? ConstructorBody ;
332
332
333
333
syntax ConstructorModifier = Annotation
334
334
| "public"
335
335
| "protected"
336
336
| "private"
337
+ | "strictfp"
337
338
;
338
339
339
340
syntax ConstructorDeclarator = TypeParameters? SimpleTypeName "(" FormalParameterList? ")" ;
340
341
341
342
syntax SimpleTypeName = Identifier ;
342
343
343
- syntax ConstructorBody = "{" ExplicitConstructorInvocation? BlockStatements? "}" ;
344
+ syntax ConstructorBody = "{" ExplicitConstructorInvocation? BlockStatements? "}" ";" * ;
344
345
345
346
syntax ExplicitConstructorInvocation = TypeArguments? "this" "(" ArgumentList? ")" ";"
346
347
| TypeArguments? "super" "(" ArgumentList? ")" ";"
@@ -412,6 +413,7 @@ syntax AnnotationTypeMemberDeclaration = AnnotationTypeElementDeclaration
412
413
| ConstantDeclaration
413
414
| ClassDeclaration
414
415
| InterfaceDeclaration
416
+ // | InterfaceMemberDeclaration
415
417
// | ";"
416
418
;
417
419
@@ -460,7 +462,7 @@ syntax VariableInitializerList = { VariableInitializer "," }+ ;
460
462
* Productions from §14 (Blocks and Statements)
461
463
*/
462
464
463
- syntax Block = "{" BlockStatements? "}" ;
465
+ syntax Block = "{" BlockStatements? "}" ;
464
466
465
467
466
468
syntax BlockStatements = BlockStatement BlockStatement* ;
0 commit comments