diff options
author | Matthew Dempsky <mdempsky@google.com> | 2016-08-16 16:33:05 -0700 |
---|---|---|
committer | Matthew Dempsky <mdempsky@google.com> | 2016-10-25 22:28:40 +0000 |
commit | adda7ad29551d0880df1805ae22401551b1fbfa8 (patch) | |
tree | 0cf1e773a78132a9d8ff266cf5863887321549b4 /test/nul1.go | |
parent | 263a825b0534a55916d472ba17feff7d1ed47569 (diff) | |
download | go-adda7ad29551d0880df1805ae22401551b1fbfa8.tar.gz go-adda7ad29551d0880df1805ae22401551b1fbfa8.zip |
cmd/compile/internal/gc: enable new parser by default
Change-Id: I3c784986755cfbbe1b8eb8da4d64227bd109a3b0
Reviewed-on: https://go-review.googlesource.com/27203
Run-TryBot: Matthew Dempsky <mdempsky@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Robert Griesemer <gri@golang.org>
Diffstat (limited to 'test/nul1.go')
-rw-r--r-- | test/nul1.go | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/test/nul1.go b/test/nul1.go index 624101b621..fbba19857b 100644 --- a/test/nul1.go +++ b/test/nul1.go @@ -1,4 +1,4 @@ -// errorcheckoutput -newparser=0 +// errorcheckoutput // Copyright 2009 The Go Authors. All rights reserved. // Use of this source code is governed by a BSD-style @@ -6,10 +6,6 @@ // Test source files and strings containing NUL and invalid UTF-8. -// TODO(mdempsky): Update error expectations for -newparser=1. The new -// lexer skips over NUL and invalid UTF-8 sequences, so they don't emit -// "illegal character" or "invalid identifier character" errors. - package main import ( @@ -40,7 +36,7 @@ var y = ` + "`in raw string \x00 foo`" + ` // ERROR "NUL" /* in other comment ` + "\x00" + ` */ // ERROR "NUL" -/* in source code */ ` + "\x00" + `// ERROR "NUL" "illegal character" +/* in source code */ ` + "\x00" + `// ERROR "NUL" var xx = "in string ` + "\xc2\xff" + `" // ERROR "UTF-8" @@ -51,9 +47,9 @@ var yy = ` + "`in raw string \xff foo`" + ` // ERROR "UTF-8" /* in other comment ` + "\xe0\x00\x00" + ` */ // ERROR "UTF-8|NUL" /* in variable name */ -var z` + "\xc1\x81" + ` int // ERROR "UTF-8" "invalid identifier character" +var z` + "\xc1\x81" + ` int // ERROR "UTF-8" -/* in source code */ ` + "var \xc2A int" + `// ERROR "UTF-8" "invalid identifier character" +/* in source code */ ` + "var \xc2A int" + `// ERROR "UTF-8" `) } |