Debian Codegraph @

test/fixedbugs/issue29562.go

raw
1 // compile
2
3 // Copyright 2019 The Go Authors. All rights reserved.
4 // Use of this source code is governed by a BSD-style
5 // license that can be found in the LICENSE file.
6
7 // Triggers a double walk of the (inlined) switch in il
8
9 package p
10
11 func il(s string) string {
12 switch len(s) {
13 case 0:
14 return "zero"
15 case 1:
16 return "one"
17 }
18 return s
19 }
20
21 func f() {
22 var s string
23 var as []string
24 switch false && (s+"a"+as[0]+il(s)+as[0]+s == "") {
25 }
26 }