2013-07-11 09:38:44 -07:00
|
|
|
//line parser.y:15
|
2014-10-14 08:21:39 -07:00
|
|
|
package rules
|
|
|
|
|
2013-06-06 06:12:37 -07:00
|
|
|
import __yyfmt__ "fmt"
|
2014-10-14 08:21:39 -07:00
|
|
|
|
2013-06-06 06:12:37 -07:00
|
|
|
//line parser.y:15
|
2014-10-14 08:21:39 -07:00
|
|
|
import (
|
|
|
|
clientmodel "github.com/prometheus/client_golang/model"
|
2013-01-07 14:24:26 -08:00
|
|
|
|
2014-10-14 08:21:39 -07:00
|
|
|
"github.com/prometheus/prometheus/rules/ast"
|
|
|
|
"github.com/prometheus/prometheus/storage/metric"
|
|
|
|
)
|
2013-07-11 09:38:44 -07:00
|
|
|
|
2014-03-28 03:58:47 -07:00
|
|
|
//line parser.y:25
|
2013-01-07 14:24:26 -08:00
|
|
|
type yySymType struct {
|
2014-10-14 08:21:39 -07:00
|
|
|
yys int
|
|
|
|
num clientmodel.SampleValue
|
|
|
|
str string
|
|
|
|
ruleNode ast.Node
|
|
|
|
ruleNodeSlice []ast.Node
|
|
|
|
boolean bool
|
|
|
|
labelNameSlice clientmodel.LabelNames
|
|
|
|
labelSet clientmodel.LabelSet
|
|
|
|
labelMatcher *metric.LabelMatcher
|
|
|
|
labelMatchers metric.LabelMatchers
|
2015-03-03 01:58:28 -08:00
|
|
|
vectorMatching *vectorMatching
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
|
2013-01-10 16:17:37 -08:00
|
|
|
const START_RULES = 57346
|
|
|
|
const START_EXPRESSION = 57347
|
|
|
|
const IDENTIFIER = 57348
|
|
|
|
const STRING = 57349
|
2013-01-21 16:51:26 -08:00
|
|
|
const DURATION = 57350
|
2014-03-21 05:11:01 -07:00
|
|
|
const METRICNAME = 57351
|
|
|
|
const NUMBER = 57352
|
|
|
|
const PERMANENT = 57353
|
|
|
|
const GROUP_OP = 57354
|
|
|
|
const KEEPING_EXTRA = 57355
|
2015-02-17 17:30:41 -08:00
|
|
|
const OFFSET = 57356
|
2015-03-03 01:58:28 -08:00
|
|
|
const MATCH_OP = 57357
|
|
|
|
const AGGR_OP = 57358
|
|
|
|
const CMP_OP = 57359
|
|
|
|
const ADDITIVE_OP = 57360
|
|
|
|
const MULT_OP = 57361
|
|
|
|
const MATCH_MOD = 57362
|
|
|
|
const ALERT = 57363
|
|
|
|
const IF = 57364
|
|
|
|
const FOR = 57365
|
|
|
|
const WITH = 57366
|
|
|
|
const SUMMARY = 57367
|
|
|
|
const DESCRIPTION = 57368
|
2013-01-07 14:24:26 -08:00
|
|
|
|
|
|
|
var yyToknames = []string{
|
2013-01-10 16:17:37 -08:00
|
|
|
"START_RULES",
|
|
|
|
"START_EXPRESSION",
|
2013-01-07 14:24:26 -08:00
|
|
|
"IDENTIFIER",
|
|
|
|
"STRING",
|
2013-01-21 16:51:26 -08:00
|
|
|
"DURATION",
|
2014-03-21 05:11:01 -07:00
|
|
|
"METRICNAME",
|
2013-01-07 14:24:26 -08:00
|
|
|
"NUMBER",
|
|
|
|
"PERMANENT",
|
|
|
|
"GROUP_OP",
|
2013-12-13 10:20:42 -08:00
|
|
|
"KEEPING_EXTRA",
|
2015-02-17 17:30:41 -08:00
|
|
|
"OFFSET",
|
2015-03-03 01:58:28 -08:00
|
|
|
"MATCH_OP",
|
2013-01-07 14:24:26 -08:00
|
|
|
"AGGR_OP",
|
|
|
|
"CMP_OP",
|
|
|
|
"ADDITIVE_OP",
|
|
|
|
"MULT_OP",
|
2015-03-03 01:58:28 -08:00
|
|
|
"MATCH_MOD",
|
2013-04-22 15:26:59 -07:00
|
|
|
"ALERT",
|
|
|
|
"IF",
|
|
|
|
"FOR",
|
|
|
|
"WITH",
|
2013-07-30 08:18:07 -07:00
|
|
|
"SUMMARY",
|
|
|
|
"DESCRIPTION",
|
2014-12-24 16:28:35 -08:00
|
|
|
"'='",
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
var yyStatenames = []string{}
|
|
|
|
|
|
|
|
const yyEofCode = 1
|
|
|
|
const yyErrCode = 2
|
|
|
|
const yyMaxDepth = 200
|
|
|
|
|
2015-03-03 03:16:46 -08:00
|
|
|
//line parser.y:281
|
2013-01-07 14:24:26 -08:00
|
|
|
|
|
|
|
//line yacctab:1
|
|
|
|
var yyExca = []int{
|
|
|
|
-1, 1,
|
|
|
|
1, -1,
|
2013-01-10 16:17:37 -08:00
|
|
|
-2, 0,
|
|
|
|
-1, 4,
|
2014-03-21 05:11:01 -07:00
|
|
|
1, 1,
|
|
|
|
-2, 10,
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
|
2015-03-03 03:16:46 -08:00
|
|
|
const yyNprod = 56
|
2013-01-07 14:24:26 -08:00
|
|
|
const yyPrivate = 57344
|
|
|
|
|
|
|
|
var yyTokenNames []string
|
|
|
|
var yyStates []string
|
|
|
|
|
2015-03-03 03:16:46 -08:00
|
|
|
const yyLast = 159
|
2013-01-07 14:24:26 -08:00
|
|
|
|
|
|
|
var yyAct = []int{
|
|
|
|
|
2015-03-03 03:16:46 -08:00
|
|
|
78, 61, 83, 58, 55, 54, 31, 48, 6, 25,
|
|
|
|
20, 21, 23, 21, 10, 56, 64, 14, 12, 10,
|
|
|
|
56, 19, 14, 12, 11, 19, 13, 19, 92, 11,
|
|
|
|
113, 13, 22, 20, 21, 57, 8, 32, 109, 7,
|
|
|
|
53, 8, 77, 65, 7, 67, 68, 101, 19, 22,
|
|
|
|
20, 21, 70, 69, 10, 98, 30, 14, 12, 22,
|
|
|
|
20, 21, 94, 95, 11, 19, 13, 87, 85, 92,
|
|
|
|
96, 99, 86, 84, 76, 19, 8, 66, 60, 7,
|
|
|
|
29, 88, 90, 89, 24, 93, 22, 20, 21, 22,
|
|
|
|
20, 21, 92, 100, 91, 75, 82, 74, 103, 73,
|
|
|
|
43, 42, 19, 44, 43, 19, 26, 108, 62, 47,
|
|
|
|
111, 28, 80, 51, 114, 110, 38, 105, 63, 46,
|
|
|
|
18, 107, 39, 9, 49, 59, 32, 33, 35, 50,
|
|
|
|
17, 14, 106, 72, 37, 115, 112, 104, 40, 41,
|
|
|
|
34, 71, 79, 84, 102, 26, 36, 2, 3, 15,
|
|
|
|
5, 4, 1, 45, 97, 16, 27, 81, 52,
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
var yyPact = []int{
|
|
|
|
|
2015-03-03 03:16:46 -08:00
|
|
|
143, -1000, -1000, 48, 109, -1000, 72, 48, 139, 83,
|
|
|
|
49, 25, -1000, 117, -1000, -1000, 122, 140, -1000, 126,
|
|
|
|
107, 107, 107, 69, 74, -1000, 92, 110, 100, 8,
|
|
|
|
48, 112, 47, -1000, 80, -1000, 96, -18, 48, 46,
|
|
|
|
48, 48, -1000, 139, 110, 134, -1000, -1000, -1000, 125,
|
|
|
|
-1000, 70, 65, -1000, -1000, 72, -1000, 42, 11, -1000,
|
|
|
|
136, 85, 67, 48, 110, -6, 136, -12, -8, -1000,
|
|
|
|
-1000, -1000, -1000, -1000, -1000, 13, 114, 48, 62, -1000,
|
|
|
|
48, 33, -1000, -1000, 43, 32, -1000, 39, -1000, 112,
|
|
|
|
15, -1000, 138, 72, -1000, 137, 130, 93, 124, 101,
|
|
|
|
-1000, -1000, -1000, -1000, -1000, 80, -1000, 7, 90, 136,
|
|
|
|
129, -2, 88, -1000, 128, -1000,
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
var yyPgo = []int{
|
|
|
|
|
2015-03-03 03:16:46 -08:00
|
|
|
0, 158, 0, 6, 2, 157, 1, 9, 84, 156,
|
|
|
|
116, 4, 5, 155, 3, 154, 123, 153, 7, 152,
|
|
|
|
151, 150, 149,
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
var yyR1 = []int{
|
|
|
|
|
2015-03-03 01:58:28 -08:00
|
|
|
0, 19, 19, 20, 20, 21, 22, 22, 15, 15,
|
|
|
|
13, 13, 16, 16, 6, 6, 6, 5, 5, 4,
|
|
|
|
9, 9, 9, 8, 8, 7, 17, 17, 18, 18,
|
|
|
|
11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
|
2015-03-03 03:16:46 -08:00
|
|
|
11, 11, 11, 14, 14, 10, 10, 10, 3, 3,
|
|
|
|
2, 2, 1, 1, 12, 12,
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
var yyR2 = []int{
|
|
|
|
|
2013-07-30 08:18:07 -07:00
|
|
|
0, 2, 2, 0, 2, 1, 5, 11, 0, 2,
|
2014-03-21 05:11:01 -07:00
|
|
|
0, 1, 1, 1, 0, 3, 2, 1, 3, 3,
|
2015-02-17 17:30:41 -08:00
|
|
|
0, 2, 3, 1, 3, 3, 1, 1, 0, 2,
|
2015-03-03 01:58:28 -08:00
|
|
|
3, 4, 3, 4, 3, 5, 6, 6, 4, 4,
|
2015-03-03 03:16:46 -08:00
|
|
|
4, 1, 2, 0, 1, 0, 4, 8, 0, 4,
|
|
|
|
1, 3, 1, 3, 1, 1,
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
var yyChk = []int{
|
|
|
|
|
2015-03-03 01:58:28 -08:00
|
|
|
-1000, -19, 4, 5, -20, -21, -11, 31, 28, -16,
|
2015-03-03 03:16:46 -08:00
|
|
|
6, 16, 10, 18, 9, -22, -13, 21, 11, 33,
|
|
|
|
18, 19, 17, -11, -8, -7, 6, -9, 28, 31,
|
|
|
|
31, -3, 12, 10, -16, 6, 6, 8, -10, 15,
|
|
|
|
-10, -10, 32, 30, 29, -17, 27, 17, -18, 14,
|
|
|
|
29, -8, -1, 32, -12, -11, 7, -11, -14, 13,
|
|
|
|
31, -6, 28, 22, 34, -11, 31, -11, -11, -7,
|
|
|
|
-18, 7, 8, 29, 32, 30, 32, 31, -2, 6,
|
|
|
|
27, -5, 29, -4, 6, -11, -18, -2, -12, -3,
|
|
|
|
-11, 32, 30, -11, 29, 30, 27, -15, 23, 32,
|
|
|
|
-14, 32, 6, -4, 7, 24, 8, 20, -6, 31,
|
|
|
|
25, -2, 7, 32, 26, 7,
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
var yyDef = []int{
|
|
|
|
|
2014-10-14 08:21:39 -07:00
|
|
|
0, -2, 3, 0, -2, 2, 5, 0, 0, 20,
|
2015-03-03 03:16:46 -08:00
|
|
|
13, 48, 41, 0, 12, 4, 0, 0, 11, 0,
|
|
|
|
45, 45, 45, 0, 0, 23, 0, 28, 0, 0,
|
|
|
|
0, 43, 0, 42, 14, 13, 0, 0, 0, 0,
|
|
|
|
0, 0, 30, 0, 28, 0, 26, 27, 32, 0,
|
|
|
|
21, 0, 0, 34, 52, 54, 55, 0, 0, 44,
|
|
|
|
0, 0, 0, 0, 28, 38, 0, 39, 40, 24,
|
|
|
|
31, 25, 29, 22, 33, 0, 48, 0, 0, 50,
|
|
|
|
0, 0, 16, 17, 0, 8, 35, 0, 53, 43,
|
|
|
|
0, 49, 0, 6, 15, 0, 0, 0, 0, 46,
|
|
|
|
36, 37, 51, 18, 19, 14, 9, 0, 0, 0,
|
|
|
|
0, 0, 0, 47, 0, 7,
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
var yyTok1 = []int{
|
|
|
|
|
|
|
|
1, 3, 3, 3, 3, 3, 3, 3, 3, 3,
|
|
|
|
3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
|
|
|
|
3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
|
|
|
|
3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
|
2015-03-03 01:58:28 -08:00
|
|
|
31, 32, 3, 3, 30, 3, 3, 3, 3, 3,
|
2013-01-07 14:24:26 -08:00
|
|
|
3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
|
2015-03-03 01:58:28 -08:00
|
|
|
3, 27, 3, 3, 3, 3, 3, 3, 3, 3,
|
2013-01-07 14:24:26 -08:00
|
|
|
3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
|
|
|
|
3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
|
2015-03-03 01:58:28 -08:00
|
|
|
3, 33, 3, 34, 3, 3, 3, 3, 3, 3,
|
2013-01-07 14:24:26 -08:00
|
|
|
3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
|
|
|
|
3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
|
2015-03-03 01:58:28 -08:00
|
|
|
3, 3, 3, 28, 3, 29,
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
var yyTok2 = []int{
|
|
|
|
|
|
|
|
2, 3, 4, 5, 6, 7, 8, 9, 10, 11,
|
2013-07-30 08:18:07 -07:00
|
|
|
12, 13, 14, 15, 16, 17, 18, 19, 20, 21,
|
2015-03-03 01:58:28 -08:00
|
|
|
22, 23, 24, 25, 26,
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
var yyTok3 = []int{
|
|
|
|
0,
|
|
|
|
}
|
|
|
|
|
|
|
|
//line yaccpar:1
|
|
|
|
|
|
|
|
/* parser for yacc output */
|
|
|
|
|
|
|
|
var yyDebug = 0
|
|
|
|
|
|
|
|
type yyLexer interface {
|
|
|
|
Lex(lval *yySymType) int
|
|
|
|
Error(s string)
|
|
|
|
}
|
|
|
|
|
|
|
|
const yyFlag = -1000
|
|
|
|
|
|
|
|
func yyTokname(c int) string {
|
2013-06-06 06:12:37 -07:00
|
|
|
// 4 is TOKSTART above
|
|
|
|
if c >= 4 && c-4 < len(yyToknames) {
|
|
|
|
if yyToknames[c-4] != "" {
|
|
|
|
return yyToknames[c-4]
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
}
|
2013-06-06 06:12:37 -07:00
|
|
|
return __yyfmt__.Sprintf("tok-%v", c)
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
|
|
|
|
func yyStatname(s int) string {
|
|
|
|
if s >= 0 && s < len(yyStatenames) {
|
|
|
|
if yyStatenames[s] != "" {
|
|
|
|
return yyStatenames[s]
|
|
|
|
}
|
|
|
|
}
|
2013-06-06 06:12:37 -07:00
|
|
|
return __yyfmt__.Sprintf("state-%v", s)
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
|
|
|
|
func yylex1(lex yyLexer, lval *yySymType) int {
|
|
|
|
c := 0
|
|
|
|
char := lex.Lex(lval)
|
|
|
|
if char <= 0 {
|
|
|
|
c = yyTok1[0]
|
|
|
|
goto out
|
|
|
|
}
|
|
|
|
if char < len(yyTok1) {
|
|
|
|
c = yyTok1[char]
|
|
|
|
goto out
|
|
|
|
}
|
|
|
|
if char >= yyPrivate {
|
|
|
|
if char < yyPrivate+len(yyTok2) {
|
|
|
|
c = yyTok2[char-yyPrivate]
|
|
|
|
goto out
|
|
|
|
}
|
|
|
|
}
|
|
|
|
for i := 0; i < len(yyTok3); i += 2 {
|
|
|
|
c = yyTok3[i+0]
|
|
|
|
if c == char {
|
|
|
|
c = yyTok3[i+1]
|
|
|
|
goto out
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
out:
|
|
|
|
if c == 0 {
|
|
|
|
c = yyTok2[1] /* unknown char */
|
|
|
|
}
|
|
|
|
if yyDebug >= 3 {
|
2014-02-22 13:29:32 -08:00
|
|
|
__yyfmt__.Printf("lex %s(%d)\n", yyTokname(c), uint(char))
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
return c
|
|
|
|
}
|
|
|
|
|
|
|
|
func yyParse(yylex yyLexer) int {
|
|
|
|
var yyn int
|
|
|
|
var yylval yySymType
|
|
|
|
var yyVAL yySymType
|
|
|
|
yyS := make([]yySymType, yyMaxDepth)
|
|
|
|
|
|
|
|
Nerrs := 0 /* number of errors */
|
|
|
|
Errflag := 0 /* error recovery flag */
|
|
|
|
yystate := 0
|
|
|
|
yychar := -1
|
|
|
|
yyp := -1
|
|
|
|
goto yystack
|
|
|
|
|
|
|
|
ret0:
|
|
|
|
return 0
|
|
|
|
|
|
|
|
ret1:
|
|
|
|
return 1
|
|
|
|
|
|
|
|
yystack:
|
|
|
|
/* put a state and value onto the stack */
|
|
|
|
if yyDebug >= 4 {
|
2013-06-06 06:12:37 -07:00
|
|
|
__yyfmt__.Printf("char %v in %v\n", yyTokname(yychar), yyStatname(yystate))
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
|
|
|
|
yyp++
|
|
|
|
if yyp >= len(yyS) {
|
|
|
|
nyys := make([]yySymType, len(yyS)*2)
|
|
|
|
copy(nyys, yyS)
|
|
|
|
yyS = nyys
|
|
|
|
}
|
|
|
|
yyS[yyp] = yyVAL
|
|
|
|
yyS[yyp].yys = yystate
|
|
|
|
|
|
|
|
yynewstate:
|
|
|
|
yyn = yyPact[yystate]
|
|
|
|
if yyn <= yyFlag {
|
|
|
|
goto yydefault /* simple state */
|
|
|
|
}
|
|
|
|
if yychar < 0 {
|
|
|
|
yychar = yylex1(yylex, &yylval)
|
|
|
|
}
|
|
|
|
yyn += yychar
|
|
|
|
if yyn < 0 || yyn >= yyLast {
|
|
|
|
goto yydefault
|
|
|
|
}
|
|
|
|
yyn = yyAct[yyn]
|
|
|
|
if yyChk[yyn] == yychar { /* valid shift */
|
|
|
|
yychar = -1
|
|
|
|
yyVAL = yylval
|
|
|
|
yystate = yyn
|
|
|
|
if Errflag > 0 {
|
|
|
|
Errflag--
|
|
|
|
}
|
|
|
|
goto yystack
|
|
|
|
}
|
|
|
|
|
|
|
|
yydefault:
|
|
|
|
/* default state action */
|
|
|
|
yyn = yyDef[yystate]
|
|
|
|
if yyn == -2 {
|
|
|
|
if yychar < 0 {
|
|
|
|
yychar = yylex1(yylex, &yylval)
|
|
|
|
}
|
|
|
|
|
|
|
|
/* look through exception table */
|
|
|
|
xi := 0
|
|
|
|
for {
|
|
|
|
if yyExca[xi+0] == -1 && yyExca[xi+1] == yystate {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
xi += 2
|
|
|
|
}
|
|
|
|
for xi += 2; ; xi += 2 {
|
|
|
|
yyn = yyExca[xi+0]
|
|
|
|
if yyn < 0 || yyn == yychar {
|
|
|
|
break
|
|
|
|
}
|
|
|
|
}
|
|
|
|
yyn = yyExca[xi+1]
|
|
|
|
if yyn < 0 {
|
|
|
|
goto ret0
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if yyn == 0 {
|
|
|
|
/* error ... attempt to resume parsing */
|
|
|
|
switch Errflag {
|
|
|
|
case 0: /* brand new error */
|
|
|
|
yylex.Error("syntax error")
|
|
|
|
Nerrs++
|
|
|
|
if yyDebug >= 1 {
|
2013-06-06 06:12:37 -07:00
|
|
|
__yyfmt__.Printf("%s", yyStatname(yystate))
|
2014-02-22 13:29:32 -08:00
|
|
|
__yyfmt__.Printf(" saw %s\n", yyTokname(yychar))
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
fallthrough
|
|
|
|
|
|
|
|
case 1, 2: /* incompletely recovered error ... try again */
|
|
|
|
Errflag = 3
|
|
|
|
|
|
|
|
/* find a state where "error" is a legal shift action */
|
|
|
|
for yyp >= 0 {
|
|
|
|
yyn = yyPact[yyS[yyp].yys] + yyErrCode
|
|
|
|
if yyn >= 0 && yyn < yyLast {
|
|
|
|
yystate = yyAct[yyn] /* simulate a shift of "error" */
|
|
|
|
if yyChk[yystate] == yyErrCode {
|
|
|
|
goto yystack
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
/* the current p has no shift on "error", pop stack */
|
|
|
|
if yyDebug >= 2 {
|
2013-06-06 06:12:37 -07:00
|
|
|
__yyfmt__.Printf("error recovery pops state %d\n", yyS[yyp].yys)
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
yyp--
|
|
|
|
}
|
|
|
|
/* there is no state on the stack with an error shift ... abort */
|
|
|
|
goto ret1
|
|
|
|
|
|
|
|
case 3: /* no shift yet; clobber input char */
|
|
|
|
if yyDebug >= 2 {
|
2013-06-06 06:12:37 -07:00
|
|
|
__yyfmt__.Printf("error recovery discards %s\n", yyTokname(yychar))
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
if yychar == yyEofCode {
|
|
|
|
goto ret1
|
|
|
|
}
|
|
|
|
yychar = -1
|
|
|
|
goto yynewstate /* try again in the same state */
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
/* reduction by production yyn */
|
|
|
|
if yyDebug >= 2 {
|
2013-06-06 06:12:37 -07:00
|
|
|
__yyfmt__.Printf("reduce %v in:\n\t%v\n", yyn, yyStatname(yystate))
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
|
|
|
|
yynt := yyn
|
|
|
|
yypt := yyp
|
|
|
|
_ = yypt // guard against "declared and not used"
|
|
|
|
|
|
|
|
yyp -= yyR2[yyn]
|
|
|
|
yyVAL = yyS[yyp+1]
|
|
|
|
|
|
|
|
/* consult goto table to find next state */
|
|
|
|
yyn = yyR1[yyn]
|
|
|
|
yyg := yyPgo[yyn]
|
|
|
|
yyj := yyg + yyS[yyp].yys + 1
|
|
|
|
|
|
|
|
if yyj >= yyLast {
|
|
|
|
yystate = yyAct[yyg]
|
|
|
|
} else {
|
|
|
|
yystate = yyAct[yyj]
|
|
|
|
if yyChk[yystate] != -yyn {
|
|
|
|
yystate = yyAct[yyg]
|
|
|
|
}
|
|
|
|
}
|
|
|
|
// dummy call; replaced with literal code
|
|
|
|
switch yynt {
|
|
|
|
|
2013-01-10 16:17:37 -08:00
|
|
|
case 5:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:76
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yylex.(*RulesLexer).parsedExpr = yyS[yypt-0].ruleNode
|
|
|
|
}
|
2013-01-10 16:17:37 -08:00
|
|
|
case 6:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:81
|
2013-01-07 14:24:26 -08:00
|
|
|
{
|
2014-10-14 08:21:39 -07:00
|
|
|
rule, err := CreateRecordingRule(yyS[yypt-3].str, yyS[yypt-2].labelSet, yyS[yypt-0].ruleNode, yyS[yypt-4].boolean)
|
|
|
|
if err != nil {
|
|
|
|
yylex.Error(err.Error())
|
|
|
|
return 1
|
|
|
|
}
|
|
|
|
yylex.(*RulesLexer).parsedRules = append(yylex.(*RulesLexer).parsedRules, rule)
|
|
|
|
}
|
2013-01-10 16:17:37 -08:00
|
|
|
case 7:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:87
|
2013-04-22 15:26:59 -07:00
|
|
|
{
|
2014-10-14 08:21:39 -07:00
|
|
|
rule, err := CreateAlertingRule(yyS[yypt-9].str, yyS[yypt-7].ruleNode, yyS[yypt-6].str, yyS[yypt-4].labelSet, yyS[yypt-2].str, yyS[yypt-0].str)
|
|
|
|
if err != nil {
|
|
|
|
yylex.Error(err.Error())
|
|
|
|
return 1
|
|
|
|
}
|
|
|
|
yylex.(*RulesLexer).parsedRules = append(yylex.(*RulesLexer).parsedRules, rule)
|
|
|
|
}
|
2013-01-10 16:17:37 -08:00
|
|
|
case 8:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:95
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yyVAL.str = "0s"
|
|
|
|
}
|
2013-01-10 16:17:37 -08:00
|
|
|
case 9:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:97
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yyVAL.str = yyS[yypt-0].str
|
|
|
|
}
|
2013-01-10 16:17:37 -08:00
|
|
|
case 10:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:101
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yyVAL.boolean = false
|
|
|
|
}
|
2013-01-10 16:17:37 -08:00
|
|
|
case 11:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:103
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yyVAL.boolean = true
|
|
|
|
}
|
2013-01-10 16:17:37 -08:00
|
|
|
case 12:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:107
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yyVAL.str = yyS[yypt-0].str
|
|
|
|
}
|
2013-01-10 16:17:37 -08:00
|
|
|
case 13:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:109
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yyVAL.str = yyS[yypt-0].str
|
|
|
|
}
|
2013-01-10 16:17:37 -08:00
|
|
|
case 14:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:113
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yyVAL.labelSet = clientmodel.LabelSet{}
|
|
|
|
}
|
2013-07-11 09:38:44 -07:00
|
|
|
case 15:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:115
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yyVAL.labelSet = yyS[yypt-1].labelSet
|
|
|
|
}
|
2014-03-21 05:11:01 -07:00
|
|
|
case 16:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:117
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yyVAL.labelSet = clientmodel.LabelSet{}
|
|
|
|
}
|
2013-01-10 16:17:37 -08:00
|
|
|
case 17:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:120
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yyVAL.labelSet = yyS[yypt-0].labelSet
|
|
|
|
}
|
2013-04-22 15:26:59 -07:00
|
|
|
case 18:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:122
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
for k, v := range yyS[yypt-0].labelSet {
|
|
|
|
yyVAL.labelSet[k] = v
|
|
|
|
}
|
|
|
|
}
|
2013-04-22 15:26:59 -07:00
|
|
|
case 19:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:126
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yyVAL.labelSet = clientmodel.LabelSet{clientmodel.LabelName(yyS[yypt-2].str): clientmodel.LabelValue(yyS[yypt-0].str)}
|
|
|
|
}
|
2013-04-22 15:26:59 -07:00
|
|
|
case 20:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:130
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yyVAL.labelMatchers = metric.LabelMatchers{}
|
|
|
|
}
|
2014-03-21 05:11:01 -07:00
|
|
|
case 21:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:132
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yyVAL.labelMatchers = metric.LabelMatchers{}
|
|
|
|
}
|
2014-03-21 05:11:01 -07:00
|
|
|
case 22:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:134
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yyVAL.labelMatchers = yyS[yypt-1].labelMatchers
|
|
|
|
}
|
2014-03-28 03:58:47 -07:00
|
|
|
case 23:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:138
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yyVAL.labelMatchers = metric.LabelMatchers{yyS[yypt-0].labelMatcher}
|
|
|
|
}
|
2014-03-28 03:58:47 -07:00
|
|
|
case 24:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:140
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yyVAL.labelMatchers = append(yyVAL.labelMatchers, yyS[yypt-0].labelMatcher)
|
|
|
|
}
|
2014-03-28 03:58:47 -07:00
|
|
|
case 25:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:144
|
2014-03-28 03:58:47 -07:00
|
|
|
{
|
2014-10-14 08:21:39 -07:00
|
|
|
var err error
|
|
|
|
yyVAL.labelMatcher, err = newLabelMatcher(yyS[yypt-1].str, clientmodel.LabelName(yyS[yypt-2].str), clientmodel.LabelValue(yyS[yypt-0].str))
|
|
|
|
if err != nil {
|
|
|
|
yylex.Error(err.Error())
|
|
|
|
return 1
|
|
|
|
}
|
|
|
|
}
|
2014-03-28 03:58:47 -07:00
|
|
|
case 26:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:152
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yyVAL.str = "="
|
|
|
|
}
|
2014-03-28 03:58:47 -07:00
|
|
|
case 27:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:154
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yyVAL.str = yyS[yypt-0].str
|
|
|
|
}
|
2014-03-28 03:58:47 -07:00
|
|
|
case 28:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:158
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
2015-02-17 17:30:41 -08:00
|
|
|
yyVAL.str = "0s"
|
2014-10-14 08:21:39 -07:00
|
|
|
}
|
2014-03-28 03:58:47 -07:00
|
|
|
case 29:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:160
|
2014-03-28 03:58:47 -07:00
|
|
|
{
|
2015-02-17 17:30:41 -08:00
|
|
|
yyVAL.str = yyS[yypt-0].str
|
2014-10-14 08:21:39 -07:00
|
|
|
}
|
2014-03-28 03:58:47 -07:00
|
|
|
case 30:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:164
|
2015-02-17 17:30:41 -08:00
|
|
|
{
|
|
|
|
yyVAL.ruleNode = yyS[yypt-1].ruleNode
|
|
|
|
}
|
|
|
|
case 31:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:166
|
2013-01-07 14:24:26 -08:00
|
|
|
{
|
2014-10-14 08:21:39 -07:00
|
|
|
var err error
|
2015-02-17 17:30:41 -08:00
|
|
|
yyVAL.ruleNode, err = NewVectorSelector(yyS[yypt-2].labelMatchers, yyS[yypt-0].str)
|
2014-10-14 08:21:39 -07:00
|
|
|
if err != nil {
|
|
|
|
yylex.Error(err.Error())
|
|
|
|
return 1
|
|
|
|
}
|
|
|
|
}
|
2015-02-17 17:30:41 -08:00
|
|
|
case 32:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:172
|
2015-02-17 17:30:41 -08:00
|
|
|
{
|
|
|
|
var err error
|
|
|
|
m, err := metric.NewLabelMatcher(metric.Equal, clientmodel.MetricNameLabel, clientmodel.LabelValue(yyS[yypt-2].str))
|
|
|
|
if err != nil {
|
|
|
|
yylex.Error(err.Error())
|
|
|
|
return 1
|
|
|
|
}
|
|
|
|
yyS[yypt-1].labelMatchers = append(yyS[yypt-1].labelMatchers, m)
|
|
|
|
yyVAL.ruleNode, err = NewVectorSelector(yyS[yypt-1].labelMatchers, yyS[yypt-0].str)
|
|
|
|
if err != nil {
|
|
|
|
yylex.Error(err.Error())
|
|
|
|
return 1
|
|
|
|
}
|
|
|
|
}
|
|
|
|
case 33:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:181
|
2013-01-07 14:24:26 -08:00
|
|
|
{
|
2014-10-14 08:21:39 -07:00
|
|
|
var err error
|
|
|
|
yyVAL.ruleNode, err = NewFunctionCall(yyS[yypt-3].str, yyS[yypt-1].ruleNodeSlice)
|
|
|
|
if err != nil {
|
|
|
|
yylex.Error(err.Error())
|
|
|
|
return 1
|
|
|
|
}
|
|
|
|
}
|
2015-02-17 17:30:41 -08:00
|
|
|
case 34:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:187
|
2013-01-10 16:17:37 -08:00
|
|
|
{
|
2014-10-14 08:21:39 -07:00
|
|
|
var err error
|
|
|
|
yyVAL.ruleNode, err = NewFunctionCall(yyS[yypt-2].str, []ast.Node{})
|
|
|
|
if err != nil {
|
|
|
|
yylex.Error(err.Error())
|
|
|
|
return 1
|
|
|
|
}
|
|
|
|
}
|
2015-02-17 17:30:41 -08:00
|
|
|
case 35:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:193
|
2013-01-07 14:24:26 -08:00
|
|
|
{
|
2014-10-14 08:21:39 -07:00
|
|
|
var err error
|
2015-02-17 17:30:41 -08:00
|
|
|
yyVAL.ruleNode, err = NewMatrixSelector(yyS[yypt-4].ruleNode, yyS[yypt-2].str, yyS[yypt-0].str)
|
2014-10-14 08:21:39 -07:00
|
|
|
if err != nil {
|
|
|
|
yylex.Error(err.Error())
|
|
|
|
return 1
|
|
|
|
}
|
|
|
|
}
|
2015-02-17 17:30:41 -08:00
|
|
|
case 36:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:199
|
2013-01-07 14:24:26 -08:00
|
|
|
{
|
2014-10-14 08:21:39 -07:00
|
|
|
var err error
|
|
|
|
yyVAL.ruleNode, err = NewVectorAggregation(yyS[yypt-5].str, yyS[yypt-3].ruleNode, yyS[yypt-1].labelNameSlice, yyS[yypt-0].boolean)
|
|
|
|
if err != nil {
|
|
|
|
yylex.Error(err.Error())
|
|
|
|
return 1
|
|
|
|
}
|
|
|
|
}
|
2015-02-17 17:30:41 -08:00
|
|
|
case 37:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:205
|
2013-01-07 14:24:26 -08:00
|
|
|
{
|
2014-10-14 08:21:39 -07:00
|
|
|
var err error
|
2014-10-22 02:03:11 -07:00
|
|
|
yyVAL.ruleNode, err = NewVectorAggregation(yyS[yypt-5].str, yyS[yypt-1].ruleNode, yyS[yypt-4].labelNameSlice, yyS[yypt-3].boolean)
|
2014-10-14 08:21:39 -07:00
|
|
|
if err != nil {
|
|
|
|
yylex.Error(err.Error())
|
|
|
|
return 1
|
|
|
|
}
|
|
|
|
}
|
2015-02-17 17:30:41 -08:00
|
|
|
case 38:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:213
|
2013-01-07 14:24:26 -08:00
|
|
|
{
|
2014-10-14 08:21:39 -07:00
|
|
|
var err error
|
2015-03-03 01:58:28 -08:00
|
|
|
yyVAL.ruleNode, err = NewArithExpr(yyS[yypt-2].str, yyS[yypt-3].ruleNode, yyS[yypt-0].ruleNode, yyS[yypt-1].vectorMatching)
|
2014-10-14 08:21:39 -07:00
|
|
|
if err != nil {
|
|
|
|
yylex.Error(err.Error())
|
|
|
|
return 1
|
|
|
|
}
|
|
|
|
}
|
2015-02-17 17:30:41 -08:00
|
|
|
case 39:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:219
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
var err error
|
2015-03-03 01:58:28 -08:00
|
|
|
yyVAL.ruleNode, err = NewArithExpr(yyS[yypt-2].str, yyS[yypt-3].ruleNode, yyS[yypt-0].ruleNode, yyS[yypt-1].vectorMatching)
|
2014-10-14 08:21:39 -07:00
|
|
|
if err != nil {
|
|
|
|
yylex.Error(err.Error())
|
|
|
|
return 1
|
|
|
|
}
|
|
|
|
}
|
2015-02-17 17:30:41 -08:00
|
|
|
case 40:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:225
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
2014-10-22 02:03:11 -07:00
|
|
|
var err error
|
2015-03-03 01:58:28 -08:00
|
|
|
yyVAL.ruleNode, err = NewArithExpr(yyS[yypt-2].str, yyS[yypt-3].ruleNode, yyS[yypt-0].ruleNode, yyS[yypt-1].vectorMatching)
|
2014-10-22 02:03:11 -07:00
|
|
|
if err != nil {
|
|
|
|
yylex.Error(err.Error())
|
|
|
|
return 1
|
|
|
|
}
|
2014-10-14 08:21:39 -07:00
|
|
|
}
|
2015-02-17 17:30:41 -08:00
|
|
|
case 41:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:231
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
2015-03-03 03:16:46 -08:00
|
|
|
yyVAL.ruleNode = NewScalarLiteral(yyS[yypt-0].num, "+")
|
2014-10-14 08:21:39 -07:00
|
|
|
}
|
2015-02-17 17:30:41 -08:00
|
|
|
case 42:
|
2015-03-03 03:16:46 -08:00
|
|
|
//line parser.y:233
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
2015-03-03 03:16:46 -08:00
|
|
|
yyVAL.ruleNode = NewScalarLiteral(yyS[yypt-0].num, yyS[yypt-1].str)
|
2014-10-14 08:21:39 -07:00
|
|
|
}
|
2015-02-17 17:30:41 -08:00
|
|
|
case 43:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:237
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
2015-03-03 03:16:46 -08:00
|
|
|
yyVAL.boolean = false
|
2014-10-14 08:21:39 -07:00
|
|
|
}
|
2015-02-17 17:30:41 -08:00
|
|
|
case 44:
|
2015-03-03 03:16:46 -08:00
|
|
|
//line parser.y:239
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
2015-03-03 03:16:46 -08:00
|
|
|
yyVAL.boolean = true
|
2014-10-14 08:21:39 -07:00
|
|
|
}
|
2015-02-17 17:30:41 -08:00
|
|
|
case 45:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:243
|
2015-03-03 03:16:46 -08:00
|
|
|
{
|
|
|
|
yyVAL.vectorMatching = nil
|
|
|
|
}
|
|
|
|
case 46:
|
|
|
|
//line parser.y:245
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
2015-03-03 01:58:28 -08:00
|
|
|
var err error
|
|
|
|
yyVAL.vectorMatching, err = newVectorMatching("", yyS[yypt-1].labelNameSlice, nil)
|
|
|
|
if err != nil {
|
|
|
|
yylex.Error(err.Error())
|
|
|
|
return 1
|
|
|
|
}
|
2014-10-14 08:21:39 -07:00
|
|
|
}
|
2015-03-03 03:16:46 -08:00
|
|
|
case 47:
|
|
|
|
//line parser.y:251
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
2015-03-03 01:58:28 -08:00
|
|
|
var err error
|
|
|
|
yyVAL.vectorMatching, err = newVectorMatching(yyS[yypt-3].str, yyS[yypt-5].labelNameSlice, yyS[yypt-1].labelNameSlice)
|
|
|
|
if err != nil {
|
|
|
|
yylex.Error(err.Error())
|
|
|
|
return 1
|
|
|
|
}
|
2014-10-14 08:21:39 -07:00
|
|
|
}
|
2015-02-17 17:30:41 -08:00
|
|
|
case 48:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:259
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
2015-03-03 03:16:46 -08:00
|
|
|
yyVAL.labelNameSlice = clientmodel.LabelNames{}
|
2014-10-14 08:21:39 -07:00
|
|
|
}
|
2015-02-17 17:30:41 -08:00
|
|
|
case 49:
|
2015-03-03 03:16:46 -08:00
|
|
|
//line parser.y:261
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
2015-03-03 03:16:46 -08:00
|
|
|
yyVAL.labelNameSlice = yyS[yypt-1].labelNameSlice
|
2014-10-14 08:21:39 -07:00
|
|
|
}
|
2015-02-17 17:30:41 -08:00
|
|
|
case 50:
|
2015-03-03 01:58:28 -08:00
|
|
|
//line parser.y:265
|
2014-10-22 02:03:11 -07:00
|
|
|
{
|
2015-03-03 03:16:46 -08:00
|
|
|
yyVAL.labelNameSlice = clientmodel.LabelNames{clientmodel.LabelName(yyS[yypt-0].str)}
|
2014-10-22 02:03:11 -07:00
|
|
|
}
|
2015-02-17 17:30:41 -08:00
|
|
|
case 51:
|
2015-03-03 03:16:46 -08:00
|
|
|
//line parser.y:267
|
2015-03-03 01:58:28 -08:00
|
|
|
{
|
2015-03-03 03:16:46 -08:00
|
|
|
yyVAL.labelNameSlice = append(yyVAL.labelNameSlice, clientmodel.LabelName(yyS[yypt-0].str))
|
2015-03-03 01:58:28 -08:00
|
|
|
}
|
|
|
|
case 52:
|
|
|
|
//line parser.y:271
|
|
|
|
{
|
2015-03-03 03:16:46 -08:00
|
|
|
yyVAL.ruleNodeSlice = []ast.Node{yyS[yypt-0].ruleNode}
|
2015-03-03 01:58:28 -08:00
|
|
|
}
|
|
|
|
case 53:
|
2015-03-03 03:16:46 -08:00
|
|
|
//line parser.y:273
|
2015-03-03 01:58:28 -08:00
|
|
|
{
|
2015-03-03 03:16:46 -08:00
|
|
|
yyVAL.ruleNodeSlice = append(yyVAL.ruleNodeSlice, yyS[yypt-0].ruleNode)
|
2015-03-03 01:58:28 -08:00
|
|
|
}
|
|
|
|
case 54:
|
|
|
|
//line parser.y:277
|
2015-03-03 03:16:46 -08:00
|
|
|
{
|
|
|
|
yyVAL.ruleNode = yyS[yypt-0].ruleNode
|
|
|
|
}
|
|
|
|
case 55:
|
|
|
|
//line parser.y:279
|
2014-10-14 08:21:39 -07:00
|
|
|
{
|
|
|
|
yyVAL.ruleNode = ast.NewStringLiteral(yyS[yypt-0].str)
|
|
|
|
}
|
2013-01-07 14:24:26 -08:00
|
|
|
}
|
|
|
|
goto yystack /* stack new state and value */
|
|
|
|
}
|