1
0
mirror of https://github.com/golang/go synced 2024-11-18 17:54:57 -07:00

units: fix compilation

R=ken2, ken3
CC=golang-dev
https://golang.org/cl/2865041
This commit is contained in:
Rob Pike 2010-11-03 12:20:37 -07:00
parent 70d0b6b242
commit 0aa9d84b56

View File

@ -215,7 +215,7 @@ expr0:
type UnitsLex int
func (_ UnitsLex) Lex(yylval *yySymType) int {
func (UnitsLex) Lex(yylval *yySymType) int {
var c, i int
c = peekrune
@ -280,7 +280,7 @@ numb:
return VAL
}
func (_ UnitsLex) Error(s string) {
func (UnitsLex) Error(s string) {
Error("syntax error, last name: %v", sym)
}
@ -298,7 +298,7 @@ func main() {
f, err := os.Open(file, os.O_RDONLY, 0)
if err != nil {
fmt.Printf("error opening %v: %v\n", file, err)
fmt.Fprintf(os.Stderr, "error opening %v: %v\n", file, err)
os.Exit(1)
}
fi = bufio.NewReader(f)
@ -390,7 +390,7 @@ func rdigit(c int) bool {
func Error(s string, v ...interface{}) {
fmt.Printf("%v: %v\n\t", lineno, line)
fmt.Printf(s, v)
fmt.Printf(s, v...)
fmt.Printf("\n")
nerrors++