Added test and fix for the case if there is a semicolon between import statements.

This commit is contained in:
Ryszard Wiśniewski 2014-08-10 02:06:26 +02:00 committed by Roman Ivanov
parent 615c6f26cd
commit a4e79cf45c
2 changed files with 10 additions and 0 deletions

View File

@ -215,6 +215,7 @@ packageDefinition
importDefinition
options {defaultErrorHandler = true;}
: i:"import"^ {#i.setType(IMPORT);} ( "static" {#i.setType(STATIC_IMPORT);} )? identifierStar SEMI
| SEMI
;
// A type definition in a file is either a class, interface, enum of annotation definition

View File

@ -0,0 +1,9 @@
package com.puppycrawl.tools.checkstyle.grammars;
import java.util.Arrays;
;
import java.util.ArrayList;
public class SemicolonBetweenImports
{
}