aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog16
-rw-r--r--Checklist5
-rw-r--r--README2
-rw-r--r--README_d/ChangeLog4
-rw-r--r--awkgram.c400
-rw-r--r--awkgram.y18
-rw-r--r--awklib/ChangeLog4
-rw-r--r--builtin.c3
-rw-r--r--doc/ChangeLog9
-rw-r--r--doc/awkcard.in2
-rw-r--r--extension/ChangeLog4
-rw-r--r--interpret.h8
-rw-r--r--m4/ChangeLog4
-rw-r--r--missing_d/ChangeLog4
-rw-r--r--pc/ChangeLog8
-rw-r--r--pc/Makefile.tst7
-rw-r--r--po/ChangeLog4
-rw-r--r--po/gawk.pot654
-rw-r--r--posix/ChangeLog4
-rw-r--r--test/ChangeLog10
-rw-r--r--test/Makefile.am6
-rw-r--r--test/Makefile.in11
-rw-r--r--test/Maketests5
-rw-r--r--test/paramuninitglobal.awk2
-rw-r--r--test/paramuninitglobal.ok2
-rw-r--r--vms/ChangeLog14
-rw-r--r--vms/descrip.mms4
-rw-r--r--vms/vms-conf.h6
-rw-r--r--vms/vmstest.com4
29 files changed, 1014 insertions, 210 deletions
diff --git a/ChangeLog b/ChangeLog
index cb0e2d9c..485c2e1f 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,19 @@
+2012-12-23 Arnold D. Robbins <arnold@skeeve.com>
+
+ * 4.0.2: Release tar ball made.
+
+2011-12-23 John Haque <j.eh@mchsi.com>
+
+ * awkgram.y (is_deferred_variable): New function.
+ (func_install): Call it.
+ * eval.c (r_interpret): Op_push_arg. Check for uninitialized scalar.
+
+2012-12-23 Arnold D. Robbins <arnold@skeeve.com>
+
+ * awkgram.y (tokentab): Whitespace fix for "include".
+ * builtin.c (printf_common): Do a fatal error if no args to printf()
+ or sprintf().
+
2012-12-19 Arnold D. Robbins <arnold@skeeve.com>
* bootstrap.sh: Touch extension/aclocal.m4 also.
diff --git a/Checklist b/Checklist
index acfbff84..e9d70e51 100644
--- a/Checklist
+++ b/Checklist
@@ -1,4 +1,4 @@
-Mon May 16 17:36:21 IDT 2011
+Sun Dec 23 15:01:09 IST 2012
============================
A checklist for making releases
@@ -35,6 +35,9 @@ Testing on
make maintainer-clean
make release
+ compile with tcc
+ compile with clang
+
configure --disable-lint
configure --disable-nls
configure --with-whiny-user-strftime
diff --git a/README b/README
index b752c65a..67b906c4 100644
--- a/README
+++ b/README
@@ -7,7 +7,7 @@
README:
-This is GNU Awk 4.0.1. It is upwardly compatible with Brian Kernighan's
+This is GNU Awk 4.0.2. It is upwardly compatible with Brian Kernighan's
version of Unix awk. It is almost completely compliant with the
2008 POSIX 1003.1 standard for awk. (See the note below about POSIX.)
diff --git a/README_d/ChangeLog b/README_d/ChangeLog
index 0310bd8d..0e164139 100644
--- a/README_d/ChangeLog
+++ b/README_d/ChangeLog
@@ -1,3 +1,7 @@
+2012-12-23 Arnold D. Robbins <arnold@skeeve.com>
+
+ * 4.0.2: Release tar ball made.
+
2012-04-11 John Haque <j.eh@mchsi.com>
* README.hacking: New file.
diff --git a/awkgram.c b/awkgram.c
index 9fd11568..228fd66d 100644
--- a/awkgram.c
+++ b/awkgram.c
@@ -98,6 +98,7 @@ static int include_source(INSTRUCTION *file);
static int load_library(INSTRUCTION *file);
static void next_sourcefile(void);
static char *tokexpand(void);
+static bool is_deferred_variable(const char *name);
#define instruction(t) bcalloc(t, 1, 0)
@@ -198,7 +199,7 @@ extern double fmod(double x, double y);
#define is_identchar(c) (isalnum(c) || (c) == '_')
/* Line 371 of yacc.c */
-#line 202 "awkgram.c"
+#line 203 "awkgram.c"
# ifndef YY_NULL
# if defined __cplusplus && 201103L <= __cplusplus
@@ -367,7 +368,7 @@ int yyparse ();
/* Copy the second part of user declarations. */
/* Line 390 of yacc.c */
-#line 371 "awkgram.c"
+#line 372 "awkgram.c"
#ifdef short
# undef short
@@ -731,25 +732,25 @@ static const yytype_int16 yyrhs[] =
/* YYRLINE[YYN] -- source line where rule number YYN was defined. */
static const yytype_uint16 yyrline[] =
{
- 0, 199, 199, 201, 206, 207, 213, 225, 229, 240,
- 246, 251, 259, 267, 269, 274, 282, 284, 290, 291,
- 293, 319, 330, 341, 347, 356, 366, 368, 370, 376,
- 381, 382, 386, 405, 404, 438, 440, 445, 446, 459,
- 464, 465, 469, 471, 473, 480, 570, 612, 654, 767,
- 774, 781, 791, 800, 809, 818, 829, 845, 844, 868,
- 880, 880, 978, 978, 1011, 1041, 1047, 1048, 1054, 1055,
- 1062, 1067, 1079, 1093, 1095, 1103, 1108, 1110, 1118, 1120,
- 1129, 1130, 1138, 1143, 1143, 1154, 1158, 1166, 1167, 1170,
- 1172, 1177, 1178, 1187, 1188, 1193, 1198, 1204, 1206, 1208,
- 1215, 1216, 1222, 1223, 1228, 1230, 1235, 1237, 1239, 1241,
- 1247, 1254, 1256, 1258, 1274, 1284, 1291, 1293, 1298, 1300,
- 1302, 1310, 1312, 1317, 1319, 1324, 1326, 1328, 1378, 1380,
- 1382, 1384, 1386, 1388, 1390, 1392, 1415, 1420, 1425, 1450,
- 1456, 1458, 1460, 1462, 1464, 1466, 1471, 1475, 1507, 1509,
- 1515, 1521, 1534, 1535, 1536, 1541, 1546, 1550, 1554, 1569,
- 1582, 1587, 1623, 1641, 1642, 1648, 1649, 1654, 1656, 1663,
- 1680, 1697, 1699, 1706, 1711, 1719, 1729, 1741, 1750, 1754,
- 1758, 1762, 1766, 1770, 1773, 1775, 1779, 1783, 1787
+ 0, 200, 200, 202, 207, 208, 214, 226, 230, 241,
+ 247, 252, 260, 268, 270, 275, 283, 285, 291, 292,
+ 294, 320, 331, 342, 348, 357, 367, 369, 371, 377,
+ 382, 383, 387, 406, 405, 439, 441, 446, 447, 460,
+ 465, 466, 470, 472, 474, 481, 571, 613, 655, 768,
+ 775, 782, 792, 801, 810, 819, 830, 846, 845, 869,
+ 881, 881, 979, 979, 1012, 1042, 1048, 1049, 1055, 1056,
+ 1063, 1068, 1080, 1094, 1096, 1104, 1109, 1111, 1119, 1121,
+ 1130, 1131, 1139, 1144, 1144, 1155, 1159, 1167, 1168, 1171,
+ 1173, 1178, 1179, 1188, 1189, 1194, 1199, 1205, 1207, 1209,
+ 1216, 1217, 1223, 1224, 1229, 1231, 1236, 1238, 1240, 1242,
+ 1248, 1255, 1257, 1259, 1275, 1285, 1292, 1294, 1299, 1301,
+ 1303, 1311, 1313, 1318, 1320, 1325, 1327, 1329, 1379, 1381,
+ 1383, 1385, 1387, 1389, 1391, 1393, 1416, 1421, 1426, 1451,
+ 1457, 1459, 1461, 1463, 1465, 1467, 1472, 1476, 1508, 1510,
+ 1516, 1522, 1535, 1536, 1537, 1542, 1547, 1551, 1555, 1570,
+ 1583, 1588, 1624, 1642, 1643, 1649, 1650, 1655, 1657, 1664,
+ 1681, 1698, 1700, 1707, 1712, 1720, 1730, 1742, 1751, 1755,
+ 1759, 1763, 1767, 1771, 1774, 1776, 1780, 1784, 1788
};
#endif
@@ -2036,7 +2037,7 @@ yyreduce:
{
case 3:
/* Line 1792 of yacc.c */
-#line 202 "awkgram.y"
+#line 203 "awkgram.y"
{
rule = 0;
yyerrok;
@@ -2045,7 +2046,7 @@ yyreduce:
case 5:
/* Line 1792 of yacc.c */
-#line 208 "awkgram.y"
+#line 209 "awkgram.y"
{
next_sourcefile();
if (sourcefile == srcfiles)
@@ -2055,7 +2056,7 @@ yyreduce:
case 6:
/* Line 1792 of yacc.c */
-#line 214 "awkgram.y"
+#line 215 "awkgram.y"
{
rule = 0;
/*
@@ -2068,7 +2069,7 @@ yyreduce:
case 7:
/* Line 1792 of yacc.c */
-#line 226 "awkgram.y"
+#line 227 "awkgram.y"
{
(void) append_rule((yyvsp[(1) - (2)]), (yyvsp[(2) - (2)]));
}
@@ -2076,7 +2077,7 @@ yyreduce:
case 8:
/* Line 1792 of yacc.c */
-#line 230 "awkgram.y"
+#line 231 "awkgram.y"
{
if (rule != Rule) {
msg(_("%s blocks must have an action part"), ruletab[rule]);
@@ -2091,7 +2092,7 @@ yyreduce:
case 9:
/* Line 1792 of yacc.c */
-#line 241 "awkgram.y"
+#line 242 "awkgram.y"
{
in_function = NULL;
(void) mk_function((yyvsp[(1) - (2)]), (yyvsp[(2) - (2)]));
@@ -2101,7 +2102,7 @@ yyreduce:
case 10:
/* Line 1792 of yacc.c */
-#line 247 "awkgram.y"
+#line 248 "awkgram.y"
{
want_source = false;
yyerrok;
@@ -2110,7 +2111,7 @@ yyreduce:
case 11:
/* Line 1792 of yacc.c */
-#line 252 "awkgram.y"
+#line 253 "awkgram.y"
{
want_source = false;
yyerrok;
@@ -2119,7 +2120,7 @@ yyreduce:
case 12:
/* Line 1792 of yacc.c */
-#line 260 "awkgram.y"
+#line 261 "awkgram.y"
{
if (include_source((yyvsp[(1) - (1)])) < 0)
YYABORT;
@@ -2131,19 +2132,19 @@ yyreduce:
case 13:
/* Line 1792 of yacc.c */
-#line 268 "awkgram.y"
+#line 269 "awkgram.y"
{ (yyval) = NULL; }
break;
case 14:
/* Line 1792 of yacc.c */
-#line 270 "awkgram.y"
+#line 271 "awkgram.y"
{ (yyval) = NULL; }
break;
case 15:
/* Line 1792 of yacc.c */
-#line 275 "awkgram.y"
+#line 276 "awkgram.y"
{
if (load_library((yyvsp[(1) - (1)])) < 0)
YYABORT;
@@ -2155,31 +2156,31 @@ yyreduce:
case 16:
/* Line 1792 of yacc.c */
-#line 283 "awkgram.y"
+#line 284 "awkgram.y"
{ (yyval) = NULL; }
break;
case 17:
/* Line 1792 of yacc.c */
-#line 285 "awkgram.y"
+#line 286 "awkgram.y"
{ (yyval) = NULL; }
break;
case 18:
/* Line 1792 of yacc.c */
-#line 290 "awkgram.y"
+#line 291 "awkgram.y"
{ (yyval) = NULL; rule = Rule; }
break;
case 19:
/* Line 1792 of yacc.c */
-#line 292 "awkgram.y"
+#line 293 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); rule = Rule; }
break;
case 20:
/* Line 1792 of yacc.c */
-#line 294 "awkgram.y"
+#line 295 "awkgram.y"
{
INSTRUCTION *tp;
@@ -2209,7 +2210,7 @@ yyreduce:
case 21:
/* Line 1792 of yacc.c */
-#line 320 "awkgram.y"
+#line 321 "awkgram.y"
{
static int begin_seen = 0;
if (do_lint_old && ++begin_seen == 2)
@@ -2224,7 +2225,7 @@ yyreduce:
case 22:
/* Line 1792 of yacc.c */
-#line 331 "awkgram.y"
+#line 332 "awkgram.y"
{
static int end_seen = 0;
if (do_lint_old && ++end_seen == 2)
@@ -2239,7 +2240,7 @@ yyreduce:
case 23:
/* Line 1792 of yacc.c */
-#line 342 "awkgram.y"
+#line 343 "awkgram.y"
{
(yyvsp[(1) - (1)])->in_rule = rule = BEGINFILE;
(yyvsp[(1) - (1)])->source_file = source;
@@ -2249,7 +2250,7 @@ yyreduce:
case 24:
/* Line 1792 of yacc.c */
-#line 348 "awkgram.y"
+#line 349 "awkgram.y"
{
(yyvsp[(1) - (1)])->in_rule = rule = ENDFILE;
(yyvsp[(1) - (1)])->source_file = source;
@@ -2259,7 +2260,7 @@ yyreduce:
case 25:
/* Line 1792 of yacc.c */
-#line 357 "awkgram.y"
+#line 358 "awkgram.y"
{
if ((yyvsp[(2) - (5)]) == NULL)
(yyval) = list_create(instruction(Op_no_op));
@@ -2270,19 +2271,19 @@ yyreduce:
case 26:
/* Line 1792 of yacc.c */
-#line 367 "awkgram.y"
+#line 368 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 27:
/* Line 1792 of yacc.c */
-#line 369 "awkgram.y"
+#line 370 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 28:
/* Line 1792 of yacc.c */
-#line 371 "awkgram.y"
+#line 372 "awkgram.y"
{
yyerror(_("`%s' is a built-in function, it cannot be redefined"),
tokstart);
@@ -2292,13 +2293,13 @@ yyreduce:
case 29:
/* Line 1792 of yacc.c */
-#line 377 "awkgram.y"
+#line 378 "awkgram.y"
{ (yyval) = (yyvsp[(2) - (2)]); }
break;
case 32:
/* Line 1792 of yacc.c */
-#line 387 "awkgram.y"
+#line 388 "awkgram.y"
{
(yyvsp[(1) - (6)])->source_file = source;
if (install_function((yyvsp[(2) - (6)])->lextok, (yyvsp[(1) - (6)]), (yyvsp[(4) - (6)])) < 0)
@@ -2313,13 +2314,13 @@ yyreduce:
case 33:
/* Line 1792 of yacc.c */
-#line 405 "awkgram.y"
+#line 406 "awkgram.y"
{ want_regexp = true; }
break;
case 34:
/* Line 1792 of yacc.c */
-#line 407 "awkgram.y"
+#line 408 "awkgram.y"
{
NODE *n, *exp;
char *re;
@@ -2352,19 +2353,19 @@ yyreduce:
case 35:
/* Line 1792 of yacc.c */
-#line 439 "awkgram.y"
+#line 440 "awkgram.y"
{ bcfree((yyvsp[(1) - (1)])); }
break;
case 37:
/* Line 1792 of yacc.c */
-#line 445 "awkgram.y"
+#line 446 "awkgram.y"
{ (yyval) = NULL; }
break;
case 38:
/* Line 1792 of yacc.c */
-#line 447 "awkgram.y"
+#line 448 "awkgram.y"
{
if ((yyvsp[(2) - (2)]) == NULL)
(yyval) = (yyvsp[(1) - (2)]);
@@ -2381,25 +2382,25 @@ yyreduce:
case 39:
/* Line 1792 of yacc.c */
-#line 460 "awkgram.y"
+#line 461 "awkgram.y"
{ (yyval) = NULL; }
break;
case 42:
/* Line 1792 of yacc.c */
-#line 470 "awkgram.y"
+#line 471 "awkgram.y"
{ (yyval) = NULL; }
break;
case 43:
/* Line 1792 of yacc.c */
-#line 472 "awkgram.y"
+#line 473 "awkgram.y"
{ (yyval) = (yyvsp[(2) - (3)]); }
break;
case 44:
/* Line 1792 of yacc.c */
-#line 474 "awkgram.y"
+#line 475 "awkgram.y"
{
if (do_pretty_print)
(yyval) = list_prepend((yyvsp[(1) - (1)]), instruction(Op_exec_count));
@@ -2410,7 +2411,7 @@ yyreduce:
case 45:
/* Line 1792 of yacc.c */
-#line 481 "awkgram.y"
+#line 482 "awkgram.y"
{
INSTRUCTION *dflt, *curr = NULL, *cexp, *cstmt;
INSTRUCTION *ip, *nextc, *tbreak;
@@ -2504,7 +2505,7 @@ yyreduce:
case 46:
/* Line 1792 of yacc.c */
-#line 571 "awkgram.y"
+#line 572 "awkgram.y"
{
/*
* -----------------
@@ -2550,7 +2551,7 @@ yyreduce:
case 47:
/* Line 1792 of yacc.c */
-#line 613 "awkgram.y"
+#line 614 "awkgram.y"
{
/*
* -----------------
@@ -2596,7 +2597,7 @@ yyreduce:
case 48:
/* Line 1792 of yacc.c */
-#line 655 "awkgram.y"
+#line 656 "awkgram.y"
{
INSTRUCTION *ip;
char *var_name = (yyvsp[(3) - (8)])->lextok;
@@ -2713,7 +2714,7 @@ regular_loop:
case 49:
/* Line 1792 of yacc.c */
-#line 768 "awkgram.y"
+#line 769 "awkgram.y"
{
(yyval) = mk_for_loop((yyvsp[(1) - (12)]), (yyvsp[(3) - (12)]), (yyvsp[(6) - (12)]), (yyvsp[(9) - (12)]), (yyvsp[(12) - (12)]));
@@ -2724,7 +2725,7 @@ regular_loop:
case 50:
/* Line 1792 of yacc.c */
-#line 775 "awkgram.y"
+#line 776 "awkgram.y"
{
(yyval) = mk_for_loop((yyvsp[(1) - (11)]), (yyvsp[(3) - (11)]), (INSTRUCTION *) NULL, (yyvsp[(8) - (11)]), (yyvsp[(11) - (11)]));
@@ -2735,7 +2736,7 @@ regular_loop:
case 51:
/* Line 1792 of yacc.c */
-#line 782 "awkgram.y"
+#line 783 "awkgram.y"
{
if (do_pretty_print)
(yyval) = list_prepend((yyvsp[(1) - (1)]), instruction(Op_exec_count));
@@ -2746,7 +2747,7 @@ regular_loop:
case 52:
/* Line 1792 of yacc.c */
-#line 792 "awkgram.y"
+#line 793 "awkgram.y"
{
if (! break_allowed)
error_ln((yyvsp[(1) - (2)])->source_line,
@@ -2759,7 +2760,7 @@ regular_loop:
case 53:
/* Line 1792 of yacc.c */
-#line 801 "awkgram.y"
+#line 802 "awkgram.y"
{
if (! continue_allowed)
error_ln((yyvsp[(1) - (2)])->source_line,
@@ -2772,7 +2773,7 @@ regular_loop:
case 54:
/* Line 1792 of yacc.c */
-#line 810 "awkgram.y"
+#line 811 "awkgram.y"
{
/* if inside function (rule = 0), resolve context at run-time */
if (rule && rule != Rule)
@@ -2785,7 +2786,7 @@ regular_loop:
case 55:
/* Line 1792 of yacc.c */
-#line 819 "awkgram.y"
+#line 820 "awkgram.y"
{
/* if inside function (rule = 0), resolve context at run-time */
if (rule == BEGIN || rule == END || rule == ENDFILE)
@@ -2800,7 +2801,7 @@ regular_loop:
case 56:
/* Line 1792 of yacc.c */
-#line 830 "awkgram.y"
+#line 831 "awkgram.y"
{
/* Initialize the two possible jump targets, the actual target
* is resolved at run-time.
@@ -2819,7 +2820,7 @@ regular_loop:
case 57:
/* Line 1792 of yacc.c */
-#line 845 "awkgram.y"
+#line 846 "awkgram.y"
{
if (! in_function)
yyerror(_("`return' used outside function context"));
@@ -2828,7 +2829,7 @@ regular_loop:
case 58:
/* Line 1792 of yacc.c */
-#line 848 "awkgram.y"
+#line 849 "awkgram.y"
{
if ((yyvsp[(3) - (4)]) == NULL) {
(yyval) = list_create((yyvsp[(1) - (4)]));
@@ -2853,13 +2854,13 @@ regular_loop:
case 60:
/* Line 1792 of yacc.c */
-#line 880 "awkgram.y"
+#line 881 "awkgram.y"
{ in_print = true; in_parens = 0; }
break;
case 61:
/* Line 1792 of yacc.c */
-#line 881 "awkgram.y"
+#line 882 "awkgram.y"
{
/*
* Optimization: plain `print' has no expression list, so $3 is null.
@@ -2960,13 +2961,13 @@ regular_print:
case 62:
/* Line 1792 of yacc.c */
-#line 978 "awkgram.y"
+#line 979 "awkgram.y"
{ sub_counter = 0; }
break;
case 63:
/* Line 1792 of yacc.c */
-#line 979 "awkgram.y"
+#line 980 "awkgram.y"
{
char *arr = (yyvsp[(2) - (4)])->lextok;
@@ -3003,7 +3004,7 @@ regular_print:
case 64:
/* Line 1792 of yacc.c */
-#line 1016 "awkgram.y"
+#line 1017 "awkgram.y"
{
static bool warned = false;
char *arr = (yyvsp[(3) - (4)])->lextok;
@@ -3033,31 +3034,31 @@ regular_print:
case 65:
/* Line 1792 of yacc.c */
-#line 1042 "awkgram.y"
+#line 1043 "awkgram.y"
{ (yyval) = optimize_assignment((yyvsp[(1) - (1)])); }
break;
case 66:
/* Line 1792 of yacc.c */
-#line 1047 "awkgram.y"
+#line 1048 "awkgram.y"
{ (yyval) = NULL; }
break;
case 67:
/* Line 1792 of yacc.c */
-#line 1049 "awkgram.y"
+#line 1050 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 68:
/* Line 1792 of yacc.c */
-#line 1054 "awkgram.y"
+#line 1055 "awkgram.y"
{ (yyval) = NULL; }
break;
case 69:
/* Line 1792 of yacc.c */
-#line 1056 "awkgram.y"
+#line 1057 "awkgram.y"
{
if ((yyvsp[(1) - (2)]) == NULL)
(yyval) = list_create((yyvsp[(2) - (2)]));
@@ -3068,13 +3069,13 @@ regular_print:
case 70:
/* Line 1792 of yacc.c */
-#line 1063 "awkgram.y"
+#line 1064 "awkgram.y"
{ (yyval) = NULL; }
break;
case 71:
/* Line 1792 of yacc.c */
-#line 1068 "awkgram.y"
+#line 1069 "awkgram.y"
{
INSTRUCTION *casestmt = (yyvsp[(5) - (5)]);
if ((yyvsp[(5) - (5)]) == NULL)
@@ -3090,7 +3091,7 @@ regular_print:
case 72:
/* Line 1792 of yacc.c */
-#line 1080 "awkgram.y"
+#line 1081 "awkgram.y"
{
INSTRUCTION *casestmt = (yyvsp[(4) - (4)]);
if ((yyvsp[(4) - (4)]) == NULL)
@@ -3105,13 +3106,13 @@ regular_print:
case 73:
/* Line 1792 of yacc.c */
-#line 1094 "awkgram.y"
+#line 1095 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 74:
/* Line 1792 of yacc.c */
-#line 1096 "awkgram.y"
+#line 1097 "awkgram.y"
{
NODE *n = (yyvsp[(2) - (2)])->memory;
(void) force_number(n);
@@ -3123,7 +3124,7 @@ regular_print:
case 75:
/* Line 1792 of yacc.c */
-#line 1104 "awkgram.y"
+#line 1105 "awkgram.y"
{
bcfree((yyvsp[(1) - (2)]));
(yyval) = (yyvsp[(2) - (2)]);
@@ -3132,13 +3133,13 @@ regular_print:
case 76:
/* Line 1792 of yacc.c */
-#line 1109 "awkgram.y"
+#line 1110 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 77:
/* Line 1792 of yacc.c */
-#line 1111 "awkgram.y"
+#line 1112 "awkgram.y"
{
(yyvsp[(1) - (1)])->opcode = Op_push_re;
(yyval) = (yyvsp[(1) - (1)]);
@@ -3147,19 +3148,19 @@ regular_print:
case 78:
/* Line 1792 of yacc.c */
-#line 1119 "awkgram.y"
+#line 1120 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 79:
/* Line 1792 of yacc.c */
-#line 1121 "awkgram.y"
+#line 1122 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 81:
/* Line 1792 of yacc.c */
-#line 1131 "awkgram.y"
+#line 1132 "awkgram.y"
{
(yyval) = (yyvsp[(2) - (3)]);
}
@@ -3167,7 +3168,7 @@ regular_print:
case 82:
/* Line 1792 of yacc.c */
-#line 1138 "awkgram.y"
+#line 1139 "awkgram.y"
{
in_print = false;
in_parens = 0;
@@ -3177,13 +3178,13 @@ regular_print:
case 83:
/* Line 1792 of yacc.c */
-#line 1143 "awkgram.y"
+#line 1144 "awkgram.y"
{ in_print = false; in_parens = 0; }
break;
case 84:
/* Line 1792 of yacc.c */
-#line 1144 "awkgram.y"
+#line 1145 "awkgram.y"
{
if ((yyvsp[(1) - (3)])->redir_type == redirect_twoway
&& (yyvsp[(3) - (3)])->lasti->opcode == Op_K_getline_redir
@@ -3195,7 +3196,7 @@ regular_print:
case 85:
/* Line 1792 of yacc.c */
-#line 1155 "awkgram.y"
+#line 1156 "awkgram.y"
{
(yyval) = mk_condition((yyvsp[(3) - (6)]), (yyvsp[(1) - (6)]), (yyvsp[(6) - (6)]), NULL, NULL);
}
@@ -3203,7 +3204,7 @@ regular_print:
case 86:
/* Line 1792 of yacc.c */
-#line 1160 "awkgram.y"
+#line 1161 "awkgram.y"
{
(yyval) = mk_condition((yyvsp[(3) - (9)]), (yyvsp[(1) - (9)]), (yyvsp[(6) - (9)]), (yyvsp[(7) - (9)]), (yyvsp[(9) - (9)]));
}
@@ -3211,13 +3212,13 @@ regular_print:
case 91:
/* Line 1792 of yacc.c */
-#line 1177 "awkgram.y"
+#line 1178 "awkgram.y"
{ (yyval) = NULL; }
break;
case 92:
/* Line 1792 of yacc.c */
-#line 1179 "awkgram.y"
+#line 1180 "awkgram.y"
{
bcfree((yyvsp[(1) - (2)]));
(yyval) = (yyvsp[(2) - (2)]);
@@ -3226,19 +3227,19 @@ regular_print:
case 93:
/* Line 1792 of yacc.c */
-#line 1187 "awkgram.y"
+#line 1188 "awkgram.y"
{ (yyval) = NULL; }
break;
case 94:
/* Line 1792 of yacc.c */
-#line 1189 "awkgram.y"
+#line 1190 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]) ; }
break;
case 95:
/* Line 1792 of yacc.c */
-#line 1194 "awkgram.y"
+#line 1195 "awkgram.y"
{
(yyvsp[(1) - (1)])->param_count = 0;
(yyval) = list_create((yyvsp[(1) - (1)]));
@@ -3247,7 +3248,7 @@ regular_print:
case 96:
/* Line 1792 of yacc.c */
-#line 1199 "awkgram.y"
+#line 1200 "awkgram.y"
{
(yyvsp[(3) - (3)])->param_count = (yyvsp[(1) - (3)])->lasti->param_count + 1;
(yyval) = list_append((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]));
@@ -3257,55 +3258,55 @@ regular_print:
case 97:
/* Line 1792 of yacc.c */
-#line 1205 "awkgram.y"
+#line 1206 "awkgram.y"
{ (yyval) = NULL; }
break;
case 98:
/* Line 1792 of yacc.c */
-#line 1207 "awkgram.y"
+#line 1208 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (2)]); }
break;
case 99:
/* Line 1792 of yacc.c */
-#line 1209 "awkgram.y"
+#line 1210 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (3)]); }
break;
case 100:
/* Line 1792 of yacc.c */
-#line 1215 "awkgram.y"
+#line 1216 "awkgram.y"
{ (yyval) = NULL; }
break;
case 101:
/* Line 1792 of yacc.c */
-#line 1217 "awkgram.y"
+#line 1218 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 102:
/* Line 1792 of yacc.c */
-#line 1222 "awkgram.y"
+#line 1223 "awkgram.y"
{ (yyval) = NULL; }
break;
case 103:
/* Line 1792 of yacc.c */
-#line 1224 "awkgram.y"
+#line 1225 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 104:
/* Line 1792 of yacc.c */
-#line 1229 "awkgram.y"
+#line 1230 "awkgram.y"
{ (yyval) = mk_expression_list(NULL, (yyvsp[(1) - (1)])); }
break;
case 105:
/* Line 1792 of yacc.c */
-#line 1231 "awkgram.y"
+#line 1232 "awkgram.y"
{
(yyval) = mk_expression_list((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]));
yyerrok;
@@ -3314,31 +3315,31 @@ regular_print:
case 106:
/* Line 1792 of yacc.c */
-#line 1236 "awkgram.y"
+#line 1237 "awkgram.y"
{ (yyval) = NULL; }
break;
case 107:
/* Line 1792 of yacc.c */
-#line 1238 "awkgram.y"
+#line 1239 "awkgram.y"
{ (yyval) = NULL; }
break;
case 108:
/* Line 1792 of yacc.c */
-#line 1240 "awkgram.y"
+#line 1241 "awkgram.y"
{ (yyval) = NULL; }
break;
case 109:
/* Line 1792 of yacc.c */
-#line 1242 "awkgram.y"
+#line 1243 "awkgram.y"
{ (yyval) = NULL; }
break;
case 110:
/* Line 1792 of yacc.c */
-#line 1248 "awkgram.y"
+#line 1249 "awkgram.y"
{
if (do_lint && (yyvsp[(3) - (3)])->lasti->opcode == Op_match_rec)
lintwarn_ln((yyvsp[(2) - (3)])->source_line,
@@ -3349,19 +3350,19 @@ regular_print:
case 111:
/* Line 1792 of yacc.c */
-#line 1255 "awkgram.y"
+#line 1256 "awkgram.y"
{ (yyval) = mk_boolean((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 112:
/* Line 1792 of yacc.c */
-#line 1257 "awkgram.y"
+#line 1258 "awkgram.y"
{ (yyval) = mk_boolean((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 113:
/* Line 1792 of yacc.c */
-#line 1259 "awkgram.y"
+#line 1260 "awkgram.y"
{
if ((yyvsp[(1) - (3)])->lasti->opcode == Op_match_rec)
warning_ln((yyvsp[(2) - (3)])->source_line,
@@ -3381,7 +3382,7 @@ regular_print:
case 114:
/* Line 1792 of yacc.c */
-#line 1275 "awkgram.y"
+#line 1276 "awkgram.y"
{
if (do_lint_old)
warning_ln((yyvsp[(2) - (3)])->source_line,
@@ -3395,7 +3396,7 @@ regular_print:
case 115:
/* Line 1792 of yacc.c */
-#line 1285 "awkgram.y"
+#line 1286 "awkgram.y"
{
if (do_lint && (yyvsp[(3) - (3)])->lasti->opcode == Op_match_rec)
lintwarn_ln((yyvsp[(2) - (3)])->source_line,
@@ -3406,31 +3407,31 @@ regular_print:
case 116:
/* Line 1792 of yacc.c */
-#line 1292 "awkgram.y"
+#line 1293 "awkgram.y"
{ (yyval) = mk_condition((yyvsp[(1) - (5)]), (yyvsp[(2) - (5)]), (yyvsp[(3) - (5)]), (yyvsp[(4) - (5)]), (yyvsp[(5) - (5)])); }
break;
case 117:
/* Line 1792 of yacc.c */
-#line 1294 "awkgram.y"
+#line 1295 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 118:
/* Line 1792 of yacc.c */
-#line 1299 "awkgram.y"
+#line 1300 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 119:
/* Line 1792 of yacc.c */
-#line 1301 "awkgram.y"
+#line 1302 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 120:
/* Line 1792 of yacc.c */
-#line 1303 "awkgram.y"
+#line 1304 "awkgram.y"
{
(yyvsp[(2) - (2)])->opcode = Op_assign_quotient;
(yyval) = (yyvsp[(2) - (2)]);
@@ -3439,43 +3440,43 @@ regular_print:
case 121:
/* Line 1792 of yacc.c */
-#line 1311 "awkgram.y"
+#line 1312 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 122:
/* Line 1792 of yacc.c */
-#line 1313 "awkgram.y"
+#line 1314 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 123:
/* Line 1792 of yacc.c */
-#line 1318 "awkgram.y"
+#line 1319 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 124:
/* Line 1792 of yacc.c */
-#line 1320 "awkgram.y"
+#line 1321 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 125:
/* Line 1792 of yacc.c */
-#line 1325 "awkgram.y"
+#line 1326 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 126:
/* Line 1792 of yacc.c */
-#line 1327 "awkgram.y"
+#line 1328 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 127:
/* Line 1792 of yacc.c */
-#line 1329 "awkgram.y"
+#line 1330 "awkgram.y"
{
int count = 2;
bool is_simple_var = false;
@@ -3526,43 +3527,43 @@ regular_print:
case 129:
/* Line 1792 of yacc.c */
-#line 1381 "awkgram.y"
+#line 1382 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 130:
/* Line 1792 of yacc.c */
-#line 1383 "awkgram.y"
+#line 1384 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 131:
/* Line 1792 of yacc.c */
-#line 1385 "awkgram.y"
+#line 1386 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 132:
/* Line 1792 of yacc.c */
-#line 1387 "awkgram.y"
+#line 1388 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 133:
/* Line 1792 of yacc.c */
-#line 1389 "awkgram.y"
+#line 1390 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 134:
/* Line 1792 of yacc.c */
-#line 1391 "awkgram.y"
+#line 1392 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 135:
/* Line 1792 of yacc.c */
-#line 1393 "awkgram.y"
+#line 1394 "awkgram.y"
{
/*
* In BEGINFILE/ENDFILE, allow `getline var < file'
@@ -3589,7 +3590,7 @@ regular_print:
case 136:
/* Line 1792 of yacc.c */
-#line 1416 "awkgram.y"
+#line 1417 "awkgram.y"
{
(yyvsp[(2) - (2)])->opcode = Op_postincrement;
(yyval) = mk_assignment((yyvsp[(1) - (2)]), NULL, (yyvsp[(2) - (2)]));
@@ -3598,7 +3599,7 @@ regular_print:
case 137:
/* Line 1792 of yacc.c */
-#line 1421 "awkgram.y"
+#line 1422 "awkgram.y"
{
(yyvsp[(2) - (2)])->opcode = Op_postdecrement;
(yyval) = mk_assignment((yyvsp[(1) - (2)]), NULL, (yyvsp[(2) - (2)]));
@@ -3607,7 +3608,7 @@ regular_print:
case 138:
/* Line 1792 of yacc.c */
-#line 1426 "awkgram.y"
+#line 1427 "awkgram.y"
{
if (do_lint_old) {
warning_ln((yyvsp[(4) - (5)])->source_line,
@@ -3631,7 +3632,7 @@ regular_print:
case 139:
/* Line 1792 of yacc.c */
-#line 1451 "awkgram.y"
+#line 1452 "awkgram.y"
{
(yyval) = mk_getline((yyvsp[(3) - (4)]), (yyvsp[(4) - (4)]), (yyvsp[(1) - (4)]), (yyvsp[(2) - (4)])->redir_type);
bcfree((yyvsp[(2) - (4)]));
@@ -3640,43 +3641,43 @@ regular_print:
case 140:
/* Line 1792 of yacc.c */
-#line 1457 "awkgram.y"
+#line 1458 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 141:
/* Line 1792 of yacc.c */
-#line 1459 "awkgram.y"
+#line 1460 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 142:
/* Line 1792 of yacc.c */
-#line 1461 "awkgram.y"
+#line 1462 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 143:
/* Line 1792 of yacc.c */
-#line 1463 "awkgram.y"
+#line 1464 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 144:
/* Line 1792 of yacc.c */
-#line 1465 "awkgram.y"
+#line 1466 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 145:
/* Line 1792 of yacc.c */
-#line 1467 "awkgram.y"
+#line 1468 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 146:
/* Line 1792 of yacc.c */
-#line 1472 "awkgram.y"
+#line 1473 "awkgram.y"
{
(yyval) = list_create((yyvsp[(1) - (1)]));
}
@@ -3684,7 +3685,7 @@ regular_print:
case 147:
/* Line 1792 of yacc.c */
-#line 1476 "awkgram.y"
+#line 1477 "awkgram.y"
{
if ((yyvsp[(2) - (2)])->opcode == Op_match_rec) {
(yyvsp[(2) - (2)])->opcode = Op_nomatch;
@@ -3720,13 +3721,13 @@ regular_print:
case 148:
/* Line 1792 of yacc.c */
-#line 1508 "awkgram.y"
+#line 1509 "awkgram.y"
{ (yyval) = (yyvsp[(2) - (3)]); }
break;
case 149:
/* Line 1792 of yacc.c */
-#line 1510 "awkgram.y"
+#line 1511 "awkgram.y"
{
(yyval) = snode((yyvsp[(3) - (4)]), (yyvsp[(1) - (4)]));
if ((yyval) == NULL)
@@ -3736,7 +3737,7 @@ regular_print:
case 150:
/* Line 1792 of yacc.c */
-#line 1516 "awkgram.y"
+#line 1517 "awkgram.y"
{
(yyval) = snode((yyvsp[(3) - (4)]), (yyvsp[(1) - (4)]));
if ((yyval) == NULL)
@@ -3746,7 +3747,7 @@ regular_print:
case 151:
/* Line 1792 of yacc.c */
-#line 1522 "awkgram.y"
+#line 1523 "awkgram.y"
{
static bool warned = false;
@@ -3763,7 +3764,7 @@ regular_print:
case 154:
/* Line 1792 of yacc.c */
-#line 1537 "awkgram.y"
+#line 1538 "awkgram.y"
{
(yyvsp[(1) - (2)])->opcode = Op_preincrement;
(yyval) = mk_assignment((yyvsp[(2) - (2)]), NULL, (yyvsp[(1) - (2)]));
@@ -3772,7 +3773,7 @@ regular_print:
case 155:
/* Line 1792 of yacc.c */
-#line 1542 "awkgram.y"
+#line 1543 "awkgram.y"
{
(yyvsp[(1) - (2)])->opcode = Op_predecrement;
(yyval) = mk_assignment((yyvsp[(2) - (2)]), NULL, (yyvsp[(1) - (2)]));
@@ -3781,7 +3782,7 @@ regular_print:
case 156:
/* Line 1792 of yacc.c */
-#line 1547 "awkgram.y"
+#line 1548 "awkgram.y"
{
(yyval) = list_create((yyvsp[(1) - (1)]));
}
@@ -3789,7 +3790,7 @@ regular_print:
case 157:
/* Line 1792 of yacc.c */
-#line 1551 "awkgram.y"
+#line 1552 "awkgram.y"
{
(yyval) = list_create((yyvsp[(1) - (1)]));
}
@@ -3797,7 +3798,7 @@ regular_print:
case 158:
/* Line 1792 of yacc.c */
-#line 1555 "awkgram.y"
+#line 1556 "awkgram.y"
{
if ((yyvsp[(2) - (2)])->lasti->opcode == Op_push_i
&& ((yyvsp[(2) - (2)])->lasti->memory->flags & (STRCUR|STRING)) == 0
@@ -3816,7 +3817,7 @@ regular_print:
case 159:
/* Line 1792 of yacc.c */
-#line 1570 "awkgram.y"
+#line 1571 "awkgram.y"
{
/*
* was: $$ = $2
@@ -3830,7 +3831,7 @@ regular_print:
case 160:
/* Line 1792 of yacc.c */
-#line 1583 "awkgram.y"
+#line 1584 "awkgram.y"
{
func_use((yyvsp[(1) - (1)])->lasti->func_name, FUNC_USE);
(yyval) = (yyvsp[(1) - (1)]);
@@ -3839,7 +3840,7 @@ regular_print:
case 161:
/* Line 1792 of yacc.c */
-#line 1588 "awkgram.y"
+#line 1589 "awkgram.y"
{
/* indirect function call */
INSTRUCTION *f, *t;
@@ -3876,7 +3877,7 @@ regular_print:
case 162:
/* Line 1792 of yacc.c */
-#line 1624 "awkgram.y"
+#line 1625 "awkgram.y"
{
param_sanity((yyvsp[(3) - (4)]));
(yyvsp[(1) - (4)])->opcode = Op_func_call;
@@ -3894,37 +3895,37 @@ regular_print:
case 163:
/* Line 1792 of yacc.c */
-#line 1641 "awkgram.y"
+#line 1642 "awkgram.y"
{ (yyval) = NULL; }
break;
case 164:
/* Line 1792 of yacc.c */
-#line 1643 "awkgram.y"
+#line 1644 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 165:
/* Line 1792 of yacc.c */
-#line 1648 "awkgram.y"
+#line 1649 "awkgram.y"
{ (yyval) = NULL; }
break;
case 166:
/* Line 1792 of yacc.c */
-#line 1650 "awkgram.y"
+#line 1651 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (2)]); }
break;
case 167:
/* Line 1792 of yacc.c */
-#line 1655 "awkgram.y"
+#line 1656 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 168:
/* Line 1792 of yacc.c */
-#line 1657 "awkgram.y"
+#line 1658 "awkgram.y"
{
(yyval) = list_merge((yyvsp[(1) - (2)]), (yyvsp[(2) - (2)]));
}
@@ -3932,7 +3933,7 @@ regular_print:
case 169:
/* Line 1792 of yacc.c */
-#line 1664 "awkgram.y"
+#line 1665 "awkgram.y"
{
INSTRUCTION *ip = (yyvsp[(1) - (1)])->lasti;
int count = ip->sub_count; /* # of SUBSEP-seperated expressions */
@@ -3950,7 +3951,7 @@ regular_print:
case 170:
/* Line 1792 of yacc.c */
-#line 1681 "awkgram.y"
+#line 1682 "awkgram.y"
{
INSTRUCTION *t = (yyvsp[(2) - (3)]);
if ((yyvsp[(2) - (3)]) == NULL) {
@@ -3968,13 +3969,13 @@ regular_print:
case 171:
/* Line 1792 of yacc.c */
-#line 1698 "awkgram.y"
+#line 1699 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 172:
/* Line 1792 of yacc.c */
-#line 1700 "awkgram.y"
+#line 1701 "awkgram.y"
{
(yyval) = list_merge((yyvsp[(1) - (2)]), (yyvsp[(2) - (2)]));
}
@@ -3982,13 +3983,13 @@ regular_print:
case 173:
/* Line 1792 of yacc.c */
-#line 1707 "awkgram.y"
+#line 1708 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (2)]); }
break;
case 174:
/* Line 1792 of yacc.c */
-#line 1712 "awkgram.y"
+#line 1713 "awkgram.y"
{
char *var_name = (yyvsp[(1) - (1)])->lextok;
@@ -4000,7 +4001,7 @@ regular_print:
case 175:
/* Line 1792 of yacc.c */
-#line 1720 "awkgram.y"
+#line 1721 "awkgram.y"
{
char *arr = (yyvsp[(1) - (2)])->lextok;
(yyvsp[(1) - (2)])->memory = variable((yyvsp[(1) - (2)])->source_line, arr, Node_var_new);
@@ -4011,7 +4012,7 @@ regular_print:
case 176:
/* Line 1792 of yacc.c */
-#line 1730 "awkgram.y"
+#line 1731 "awkgram.y"
{
INSTRUCTION *ip = (yyvsp[(1) - (1)])->nexti;
if (ip->opcode == Op_push
@@ -4027,7 +4028,7 @@ regular_print:
case 177:
/* Line 1792 of yacc.c */
-#line 1742 "awkgram.y"
+#line 1743 "awkgram.y"
{
(yyval) = list_append((yyvsp[(2) - (3)]), (yyvsp[(1) - (3)]));
if ((yyvsp[(3) - (3)]) != NULL)
@@ -4037,7 +4038,7 @@ regular_print:
case 178:
/* Line 1792 of yacc.c */
-#line 1751 "awkgram.y"
+#line 1752 "awkgram.y"
{
(yyvsp[(1) - (1)])->opcode = Op_postincrement;
}
@@ -4045,7 +4046,7 @@ regular_print:
case 179:
/* Line 1792 of yacc.c */
-#line 1755 "awkgram.y"
+#line 1756 "awkgram.y"
{
(yyvsp[(1) - (1)])->opcode = Op_postdecrement;
}
@@ -4053,43 +4054,43 @@ regular_print:
case 180:
/* Line 1792 of yacc.c */
-#line 1758 "awkgram.y"
+#line 1759 "awkgram.y"
{ (yyval) = NULL; }
break;
case 182:
/* Line 1792 of yacc.c */
-#line 1766 "awkgram.y"
+#line 1767 "awkgram.y"
{ yyerrok; }
break;
case 183:
/* Line 1792 of yacc.c */
-#line 1770 "awkgram.y"
+#line 1771 "awkgram.y"
{ yyerrok; }
break;
case 186:
/* Line 1792 of yacc.c */
-#line 1779 "awkgram.y"
+#line 1780 "awkgram.y"
{ yyerrok; }
break;
case 187:
/* Line 1792 of yacc.c */
-#line 1783 "awkgram.y"
+#line 1784 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); yyerrok; }
break;
case 188:
/* Line 1792 of yacc.c */
-#line 1787 "awkgram.y"
+#line 1788 "awkgram.y"
{ yyerrok; }
break;
/* Line 1792 of yacc.c */
-#line 4105 "awkgram.c"
+#line 4106 "awkgram.c"
default: break;
}
/* User semantic actions sometimes alter yychar, and that requires
@@ -4321,7 +4322,7 @@ yyreturn:
/* Line 2055 of yacc.c */
-#line 1789 "awkgram.y"
+#line 1790 "awkgram.y"
struct token {
@@ -4409,7 +4410,7 @@ static const struct token tokentab[] = {
{"gsub", Op_sub_builtin, LEX_BUILTIN, NOT_OLD|A(2)|A(3), 0, 0},
{"if", Op_K_if, LEX_IF, 0, 0, 0},
{"in", Op_symbol, LEX_IN, 0, 0, 0},
-{"include", Op_symbol, LEX_INCLUDE, GAWKX, 0, 0},
+{"include", Op_symbol, LEX_INCLUDE, GAWKX, 0, 0},
{"index", Op_builtin, LEX_BUILTIN, A(2), do_index, 0},
{"int", Op_builtin, LEX_BUILTIN, A(1), do_int, MPF(int)},
{"isarray", Op_builtin, LEX_BUILTIN, GAWKX|A(1), do_isarray, 0},
@@ -6728,7 +6729,7 @@ install_function(char *fname, INSTRUCTION *fi, INSTRUCTION *plist)
int pcount = 0;
r = lookup(fname);
- if (r != NULL) {
+ if (r != NULL || is_deferred_variable(fname)) {
error_ln(fi->source_line, _("function name `%s' previously defined"), fname);
return -1;
}
@@ -6958,6 +6959,19 @@ register_deferred_variable(const char *name, NODE *(*load_func)(void))
deferred_variables = dv;
}
+/* is_deferred_variable --- check if NAME is a deferred variable */
+
+static bool
+is_deferred_variable(const char *name)
+{
+ struct deferred_variable *dv;
+ for (dv = deferred_variables; dv != NULL; dv = dv->next)
+ if (strcmp(name, dv->name) == 0)
+ return true;
+ return false;
+}
+
+
/* variable --- make sure NAME is in the symbol table */
NODE *
diff --git a/awkgram.y b/awkgram.y
index b1574c88..6a707cbc 100644
--- a/awkgram.y
+++ b/awkgram.y
@@ -57,6 +57,7 @@ static int include_source(INSTRUCTION *file);
static int load_library(INSTRUCTION *file);
static void next_sourcefile(void);
static char *tokexpand(void);
+static bool is_deferred_variable(const char *name);
#define instruction(t) bcalloc(t, 1, 0)
@@ -1873,7 +1874,7 @@ static const struct token tokentab[] = {
{"gsub", Op_sub_builtin, LEX_BUILTIN, NOT_OLD|A(2)|A(3), 0, 0},
{"if", Op_K_if, LEX_IF, 0, 0, 0},
{"in", Op_symbol, LEX_IN, 0, 0, 0},
-{"include", Op_symbol, LEX_INCLUDE, GAWKX, 0, 0},
+{"include", Op_symbol, LEX_INCLUDE, GAWKX, 0, 0},
{"index", Op_builtin, LEX_BUILTIN, A(2), do_index, 0},
{"int", Op_builtin, LEX_BUILTIN, A(1), do_int, MPF(int)},
{"isarray", Op_builtin, LEX_BUILTIN, GAWKX|A(1), do_isarray, 0},
@@ -4192,7 +4193,7 @@ install_function(char *fname, INSTRUCTION *fi, INSTRUCTION *plist)
int pcount = 0;
r = lookup(fname);
- if (r != NULL) {
+ if (r != NULL || is_deferred_variable(fname)) {
error_ln(fi->source_line, _("function name `%s' previously defined"), fname);
return -1;
}
@@ -4422,6 +4423,19 @@ register_deferred_variable(const char *name, NODE *(*load_func)(void))
deferred_variables = dv;
}
+/* is_deferred_variable --- check if NAME is a deferred variable */
+
+static bool
+is_deferred_variable(const char *name)
+{
+ struct deferred_variable *dv;
+ for (dv = deferred_variables; dv != NULL; dv = dv->next)
+ if (strcmp(name, dv->name) == 0)
+ return true;
+ return false;
+}
+
+
/* variable --- make sure NAME is in the symbol table */
NODE *
diff --git a/awklib/ChangeLog b/awklib/ChangeLog
index 1be7b4b7..1948c564 100644
--- a/awklib/ChangeLog
+++ b/awklib/ChangeLog
@@ -1,3 +1,7 @@
+2012-12-23 Arnold D. Robbins <arnold@skeeve.com>
+
+ * 4.0.2: Release tar ball made.
+
2012-03-28 Arnold D. Robbins <arnold@skeeve.com>
* 4.0.1: Release tar ball made.
diff --git a/builtin.c b/builtin.c
index 07169a3d..09a3287f 100644
--- a/builtin.c
+++ b/builtin.c
@@ -1582,6 +1582,9 @@ printf_common(int nargs)
int i;
NODE *r, *tmp;
+ if (nargs == 0)
+ fatal(_("[s]printf called with no arguments"));
+
assert(nargs <= max_args);
for (i = 1; i <= nargs; i++) {
tmp = args_array[nargs - i] = POP();
diff --git a/doc/ChangeLog b/doc/ChangeLog
index 0e0b806d..b5552676 100644
--- a/doc/ChangeLog
+++ b/doc/ChangeLog
@@ -1,3 +1,12 @@
+2012-12-23 Arnold D. Robbins <arnold@skeeve.com>
+
+ * 4.0.2: Release tar ball made.
+
+2012-12-23 Arnold D. Robbins <arnold@skeeve.com>
+
+ * gawk.texi: Remove an incorrect comment.
+ * awkcard.in: Bump patch level.
+
2012-12-18 Arnold D. Robbins <arnold@skeeve.com>
* gawk.texi (Input Parsers): Add info on read_func.
diff --git a/doc/awkcard.in b/doc/awkcard.in
index 9df71344..714b5441 100644
--- a/doc/awkcard.in
+++ b/doc/awkcard.in
@@ -1935,7 +1935,7 @@ to use the current domain.\*(CB
.ES
.nf
\*(CDHost: \*(FCftp.gnu.org\*(FR
-File: \*(FC/gnu/gawk/gawk-4.0.1.tar.gz\fP
+File: \*(FC/gnu/gawk/gawk-4.0.2.tar.gz\fP
.in +.2i
.fi
GNU \*(AK (\*(GK). There may be a later version.
diff --git a/extension/ChangeLog b/extension/ChangeLog
index da24b788..73b64fb6 100644
--- a/extension/ChangeLog
+++ b/extension/ChangeLog
@@ -1,3 +1,7 @@
+2012-12-23 Arnold D. Robbins <arnold@skeeve.com>
+
+ * 4.0.2: Release tar ball made.
+
2012-12-19 Arnold D. Robbins <arnold@skeeve.com>
* testext.c (test_indirect_vars): New test and awk code.
diff --git a/interpret.h b/interpret.h
index c652624a..8e0fdee0 100644
--- a/interpret.h
+++ b/interpret.h
@@ -140,8 +140,13 @@ top:
if (m->type == Node_param_list) {
isparam = true;
save_symbol = m = GET_PARAM(m->param_cnt);
- if (m->type == Node_array_ref)
+ if (m->type == Node_array_ref) {
+ if (m->orig_array->type == Node_var) {
+ /* gawk 'func f(x) { a = 10; print x; } BEGIN{ f(a) }' */
+ goto uninitialized_scalar;
+ }
m = m->orig_array;
+ }
}
switch (m->type) {
@@ -157,6 +162,7 @@ top:
break;
case Node_var_new:
+uninitialized_scalar:
m->type = Node_var;
m->var_value = dupnode(Nnull_string);
if (do_lint)
diff --git a/m4/ChangeLog b/m4/ChangeLog
index 8489f90e..8af73a26 100644
--- a/m4/ChangeLog
+++ b/m4/ChangeLog
@@ -1,3 +1,7 @@
+2012-12-23 Arnold D. Robbins <arnold@skeeve.com>
+
+ * 4.0.2: Release tar ball made.
+
2012-10-27 Arnold D. Robbins <arnold@skeeve.com>
* po.m4, intl.m4: Fix droppings left over from a git merge.
diff --git a/missing_d/ChangeLog b/missing_d/ChangeLog
index cb797470..15c44a61 100644
--- a/missing_d/ChangeLog
+++ b/missing_d/ChangeLog
@@ -1,3 +1,7 @@
+2012-12-23 Arnold D. Robbins <arnold@skeeve.com>
+
+ * 4.0.2: Release tar ball made.
+
2012-09-13 Arnold D. Robbins <arnold@skeeve.com>
* snprintf.c, strtoul.c: Remove TRUE/FALSE in favor of true/false.
diff --git a/pc/ChangeLog b/pc/ChangeLog
index 0a53226e..fc7a521d 100644
--- a/pc/ChangeLog
+++ b/pc/ChangeLog
@@ -1,3 +1,11 @@
+2012-12-23 Arnold D. Robbins <arnold@skeeve.com>
+
+ * Makefile.tst (paramuninitglobal): New test.
+
+ And then:
+
+ * 4.0.2: Release tar ball made.
+
2012-11-22 Eli Zaretskii <eliz@gnu.org>
* Makefile.tst (jarebug): Update.
diff --git a/pc/Makefile.tst b/pc/Makefile.tst
index 4f7e06b0..05515a58 100644
--- a/pc/Makefile.tst
+++ b/pc/Makefile.tst
@@ -152,7 +152,7 @@ BASIC_TESTS = \
nlinstr nlstrina noeffect nofile nofmtch noloop1 noloop2 nonl \
noparms nors nulrsend numindex numsubstr \
octsub ofmt ofmta ofmtbig ofmtfidl ofmts ofs1 onlynl opasnidx opasnslf \
- paramdup paramres paramtyp parse1 parsefld parseme pcntplus \
+ paramdup paramres paramtyp paramuninitglobal parse1 parsefld parseme pcntplus \
posix2008sub prdupval prec printf0 printf1 prmarscl prmreuse \
prt1eval prtoeval \
rand range1 rebt8b1 redfilnm regeq regexprange regrange \
@@ -1458,6 +1458,11 @@ paramtyp:
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+paramuninitglobal:
+ @echo paramuninitglobal
+ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
parse1:
@echo parse1
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
diff --git a/po/ChangeLog b/po/ChangeLog
index 91cbd991..c0ab096c 100644
--- a/po/ChangeLog
+++ b/po/ChangeLog
@@ -1,3 +1,7 @@
+2012-12-23 Arnold D. Robbins <arnold@skeeve.com>
+
+ * 4.0.2: Release tar ball made.
+
2012-07-25 Arnold D. Robbins <arnold@skeeve.com>
* POTFILES.in: Brought up to date.
diff --git a/po/gawk.pot b/po/gawk.pot
index 5ff6a02d..c03b7eff 100644
--- a/po/gawk.pot
+++ b/po/gawk.pot
@@ -6,9 +6,15 @@
#, fuzzy
msgid ""
msgstr ""
+<<<<<<< HEAD
"Project-Id-Version: gawk 4.0.71\n"
"Report-Msgid-Bugs-To: arnold@skeeve.com\n"
"POT-Creation-Date: 2012-12-15 21:58+0200\n"
+=======
+"Project-Id-Version: gawk 4.0.2\n"
+"Report-Msgid-Bugs-To: arnold@skeeve.com\n"
+"POT-Creation-Date: 2012-12-23 14:16+0200\n"
+>>>>>>> gawk-4.0-stable
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -36,9 +42,15 @@ msgstr ""
msgid "attempt to use scalar `%s' as an array"
msgstr ""
+<<<<<<< HEAD
#: array.c:404 array.c:570 builtin.c:85 builtin.c:1582 builtin.c:1624
#: builtin.c:1637 builtin.c:2063 builtin.c:2075 eval.c:1118 eval.c:1122
#: eval.c:1519
+=======
+#: array.c:302 array.c:707 builtin.c:84 builtin.c:1404 builtin.c:1446
+#: builtin.c:1459 builtin.c:1878 builtin.c:1890 eval.c:1135 eval.c:1139
+#: eval.c:1495 eval.c:1818
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "attempt to use array `%s' in a scalar context"
msgstr ""
@@ -48,7 +60,11 @@ msgstr ""
msgid "delete: index `%s' not in array `%s'"
msgstr ""
+<<<<<<< HEAD
#: array.c:591
+=======
+#: array.c:734 eval.c:1871
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "attempt to use scalar `%s[\"%.*s\"]' as an array"
msgstr ""
@@ -99,11 +115,16 @@ msgstr ""
msgid "sort comparison function `%s' is not defined"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:230
+=======
+#: awkgram.y:250
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "%s blocks must have an action part"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:233
msgid "each rule must have a pattern or an action part"
msgstr ""
@@ -113,24 +134,48 @@ msgid "old awk does not support multiple `BEGIN' or `END' rules"
msgstr ""
#: awkgram.y:370
+=======
+#: awkgram.y:253
+msgid "each rule must have a pattern or an action part"
+msgstr ""
+
+#: awkgram.y:324 awkgram.y:335
+msgid "old awk does not support multiple `BEGIN' or `END' rules"
+msgstr ""
+
+#: awkgram.y:372
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "`%s' is a built-in function, it cannot be redefined"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:416
msgid "regexp constant `//' looks like a C++ comment, but is not"
msgstr ""
#: awkgram.y:420
+=======
+#: awkgram.y:433
+msgid "regexp constant `//' looks like a C++ comment, but is not"
+msgstr ""
+
+#: awkgram.y:437
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "regexp constant `/%s/' looks like a C comment, but is not"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:512
+=======
+#: awkgram.y:529
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "duplicate case values in switch body: %s"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:533
msgid "duplicate `default' detected in switch body"
msgstr ""
@@ -144,15 +189,35 @@ msgid "`continue' is not allowed outside a loop"
msgstr ""
#: awkgram.y:812
+=======
+#: awkgram.y:550
+msgid "duplicate `default' detected in switch body"
+msgstr ""
+
+#: awkgram.y:810
+msgid "`break' is not allowed outside a loop or switch"
+msgstr ""
+
+#: awkgram.y:819
+msgid "`continue' is not allowed outside a loop"
+msgstr ""
+
+#: awkgram.y:829
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "`next' used in %s action"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:821
+=======
+#: awkgram.y:838
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "`nextfile' used in %s action"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:845
msgid "`return' used outside function context"
msgstr ""
@@ -194,15 +259,55 @@ msgid "regular expression on right of comparison"
msgstr ""
#: awkgram.y:1402
+=======
+#: awkgram.y:862
+msgid "`return' used outside function context"
+msgstr ""
+
+#: awkgram.y:922
+msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'"
+msgstr ""
+
+#: awkgram.y:1017 awkgram.y:1021
+msgid "`delete(array)' is a non-portable tawk extension"
+msgstr ""
+
+#: awkgram.y:1133
+msgid "multistage two-way pipelines don't work"
+msgstr ""
+
+#: awkgram.y:1236
+msgid "regular expression on right of assignment"
+msgstr ""
+
+#: awkgram.y:1247
+msgid "regular expression on left of `~' or `!~' operator"
+msgstr ""
+
+#: awkgram.y:1263 awkgram.y:1417
+msgid "old awk does not support the keyword `in' except after `for'"
+msgstr ""
+
+#: awkgram.y:1273
+msgid "regular expression on right of comparison"
+msgstr ""
+
+#: awkgram.y:1392
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "`getline var' invalid inside `%s' rule"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:1405
+=======
+#: awkgram.y:1395 eval.c:2522
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "`getline' invalid inside `%s' rule"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:1410
msgid "non-redirected `getline' undefined inside END action"
msgstr ""
@@ -220,10 +325,30 @@ msgid "indirect function calls are a gawk extension"
msgstr ""
#: awkgram.y:1605
+=======
+#: awkgram.y:1400
+msgid "non-redirected `getline' undefined inside END action"
+msgstr ""
+
+#: awkgram.y:1419
+msgid "old awk does not support multidimensional arrays"
+msgstr ""
+
+#: awkgram.y:1515
+msgid "call of `length' without parentheses is not portable"
+msgstr ""
+
+#: awkgram.y:1578
+msgid "indirect function calls are a gawk extension"
+msgstr ""
+
+#: awkgram.y:1591
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "can not use special variable `%s' for indirect function call"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:1683
msgid "invalid subscript expression"
msgstr ""
@@ -242,10 +367,34 @@ msgstr ""
#: awkgram.y:2341 awkgram.y:2417 awkgram.y:2640 debug.c:517 debug.c:533
#: debug.c:2790 debug.c:5038
+=======
+#: awkgram.y:1669
+msgid "invalid subscript expression"
+msgstr ""
+
+#: awkgram.y:1709
+msgid "use of non-array as array"
+msgstr ""
+
+#: awkgram.y:1972 awkgram.y:1992 msg.c:98
+msgid "warning: "
+msgstr ""
+
+#: awkgram.y:1990 msg.c:130
+msgid "fatal: "
+msgstr ""
+
+#: awkgram.y:2040
+msgid "unexpected newline or end of string"
+msgstr ""
+
+#: awkgram.y:2297 awkgram.y:2355 awkgram.y:2539
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "can't open source file `%s' for reading (%s)"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:2342 awkgram.y:2467
#, c-format
msgid "can't open shared library `%s' for reading (%s)"
@@ -261,10 +410,18 @@ msgid "can't include `%s' and use it as a program file"
msgstr ""
#: awkgram.y:2366
+=======
+#: awkgram.y:2298 awkgram.y:2356 builtin.c:122
+msgid "reason unknown"
+msgstr ""
+
+#: awkgram.y:2314
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "already included source file `%s'"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:2367
#, c-format
msgid "already loaded shared library `%s'"
@@ -291,15 +448,35 @@ msgid "empty program text on command line"
msgstr ""
#: awkgram.y:2707
+=======
+#: awkgram.y:2340
+msgid "@include is a gawk extension"
+msgstr ""
+
+#: awkgram.y:2346
+msgid "empty filename after @include"
+msgstr ""
+
+#: awkgram.y:2491
+msgid "empty program text on command line"
+msgstr ""
+
+#: awkgram.y:2606
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "can't read sourcefile `%s' (%s)"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:2718
+=======
+#: awkgram.y:2617
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "source file `%s' is empty"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:2895
msgid "source file does not end in newline"
msgstr ""
@@ -309,15 +486,31 @@ msgid "unterminated regexp ends with `\\' at end of file"
msgstr ""
#: awkgram.y:3024
+=======
+#: awkgram.y:2794
+msgid "source file does not end in newline"
+msgstr ""
+
+#: awkgram.y:2897
+msgid "unterminated regexp ends with `\\' at end of file"
+msgstr ""
+
+#: awkgram.y:2921
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "%s: %d: tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:3028
+=======
+#: awkgram.y:2925
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:3035
msgid "unterminated regexp"
msgstr ""
@@ -363,44 +556,120 @@ msgid "unterminated string"
msgstr ""
#: awkgram.y:3561
+=======
+#: awkgram.y:2932
+msgid "unterminated regexp"
+msgstr ""
+
+#: awkgram.y:2936
+msgid "unterminated regexp at end of file"
+msgstr ""
+
+#: awkgram.y:2995
+msgid "use of `\\ #...' line continuation is not portable"
+msgstr ""
+
+#: awkgram.y:3011
+msgid "backslash not last character on line"
+msgstr ""
+
+#: awkgram.y:3072
+msgid "POSIX does not allow operator `**='"
+msgstr ""
+
+#: awkgram.y:3074
+msgid "old awk does not support operator `**='"
+msgstr ""
+
+#: awkgram.y:3083
+msgid "POSIX does not allow operator `**'"
+msgstr ""
+
+#: awkgram.y:3085
+msgid "old awk does not support operator `**'"
+msgstr ""
+
+#: awkgram.y:3120
+msgid "operator `^=' is not supported in old awk"
+msgstr ""
+
+#: awkgram.y:3128
+msgid "operator `^' is not supported in old awk"
+msgstr ""
+
+#: awkgram.y:3221 awkgram.y:3237
+msgid "unterminated string"
+msgstr ""
+
+#: awkgram.y:3433
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "invalid char '%c' in expression"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:3608
+=======
+#: awkgram.y:3480
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "`%s' is a gawk extension"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:3613
+=======
+#: awkgram.y:3485
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "POSIX does not allow `%s'"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:3621
+=======
+#: awkgram.y:3493
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "`%s' is not supported in old awk"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:3711
msgid "`goto' considered harmful!\n"
msgstr ""
#: awkgram.y:3745
+=======
+#: awkgram.y:3560
+msgid "`goto' considered harmful!\n"
+msgstr ""
+
+#: awkgram.y:3611
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "%d is invalid as number of arguments for %s"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:3780
+=======
+#: awkgram.y:3646
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "%s: string literal as last arg of substitute has no effect"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:3785
+=======
+#: awkgram.y:3651
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "%s third parameter is not a changeable object"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:3864 awkgram.y:3867
msgid "match: third argument is a gawk extension"
msgstr ""
@@ -418,24 +687,61 @@ msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore"
msgstr ""
#: awkgram.y:4017
+=======
+#: awkgram.y:3724 awkgram.y:3727
+msgid "match: third argument is a gawk extension"
+msgstr ""
+
+#: awkgram.y:3781 awkgram.y:3784
+msgid "close: second argument is a gawk extension"
+msgstr ""
+
+#: awkgram.y:3796
+msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore"
+msgstr ""
+
+#: awkgram.y:3811
+msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore"
+msgstr ""
+
+#: awkgram.y:3903
+#, c-format
+msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
+msgstr ""
+
+#: awkgram.y:3945
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "function `%s': parameter `%s' shadows global variable"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:4074 debug.c:4019 debug.c:4062 debug.c:5187
+=======
+#: awkgram.y:4103
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "could not open `%s' for writing (%s)"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:4075
msgid "sending variable list to standard error"
msgstr ""
#: awkgram.y:4083
+=======
+#: awkgram.y:4104
+msgid "sending variable list to standard error"
+msgstr ""
+
+#: awkgram.y:4110
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "%s: close failed (%s)"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:4108
msgid "shadow_funcs() called twice!"
msgstr ""
@@ -450,47 +756,90 @@ msgid "function name `%s' previously defined"
msgstr ""
#: awkgram.y:4233
+=======
+#: awkgram.y:4162
+msgid "shadow_funcs() called twice!"
+msgstr ""
+
+#: awkgram.y:4168
+msgid "there were shadowed variables."
+msgstr ""
+
+#: awkgram.y:4198
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "function `%s': can't use function name as parameter name"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:4236
+=======
+#: awkgram.y:4202
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "function `%s': can't use special variable `%s' as a function parameter"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:4244
+=======
+#: awkgram.y:4218
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:4338 awkgram.y:4342
+=======
+#: awkgram.y:4386 awkgram.y:4392
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "function `%s' called but never defined"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:4347
+=======
+#: awkgram.y:4395
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "function `%s' defined but never called directly"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:4379
+=======
+#: awkgram.y:4427
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "regexp constant for parameter #%d yields boolean value"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:4425
+=======
+#: awkgram.y:4549
+>>>>>>> gawk-4.0-stable
#, c-format
msgid ""
"function `%s' called with space between name and `(',\n"
"or used as a variable or an array"
msgstr ""
+<<<<<<< HEAD
#: awkgram.y:4658
msgid "division by zero attempted"
msgstr ""
#: awkgram.y:4667
+=======
+#: awkgram.y:4796 eval.c:2062
+msgid "division by zero attempted"
+msgstr ""
+
+#: awkgram.y:4805 eval.c:2078
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "division by zero attempted in `%%'"
msgstr ""
@@ -651,6 +1000,7 @@ msgstr ""
msgid "too many arguments supplied for format string"
msgstr ""
+<<<<<<< HEAD
#: builtin.c:1620 builtin.c:1631
msgid "printf: no arguments"
msgstr ""
@@ -660,55 +1010,107 @@ msgid "sqrt: received non-numeric argument"
msgstr ""
#: builtin.c:1676
+=======
+#: builtin.c:1396
+msgid "[s]printf called with no arguments"
+msgstr ""
+
+#: builtin.c:1442 builtin.c:1453
+msgid "printf: no arguments"
+msgstr ""
+
+#: builtin.c:1494
+msgid "sqrt: received non-numeric argument"
+msgstr ""
+
+#: builtin.c:1498
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "sqrt: called with negative argument %g"
msgstr ""
+<<<<<<< HEAD
#: builtin.c:1707
+=======
+#: builtin.c:1522
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "substr: length %g is not >= 1"
msgstr ""
+<<<<<<< HEAD
#: builtin.c:1709
+=======
+#: builtin.c:1524
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "substr: length %g is not >= 0"
msgstr ""
+<<<<<<< HEAD
#: builtin.c:1716
+=======
+#: builtin.c:1531
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "substr: non-integer length %g will be truncated"
msgstr ""
+<<<<<<< HEAD
#: builtin.c:1721
+=======
+#: builtin.c:1536
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "substr: length %g too big for string indexing, truncating to %g"
msgstr ""
+<<<<<<< HEAD
#: builtin.c:1733
+=======
+#: builtin.c:1548
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "substr: start index %g is invalid, using 1"
msgstr ""
+<<<<<<< HEAD
#: builtin.c:1738
+=======
+#: builtin.c:1553
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "substr: non-integer start index %g will be truncated"
msgstr ""
+<<<<<<< HEAD
#: builtin.c:1763
msgid "substr: source string is zero length"
msgstr ""
#: builtin.c:1779
+=======
+#: builtin.c:1578
+msgid "substr: source string is zero length"
+msgstr ""
+
+#: builtin.c:1594
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "substr: start index %g is past end of string"
msgstr ""
+<<<<<<< HEAD
#: builtin.c:1787
+=======
+#: builtin.c:1602
+>>>>>>> gawk-4.0-stable
#, c-format
msgid ""
"substr: length %g at start index %g exceeds length of first argument (%lu)"
msgstr ""
+<<<<<<< HEAD
#: builtin.c:1861
msgid "strftime: format value in PROCINFO[\"strftime\"] has numeric type"
msgstr ""
@@ -1805,15 +2207,59 @@ msgid "turning off `--lint' due to assignment to `LINT'"
msgstr ""
#: eval.c:1141
+=======
+#: builtin.c:1676
+msgid "strftime: format value in PROCINFO[\"strftime\"] has numeric type"
+msgstr ""
+
+#: builtin.c:1699
+msgid "strftime: received non-numeric second argument"
+msgstr ""
+
+#: builtin.c:1702
+msgid "strftime: second argument less than 0 or too big for time_t"
+msgstr ""
+
+#: builtin.c:1709
+msgid "strftime: received non-string first argument"
+msgstr ""
+
+#: builtin.c:1715
+msgid "strftime: received empty format string"
+msgstr ""
+
+#: builtin.c:1781
+msgid "mktime: received non-string argument"
+msgstr ""
+
+#: builtin.c:1798
+msgid "mktime: at least one of the values is out of the default range"
+msgstr ""
+
+#: builtin.c:1833
+msgid "'system' function not allowed in sandbox mode"
+msgstr ""
+
+#: builtin.c:1838
+msgid "system: received non-string argument"
+msgstr ""
+
+#: builtin.c:1893 eval.c:1159 eval.c:1795 eval.c:1809
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "reference to uninitialized argument `%s'"
msgstr ""
+<<<<<<< HEAD
#: eval.c:1142
+=======
+#: builtin.c:1960
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "reference to uninitialized variable `%s'"
msgstr ""
+<<<<<<< HEAD
#: eval.c:1160
msgid "attempt to field reference from non-numeric value"
msgstr ""
@@ -1864,21 +2310,77 @@ msgid "load_ext: received NULL lib_name"
msgstr ""
#: ext.c:94
+=======
+#: builtin.c:2047
+msgid "tolower: received non-string argument"
+msgstr ""
+
+#: builtin.c:2081
+msgid "toupper: received non-string argument"
+msgstr ""
+
+#: builtin.c:2117
+msgid "atan2: received non-numeric first argument"
+msgstr ""
+
+#: builtin.c:2119
+msgid "atan2: received non-numeric second argument"
+msgstr ""
+
+#: builtin.c:2138
+msgid "sin: received non-numeric argument"
+msgstr ""
+
+#: builtin.c:2154
+msgid "cos: received non-numeric argument"
+msgstr ""
+
+#: builtin.c:2207
+msgid "srand: received non-numeric argument"
+msgstr ""
+
+#: builtin.c:2238
+msgid "match: third argument is not an array"
+msgstr ""
+
+#: builtin.c:2502
+msgid "gensub: third argument of 0 treated as 1"
+msgstr ""
+
+#: builtin.c:2795
+msgid "lshift: received non-numeric first argument"
+msgstr ""
+
+#: builtin.c:2797
+msgid "lshift: received non-numeric second argument"
+msgstr ""
+
+#: builtin.c:2803
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "load_ext: cannot open library `%s' (%s)\n"
msgstr ""
+<<<<<<< HEAD
#: ext.c:100
+=======
+#: builtin.c:2805
+>>>>>>> gawk-4.0-stable
#, c-format
msgid ""
"load_ext: library `%s': does not define `plugin_is_GPL_compatible' (%s)\n"
msgstr ""
+<<<<<<< HEAD
#: ext.c:106
+=======
+#: builtin.c:2807
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "load_ext: library `%s': cannot call function `%s' (%s)\n"
msgstr ""
+<<<<<<< HEAD
#: ext.c:110
#, c-format
msgid "load_ext: library `%s' initialization routine `%s' failed\n"
@@ -1889,30 +2391,67 @@ msgid "make_builtin: missing function name"
msgstr ""
#: ext.c:146
+=======
+#: builtin.c:2832
+msgid "rshift: received non-numeric first argument"
+msgstr ""
+
+#: builtin.c:2834
+msgid "rshift: received non-numeric second argument"
+msgstr ""
+
+#: builtin.c:2840
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "make_builtin: can't redefine function `%s'"
msgstr ""
+<<<<<<< HEAD
#: ext.c:150
+=======
+#: builtin.c:2842
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "make_builtin: function `%s' already defined"
msgstr ""
+<<<<<<< HEAD
#: ext.c:154
#, c-format
msgid "make_builtin: function name `%s' previously defined"
msgstr ""
#: ext.c:156
+=======
+#: builtin.c:2844
+#, c-format
+msgid "rshift(%f, %f): too large shift value will give strange results"
+msgstr ""
+
+#: builtin.c:2869
+msgid "and: received non-numeric first argument"
+msgstr ""
+
+#: builtin.c:2871
+msgid "and: received non-numeric second argument"
+msgstr ""
+
+#: builtin.c:2877
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "make_builtin: can't use gawk built-in `%s' as function name"
msgstr ""
+<<<<<<< HEAD
#: ext.c:159
+=======
+#: builtin.c:2879
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "make_builtin: negative argument count for function `%s'"
msgstr ""
+<<<<<<< HEAD
#: ext.c:223
#, c-format
msgid "function `%s' defined to take no more than %d argument(s)"
@@ -1924,15 +2463,31 @@ msgid "function `%s': missing argument #%d"
msgstr ""
#: ext.c:243
+=======
+#: builtin.c:2904
+msgid "or: received non-numeric first argument"
+msgstr ""
+
+#: builtin.c:2906
+msgid "or: received non-numeric second argument"
+msgstr ""
+
+#: builtin.c:2912
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "function `%s': argument #%d: attempt to use scalar as an array"
msgstr ""
+<<<<<<< HEAD
#: ext.c:247
+=======
+#: builtin.c:2914
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "function `%s': argument #%d: attempt to use array as a scalar"
msgstr ""
+<<<<<<< HEAD
#: ext.c:261
msgid "dynamic loading of library not supported"
msgstr ""
@@ -1942,10 +2497,22 @@ msgid "chdir: called with incorrect number of arguments, expecting 1"
msgstr ""
#: extension/filefuncs.c:317
+=======
+#: builtin.c:2942
+msgid "xor: received non-numeric first argument"
+msgstr ""
+
+#: builtin.c:2944
+msgid "xor: received non-numeric second argument"
+msgstr ""
+
+#: builtin.c:2950
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "stat: unable to read symbolic link `%s'"
msgstr ""
+<<<<<<< HEAD
#: extension/filefuncs.c:350
msgid "stat: called with wrong number of arguments"
msgstr ""
@@ -1955,16 +2522,39 @@ msgid "stat: bad parameters"
msgstr ""
#: extension/filefuncs.c:410
+=======
+#: builtin.c:2952
+#, c-format
+msgid "xor(%f, %f): fractional values will be truncated"
+msgstr ""
+
+#: builtin.c:2976 builtin.c:2982
+msgid "compl: received non-numeric argument"
+msgstr ""
+
+#: builtin.c:2984
+>>>>>>> gawk-4.0-stable
#, c-format
msgid "fts init: could not create constant %s"
msgstr ""
+<<<<<<< HEAD
#: extension/filefuncs.c:430
msgid "fill_stat_element: could not create array"
msgstr ""
#: extension/filefuncs.c:439
msgid "fill_stat_element: could not set element"
+=======
+#: builtin.c:2986
+#, c-format
+msgid "compl(%f): fractional value will be truncated"
+msgstr ""
+
+#: builtin.c:3155
+#, c-format
+msgid "dcgettext: `%s' is not a valid locale category"
+>>>>>>> gawk-4.0-stable
msgstr ""
#: extension/filefuncs.c:454
@@ -2012,8 +2602,14 @@ msgstr ""
msgid "fts: clear_array() failed\n"
msgstr ""
+<<<<<<< HEAD
#: extension/fnmatch.c:91
msgid "fnmatch: called with less than three arguments"
+=======
+#: eval.c:1158 eval.c:1794 eval.c:1808
+#, c-format
+msgid "reference to uninitialized argument `%s'"
+>>>>>>> gawk-4.0-stable
msgstr ""
#: extension/fnmatch.c:94
@@ -2049,6 +2645,7 @@ msgstr ""
msgid "fnmatch init: could not install FNM array"
msgstr ""
+<<<<<<< HEAD
#: extension/fork.c:81
msgid "fork: called with too many arguments"
msgstr ""
@@ -2095,6 +2692,63 @@ msgstr ""
#: extension/readfile.c:81
msgid "readfile: called with too many arguments"
+=======
+#: eval.c:1882 eval.c:2128
+#, c-format
+msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
+msgstr ""
+
+#: eval.c:1913
+msgid "assignment used in conditional context"
+msgstr ""
+
+#: eval.c:1917
+msgid "statement has no effect"
+msgstr ""
+
+#: eval.c:2361
+#, c-format
+msgid "for loop: array `%s' changed size from %ld to %ld during loop execution"
+msgstr ""
+
+#: eval.c:2476
+#, c-format
+msgid "function called indirectly through `%s' does not exist"
+msgstr ""
+
+#: eval.c:2488
+#, c-format
+msgid "function `%s' not defined"
+msgstr ""
+
+#: eval.c:2529
+#, c-format
+msgid "non-redirected `getline' invalid inside `%s' rule"
+msgstr ""
+
+#: eval.c:2618
+#, c-format
+msgid "error reading input file `%s': %s"
+msgstr ""
+
+#: eval.c:2632
+#, c-format
+msgid "`nextfile' cannot be called from a `%s' rule"
+msgstr ""
+
+#: eval.c:2679
+msgid "`exit' cannot be called in the current context"
+msgstr ""
+
+#: eval.c:2718
+#, c-format
+msgid "`next' cannot be called from a `%s' rule"
+msgstr ""
+
+#: eval.c:2784
+#, c-format
+msgid "Sorry, don't know how to interpret `%s'"
+>>>>>>> gawk-4.0-stable
msgstr ""
#: extension/readfile.c:114
diff --git a/posix/ChangeLog b/posix/ChangeLog
index 17a93f7f..ce5cd2c9 100644
--- a/posix/ChangeLog
+++ b/posix/ChangeLog
@@ -1,3 +1,7 @@
+2012-12-23 Arnold D. Robbins <arnold@skeeve.com>
+
+ * 4.0.2: Release tar ball made.
+
2012-10-14 Arnold D. Robbins <arnold@skeeve.com>
* gawkmisc.c (os_isreadable): Change name of input parameter to
diff --git a/test/ChangeLog b/test/ChangeLog
index 1897aed0..1d015467 100644
--- a/test/ChangeLog
+++ b/test/ChangeLog
@@ -1,3 +1,13 @@
+2012-12-23 Arnold D. Robbins <arnold@skeeve.com>
+
+ * 4.0.2: Release tar ball made.
+
+2012-12-23 Arnold D. Robbins <arnold@skeeve.com>
+
+ * Makefile.am (paramuninitglobal): New test.
+ * paramuninitglobal.awk, paramuninitglobal.ok: New files.
+ Thanks to John Haque.
+
2012-12-19 Arnold D. Robbins <arnold@skeeve.com>
* symtab9.awk, symtab9.ok: New files.
diff --git a/test/Makefile.am b/test/Makefile.am
index 2bf7eba2..8f4ce48f 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -583,6 +583,8 @@ EXTRA_DIST = \
paramres.ok \
paramtyp.awk \
paramtyp.ok \
+ paramuninitglobal.awk \
+ paramuninitglobal.ok \
parse1.awk \
parse1.in \
parse1.ok \
@@ -900,8 +902,8 @@ BASIC_TESTS = \
nlinstr nlstrina noeffect nofile nofmtch noloop1 noloop2 nonl \
noparms nors nulrsend numindex numsubstr \
octsub ofmt ofmta ofmtbig ofmtfidl ofmts ofs1 onlynl opasnidx opasnslf \
- paramdup paramres paramtyp parse1 parsefld parseme pcntplus \
- posix2008sub prdupval prec printf0 printf1 prmarscl prmreuse \
+ paramdup paramres paramtyp paramuninitglobal parse1 parsefld parseme \
+ pcntplus posix2008sub prdupval prec printf0 printf1 prmarscl prmreuse \
prt1eval prtoeval \
rand range1 rebt8b1 redfilnm regeq regexprange regrange \
reindops reparse \
diff --git a/test/Makefile.in b/test/Makefile.in
index 6cdff55f..2316cf71 100644
--- a/test/Makefile.in
+++ b/test/Makefile.in
@@ -795,6 +795,8 @@ EXTRA_DIST = \
paramres.ok \
paramtyp.awk \
paramtyp.ok \
+ paramuninitglobal.awk \
+ paramuninitglobal.ok \
parse1.awk \
parse1.in \
parse1.ok \
@@ -1111,8 +1113,8 @@ BASIC_TESTS = \
nlinstr nlstrina noeffect nofile nofmtch noloop1 noloop2 nonl \
noparms nors nulrsend numindex numsubstr \
octsub ofmt ofmta ofmtbig ofmtfidl ofmts ofs1 onlynl opasnidx opasnslf \
- paramdup paramres paramtyp parse1 parsefld parseme pcntplus \
- posix2008sub prdupval prec printf0 printf1 prmarscl prmreuse \
+ paramdup paramres paramtyp paramuninitglobal parse1 parsefld parseme \
+ pcntplus posix2008sub prdupval prec printf0 printf1 prmarscl prmreuse \
prt1eval prtoeval \
rand range1 rebt8b1 redfilnm regeq regexprange regrange \
reindops reparse \
@@ -2696,6 +2698,11 @@ paramtyp:
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+paramuninitglobal:
+ @echo $@
+ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
parse1:
@echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
diff --git a/test/Maketests b/test/Maketests
index 457363e4..be8b53b9 100644
--- a/test/Maketests
+++ b/test/Maketests
@@ -595,6 +595,11 @@ paramtyp:
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+paramuninitglobal:
+ @echo $@
+ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
parse1:
@echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
diff --git a/test/paramuninitglobal.awk b/test/paramuninitglobal.awk
new file mode 100644
index 00000000..b59bb248
--- /dev/null
+++ b/test/paramuninitglobal.awk
@@ -0,0 +1,2 @@
+function f(x) { a=10; print x; print a}
+BEGIN { f(a) }
diff --git a/test/paramuninitglobal.ok b/test/paramuninitglobal.ok
new file mode 100644
index 00000000..069c2ae6
--- /dev/null
+++ b/test/paramuninitglobal.ok
@@ -0,0 +1,2 @@
+
+10
diff --git a/vms/ChangeLog b/vms/ChangeLog
index 6c56405f..9e2f6297 100644
--- a/vms/ChangeLog
+++ b/vms/ChangeLog
@@ -1,3 +1,17 @@
+2012-12-23 Arnold D. Robbins <arnold@skeeve.com>
+
+ * vmstest.com (paramuninitglobal): New test.
+
+ And then:
+
+ * 4.0.2: Release tar ball made.
+
+2012-12-23 Arnold D. Robbins <arnold@skeeve.com>
+
+ * vmsbuild.com (REL, PATCHLVL): Move to 4.0.2.
+ * descrip.mms (REL, PATCHLVL): Move to 4.0.2.
+ * vms-conf.h (VERSION, PACKAGE_VERSION, PACKAGE_STRING): Move to 4.0.2.
+
2012-12-18 John E. Malmberg <wb8tyw@qsl.net>
* descrip.mms: Make the build procedure run on a default directory
diff --git a/vms/descrip.mms b/vms/descrip.mms
index 069c45f4..77dad90a 100644
--- a/vms/descrip.mms
+++ b/vms/descrip.mms
@@ -113,8 +113,8 @@ VMSOBJS = $(VMSCODE),$(VMSCMD)
DOCS= $(DOCDIR)gawk.1,$(DOCDIR)gawk.texi,$(DOCDIR)texinfo.tex
# Release of gawk
-REL=4.0
-PATCHLVL=1
+REL=4.1
+PATCHLVL=0
# generic target
all : gawk
diff --git a/vms/vms-conf.h b/vms/vms-conf.h
index fbd611f2..910d519b 100644
--- a/vms/vms-conf.h
+++ b/vms/vms-conf.h
@@ -403,7 +403,7 @@
#define PACKAGE_NAME "GNU Awk"
/* Define to the full name and version of this package. */
-#define PACKAGE_STRING "GNU Awk 3.1.8"
+#define PACKAGE_STRING "GNU Awk 4.0.2"
/* Define to the one symbol short name of this package. */
#define PACKAGE_TARNAME "gawk"
@@ -412,7 +412,7 @@
#undef PACKAGE_URL
/* Define to the version of this package. */
-#define PACKAGE_VERSION "4.0.1"
+#define PACKAGE_VERSION "4.0.2"
/* Define to 1 if *printf supports %F format */
#undef PRINTF_HAS_F_FORMAT
@@ -442,7 +442,7 @@
#define USE_INCLUDED_STRFTIME 1
/* Version number of package */
-#define VERSION "4.0.1"
+#define VERSION "4.0.2"
/* Define to 1 if on AIX 3.
System headers sometimes define this.
diff --git a/vms/vmstest.com b/vms/vmstest.com
index 360f2fd5..2aebe9ff 100644
--- a/vms/vmstest.com
+++ b/vms/vmstest.com
@@ -70,7 +70,8 @@ $ list = "nfset nlfldsep nlinstr nlstrina noeffect nofile" -
+ " nofmtch noloop1 noloop2 nonl noparms nors nulrsend" -
+ " numindex numsubstr octsub ofmt ofmtbig ofmtfidl" -
+ " ofmta ofmts ofs1 onlynl opasnidx opasnslf paramdup" -
- + " paramres paramtyp parse1 parsefld parseme pcntplus" -
+ + " paramres paramtyp paramuninitglobal parse1 parsefld" -
+ + " parseme pcntplus" -
+ " posix2008sub prdupval prec printf0 printf1 prmarscl"
$ gosub list_of_tests
$ list = "prmreuse prt1eval prtoeval rand range1 rebt8b1" -
@@ -313,6 +314,7 @@ $nondec:
$octsub:
$ofmta:
$paramtyp:
+$paramuninitglobal:
$patsplit:
$pcntplus:
$printf1: