mirror of
https://github.com/golang/go
synced 2024-11-20 05:14:41 -07:00
all: fix errors found by go vet
R=golang-dev, rsc CC=golang-dev https://golang.org/cl/6125044
This commit is contained in:
parent
dde8358a1c
commit
459837c86e
@ -607,7 +607,7 @@ func printCharInfoTables() int {
|
|||||||
tccc := ccc(d[len(d)-1])
|
tccc := ccc(d[len(d)-1])
|
||||||
cc := ccc(r)
|
cc := ccc(r)
|
||||||
if cc != 0 && lccc == 0 && tccc == 0 {
|
if cc != 0 && lccc == 0 && tccc == 0 {
|
||||||
logger.Fatalf("%U: trailing and leading ccc are 0 for non-zero ccc %d", cc)
|
logger.Fatalf("%U: trailing and leading ccc are 0 for non-zero ccc %d", r, cc)
|
||||||
}
|
}
|
||||||
if tccc < lccc && lccc != 0 {
|
if tccc < lccc && lccc != 0 {
|
||||||
const msg = "%U: lccc (%d) must be <= tcc (%d)"
|
const msg = "%U: lccc (%d) must be <= tcc (%d)"
|
||||||
@ -623,7 +623,7 @@ func printCharInfoTables() int {
|
|||||||
}
|
}
|
||||||
if cc != lccc {
|
if cc != lccc {
|
||||||
if cc != 0 {
|
if cc != 0 {
|
||||||
logger.Fatalf("%U: for lccc != ccc, expected ccc to be 0; was %d", cc)
|
logger.Fatalf("%U: for lccc != ccc, expected ccc to be 0; was %d", r, cc)
|
||||||
}
|
}
|
||||||
index = 3
|
index = 3
|
||||||
}
|
}
|
||||||
|
@ -348,7 +348,7 @@ Loop:
|
|||||||
l.backup()
|
l.backup()
|
||||||
word := l.input[l.start:l.pos]
|
word := l.input[l.start:l.pos]
|
||||||
if !l.atTerminator() {
|
if !l.atTerminator() {
|
||||||
return l.errorf("bad character %+U", r)
|
return l.errorf("bad character %#U", r)
|
||||||
}
|
}
|
||||||
switch {
|
switch {
|
||||||
case key[word] > itemKeyword:
|
case key[word] > itemKeyword:
|
||||||
|
Loading…
Reference in New Issue
Block a user