From: Josh Bleecher Snyder Date: Thu, 16 Jun 2016 20:39:16 +0000 (-0700) Subject: test: expand switch dead code test to include a range X-Git-Tag: go1.8beta1~1710 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=1a3006b03564936326e591f191a5af0630afca85;p=gostls13.git test: expand switch dead code test to include a range Change-Id: If443ffb50b140c466dcf4cc5340f44948bfa46a9 Reviewed-on: https://go-review.googlesource.com/26765 Reviewed-by: Matthew Dempsky --- diff --git a/test/fixedbugs/issue9608.dir/issue9608.go b/test/fixedbugs/issue9608.dir/issue9608.go index 56b52cc606..ca82ded4cd 100644 --- a/test/fixedbugs/issue9608.dir/issue9608.go +++ b/test/fixedbugs/issue9608.dir/issue9608.go @@ -67,6 +67,15 @@ func init() { case true: fail() } + + // Test dead code elimination in large ranges. + switch 5 { + case 3, 4, 5, 6, 7: + case 0, 1, 2: + fail() + default: + fail() + } } func main() {