aboutsummaryrefslogtreecommitdiff
path: root/test/const1.go
diff options
context:
space:
mode:
authorKen Thompson <ken@golang.org>2009-03-24 16:40:38 -0700
committerKen Thompson <ken@golang.org>2009-03-24 16:40:38 -0700
commitb8be809c10e86dcee31317d78d84710ef8b67c82 (patch)
tree5b73d4110f951999b18acebaae296da0e992fceb /test/const1.go
parent85e014a27ef0a640a33f58bc412b3fa5bcc4a800 (diff)
downloadgo-b8be809c10e86dcee31317d78d84710ef8b67c82.tar.gz
go-b8be809c10e86dcee31317d78d84710ef8b67c82.zip
^ type(const) now inverts "enough" bits
^ signed(const) becomes illegal ^ unsigned(const) becomes legal R=r OCL=26697 CL=26697
Diffstat (limited to 'test/const1.go')
-rw-r--r--test/const1.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/const1.go b/test/const1.go
index d51e5823a6..0d48ada5e2 100644
--- a/test/const1.go
+++ b/test/const1.go
@@ -39,7 +39,7 @@ var (
b3 = Uint8 - Uint8; // OK
b4 = Uint8 - Uint8 - Uint8; // ERROR "overflow"
b5 = uint8(^0); // ERROR "overflow"
- b6 = ^uint8(0); // ERROR "overflow"
+ b6 = ^uint8(0); // OK
b7 = uint8(Minus1); // ERROR "overflow"
b8 = uint8(int8(-1)); // ERROR "overflow"
b8a = uint8(-1); // ERROR "overflow"