aboutsummaryrefslogtreecommitdiff
path: root/test/assign.go
diff options
context:
space:
mode:
authorRobert Griesemer <gri@golang.org>2020-12-14 11:53:55 -0800
committerRobert Griesemer <gri@golang.org>2020-12-14 12:13:36 -0800
commit91803a2df334ddfc9377ef4d07cc5f0eff51b6a2 (patch)
tree277500790211cdab0ee3f12e1833efa44495afbc /test/assign.go
parenta20021227e987a24d3dbac5118a9dee4d90a96ff (diff)
parent89f38323faa57d3f7475016f778be69fcffbe9fb (diff)
downloadgo-91803a2df334ddfc9377ef4d07cc5f0eff51b6a2.tar.gz
go-91803a2df334ddfc9377ef4d07cc5f0eff51b6a2.zip
[dev.typeparams] merge: merge branch 'dev.regabi' into 'dev.typeparams'
The following files had merge conflicts and were merged manually: src/cmd/compile/fmtmap_test.go src/cmd/compile/internal/gc/noder.go src/go/parser/error_test.go test/assign.go test/chan/perm.go test/fixedbugs/issue22822.go test/fixedbugs/issue4458.go test/init.go test/interface/explicit.go test/map1.go test/method2.go The following files had manual changes to make tests pass: test/run.go test/used.go src/cmd/compile/internal/types2/stdlib_test.go Change-Id: Ia495aaaa80ce321ee4ec2a9105780fbe913dbd4c
Diffstat (limited to 'test/assign.go')
-rw-r--r--test/assign.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/assign.go b/test/assign.go
index 549f42eb80..bdec58b710 100644
--- a/test/assign.go
+++ b/test/assign.go
@@ -42,7 +42,7 @@ func main() {
_ = x
}
{
- x := sync.Mutex{key: 0} // ERROR "(unknown|assignment).*Mutex|unknown field.* in struct literal"
+ x := sync.Mutex{key: 0} // ERROR "(unknown|assignment).*Mutex"
_ = x
}
{
@@ -56,13 +56,13 @@ func main() {
{
var x = 1
{
- x, x := 2, 3 // ERROR "x repeated on left side of :=|x redeclared in this block"
+ x, x := 2, 3 // ERROR ".*x.* repeated on left side of :=|x redeclared in this block"
_ = x
}
_ = x
}
{
- a, a := 1, 2 // ERROR "a repeated on left side of :=|a redeclared in this block"
+ a, a := 1, 2 // ERROR ".*a.* repeated on left side of :=|a redeclared in this block"
_ = a
}
}