diff options
author | johans <johans@FreeBSD.org> | 2009-03-06 20:04:11 +0800 |
---|---|---|
committer | johans <johans@FreeBSD.org> | 2009-03-06 20:04:11 +0800 |
commit | 22042d5823770cbfc2dfe8e5204aeca8bbd07a5e (patch) | |
tree | 6278b6ba7abe11dddf84df2261faaaa99bc5a989 /lang | |
parent | cda4cb0e938960d41d98a51ee53848b56f54c6cc (diff) | |
download | freebsd-ports-gnome-22042d5823770cbfc2dfe8e5204aeca8bbd07a5e.tar.gz freebsd-ports-gnome-22042d5823770cbfc2dfe8e5204aeca8bbd07a5e.tar.zst freebsd-ports-gnome-22042d5823770cbfc2dfe8e5204aeca8bbd07a5e.zip |
- Update bison to 2.4.1, see announcements for important changes:
http://lists.gnu.org/archive/html/bug-bison/2008-11/msg00000.html
http://lists.gnu.org/archive/html/bug-bison/2008-12/msg00000.html
- Take over bison maintainership - as approved by portmgr (marcus)
- Add patches for ports to compile with new bison:
Replace %{ .. %} with %code { .. } where required
and accommodate stricter typing requirements
Thanks to pav for an exp-run on pointyhat
PR: ports/131640
Approved by: portmgr (pav)
Diffstat (limited to 'lang')
-rw-r--r-- | lang/ptoc/files/patch-parser.y | 52 |
1 files changed, 37 insertions, 15 deletions
diff --git a/lang/ptoc/files/patch-parser.y b/lang/ptoc/files/patch-parser.y index b895a2dc13ed..1d2b86fc752a 100644 --- a/lang/ptoc/files/patch-parser.y +++ b/lang/ptoc/files/patch-parser.y @@ -1,6 +1,9 @@ ---- parser.y.orig Mon Mar 26 10:02:40 2001 -+++ parser.y Wed Sep 17 13:34:05 2003 -@@ -3,11 +3,6 @@ +--- parser.y.orig 2004-12-09 11:50:14.000000000 +0100 ++++ parser.y 2009-03-06 11:26:20.000000000 +0100 +@@ -1,19 +1,18 @@ +-%{ ++%code requires { + #include <stdio.h> #include <stdlib.h> #include <string.h> @@ -12,7 +15,26 @@ #include "nmtbl.h" #include "token.h" -@@ -285,23 +280,27 @@ + #include "trnod.h" + #include "util.h" + ++} ++ ++%code provides { ++ + static int zzcnv_table[] = { + #define DEF_TOKEN(mnem, cat, cls, yacc) yacc, + #include "token.dpp" +@@ -26,7 +25,7 @@ + error(curr_token, "syntax error: %s", text); + } + +-%} ++} + + + %union { +@@ -286,23 +285,27 @@ $2->attrib(ctx_program); $2->translate(ctx_program); } @@ -41,7 +63,7 @@ /* Turbo Pascal specific */ -@@ -313,38 +312,46 @@ +@@ -314,38 +317,46 @@ { $$ = new unit_node(NULL, NULL, NULL, $1, $2, $3, $4, NULL, $5, $6); } | INTERFACE unit_decl_list IMPLEMENTATION unit_def_list compoundst '.' { $$ = new unit_node(NULL, NULL, NULL, $1, $2, $3, $4, $5, NULL, $6); } @@ -90,7 +112,7 @@ /* //============================================================================= -@@ -401,15 +408,20 @@ +@@ -402,15 +413,20 @@ | ICONST ':' statement { $$ = new label_node($1, $2, $3); } | IDENT ':' statement { $$ = new label_node($1, $2, $3); } | compoundst { $$ = $1; } @@ -111,7 +133,7 @@ case_list: case_items | case_items otherwise sequence -@@ -423,20 +435,26 @@ +@@ -424,20 +440,26 @@ $$ = new case_node(NULL, $2, $3); } } @@ -138,7 +160,7 @@ /* //============================================================================= -@@ -485,6 +503,7 @@ +@@ -486,6 +508,7 @@ | expr OR expr { $$ = new op_node(tn_or, $1, $2, $3); } | expr XOR expr { $$ = new op_node(tn_xor, $1, $2, $3); } @@ -146,7 +168,7 @@ | expr GT expr { $$ = new op_node(tn_gt, $1, $2, $3); } | expr LT expr { $$ = new op_node(tn_lt, $1, $2, $3); } | expr LE expr { $$ = new op_node(tn_le, $1, $2, $3); } -@@ -492,6 +511,7 @@ +@@ -493,6 +516,7 @@ | expr EQ expr { $$ = new op_node(tn_eq, $1, $2, $3); } | expr NE expr { $$ = new op_node(tn_ne, $1, $2, $3); } | expr IN expr { $$ = new op_node(tn_in, $1, $2, $3); } @@ -154,7 +176,7 @@ simple_expr: primary | PLUS simple_expr %prec UPLUS { -@@ -502,6 +522,7 @@ +@@ -503,6 +527,7 @@ { $$ = new op_node(tn_not, NULL, $1, $2); } | '@' primary { $$ = new address_node($1, $2); } | AND primary %prec ADDRESS { $$ = new address_node($1, $2); } @@ -162,7 +184,7 @@ primary: constant | '(' expr_list ')' { $$ = new expr_group_node($1, $2, $3); } -@@ -510,6 +531,7 @@ +@@ -511,6 +536,7 @@ | primary '^' { $$ = new deref_expr_node($1, $2); } | primary '[' expr_list ']' { $$ = new idx_expr_node($1, $2, $3, $4); } | LOOPHOLE '(' type ',' expr ')' { $$ = new loophole_node($1, $2, $3, $4, $5, $6); } @@ -170,7 +192,7 @@ constant: record_constant | ICONST { $$ = new integer_node($1); } -@@ -517,41 +539,49 @@ +@@ -518,41 +544,49 @@ | SCONST { $$ = new string_node($1); } | '[' set_elem_list ']' { $$ = new set_node($1, $2, $3); } | IDENT { $$ = new atom_expr_node($1); } @@ -224,7 +246,7 @@ /* //============================================================================= -@@ -594,31 +624,40 @@ +@@ -595,31 +629,40 @@ label_decl_part: LABEL label_list ';' { $$ = new label_decl_part_node($1, $2, $3); } @@ -265,7 +287,7 @@ var_decl_list: { $$ = NULL; } | var_decl -@@ -634,29 +673,33 @@ +@@ -635,29 +678,33 @@ $1->next = $5; $$ = $1; } | var_decl ';' var_decl_list { $1->next = $3; $$ = $1; } @@ -300,7 +322,7 @@ proc_def: PROCEDURE IDENT formal_params ';' block ';' -@@ -675,135 +718,166 @@ +@@ -676,135 +723,166 @@ { $$ = new proc_def_node($1, NULL, NULL, $2, $3, $4, $5, $6, $7, $8, $9, $10); } | FUNCTION IDENT ';' FAR ';' block ';' { $$ = new proc_def_node($1, NULL, NULL, $2, NULL, NULL, NULL, $3, $4, $5, $6, $7); } |