From: Matthew Dempsky Date: Sat, 20 Feb 2016 02:39:25 +0000 (-0800) Subject: cmd/compile: change two pushedio.bin tests to use importpkg instead X-Git-Tag: go1.7beta1~1817 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=4e6e8e8c582bcd7d74378be31f070eecf0f1d5e4;p=gostls13.git cmd/compile: change two pushedio.bin tests to use importpkg instead pushedio.bin and importpkg are both non-nil iff we're parsing an package's export data, so "pushedio.bin == nil" and "importpkg == nil" are equivalent tests. Change-Id: I571ee908fef867117ef72c5da1eb24fe9b3fd12d Reviewed-on: https://go-review.googlesource.com/19751 Reviewed-by: Robert Griesemer --- diff --git a/src/cmd/compile/internal/gc/lex.go b/src/cmd/compile/internal/gc/lex.go index 57b2959de6..ae201a7d97 100644 --- a/src/cmd/compile/internal/gc/lex.go +++ b/src/cmd/compile/internal/gc/lex.go @@ -1936,7 +1936,7 @@ check: fallthrough case '\n': - if pushedio.bin == nil { + if importpkg == nil { lexlineno++ } } @@ -1948,7 +1948,7 @@ check: func ungetc(c int) { curio.peekc1 = curio.peekc curio.peekc = c - if c == '\n' && pushedio.bin == nil { + if c == '\n' && importpkg == nil { lexlineno-- } }