Debian Codegraph @

src/cmd/compile/internal/inline/inlheur/pstate_string.go

raw
1 // Copyright 2023 The Go Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style
3 // license that can be found in the LICENSE file.
4
5 // Code generated by "stringer -type pstate"; DO NOT EDIT.
6
7 package inlheur
8
9 import "strconv"
10
11 func _() {
12 // An "invalid array index" compiler error signifies that the constant values have changed.
13 // Re-run the stringer command to generate them again.
14 var x [1]struct{}
15 _ = x[psNoInfo-0]
16 _ = x[psCallsPanic-1]
17 _ = x[psMayReturn-2]
18 _ = x[psTop-3]
19 }
20
21 const _pstate_name = "psNoInfopsCallsPanicpsMayReturnpsTop"
22
23 var _pstate_index = [...]uint8{0, 8, 20, 31, 36}
24
25 func (i pstate) String() string {
26 if i < 0 || i >= pstate(len(_pstate_index)-1) {
27 return "pstate(" + strconv.FormatInt(int64(i), 10) + ")"
28 }
29 return _pstate_name[_pstate_index[i]:_pstate_index[i+1]]
30 }