1// compile
2
3// Copyright 2023 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
7package j
8
9func f(try func() int, shouldInc func() bool, N func(int) int) {
10	var n int
11loop: // we want to have 3 preds here, the function entry and both gotos
12	if v := try(); v == 42 || v == 1337 { // the two || are to trick findIndVar
13		if n < 30 { // this aims to be the matched block
14			if shouldInc() {
15				n++
16				goto loop
17			}
18			n = N(n) // try to prevent some block joining
19			goto loop
20		}
21	}
22}
23