summaryrefslogtreecommitdiff
path: root/gcc/go
diff options
context:
space:
mode:
authorian <ian@138bc75d-0d04-0410-961f-82ee72b054a4>2014-07-08 20:49:38 +0000
committerian <ian@138bc75d-0d04-0410-961f-82ee72b054a4>2014-07-08 20:49:38 +0000
commit3d983dbf6100edc7807dd339c92c827eeea672d5 (patch)
treece859a4e15455a3a034abdcbfc540daea36a3753 /gcc/go
parenta485453ac17516d74a4fb3dfc29b04408cbfd4cb (diff)
downloadgcc-3d983dbf6100edc7807dd339c92c827eeea672d5.tar.gz
PR go/61746
compiler: Fix C-style comment parsing. The compiler was incorrectly seeing /*/ as a complete C-style comment. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@212370 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/go')
-rw-r--r--gcc/go/gofrontend/lex.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/go/gofrontend/lex.cc b/gcc/go/gofrontend/lex.cc
index 16169634733..3404cedb5f6 100644
--- a/gcc/go/gofrontend/lex.cc
+++ b/gcc/go/gofrontend/lex.cc
@@ -598,7 +598,7 @@ Lex::next_token()
}
else if (p[1] == '*')
{
- this->lineoff_ = p - this->linebuf_;
+ this->lineoff_ = p + 2 - this->linebuf_;
Location location = this->location();
if (!this->skip_c_comment())
return Token::make_invalid_token(location);