summaryrefslogtreecommitdiff
path: root/test/fixedbugs/issue43762.go
diff options
context:
space:
mode:
authorCuong Manh Le <cuong.manhle.vn@gmail.com>2021-01-19 22:57:45 +0700
committerCuong Manh Le <cuong.manhle.vn@gmail.com>2021-01-19 18:27:50 +0000
commit9423d50d53f132d7d00f5126144736bfe65627b6 (patch)
treee8874c98e411d76aad50f856db88bdef52b5bb8a /test/fixedbugs/issue43762.go
parenta2f825c542bc62b9d4341080302ed309cd3daa97 (diff)
downloadgo-git-9423d50d53f132d7d00f5126144736bfe65627b6.tar.gz
[dev.regabi] cmd/compile: use '%q' for printing rune values less than 128
Fixes #43762 Change-Id: I51734c9b4ee2366a5dae53b2d27b363f4d5fe6c1 Reviewed-on: https://go-review.googlesource.com/c/go/+/284592 Trust: Cuong Manh Le <cuong.manhle.vn@gmail.com> Run-TryBot: Cuong Manh Le <cuong.manhle.vn@gmail.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Matthew Dempsky <mdempsky@google.com>
Diffstat (limited to 'test/fixedbugs/issue43762.go')
-rw-r--r--test/fixedbugs/issue43762.go11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/fixedbugs/issue43762.go b/test/fixedbugs/issue43762.go
new file mode 100644
index 0000000000..4544b6e496
--- /dev/null
+++ b/test/fixedbugs/issue43762.go
@@ -0,0 +1,11 @@
+// errorcheck
+
+// Copyright 2021 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
+
+var _ = true == '\\' // ERROR "invalid operation: true == '\\\\'"
+var _ = true == '\'' // ERROR "invalid operation: true == '\\''"
+var _ = true == '\n' // ERROR "invalid operation: true == '\\n'"