php-parser/pkg/token/position_string.go

97 lines
2.9 KiB
Go
Raw Normal View History

// Code generated by "stringer -type=Position -output ./position_string.go"; DO NOT EDIT.
2020-05-12 21:16:36 +00:00
package token
import "strconv"
2020-03-09 09:58:18 +00:00
func _() {
// An "invalid array index" compiler error signifies that the constant values have changed.
// Re-run the stringer command to generate them again.
var x [1]struct{}
_ = x[Start-0]
_ = x[End-1]
_ = x[SemiColon-2]
_ = x[AltEnd-3]
_ = x[Dollar-4]
_ = x[Ampersand-5]
_ = x[Name-6]
_ = x[Prefix-7]
_ = x[Key-8]
_ = x[Var-9]
_ = x[UseType-10]
_ = x[ReturnType-11]
_ = x[OptionalType-12]
_ = x[CaseSeparator-13]
_ = x[LexicalVars-14]
_ = x[Params-15]
_ = x[Ref-16]
_ = x[Cast-17]
_ = x[Expr-18]
_ = x[InitExpr-19]
_ = x[CondExpr-20]
_ = x[IncExpr-21]
_ = x[True-22]
_ = x[Cond-23]
_ = x[HaltCompiller-24]
_ = x[Namespace-25]
_ = x[Static-26]
_ = x[Class-27]
_ = x[Use-28]
_ = x[While-29]
_ = x[For-30]
_ = x[Switch-31]
_ = x[Break-32]
_ = x[Foreach-33]
_ = x[Declare-34]
_ = x[Label-35]
_ = x[Finally-36]
_ = x[List-37]
_ = x[Default-38]
_ = x[If-39]
_ = x[ElseIf-40]
_ = x[Else-41]
_ = x[Variadic-42]
_ = x[Function-43]
_ = x[DoubleArrow-44]
_ = x[Alias-45]
_ = x[As-46]
_ = x[Equal-47]
_ = x[Exit-48]
_ = x[Array-49]
_ = x[Isset-50]
_ = x[Empty-51]
_ = x[Eval-52]
_ = x[Echo-53]
_ = x[Try-54]
_ = x[Catch-55]
_ = x[Unset-56]
_ = x[Stmts-57]
_ = x[VarList-58]
_ = x[ConstList-59]
_ = x[NameList-60]
_ = x[ParamList-61]
_ = x[ModifierList-62]
_ = x[ArrayPairList-63]
_ = x[CaseListStart-64]
_ = x[CaseListEnd-65]
_ = x[ArgumentList-66]
_ = x[PropertyList-67]
_ = x[ParameterList-68]
_ = x[AdaptationList-69]
_ = x[LexicalVarList-70]
_ = x[UseDeclarationList-71]
_ = x[OpenParenthesisToken-72]
_ = x[CloseParenthesisToken-73]
2020-03-09 09:58:18 +00:00
}
const _Position_name = "StartEndSemiColonAltEndDollarAmpersandNamePrefixKeyVarUseTypeReturnTypeOptionalTypeCaseSeparatorLexicalVarsParamsRefCastExprInitExprCondExprIncExprTrueCondHaltCompillerNamespaceStaticClassUseWhileForSwitchBreakForeachDeclareLabelFinallyListDefaultIfElseIfElseVariadicFunctionDoubleArrowAliasAsEqualExitArrayIssetEmptyEvalEchoTryCatchUnsetStmtsVarListConstListNameListParamListModifierListArrayPairListCaseListStartCaseListEndArgumentListPropertyListParameterListAdaptationListLexicalVarListUseDeclarationListOpenParenthesisTokenCloseParenthesisToken"
var _Position_index = [...]uint16{0, 5, 8, 17, 23, 29, 38, 42, 48, 51, 54, 61, 71, 83, 96, 107, 113, 116, 120, 124, 132, 140, 147, 151, 155, 168, 177, 183, 188, 191, 196, 199, 205, 210, 217, 224, 229, 236, 240, 247, 249, 255, 259, 267, 275, 286, 291, 293, 298, 302, 307, 312, 317, 321, 325, 328, 333, 338, 343, 350, 359, 367, 376, 388, 401, 414, 425, 437, 449, 462, 476, 490, 508, 528, 549}
func (i Position) String() string {
if i < 0 || i >= Position(len(_Position_index)-1) {
return "Position(" + strconv.FormatInt(int64(i), 10) + ")"
}
return _Position_name[_Position_index[i]:_Position_index[i+1]]
}