cuelang.org/go@v0.13.0/cue/token/relpos_string.go (about) 1 // Code generated by "stringer -type=RelPos -linecomment"; DO NOT EDIT. 2 3 package token 4 5 import "strconv" 6 7 func _() { 8 // An "invalid array index" compiler error signifies that the constant values have changed. 9 // Re-run the stringer command to generate them again. 10 var x [1]struct{} 11 _ = x[NoRelPos-0] 12 _ = x[Elided-1] 13 _ = x[NoSpace-2] 14 _ = x[Blank-3] 15 _ = x[Newline-4] 16 _ = x[NewSection-5] 17 } 18 19 const _RelPos_name = "invalidelidednospaceblanknewlinesection" 20 21 var _RelPos_index = [...]uint8{0, 7, 13, 20, 25, 32, 39} 22 23 func (i RelPos) String() string { 24 if i < 0 || i >= RelPos(len(_RelPos_index)-1) { 25 return "RelPos(" + strconv.FormatInt(int64(i), 10) + ")" 26 } 27 return _RelPos_name[_RelPos_index[i]:_RelPos_index[i+1]] 28 }