varoptsemi:
{
- yyoptsemi('=');
+ if(yylast == LSEMIBRACE)
+ yyoptsemi('=');
}
vardcl:
cp[c1++] = c;
if(fullrune(cp, c1)) {
chartorune(&rune, cp);
- if(isfrog(rune)) {
- yyerror("illegal character 0x%ux", rune);
- goto l0;
- }
+ if(isfrog(rune)) {
+ yyerror("illegal character 0x%ux", rune);
+ goto l0;
+ }
+ // 0xb7 · is used for internal names
+ if(!isalpharune(c) && !isdigitrune(c) && c != 0xb7)
+ yyerror("invalid identifier character 0x%ux", rune);
break;
}
c = getc();
Loop:
for {
var nr, nw int;
- var er, ew os.Error
+ var er, ew os.Error;
if nr, er = req.Body.Read(buf); nr > 0 {
if er == nil || er == os.EOF {
fmt.Fprintf(w, "%x\r\n", nr);
import "fmt"
func main() {
- 日本語 := 1; // Japanese ideographs are not letters
+ 日本語 := 1; // ERROR "identifier"
}
package main
-// Multi-line string literal do not allow newline chars according to spec
-// but 6g accepts this code with the newlines interpreted as newlines.
+// Multi-line string literal now allowed.
const s = `
Hello, World!
123
BUG: should fail
-=========== bugs/bug163.go
-BUG: should not compile
-
-=========== bugs/bug164.go
-BUG: should not compile
-
-=========== bugs/bug166.go
-BUG: errchk: command succeeded unexpectedly: 6g bugs/bug166.go
-
=========== fixedbugs/bug016.go
fixedbugs/bug016.go:7: constant -3 overflows uint