diff options
Diffstat (limited to 'src/cmd/compile/internal/types2/testdata/fixedbugs/issue52401.go')
-rw-r--r-- | src/cmd/compile/internal/types2/testdata/fixedbugs/issue52401.go | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/cmd/compile/internal/types2/testdata/fixedbugs/issue52401.go b/src/cmd/compile/internal/types2/testdata/fixedbugs/issue52401.go new file mode 100644 index 00000000000..c7efd8c7180 --- /dev/null +++ b/src/cmd/compile/internal/types2/testdata/fixedbugs/issue52401.go @@ -0,0 +1,11 @@ +// Copyright 2022 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package p + +func _() { + const x = 0 + x /* ERROR cannot assign to x */ += 1 + x /* ERROR cannot assign to x */ ++ +} |