mirror of
https://github.com/golang/go
synced 2024-11-23 22:40:04 -07:00
cb0e98b833
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>
16 lines
404 B
Go
16 lines
404 B
Go
// errorcheck
|
|
|
|
// Copyright 2015 The Go Authors. All rights reserved.
|
|
// Use of this source code is governed by a BSD-style
|
|
// license that can be found in the LICENSE file.
|
|
|
|
// Issue 11362: prints empty canonical import path
|
|
|
|
package main
|
|
|
|
import _ "unicode//utf8" // ERROR "non-canonical import path .unicode//utf8. \(should be .unicode/utf8.\)" "can't find import: .unicode//utf8."
|
|
|
|
func main() {
|
|
}
|
|
|