compiler: don't advance past unexpected semicolon

We've already read the unexpected semicolon, so advancing again causes
us to skip the next token, causing future errors to be out of sync.

Change-Id: Id83776a31996dbfd4734420fd3e8b4cfcc14d2f0
Trust: Ian Lance Taylor <>
Reviewed-by: Cherry Zhang <>
Reviewed-by: Than McIntosh <>
diff --git a/go/ b/go/
index c9a5485..b062a47 100644
--- a/go/
+++ b/go/
@@ -1567,7 +1567,6 @@
 		  "unexpected semicolon or newline in type declaration");
       type = Type::make_error_type();
-      this->advance_token();
   if (type->is_error_type())