parse-events.y (3eb66e91a25497065c5322b1268cbc3953642227) parse-events.y (714a92d83fd1e20461f53549cfbee77b20be5032)
1%pure-parser
2%parse-param {void *_parse_state}
3%parse-param {void *scanner}
4%lex-param {void* scanner}
5%locations
6
7%{
8

--- 297 unchanged lines hidden (view full) ---

306 int config = $1 & 255;
307
308 ALLOC_LIST(list);
309 ABORT_ON(parse_events_add_numeric(_parse_state, list, type, config, $3));
310 parse_events_terms__delete($3);
311 $$ = list;
312}
313|
1%pure-parser
2%parse-param {void *_parse_state}
3%parse-param {void *scanner}
4%lex-param {void* scanner}
5%locations
6
7%{
8

--- 297 unchanged lines hidden (view full) ---

306 int config = $1 & 255;
307
308 ALLOC_LIST(list);
309 ABORT_ON(parse_events_add_numeric(_parse_state, list, type, config, $3));
310 parse_events_terms__delete($3);
311 $$ = list;
312}
313|
314value_sym sep_slash_dc
314value_sym sep_slash_slash_dc
315{
316 struct list_head *list;
317 int type = $1 >> 16;
318 int config = $1 & 255;
319
320 ALLOC_LIST(list);
321 ABORT_ON(parse_events_add_numeric(_parse_state, list, type, config, NULL));
322 $$ = list;

--- 374 unchanged lines hidden (view full) ---

697 ABORT_ON(!array.ranges);
698 array.ranges[0].start = $1;
699 array.ranges[0].length = $3 - $1 + 1;
700 $$ = array;
701}
702
703sep_dc: ':' |
704
315{
316 struct list_head *list;
317 int type = $1 >> 16;
318 int config = $1 & 255;
319
320 ALLOC_LIST(list);
321 ABORT_ON(parse_events_add_numeric(_parse_state, list, type, config, NULL));
322 $$ = list;

--- 374 unchanged lines hidden (view full) ---

697 ABORT_ON(!array.ranges);
698 array.ranges[0].start = $1;
699 array.ranges[0].length = $3 - $1 + 1;
700 $$ = array;
701}
702
703sep_dc: ':' |
704
705sep_slash_dc: '/' | ':' |
705sep_slash_slash_dc: '/' '/' | ':' |
706
707%%
708
709void parse_events_error(YYLTYPE *loc, void *parse_state,
710 void *scanner __maybe_unused,
711 char const *msg __maybe_unused)
712{
713 parse_events_evlist_error(parse_state, loc->last_column, "parser error");
714}
706
707%%
708
709void parse_events_error(YYLTYPE *loc, void *parse_state,
710 void *scanner __maybe_unused,
711 char const *msg __maybe_unused)
712{
713 parse_events_evlist_error(parse_state, loc->last_column, "parser error");
714}