pike.git/
src/
language.yacc
Branch:
Tag:
Non-build tags
All tags
No tags
2016-05-09
2016-05-09 14:14:10 by Henrik Grubbström (Grubba) <grubba@grubba.org>
aea6a47d7252d72738742b1e70f463af77346bf0 (
24
lines) (+
14
/-
10
)
[
Show
|
Annotate
]
Branch:
8.1
Compiler: Fixed a few shift/reduce conflicts.
329:
%type <n> expr3 expr0 %type <n> apply %type <n> expr4
+
%type <n> expr5
%type <n> expr_list %type <n> expr_list2 %type <n> for
3497:
} ;
-
expr4: literal_expr
+
expr4:
idents2 | expr5
+
| expr5 '.' line_number_info TOK_IDENTIFIER
+
{
+
$$=index_node($1,".",$4->u.sval.u.string);
+
COPY_LINE_NUMBER_INFO($$, $3);
+
free_node ($1);
+
free_node ($3);
+
free_node ($4);
+
}
+
;
+
+
expr5:
literal_expr
| catch | gauge | typeof
3505:
| lambda | implicit_modifiers class { $$ = $2; } | implicit_modifiers enum { $$ = $2; }
-
| idents2
+
| apply | expr4 open_bracket_with_line_info '*' ']' {
3658:
COPY_LINE_NUMBER_INFO($$, $3); free_node ($3); }
-
| expr4 '.' line_number_info TOK_IDENTIFIER
-
{
-
$$=index_node($1,".",$4->u.sval.u.string);
-
COPY_LINE_NUMBER_INFO($$, $3);
-
free_node ($1);
-
free_node ($3);
-
free_node ($4);
-
}
+
| expr4 TOK_ARROW line_number_info error {$$=$1; free_node ($3);} ;