]> Cypherpunks repositories - gostls13.git/commit
cmd/compile: fix some C to Go translation leftovers
authorDidier Spezia <didier.06@gmail.com>
Wed, 7 Oct 2015 22:25:25 +0000 (22:25 +0000)
committerMinux Ma <minux@golang.org>
Thu, 8 Oct 2015 01:51:24 +0000 (01:51 +0000)
commitcb0e98b833fc2a5a346912ae725854d96ac79f78
treefab7ee463c97ed876b2fbb86a75a8a1a4e3013f5
parenta5cb76243af54a6729f5668317fb87baa242b9cc
cmd/compile: fix some C to Go translation leftovers

Following the C to Go translation, some useless variables
were left in the code. In fmt.go, this was harmless.
In lex.go, it broke the error message related to
non-canonical import paths.

Fix it, and remove the useless variables.

The added test case is ignored in the go/types tests, since
the behavior of the non-canonical import path check seems
to be different.

Fixes #11362

Change-Id: Ic9129139ede90357dc79ebf167af638cf44536fa
Reviewed-on: https://go-review.googlesource.com/15580
Reviewed-by: Marvin Stenger <marvin.stenger94@gmail.com>
Reviewed-by: Minux Ma <minux@golang.org>
Run-TryBot: Minux Ma <minux@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
src/cmd/compile/internal/gc/fmt.go
src/cmd/compile/internal/gc/lex.go
src/go/types/stdlib_test.go
test/fixedbugs/issue11362.go [new file with mode: 0644]