Skip to content

Commit

Permalink
Do not crash when encountering double semi-colon after package statement
Browse files Browse the repository at this point in the history
MOE_MIGRATED_REVID=240588095
  • Loading branch information
TimvdLippe authored and cushon committed Apr 3, 2019
1 parent 9b0f032 commit 5e114ca
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -347,6 +347,7 @@ public Void visitCompilationUnit(CompilationUnitTree node, Void unused) {
builder.forcedBreak();
first = false;
}
dropEmptyDeclarations();
if (!node.getImports().isEmpty()) {
if (!first) {
builder.blankLineWanted(BlankLineWanted.YES);
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
package foo;;

import com.google.second.Foo;
import com.google.first.Bar;

public class Blim {}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
package foo;
;
import com.google.second.Foo;
import com.google.first.Bar;

public class Blim {}

0 comments on commit 5e114ca

Please sign in to comment.