gc: more accurate error description

R=ken2
CC=golang-dev
https://golang.org/cl/1284041
This commit is contained in:
Russ Cox 2010-05-24 17:07:51 -07:00
parent 566f598046
commit ea941f09bf
3 changed files with 4 additions and 4 deletions

View file

@ -45,10 +45,10 @@ static struct {
"var declaration not allowed in for initializer",
% loadsys package imports LVAR LNAME '[' ']' LNAME '{'
"var declaration missing = before initial value",
"unexpected { at end of statement",
% loadsys package imports LFUNC LNAME '(' ')' '{' LVAR LNAME '[' ']' LNAME '{'
"var declaration missing = before initial value",
"unexpected { at end of statement",
% loadsys package imports LFUNC LNAME '(' ')' '{' LDEFER LNAME ';'
"argument to go/defer must be function call",

View file

@ -7,4 +7,4 @@
package main
func main() {
var x map[string]string{"a":"b"} // ERROR "var declaration missing ="
var x map[string]string{"a":"b"} // ERROR "unexpected { at end of statement"

View file

@ -6,5 +6,5 @@
package main
var x map[string]string{"a":"b"} // ERROR "var declaration missing ="
var x map[string]string{"a":"b"} // ERROR "unexpected { at end of statement"