aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog313
-rw-r--r--FUTURES6
-rw-r--r--Makefile.am29
-rw-r--r--Makefile.in85
-rw-r--r--NEWS12
-rw-r--r--README.git261
-rw-r--r--README_d/ChangeLog8
-rw-r--r--README_d/README.hacking11
-rw-r--r--README_d/README.mpfr25
-rw-r--r--TODO2
-rw-r--r--aclocal.m41
-rw-r--r--array.c1454
-rw-r--r--awk.h708
-rw-r--r--awkgram.c3053
-rw-r--r--awkgram.y1512
-rw-r--r--awklib/.gitignore8
-rw-r--r--awklib/Makefile.in11
-rw-r--r--builtin.c356
-rw-r--r--cint_array.c1217
-rw-r--r--cmd.h3
-rw-r--r--command.c101
-rw-r--r--command.y101
-rw-r--r--configh.in3
-rwxr-xr-xconfigure102
-rw-r--r--configure.ac9
-rw-r--r--debug.c426
-rw-r--r--doc/ChangeLog44
-rw-r--r--doc/Makefile.in11
-rw-r--r--doc/awkcard.in56
-rw-r--r--doc/gawk.1187
-rw-r--r--doc/gawk.info3026
-rw-r--r--doc/gawk.texi1505
-rw-r--r--eval.c1593
-rw-r--r--eval_d.c27
-rw-r--r--eval_p.c27
-rw-r--r--ext.c231
-rw-r--r--extension/ChangeLog5
-rw-r--r--extension/arrayparm.c8
-rw-r--r--extension/filefuncs.c44
-rw-r--r--extension/fork.c8
-rw-r--r--extension/ordchr.c4
-rw-r--r--extension/readfile.c2
-rw-r--r--extension/rwarray.c6
-rw-r--r--extension/testarg.c8
-rw-r--r--field.c57
-rw-r--r--int_array.c799
-rw-r--r--interpret.h1218
-rw-r--r--io.c802
-rw-r--r--m4/ChangeLog6
-rw-r--r--m4/mpfr.m462
-rw-r--r--main.c288
-rw-r--r--mpfr.c1620
-rw-r--r--msg.c18
-rw-r--r--node.c255
-rw-r--r--pc/ChangeLog38
-rw-r--r--pc/Makefile100
-rw-r--r--pc/Makefile.tst37
-rw-r--r--pc/config.h44
-rw-r--r--po/.gitignore4
-rw-r--r--po/ast.gmobin37068 -> 0 bytes
-rw-r--r--po/ca.gmobin25787 -> 0 bytes
-rw-r--r--po/da.gmobin48955 -> 46123 bytes
-rw-r--r--po/da.po1030
-rw-r--r--po/de.gmobin52410 -> 49358 bytes
-rw-r--r--po/de.po1034
-rw-r--r--po/es.gmobin51691 -> 48746 bytes
-rw-r--r--po/es.po1031
-rw-r--r--po/fi.gmobin51928 -> 48930 bytes
-rw-r--r--po/fi.po1030
-rw-r--r--po/fr.gmobin53536 -> 50390 bytes
-rw-r--r--po/fr.po1031
-rw-r--r--po/ga.gmobin33929 -> 0 bytes
-rw-r--r--po/gawk.pot941
-rw-r--r--po/he.gmobin24651 -> 0 bytes
-rw-r--r--po/id.gmobin35809 -> 0 bytes
-rw-r--r--po/it.gmobin44170 -> 41479 bytes
-rw-r--r--po/it.po1033
-rw-r--r--po/ja.gmobin55401 -> 52218 bytes
-rw-r--r--po/ja.po1032
-rw-r--r--po/nl.gmobin49531 -> 46629 bytes
-rw-r--r--po/nl.po1030
-rw-r--r--po/pl.gmobin51712 -> 48745 bytes
-rw-r--r--po/pl.po1033
-rw-r--r--po/pt_BR.gmobin29120 -> 0 bytes
-rw-r--r--po/ro.gmobin25383 -> 0 bytes
-rw-r--r--po/rw.gmobin487 -> 0 bytes
-rw-r--r--po/sv.gmobin48974 -> 46113 bytes
-rw-r--r--po/sv.po1030
-rw-r--r--po/tr.gmobin33826 -> 0 bytes
-rw-r--r--po/vi.gmobin58485 -> 55101 bytes
-rw-r--r--po/vi.po1030
-rw-r--r--po/zh_CN.gmobin33717 -> 0 bytes
-rw-r--r--profile.c86
-rw-r--r--profile_p.c27
-rw-r--r--re.c52
-rw-r--r--str_array.c731
-rw-r--r--symbol.c718
-rw-r--r--test/ChangeLog24
-rwxr-xr-xtest/Gentests19
-rw-r--r--test/Makefile.am67
-rw-r--r--test/Makefile.in566
-rw-r--r--test/Maketests489
-rw-r--r--test/badargs.ok4
-rw-r--r--test/delfunc.ok5
-rw-r--r--test/dumpvars.ok2
-rw-r--r--test/fmtspcl-mpfr.ok0
-rw-r--r--test/fnamedat.ok5
-rw-r--r--test/fnarray.ok2
-rw-r--r--test/fnarray2.in1
-rw-r--r--test/fnarray2.ok4
-rw-r--r--test/fnarydel-mpfr.ok27
-rw-r--r--test/fnarydel.ok10
-rw-r--r--test/fnasgnm.ok5
-rw-r--r--test/fnparydl-mpfr.ok10
-rw-r--r--test/fnparydl.ok6
-rw-r--r--test/funsmnam.ok2
-rw-r--r--test/gsubasgn.ok8
-rw-r--r--test/match2.ok5
-rw-r--r--test/mpfrbigint.awk11
-rw-r--r--test/mpfrbigint.ok5
-rw-r--r--test/mpfrexprange.awk7
-rw-r--r--test/mpfrexprange.ok2
-rw-r--r--test/mpfrieee.awk13
-rw-r--r--test/mpfrieee.ok12
-rw-r--r--test/mpfrnr.awk10
-rw-r--r--test/mpfrnr.in3
-rw-r--r--test/mpfrnr.ok1
-rw-r--r--test/mpfrrnd.awk15
-rw-r--r--test/mpfrrnd.ok10
-rw-r--r--test/mpfrsort.awk8
-rw-r--r--test/mpfrsort.ok11
-rw-r--r--test/rand-mpfr.ok1
-rw-r--r--test/rand-mpfr1.ok1
-rw-r--r--version.c2
134 files changed, 22380 insertions, 14849 deletions
diff --git a/ChangeLog b/ChangeLog
index b431bb8b..3529f5d9 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -15,6 +15,113 @@
* debug.c: Ditto.
* command.y: Ditto. Some minor whitespace and comments cleanup.
+2012-04-24 Arnold D. Robbins <arnold@skeeve.com>
+
+ io.c cleanup and some speedup for RS as regexp parsing.
+
+ * awk.h (Regexp): New members has_meta and maybe_long.
+ (enum redirval): Add redirect_none as value 0.
+ (remaybelong): Remove function declaration.
+ * awkgram.y: Use redirect_none instead of 0 for no redirect cases.
+ * io.c (go_getline_redir): Second arg now of type enum redirval.
+ Changed intovar into into_variable.
+ (comments and whitespace): Lots of general cleanup.
+ (socket_open): readle changed to read_len.
+ (two_way_open): Add additional calls to os_close_on_exec.
+ (rsrescan): Simplify code a bit and use RS->maybe_long.
+ * re.c (make_regexp): Set up new members in Regexp struct.
+ (remaybelong): Remove function.
+ (reisstring): Simplified code.
+
+2012-04-16 Eli Zaretskii <eliz@gnu.org>
+
+ * io.c (read_with_timeout) [__MINGW32__]: Just call the blocking
+ 'read', as 'select' is only available for sockets.
+ * mpfr.c (set_ROUNDMODE) [!HAVE_MPFR]: Renamed from set_RNDMODE.
+ * main.c (load_procinfo): Declare name[] also when HAVE_MPFR is
+ defined even though HAVE_GETGROUPS etc. are not.
+
+2012-04-12 John Haque <j.eh@mchsi.com>
+
+ * array.c, awk.h, awkgram.y, builtin.c, command.y, debug.c,
+ field.c, mpfr.c, profile.c: Change RND_MODE to ROUND_MODE.
+
+2012-04-11 John Haque <j.eh@mchsi.com>
+
+ * main.c (varinit): Change RNDMODE to ROUNDMODE.
+
+2012-04-11 Arnold D. Robbins <arnold@skeeve.com>
+
+ * main.c: Change --arbitrary-precision to --bignum.
+
+2012-04-02 John Haque <j.eh@mchsi.com>
+
+ Add support for arbitrary-precision arithmetic.
+
+ * mpfr.c: New file.
+ * awk.h (struct exp_node): Add union to handle different number types.
+ (MPFN, MPZN): New flag values.
+ (DO_MPFR, do_mpfr): New defines.
+ (PREC_node, RNDMODE_node): Add declarations.
+ (PRECISION, RND_MODE, MNR, MFNR, mpzval, do_ieee_fmt): Add declarations.
+ (make_number, str2number, format_val, cmp_numbers): Ditto.
+ (force_number): Change definition.
+ (Func_pre_exec, Func_post_exec): New typedefs.
+ (POP_NUMBER, TOP_NUMBER): Change definitions.
+ (get_number_ui, get_number_si, get_number_d, get_number_uj,
+ iszero, IEEE_FMT, mpg_float, mpg_integer, mpg_float,
+ mpg_integer): New defines.
+ * awkgram.y (tokentab): Add alternate function entries for MPFR/GMP.
+ (snode): Choose the appropriate function.
+ (negate_num): New function to negate a number.
+ (grammar): Use it.
+ (yylex): Adjust number handling code.
+ * array.c (value_info, asort_actual, sort_user_func): Adjust for
+ MPFR/GMP numbers.
+ (do_adump, indent): Minor changes.
+ (sort_up_index_number, sort_up_value_number, sort_up_value_type): Use
+ cmp_numbers() for numeric comparisons.
+ * builtin.c (mpz2mpfr): New function.
+ (format_tree): Adjust to handle MPFR and GMP numbers.
+ * eval.c (register_exec_hook): New function to manage interpreter hooks.
+ (num_exec_hook, pre_execute, post_execute): New and adjusted definitions.
+ (h_interpret): Renamed from debug_interpret.
+ (init_interpret): Changed to use the new name.
+ (flags2str): New entries for MPFN and MPZN.
+ (cmp_nodes): Reworked to use seperate routine for numeric comparisons.
+ (set_IGNORECASE, set_BINMODE, set_LINT, update_NR, update_FNR,
+ update_NF): Adjust code and some cleanup.
+ * field.c (rebuild_record): Field copying code reworked to handle
+ MPFR/GMP numbers.
+ (set_NF): Minor adjustment.
+ * io.c (INCREMENT_REC): New macro.
+ (inrec, do_getline): Use the new macro.
+ (nextfile, set_NR, set_FNR, get_read_timeout, pty_vs_pipe): Adjust code
+ to handle MPFR/GMP numbers.
+ * interpret.h (r_interpret): Adjust TOP_NUMBER/POP_NUMBER usage.
+ (EXEC_HOOK): New macro and definition.
+ (DEBUGGING): Removed.
+ * main.c (DEFAULT_PREC, DEFAULT_RNDMODE): New defines.
+ (opttab): New entry for option arbitrary-precision.
+ (main): Handle the new option.
+ (usage): Add to usage message.
+ (varinit): Add PREC and RNDMODE.
+ (load_procinfo): Install MPFR and GMP related items.
+ (version): Append MPFR and GMP versions to message.
+ * msg.c (err) : Adjust FNR handling with MPFR/GMP.
+ * node.c (r_format_val): Renamed from format_val.
+ (r_force_number): Return NODE * instead of AWKNUM.
+ (make_number, str2number, format_val, cmp_numpers: Defined and initialized.
+ (r_unref): Free MPFR/MPZ numbers.
+ (get_numbase): Renamed from isnondecimal and return the base.
+ (cmp_awknums): New function to compare two AWKNUMs.
+ * command.y (yylex): Adjust number handling code.
+ (grammar): Minor adjustments to handle negative numbers.
+ * debug.c (init_debug): New function.
+ (do_info, do_set_var, watchpoint_triggered, serialize,
+ initialize_watch_item, do_watch, print_watch_item): Minor adjustments.
+ (debug_pre_execute): Adjusted to handle MPFR and GMP numbers.
+
2012-04-09 Arnold D. Robbins <arnold@skeeve.com>
* INSTALL, config.guess, config.sub, depcomp, install-sh,
@@ -132,12 +239,92 @@
* dfa.c: Sync with GNU grep.
+2012-01-02 Arnold D. Robbins <arnold@skeeve.com>
+
+ * io.c (Read_can_timeout, Read_timeout, Read_default_timeout):
+ Renamed to use lower case.
+ Other minor stylistic edits.
+
+2012-01-01 John Haque <j.eh@mchsi.com>
+
+ * awk.h (struct iobuf): New entry read_func.
+ * io.c (Read_can_timeout, Read_timeout, Read_default_timeout):
+ New variables.
+ (init_io): New routine to initialize the variables.
+ (in_PROCINFO): New "clever" routine to parse elements with indices
+ seperated by a SUPSEP.
+ (get_read_timeout): New routine to read timeout value for an IOBUF.
+ (read_with_timeout): New routine to read from a fd with a timeout.
+ (pty_vs_pipe): Use in_PROCINFO().
+ (get_a_record): Set the timeout value and the read routine as necessary.
+ * main.c (main): Call init_io().
+
+2011-12-31 Arnold D. Robbins <arnold@skeeve.com>
+
+ * profile_p.c: Remove the file.
+ * msg.c (err): Remove check for name being dgawk.
+
2011-12-31 Arnold D. Robbins <arnold@skeeve.com>
* awk.h [STREQ, STREQN]: Remove macros.
* awkgram.y, builtin.c, command.y, debug.c, eval.c,
io.c, msg.c: Change all uses to call strcmp, strncmp.
+2011-12-28 Arnold D. Robbins <arnold@skeeve.com>
+
+ * int_array.c, str_array.c: Fix some compiler warnings 32/64
+ bit system differences.
+
+2011-12-26 John Haque <j.eh@mchsi.com>
+
+ Merge gawk, pgawk and dgawk into a single executable gawk.
+
+ * awk.h (DO_PRETTY_PRINT, DO_PROFILE, DO_DEBUG,
+ do_pretty_print, do_debug): New defines.
+ (interpret): New variable, a pointer to an interpreter routine.
+ (enum exe_mode): Nuked.
+ * main.c (opttab): New options --pretty-print and --debug;
+ Remove option --command.
+ (usage): Update usage messages.
+ * interpret.h: New file.
+ * eval.c (r_interpret): Move to the new file.
+ (debug_interpret): New interpreter routine when debugging.
+ (init_interpret): New routine to initialize interpreter related
+ variables.
+ * eval_d.c, eval_p.c: Delete files.
+ * debug.c (interpret): Renamed to debug_prog.
+ (DEFAULT_PROMPT, DEFAULT_HISTFILE, DEFAULT_OPTFILE): Remove prefix 'd'.
+ * profile.c (init_profiling): Nuked.
+ * Makefile.am: Adjusted.
+
+ Add command line option --load for loading extensions.
+
+ * awk.h (srctype): Add new source type SRC_EXTLIB.
+ * ext.c(load_ext): New routine to load extension.
+ (do_ext): Adjust to use load_ext().
+ * main.c (opttab): Add new option --load.
+ (main): Call load_ext() to load extensions.
+ (usage): Add usage message for the new option.
+ * io.c (get_cwd): New routine.
+ (do_find_source): Use the new routine.
+ (find_source): Handle new type SRC_EXTLIB.
+ * awkgram.y (parse_program, next_sourcefile): Skip type SRC_EXTLIB.
+ (add_srcfile): Adjust call to find_source.
+ * debug.c (source_find): Same.
+
+ Unrelated:
+
+ * ext.c (get_argument): Fixed argument parsing.
+ * array.c (null_array_func): Reworked array routines for an empty array.
+ * str_array.c, int_array.c: Make GCC happy, use %u instead of %lu
+ printf formats.
+ * eval.c (node_Boolean): New array for TRUE and FALSE nodes.
+ (init_interpret): Create the new nodes.
+ (eval_condition): Add test for the new nodes.
+ (setup_frame): Disable tail-recursion optimization when profiling.
+ * interpret.h (r_interpret): Use the boolean nodes instead of making
+ new ones when needed.
+
2011-12-26 Arnold D. Robbins <arnold@skeeve.com>
Finish Rational Range Interpretation (!)
@@ -197,6 +384,14 @@
2011-10-25 Arnold D. Robbins <arnold@skeeve.com>
+ Merge with gawk_performance branch done. Additionally:
+
+ * cint_array.c, int_array.c, str_array.c: Fix compiler complaints
+ about printf formats (signed / unsigned vs. %d / %u).
+ * eval.c (setup_frame): Add a missing return value.
+
+2011-10-25 Arnold D. Robbins <arnold@skeeve.com>
+
* Makefile.am (dist-hook): Use `cd $(srcdir)/pc' so that
`make distcheck' works completely.
* builtin.c (do_strftime): Add cast to long int in check
@@ -268,10 +463,25 @@
(remap_std_file): Per Eli's suggestion, removed the leading close
of oldfd and will let dup2 do the close for us.
+2011-10-11 John Haque <j.eh@mchsi.com>
+
+ * symbol.c: Add licence notice.
+ * array.c (PREC_NUM, PREC_STR): Define as macros.
+
2011-10-09 Arnold D. Robbins <arnold@skeeve.com>
* dfa.c: Sync with GNU grep.
+2011-10-07 John Haque <j.eh@mchsi.com>
+
+ Tail recursion optimization.
+ * awkgram.y (grammar, mk_function): Recognize tail-recursive
+ calls.
+ * awk.h (tail_call, num_tail_calls): New defines.
+ * eval.c (setup_frame): Reuse function call stack for
+ tail-recursive calls.
+ (dump_fcall_stack): Reworked.
+
2011-10-04 Arnold D. Robbins <arnold@skeeve.com>
* awk.h, main.c (gawk_mb_cur_max): Make it a constant 1 when
@@ -308,10 +518,113 @@
* dfa.c: Sync with GNU grep.
+2011-09-08 John Haque <j.eh@mchsi.com>
+
+ Optimization for compound assignment, increment and
+ decrement operators; Avoid unref and make_number calls
+ when there is no extra references to the value NODE.
+
2011-09-03 Arnold D. Robbins <arnold@skeeve.com>
* dfa.c: Sync with GNU grep.
+2011-08-31 John Haque <j.eh@mchsi.com>
+
+ Grammar related changes: Simplify grammar for user-defined
+ functions and general cleanups.
+
+ * symbol.c: New file.
+ * awkgram.y: Move symbol table related routines to the
+ new file.
+ (rule, func_name, function_prologue, param_list): Reworked.
+ (install_function, check_params): Do all error checkings
+ for the function name and parameters before installing in
+ the symbol table.
+ (mk_function): Finalize function definition.
+ (func_install, append_param, dup_params): Nuked.
+ * symbol.c (make_params): allocate function parameter nodes
+ for the symbol table. Use the hash node as Node_param_list;
+ Saves a NODE for each parameter.
+ (install_params): Install function parameters into the symbol
+ table.
+ (remove_params): Remove parameters out of the symbol table.
+ * awk.h (parmlist, FUNC): Nuked.
+ (fparms): New define.
+
+
+ Dynamically loaded function parameters are now handled like
+ those for a builtin.
+
+ * awk.h (Node_ext_func, Op_ext_builtin): New types.
+ (Op_ext_func): Nuked.
+ * ext.c (make_builtin): Simplified.
+ (get_curfunc_arg_count): Nuked; Use the argument 'nargs' of
+ the extension function instead.
+ (get_argument, get_actual_argument): Adjust.
+ * eval.c (r_interpret): Update case Op_func_call for a dynamic
+ extension function. Handle the new opcode Op_ext_builtin.
+ * pprint (profile.c): Adjust.
+
+
+ Use a single variable to process gawk options.
+
+ * awk.h (do_flags): New variable.
+ (DO_LINT_INVALID, DO_LINT_ALL, DO_LINT_OLD, DO_TRADITIONAL,
+ DO_POSIX, DO_INTL, DO_NON_DEC_DATA, DO_INTERVALS,
+ DO_PROFILING, DO_DUMP_VARS, DO_TIDY_MEM,
+ DO_SANDBOX): New defines.
+ (do_traditional, do_posix, do_intervals, do_intl,
+ do_non_decimal_data, do_profiling, do_dump_vars,
+ do_tidy_mem, do_sandbox, do_lint,
+ do_lint_old): Defined as macros.
+ * main.c: Remove definitions of the do_XX variables. Add
+ do_flags definition.
+ * debug.c (execute_code, do_eval, parse_condition): Save
+ do_flags before executing/parsing and restore afterwards.
+
+
+ Nuke PERM flag. Always increment/decrement the reference
+ count for a Node_val. Simplifies macros and avoids
+ occassional memory leaks, specially in the debugger.
+
+ * awk.h (UPREF, DEREF, dupnode, unref): Simplified.
+ (mk_number): Nuked.
+ * (*.c): Increment the reference count of Nnull_string before
+ assigning as a value.
+
+
+ Revamped array handling mechanism for more speed and
+ less memory consumption.
+
+ * awk.h (union bucket_item, BUCKET): New definitions. Used as
+ bucket elements for the hash table implementations of arrays;
+ 40% space saving in 32 bit x86.
+ (buckets, nodes, array_funcs, array_base, array_capacity,
+ xarray, alookup, aexists, aclear, aremove, alist,
+ acopy, adump, NUM_AFUNCS): New defines.
+ (array_empty): New macro to test for an empty array.
+ (assoc_lookup, in_array): Defined as macros.
+ (enum assoc_list_flags): New declaration.
+ (Node_ahash, NUMIND): Nuked.
+ * eval.c (r_interpret): Adjust cases Op_subscript,
+ Op_subscript_lhs, Op_store_var and Op_arrayfor_incr.
+ * node.c (dupnode, unref): Removed code related to Node_ahash.
+ * str_array.c: New file to handle array with string indices.
+ * int_array.c: New file to handle array with integer indices.
+ * cint_array.c: New file. Special handling of arrays with
+ (mostly) consecutive integer indices.
+
+
+ Memory pool management reworked to handle NODE and BUCKET.
+
+ * awk.h (struct block_item, BLOCK, block_id): New definitions.
+ (getblock, freeblock): New macros.
+ (getbucket, freebucket): New macros to allocate and deallocate
+ a BUCKET.
+ (getnode, freenode): Adjusted.
+ * node.c (more_nodes): Nuked.
+ (more_blocks): New routine to allocate blocks of memory.
+
2011-08-24 Arnold D. Robbins <arnold@skeeve.com>
Fix pty co-process communication on Ubuntu GNU/Linux.
diff --git a/FUTURES b/FUTURES
index 6b570567..62225b12 100644
--- a/FUTURES
+++ b/FUTURES
@@ -11,18 +11,18 @@ don't bug us too much about schedules or what all this really means.
For 4.1
=======
- Merge gawk/pgawk/dgawk into one executable
+ DONE: Merge gawk/pgawk/dgawk into one executable
Consider removing use of and/or need for the protos.h file.
Consider moving var_value info into Node_var itself
to reduce memory usage.
- Merge xmlgawk -l feature
+ DONE: Merge xmlgawk -l feature
Merge xmlgawk XML extensions
- Integrate MPFR to provide high precision arithmetic.
+ DONE: Integrate MPFR to provide high precision arithmetic.
Continue code reviews / code cleanup
diff --git a/Makefile.am b/Makefile.am
index aeff42f5..8f6ee12e 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -79,17 +79,22 @@ SUBDIRS = \
test
# what to make and install
-bin_PROGRAMS = gawk pgawk dgawk
+bin_PROGRAMS = gawk
-# sources for both gawk and pgawk
+# sources for both gawk and dgawk
base_sources = \
array.c \
awk.h \
awkgram.y \
builtin.c \
+ cint_array.c \
+ cmd.h \
+ command.y \
custom.h \
+ debug.c \
dfa.c \
dfa.h \
+ eval.c \
ext.c \
field.c \
floatcomp.c \
@@ -100,11 +105,15 @@ base_sources = \
getopt1.c \
getopt_int.h \
gettext.h \
+ int_array.c \
+ interpret.h \
io.c \
mbsupport.h \
main.c \
+ mpfr.c \
msg.c \
node.c \
+ profile.c \
protos.h \
random.c \
random.h \
@@ -112,16 +121,15 @@ base_sources = \
regex.c \
regex.h \
replace.c \
+ str_array.c \
+ symbol.c \
version.c \
xalloc.h
-gawk_SOURCES = $(base_sources) eval.c profile.c
-pgawk_SOURCES = $(base_sources) eval_p.c profile_p.c
-dgawk_SOURCES = $(base_sources) eval_d.c profile.c cmd.h command.y debug.c
+gawk_SOURCES = $(base_sources)
# Get extra libs as needed, Automake will supply LIBINTL and SOCKET_LIBS.
-LDADD = $(LIBSIGSEGV) $(LIBINTL) $(SOCKET_LIBS)
-dgawk_LDADD = $(LDADD) @LIBREADLINE@
+LDADD = $(LIBSIGSEGV) $(LIBINTL) $(SOCKET_LIBS) @LIBREADLINE@ @LIBMPFR@
# Directory for gawk's data files. Automake supplies datadir.
pkgdatadir = $(datadir)/awk
@@ -140,7 +148,6 @@ MAINTAINERCLEANFILES = version.c
LN= ln
# First, add a link from gawk to gawk-X.Y.Z.
-# Same for pgawk.
#
# For GNU systems where gawk is awk, add a link to awk.
# (This is done universally, which may not always be right, but
@@ -148,7 +155,6 @@ LN= ln
install-exec-hook:
(cd $(DESTDIR)$(bindir); \
$(LN) gawk$(EXEEXT) gawk-$(VERSION)$(EXEEXT) 2>/dev/null ; \
- $(LN) pgawk$(EXEEXT) pgawk-$(VERSION)$(EXEEXT) 2>/dev/null ; \
if [ ! -f awk ]; \
then $(LN_S) gawk$(EXEEXT) awk; \
fi; exit 0)
@@ -157,12 +163,12 @@ install-exec-hook:
uninstall-links:
(cd $(DESTDIR)$(bindir); \
if [ -f awk ] && cmp awk gawk$(EXEEXT) > /dev/null; then rm -f awk; fi ; \
- rm -f gawk-$(VERSION)$(EXEEXT) pgawk-$(VERSION)$(EXEEXT); exit 0)
+ rm -f gawk-$(VERSION)$(EXEEXT); exit 0)
uninstall-recursive: uninstall-links
# force there to be a gawk executable before running tests
-check-local: gawk$(EXEEXT) pgawk$(EXEEXT)
+check-local: gawk$(EXEEXT)
# A little extra clean up when making distributions.
# And additional set up for the pc directory.
@@ -177,6 +183,7 @@ dist-hook:
# Special rules for individual files
# Use of awk instead of $(AWK) is deliberate, in case gawk doesn't build
# or work correctly.
+
awkgram.c: awkgram.y
$(YACC) $(AM_YFLAGS) $(YFLAGS) $<
sed 's/parse error/syntax error/g' < y.tab.c | awk -f $(srcdir)/bisonfix.awk awkgram > $*.c && rm y.tab.c
diff --git a/Makefile.in b/Makefile.in
index 0b359056..2d28a59c 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -73,7 +73,7 @@ PRE_UNINSTALL = :
POST_UNINSTALL = :
build_triplet = @build@
host_triplet = @host@
-bin_PROGRAMS = gawk$(EXEEXT) pgawk$(EXEEXT) dgawk$(EXEEXT)
+bin_PROGRAMS = gawk$(EXEEXT)
subdir = .
DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \
$(srcdir)/Makefile.in $(srcdir)/configh.in \
@@ -88,11 +88,11 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/arch.m4 \
$(top_srcdir)/m4/isc-posix.m4 $(top_srcdir)/m4/lcmessage.m4 \
$(top_srcdir)/m4/lib-ld.m4 $(top_srcdir)/m4/lib-link.m4 \
$(top_srcdir)/m4/lib-prefix.m4 $(top_srcdir)/m4/libsigsegv.m4 \
- $(top_srcdir)/m4/longlong.m4 $(top_srcdir)/m4/nls.m4 \
- $(top_srcdir)/m4/noreturn.m4 $(top_srcdir)/m4/po.m4 \
- $(top_srcdir)/m4/progtest.m4 $(top_srcdir)/m4/readline.m4 \
- $(top_srcdir)/m4/socket.m4 $(top_srcdir)/m4/ulonglong.m4 \
- $(top_srcdir)/configure.ac
+ $(top_srcdir)/m4/longlong.m4 $(top_srcdir)/m4/mpfr.m4 \
+ $(top_srcdir)/m4/nls.m4 $(top_srcdir)/m4/noreturn.m4 \
+ $(top_srcdir)/m4/po.m4 $(top_srcdir)/m4/progtest.m4 \
+ $(top_srcdir)/m4/readline.m4 $(top_srcdir)/m4/socket.m4 \
+ $(top_srcdir)/m4/ulonglong.m4 $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
@@ -104,29 +104,20 @@ CONFIG_CLEAN_VPATH_FILES =
am__installdirs = "$(DESTDIR)$(bindir)"
PROGRAMS = $(bin_PROGRAMS)
am__objects_1 = array.$(OBJEXT) awkgram.$(OBJEXT) builtin.$(OBJEXT) \
- dfa.$(OBJEXT) ext.$(OBJEXT) field.$(OBJEXT) \
+ cint_array.$(OBJEXT) command.$(OBJEXT) debug.$(OBJEXT) \
+ dfa.$(OBJEXT) eval.$(OBJEXT) ext.$(OBJEXT) field.$(OBJEXT) \
floatcomp.$(OBJEXT) gawkmisc.$(OBJEXT) getopt.$(OBJEXT) \
- getopt1.$(OBJEXT) io.$(OBJEXT) main.$(OBJEXT) msg.$(OBJEXT) \
- node.$(OBJEXT) random.$(OBJEXT) re.$(OBJEXT) regex.$(OBJEXT) \
- replace.$(OBJEXT) version.$(OBJEXT)
-am_dgawk_OBJECTS = $(am__objects_1) eval_d.$(OBJEXT) profile.$(OBJEXT) \
- command.$(OBJEXT) debug.$(OBJEXT)
-dgawk_OBJECTS = $(am_dgawk_OBJECTS)
-am__DEPENDENCIES_1 =
-am__DEPENDENCIES_2 = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \
- $(am__DEPENDENCIES_1)
-dgawk_DEPENDENCIES = $(am__DEPENDENCIES_2)
-am_gawk_OBJECTS = $(am__objects_1) eval.$(OBJEXT) profile.$(OBJEXT)
+ getopt1.$(OBJEXT) int_array.$(OBJEXT) io.$(OBJEXT) \
+ main.$(OBJEXT) mpfr.$(OBJEXT) msg.$(OBJEXT) node.$(OBJEXT) \
+ profile.$(OBJEXT) random.$(OBJEXT) re.$(OBJEXT) \
+ regex.$(OBJEXT) replace.$(OBJEXT) str_array.$(OBJEXT) \
+ symbol.$(OBJEXT) version.$(OBJEXT)
+am_gawk_OBJECTS = $(am__objects_1)
gawk_OBJECTS = $(am_gawk_OBJECTS)
gawk_LDADD = $(LDADD)
+am__DEPENDENCIES_1 =
gawk_DEPENDENCIES = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \
$(am__DEPENDENCIES_1)
-am_pgawk_OBJECTS = $(am__objects_1) eval_p.$(OBJEXT) \
- profile_p.$(OBJEXT)
-pgawk_OBJECTS = $(am_pgawk_OBJECTS)
-pgawk_LDADD = $(LDADD)
-pgawk_DEPENDENCIES = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \
- $(am__DEPENDENCIES_1)
DEFAULT_INCLUDES = -I.@am__isrc@
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
@@ -139,8 +130,8 @@ am__yacc_c2h = sed -e s/cc$$/hh/ -e s/cpp$$/hpp/ -e s/cxx$$/hxx/ \
-e s/c++$$/h++/ -e s/c$$/h/
YACCCOMPILE = $(YACC) $(AM_YFLAGS) $(YFLAGS)
YLWRAP = $(top_srcdir)/ylwrap
-SOURCES = $(dgawk_SOURCES) $(gawk_SOURCES) $(pgawk_SOURCES)
-DIST_SOURCES = $(dgawk_SOURCES) $(gawk_SOURCES) $(pgawk_SOURCES)
+SOURCES = $(gawk_SOURCES)
+DIST_SOURCES = $(gawk_SOURCES)
RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
html-recursive info-recursive install-data-recursive \
install-dvi-recursive install-exec-recursive \
@@ -240,6 +231,7 @@ INTL_MACOSX_LIBS = @INTL_MACOSX_LIBS@
LDFLAGS = @LDFLAGS@
LIBICONV = @LIBICONV@
LIBINTL = @LIBINTL@
+LIBMPFR = @LIBMPFR@
LIBOBJS = @LIBOBJS@
LIBREADLINE = @LIBREADLINE@
LIBS = @LIBS@
@@ -385,15 +377,20 @@ SUBDIRS = \
test
-# sources for both gawk and pgawk
+# sources for both gawk and dgawk
base_sources = \
array.c \
awk.h \
awkgram.y \
builtin.c \
+ cint_array.c \
+ cmd.h \
+ command.y \
custom.h \
+ debug.c \
dfa.c \
dfa.h \
+ eval.c \
ext.c \
field.c \
floatcomp.c \
@@ -404,11 +401,15 @@ base_sources = \
getopt1.c \
getopt_int.h \
gettext.h \
+ int_array.c \
+ interpret.h \
io.c \
mbsupport.h \
main.c \
+ mpfr.c \
msg.c \
node.c \
+ profile.c \
protos.h \
random.c \
random.h \
@@ -416,16 +417,15 @@ base_sources = \
regex.c \
regex.h \
replace.c \
+ str_array.c \
+ symbol.c \
version.c \
xalloc.h
-gawk_SOURCES = $(base_sources) eval.c profile.c
-pgawk_SOURCES = $(base_sources) eval_p.c profile_p.c
-dgawk_SOURCES = $(base_sources) eval_d.c profile.c cmd.h command.y debug.c
+gawk_SOURCES = $(base_sources)
# Get extra libs as needed, Automake will supply LIBINTL and SOCKET_LIBS.
-LDADD = $(LIBSIGSEGV) $(LIBINTL) $(SOCKET_LIBS)
-dgawk_LDADD = $(LDADD) @LIBREADLINE@
+LDADD = $(LIBSIGSEGV) $(LIBINTL) $(SOCKET_LIBS) @LIBREADLINE@ @LIBMPFR@
# stuff for compiling gawk/pgawk
DEFPATH = '".$(PATH_SEPARATOR)$(pkgdatadir)"'
@@ -530,15 +530,9 @@ uninstall-binPROGRAMS:
clean-binPROGRAMS:
-test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS)
-dgawk$(EXEEXT): $(dgawk_OBJECTS) $(dgawk_DEPENDENCIES) $(EXTRA_dgawk_DEPENDENCIES)
- @rm -f dgawk$(EXEEXT)
- $(LINK) $(dgawk_OBJECTS) $(dgawk_LDADD) $(LIBS)
gawk$(EXEEXT): $(gawk_OBJECTS) $(gawk_DEPENDENCIES) $(EXTRA_gawk_DEPENDENCIES)
@rm -f gawk$(EXEEXT)
$(LINK) $(gawk_OBJECTS) $(gawk_LDADD) $(LIBS)
-pgawk$(EXEEXT): $(pgawk_OBJECTS) $(pgawk_DEPENDENCIES) $(EXTRA_pgawk_DEPENDENCIES)
- @rm -f pgawk$(EXEEXT)
- $(LINK) $(pgawk_OBJECTS) $(pgawk_LDADD) $(LIBS)
mostlyclean-compile:
-rm -f *.$(OBJEXT)
@@ -549,28 +543,30 @@ distclean-compile:
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/array.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/awkgram.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/builtin.Po@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cint_array.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/command.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/debug.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dfa.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/eval.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/eval_d.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/eval_p.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ext.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/field.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/floatcomp.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gawkmisc.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/getopt.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/getopt1.Po@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/int_array.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/io.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/main.Po@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mpfr.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/msg.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/node.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/profile.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/profile_p.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/random.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/re.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/regex.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/replace.Po@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/str_array.Po@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/symbol.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/version.Po@am__quote@
.c.o:
@@ -1077,7 +1073,6 @@ uninstall-am: uninstall-binPROGRAMS
# First, add a link from gawk to gawk-X.Y.Z.
-# Same for pgawk.
#
# For GNU systems where gawk is awk, add a link to awk.
# (This is done universally, which may not always be right, but
@@ -1085,7 +1080,6 @@ uninstall-am: uninstall-binPROGRAMS
install-exec-hook:
(cd $(DESTDIR)$(bindir); \
$(LN) gawk$(EXEEXT) gawk-$(VERSION)$(EXEEXT) 2>/dev/null ; \
- $(LN) pgawk$(EXEEXT) pgawk-$(VERSION)$(EXEEXT) 2>/dev/null ; \
if [ ! -f awk ]; \
then $(LN_S) gawk$(EXEEXT) awk; \
fi; exit 0)
@@ -1094,12 +1088,12 @@ install-exec-hook:
uninstall-links:
(cd $(DESTDIR)$(bindir); \
if [ -f awk ] && cmp awk gawk$(EXEEXT) > /dev/null; then rm -f awk; fi ; \
- rm -f gawk-$(VERSION)$(EXEEXT) pgawk-$(VERSION)$(EXEEXT); exit 0)
+ rm -f gawk-$(VERSION)$(EXEEXT); exit 0)
uninstall-recursive: uninstall-links
# force there to be a gawk executable before running tests
-check-local: gawk$(EXEEXT) pgawk$(EXEEXT)
+check-local: gawk$(EXEEXT)
# A little extra clean up when making distributions.
# And additional set up for the pc directory.
@@ -1114,6 +1108,7 @@ dist-hook:
# Special rules for individual files
# Use of awk instead of $(AWK) is deliberate, in case gawk doesn't build
# or work correctly.
+
awkgram.c: awkgram.y
$(YACC) $(AM_YFLAGS) $(YFLAGS) $<
sed 's/parse error/syntax error/g' < y.tab.c | awk -f $(srcdir)/bisonfix.awk awkgram > $*.c && rm y.tab.c
diff --git a/NEWS b/NEWS
index c5d28c1e..04f2a87b 100644
--- a/NEWS
+++ b/NEWS
@@ -3,6 +3,18 @@
Copying and distribution of this file, with or without modification,
are permitted in any medium without royalty provided the copyright
notice and this notice are preserved.
+
+Changes from 4.0.1 to 4.1
+-------------------------
+1. The three executables gawk, pgawk, and dgawk, have been merged into
+ one, named just gawk. As a result:
+ * The -R option is gone
+ * Use -D to run the debugger. An optional file argument is a
+ list of commands to run first.
+ * Use -o to do pretty-printing only.
+ * Use -p to do profiling.
+
+2. The new -l option is used for loading dynamic extensions.
Changes from 4.0.1 to 4.0.2
---------------------------
diff --git a/README.git b/README.git
index f14588e1..70840f3a 100644
--- a/README.git
+++ b/README.git
@@ -18,7 +18,268 @@ comp.lang.awk is generally a bad idea, no matter what the purpose, but
especially if you wish to report a gawk bug. Use the above email address.
Really.
+You can find gawk's GIT repository at Savannah
+https://savannah.gnu.org/git/?group=gawk
+
+Detailed instructions on using and contributing to gawk can also be
+found at Savannah, see http://savannah.gnu.org/maintenance/UsingGit
+
Thanks,
Arnold Robbins
Gawk Maintainer
+
+=====================================================================
+Here are some questions and answers related to using git compiled
+by several of the gawk maintainers.
+
+- How can I check out the GIT repository ?
+
+Depending upon your working habits, there are several options.
+1. On the Linux command line use the git command (details see below)
+2. With Microsoft Windows, use TortoiseGIT
+3. On both platforms Eclipse with its EGIT plugin is an excellent choice
+
+On the Linux command line use git to check out the repository.
+With Microsoft Windows, use TortoiseGIT.
+
+
+- Where is TortoiseGIT and how do I install it ?
+
+Follow these instructions for installation:
+ https://github.com/multitheftauto/multitheftauto/wiki/how-to-use-tortoisegit
+
+Begin with installing Putty, then msysgit and finally TortoiseGIT.
+Find Putty at http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html
+
+
+- What about the SSH keys needed when Windows is my primary environment ?
+
+On Windows you may use Puttygen for generating keys.
+Save both keys (public and private) in a local .ppk file.
+Notice that this file is highly confidential and even other
+team members are not supposed to see your keys.
+Finally you need to convert Putty's keys (.ppk file) so that they
+can also be used on Linux.
+ http://www.laszlomolnar.name/open-source/tips-and-tutorials/how-to-convert-puttys-private-key-ppk-into-opensshs-private-key-format-in-linux.html
+
+ puttygen my_keys.ppk -O private-openssh -o .ssh/id_rsa
+ puttygen my_keys.ppk -O public-openssh -o .ssh/id_rsa.pub
+
+
+- What about the SSH keys needed when Linux is my primary environment ?
+
+On Linux follow these instructions to generate keys:
+http://www.guyrutenberg.com/2007/10/05/ssh-keygen-tutorial-generating-rsa-and-dsa-keys/
+If you ever need these keys inside a Windows environment, use Puttygen
+to import the already existing keys.
+
+
+- I know Subversion, now what's different with git ?
+
+Read the "Git - SVN Crash Course". It lists the Subversion commands that
+are roughly equivalent to certain git commands:
+ http://www.pronego.com/helpdesk/knowledgebase.php?article=49
+This document is only one of many copies of the document on the Internet.
+You should read the original (which is currently offline and unreachable):
+ https://git.wiki.kernel.org/index.php/GitSvnCrashCourse
+
+
+- How can I check out this repository inside a clean subdirectory ?
+
+ mkdir -p workspace/git
+ cd workspace/git
+ git clone git://git.sv.gnu.org/project.git
+
+ git remote -v
+ origin ssh://jkahrs@git.sv.gnu.org/srv/git/gawk.git (fetch)
+ origin ssh://jkahrs@git.sv.gnu.org/srv/git/gawk.git (push)
+
+
+- How can I check out this repository with Eclipse ?
+
+Use the most recent version of Eclipse, it already comes with the
+EGIT plugin installed.
+ Select File -> Import -> Git -> Git Repository.
+ Press clone and maintain the git repository "ssh://jkahrs@git.sv.gnu.org/srv/git/gawk.git".
+ You only have to paste the URL to the first line of the dialog,
+ the rest will be filled out automatically.
+
+You can find details in the EGIT tutorial.
+ http://www.vogella.de/articles/EGit/article.html#respository_checkoutproject
+
+
+- Can I start adding new files to the repository right now ?
+Yes, you can, but you should not do so.
+Convention with branches.
+
+But first you should make sure some global settings identifying
+you are set. The global settings will be used every time you commit
+something to the repository.
+
+ git config --global user.name "First-Name Last-Name"
+ git config --global user.email email@address.site
+ git config --global color.ui auto
+
+
+- How can I inspect my settings ?
+
+
+ git config --list
+ giggle.main-window-maximized=false
+ giggle.main-window-geometry=1369x753+183+81
+ giggle.main-window-view=HistoryView
+ giggle.history-view-vpane-position=389
+ giggle.file-view-vpane-position=293
+ user.name=First-Name Last-Name
+ user.email=email@address.site
+ color.diff=auto
+ color.status=auto
+ color.branch=auto
+ gui.spellingdictionary=en_US
+ core.repositoryformatversion=0
+ core.filemode=true
+ core.bare=false
+ core.logallrefupdates=true
+ remote.origin.fetch=+refs/heads/*:refs/remotes/origin/*
+ remote.origin.url=ssh://jkahrs@git.sv.gnu.org/srv/git/gawk.git
+ branch.master.remote=origin
+ branch.master.merge=refs/heads/master
+ branch.xgawk_load.remote=origin
+ branch.xgawk_load.merge=refs/heads/xgawk_load
+
+
+- How can I get or set a specific variable of the settings ?
+
+ git config --get color.ui
+ git config --set color.ui auto
+
+
+- How can I create new files or directories to the repository ?
+
+ touch README
+ git add README
+ git commit -m "first commit"
+
+
+- What did I change since the last commit ?
+
+ git diff README
+ git diff
+
+
+- I have committed everything to my local repository, now how can I
+ "push" these changes up to gawk.git ?
+
+ git push -u origin master # push up to master branch
+ git push -u origin my_feature_branch # push up to my own branch
+
+
+- How can I inspect the list of branches of my repository ?
+
+ git branch # shows all local branches
+ git branch -r # shows all remote branches
+ git branch -a # shows all local and all remote branches
+
+
+- How can I change to a different branch ?
+
+ git checkout my_stuff # change to branch my_stuff
+ git checkout -b my_stuff # create new branch my_stuff and change to it
+
+- How can I create a branch ?
+
+For each new feature to be considered for inclusion into future
+releasses, a new branch shall be created. Upon creation, this new
+branch shall be based on the master branch.
+
+ # make master branch the base
+ git checkout master
+ git branch my_new_feature_branch
+ touch my_new_file.c
+ git add my_new_file.c
+ git status
+ git commit -m "Created new feature branch."
+ git push -u origin my_new_feature_branch
+ git checkout my_new_feature_branch
+
+- How can I throw away an obsolete branch ?
+
+ git push origin :newfeature # remove remote branch
+ git checkout -f master # switch back from newfeature to master, ignoring changes
+ git branch -D newfeature # remove local branch
+
+
+- I have made stupid changes to a file and want the original back, how ?
+
+ svn checkout file_name.ext
+
+ This will only work if the file was not yet committed.
+ If you have already committed the change and want back the
+ last pushed version, use "git reset" instead.
+
+
+- Who changed a specific line in my file ?
+
+Sometimes you need to find out whom to blame for a certain line of a change.
+git can tell you for each line who did the most recent change of the line.
+
+ git blame README
+
+
+- Who else has ever changed my file, when and why ?
+
+You can inspect the log history file-wise but also directory-wise.
+
+ git log README
+ git log
+
+
+- How to fix a broken repository ?
+
+ git fsck
+
+- How to clean up my repository (garbage collection) ?
+
+ git gc
+
+- I'm a devoted user of Bazaar, and don't want to switch to git. Is
+ there any way for me to track Gawk development with bzr?
+
+Yes, there is. First, install the latest version of bzr (2.5.0 or
+later is required). If it doesn't come with the bzr-git plugin,
+download and install it from https://launchpad.net/bzr-git. You will
+also need dulwich, which is a Python implementation of the git
+protocol; get it from http://www.samba.org/~jelmer/dulwich/.
+
+(To know whether you have bzr-git, type "bzr plugins".)
+
+Next, clone the Gawk git repository with this command:
+
+ bzr git-import git://git.savannah.gnu.org/gawk.git gawk
+
+This will create a directory called 'gawk' with meta-data of the
+repository, but without any working trees. To checkout the files,
+chdir to that directory and type:
+
+ bzr checkout
+
+This will checkout the files for the default branch. To see the list
+of branches, type
+
+ bzr branches
+
+To switch to another branch, type
+
+ bzr switch --force BRANCH
+
+where BRANCH is the name of the branch, e.g. 'xgawk'. (The --force
+option is a workaround for an annoying misfeature in bzr 2.5.0, which
+will most probably be resolved in the near future.)
+
+To sync the current branch with upstream, type
+
+ bzr pull
+
+If you want to update several branches, "bzr switch" to each one in
+turn, followed by "bzr pull" to sync the branch.
diff --git a/README_d/ChangeLog b/README_d/ChangeLog
index b29f67a2..0310bd8d 100644
--- a/README_d/ChangeLog
+++ b/README_d/ChangeLog
@@ -1,3 +1,11 @@
+2012-04-11 John Haque <j.eh@mchsi.com>
+
+ * README.hacking: New file.
+
+2012-04-01 John Haque <j.eh@mchsi.com>
+
+ * README.mpfr: New file.
+
2012-03-28 Arnold D. Robbins <arnold@skeeve.com>
* 4.0.1: Release tar ball made.
diff --git a/README_d/README.hacking b/README_d/README.hacking
new file mode 100644
index 00000000..dcb57359
--- /dev/null
+++ b/README_d/README.hacking
@@ -0,0 +1,11 @@
+* Use one of the following macros to access the value of a numeric NODE:
+ Macro Returned C type
+ ---------------------------------------
+ get_number_ui(n) unsigned long
+ get_number_si(n) long
+ get_number_d(n) double
+ get_number_uj(n) uintmax_t
+
+* Use iszero(n) to test if a numeric NODE is zero.
+
+ \ No newline at end of file
diff --git a/README_d/README.mpfr b/README_d/README.mpfr
new file mode 100644
index 00000000..b12c19b6
--- /dev/null
+++ b/README_d/README.mpfr
@@ -0,0 +1,25 @@
+Sat Mar 17 07:32:01 CDT 2012
+=============================
+
+The MPFR and GMP versions known to work for Mac OS X on PPC:
+GNU MPFR 3.1.0, GNU MP 4.3.1
+
+----
+Precompiled binaries for GMP and MPFR in Windows may be available
+from here:
+
+ http://sourceforge.net/projects/ezwinports/files/
+
+or here:
+
+ http://sourceforge.net/projects/mingw/files/MinGW/Base/mpfr/
+ http://sourceforge.net/projects/mingw/files/MinGW/Base/gmp/
+
+You should try to use libraries downloaded from the same site
+to avoid possible incompatibilities.
+
+----
+Gawk has been compiled and tested using the following combinations
+of MPFR and GMP versions on GNU/Linux:
+GNU MPFR 2.4.2, GNU MP 4.3.2
+GNU MPFR 3.1.0, GNU MP 5.0.3
diff --git a/TODO b/TODO
index ab38248c..0b79c026 100644
--- a/TODO
+++ b/TODO
@@ -11,6 +11,8 @@ Really make failure to open a socket a non-fatal error (for 4.1).
?? Scope IDs for IPv6 addresses ??
+Merge the chapter and the appendix on floating-point math (for 4.1).
+
------
Code Review:
diff --git a/aclocal.m4 b/aclocal.m4
index b4c9c49d..1ae4be15 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -996,6 +996,7 @@ m4_include([m4/lib-link.m4])
m4_include([m4/lib-prefix.m4])
m4_include([m4/libsigsegv.m4])
m4_include([m4/longlong.m4])
+m4_include([m4/mpfr.m4])
m4_include([m4/nls.m4])
m4_include([m4/noreturn.m4])
m4_include([m4/po.m4])
diff --git a/array.c b/array.c
index e814e976..c8e230f7 100644
--- a/array.c
+++ b/array.c
@@ -1,5 +1,5 @@
/*
- * array.c - routines for associative arrays.
+ * array.c - routines for awk arrays.
*/
/*
@@ -25,69 +25,194 @@
#include "awk.h"
+extern FILE *output_fp;
+extern NODE **fmt_list; /* declared in eval.c */
+extern array_ptr str_array_func[];
+extern array_ptr cint_array_func[];
+extern array_ptr int_array_func[];
+
+static size_t SUBSEPlen;
+static char *SUBSEP;
+static char indent_char[] = " ";
+
+static NODE **null_lookup(NODE *symbol, NODE *subs);
+static NODE **null_afunc(NODE *symbol, NODE *subs);
+static NODE **null_dump(NODE *symbol, NODE *subs);
+static array_ptr null_array_func[] = {
+ (array_ptr) 0,
+ (array_ptr) 0,
+ null_lookup,
+ null_afunc,
+ null_afunc,
+ null_afunc,
+ null_afunc,
+ null_afunc,
+ null_dump,
+};
+
+#define MAX_ATYPE 10
+
+static array_ptr *atypes[MAX_ATYPE];
+static int num_atypes = 0;
+
/*
- * Tree walks (``for (iggy in foo)'') and array deletions use expensive
- * linear searching. So what we do is start out with small arrays and
- * grow them as needed, so that our arrays are hopefully small enough,
- * most of the time, that they're pretty full and we're not looking at
- * wasted space.
- *
- * The decision is made to grow the array if the average chain length is
- * ``too big''. This is defined as the total number of entries in the table
- * divided by the size of the array being greater than some constant.
+ * register_array_func --- add routines to handle arrays.
*
- * We make the constant a variable, so that it can be tweaked
- * via environment variable.
+ * index 0 : initialization.
+ * index 1 : check if index is compatible.
+ * index 8 : array dump, memory and other statistics (do_adump).
*/
+
-static size_t AVG_CHAIN_MAX = 2; /* Modern machines are bigger, reduce this from 10. */
+int
+register_array_func(array_ptr *afunc)
+{
+ if (afunc && num_atypes < MAX_ATYPE) {
+ if (afunc != str_array_func && ! afunc[1])
+ return FALSE;
+ atypes[num_atypes++] = afunc;
+ if (afunc[0]) /* execute init routine if any */
+ (void) (*afunc[0])(NULL, NULL);
+ return TRUE;
+ }
+ return FALSE;
+}
-static size_t SUBSEPlen;
-static char *SUBSEP;
-static NODE *assoc_find(NODE *symbol, NODE *subs, unsigned long hash1, NODE **last);
-static void grow_table(NODE *symbol);
+/* array_init --- register all builtin array types */
-static unsigned long gst_hash_string(const char *str, size_t len, unsigned long hsize, size_t *code);
-static unsigned long scramble(unsigned long x);
-static unsigned long awk_hash(const char *s, size_t len, unsigned long hsize, size_t *code);
+void
+array_init()
+{
+ (void) register_array_func(str_array_func); /* the default */
+ if (! do_mpfr) {
+ (void) register_array_func(int_array_func);
+ (void) register_array_func(cint_array_func);
+ }
+}
-unsigned long (*hash)(const char *s, size_t len, unsigned long hsize, size_t *code) = awk_hash;
-/* qsort comparison function */
-static int sort_up_index_string(const void *, const void *);
-static int sort_down_index_string(const void *, const void *);
-static int sort_up_index_number(const void *, const void *);
-static int sort_down_index_number(const void *, const void *);
-static int sort_up_value_string(const void *, const void *);
-static int sort_down_value_string(const void *, const void *);
-static int sort_up_value_number(const void *, const void *);
-static int sort_down_value_number(const void *, const void *);
-static int sort_up_value_type(const void *, const void *);
-static int sort_down_value_type(const void *, const void *);
+/* make_array --- create an array node */
-/* array_init --- check relevant environment variables */
+NODE *
+make_array()
+{
+ NODE *array;
+ getnode(array);
+ memset(array, '\0', sizeof(NODE));
+ array->type = Node_var_array;
+ array->array_funcs = null_array_func;
+ /* vname, flags, and parent_array not set here */
+
+ return array;
+}
+
+
+/* init_array --- (re)initialize an array node */
void
-array_init()
+init_array(NODE *symbol)
{
- const char *val;
- char *endptr;
- size_t newval;
-
- if ((val = getenv("AVG_CHAIN_MAX")) != NULL && isdigit((unsigned char) *val)) {
- newval = strtoul(val, & endptr, 10);
- if (endptr != val && newval > 0)
- AVG_CHAIN_MAX = newval;
+ symbol->type = Node_var_array;
+ symbol->array_funcs = null_array_func;
+ symbol->buckets = NULL;
+ symbol->table_size = symbol->array_size = 0;
+ symbol->array_capacity = 0;
+
+ assert(symbol->xarray == NULL);
+ /* symbol->xarray = NULL; */
+
+ /* flags, vname, parent_array not (re)initialized */
+}
+
+
+/* null_lookup: assign type to an empty array. */
+
+static NODE **
+null_lookup(NODE *symbol, NODE *subs)
+{
+ int i;
+ array_ptr *afunc = NULL;
+
+ assert(symbol->table_size == 0);
+
+ /* Check which array type wants to accept this sub; traverse
+ * array type list in reverse order.
+ */
+ for (i = num_atypes - 1; i >= 1; i--) {
+ afunc = atypes[i];
+ if (afunc[1](symbol, subs) != NULL)
+ break;
}
+ if (i == 0 || afunc == NULL)
+ afunc = atypes[0]; /* default is str_array_func */
+ symbol->array_funcs = afunc;
- if ((val = getenv("AWK_HASH")) != NULL && strcmp(val, "gst") == 0)
- hash = gst_hash_string;
+ /* We have the right type of array; install the subscript */
+ return symbol->alookup(symbol, subs);
}
+
+/* null_afunc --- dummy function for an empty array */
+
+static NODE **
+null_afunc(NODE *symbol ATTRIBUTE_UNUSED, NODE *subs ATTRIBUTE_UNUSED)
+{
+ return NULL;
+}
+
+/* null_dump --- dump function for an empty array */
+
+static NODE **
+null_dump(NODE *symbol, NODE *subs ATTRIBUTE_UNUSED)
+{
+ fprintf(output_fp, "array `%s' is empty\n", array_vname(symbol));
+ return NULL;
+}
+
+
+/* r_in_array --- test whether the array element symbol[subs] exists or not,
+ * return pointer to value if it does.
+ */
+
+NODE *
+r_in_array(NODE *symbol, NODE *subs)
+{
+ NODE **ret;
+
+ ret = symbol->aexists(symbol, subs);
+ return (ret ? *ret : NULL);
+}
+
+
+/* assoc_copy --- duplicate input array "symbol" */
+
+NODE *
+assoc_copy(NODE *symbol, NODE *newsymb)
+{
+ assert(newsymb->vname != NULL);
+
+ assoc_clear(newsymb);
+ (void) symbol->acopy(symbol, newsymb);
+ newsymb->array_funcs = symbol->array_funcs;
+ newsymb->flags = symbol->flags;
+ return newsymb;
+}
+
+
+/* assoc_dump --- dump array */
+
+void
+assoc_dump(NODE *symbol, NODE *ndump)
+{
+ if (symbol->adump)
+ (void) symbol->adump(symbol, ndump);
+}
+
+
/* make_aname --- construct a 'vname' for a (sub)array */
-static char *
+const char *
make_aname(const NODE *symbol)
{
static char *aname = NULL;
@@ -115,10 +240,11 @@ make_aname(const NODE *symbol)
erealloc(aname, char *, (max_alen + 1) * sizeof(char *), "make_aname");
}
memcpy(aname, symbol->vname, alen + 1);
- }
+ }
return aname;
-#undef SLEN
}
+#undef SLEN
+
/*
* array_vname --- print the name of the array
@@ -128,7 +254,7 @@ make_aname(const NODE *symbol)
* to save it, they have to make a copy.
*/
-char *
+const char *
array_vname(const NODE *symbol)
{
static char *message = NULL;
@@ -164,7 +290,6 @@ array_vname(const NODE *symbol)
else
aname = make_aname(symbol);
len += strlen(aname);
-
/*
* Each node contributes by strlen(from) minus the length
* of "%s" in the translation (which is at least 2)
@@ -218,7 +343,7 @@ get_array(NODE *symbol, int canfatal)
NODE *save_symbol = symbol;
int isparam = FALSE;
- if (symbol->type == Node_param_list && (symbol->flags & FUNC) == 0) {
+ if (symbol->type == Node_param_list) {
save_symbol = symbol = GET_PARAM(symbol->param_cnt);
isparam = TRUE;
if (symbol->type == Node_array_ref)
@@ -227,35 +352,24 @@ get_array(NODE *symbol, int canfatal)
switch (symbol->type) {
case Node_var_new:
- symbol->type = Node_var_array;
- symbol->var_array = NULL;
+ init_array(symbol);
symbol->parent_array = NULL; /* main array has no parent */
/* fall through */
case Node_var_array:
break;
case Node_array_ref:
- case Node_param_list:
- if ((symbol->flags & FUNC) == 0)
- cant_happen();
- /* else
- fall through */
-
default:
- /* notably Node_var but catches also e.g. FS[1] = "x" */
+ /* notably Node_var but catches also e.g. a[1] = "x"; a[1][1] = "y" */
if (canfatal) {
if (symbol->type == Node_val)
fatal(_("attempt to use a scalar value as array"));
-
- if ((symbol->flags & FUNC) != 0)
- fatal(_("attempt to use function `%s' as an array"),
- save_symbol->vname);
- else if (isparam)
+ if (isparam)
fatal(_("attempt to use scalar parameter `%s' as an array"),
- save_symbol->vname);
+ save_symbol->vname);
else
fatal(_("attempt to use scalar `%s' as an array"),
- save_symbol->vname);
+ save_symbol->vname);
} else
break;
}
@@ -269,16 +383,18 @@ get_array(NODE *symbol, int canfatal)
void
set_SUBSEP()
{
- SUBSEP = force_string(SUBSEP_node->var_value)->stptr;
+ SUBSEP_node->var_value = force_string(SUBSEP_node->var_value);
+ SUBSEP = SUBSEP_node->var_value->stptr;
SUBSEPlen = SUBSEP_node->var_value->stlen;
-}
+}
+
/* concat_exp --- concatenate expression list into a single string */
NODE *
concat_exp(int nargs, int do_subsep)
{
- /* do_subsep is false for Node-concat */
+ /* do_subsep is FALSE for Op_concat */
NODE *r;
char *str;
char *s;
@@ -295,13 +411,14 @@ concat_exp(int nargs, int do_subsep)
len = 0;
for (i = 1; i <= nargs; i++) {
- r = POP();
+ r = TOP();
if (r->type == Node_var_array) {
while (--i > 0)
DEREF(args_array[i]); /* avoid memory leak */
fatal(_("attempt to use array `%s' in a scalar context"), array_vname(r));
- }
- args_array[i] = force_string(r);
+ }
+ r = POP_STRING();
+ args_array[i] = r;
len += r->stlen;
}
len += (nargs - 1) * subseplen;
@@ -329,246 +446,6 @@ concat_exp(int nargs, int do_subsep)
}
-/* assoc_clear --- flush all the values in symbol[] */
-
-void
-assoc_clear(NODE *symbol)
-{
- long i;
- NODE *bucket, *next;
-
- if (symbol->var_array == NULL)
- return;
-
- for (i = 0; i < symbol->array_size; i++) {
- for (bucket = symbol->var_array[i]; bucket != NULL; bucket = next) {
- next = bucket->ahnext;
- if (bucket->ahvalue->type == Node_var_array) {
- NODE *r = bucket->ahvalue;
- assoc_clear(r); /* recursively clear all sub-arrays */
- efree(r->vname);
- freenode(r);
- } else
- unref(bucket->ahvalue);
-
- unref(bucket); /* unref() will free the ahname_str */
- }
- symbol->var_array[i] = NULL;
- }
- efree(symbol->var_array);
- symbol->var_array = NULL;
- symbol->array_size = symbol->table_size = 0;
- symbol->flags &= ~ARRAYMAXED;
-}
-
-/* awk_hash --- calculate the hash function of the string in subs */
-
-static unsigned long
-awk_hash(const char *s, size_t len, unsigned long hsize, size_t *code)
-{
- unsigned long h = 0;
- unsigned long htmp;
-
- /*
- * Ozan Yigit's original sdbm hash, copied from Margo Seltzers
- * db package.
- *
- * This is INCREDIBLY ugly, but fast. We break the string up into
- * 8 byte units. On the first time through the loop we get the
- * "leftover bytes" (strlen % 8). On every other iteration, we
- * perform 8 HASHC's so we handle all 8 bytes. Essentially, this
- * saves us 7 cmp & branch instructions. If this routine is
- * heavily used enough, it's worth the ugly coding.
- */
-
- /*
- * Even more speed:
- * #define HASHC h = *s++ + 65599 * h
- * Because 65599 = pow(2, 6) + pow(2, 16) - 1 we multiply by shifts
- *
- * 4/2011: Force the results to 32 bits, to get the same
- * result on both 32- and 64-bit systems. This may be a
- * bad idea.
- */
-#define HASHC htmp = (h << 6); \
- h = *s++ + htmp + (htmp << 10) - h ; \
- htmp &= 0xFFFFFFFF; \
- h &= 0xFFFFFFFF
-
- h = 0;
-
- /* "Duff's Device" */
- if (len > 0) {
- size_t loop = (len + 8 - 1) >> 3;
-
- switch (len & (8 - 1)) {
- case 0:
- do { /* All fall throughs */
- HASHC;
- case 7: HASHC;
- case 6: HASHC;
- case 5: HASHC;
- case 4: HASHC;
- case 3: HASHC;
- case 2: HASHC;
- case 1: HASHC;
- } while (--loop);
- }
- }
-
- if (code != NULL)
- *code = h;
-
- if (h >= hsize)
- h %= hsize;
- return h;
-}
-
-/* assoc_find --- locate symbol[subs] */
-
-static NODE * /* NULL if not found */
-assoc_find(NODE *symbol, NODE *subs, unsigned long hash1, NODE **last)
-{
- NODE *bucket, *prev;
- const char *s1_str;
- size_t s1_len;
- NODE *s2;
-
- for (prev = NULL, bucket = symbol->var_array[hash1]; bucket != NULL;
- prev = bucket, bucket = bucket->ahnext) {
- /*
- * This used to use cmp_nodes() here. That's wrong.
- * Array indices are strings; compare as such, always!
- */
- s1_str = bucket->ahname_str;
- s1_len = bucket->ahname_len;
- s2 = subs;
-
- if (s1_len == s2->stlen) {
- if (s1_len == 0 /* "" is a valid index */
- || memcmp(s1_str, s2->stptr, s1_len) == 0)
- break;
- }
- }
- if (last != NULL)
- *last = prev;
- return bucket;
-}
-
-/* in_array --- test whether the array element symbol[subs] exists or not,
- * return pointer to value if it does.
- */
-
-NODE *
-in_array(NODE *symbol, NODE *subs)
-{
- unsigned long hash1;
- NODE *ret;
-
- assert(symbol->type == Node_var_array);
-
- if (symbol->var_array == NULL)
- return NULL;
-
- hash1 = hash(subs->stptr, subs->stlen, (unsigned long) symbol->array_size, NULL);
- ret = assoc_find(symbol, subs, hash1, NULL);
- return (ret ? ret->ahvalue : NULL);
-}
-
-/*
- * assoc_lookup:
- * Find SYMBOL[SUBS] in the assoc array. Install it with value "" if it
- * isn't there. Returns a pointer ala get_lhs to where its value is stored.
- *
- * SYMBOL is the address of the node (or other pointer) being dereferenced.
- * SUBS is a number or string used as the subscript.
- */
-
-NODE **
-assoc_lookup(NODE *symbol, NODE *subs, int reference)
-{
- unsigned long hash1;
- NODE *bucket;
- size_t code;
-
- assert(symbol->type == Node_var_array);
-
- (void) force_string(subs);
-
- if (symbol->var_array == NULL) {
- symbol->array_size = symbol->table_size = 0; /* sanity */
- symbol->flags &= ~ARRAYMAXED;
- grow_table(symbol);
- hash1 = hash(subs->stptr, subs->stlen,
- (unsigned long) symbol->array_size, & code);
- } else {
- hash1 = hash(subs->stptr, subs->stlen,
- (unsigned long) symbol->array_size, & code);
- bucket = assoc_find(symbol, subs, hash1, NULL);
- if (bucket != NULL)
- return &(bucket->ahvalue);
- }
-
- if (do_lint && reference) {
- lintwarn(_("reference to uninitialized element `%s[\"%.*s\"]'"),
- array_vname(symbol), (int)subs->stlen, subs->stptr);
- }
-
- /* It's not there, install it. */
- if (do_lint && subs->stlen == 0)
- lintwarn(_("subscript of array `%s' is null string"),
- array_vname(symbol));
-
- /* first see if we would need to grow the array, before installing */
- symbol->table_size++;
- if ((symbol->flags & ARRAYMAXED) == 0
- && (symbol->table_size / symbol->array_size) > AVG_CHAIN_MAX) {
- grow_table(symbol);
- /* have to recompute hash value for new size */
- hash1 = code % (unsigned long) symbol->array_size;
- }
-
- getnode(bucket);
- bucket->type = Node_ahash;
-
- /*
- * Freeze this string value --- it must never
- * change, no matter what happens to the value
- * that created it or to CONVFMT, etc.
- *
- * One day: Use an atom table to track array indices,
- * and avoid the extra memory overhead.
- */
- bucket->flags |= MALLOC;
- bucket->ahname_ref = 1;
-
- emalloc(bucket->ahname_str, char *, subs->stlen + 2, "assoc_lookup");
- bucket->ahname_len = subs->stlen;
- memcpy(bucket->ahname_str, subs->stptr, subs->stlen);
- bucket->ahname_str[bucket->ahname_len] = '\0';
- bucket->ahvalue = Nnull_string;
-
- bucket->ahnext = symbol->var_array[hash1];
- bucket->ahcode = code;
-
- /*
- * Set the numeric value for the index if it's available. Useful
- * for numeric sorting by index. Do this only if the numeric
- * value is available, instead of all the time, since doing it
- * all the time is a big performance hit for something that may
- * never be used.
- */
- if ((subs->flags & NUMCUR) != 0) {
- bucket->ahname_num = subs->numbr;
- bucket->flags |= NUMIND;
- }
-
- /* hook it into the symbol table */
- symbol->var_array[hash1] = bucket;
- return &(bucket->ahvalue);
-}
-
-
/* adjust_fcall_stack: remove subarray(s) of symbol[] from
* function call stack.
*/
@@ -602,7 +479,7 @@ adjust_fcall_stack(NODE *symbol, int nsubs)
func = frame_ptr->func_node;
if (func == NULL) /* in main */
return;
- pcount = func->lnode->param_cnt;
+ pcount = func->param_cnt;
sp = frame_ptr->stack;
for (; pcount > 0; pcount--) {
@@ -627,12 +504,10 @@ adjust_fcall_stack(NODE *symbol, int nsubs)
* function f(c, d) { delete c; ..}
* BEGIN { a[0][0] = 1; f(a[0], a[0]); ...}
*/
- char *save;
-local_array:
- save = r->vname;
- memset(r, '\0', sizeof(NODE));
- r->vname = save;
- r->type = Node_var_array;
+
+ init_array(r);
+ r->parent_array = NULL;
+ r->flags = 0;
continue;
}
@@ -648,8 +523,10 @@ local_array:
* BEGIN { a[0][0][0][0] = 1; f(a[0], a[0][0][0]); .. }
*
*/
-
- goto local_array;
+ init_array(r);
+ r->parent_array = NULL;
+ r->flags = 0;
+ break;
}
}
}
@@ -660,18 +537,17 @@ local_array:
/*
* `symbol' is array
- * `nsubs' is number of subscripts
+ * `nsubs' is no of subscripts
*/
void
do_delete(NODE *symbol, int nsubs)
{
- unsigned long hash1 = 0;
- NODE *subs, *bucket, *last, *r;
+ NODE *val, *subs;
int i;
assert(symbol->type == Node_var_array);
- subs = bucket = last = r = NULL; /* silence the compiler */
+ subs = val = NULL; /* silence the compiler */
/*
* The force_string() call is needed to make sure that
@@ -683,16 +559,17 @@ do_delete(NODE *symbol, int nsubs)
* Without it, the code does not fail.
*/
-#define free_subs(n) \
-do { \
+#define free_subs(n) do { \
NODE *s = PEEK(n - 1); \
if (s->type == Node_val) { \
- (void) force_string(s); /* may have side effects ? */ \
+ (void) force_string(s); /* may have side effects. */ \
DEREF(s); \
} \
} while (--n > 0)
- if (nsubs == 0) { /* delete array */
+ if (nsubs == 0) {
+ /* delete array */
+
adjust_fcall_stack(symbol, 0); /* fix function call stack; See above. */
assoc_clear(symbol);
return;
@@ -706,66 +583,46 @@ do { \
free_subs(i);
fatal(_("attempt to use array `%s' in a scalar context"), array_vname(subs));
}
- (void) force_string(subs);
-
- last = NULL; /* shut up gcc -Wall */
- hash1 = 0; /* ditto */
- bucket = NULL; /* array may be empty */
-
- if (symbol->var_array != NULL) {
- hash1 = hash(subs->stptr, subs->stlen,
- (unsigned long) symbol->array_size, NULL);
- bucket = assoc_find(symbol, subs, hash1, &last);
- }
- if (bucket == NULL) {
- if (do_lint)
+ val = in_array(symbol, subs);
+ if (val == NULL) {
+ if (do_lint) {
+ subs = force_string(subs);
lintwarn(_("delete: index `%s' not in array `%s'"),
subs->stptr, array_vname(symbol));
+ }
/* avoid memory leak, free all subs */
free_subs(i);
return;
}
if (i > 1) {
- if (bucket->ahvalue->type != Node_var_array) {
+ if (val->type != Node_var_array) {
/* e.g.: a[1] = 1; delete a[1][1] */
+
free_subs(i);
+ subs = force_string(subs);
fatal(_("attempt to use scalar `%s[\"%.*s\"]' as an array"),
array_vname(symbol),
- (int) bucket->ahname_len,
- bucket->ahname_str);
+ (int) subs->stlen,
+ subs->stptr);
}
- symbol = bucket->ahvalue;
+ symbol = val;
+ DEREF(subs);
}
- DEREF(subs);
}
- r = bucket->ahvalue;
- if (r->type == Node_var_array) {
- adjust_fcall_stack(r, nsubs); /* fix function call stack; See above. */
- assoc_clear(r);
+ if (val->type == Node_var_array) {
+ adjust_fcall_stack(val, nsubs); /* fix function call stack; See above. */
+ assoc_clear(val);
/* cleared a sub-array, free Node_var_array */
- efree(r->vname);
- freenode(r);
+ efree(val->vname);
+ freenode(val);
} else
- unref(r);
+ unref(val);
- if (last != NULL)
- last->ahnext = bucket->ahnext;
- else
- symbol->var_array[hash1] = bucket->ahnext;
-
- unref(bucket); /* unref() will free the ahname_str */
- symbol->table_size--;
- if (symbol->table_size <= 0) {
- symbol->table_size = symbol->array_size = 0;
- symbol->flags &= ~ARRAYMAXED;
- if (symbol->var_array != NULL) {
- efree(symbol->var_array);
- symbol->var_array = NULL;
- }
- }
+ (void) assoc_remove(symbol, subs);
+ DEREF(subs);
#undef free_subs
}
@@ -782,272 +639,155 @@ do { \
void
do_delete_loop(NODE *symbol, NODE **lhs)
{
- long i;
-
- assert(symbol->type == Node_var_array);
+ NODE **list;
+ NODE fl;
- if (symbol->var_array == NULL)
+ if (array_empty(symbol))
return;
- /* get first index value */
- for (i = 0; i < symbol->array_size; i++) {
- if (symbol->var_array[i] != NULL) {
- unref(*lhs);
- *lhs = make_string(symbol->var_array[i]->ahname_str,
- symbol->var_array[i]->ahname_len);
- break;
- }
- }
+ fl.flags = AINDEX|ADELETE; /* need a single index */
+ list = symbol->alist(symbol, & fl);
+ assert(list != NULL);
+
+ unref(*lhs);
+ *lhs = list[0];
+ efree(list);
/* blast the array in one shot */
- adjust_fcall_stack(symbol, 0);
+ adjust_fcall_stack(symbol, 0);
assoc_clear(symbol);
}
-/* grow_table --- grow a hash table */
+
+/* value_info --- print scalar node info */
static void
-grow_table(NODE *symbol)
+value_info(NODE *n)
{
- NODE **old, **new, *chain, *next;
- int i, j;
- unsigned long hash1;
- unsigned long oldsize, newsize, k;
- /*
- * This is an array of primes. We grow the table by an order of
- * magnitude each time (not just doubling) so that growing is a
- * rare operation. We expect, on average, that it won't happen
- * more than twice. When things are very large (> 8K), we just
- * double more or less, instead of just jumping from 8K to 64K.
- */
- static const long sizes[] = {
- 13, 127, 1021, 8191, 16381, 32749, 65497, 131101, 262147,
- 524309, 1048583, 2097169, 4194319, 8388617, 16777259, 33554467,
- 67108879, 134217757, 268435459, 536870923, 1073741827
- };
-
- /* find next biggest hash size */
- newsize = oldsize = symbol->array_size;
- for (i = 0, j = sizeof(sizes)/sizeof(sizes[0]); i < j; i++) {
- if (oldsize < sizes[i]) {
- newsize = sizes[i];
- break;
- }
- }
- if (newsize == oldsize) { /* table already at max (!) */
- symbol->flags |= ARRAYMAXED;
+#define PREC_NUM -1
+#define PREC_STR -1
+
+ if (n == Nnull_string || n == Null_field) {
+ fprintf(output_fp, "<(null)>");
return;
}
- /* allocate new table */
- emalloc(new, NODE **, newsize * sizeof(NODE *), "grow_table");
- memset(new, '\0', newsize * sizeof(NODE *));
-
- /* brand new hash table, set things up and return */
- if (symbol->var_array == NULL) {
- symbol->table_size = 0;
- goto done;
+ if ((n->flags & (STRING|STRCUR)) != 0) {
+ fprintf(output_fp, "<");
+ fprintf(output_fp, "\"%.*s\"", PREC_STR, n->stptr);
+ if ((n->flags & (NUMBER|NUMCUR)) != 0) {
+#ifdef HAVE_MPFR
+ if (is_mpg_float(n))
+ fprintf(output_fp, ":%s",
+ mpg_fmt("%.*R*g", PREC_NUM, ROUND_MODE, n->mpg_numbr));
+ else if (is_mpg_integer(n))
+ fprintf(output_fp, ":%s", mpg_fmt("%Zd", n->mpg_i));
+ else
+#endif
+ fprintf(output_fp, ":%.*g", PREC_NUM, n->numbr);
+ }
+ fprintf(output_fp, ">");
+ } else {
+#ifdef HAVE_MPFR
+ if (is_mpg_float(n))
+ fprintf(output_fp, "<%s>",
+ mpg_fmt("%.*R*g", PREC_NUM, ROUND_MODE, n->mpg_numbr));
+ else if (is_mpg_integer(n))
+ fprintf(output_fp, "<%s>", mpg_fmt("%Zd", n->mpg_i));
+ else
+#endif
+ fprintf(output_fp, "<%.*g>", PREC_NUM, n->numbr);
}
- /* old hash table there, move stuff to new, free old */
- old = symbol->var_array;
- for (k = 0; k < oldsize; k++) {
- if (old[k] == NULL)
- continue;
+ fprintf(output_fp, ":%s", flags2str(n->flags));
- for (chain = old[k]; chain != NULL; chain = next) {
- next = chain->ahnext;
- hash1 = chain->ahcode % newsize;
+ if ((n->flags & FIELD) == 0)
+ fprintf(output_fp, ":%ld", n->valref);
+ else
+ fprintf(output_fp, ":");
- /* remove from old list, add to new */
- chain->ahnext = new[hash1];
- new[hash1] = chain;
- }
+ if ((n->flags & (STRING|STRCUR)) == STRCUR) {
+ fprintf(output_fp, "][");
+ fprintf(output_fp, "stfmt=%d, ", n->stfmt);
+ fprintf(output_fp, "CONVFMT=\"%s\"", n->stfmt <= -1 ? "%ld"
+ : fmt_list[n->stfmt]->stptr);
}
- efree(old);
-done:
- /*
- * note that symbol->table_size does not change if an old array,
- * and is explicitly set to 0 if a new one.
- */
- symbol->var_array = new;
- symbol->array_size = newsize;
-}
-
-/* pr_node --- print simple node info */
-
-static void
-pr_node(NODE *n)
-{
- if ((n->flags & NUMBER) != 0)
- printf("%s %g p: %p", flags2str(n->flags), n->numbr, n);
- else
- printf("%s %.*s p: %p", flags2str(n->flags),
- (int) n->stlen, n->stptr, n);
+#undef PREC_NUM
+#undef PREC_STR
}
-static void
+void
indent(int indent_level)
{
- int k;
- for (k = 0; k < indent_level; k++)
- putchar('\t');
+ int i;
+ for (i = 0; i < indent_level; i++)
+ fprintf(output_fp, "%s", indent_char);
}
-/* assoc_dump --- dump the contents of an array */
+/* assoc_info --- print index, value info */
-NODE *
-assoc_dump(NODE *symbol, int indent_level)
+void
+assoc_info(NODE *subs, NODE *val, NODE *ndump, const char *aname)
{
- long i;
- NODE *bucket;
+ int indent_level = ndump->alevel;
+ indent_level++;
indent(indent_level);
- if (symbol->var_array == NULL) {
- printf(_("%s: empty (null)\n"), symbol->vname);
- return make_number((AWKNUM) 0);
- }
-
- if (symbol->table_size == 0) {
- printf(_("%s: empty (zero)\n"), symbol->vname);
- return make_number((AWKNUM) 0);
- }
+ fprintf(output_fp, "I: [%s:", aname);
+ if ((subs->flags & (MPFN|MPZN|INTIND)) == INTIND)
+ fprintf(output_fp, "<%ld>", (long) subs->numbr);
+ else
+ value_info(subs);
+ fprintf(output_fp, "]\n");
- printf(_("%s: table_size = %d, array_size = %d\n"), symbol->vname,
- (int) symbol->table_size, (int) symbol->array_size);
-
- for (i = 0; i < symbol->array_size; i++) {
- for (bucket = symbol->var_array[i]; bucket != NULL;
- bucket = bucket->ahnext) {
- indent(indent_level);
- printf("%s: I: [len %d <%.*s> p: %p] V: [",
- symbol->vname,
- (int) bucket->ahname_len,
- (int) bucket->ahname_len,
- bucket->ahname_str,
- bucket->ahname_str);
- if (bucket->ahvalue->type == Node_var_array) {
- printf("\n");
- assoc_dump(bucket->ahvalue, indent_level + 1);
- indent(indent_level);
- } else
- pr_node(bucket->ahvalue);
- printf("]\n");
- }
+ indent(indent_level);
+ if (val->type == Node_val) {
+ fprintf(output_fp, "V: [scalar: ");
+ value_info(val);
+ } else {
+ fprintf(output_fp, "V: [");
+ ndump->alevel++;
+ ndump->adepth--;
+ assoc_dump(val, ndump);
+ ndump->adepth++;
+ ndump->alevel--;
+ indent(indent_level);
}
-
- return make_number((AWKNUM) 0);
+ fprintf(output_fp, "]\n");
}
+
/* do_adump --- dump an array: interface to assoc_dump */
NODE *
do_adump(int nargs)
{
- NODE *r, *a;
-
- a = POP();
- if (a->type == Node_param_list) {
- printf(_("%s: is parameter\n"), a->vname);
- a = GET_PARAM(a->param_cnt);
- }
- if (a->type == Node_array_ref) {
- printf(_("%s: array_ref to %s\n"), a->vname,
- a->orig_array->vname);
- a = a->orig_array;
- }
- if (a->type != Node_var_array)
- fatal(_("adump: argument not an array"));
- r = assoc_dump(a, 0);
- return r;
-}
-
-/*
- * The following functions implement the builtin
- * asort function. Initial work by Alan J. Broder,
- * ajb@woti.com.
- */
+ NODE *symbol, *tmp;
+ static NODE ndump;
+ long depth = 0;
-/* dup_table --- recursively duplicate input array "symbol" */
+ /* depth < 0, no index and value info.
+ * = 0, main array index and value info; does not descend into sub-arrays.
+ * > 0, descends into 'depth' sub-arrays, and prints index and value info.
+ */
-static NODE *
-dup_table(NODE *symbol, NODE *newsymb)
-{
- NODE **old, **new, *chain, *bucket;
- long i;
- unsigned long cursize;
-
- /* find the current hash size */
- cursize = symbol->array_size;
-
- new = NULL;
-
- /* input is a brand new hash table, so there's nothing to copy */
- if (symbol->var_array == NULL)
- newsymb->table_size = 0;
- else {
- /* old hash table there, dupnode stuff into a new table */
-
- /* allocate new table */
- emalloc(new, NODE **, cursize * sizeof(NODE *), "dup_table");
- memset(new, '\0', cursize * sizeof(NODE *));
-
- /* do the copying/dupnode'ing */
- old = symbol->var_array;
- for (i = 0; i < cursize; i++) {
- if (old[i] != NULL) {
- for (chain = old[i]; chain != NULL;
- chain = chain->ahnext) {
- /* get a node for the linked list */
- getnode(bucket);
- bucket->type = Node_ahash;
- bucket->flags |= MALLOC;
- bucket->ahname_ref = 1;
- bucket->ahcode = chain->ahcode;
- if ((chain->flags & NUMIND) != 0) {
- bucket->ahname_num = chain->ahname_num;
- bucket->flags |= NUMIND;
- }
-
- /*
- * copy the corresponding name and
- * value from the original input list
- */
- emalloc(bucket->ahname_str, char *, chain->ahname_len + 2, "dup_table");
- bucket->ahname_len = chain->ahname_len;
-
- memcpy(bucket->ahname_str, chain->ahname_str, chain->ahname_len);
- bucket->ahname_str[bucket->ahname_len] = '\0';
-
- if (chain->ahvalue->type == Node_var_array) {
- NODE *r;
- getnode(r);
- r->type = Node_var_array;
- r->vname = estrdup(chain->ahname_str, chain->ahname_len);
- r->parent_array = newsymb;
- bucket->ahvalue = dup_table(chain->ahvalue, r);
- } else
- bucket->ahvalue = dupnode(chain->ahvalue);
-
- /*
- * put the node on the corresponding
- * linked list in the new table
- */
- bucket->ahnext = new[i];
- new[i] = bucket;
- }
- }
- }
- newsymb->table_size = symbol->table_size;
+ if (nargs == 2) {
+ tmp = POP_NUMBER();
+ depth = get_number_si(tmp);
+ DEREF(tmp);
}
-
- newsymb->var_array = new;
- newsymb->array_size = cursize;
- newsymb->flags = symbol->flags; /* ARRAYMAXED */
- return newsymb;
+ symbol = POP_PARAM();
+ if (symbol->type != Node_var_array)
+ fatal(_("adump: first argument not an array"));
+
+ ndump.type = Node_dump_array;
+ ndump.adepth = depth;
+ ndump.alevel = 0;
+ assoc_dump(symbol, & ndump);
+ return make_number((AWKNUM) 0);
}
@@ -1058,16 +798,14 @@ asort_actual(int nargs, SORT_CTXT ctxt)
{
NODE *array, *dest = NULL, *result;
NODE *r, *subs, *s;
- NODE **list, **ptr;
-#define TSIZE 100 /* an arbitrary amount */
- static char buf[TSIZE+2];
+ NODE **list = NULL, **ptr;
unsigned long num_elems, i;
const char *sort_str;
if (nargs == 3) /* 3rd optional arg */
s = POP_STRING();
else
- s = Nnull_string; /* "" => default sorting */
+ s = dupnode(Nnull_string); /* "" => default sorting */
s = force_string(s);
sort_str = s->stptr;
@@ -1078,7 +816,6 @@ asort_actual(int nargs, SORT_CTXT ctxt)
sort_str = "@ind_str_asc";
}
-
if (nargs >= 2) { /* 2nd optional arg */
dest = POP_PARAM();
if (dest->type != Node_var_array) {
@@ -1107,20 +844,21 @@ asort_actual(int nargs, SORT_CTXT ctxt)
fatal(ctxt == ASORT ?
_("asort: cannot use a subarray of second arg for first arg") :
_("asorti: cannot use a subarray of second arg for first arg"));
- }
+ }
}
num_elems = array->table_size;
- if (num_elems == 0 || array->var_array == NULL) { /* source array is empty */
- if (dest != NULL && dest != array)
- assoc_clear(dest);
- return make_number((AWKNUM) 0);
- }
-
- /* sorting happens inside assoc_list */
- list = assoc_list(array, sort_str, ctxt);
+ if (num_elems > 0) /* sorting happens inside assoc_list */
+ list = assoc_list(array, sort_str, ctxt);
DEREF(s);
+ if (num_elems == 0 || list == NULL) {
+ /* source array is empty */
+ if (dest != NULL && dest != array)
+ assoc_clear(dest);
+ return make_number((AWKNUM) 0);
+ }
+
/*
* Must not assoc_clear() the source array before constructing
* the output array. assoc_list() does not duplicate array values
@@ -1132,70 +870,48 @@ asort_actual(int nargs, SORT_CTXT ctxt)
result = dest;
} else {
/* use 'result' as a temporary destination array */
- getnode(result);
- memset(result, '\0', sizeof(NODE));
- result->type = Node_var_array;
+ result = make_array();
result->vname = array->vname;
result->parent_array = array->parent_array;
}
- subs = make_str_node(buf, TSIZE, ALREADY_MALLOCED); /* fake it */
- subs->flags &= ~MALLOC; /* safety */
- for (i = 1, ptr = list; i <= num_elems; i++) {
- sprintf(buf, "%lu", i);
- subs->stlen = strlen(buf);
- /* make number valid in case this array gets sorted later */
- subs->numbr = i;
- subs->flags |= NUMCUR;
- r = *ptr++;
- if (ctxt == ASORTI) {
- /*
- * We want the indices of the source array as values
- * of the 'result' array.
- */
- *assoc_lookup(result, subs, FALSE) =
- make_string(r->ahname_str, r->ahname_len);
- } else {
- NODE *val;
-
- /* We want the values of the source array. */
-
- val = r->ahvalue;
- if (result != dest) {
- /* optimization for dest = NULL or dest = array */
-
- if (val->type == Node_var_array) {
- /* update subarray index in parent array */
- efree(val->vname);
- val->vname = estrdup(subs->stptr, subs->stlen);
- }
- *assoc_lookup(result, subs, FALSE) = val;
- r->ahvalue = Nnull_string;
- } else {
- if (val->type == Node_val)
- *assoc_lookup(result, subs, FALSE) = dupnode(val);
- else {
- NODE *arr;
-
- /*
- * There isn't any reference counting for
- * subarrays, so recursively copy subarrays
- * using dup_table().
- */
- getnode(arr);
- arr->type = Node_var_array;
- arr->var_array = NULL;
- arr->vname = estrdup(subs->stptr, subs->stlen);
- arr->parent_array = array; /* actual parent, not the temporary one. */
- *assoc_lookup(result, subs, FALSE) = dup_table(val, arr);
- }
+ if (ctxt == ASORTI) {
+ /* We want the indices of the source array. */
+
+ for (i = 1, ptr = list; i <= num_elems; i++, ptr += 2) {
+ subs = make_number(i);
+ *assoc_lookup(result, subs) = *ptr;
+ unref(subs);
+ }
+ } else {
+ /* We want the values of the source array. */
+
+ for (i = 1, ptr = list; i <= num_elems; i++) {
+ subs = make_number(i);
+
+ /* free index node */
+ r = *ptr++;
+ unref(r);
+
+ /* value node */
+ r = *ptr++;
+
+ if (r->type == Node_val)
+ *assoc_lookup(result, subs) = dupnode(r);
+ else {
+ NODE *arr;
+ arr = make_array();
+ subs = force_string(subs);
+ arr->vname = subs->stptr;
+ subs->stptr = NULL;
+ subs->flags &= ~STRCUR;
+ arr->parent_array = array; /* actual parent, not the temporary one. */
+ *assoc_lookup(result, subs) = assoc_copy(r, arr);
}
+ unref(subs);
}
+ }
- unref(r);
- }
-
- freenode(subs); /* stptr(buf) not malloc-ed */
efree(list);
if (result != dest) {
@@ -1209,7 +925,6 @@ asort_actual(int nargs, SORT_CTXT ctxt)
return make_number((AWKNUM) num_elems);
}
-#undef TSIZE
/* do_asort --- sort array by value */
@@ -1227,32 +942,25 @@ do_asorti(int nargs)
return asort_actual(nargs, ASORTI);
}
+
/*
- * cmp_string --- compare two strings; logic similar to cmp_nodes() in eval.c
+ * cmp_strings --- compare two strings; logic similar to cmp_nodes() in eval.c
* except the extra case-sensitive comparison when the case-insensitive
* result is a match.
*/
static int
-cmp_string(const NODE *n1, const NODE *n2)
+cmp_strings(const NODE *n1, const NODE *n2)
{
char *s1, *s2;
size_t len1, len2;
int ret;
size_t lmin;
- assert(n1->type == n2->type);
- if (n1->type == Node_ahash) {
- s1 = n1->ahname_str;
- len1 = n1->ahname_len;
- s2 = n2->ahname_str;
- len2 = n2->ahname_len;
- } else {
- s1 = n1->stptr;
- len1 = n1->stlen;
- s2 = n2->stptr;
- len2 = n2->stlen;
- }
+ s1 = n1->stptr;
+ len1 = n1->stlen;
+ s2 = n2->stptr;
+ len2 = n2->stlen;
if (len1 == 0)
return len2 == 0 ? 0 : -1;
@@ -1288,7 +996,6 @@ cmp_string(const NODE *n1, const NODE *n2)
return (len1 < len2) ? -1 : 1;
}
-
/* sort_up_index_string --- qsort comparison function; ascending index strings. */
static int
@@ -1299,11 +1006,11 @@ sort_up_index_string(const void *p1, const void *p2)
/* Array indices are strings */
t1 = *((const NODE *const *) p1);
t2 = *((const NODE *const *) p2);
- return cmp_string(t1, t2);
+ return cmp_strings(t1, t2);
}
-/* sort_down_index_string --- descending index strings */
+/* sort_down_index_str --- qsort comparison function; descending index strings. */
static int
sort_down_index_string(const void *p1, const void *p2)
@@ -1326,24 +1033,22 @@ sort_down_index_string(const void *p1, const void *p2)
static int
sort_up_index_number(const void *p1, const void *p2)
{
- const NODE *n1, *n2;
+ const NODE *t1, *t2;
int ret;
- n1 = *((const NODE *const *) p1);
- n2 = *((const NODE *const *) p2);
+ t1 = *((const NODE *const *) p1);
+ t2 = *((const NODE *const *) p2);
- if (n1->ahname_num < n2->ahname_num)
- ret = -1;
- else
- ret = (n1->ahname_num > n2->ahname_num);
+ ret = cmp_numbers(t1, t2);
+ if (ret != 0)
+ return ret;
/* break a tie with the index string itself */
- if (ret == 0)
- return cmp_string(n1, n2);
- return ret;
+ t1 = force_string((NODE *) t1);
+ t2 = force_string((NODE *) t2);
+ return cmp_strings(t1, t2);
}
-
/* sort_down_index_number --- qsort comparison function; descending index numbers */
static int
@@ -1359,29 +1064,23 @@ static int
sort_up_value_string(const void *p1, const void *p2)
{
const NODE *t1, *t2;
- NODE *n1, *n2;
-
- /* we're passed a pair of index (array subscript) nodes */
- t1 = *(const NODE *const *) p1;
- t2 = *(const NODE *const *) p2;
- /* and we want to compare the element values they refer to */
- n1 = t1->ahvalue;
- n2 = t2->ahvalue;
+ t1 = *((const NODE *const *) p1 + 1);
+ t2 = *((const NODE *const *) p2 + 1);
- if (n1->type == Node_var_array) {
- /* return 0 if n2 is a sub-array too, else return 1 */
- return (n2->type != Node_var_array);
+ if (t1->type == Node_var_array) {
+ /* return 0 if t2 is a sub-array too, else return 1 */
+ return (t2->type != Node_var_array);
}
- if (n2->type == Node_var_array)
- return -1; /* n1 (scalar) < n2 (sub-array) */
+ if (t2->type == Node_var_array)
+ return -1; /* t1 (scalar) < t2 (sub-array) */
- /* n1 and n2 both have string values; See sort_force_value_string(). */
- return cmp_string(n1, n2);
+ /* t1 and t2 both have string values */
+ return cmp_strings(t1, t2);
}
-/* sort_down_value_string --- descending value string */
+/* sort_down_value_string --- qsort comparison function; descending value string */
static int
sort_down_value_string(const void *p1, const void *p2)
@@ -1389,50 +1088,40 @@ sort_down_value_string(const void *p1, const void *p2)
return -sort_up_value_string(p1, p2);
}
+
/* sort_up_value_number --- qsort comparison function; ascending value number */
static int
sort_up_value_number(const void *p1, const void *p2)
{
- const NODE *t1, *t2;
- NODE *n1, *n2;
+ NODE *t1, *t2;
int ret;
- /* we're passed a pair of index (array subscript) nodes */
- t1 = *(const NODE *const *) p1;
- t2 = *(const NODE *const *) p2;
-
- /* and we want to compare the element values they refer to */
- n1 = t1->ahvalue;
- n2 = t2->ahvalue;
+ t1 = *((NODE *const *) p1 + 1);
+ t2 = *((NODE *const *) p2 + 1);
- if (n1->type == Node_var_array) {
- /* return 0 if n2 is a sub-array too, else return 1 */
- return (n2->type != Node_var_array);
+ if (t1->type == Node_var_array) {
+ /* return 0 if t2 is a sub-array too, else return 1 */
+ return (t2->type != Node_var_array);
}
- if (n2->type == Node_var_array)
- return -1; /* n1 (scalar) < n2 (sub-array) */
-
- /* n1 and n2 both Node_val, and force_number'ed */
- if (n1->numbr < n2->numbr)
- ret = -1;
- else
- ret = (n1->numbr > n2->numbr);
+ if (t2->type == Node_var_array)
+ return -1; /* t1 (scalar) < t2 (sub-array) */
- if (ret == 0) {
- /*
- * Use string value to guarantee same sort order on all
- * versions of qsort().
- */
- n1 = force_string(n1);
- n2 = force_string(n2);
- ret = cmp_string(n1, n2);
- }
+ ret = cmp_numbers(t1, t2);
+ if (ret != 0)
+ return ret;
- return ret;
+ /*
+ * Use string value to guarantee same sort order on all
+ * versions of qsort().
+ */
+ t1 = force_string(t1);
+ t2 = force_string(t2);
+ return cmp_strings(t1, t2);
}
-/* sort_down_value_number --- descending value number */
+
+/* sort_down_value_number --- qsort comparison function; descending value number */
static int
sort_down_value_number(const void *p1, const void *p2)
@@ -1440,21 +1129,17 @@ sort_down_value_number(const void *p1, const void *p2)
return -sort_up_value_number(p1, p2);
}
+
/* sort_up_value_type --- qsort comparison function; ascending value type */
static int
sort_up_value_type(const void *p1, const void *p2)
{
- const NODE *t1, *t2;
NODE *n1, *n2;
- /* we're passed a pair of index (array subscript) nodes */
- t1 = *(const NODE *const *) p1;
- t2 = *(const NODE *const *) p2;
-
- /* and we want to compare the element values they refer to */
- n1 = t1->ahvalue;
- n2 = t2->ahvalue;
+ /* we want to compare the element values */
+ n1 = *((NODE *const *) p1 + 1);
+ n2 = *((NODE *const *) p2 + 1);
/* 1. Arrays vs. scalar, scalar is less than array */
if (n1->type == Node_var_array) {
@@ -1472,13 +1157,14 @@ sort_up_value_type(const void *p1, const void *p2)
if ((n2->flags & MAYBE_NUM) != 0)
(void) force_number(n2);
+ /* 2.5. Resolve INTIND, so that is STRING, and not NUMBER */
+ if ((n1->flags & INTIND) != 0)
+ (void) force_string(n1);
+ if ((n2->flags & INTIND) != 0)
+ (void) force_string(n2);
+
if ((n1->flags & NUMBER) != 0 && (n2->flags & NUMBER) != 0) {
- if (n1->numbr < n2->numbr)
- return -1;
- else if (n1->numbr > n2->numbr)
- return 1;
- else
- return 0;
+ return cmp_numbers(n1, n2);
}
/* 3. All numbers are less than all strings. This is aribitrary. */
@@ -1489,10 +1175,10 @@ sort_up_value_type(const void *p1, const void *p2)
}
/* 4. Two strings */
- return cmp_string(n1, n2);
+ return cmp_strings(n1, n2);
}
-/* sort_down_value_type --- descending value type */
+/* sort_down_value_type --- qsort comparison function; descending value type */
static int
sort_down_value_type(const void *p1, const void *p2)
@@ -1505,147 +1191,120 @@ sort_down_value_type(const void *p1, const void *p2)
static int
sort_user_func(const void *p1, const void *p2)
{
- const NODE *t1, *t2;
- NODE *idx1, *idx2, *val1, *val2;
- AWKNUM ret;
+ NODE *idx1, *idx2, *val1, *val2, *r;
+ int ret;
INSTRUCTION *code;
- t1 = *((const NODE *const *) p1);
- t2 = *((const NODE *const *) p2);
-
- idx1 = make_string(t1->ahname_str, t1->ahname_len);
- idx2 = make_string(t2->ahname_str, t2->ahname_len);
- val1 = t1->ahvalue;
- val2 = t2->ahvalue;
+ idx1 = *((NODE *const *) p1);
+ idx2 = *((NODE *const *) p2);
+ val1 = *((NODE *const *) p1 + 1);
+ val2 = *((NODE *const *) p2 + 1);
code = TOP()->code_ptr; /* comparison function call instructions */
/* setup 4 arguments to comp_func() */
+ UPREF(idx1);
PUSH(idx1);
if (val1->type == Node_val)
UPREF(val1);
PUSH(val1);
+
+ UPREF(idx2);
PUSH(idx2);
if (val2->type == Node_val)
UPREF(val2);
PUSH(val2);
/* execute the comparison function */
- (void) interpret(code);
+ (void) (*interpret)(code);
/* return value of the comparison function */
- POP_NUMBER(ret);
-
- return (ret < 0.0) ? -1 : (ret > 0.0);
-}
-
-/* sort_force_index_number -- pre-process list items for sorting indices as numbers */
-
-static void
-sort_force_index_number(NODE **list, size_t num_elems)
-{
- size_t i;
- NODE *r;
- static NODE temp_node;
-
- for (i = 0; i < num_elems; i++) {
- r = list[i];
-
- if ((r->flags & NUMIND) != 0) /* once in a lifetime is plenty */
- continue;
- temp_node.type = Node_val;
- temp_node.stptr = r->ahname_str;
- temp_node.stlen = r->ahname_len;
- temp_node.flags = 0; /* only interested in the return value of r_force_number */
- r->ahname_num = r_force_number(& temp_node);
- r->flags |= NUMIND;
- }
-}
-
-/* sort_force_value_number -- pre-process list items for sorting values as numbers */
-
-static void
-sort_force_value_number(NODE **list, size_t num_elems)
-{
- size_t i;
- NODE *r, *val;
-
- for (i = 0; i < num_elems; i++) {
- r = list[i];
- val = r->ahvalue;
- if (val->type == Node_val)
- (void) force_number(val);
- }
+ r = POP_NUMBER();
+#ifdef HAVE_MPFR
+ /*
+ * mpfr_sgn(mpz_sgn): Returns a positive value if op > 0,
+ * zero if op = 0, and a negative value if op < 0.
+ */
+ if (is_mpg_float(r))
+ ret = mpfr_sgn(r->mpg_numbr);
+ else if (is_mpg_integer(r))
+ ret = mpz_sgn(r->mpg_i);
+ else
+#endif
+ ret = (r->numbr < 0.0) ? -1 : (r->numbr > 0.0);
+ DEREF(r);
+ return ret;
}
-/* sort_force_value_string -- pre-process list items for sorting values as strings */
-
-static void
-sort_force_value_string(NODE **list, size_t num_elems)
-{
- size_t i;
- NODE *r, *val;
-
- for (i = 0; i < num_elems; i++) {
- r = list[i];
- val = r->ahvalue;
- if (val->type == Node_val)
- r->ahvalue = force_string(val);
- }
-}
/* assoc_list -- construct, and optionally sort, a list of array elements */
NODE **
-assoc_list(NODE *array, const char *sort_str, SORT_CTXT sort_ctxt)
+assoc_list(NODE *symbol, const char *sort_str, SORT_CTXT sort_ctxt)
{
- typedef void (*qsort_prefunc)(NODE **, size_t);
typedef int (*qsort_compfunc)(const void *, const void *);
static const struct qsort_funcs {
const char *name;
qsort_compfunc comp_func;
- qsort_prefunc pre_func; /* pre-processing of list items */
+ enum assoc_list_flags flags;
} sort_funcs[] = {
- { "@ind_str_asc", sort_up_index_string, 0 },
- { "@ind_num_asc", sort_up_index_number, sort_force_index_number },
- { "@val_str_asc", sort_up_value_string, sort_force_value_string },
- { "@val_num_asc", sort_up_value_number, sort_force_value_number },
- { "@ind_str_desc", sort_down_index_string, 0 },
- { "@ind_num_desc", sort_down_index_number, sort_force_index_number },
- { "@val_str_desc", sort_down_value_string, sort_force_value_string },
- { "@val_num_desc", sort_down_value_number, sort_force_value_number },
- { "@val_type_asc", sort_up_value_type, 0 },
- { "@val_type_desc", sort_down_value_type, 0 },
- { "@unsorted", 0, 0 },
- };
+{ "@ind_str_asc", sort_up_index_string, AINDEX|AISTR|AASC },
+{ "@ind_num_asc", sort_up_index_number, AINDEX|AINUM|AASC },
+{ "@val_str_asc", sort_up_value_string, AVALUE|AVSTR|AASC },
+{ "@val_num_asc", sort_up_value_number, AVALUE|AVNUM|AASC },
+{ "@ind_str_desc", sort_down_index_string, AINDEX|AISTR|ADESC },
+{ "@ind_num_desc", sort_down_index_number, AINDEX|AINUM|ADESC },
+{ "@val_str_desc", sort_down_value_string, AVALUE|AVSTR|ADESC },
+{ "@val_num_desc", sort_down_value_number, AVALUE|AVNUM|ADESC },
+{ "@val_type_asc", sort_up_value_type, AVALUE|AASC },
+{ "@val_type_desc", sort_down_value_type, AVALUE|ADESC },
+{ "@unsorted", 0, AINDEX },
+};
+
+ /* N.B.: AASC and ADESC are hints to the specific array types.
+ * See cint_list() in cint_array.c.
+ */
+
NODE **list;
- NODE *r;
- size_t num_elems, i, j;
+ NODE fl;
+ unsigned long num_elems, j;
+ int elem_size, qi;
qsort_compfunc cmp_func = 0;
- qsort_prefunc pre_func = 0;
INSTRUCTION *code = NULL;
- int qi;
extern int currule;
+ int save_rule = 0;
- num_elems = array->table_size;
- assert(num_elems > 0);
+ num_elems = symbol->table_size;
+ if (num_elems == 0)
+ return NULL;
+
+ elem_size = 1;
+ fl.flags = 0;
for (qi = 0, j = sizeof(sort_funcs)/sizeof(sort_funcs[0]); qi < j; qi++) {
if (strcmp(sort_funcs[qi].name, sort_str) == 0)
break;
}
- if (qi >= 0 && qi < j) {
+ if (qi < j) {
cmp_func = sort_funcs[qi].comp_func;
- pre_func = sort_funcs[qi].pre_func;
+ fl.flags = sort_funcs[qi].flags;
+
+ if (symbol->array_funcs != cint_array_func)
+ fl.flags &= ~(AASC|ADESC);
+
+ if (sort_ctxt != SORTED_IN || (fl.flags & AVALUE) != 0) {
+ /* need index and value pair in the list */
- } else { /* unrecognized */
+ fl.flags |= (AINDEX|AVALUE);
+ elem_size = 2;
+ }
+
+ } else { /* unrecognized */
NODE *f;
const char *sp;
- assert(sort_str != NULL);
-
for (sp = sort_str; *sp != '\0'
&& ! isspace((unsigned char) *sp); sp++)
continue;
@@ -1659,7 +1318,10 @@ assoc_list(NODE *array, const char *sort_str, SORT_CTXT sort_ctxt)
fatal(_("sort comparison function `%s' is not defined"), sort_str);
cmp_func = sort_user_func;
- /* pre_func is still NULL */
+
+ /* need index and value pair in the list */
+ fl.flags |= (AVALUE|AINDEX);
+ elem_size = 2;
/* make function call instructions */
code = bcalloc(Op_func_call, 2, 0);
@@ -1673,103 +1335,35 @@ assoc_list(NODE *array, const char *sort_str, SORT_CTXT sort_ctxt)
* to undefined (0).
*/
- (code + 1)->inrule = currule; /* save current rule */
+ save_rule = currule; /* save current rule */
currule = 0;
PUSH_CODE(code);
}
- /* allocate space for array; the extra space is used in for(i in a) opcode (eval.c) */
- emalloc(list, NODE **, (num_elems + 1) * sizeof(NODE *), "assoc_list");
-
- /* populate it */
- for (i = j = 0; i < array->array_size; i++)
- for (r = array->var_array[i]; r != NULL; r = r->ahnext)
- list[j++] = dupnode(r);
- list[num_elems] = NULL;
-
- if (! cmp_func) /* unsorted */
- return list;
+ list = symbol->alist(symbol, & fl);
- /* special pre-processing of list items */
- if (pre_func)
- pre_func(list, num_elems);
+ if (list == NULL || ! cmp_func || (fl.flags & (AASC|ADESC)) != 0)
+ return list; /* empty list or unsorted, or list already sorted */
- qsort(list, num_elems, sizeof(NODE *), cmp_func); /* shazzam! */
+ qsort(list, num_elems, elem_size * sizeof(NODE *), cmp_func); /* shazzam! */
if (cmp_func == sort_user_func) {
code = POP_CODE();
- currule = (code + 1)->inrule; /* restore current rule */
+ currule = save_rule; /* restore current rule */
bcfree(code->nexti); /* Op_stop */
bcfree(code); /* Op_func_call */
}
- return list;
-}
-
-
-/*
-From bonzini@gnu.org Mon Oct 28 16:05:26 2002
-Date: Mon, 28 Oct 2002 13:33:03 +0100
-From: Paolo Bonzini <bonzini@gnu.org>
-To: arnold@skeeve.com
-Subject: Hash function
-Message-ID: <20021028123303.GA6832@biancaneve>
-
-Here is the hash function I'm using in GNU Smalltalk. The scrambling is
-needed if you use powers of two as the table sizes. If you use primes it
-is not needed.
-
-To use double-hashing with power-of-two size, you should use the
-_gst_hash_string(str, len) as the primary hash and
-scramble(_gst_hash_string (str, len)) | 1 as the secondary hash.
-
-Paolo
-
-*/
-/*
- * ADR: Slightly modified to work w/in the context of gawk.
- */
-
-static unsigned long
-gst_hash_string(const char *str, size_t len, unsigned long hsize, size_t *code)
-{
- unsigned long hashVal = 1497032417; /* arbitrary value */
- unsigned long ret;
-
- while (len--) {
- hashVal += *str++;
- hashVal += (hashVal << 10);
- hashVal ^= (hashVal >> 6);
- }
-
- ret = scramble(hashVal);
+ if (sort_ctxt == SORTED_IN && (fl.flags & (AINDEX|AVALUE)) == (AINDEX|AVALUE)) {
+ /* relocate all index nodes to the first half of the list. */
+ for (j = 1; j < num_elems; j++)
+ list[j] = list[2 * j];
- if (code != NULL)
- *code = ret;
+ /* give back extra memory */
- if (ret >= hsize)
- ret %= hsize;
-
- return ret;
-}
-
-static unsigned long
-scramble(unsigned long x)
-{
- if (sizeof(long) == 4) {
- int y = ~x;
-
- x += (y << 10) | (y >> 22);
- x += (x << 6) | (x >> 26);
- x -= (x << 16) | (x >> 16);
- } else {
- x ^= (~x) >> 31;
- x += (x << 21) | (x >> 11);
- x += (x << 5) | (x >> 27);
- x += (x << 27) | (x >> 5);
- x += (x << 31);
+ erealloc(list, NODE **, num_elems * sizeof(NODE *), "assoc_list");
}
- return x;
+ return list;
}
diff --git a/awk.h b/awk.h
index 3574e587..44fda9d4 100644
--- a/awk.h
+++ b/awk.h
@@ -195,6 +195,18 @@ typedef void *stackoverflow_context_t;
this is a hack but it gives us the right semantics */
#define lintwarn (*(set_loc(__FILE__, __LINE__),lintfunc))
+#ifdef HAVE_MPFR
+#include <gmp.h>
+#include <mpfr.h>
+#ifndef MPFR_RNDN
+/* for compatibility with MPFR 2.X */
+#define MPFR_RNDN GMP_RNDN
+#define MPFR_RNDZ GMP_RNDZ
+#define MPFR_RNDU GMP_RNDU
+#define MPFR_RNDD GMP_RNDD
+#endif
+#endif
+
#include "regex.h"
#include "dfa.h"
typedef struct Regexp {
@@ -204,6 +216,8 @@ typedef struct Regexp {
short dfa;
short has_anchor; /* speed up of avoid_dfa kludge, temporary */
short non_empty; /* for use in fpat_parse_field */
+ short has_meta; /* re has meta chars so (probably) isn't simple string */
+ short maybe_long; /* re has meta chars that can match long text */
} Regexp;
#define RESTART(rp,s) (rp)->regs.start[0]
#define REEND(rp,s) (rp)->regs.end[0]
@@ -256,10 +270,9 @@ extern double gawk_strtod();
#define FALSE 0
#endif
-#define LINT_INVALID 1 /* only warn about invalid */
-#define LINT_ALL 2 /* warn about all things */
+#define INT32_BIT 32
-enum defrule {BEGIN = 1, Rule, END, BEGINFILE, ENDFILE,
+enum defrule { BEGIN = 1, Rule, END, BEGINFILE, ENDFILE,
MAXRULE /* sentinel, not legal */ };
extern const char *const ruletab[];
@@ -278,10 +291,13 @@ typedef enum nodevals {
Node_var_new, /* newly created variable, may become an array */
Node_param_list, /* lnode is a variable, rnode is more list */
Node_func, /* lnode is param. list, rnode is body */
+ Node_ext_func, /* extension function, code_ptr is builtin code */
Node_hashnode, /* an identifier in the symbol table */
- Node_ahash, /* an array element */
Node_array_ref, /* array passed by ref as parameter */
+ Node_array_tree, /* Hashed array tree (HAT) */
+ Node_array_leaf, /* Linear 1-D array */
+ Node_dump_array, /* array info */
/* program execution -- stack item types */
Node_arrayfor,
@@ -291,9 +307,44 @@ typedef enum nodevals {
Node_final /* sentry value, not legal */
} NODETYPE;
+struct exp_node;
+
+typedef union bucket_item {
+ struct {
+ union bucket_item *next;
+ char *str;
+ size_t len;
+ size_t code;
+ struct exp_node *name;
+ struct exp_node *val;
+ } hs;
+ struct {
+ union bucket_item *next;
+ long li[2];
+ struct exp_node *val[2];
+ size_t cnt;
+ } hi;
+} BUCKET;
+
+/* string hash table */
+#define ahnext hs.next
+#define ahname hs.name /* a string index node */
+#define ahname_str hs.str /* shallow copy; = ahname->stptr */
+#define ahname_len hs.len /* = ahname->stlen */
+#define ahvalue hs.val
+#define ahcode hs.code
+
+/* integer hash table */
+#define ainext hi.next
+#define ainum hi.li /* integer indices */
+#define aivalue hi.val
+#define aicount hi.cnt
struct exp_instruction;
+typedef int (*Func_print)(FILE *, const char *, ...);
+typedef struct exp_node **(*array_ptr)(struct exp_node *, struct exp_node *);
+
/*
* NOTE - this struct is a rather kludgey -- it is packed to minimize
* space usage, at the expense of cleanliness. Alter at own risk.
@@ -305,13 +356,15 @@ typedef struct exp_node {
struct exp_node *lptr;
struct exp_instruction *li;
long ll;
+ array_ptr *lp;
} l;
union {
struct exp_node *rptr;
Regexp *preg;
struct exp_node **av;
+ BUCKET **bv;
void (*uptr)(void);
- struct exp_instruction *ri;
+ struct exp_instruction *iptr;
} r;
union {
struct exp_node *extra;
@@ -320,16 +373,27 @@ typedef struct exp_node {
char **param_list;
} x;
char *name;
+ size_t reserved;
struct exp_node *rn;
+ unsigned long cnt;
unsigned long reflags;
# define CASE 1
# define CONSTANT 2
# define FS_DFLT 4
} nodep;
+
struct {
+#ifdef HAVE_MPFR
+ union {
+ AWKNUM fltnum;
+ mpfr_t mpnum;
+ mpz_t mpi;
+ } nm;
+#else
AWKNUM fltnum; /* this is here for optimal packing of
- * the structure on many machines
- */
+ * the structure on many machines
+ */
+#endif
char *sp;
size_t slen;
long sref;
@@ -339,97 +403,130 @@ typedef struct exp_node {
size_t wslen;
#endif
} val;
- struct {
- AWKNUM num;
- struct exp_node *next;
- char *name;
- size_t length;
- struct exp_node *value;
- long ref;
- size_t code;
- } hash;
-#define hnext sub.hash.next
-#define hname sub.hash.name
-#define hlength sub.hash.length
-#define hvalue sub.hash.value
-
-#define ahnext sub.hash.next
-#define ahname_str sub.hash.name
-#define ahname_len sub.hash.length
-#define ahname_num sub.hash.num
-#define ahvalue sub.hash.value
-#define ahname_ref sub.hash.ref
-#define ahcode sub.hash.code
} sub;
NODETYPE type;
- unsigned short flags;
-# define MALLOC 1 /* can be free'd */
-# define PERM 2 /* can't be free'd */
-# define STRING 4 /* assigned as string */
-# define STRCUR 8 /* string value is current */
-# define NUMCUR 16 /* numeric value is current */
-# define NUMBER 32 /* assigned as number */
-# define MAYBE_NUM 64 /* user input: if NUMERIC then
- * a NUMBER */
-# define ARRAYMAXED 128 /* array is at max size */
-# define FUNC 256 /* this parameter is really a
- * function name; see awkgram.y */
-# define FIELD 512 /* this is a field */
-# define INTLSTR 1024 /* use localized version */
-# define NUMIND 2048 /* numeric val of index is current */
-# define WSTRCUR 4096 /* wide str value is current */
+ unsigned int flags;
+
+/* any type */
+# define MALLOC 0x0001 /* can be free'd */
+
+/* type = Node_val */
+# define STRING 0x0002 /* assigned as string */
+# define STRCUR 0x0004 /* string value is current */
+# define NUMCUR 0x0008 /* numeric value is current */
+# define NUMBER 0x0010 /* assigned as number */
+# define MAYBE_NUM 0x0020 /* user input: if NUMERIC then
+ * a NUMBER */
+# define FIELD 0x0040 /* this is a field */
+# define INTLSTR 0x0080 /* use localized version */
+# define NUMINT 0x0100 /* numeric value is an integer */
+# define INTIND 0x0200 /* integral value is array index;
+ * lazy conversion to string.
+ */
+# define WSTRCUR 0x0400 /* wide str value is current */
+# define MPFN 0x0800 /* arbitrary-precision floating-point number */
+# define MPZN 0x1000 /* arbitrary-precision integer */
+
+/* type = Node_var_array */
+# define ARRAYMAXED 0x2000 /* array is at max size */
+# define HALFHAT 0x4000 /* half-capacity Hashed Array Tree;
+ * See cint_array.c */
+# define XARRAY 0x8000
} NODE;
-
#define vname sub.nodep.name
#define lnode sub.nodep.l.lptr
#define nextp sub.nodep.l.lptr
#define rnode sub.nodep.r.rptr
-#define param_cnt sub.nodep.l.ll
-#define param vname
+/* Node_hashnode, Node_param_list */
+#define hnext sub.nodep.r.rptr
+#define hname vname
+#define hlength sub.nodep.reserved
+#define hcode sub.nodep.cnt
+#define hvalue sub.nodep.x.extra
+
+/* Node_param_list, Node_func */
+#define param_cnt sub.nodep.l.ll
+/* Node_param_list */
+#define param vname
-#define parmlist sub.nodep.x.param_list
-#define code_ptr sub.nodep.r.ri
+/* Node_func */
+#define fparms sub.nodep.rn
+#define code_ptr sub.nodep.r.iptr
+/* Node_regex, Node_dynregex */
#define re_reg sub.nodep.r.preg
#define re_flags sub.nodep.reflags
#define re_text lnode
#define re_exp sub.nodep.x.extra
-#define re_cnt flags
+#define re_cnt flags
+/* Node_val */
#define stptr sub.val.sp
#define stlen sub.val.slen
#define valref sub.val.sref
-#define stfmt sub.val.idx
-
+#define stfmt sub.val.idx
#define wstptr sub.val.wsp
#define wstlen sub.val.wslen
+#ifdef HAVE_MPFR
+#define mpg_numbr sub.val.nm.mpnum
+#define mpg_i sub.val.nm.mpi
+#define numbr sub.val.nm.fltnum
+#else
+#define numbr sub.val.fltnum
+#endif
-#define numbr sub.val.fltnum
+/* Node_arrayfor */
+#define for_list sub.nodep.r.av
+#define for_list_size sub.nodep.reflags
+#define cur_idx sub.nodep.l.ll
+#define for_array sub.nodep.rn
/* Node_frame: */
#define stack sub.nodep.r.av
#define func_node sub.nodep.x.extra
#define prev_frame_size sub.nodep.reflags
#define reti sub.nodep.l.li
+#define num_tail_calls sub.nodep.cnt
/* Node_var: */
-#define var_value lnode
+#define var_value lnode
#define var_update sub.nodep.r.uptr
#define var_assign sub.nodep.x.aptr
/* Node_var_array: */
-#define var_array sub.nodep.r.av
-#define array_size sub.nodep.l.ll
-#define table_size sub.nodep.x.xl
-#define parent_array sub.nodep.rn
+#define buckets sub.nodep.r.bv
+#define nodes sub.nodep.r.av
+#define array_funcs sub.nodep.l.lp
+#define array_base sub.nodep.l.ll
+#define table_size sub.nodep.reflags
+#define array_size sub.nodep.cnt
+#define array_capacity sub.nodep.reserved
+#define xarray sub.nodep.rn
+#define parent_array sub.nodep.x.extra
+
+/* array_funcs[0] is the array initialization function and
+ * array_funcs[1] is the index type checking function
+ */
+#define alookup array_funcs[2]
+#define aexists array_funcs[3]
+#define aclear array_funcs[4]
+#define aremove array_funcs[5]
+#define alist array_funcs[6]
+#define acopy array_funcs[7]
+#define adump array_funcs[8]
+#define NUM_AFUNCS 9 /* # of entries in array_funcs */
/* Node_array_ref: */
#define orig_array lnode
#define prev_array rnode
+/* Node_array_print */
+#define adepth sub.nodep.l.ll
+#define alevel sub.nodep.x.xl
+
/* --------------------------------lint warning types----------------------------*/
typedef enum lintvals {
LINT_illegal,
@@ -527,6 +624,7 @@ typedef enum opcodeval {
Op_builtin,
Op_sub_builtin, /* sub, gsub and gensub */
+ Op_ext_builtin,
Op_in_array, /* boolean test of membership in array */
/* function call instruction */
@@ -534,7 +632,7 @@ typedef enum opcodeval {
Op_indirect_func_call,
Op_push, /* scalar variable */
- Op_push_arg, /* variable type (scalar or array) argument to built-in */
+ Op_push_arg, /* variable type (scalar or array) argument to built-in */
Op_push_i, /* number, string */
Op_push_re, /* regex */
Op_push_array,
@@ -559,7 +657,6 @@ typedef enum opcodeval {
Op_after_beginfile,
Op_after_endfile,
- Op_ext_func,
Op_func,
Op_exec_count,
@@ -588,7 +685,8 @@ typedef enum opcodeval {
enum redirval {
/* I/O redirections */
- redirect_output = 1,
+ redirect_none = 0,
+ redirect_output,
redirect_append,
redirect_pipe,
redirect_pipein,
@@ -660,6 +758,7 @@ typedef struct exp_instruction {
/* Op_token */
#define lextok d.name
+#define param_count x.xl
/* Op_rule */
#define in_rule x.xl
@@ -668,11 +767,11 @@ typedef struct exp_instruction {
/* Op_K_case, Op_K_default */
#define case_stmt x.xi
#define case_exp d.di
-#define stmt_start case_exp
-#define stmt_end case_stmt
-#define match_exp x.xl
+#define stmt_start case_exp
+#define stmt_end case_stmt
+#define match_exp x.xl
-#define target_stmt x.xi
+#define target_stmt x.xi
/* Op_K_switch */
#define switch_end x.xi
@@ -697,7 +796,7 @@ typedef struct exp_instruction {
#define func_body x.xn
/* Op_func_call */
-#define inrule d.dl
+#define tail_call d.dl
/* Op_subscript */
#define sub_count d.dl
@@ -732,9 +831,9 @@ typedef struct exp_instruction {
#define assign_ctxt d.dl
/* Op_concat */
-#define concat_flag d.dl
-#define CSUBSEP 1
-#define CSVAR 2
+#define concat_flag d.dl
+#define CSUBSEP 1
+#define CSVAR 2
/* Op_breakpoint */
#define break_pt x.bpt
@@ -764,6 +863,10 @@ typedef struct exp_instruction {
#define condpair_left d.di
#define condpair_right x.xi
+/* Op_store_var */
+#define initval x.xn
+
+
typedef struct iobuf {
const char *name; /* filename */
int fd; /* file descriptor */
@@ -778,6 +881,11 @@ typedef struct iobuf {
ssize_t count; /* amount read last time */
size_t scanoff; /* where we were in the buffer when we had
to regrow/refill */
+ /*
+ * No argument prototype on read_func. See get_src_buf()
+ * in awkgram.y.
+ */
+ ssize_t (*read_func)();
void *opaque; /* private data for open hooks */
int (*get_record)(char **out, struct iobuf *, int *errcode);
@@ -790,7 +898,7 @@ typedef struct iobuf {
# define IOP_NOFREE_OBJ 2
# define IOP_AT_EOF 4
# define IOP_CLOSED 8
-# define IOP_AT_START 16
+# define IOP_AT_START 16
} IOBUF;
typedef void (*Func_ptr)(void);
@@ -829,8 +937,8 @@ typedef struct srcfile {
struct srcfile *next;
struct srcfile *prev;
- enum srctype { SRC_CMDLINE = 1, SRC_STDIN, SRC_FILE, SRC_INC } stype;
- char *src; /* name on command line or inclde statement */
+ enum srctype { SRC_CMDLINE = 1, SRC_STDIN, SRC_FILE, SRC_INC, SRC_EXTLIB } stype;
+ char *src; /* name on command line or include statement */
char *fullpath; /* full path after AWKPATH search */
time_t mtime;
struct stat sbuf;
@@ -856,7 +964,7 @@ typedef struct context {
SRCFILE srcfiles;
int sourceline;
char *source;
- void (*install_func)(char *);
+ void (*install_func)(NODE *);
struct context *prev;
} AWK_CONTEXT;
@@ -866,6 +974,20 @@ struct flagtab {
const char *name;
};
+
+typedef struct block_item {
+ size_t size;
+ struct block_item *freep;
+} BLOCK;
+
+enum block_id {
+ BLOCK_INVALID = 0, /* not legal */
+ BLOCK_NODE,
+ BLOCK_BUCKET,
+ BLOCK_MAX /* count */
+};
+
+
#ifndef LONG_MAX
#define LONG_MAX ((long)(~(1L << (sizeof (long) * 8 - 1))))
#endif
@@ -899,28 +1021,75 @@ extern NODE *FNR_node, *FS_node, *IGNORECASE_node, *NF_node;
extern NODE *NR_node, *OFMT_node, *OFS_node, *ORS_node, *RLENGTH_node;
extern NODE *RSTART_node, *RS_node, *RT_node, *SUBSEP_node, *PROCINFO_node;
extern NODE *LINT_node, *ERRNO_node, *TEXTDOMAIN_node, *FPAT_node;
+extern NODE *PREC_node, *ROUNDMODE_node;
extern NODE *Nnull_string;
extern NODE *Null_field;
extern NODE **fields_arr;
extern int sourceline;
extern char *source;
+extern int (*interpret)(INSTRUCTION *); /* interpreter routine */
+extern NODE *(*make_number)(double); /* double instead of AWKNUM on purpose */
+extern NODE *(*str2number)(NODE *);
+extern NODE *(*format_val)(const char *, int, NODE *);
+extern int (*cmp_numbers)(const NODE *, const NODE *);
+
+typedef int (*Func_pre_exec)(INSTRUCTION **);
+typedef void (*Func_post_exec)(INSTRUCTION *);
#if __GNUC__ < 2
-extern NODE *_t; /* used as temporary in tree_eval */
+extern NODE *_t; /* used as temporary in macros */
#endif
-extern NODE *_r; /* used as temporary in stack macros */
+extern NODE *_r; /* used as temporary in macros */
-extern NODE *nextfree;
+extern BLOCK nextfree[];
extern int field0_valid;
-extern int do_traditional;
-extern int do_posix;
-extern int do_intervals;
-extern int do_intl;
-extern int do_non_decimal_data;
-extern int do_profiling;
-extern int do_dump_vars;
-extern int do_tidy_mem;
-extern int do_sandbox;
+
+extern int do_flags;
+
+/* only warn about invalid */
+#define DO_LINT_INVALID 0x0001
+/* warn about all things */
+#define DO_LINT_ALL 0x0002
+/* warn about stuff not in V7 awk */
+#define DO_LINT_OLD 0x0004
+/* no gnu extensions, add traditional weirdnesses */
+#define DO_TRADITIONAL 0x0008
+/* turn off gnu and unix extensions */
+#define DO_POSIX 0x0010
+/* dump locale-izable strings to stdout */
+#define DO_INTL 0x0020
+/* allow octal/hex C style DATA. Use with caution! */
+#define DO_NON_DEC_DATA 0x0040
+/* allow {...,...} in regexps, see resetup() */
+#define DO_INTERVALS 0x0080
+/* pretty print the program */
+#define DO_PRETTY_PRINT 0x0100
+/* dump all global variables at end */
+#define DO_DUMP_VARS 0x0200
+/* release vars when done */
+#define DO_TIDY_MEM 0x0400
+/* sandbox mode - disable 'system' function & redirections */
+#define DO_SANDBOX 0x0800
+/* profile the program */
+#define DO_PROFILE 0x1000
+/* debug the program */
+#define DO_DEBUG 0x2000
+/* arbitrary-precision floating-point math */
+#define DO_MPFR 0x4000
+
+#define do_traditional (do_flags & DO_TRADITIONAL)
+#define do_posix (do_flags & DO_POSIX)
+#define do_intl (do_flags & DO_INTL)
+#define do_non_decimal_data (do_flags & DO_NON_DEC_DATA)
+#define do_intervals (do_flags & DO_INTERVALS)
+#define do_pretty_print (do_flags & DO_PRETTY_PRINT)
+#define do_profile (do_flags & DO_PROFILE)
+#define do_dump_vars (do_flags & DO_DUMP_VARS)
+#define do_tidy_mem (do_flags & DO_TIDY_MEM)
+#define do_sandbox (do_flags & DO_SANDBOX)
+#define do_debug (do_flags & DO_DEBUG)
+#define do_mpfr (do_flags & DO_MPFR)
+
extern int do_optimize;
extern int use_lc_numeric;
extern int exit_val;
@@ -929,8 +1098,8 @@ extern int exit_val;
#define do_lint 0
#define do_lint_old 0
#else
-extern int do_lint;
-extern int do_lint_old;
+#define do_lint (do_flags & (DO_LINT_INVALID|DO_LINT_ALL))
+#define do_lint_old (do_flags & DO_LINT_OLD)
#endif
#if MBS_SUPPORT
extern int gawk_mb_cur_max;
@@ -947,6 +1116,16 @@ extern int ngroups;
extern struct lconv loc;
#endif /* HAVE_LOCALE_H */
+#ifdef HAVE_MPFR
+extern mpfr_prec_t PRECISION;
+extern mpfr_rnd_t ROUND_MODE;
+extern mpz_t MNR;
+extern mpz_t MFNR;
+extern mpz_t mpzval;
+extern int do_ieee_fmt; /* emulate IEEE 754 floating-point format */
+#endif
+
+
extern const char *myname;
extern const char def_strftime_format[];
@@ -956,18 +1135,11 @@ extern char envsep;
extern char casetable[]; /* for case-independent regexp matching */
-/*
- * Provide a way for code to know which program is executing:
- * gawk vs dgawk vs pgawk.
- */
-enum exe_mode { exe_normal = 1, exe_debugging, exe_profiling };
-extern enum exe_mode which_gawk; /* (defined in eval.c) */
-
/* ------------------------- Runtime stack -------------------------------- */
typedef union stack_item {
- NODE *rptr; /* variable etc. */
- NODE **lptr; /* address of a variable etc. */
+ NODE *rptr; /* variable etc. */
+ NODE **lptr; /* address of a variable etc. */
} STACK_ITEM;
extern STACK_ITEM *stack_ptr;
@@ -975,83 +1147,109 @@ extern NODE *frame_ptr;
extern STACK_ITEM *stack_bottom;
extern STACK_ITEM *stack_top;
-#define decr_sp() (stack_ptr--)
+#define decr_sp() (stack_ptr--)
#define incr_sp() ((stack_ptr < stack_top) ? ++stack_ptr : grow_stack())
-#define stack_adj(n) (stack_ptr += (n))
-#define stack_empty() (stack_ptr < stack_bottom)
-
-#define POP() decr_sp()->rptr
-#define POP_ADDRESS() decr_sp()->lptr
-#define PEEK(n) (stack_ptr - (n))->rptr
-#define TOP() stack_ptr->rptr /* same as PEEK(0) */
-#define TOP_ADDRESS() stack_ptr->lptr
-#define PUSH(r) (void) (incr_sp()->rptr = (r))
-#define PUSH_ADDRESS(l) (void) (incr_sp()->lptr = (l))
-#define REPLACE(r) (void) (stack_ptr->rptr = (r))
-#define REPLACE_ADDRESS(l) (void) (stack_ptr->lptr = (l))
-
+#define stack_adj(n) (stack_ptr += (n))
+#define stack_empty() (stack_ptr < stack_bottom)
+
+#define POP() decr_sp()->rptr
+#define POP_ADDRESS() decr_sp()->lptr
+#define PEEK(n) (stack_ptr - (n))->rptr
+#define TOP() stack_ptr->rptr /* same as PEEK(0) */
+#define TOP_ADDRESS() stack_ptr->lptr
+#define PUSH(r) (void) (incr_sp()->rptr = (r))
+#define PUSH_ADDRESS(l) (void) (incr_sp()->lptr = (l))
+#define REPLACE(r) (void) (stack_ptr->rptr = (r))
+#define REPLACE_ADDRESS(l) (void) (stack_ptr->lptr = (l))
/* function param */
-#define GET_PARAM(n) frame_ptr->stack[n]
+#define GET_PARAM(n) frame_ptr->stack[n]
/*
- * UPREF and DEREF --- simplified versions of dupnode and unref
- * UPREF does not handle FIELD node. Most appropriate use is
- * for elements on the runtime stack. When in doubt, use dupnode.
- */
+ * UPREF --- simplified versions of dupnode, does not handle FIELD node.
+ * Most appropriate use is for elements on the runtime stack.
+ * When in doubt, use dupnode.
+ */
-#define DEREF(r) ( _r = (r), (!(_r->flags & PERM) && (--_r->valref == 0)) ? unref(_r) : (void)0 )
+#define UPREF(r) (void) ((r)->valref++)
+
+#define DEREF(r) ( _r = (r), (--_r->valref == 0) ? r_unref(_r) : (void)0 )
#if __GNUC__ >= 2
-#define UPREF(r) ({ NODE *_t = (r); !(_t->flags & PERM) && _t->valref++;})
#define POP_ARRAY() ({ NODE *_t = POP(); \
- _t->type == Node_var_array ? \
- _t : get_array(_t, TRUE); })
+ _t->type == Node_var_array ? _t : get_array(_t, TRUE); })
#define POP_PARAM() ({ NODE *_t = POP(); \
- _t->type == Node_var_array ? \
- _t : get_array(_t, FALSE); })
+ _t->type == Node_var_array ? _t : get_array(_t, FALSE); })
-#define POP_NUMBER(x) ({ NODE *_t = POP_SCALAR(); \
- x = force_number(_t); DEREF(_t); })
-#define TOP_NUMBER(x) ({ NODE *_t = TOP_SCALAR(); \
- x = force_number(_t); DEREF(_t); })
+#define POP_SCALAR() ({ NODE *_t = POP(); _t->type != Node_var_array ? _t \
+ : (fatal(_("attempt to use array `%s' in a scalar context"), array_vname(_t)), _t);})
+#define TOP_SCALAR() ({ NODE *_t = TOP(); _t->type != Node_var_array ? _t \
+ : (fatal(_("attempt to use array `%s' in a scalar context"), array_vname(_t)), _t);})
-#define POP_SCALAR() ({ NODE *_t = POP(); _t->type != Node_var_array ? _t \
- : (fatal(_("attempt to use array `%s' in a scalar context"), array_vname(_t)), _t);})
-#define TOP_SCALAR() ({ NODE *_t = TOP(); _t->type != Node_var_array ? _t \
- : (fatal(_("attempt to use array `%s' in a scalar context"), array_vname(_t)), _t);})
+#define POP_STRING() force_string(POP_SCALAR())
+#define TOP_STRING() force_string(TOP_SCALAR())
#else /* not __GNUC__ */
-#define UPREF(r) (_t = (r), !(_t->flags & PERM) && _t->valref++)
-
#define POP_ARRAY() (_t = POP(), \
- _t->type == Node_var_array ? \
- _t : get_array(_t, TRUE))
+ _t->type == Node_var_array ? _t : get_array(_t, TRUE))
#define POP_PARAM() (_t = POP(), \
- _t->type == Node_var_array ? \
- _t : get_array(_t, FALSE))
-
-#define POP_NUMBER(x) (_t = POP_SCALAR(), \
- x = force_number(_t), DEREF(_t))
-#define TOP_NUMBER(x) (_t = TOP_SCALAR(), \
- x = force_number(_t), DEREF(_t))
+ _t->type == Node_var_array ? _t : get_array(_t, FALSE))
#define POP_SCALAR() (_t = POP(), _t->type != Node_var_array ? _t \
- : (fatal(_("attempt to use array `%s' in a scalar context"), array_vname(_t)), _t))
+ : (fatal(_("attempt to use array `%s' in a scalar context"), array_vname(_t)), _t))
#define TOP_SCALAR() (_t = TOP(), _t->type != Node_var_array ? _t \
- : (fatal(_("attempt to use array `%s' in a scalar context"), array_vname(_t)), _t))
+ : (fatal(_("attempt to use array `%s' in a scalar context"), array_vname(_t)), _t))
-#endif /* __GNUC__ */
+#define POP_STRING() (_r = POP_SCALAR(), m_force_string(_r))
+#define TOP_STRING() (_r = TOP_SCALAR(), m_force_string(_r))
+#endif /* __GNUC__ */
-#define POP_STRING() force_string(POP_SCALAR())
-#define TOP_STRING() force_string(TOP_SCALAR())
+#define POP_NUMBER() force_number(POP_SCALAR())
+#define TOP_NUMBER() force_number(TOP_SCALAR())
/* ------------------------- Pseudo-functions ------------------------- */
+#ifdef HAVE_MPFR
+/* conversion to C types */
+#define get_number_ui(n) (((n)->flags & MPFN) ? mpfr_get_ui((n)->mpg_numbr, ROUND_MODE) \
+ : ((n)->flags & MPZN) ? mpz_get_ui((n)->mpg_i) \
+ : (unsigned long) (n)->numbr)
+#define get_number_si(n) (((n)->flags & MPFN) ? mpfr_get_si((n)->mpg_numbr, ROUND_MODE) \
+ : ((n)->flags & MPZN) ? mpz_get_si((n)->mpg_i) \
+ : (long) (n)->numbr)
+#define get_number_d(n) (((n)->flags & MPFN) ? mpfr_get_d((n)->mpg_numbr, ROUND_MODE) \
+ : ((n)->flags & MPZN) ? mpz_get_d((n)->mpg_i) \
+ : (double) (n)->numbr)
+#define get_number_uj(n) (((n)->flags & MPFN) ? mpfr_get_uj((n)->mpg_numbr, ROUND_MODE) \
+ : ((n)->flags & MPZN) ? (uintmax_t) mpz_get_d((n)->mpg_i) \
+ : (uintmax_t) (n)->numbr)
+
+#define iszero(n) (((n)->flags & MPFN) ? mpfr_zero_p((n)->mpg_numbr) \
+ : ((n)->flags & MPZN) ? (mpz_sgn((n)->mpg_i) == 0) \
+ : ((n)->numbr == 0.0))
+
+#define IEEE_FMT(r, t) (void) (do_ieee_fmt && format_ieee(r, t))
+
+#define mpg_float() mpg_node(MPFN)
+#define mpg_integer() mpg_node(MPZN)
+#define is_mpg_float(n) (((n)->flags & MPFN) != 0)
+#define is_mpg_integer(n) (((n)->flags & MPZN) != 0)
+#define is_mpg_number(n) (((n)->flags & (MPZN|MPFN)) != 0)
+#else
+#define get_number_ui(n) (unsigned long) (n)->numbr
+#define get_number_si(n) (long) (n)->numbr
+#define get_number_d(n) (double) (n)->numbr
+#define get_number_uj(n) (uintmax_t) (n)->numbr
+
+#define is_mpg_number(n) 0
+#define is_mpg_float(n) 0
+#define is_mpg_integer(n) 0
+#define iszero(n) ((n)->numbr == 0.0)
+#endif
#define is_identchar(c) (isalnum(c) || (c) == '_')
@@ -1060,21 +1258,20 @@ extern STACK_ITEM *stack_top;
#define get_lhs(n, r) (n)->type == Node_var && ! var_uninitialized(n) ? \
&((n)->var_value) : r_get_lhs((n), (r))
-#ifdef MPROF
-#define getnode(n) emalloc((n), NODE *, sizeof(NODE), "getnode"), \
- (n)->flags = 0
-#define freenode(n) efree(n)
-#else /* not MPROF */
-#define getnode(n) (void) (nextfree ? \
- (n = nextfree, nextfree = nextfree->nextp) \
- : (n = more_nodes()))
-#define freenode(n) ((n)->flags = 0, (n)->nextp = nextfree, nextfree = (n))
-#endif /* not MPROF */
+#define getblock(p, id, ty) (void) ((p = (ty) nextfree[id].freep) ? \
+ (ty) (nextfree[id].freep = ((BLOCK *) p)->freep) \
+ : (p = (ty) more_blocks(id)))
+#define freeblock(p, id) (void) (((BLOCK *) p)->freep = nextfree[id].freep, \
+ nextfree[id].freep = (BLOCK *) p)
+
+#define getnode(n) getblock(n, BLOCK_NODE, NODE *)
+#define freenode(n) freeblock(n, BLOCK_NODE)
-#define make_number(x) mk_number((x), (unsigned int)(MALLOC|NUMCUR|NUMBER))
+#define getbucket(b) getblock(b, BLOCK_BUCKET, BUCKET *)
+#define freebucket(b) freeblock(b, BLOCK_BUCKET)
-#define make_string(s, l) r_make_str_node((s), (size_t) (l), 0)
-#define make_str_node(s, l, f) r_make_str_node((s), (size_t) (l), (f))
+#define make_string(s, l) r_make_str_node((s), (l), 0)
+#define make_str_node(s, l, f) r_make_str_node((s), (l), (f))
#define SCAN 1
#define ALREADY_MALLOCED 2
@@ -1093,20 +1290,35 @@ extern STACK_ITEM *stack_top;
#define efree(p) free(p)
#ifdef GAWKDEBUG
-#define force_number r_force_number
-#define force_string r_force_string
+#define force_number str2number
+#define dupnode r_dupnode
+#define unref r_unref
+#define m_force_string r_force_string
+extern NODE *r_force_string(NODE *s);
#else /* not GAWKDEBUG */
+
+#define unref(r) ( _r = (r), (_r == NULL || --_r->valref > 0) ? \
+ (void)0 : r_unref(_r) )
+
+#define m_force_string(_ts) (((_ts->flags & STRCUR) && \
+ (_ts->stfmt == -1 || _ts->stfmt == CONVFMTidx)) ? \
+ _ts : format_val(CONVFMT, CONVFMTidx, _ts))
+
#if __GNUC__ >= 2
-#define force_number(n) __extension__ ({NODE *_tn = (n);\
- (_tn->flags & NUMCUR) ? _tn->numbr : r_force_number(_tn);})
+#define dupnode(n) __extension__ ({ NODE *_tn = (n); \
+ (_tn->flags & MALLOC) ? (_tn->valref++, _tn) : r_dupnode(_tn); })
+
+#define force_number(n) __extension__ ({ NODE *_tn = (n); \
+ (_tn->flags & NUMCUR) ? _tn : str2number(_tn); })
+
+#define force_string(s) __extension__ ({ NODE *_ts = (s); m_force_string(_ts); })
-#define force_string(s) __extension__ ({NODE *_ts = (s);\
- ((_ts->flags & STRCUR) && \
- (_ts->stfmt == -1 || _ts->stfmt == CONVFMTidx)) ?\
- _ts : format_val(CONVFMT, CONVFMTidx, _ts);})
#else /* not __GNUC__ */
-#define force_number r_force_number
-#define force_string r_force_string
+#define dupnode(n) (_t = (n), \
+ (_t->flags & MALLOC) ? (_t->valref++, _t) : r_dupnode(_t))
+
+#define force_number str2number
+#define force_string(s) (_t = (s), m_force_string(_t))
#endif /* __GNUC__ */
#endif /* GAWKDEBUG */
@@ -1119,60 +1331,75 @@ extern int fatal_tag_valid;
if (val++) \
memcpy((char *) (stack), (const char *) tag, sizeof(jmp_buf))
#define POP_BINDING(stack, tag, val) \
-if (--val) \
+if (--val) \
memcpy((char *) tag, (const char *) (stack), sizeof(jmp_buf))
-/* ------------- Function prototypes or defs (as appropriate) ------------- */
-typedef int (*Func_print)(FILE *, const char *, ...);
+#define array_empty(a) ((a)->table_size == 0)
+#define assoc_lookup(a, s) (a)->alookup(a, s)
+
+/* assoc_clear --- flush all the values in symbol[] */
+#define assoc_clear(a) (void) ((a)->aclear(a, NULL))
+
+/* assoc_remove --- remove an index from symbol[] */
+#define assoc_remove(a, s) ((a)->aremove(a, s) != NULL)
+
+#if __GNUC__ >= 2
+#define in_array(a, s) ({ NODE **_l; _l = (a)->aexists(a, s); _l ? *_l : NULL; })
+#else /* not __GNUC__ */
+#define in_array(a, s) r_in_array(a, s)
+#endif /* __GNUC__ */
+
+
+/* ------------- Function prototypes or defs (as appropriate) ------------- */
/* array.c */
typedef enum sort_context { SORTED_IN = 1, ASORT, ASORTI } SORT_CTXT;
-extern NODE **assoc_list(NODE *array, const char *sort_str, SORT_CTXT sort_ctxt);
+enum assoc_list_flags {
+AINDEX = 0x01, /* list of indices */
+AVALUE = 0x02, /* list of values */
+AINUM = 0x04, /* numeric index */
+AISTR = 0x08, /* string index */
+AVNUM = 0x10, /* numeric scalar value */
+AVSTR = 0x20, /* string scalar value */
+AASC = 0x40, /* ascending order */
+ADESC = 0x80, /* descending order */
+ADELETE = 0x100, /* need a single index; for use in do_delete_loop */
+};
+
+extern NODE *make_array(void);
+extern void init_array(NODE *symbol);
extern NODE *get_array(NODE *symbol, int canfatal);
-extern char *array_vname(const NODE *symbol);
+extern const char *make_aname(const NODE *symbol);
+extern const char *array_vname(const NODE *symbol);
extern void array_init(void);
+extern int register_array_func(array_ptr *afunc);
extern void set_SUBSEP(void);
extern NODE *concat_exp(int nargs, int do_subsep);
-extern void ahash_unref(NODE *tmp);
-extern void assoc_clear(NODE *symbol);
-extern NODE *in_array(NODE *symbol, NODE *subs);
-extern NODE **assoc_lookup(NODE *symbol, NODE *subs, int reference);
+extern NODE *r_in_array(NODE *symbol, NODE *subs);
+extern NODE *assoc_copy(NODE *symbol, NODE *newsymb);
+extern void assoc_dump(NODE *symbol, NODE *p);
+extern NODE **assoc_list(NODE *symbol, const char *sort_str, SORT_CTXT sort_ctxt);
+extern void assoc_info(NODE *subs, NODE *val, NODE *p, const char *aname);
extern void do_delete(NODE *symbol, int nsubs);
extern void do_delete_loop(NODE *symbol, NODE **lhs);
-extern NODE *assoc_dump(NODE *symbol, int indent_level);
extern NODE *do_adump(int nargs);
+extern NODE *do_aoption(int nargs);
extern NODE *do_asort(int nargs);
extern NODE *do_asorti(int nargs);
extern unsigned long (*hash)(const char *s, size_t len, unsigned long hsize, size_t *code);
/* awkgram.c */
-extern NODE *mk_symbol(NODETYPE type, NODE *value);
-extern NODE *install_symbol(char *name, NODE *value);
-extern NODE *remove_symbol(char *name);
-extern NODE *lookup(const char *name);
-extern NODE *variable(char *name, NODETYPE type);
+extern NODE *variable(int location, char *name, NODETYPE type);
extern int parse_program(INSTRUCTION **pcode);
extern void dump_funcs(void);
extern void dump_vars(const char *fname);
-extern void release_all_vars(void);
extern const char *getfname(NODE *(*)(int));
-extern NODE *stopme(int nargs);
extern void shadow_funcs(void);
extern int check_special(const char *name);
-extern int foreach_func(int (*)(INSTRUCTION *, void *), int, void *);
-extern INSTRUCTION *bcalloc(OPCODE op, int size, int srcline);
-extern void bcfree(INSTRUCTION *);
extern SRCFILE *add_srcfile(int stype, char *src, SRCFILE *curr, int *already_included, int *errcode);
extern void register_deferred_variable(const char *name, NODE *(*load_func)(void));
extern int files_are_same(char *path, SRCFILE *src);
extern void valinfo(NODE *n, Func_print print_func, FILE *fp);
-extern void print_vars(Func_print print_func, FILE *fp);
-extern AWK_CONTEXT *new_context(void);
-extern void push_context(AWK_CONTEXT *ctxt);
-extern void pop_context();
-extern int in_main_context();
-extern void free_context(AWK_CONTEXT *ctxt, int );
-extern void append_symbol(char *name);
-
+extern void negate_num(NODE *n);
/* builtin.c */
extern double double_to_int(double d);
extern NODE *do_exp(int nargs);
@@ -1221,8 +1448,9 @@ extern int strncasecmpmbs(const unsigned char *,
/* eval.c */
extern void PUSH_CODE(INSTRUCTION *cp);
extern INSTRUCTION *POP_CODE(void);
-extern int interpret(INSTRUCTION *);
-extern int cmp_nodes(NODE *, NODE *);
+extern void init_interpret(void);
+extern int cmp_nodes(NODE *t1, NODE *t2);
+extern int cmp_awknums(const NODE *t1, const NODE *t2);
extern void set_IGNORECASE(void);
extern void set_OFS(void);
extern void set_ORS(void);
@@ -1241,20 +1469,18 @@ extern const char *flags2str(int);
extern const char *genflags2str(int flagval, const struct flagtab *tab);
extern const char *nodetype2str(NODETYPE type);
extern void load_casetable(void);
-
extern AWKNUM calc_exp(AWKNUM x1, AWKNUM x2);
extern const char *opcode2str(OPCODE type);
extern const char *op2str(OPCODE type);
extern NODE **r_get_lhs(NODE *n, int reference);
extern STACK_ITEM *grow_stack(void);
-#ifdef PROFILING
extern void dump_fcall_stack(FILE *fp);
-#endif
+extern int register_exec_hook(Func_pre_exec preh, Func_post_exec posth);
/* ext.c */
NODE *do_ext(int nargs);
+NODE *load_ext(const char *lib_name, const char *init_func, NODE *obj);
#ifdef DYNAMIC
void make_builtin(const char *, NODE *(*)(int), int);
-size_t get_curfunc_arg_count(void);
NODE *get_argument(int);
NODE *get_actual_argument(int, int, int);
#define get_scalar_argument(i, opt) get_actual_argument((i), (opt), FALSE)
@@ -1297,6 +1523,7 @@ extern int ispath(const char *file);
extern int isdirpunct(int c);
/* io.c */
+extern void init_io(void);
extern void register_open_hook(void *(*open_func)(IOBUF *));
extern void set_FNR(void);
extern void set_NR(void);
@@ -1307,8 +1534,8 @@ extern int flush_io(void);
extern int close_io(int *stdio_problem);
extern int devopen(const char *name, const char *mode);
extern int srcopen(SRCFILE *s);
-extern char *find_source(const char *src, struct stat *stb, int *errcode);
-extern NODE *do_getline_redir(int intovar, int redirtype);
+extern char *find_source(const char *src, struct stat *stb, int *errcode, int is_extlib);
+extern NODE *do_getline_redir(int intovar, enum redirval redirtype);
extern NODE *do_getline(int intovar, IOBUF *iop);
extern struct redirect *getredirect(const char *str, int len);
extern int inrec(IOBUF *iop, int *errcode);
@@ -1318,6 +1545,37 @@ extern int arg_assign(char *arg, int initing);
extern int is_std_var(const char *var);
extern char *estrdup(const char *str, size_t len);
extern void update_global_values();
+extern long getenv_long(const char *name);
+
+/* mpfr.c */
+extern void set_PREC(void);
+extern void set_ROUNDMODE(void);
+#ifdef HAVE_MPFR
+extern int mpg_cmp(const NODE *, const NODE *);
+extern int format_ieee(mpfr_ptr, int);
+extern NODE *mpg_update_var(NODE *);
+extern long mpg_set_var(NODE *);
+extern NODE *do_mpfr_and(int);
+extern NODE *do_mpfr_atan2(int);
+extern NODE *do_mpfr_compl(int);
+extern NODE *do_mpfr_cos(int);
+extern NODE *do_mpfr_exp(int);
+extern NODE *do_mpfr_int(int);
+extern NODE *do_mpfr_log(int);
+extern NODE *do_mpfr_lshift(int);
+extern NODE *do_mpfr_or(int);
+extern NODE *do_mpfr_rand(int);
+extern NODE *do_mpfr_rhift(int);
+extern NODE *do_mpfr_sin(int);
+extern NODE *do_mpfr_sqrt(int);
+extern NODE *do_mpfr_srand(int);
+extern NODE *do_mpfr_strtonum(int);
+extern NODE *do_mpfr_xor(int);
+extern void init_mpfr(mpfr_prec_t, const char *);
+extern NODE *mpg_node(unsigned int);
+extern const char *mpg_fmt(const char *, ...);
+extern int mpg_strtoui(mpz_ptr, char *, size_t, char **, int);
+#endif
/* msg.c */
extern void gawk_exit(int status);
extern void err(const char *s, const char *emsg, va_list argp) ATTRIBUTE_PRINTF(2, 0);
@@ -1336,21 +1594,19 @@ extern void init_profiling(int *flag, const char *def_file);
extern void init_profiling_signals(void);
extern void set_prof_file(const char *filename);
extern void dump_prog(INSTRUCTION *code);
-extern char *pp_number(AWKNUM d);
+extern char *pp_number(NODE *n);
extern char *pp_string(const char *in_str, size_t len, int delim);
extern char *pp_node(NODE *n);
extern int pp_func(INSTRUCTION *pc, void *);
extern void pp_string_fp(Func_print print_func, FILE *fp, const char *str,
size_t namelen, int delim, int breaklines);
/* node.c */
-extern AWKNUM r_force_number(NODE *n);
-extern NODE *format_val(const char *format, int index, NODE *s);
-extern NODE *r_force_string(NODE *s);
-extern NODE *dupnode(NODE *n);
-extern NODE *mk_number(AWKNUM x, unsigned int flags);
-extern NODE *r_make_str_node(const char *s, unsigned long len, int scan);
-extern NODE *more_nodes(void);
-extern void unref(NODE *tmp);
+extern NODE *r_force_number(NODE *n);
+extern NODE *r_format_val(const char *format, int index, NODE *s);
+extern NODE *r_dupnode(NODE *n);
+extern NODE *r_make_str_node(const char *s, size_t len, int flags);
+extern void *more_blocks(int id);
+extern void r_unref(NODE *tmp);
extern int parse_escape(const char **string_ptr);
#if MBS_SUPPORT
extern NODE *str2wstr(NODE *n, size_t **ptr);
@@ -1378,8 +1634,30 @@ extern void resyntax(int syntax);
extern void resetup(void);
extern int avoid_dfa(NODE *re, char *str, size_t len);
extern int reisstring(const char *text, size_t len, Regexp *re, const char *buf);
-extern int remaybelong(const char *text, size_t len);
-extern int isnondecimal(const char *str, int use_locale);
+extern int get_numbase(const char *str, int use_locale);
+
+/* symbol.c */
+extern NODE *install_symbol(char *name, NODETYPE type);
+extern NODE *remove_symbol(NODE *r);
+extern void destroy_symbol(NODE *r);
+extern void release_symbols(NODE *symlist, int keep_globals);
+extern void append_symbol(NODE *r);
+extern NODE *lookup(const char *name);
+extern NODE *make_params(char **pnames, int pcount);
+extern void install_params(NODE *func);
+extern void remove_params(NODE *func);
+extern void release_all_vars(void);
+extern int foreach_func(NODE **table, int (*)(INSTRUCTION *, void *), void *);
+extern INSTRUCTION *bcalloc(OPCODE op, int size, int srcline);
+extern void bcfree(INSTRUCTION *);
+extern AWK_CONTEXT *new_context(void);
+extern void push_context(AWK_CONTEXT *ctxt);
+extern void pop_context();
+extern int in_main_context();
+extern void free_context(AWK_CONTEXT *ctxt, int );
+extern NODE **variable_list();
+extern NODE **function_list(int sort);
+extern void print_vars(NODE **table, Func_print print_func, FILE *fp);
/* floatcomp.c */
#ifdef VMS /* VMS linker weirdness? */
diff --git a/awkgram.c b/awkgram.c
index 0b439184..761b839b 100644
--- a/awkgram.c
+++ b/awkgram.c
@@ -86,19 +86,15 @@ static char *get_src_buf(void);
static int yylex(void);
int yyparse(void);
static INSTRUCTION *snode(INSTRUCTION *subn, INSTRUCTION *op);
-static int func_install(INSTRUCTION *fp, INSTRUCTION *def);
-static void pop_params(NODE *params);
-static NODE *make_param(char *pname);
+static char **check_params(char *fname, int pcount, INSTRUCTION *list);
+static int install_function(char *fname, INSTRUCTION *fi, INSTRUCTION *plist);
static NODE *mk_rexp(INSTRUCTION *exp);
-static void append_param(char *pname);
-static int dup_parms(INSTRUCTION *fp, NODE *func);
static void param_sanity(INSTRUCTION *arglist);
static int parms_shadow(INSTRUCTION *pc, int *shadow);
static int isnoeffect(OPCODE type);
static INSTRUCTION *make_assignable(INSTRUCTION *ip);
static void dumpintlstr(const char *str, size_t len);
static void dumpintlstr2(const char *str1, size_t len1, const char *str2, size_t len2);
-static int isarray(NODE *n);
static int include_source(INSTRUCTION *file);
static void next_sourcefile(void);
static char *tokexpand(void);
@@ -107,6 +103,7 @@ static char *tokexpand(void);
static INSTRUCTION *mk_program(void);
static INSTRUCTION *append_rule(INSTRUCTION *pattern, INSTRUCTION *action);
+static INSTRUCTION *mk_function(INSTRUCTION *fi, INSTRUCTION *def);
static INSTRUCTION *mk_condition(INSTRUCTION *cond, INSTRUCTION *ifp, INSTRUCTION *true_branch,
INSTRUCTION *elsep, INSTRUCTION *false_branch);
static INSTRUCTION *mk_expression_list(INSTRUCTION *list, INSTRUCTION *s1);
@@ -125,16 +122,13 @@ static void add_lint(INSTRUCTION *list, LINTTYPE linttype);
enum defref { FUNC_DEFINE, FUNC_USE };
static void func_use(const char *name, enum defref how);
static void check_funcs(void);
-static void free_bcpool(INSTRUCTION *pl);
static ssize_t read_one_line(int fd, void *buffer, size_t count);
static int one_line_close(int fd);
-static void (*install_func)(char *) = NULL;
-
static int want_source = FALSE;
static int want_regexp; /* lexical scanning kludge */
-static int can_return; /* parsing kludge */
+static char *in_function; /* parsing kludge */
static int rule = 0;
const char *const ruletab[] = {
@@ -169,27 +163,17 @@ static int continue_allowed; /* kludge for continue */
#define END_SRC -2000
#define YYDEBUG_LEXER_TEXT (lexeme)
-static int param_counter;
-static NODE *func_params; /* list of parameters for the current function */
static char *tokstart = NULL;
static char *tok = NULL;
static char *tokend;
static int errcount = 0;
-static NODE *symbol_list;
-extern void destroy_symbol(char *name);
-
-static long func_count; /* total number of functions */
-
-#define HASHSIZE 1021 /* this constant only used here */
-NODE *variables[HASHSIZE];
-static int var_count; /* total number of global variables */
-
extern char *source;
extern int sourceline;
extern SRCFILE *srcfiles;
extern INSTRUCTION *rule_list;
extern int max_args;
+extern NODE **args_array;
static INSTRUCTION *rule_block[sizeof(ruletab)];
@@ -206,22 +190,12 @@ static inline INSTRUCTION *list_prepend(INSTRUCTION *l, INSTRUCTION *x);
static inline INSTRUCTION *list_merge(INSTRUCTION *l1, INSTRUCTION *l2);
extern double fmod(double x, double y);
-/*
- * This string cannot occur as a real awk identifier.
- * Use it as a special token to make function parsing
- * uniform, but if it's seen, don't install the function.
- * e.g.
- * function split(x) { return x }
- * function x(a) { return a }
- * should only produce one error message, and not core dump.
- */
-static char builtin_func[] = "@builtin";
#define YYSTYPE INSTRUCTION *
/* Line 268 of yacc.c */
-#line 225 "awkgram.c"
+#line 199 "awkgram.c"
/* Enabling traces. */
#ifndef YYDEBUG
@@ -367,7 +341,7 @@ typedef int YYSTYPE;
/* Line 343 of yacc.c */
-#line 371 "awkgram.c"
+#line 345 "awkgram.c"
#ifdef short
# undef short
@@ -583,16 +557,16 @@ union yyalloc
/* YYFINAL -- State number of the termination state. */
#define YYFINAL 2
/* YYLAST -- Last index in YYTABLE. */
-#define YYLAST 1157
+#define YYLAST 1150
/* YYNTOKENS -- Number of terminals. */
#define YYNTOKENS 74
/* YYNNTS -- Number of nonterminals. */
-#define YYNNTS 65
+#define YYNNTS 64
/* YYNRULES -- Number of rules. */
-#define YYNRULES 185
+#define YYNRULES 184
/* YYNRULES -- Number of states. */
-#define YYNSTATES 330
+#define YYNSTATES 329
/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */
#define YYUNDEFTOK 2
@@ -644,110 +618,110 @@ static const yytype_uint16 yyprhs[] =
{
0, 0, 3, 4, 7, 10, 13, 16, 19, 22,
25, 30, 32, 35, 37, 38, 40, 45, 47, 49,
- 51, 53, 59, 61, 63, 65, 68, 70, 72, 73,
- 81, 82, 86, 88, 90, 91, 94, 97, 99, 102,
- 105, 109, 111, 121, 128, 137, 146, 159, 171, 173,
- 176, 179, 182, 185, 189, 190, 195, 198, 199, 204,
- 205, 210, 215, 217, 218, 220, 221, 224, 227, 233,
- 238, 240, 243, 246, 248, 250, 252, 254, 256, 260,
- 261, 262, 266, 273, 283, 285, 288, 289, 291, 292,
- 295, 296, 298, 300, 304, 306, 309, 313, 314, 316,
- 317, 319, 321, 325, 327, 330, 334, 338, 342, 346,
- 350, 354, 358, 362, 368, 370, 372, 374, 377, 379,
- 381, 383, 385, 387, 389, 392, 394, 398, 402, 406,
- 410, 414, 418, 422, 425, 428, 434, 439, 443, 447,
- 451, 455, 459, 463, 465, 468, 472, 477, 482, 484,
- 486, 488, 491, 494, 496, 498, 501, 504, 506, 509,
- 514, 515, 517, 518, 521, 523, 526, 528, 532, 534,
- 537, 540, 542, 545, 547, 551, 553, 555, 556, 559,
- 562, 564, 565, 567, 569, 571
+ 51, 53, 59, 61, 63, 65, 68, 70, 72, 79,
+ 80, 84, 86, 88, 89, 92, 95, 97, 100, 103,
+ 107, 109, 119, 126, 135, 144, 157, 169, 171, 174,
+ 177, 180, 183, 187, 188, 193, 196, 197, 202, 203,
+ 208, 213, 215, 216, 218, 219, 222, 225, 231, 236,
+ 238, 241, 244, 246, 248, 250, 252, 254, 258, 259,
+ 260, 264, 271, 281, 283, 286, 287, 289, 290, 293,
+ 294, 296, 298, 302, 304, 307, 311, 312, 314, 315,
+ 317, 319, 323, 325, 328, 332, 336, 340, 344, 348,
+ 352, 356, 360, 366, 368, 370, 372, 375, 377, 379,
+ 381, 383, 385, 387, 390, 392, 396, 400, 404, 408,
+ 412, 416, 420, 423, 426, 432, 437, 441, 445, 449,
+ 453, 457, 461, 463, 466, 470, 475, 480, 482, 484,
+ 486, 489, 492, 494, 496, 499, 502, 504, 507, 512,
+ 513, 515, 516, 519, 521, 524, 526, 530, 532, 535,
+ 538, 540, 543, 545, 549, 551, 553, 554, 557, 560,
+ 562, 563, 565, 567, 569
};
/* YYRHS -- A `-1'-separated list of the rules' RHS. */
static const yytype_int16 yyrhs[] =
{
- 75, 0, -1, -1, 75, 76, -1, 75, 104, -1,
+ 75, 0, -1, -1, 75, 76, -1, 75, 103, -1,
75, 47, -1, 75, 1, -1, 78, 79, -1, 78,
- 88, -1, 82, 79, -1, 68, 48, 77, 88, -1,
- 6, -1, 6, 1, -1, 1, -1, -1, 112, -1,
- 112, 54, 105, 112, -1, 17, -1, 18, -1, 36,
- -1, 37, -1, 132, 87, 133, 135, 105, -1, 4,
+ 87, -1, 82, 79, -1, 68, 48, 77, 87, -1,
+ 6, -1, 6, 1, -1, 1, -1, -1, 111, -1,
+ 111, 54, 104, 111, -1, 17, -1, 18, -1, 36,
+ -1, 37, -1, 131, 86, 132, 134, 104, -1, 4,
-1, 3, -1, 81, -1, 68, 49, -1, 45, -1,
- 46, -1, -1, 35, 83, 80, 66, 107, 134, 105,
- -1, -1, 86, 85, 5, -1, 60, -1, 51, -1,
- -1, 87, 89, -1, 87, 1, -1, 104, -1, 136,
- 105, -1, 136, 105, -1, 132, 87, 133, -1, 103,
- -1, 23, 66, 112, 134, 105, 132, 96, 105, 133,
- -1, 26, 66, 112, 134, 105, 89, -1, 27, 105,
- 89, 26, 66, 112, 134, 105, -1, 28, 66, 4,
- 40, 129, 134, 105, 89, -1, 28, 66, 95, 136,
- 105, 112, 136, 105, 95, 134, 105, 89, -1, 28,
- 66, 95, 136, 105, 136, 105, 95, 134, 105, 89,
- -1, 90, -1, 29, 88, -1, 30, 88, -1, 33,
- 88, -1, 39, 88, -1, 34, 109, 88, -1, -1,
- 21, 91, 109, 88, -1, 92, 88, -1, -1, 99,
- 93, 100, 101, -1, -1, 22, 4, 94, 123, -1,
- 22, 66, 4, 67, -1, 112, -1, -1, 92, -1,
- -1, 96, 97, -1, 96, 1, -1, 24, 98, 137,
- 105, 87, -1, 25, 137, 105, 87, -1, 7, -1,
- 58, 7, -1, 57, 7, -1, 8, -1, 84, -1,
- 31, -1, 32, -1, 110, -1, 66, 111, 134, -1,
- -1, -1, 10, 102, 116, -1, 19, 66, 112, 134,
- 105, 89, -1, 19, 66, 112, 134, 105, 89, 20,
- 105, 89, -1, 50, -1, 104, 50, -1, -1, 104,
- -1, -1, 55, 117, -1, -1, 108, -1, 4, -1,
- 108, 138, 4, -1, 1, -1, 108, 1, -1, 108,
- 138, 1, -1, -1, 112, -1, -1, 111, -1, 112,
- -1, 111, 138, 112, -1, 1, -1, 111, 1, -1,
- 111, 1, 112, -1, 111, 138, 1, -1, 130, 113,
- 112, -1, 112, 41, 112, -1, 112, 42, 112, -1,
- 112, 14, 112, -1, 112, 40, 129, -1, 112, 115,
- 112, -1, 112, 52, 112, 53, 112, -1, 116, -1,
- 13, -1, 12, -1, 51, 13, -1, 9, -1, 55,
- -1, 114, -1, 56, -1, 117, -1, 118, -1, 116,
- 117, -1, 119, -1, 117, 64, 117, -1, 117, 59,
- 117, -1, 117, 60, 117, -1, 117, 61, 117, -1,
- 117, 57, 117, -1, 117, 58, 117, -1, 38, 122,
- 106, -1, 130, 43, -1, 130, 44, -1, 66, 111,
- 134, 40, 129, -1, 116, 11, 38, 122, -1, 118,
- 64, 117, -1, 118, 59, 117, -1, 118, 60, 117,
- -1, 118, 61, 117, -1, 118, 57, 117, -1, 118,
- 58, 117, -1, 84, -1, 62, 117, -1, 66, 112,
- 134, -1, 45, 66, 110, 134, -1, 46, 66, 110,
- 134, -1, 46, -1, 120, -1, 130, -1, 43, 130,
- -1, 44, 130, -1, 7, -1, 8, -1, 58, 117,
- -1, 57, 117, -1, 121, -1, 68, 121, -1, 3,
- 66, 110, 134, -1, -1, 130, -1, -1, 124, 16,
- -1, 125, -1, 124, 125, -1, 126, -1, 69, 111,
- 70, -1, 126, -1, 127, 126, -1, 127, 16, -1,
- 4, -1, 4, 128, -1, 129, -1, 65, 119, 131,
- -1, 43, -1, 44, -1, -1, 71, 105, -1, 72,
- 105, -1, 67, -1, -1, 136, -1, 73, -1, 53,
- -1, 54, 105, -1
+ 46, -1, 35, 80, 66, 106, 133, 104, -1, -1,
+ 85, 84, 5, -1, 60, -1, 51, -1, -1, 86,
+ 88, -1, 86, 1, -1, 103, -1, 135, 104, -1,
+ 135, 104, -1, 131, 86, 132, -1, 102, -1, 23,
+ 66, 111, 133, 104, 131, 95, 104, 132, -1, 26,
+ 66, 111, 133, 104, 88, -1, 27, 104, 88, 26,
+ 66, 111, 133, 104, -1, 28, 66, 4, 40, 128,
+ 133, 104, 88, -1, 28, 66, 94, 135, 104, 111,
+ 135, 104, 94, 133, 104, 88, -1, 28, 66, 94,
+ 135, 104, 135, 104, 94, 133, 104, 88, -1, 89,
+ -1, 29, 87, -1, 30, 87, -1, 33, 87, -1,
+ 39, 87, -1, 34, 108, 87, -1, -1, 21, 90,
+ 108, 87, -1, 91, 87, -1, -1, 98, 92, 99,
+ 100, -1, -1, 22, 4, 93, 122, -1, 22, 66,
+ 4, 67, -1, 111, -1, -1, 91, -1, -1, 95,
+ 96, -1, 95, 1, -1, 24, 97, 136, 104, 86,
+ -1, 25, 136, 104, 86, -1, 7, -1, 58, 7,
+ -1, 57, 7, -1, 8, -1, 83, -1, 31, -1,
+ 32, -1, 109, -1, 66, 110, 133, -1, -1, -1,
+ 10, 101, 115, -1, 19, 66, 111, 133, 104, 88,
+ -1, 19, 66, 111, 133, 104, 88, 20, 104, 88,
+ -1, 50, -1, 103, 50, -1, -1, 103, -1, -1,
+ 55, 116, -1, -1, 107, -1, 4, -1, 107, 137,
+ 4, -1, 1, -1, 107, 1, -1, 107, 137, 1,
+ -1, -1, 111, -1, -1, 110, -1, 111, -1, 110,
+ 137, 111, -1, 1, -1, 110, 1, -1, 110, 1,
+ 111, -1, 110, 137, 1, -1, 129, 112, 111, -1,
+ 111, 41, 111, -1, 111, 42, 111, -1, 111, 14,
+ 111, -1, 111, 40, 128, -1, 111, 114, 111, -1,
+ 111, 52, 111, 53, 111, -1, 115, -1, 13, -1,
+ 12, -1, 51, 13, -1, 9, -1, 55, -1, 113,
+ -1, 56, -1, 116, -1, 117, -1, 115, 116, -1,
+ 118, -1, 116, 64, 116, -1, 116, 59, 116, -1,
+ 116, 60, 116, -1, 116, 61, 116, -1, 116, 57,
+ 116, -1, 116, 58, 116, -1, 38, 121, 105, -1,
+ 129, 43, -1, 129, 44, -1, 66, 110, 133, 40,
+ 128, -1, 115, 11, 38, 121, -1, 117, 64, 116,
+ -1, 117, 59, 116, -1, 117, 60, 116, -1, 117,
+ 61, 116, -1, 117, 57, 116, -1, 117, 58, 116,
+ -1, 83, -1, 62, 116, -1, 66, 111, 133, -1,
+ 45, 66, 109, 133, -1, 46, 66, 109, 133, -1,
+ 46, -1, 119, -1, 129, -1, 43, 129, -1, 44,
+ 129, -1, 7, -1, 8, -1, 58, 116, -1, 57,
+ 116, -1, 120, -1, 68, 120, -1, 3, 66, 109,
+ 133, -1, -1, 129, -1, -1, 123, 16, -1, 124,
+ -1, 123, 124, -1, 125, -1, 69, 110, 70, -1,
+ 125, -1, 126, 125, -1, 126, 16, -1, 4, -1,
+ 4, 127, -1, 128, -1, 65, 118, 130, -1, 43,
+ -1, 44, -1, -1, 71, 104, -1, 72, 104, -1,
+ 67, -1, -1, 135, -1, 73, -1, 53, -1, 54,
+ 104, -1
};
/* YYRLINE[YYN] -- source line where rule number YYN was defined. */
static const yytype_uint16 yyrline[] =
{
- 0, 218, 218, 220, 225, 226, 230, 242, 246, 257,
- 265, 273, 281, 283, 289, 290, 292, 318, 329, 340,
- 346, 355, 365, 367, 369, 380, 385, 386, 391, 390,
- 420, 419, 452, 454, 459, 460, 473, 478, 479, 483,
- 485, 487, 494, 584, 626, 668, 781, 788, 795, 805,
- 814, 823, 832, 847, 863, 862, 874, 886, 886, 982,
- 982, 1007, 1030, 1036, 1037, 1043, 1044, 1051, 1056, 1068,
- 1082, 1084, 1090, 1095, 1097, 1105, 1107, 1116, 1117, 1125,
- 1130, 1130, 1141, 1145, 1153, 1154, 1157, 1159, 1164, 1165,
- 1172, 1174, 1178, 1184, 1191, 1193, 1195, 1202, 1203, 1209,
- 1210, 1215, 1217, 1222, 1224, 1226, 1228, 1234, 1241, 1243,
- 1245, 1261, 1271, 1278, 1280, 1285, 1287, 1289, 1297, 1299,
- 1304, 1306, 1311, 1313, 1315, 1368, 1370, 1372, 1374, 1376,
- 1378, 1380, 1382, 1405, 1410, 1415, 1440, 1446, 1448, 1450,
- 1452, 1454, 1456, 1461, 1465, 1496, 1498, 1504, 1510, 1523,
- 1524, 1525, 1530, 1535, 1539, 1543, 1555, 1568, 1573, 1609,
- 1627, 1628, 1634, 1635, 1640, 1642, 1649, 1666, 1683, 1685,
- 1692, 1697, 1705, 1719, 1731, 1740, 1744, 1748, 1752, 1756,
- 1760, 1763, 1765, 1769, 1773, 1777
+ 0, 192, 192, 194, 199, 200, 204, 216, 220, 231,
+ 237, 245, 253, 255, 261, 262, 264, 290, 301, 312,
+ 318, 327, 337, 339, 341, 347, 352, 353, 357, 376,
+ 375, 409, 411, 416, 417, 430, 435, 436, 440, 442,
+ 444, 451, 541, 583, 625, 738, 745, 752, 762, 771,
+ 780, 789, 804, 820, 819, 843, 855, 855, 953, 953,
+ 978, 1001, 1007, 1008, 1014, 1015, 1022, 1027, 1039, 1053,
+ 1055, 1063, 1068, 1070, 1078, 1080, 1089, 1090, 1098, 1103,
+ 1103, 1114, 1118, 1126, 1127, 1130, 1132, 1137, 1138, 1147,
+ 1148, 1153, 1158, 1164, 1166, 1168, 1175, 1176, 1182, 1183,
+ 1188, 1190, 1195, 1197, 1199, 1201, 1207, 1214, 1216, 1218,
+ 1234, 1244, 1251, 1253, 1258, 1260, 1262, 1270, 1272, 1277,
+ 1279, 1284, 1286, 1288, 1338, 1340, 1342, 1344, 1346, 1348,
+ 1350, 1352, 1375, 1380, 1385, 1410, 1416, 1418, 1420, 1422,
+ 1424, 1426, 1431, 1435, 1467, 1469, 1475, 1481, 1494, 1495,
+ 1496, 1501, 1506, 1510, 1514, 1529, 1542, 1547, 1583, 1601,
+ 1602, 1608, 1609, 1614, 1616, 1623, 1640, 1657, 1659, 1666,
+ 1671, 1679, 1689, 1701, 1710, 1714, 1718, 1722, 1726, 1730,
+ 1733, 1735, 1739, 1743, 1747
};
#endif
@@ -769,10 +743,10 @@ static const char *const yytname[] =
"'+'", "'-'", "'*'", "'/'", "'%'", "'!'", "UNARY", "'^'", "'$'", "'('",
"')'", "'@'", "'['", "']'", "'{'", "'}'", "';'", "$accept", "program",
"rule", "source", "pattern", "action", "func_name", "lex_builtin",
- "function_prologue", "$@1", "regexp", "$@2", "a_slash", "statements",
- "statement_term", "statement", "non_compound_stmt", "$@3", "simple_stmt",
- "$@4", "$@5", "opt_simple_stmt", "case_statements", "case_statement",
- "case_value", "print", "print_expression_list", "output_redir", "$@6",
+ "function_prologue", "regexp", "$@1", "a_slash", "statements",
+ "statement_term", "statement", "non_compound_stmt", "$@2", "simple_stmt",
+ "$@3", "$@4", "opt_simple_stmt", "case_statements", "case_statement",
+ "case_value", "print", "print_expression_list", "output_redir", "$@5",
"if_statement", "nls", "opt_nls", "input_redir", "opt_param_list",
"param_list", "opt_exp", "opt_expression_list", "expression_list", "exp",
"assign_operator", "relop_or_less", "a_relop", "common_exp", "simp_exp",
@@ -805,23 +779,23 @@ static const yytype_uint8 yyr1[] =
{
0, 74, 75, 75, 75, 75, 75, 76, 76, 76,
76, 77, 77, 77, 78, 78, 78, 78, 78, 78,
- 78, 79, 80, 80, 80, 80, 81, 81, 83, 82,
- 85, 84, 86, 86, 87, 87, 87, 88, 88, 89,
- 89, 89, 89, 89, 89, 89, 89, 89, 89, 90,
- 90, 90, 90, 90, 91, 90, 90, 93, 92, 94,
- 92, 92, 92, 95, 95, 96, 96, 96, 97, 97,
- 98, 98, 98, 98, 98, 99, 99, 100, 100, 101,
- 102, 101, 103, 103, 104, 104, 105, 105, 106, 106,
- 107, 107, 108, 108, 108, 108, 108, 109, 109, 110,
- 110, 111, 111, 111, 111, 111, 111, 112, 112, 112,
- 112, 112, 112, 112, 112, 113, 113, 113, 114, 114,
- 115, 115, 116, 116, 116, 117, 117, 117, 117, 117,
- 117, 117, 117, 117, 117, 117, 118, 118, 118, 118,
- 118, 118, 118, 119, 119, 119, 119, 119, 119, 119,
- 119, 119, 119, 119, 119, 119, 119, 120, 120, 121,
- 122, 122, 123, 123, 124, 124, 125, 126, 127, 127,
- 128, 129, 129, 130, 130, 131, 131, 131, 132, 133,
- 134, 135, 135, 136, 137, 138
+ 78, 79, 80, 80, 80, 80, 81, 81, 82, 84,
+ 83, 85, 85, 86, 86, 86, 87, 87, 88, 88,
+ 88, 88, 88, 88, 88, 88, 88, 88, 89, 89,
+ 89, 89, 89, 90, 89, 89, 92, 91, 93, 91,
+ 91, 91, 94, 94, 95, 95, 95, 96, 96, 97,
+ 97, 97, 97, 97, 98, 98, 99, 99, 100, 101,
+ 100, 102, 102, 103, 103, 104, 104, 105, 105, 106,
+ 106, 107, 107, 107, 107, 107, 108, 108, 109, 109,
+ 110, 110, 110, 110, 110, 110, 111, 111, 111, 111,
+ 111, 111, 111, 111, 112, 112, 112, 113, 113, 114,
+ 114, 115, 115, 115, 116, 116, 116, 116, 116, 116,
+ 116, 116, 116, 116, 116, 117, 117, 117, 117, 117,
+ 117, 117, 118, 118, 118, 118, 118, 118, 118, 118,
+ 118, 118, 118, 118, 118, 118, 119, 119, 120, 121,
+ 121, 122, 122, 123, 123, 124, 125, 126, 126, 127,
+ 128, 128, 129, 129, 130, 130, 130, 131, 132, 133,
+ 134, 134, 135, 136, 137
};
/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */
@@ -829,23 +803,23 @@ static const yytype_uint8 yyr2[] =
{
0, 2, 0, 2, 2, 2, 2, 2, 2, 2,
4, 1, 2, 1, 0, 1, 4, 1, 1, 1,
- 1, 5, 1, 1, 1, 2, 1, 1, 0, 7,
- 0, 3, 1, 1, 0, 2, 2, 1, 2, 2,
- 3, 1, 9, 6, 8, 8, 12, 11, 1, 2,
- 2, 2, 2, 3, 0, 4, 2, 0, 4, 0,
- 4, 4, 1, 0, 1, 0, 2, 2, 5, 4,
- 1, 2, 2, 1, 1, 1, 1, 1, 3, 0,
- 0, 3, 6, 9, 1, 2, 0, 1, 0, 2,
- 0, 1, 1, 3, 1, 2, 3, 0, 1, 0,
- 1, 1, 3, 1, 2, 3, 3, 3, 3, 3,
- 3, 3, 3, 5, 1, 1, 1, 2, 1, 1,
- 1, 1, 1, 1, 2, 1, 3, 3, 3, 3,
- 3, 3, 3, 2, 2, 5, 4, 3, 3, 3,
- 3, 3, 3, 1, 2, 3, 4, 4, 1, 1,
- 1, 2, 2, 1, 1, 2, 2, 1, 2, 4,
- 0, 1, 0, 2, 1, 2, 1, 3, 1, 2,
- 2, 1, 2, 1, 3, 1, 1, 0, 2, 2,
- 1, 0, 1, 1, 1, 2
+ 1, 5, 1, 1, 1, 2, 1, 1, 6, 0,
+ 3, 1, 1, 0, 2, 2, 1, 2, 2, 3,
+ 1, 9, 6, 8, 8, 12, 11, 1, 2, 2,
+ 2, 2, 3, 0, 4, 2, 0, 4, 0, 4,
+ 4, 1, 0, 1, 0, 2, 2, 5, 4, 1,
+ 2, 2, 1, 1, 1, 1, 1, 3, 0, 0,
+ 3, 6, 9, 1, 2, 0, 1, 0, 2, 0,
+ 1, 1, 3, 1, 2, 3, 0, 1, 0, 1,
+ 1, 3, 1, 2, 3, 3, 3, 3, 3, 3,
+ 3, 3, 5, 1, 1, 1, 2, 1, 1, 1,
+ 1, 1, 1, 2, 1, 3, 3, 3, 3, 3,
+ 3, 3, 2, 2, 5, 4, 3, 3, 3, 3,
+ 3, 3, 1, 2, 3, 4, 4, 1, 1, 1,
+ 2, 2, 1, 1, 2, 2, 1, 2, 4, 0,
+ 1, 0, 2, 1, 2, 1, 3, 1, 2, 2,
+ 1, 2, 1, 3, 1, 1, 0, 2, 2, 1,
+ 0, 1, 1, 1, 2
};
/* YYDEFACT[STATE-NAME] -- Default reduction number in state STATE-NUM.
@@ -853,353 +827,353 @@ static const yytype_uint8 yyr2[] =
means the default is an error. */
static const yytype_uint8 yydefact[] =
{
- 2, 0, 1, 6, 0, 171, 153, 154, 17, 18,
- 28, 19, 20, 160, 0, 0, 0, 148, 5, 84,
- 33, 0, 0, 32, 0, 0, 0, 0, 3, 0,
- 0, 143, 30, 4, 15, 114, 122, 123, 125, 149,
- 157, 173, 150, 0, 0, 168, 0, 172, 0, 88,
- 161, 151, 152, 0, 0, 0, 156, 150, 155, 144,
- 0, 177, 150, 103, 0, 101, 0, 158, 86, 183,
- 7, 8, 37, 34, 86, 9, 0, 85, 118, 0,
- 0, 0, 0, 0, 86, 119, 121, 120, 0, 0,
- 124, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 116, 115, 133, 134, 0, 0, 0,
- 0, 101, 0, 170, 169, 23, 22, 26, 27, 0,
- 0, 24, 0, 132, 0, 0, 0, 175, 176, 174,
- 104, 86, 180, 0, 0, 145, 13, 0, 0, 87,
- 178, 0, 38, 31, 110, 111, 108, 109, 0, 0,
- 112, 160, 130, 131, 127, 128, 129, 126, 141, 142,
- 138, 139, 140, 137, 117, 107, 159, 167, 25, 0,
- 89, 146, 147, 105, 185, 0, 106, 102, 12, 10,
- 36, 0, 54, 0, 0, 0, 86, 0, 0, 0,
- 75, 76, 0, 97, 0, 86, 35, 48, 0, 57,
- 41, 62, 34, 181, 86, 0, 16, 136, 94, 92,
- 0, 0, 135, 0, 97, 59, 0, 0, 0, 0,
- 63, 49, 50, 51, 0, 98, 52, 179, 56, 0,
- 0, 86, 182, 39, 113, 86, 95, 0, 0, 0,
- 162, 0, 0, 0, 0, 171, 64, 0, 53, 0,
- 79, 77, 40, 21, 29, 96, 93, 86, 55, 60,
- 0, 164, 166, 61, 86, 86, 0, 0, 86, 0,
- 80, 58, 0, 163, 165, 0, 0, 0, 0, 0,
- 78, 0, 82, 65, 43, 0, 86, 0, 86, 81,
- 86, 0, 86, 0, 86, 63, 0, 67, 0, 0,
- 66, 0, 44, 45, 63, 0, 83, 70, 73, 0,
- 0, 74, 0, 184, 86, 42, 0, 86, 72, 71,
- 86, 34, 86, 0, 34, 0, 0, 47, 0, 46
+ 2, 0, 1, 6, 0, 170, 152, 153, 17, 18,
+ 0, 19, 20, 159, 0, 0, 0, 147, 5, 83,
+ 32, 0, 0, 31, 0, 0, 0, 0, 3, 0,
+ 0, 142, 29, 4, 15, 113, 121, 122, 124, 148,
+ 156, 172, 149, 0, 0, 167, 0, 171, 23, 22,
+ 26, 27, 0, 0, 24, 87, 160, 150, 151, 0,
+ 0, 0, 155, 149, 154, 143, 0, 176, 149, 102,
+ 0, 100, 0, 157, 85, 182, 7, 8, 36, 33,
+ 85, 9, 0, 84, 117, 0, 0, 0, 0, 0,
+ 85, 118, 120, 119, 0, 0, 123, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 115,
+ 114, 132, 133, 0, 0, 0, 0, 100, 0, 169,
+ 168, 25, 0, 0, 131, 0, 0, 0, 174, 175,
+ 173, 103, 85, 179, 0, 0, 144, 13, 0, 0,
+ 86, 177, 0, 37, 30, 109, 110, 107, 108, 0,
+ 0, 111, 159, 129, 130, 126, 127, 128, 125, 140,
+ 141, 137, 138, 139, 136, 116, 106, 158, 166, 93,
+ 91, 0, 0, 88, 145, 146, 104, 184, 0, 105,
+ 101, 12, 10, 35, 0, 53, 0, 0, 0, 85,
+ 0, 0, 0, 74, 75, 0, 96, 0, 85, 34,
+ 47, 0, 56, 40, 61, 33, 180, 85, 0, 16,
+ 135, 85, 94, 0, 134, 0, 96, 58, 0, 0,
+ 0, 0, 62, 48, 49, 50, 0, 97, 51, 178,
+ 55, 0, 0, 85, 181, 38, 112, 28, 95, 92,
+ 0, 0, 161, 0, 0, 0, 0, 170, 63, 0,
+ 52, 0, 78, 76, 39, 21, 85, 54, 59, 0,
+ 163, 165, 60, 85, 85, 0, 0, 85, 0, 79,
+ 57, 0, 162, 164, 0, 0, 0, 0, 0, 77,
+ 0, 81, 64, 42, 0, 85, 0, 85, 80, 85,
+ 0, 85, 0, 85, 62, 0, 66, 0, 0, 65,
+ 0, 43, 44, 62, 0, 82, 69, 72, 0, 0,
+ 73, 0, 183, 85, 41, 0, 85, 71, 70, 85,
+ 33, 85, 0, 33, 0, 0, 46, 0, 45
};
/* YYDEFGOTO[NTERM-NUM]. */
static const yytype_int16 yydefgoto[] =
{
- -1, 1, 28, 138, 29, 70, 120, 121, 30, 48,
- 31, 76, 32, 141, 71, 196, 197, 214, 198, 229,
- 240, 247, 291, 300, 312, 199, 250, 271, 281, 200,
- 139, 140, 123, 210, 211, 224, 109, 110, 201, 108,
- 87, 88, 35, 36, 37, 38, 39, 40, 49, 259,
- 260, 261, 45, 46, 47, 41, 42, 129, 202, 203,
- 135, 231, 204, 314, 134
+ -1, 1, 28, 139, 29, 76, 53, 54, 30, 31,
+ 82, 32, 142, 77, 199, 200, 216, 201, 231, 242,
+ 249, 290, 299, 311, 202, 252, 270, 280, 203, 140,
+ 141, 124, 171, 172, 226, 115, 116, 204, 114, 93,
+ 94, 35, 36, 37, 38, 39, 40, 55, 258, 259,
+ 260, 45, 46, 47, 41, 42, 130, 205, 206, 136,
+ 233, 207, 313, 135
};
/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
STATE-NUM. */
-#define YYPACT_NINF -269
+#define YYPACT_NINF -264
static const yytype_int16 yypact[] =
{
- -269, 335, -269, -269, -31, -24, -269, -269, -269, -269,
- -269, -269, -269, 12, 12, 12, -19, -12, -269, -269,
- -269, 978, 978, -269, 978, 1023, 804, 21, -269, 115,
- -21, -269, -269, 8, 1062, 952, -20, 330, -269, -269,
- -269, -269, 246, 736, 804, -269, 2, -269, 205, 15,
- -269, -269, -269, 736, 736, 70, 52, 80, 52, 52,
- 978, 147, -269, -269, 50, 308, 174, -269, 64, -269,
- -269, -269, 8, -269, 64, -269, 129, -269, -269, 978,
- 143, 978, 978, 978, 64, -269, -269, -269, 978, 112,
- -20, 978, 978, 978, 978, 978, 978, 978, 978, 978,
- 978, 978, 978, -269, -269, -269, -269, 141, 978, 90,
- 152, 1101, 48, -269, -269, -269, -269, -269, -269, 111,
- 105, -269, 978, -269, 90, 90, 308, -269, -269, -269,
- 978, 64, -269, 134, 830, -269, -269, 13, -16, 8,
- -269, 552, -269, -269, 53, -269, 142, 300, 1081, 978,
- 103, 12, 185, 185, 52, 52, 52, 52, 185, 185,
- 52, 52, 52, 52, -269, 1101, -269, -269, -269, 63,
- -20, -269, -269, 1101, -269, 143, -269, 1101, -269, -269,
- -269, 121, -269, 6, 130, 137, 64, 139, -16, -16,
- -269, -269, -16, 978, -16, 64, -269, -269, -16, -269,
- -269, 1101, -269, 127, 64, 978, 1101, -269, -269, -269,
- 90, 118, -269, 978, 978, -269, 180, 978, 978, 665,
- 875, -269, -269, -269, -16, 1101, -269, -269, -269, 598,
- 552, 64, -269, -269, 1101, 64, -269, 28, 308, -16,
- -24, 140, 308, 308, 189, -14, -269, 127, -269, 804,
- 201, -269, -269, -269, -269, -269, -269, 64, -269, -269,
- 14, -269, -269, -269, 64, 64, 158, 143, 64, 50,
- -269, -269, 665, -269, -269, -21, 665, 978, 90, 710,
- 134, 978, 198, -269, -269, 308, 64, 1056, 64, 952,
- 64, 60, 64, 665, 64, 907, 665, -269, 119, 177,
- -269, 155, -269, -269, 907, 90, -269, -269, -269, 224,
- 228, -269, 177, -269, 64, -269, 90, 64, -269, -269,
- 64, -269, 64, 665, -269, 406, 665, -269, 479, -269
+ -264, 367, -264, -264, -31, -42, -264, -264, -264, -264,
+ 165, -264, -264, 46, 46, 46, -29, -27, -264, -264,
+ -264, 1010, 1010, -264, 1010, 1055, 836, 27, -264, -35,
+ -7, -264, -264, 17, 1088, 984, 288, 362, -264, -264,
+ -264, -264, 146, 768, 836, -264, 1, -264, -264, -264,
+ -264, -264, 60, -18, -264, 11, -264, -264, -264, 768,
+ 768, 74, 52, 9, 52, 52, 1010, 13, -264, -264,
+ 53, 341, 28, -264, 79, -264, -264, -264, 17, -264,
+ 79, -264, 119, -264, -264, 1010, 148, 1010, 1010, 1010,
+ 79, -264, -264, -264, 1010, 122, 288, 1010, 1010, 1010,
+ 1010, 1010, 1010, 1010, 1010, 1010, 1010, 1010, 1010, -264,
+ -264, -264, -264, 151, 1010, 94, 81, 1094, 40, -264,
+ -264, -264, 45, 1010, -264, 94, 94, 341, -264, -264,
+ -264, 1010, 79, -264, 125, 862, -264, -264, 82, -22,
+ 17, -264, 584, -264, -264, 62, -264, 212, 267, 301,
+ 1010, 118, 46, 127, 127, 52, 52, 52, 52, 127,
+ 127, 52, 52, 52, 52, -264, 1094, -264, -264, -264,
+ -264, 94, 61, 288, -264, -264, 1094, -264, 148, -264,
+ 1094, -264, -264, -264, 105, -264, 10, 109, 112, 79,
+ 113, -22, -22, -264, -264, -22, 1010, -22, 79, -264,
+ -264, -22, -264, -264, 1094, -264, 107, 79, 1010, 1094,
+ -264, 79, -264, 43, -264, 1010, 1010, -264, 180, 1010,
+ 1010, 697, 907, -264, -264, -264, -22, 1094, -264, -264,
+ -264, 630, 584, 79, -264, -264, 1094, -264, -264, -264,
+ 341, -22, -42, 126, 341, 341, 166, -14, -264, 107,
+ -264, 836, 190, -264, -264, -264, 79, -264, -264, 16,
+ -264, -264, -264, 79, 79, 136, 148, 79, 53, -264,
+ -264, 697, -264, -264, -7, 697, 1010, 94, 742, 125,
+ 1010, 186, -264, -264, 341, 79, 278, 79, 984, 79,
+ 132, 79, 697, 79, 939, 697, -264, 240, 155, -264,
+ 137, -264, -264, 939, 94, -264, -264, -264, 205, 206,
+ -264, 155, -264, 79, -264, 94, 79, -264, -264, 79,
+ -264, 79, 697, -264, 438, 697, -264, 511, -264
};
/* YYPGOTO[NTERM-NUM]. */
static const yytype_int16 yypgoto[] =
{
- -269, -269, -269, -269, -269, 208, -269, -269, -269, -269,
- -58, -269, -269, -193, 72, -171, -269, -269, -189, -269,
- -269, -268, -269, -269, -269, -269, -269, -269, -269, -269,
- 45, 37, -269, -269, -269, 38, -48, -23, -1, -269,
- -269, -269, -26, 44, -269, 217, -269, 1, 102, -269,
- -269, -3, -39, -269, -269, -72, -2, -269, -28, -213,
- -49, -269, -25, -47, 66
+ -264, -264, -264, -264, -264, 187, -264, -264, -264, -74,
+ -264, -264, -197, 98, -203, -264, -264, -213, -264, -264,
+ -263, -264, -264, -264, -264, -264, -264, -264, -264, 44,
+ 73, -264, -264, -264, 18, -54, -23, -1, -264, -264,
+ -264, -55, 39, -264, 202, -264, 124, 77, -264, -264,
+ -19, -39, -264, -264, -70, -2, -264, -28, -222, -46,
+ -264, -25, -79, 70
};
/* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If
positive, shift that token. If negative, reduce the rule which
number is the opposite. If YYTABLE_NINF, syntax error. */
-#define YYTABLE_NINF -101
+#define YYTABLE_NINF -100
static const yytype_int16 yytable[] =
{
- 34, 73, 73, 64, 74, 124, 125, 114, 145, 230,
- 215, 50, 51, 52, 178, 133, 5, 252, 113, 57,
- 57, 112, 57, 62, 4, 65, 267, 305, 67, 255,
- 273, 246, 256, 57, 19, 43, 316, 91, 92, 93,
- 94, 95, 111, 111, 96, 44, 33, 53, 244, 130,
- 68, 130, 111, 111, 54, 44, 67, 69, 77, 126,
- 166, 297, 78, -11, 208, 56, 58, 209, 59, 66,
- 122, 44, 216, 4, 72, 171, 172, 25, 144, 90,
- 146, 147, 148, 44, 298, 299, -11, 150, 315, 57,
- 57, 57, 57, 57, 57, 57, 57, 57, 57, 57,
- 57, 282, 131, 212, 131, 284, 246, 165, 85, 86,
- 19, 142, -101, 74, 19, 246, 96, 132, 167, 236,
- 57, 149, 303, 105, 106, 306, 307, 308, 325, 173,
- -90, 328, -86, 177, 143, 152, 153, 154, 155, 156,
- 157, 158, 159, 160, 161, 162, 163, 5, 206, 50,
- 151, 78, 327, 130, 164, 329, 79, 132, -101, -101,
- 168, 235, -100, 74, 74, 19, 170, 74, 174, 74,
- 20, 169, 131, 74, 175, 136, 309, 310, 232, 23,
- 137, 251, 80, 72, 241, -91, 68, 213, 69, 257,
- 127, 128, 225, 264, 265, 278, 217, 85, 86, 74,
- 69, 262, -100, 218, 234, 220, 131, 263, 115, 116,
- 179, 270, 238, 225, 74, 266, 242, 243, 290, -100,
- 280, 262, 268, 219, 277, -100, 269, 195, 111, 286,
- 313, 318, 227, 72, 72, 319, 292, 72, 75, 72,
- 311, 233, 61, 72, 93, 94, 95, 283, 65, 96,
- 117, 118, 239, 207, 288, 289, 317, 274, 103, 104,
- 221, 222, 294, 0, 223, 320, 226, 322, 253, 72,
- 228, 0, 254, 119, 0, 0, 285, 237, 287, 57,
- 0, 0, 0, 0, 72, 0, 0, 57, 0, 105,
- 106, 0, 0, 0, 272, 0, 248, 107, 0, 0,
- 0, 275, 276, 0, 0, 279, 0, 0, 0, 78,
- 0, 258, 0, 0, 79, 0, 0, 78, 0, 0,
- 0, 0, 79, 293, 0, 295, 0, 296, 301, 302,
- 0, 304, 0, 90, 0, 2, 3, 0, 4, 5,
- 80, 81, 6, 7, 0, 0, 0, 0, 80, 81,
- 82, 321, 8, 9, 323, 85, 86, 324, 0, 326,
- 83, 0, 0, 85, 86, 0, 0, 0, 0, 0,
- 10, 11, 12, 13, 0, 132, 0, 0, 14, 15,
- 16, 17, 18, 0, 0, 19, 20, 97, 98, 99,
- 100, 101, 21, 22, 102, 23, 0, 24, 0, 0,
- 25, 26, 0, 27, 0, 0, -14, 180, -14, 4,
- 5, 0, 0, 6, 7, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 181, 0, 182, 183, 184,
- -69, -69, 185, 186, 187, 188, 189, 190, 191, 192,
- 193, 0, 0, 0, 13, 194, 0, 0, 0, 14,
- 15, 16, 17, 0, 0, 0, -69, 20, 0, 0,
- 0, 0, 0, 21, 22, 0, 23, 0, 24, 0,
- 0, 25, 26, 0, 55, 0, 0, 68, -69, 69,
- 180, 0, 4, 5, 0, 0, 6, 7, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 181, 0,
- 182, 183, 184, -68, -68, 185, 186, 187, 188, 189,
- 190, 191, 192, 193, 0, 0, 0, 13, 194, 0,
- 0, 0, 14, 15, 16, 17, 0, 0, 0, -68,
- 20, 0, 0, 0, 0, 0, 21, 22, 0, 23,
- 0, 24, 0, 0, 25, 26, 0, 55, 0, 0,
- 68, -68, 69, 180, 0, 4, 5, 0, 0, 6,
- 7, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 181, 0, 182, 183, 184, 0, 0, 185, 186,
- 187, 188, 189, 190, 191, 192, 193, 0, 0, 0,
- 13, 194, 0, 0, 0, 14, 15, 16, 17, 63,
- 0, 4, 5, 20, 0, 6, 7, 0, -99, 21,
- 22, 0, 23, 0, 24, 0, 0, 25, 26, 0,
- 55, 0, 0, 68, 195, 69, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 13, 0, 0, 0,
- 0, 14, 15, 16, 17, 0, 0, 0, -99, 20,
+ 34, 79, 79, 70, 80, 125, 126, 120, 232, 248,
+ 254, 56, 57, 58, 217, 19, 146, 119, 246, 63,
+ 63, 118, 63, 68, 134, 71, 266, 44, 19, 137,
+ 4, 304, 272, 63, 138, 43, 74, 59, 75, 60,
+ 315, 131, 117, 117, 238, 33, 169, 239, 122, 170,
+ 5, 75, 111, 112, 131, 44, 128, 129, 117, 117,
+ 62, 64, 212, 65, 74, 127, 123, 83, 281, 167,
+ 44, 84, 283, 78, 96, 72, 218, 4, 314, 174,
+ 175, 248, 131, 181, 145, 44, 147, 148, 149, 302,
+ 248, -99, 305, 151, 132, 63, 63, 63, 63, 63,
+ 63, 63, 63, 63, 63, 63, 63, 132, 214, 121,
+ 168, 25, -89, 166, 80, 132, 102, 91, 92, 326,
+ 133, 63, 328, 324, 144, 211, 327, -100, -90, 19,
+ 176, -99, -11, 296, 180, 132, 153, 154, 155, 156,
+ 157, 158, 159, 160, 161, 162, 163, 164, -99, 209,
+ 56, 73, 5, 143, -99, -11, 297, 298, 109, 110,
+ 152, 133, 173, 150, 165, 178, 80, 80, 48, 49,
+ 80, 215, 80, -100, -100, 219, 80, 253, 220, 222,
+ 75, 234, 19, 78, 243, 73, 99, 100, 101, 111,
+ 112, 102, 265, 262, 256, 227, 277, 113, 263, 264,
+ 269, 80, 276, 261, -85, 177, 289, 236, 312, 198,
+ 50, 51, 317, 318, 240, 227, 80, 81, 244, 245,
+ 261, 84, 279, 310, 267, 288, 85, 67, 268, 210,
+ 117, 285, 319, 52, 241, 78, 78, 182, 291, 78,
+ 273, 78, 213, 0, 0, 78, 282, 306, 307, 0,
+ 71, 0, 86, 287, 0, 0, 0, 0, 316, 0,
+ 0, 293, 221, 0, 0, 0, 0, 91, 92, 321,
+ 78, 229, 0, 0, 0, 284, 84, 286, 63, 0,
+ 235, 85, 0, 0, 237, 78, 63, 84, 0, 223,
+ 224, 20, 85, 225, 0, 228, 0, 308, 309, 230,
+ 23, 0, 0, 0, 0, 0, 255, 86, 87, 0,
+ 84, 0, 0, 0, 0, 85, 0, 0, 86, 87,
+ 88, 0, 91, 92, 250, 0, 0, 96, 0, 271,
+ 89, 0, 0, 91, 92, 0, 274, 275, 0, 257,
+ 278, 86, 87, 88, 0, 97, 98, 99, 100, 101,
+ 84, 75, 102, 89, 208, 85, 91, 92, 292, 0,
+ 294, 0, 295, 300, 301, 0, 303, 2, 3, 0,
+ 4, 5, 0, 0, 6, 7, 0, 0, 0, 0,
+ 0, 86, 87, 88, 8, 9, 320, 0, 0, 322,
+ 0, 0, 323, 89, 325, 0, 91, 92, 0, 0,
+ 0, 0, 10, 11, 12, 13, 0, 0, 133, 0,
+ 14, 15, 16, 17, 18, 0, 0, 19, 20, 103,
+ 104, 105, 106, 107, 21, 22, 108, 23, 0, 24,
+ 0, 0, 25, 26, 0, 27, 0, 0, -14, 183,
+ -14, 4, 5, 0, 0, 6, 7, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 184, 0, 185,
+ 186, 187, -68, -68, 188, 189, 190, 191, 192, 193,
+ 194, 195, 196, 0, 0, 0, 13, 197, 0, 0,
+ 0, 14, 15, 16, 17, 0, 0, 0, -68, 20,
0, 0, 0, 0, 0, 21, 22, 0, 23, 0,
- 24, 0, 0, 25, 249, -99, 55, 0, 4, 5,
- 0, -99, 6, 7, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 181, 0, 182, 183, 184, 0,
- 0, 185, 186, 187, 188, 189, 190, 191, 192, 193,
- 0, 0, 0, 13, 194, 0, 0, 0, 14, 15,
- 16, 17, 0, 4, 5, 0, 20, 6, 7, 0,
- 0, 0, 21, 22, 0, 23, 0, 24, 0, 0,
- 25, 26, 0, 55, 0, 0, 68, 63, 69, 4,
- 5, 0, 0, 6, 7, 0, 0, 0, 13, 0,
- 0, 0, 0, 14, 15, 16, 17, 0, 0, 0,
- 0, 20, 0, 0, 0, 0, 0, 21, 22, 0,
- 23, 0, 24, 0, 13, 25, 26, 0, 55, 14,
- 15, 16, 17, 69, 0, 0, 0, 20, 0, 0,
- 0, 0, 0, 21, 22, 0, 23, 0, 24, 0,
- 0, 25, 26, -99, 55, 63, 0, 4, 5, 0,
+ 24, 0, 0, 25, 26, 0, 61, 0, 0, 74,
+ -68, 75, 183, 0, 4, 5, 0, 0, 6, 7,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 184, 0, 185, 186, 187, -67, -67, 188, 189, 190,
+ 191, 192, 193, 194, 195, 196, 0, 0, 0, 13,
+ 197, 0, 0, 0, 14, 15, 16, 17, 0, 0,
+ 0, -67, 20, 0, 0, 0, 0, 0, 21, 22,
+ 0, 23, 0, 24, 0, 0, 25, 26, 0, 61,
+ 0, 0, 74, -67, 75, 183, 0, 4, 5, 0,
0, 6, 7, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 184, 0, 185, 186, 187, 0, 0,
+ 188, 189, 190, 191, 192, 193, 194, 195, 196, 0,
+ 0, 0, 13, 197, 0, 0, 0, 14, 15, 16,
+ 17, 69, 0, 4, 5, 20, 0, 6, 7, 0,
+ -98, 21, 22, 0, 23, 0, 24, 0, 0, 25,
+ 26, 0, 61, 0, 0, 74, 198, 75, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 13, 0,
+ 0, 0, 0, 14, 15, 16, 17, 0, 0, 0,
+ -98, 20, 0, 0, 0, 0, 0, 21, 22, 0,
+ 23, 0, 24, 0, 0, 25, 251, -98, 61, 0,
+ 4, 5, 0, -98, 6, 7, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 184, 0, 185, 186,
+ 187, 0, 0, 188, 189, 190, 191, 192, 193, 194,
+ 195, 196, 0, 0, 0, 13, 197, 0, 0, 0,
+ 14, 15, 16, 17, 0, 4, 5, 0, 20, 6,
+ 7, 0, 0, 0, 21, 22, 0, 23, 0, 24,
+ 0, 0, 25, 26, 0, 61, 0, 0, 74, 69,
+ 75, 4, 5, 0, 0, 6, 7, 0, 0, 0,
+ 13, 0, 0, 0, 0, 14, 15, 16, 17, 0,
+ 0, 0, 0, 20, 0, 0, 0, 0, 0, 21,
+ 22, 0, 23, 0, 24, 0, 13, 25, 26, 0,
+ 61, 14, 15, 16, 17, 75, 0, 0, 0, 20,
+ 0, 0, 0, 0, 0, 21, 22, 0, 23, 0,
+ 24, 0, 0, 25, 26, -98, 61, 69, 0, 4,
+ 5, 0, 0, 6, 7, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 176, 0, 4, 5, 0, 0, 6, 7, 0,
+ 0, 0, 0, 179, 0, 4, 5, 0, 0, 6,
+ 7, 0, 0, 0, 13, 0, 0, 0, 0, 14,
+ 15, 16, 17, 0, 0, 0, 0, 20, 0, 0,
+ 0, 0, 0, 21, 22, 0, 23, 0, 24, 0,
+ 13, 25, 26, 0, 61, 14, 15, 16, 17, 0,
+ 4, 247, 0, 20, 6, 7, 0, 0, 0, 21,
+ 22, 0, 23, 0, 24, 0, 0, 25, 26, 186,
+ 61, 0, 0, 0, 0, 0, 0, 0, 193, 194,
+ 0, 0, 4, 5, 0, 13, 6, 7, 0, 0,
+ 14, 15, 16, 17, 0, 0, 0, 0, 20, 0,
+ 0, 186, 0, 0, 21, 22, 0, 23, 0, 24,
+ 193, 194, 25, 26, 0, 61, 0, 13, 0, 0,
+ 0, 0, 14, 15, 16, 17, 0, 4, 5, 0,
+ 20, 6, 7, 0, 0, 95, 21, 22, 0, 23,
+ 0, 24, 0, 0, 25, 26, 0, 61, 0, 0,
+ 0, 0, 0, 4, 5, 0, 0, 6, 7, 0,
0, 0, 13, 0, 0, 0, 0, 14, 15, 16,
17, 0, 0, 0, 0, 20, 0, 0, 0, 0,
0, 21, 22, 0, 23, 0, 24, 0, 13, 25,
- 26, 0, 55, 14, 15, 16, 17, 0, 4, 245,
+ 26, 0, 61, 14, 15, 16, 17, 0, 4, 5,
0, 20, 6, 7, 0, 0, 0, 21, 22, 0,
- 23, 0, 24, 0, 0, 25, 26, 183, 55, 0,
- 0, 0, 0, 0, 0, 0, 190, 191, 0, 0,
- 4, 5, 0, 13, 6, 7, 0, 0, 14, 15,
- 16, 17, 0, 0, 0, 0, 20, 0, 0, 183,
- 0, 0, 21, 22, 0, 23, 0, 24, 190, 191,
- 25, 26, 0, 55, 0, 13, 0, 0, 0, 0,
- 14, 15, 16, 17, 0, 4, 5, 0, 20, 6,
- 7, 0, 0, 89, 21, 22, 0, 23, 0, 24,
- 0, 0, 25, 26, 0, 55, 0, 0, 0, 0,
- 0, 4, 5, 0, 0, 6, 7, 0, 0, 0,
- 13, 0, 0, 0, 0, 14, 15, 16, 17, 0,
- 0, 0, 0, 20, 0, 0, 0, 0, 0, 21,
- 22, 0, 23, 0, 24, 0, 13, 25, 26, 0,
- 55, 14, 15, 16, 17, 0, 4, 5, 0, 20,
- 6, 7, 0, 0, 0, 21, 22, 0, 23, 0,
- 24, 0, 0, 25, 26, 0, 55, 0, 0, 0,
+ 23, 0, 24, 0, 0, 25, 26, 0, 61, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 78, 14, 15, 16, 17,
- 79, 78, 0, 0, 20, 0, 79, 0, 0, 0,
- 21, 22, 0, 23, 0, 24, 0, 0, 25, 60,
- 78, 55, 0, 0, 0, 79, 80, 81, 82, 0,
- 0, 0, 80, 81, 82, 0, 0, 0, 83, 0,
- 78, 85, 86, 0, 83, 79, 84, 85, 86, 0,
- 0, 80, 81, 82, 0, 0, 0, 0, 0, 69,
- 0, 0, 0, 83, 205, 0, 85, 86, 0, 0,
- 0, 80, 81, 82, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 83, 0, 0, 85, 86
+ 0, 0, 0, 0, 0, 0, 0, 84, 14, 15,
+ 16, 17, 85, 84, 0, 0, 20, 0, 85, 0,
+ 0, 0, 21, 22, 0, 23, 0, 24, 0, 0,
+ 25, 66, 0, 61, 0, 0, 0, 0, 86, 87,
+ 88, 0, 0, 0, 86, 87, 88, 0, 0, 0,
+ 89, 0, 90, 91, 92, 0, 89, 0, 0, 91,
+ 92
};
#define yypact_value_is_default(yystate) \
- ((yystate) == (-269))
+ ((yystate) == (-264))
#define yytable_value_is_error(yytable_value) \
- ((yytable_value) == (-101))
+ ((yytable_value) == (-100))
static const yytype_int16 yycheck[] =
{
- 1, 29, 30, 26, 29, 53, 54, 46, 80, 202,
- 4, 13, 14, 15, 1, 64, 4, 230, 16, 21,
- 22, 44, 24, 25, 3, 26, 40, 295, 27, 1,
- 16, 220, 4, 35, 50, 66, 304, 57, 58, 59,
- 60, 61, 43, 44, 64, 69, 1, 66, 219, 1,
- 71, 1, 53, 54, 66, 69, 55, 73, 50, 60,
- 109, 1, 9, 50, 1, 21, 22, 4, 24, 48,
- 55, 69, 66, 3, 29, 124, 125, 65, 79, 35,
- 81, 82, 83, 69, 24, 25, 73, 88, 301, 91,
- 92, 93, 94, 95, 96, 97, 98, 99, 100, 101,
- 102, 272, 54, 175, 54, 276, 295, 108, 55, 56,
- 50, 74, 9, 138, 50, 304, 64, 67, 70, 1,
- 122, 84, 293, 43, 44, 296, 7, 8, 321, 130,
- 67, 324, 72, 134, 5, 91, 92, 93, 94, 95,
- 96, 97, 98, 99, 100, 101, 102, 4, 149, 151,
- 38, 9, 323, 1, 13, 326, 14, 67, 55, 56,
- 49, 210, 10, 188, 189, 50, 122, 192, 131, 194,
- 51, 66, 54, 198, 40, 1, 57, 58, 203, 60,
- 6, 229, 40, 138, 4, 67, 71, 66, 73, 238,
- 43, 44, 193, 242, 243, 267, 66, 55, 56, 224,
- 73, 240, 50, 66, 205, 66, 54, 67, 3, 4,
- 138, 10, 213, 214, 239, 26, 217, 218, 20, 67,
- 269, 260, 247, 186, 66, 73, 249, 72, 229, 278,
- 53, 7, 195, 188, 189, 7, 285, 192, 30, 194,
- 298, 204, 25, 198, 59, 60, 61, 275, 249, 64,
- 45, 46, 214, 151, 279, 281, 305, 260, 12, 13,
- 188, 189, 287, -1, 192, 312, 194, 316, 231, 224,
- 198, -1, 235, 68, -1, -1, 277, 211, 279, 281,
- -1, -1, -1, -1, 239, -1, -1, 289, -1, 43,
- 44, -1, -1, -1, 257, -1, 224, 51, -1, -1,
- -1, 264, 265, -1, -1, 268, -1, -1, -1, 9,
- -1, 239, -1, -1, 14, -1, -1, 9, -1, -1,
- -1, -1, 14, 286, -1, 288, -1, 290, 291, 292,
- -1, 294, -1, 289, -1, 0, 1, -1, 3, 4,
- 40, 41, 7, 8, -1, -1, -1, -1, 40, 41,
- 42, 314, 17, 18, 317, 55, 56, 320, -1, 322,
- 52, -1, -1, 55, 56, -1, -1, -1, -1, -1,
- 35, 36, 37, 38, -1, 67, -1, -1, 43, 44,
- 45, 46, 47, -1, -1, 50, 51, 57, 58, 59,
- 60, 61, 57, 58, 64, 60, -1, 62, -1, -1,
- 65, 66, -1, 68, -1, -1, 71, 1, 73, 3,
- 4, -1, -1, 7, 8, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, 19, -1, 21, 22, 23,
- 24, 25, 26, 27, 28, 29, 30, 31, 32, 33,
- 34, -1, -1, -1, 38, 39, -1, -1, -1, 43,
- 44, 45, 46, -1, -1, -1, 50, 51, -1, -1,
- -1, -1, -1, 57, 58, -1, 60, -1, 62, -1,
- -1, 65, 66, -1, 68, -1, -1, 71, 72, 73,
- 1, -1, 3, 4, -1, -1, 7, 8, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, 19, -1,
- 21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
- 31, 32, 33, 34, -1, -1, -1, 38, 39, -1,
- -1, -1, 43, 44, 45, 46, -1, -1, -1, 50,
- 51, -1, -1, -1, -1, -1, 57, 58, -1, 60,
- -1, 62, -1, -1, 65, 66, -1, 68, -1, -1,
- 71, 72, 73, 1, -1, 3, 4, -1, -1, 7,
- 8, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, 19, -1, 21, 22, 23, -1, -1, 26, 27,
- 28, 29, 30, 31, 32, 33, 34, -1, -1, -1,
- 38, 39, -1, -1, -1, 43, 44, 45, 46, 1,
- -1, 3, 4, 51, -1, 7, 8, -1, 10, 57,
- 58, -1, 60, -1, 62, -1, -1, 65, 66, -1,
- 68, -1, -1, 71, 72, 73, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, 38, -1, -1, -1,
+ 1, 29, 30, 26, 29, 59, 60, 46, 205, 222,
+ 232, 13, 14, 15, 4, 50, 86, 16, 221, 21,
+ 22, 44, 24, 25, 70, 26, 40, 69, 50, 1,
+ 3, 294, 16, 35, 6, 66, 71, 66, 73, 66,
+ 303, 1, 43, 44, 1, 1, 1, 4, 66, 4,
+ 4, 73, 43, 44, 1, 69, 43, 44, 59, 60,
+ 21, 22, 1, 24, 71, 66, 55, 50, 271, 115,
+ 69, 9, 275, 29, 35, 48, 66, 3, 300, 125,
+ 126, 294, 1, 1, 85, 69, 87, 88, 89, 292,
+ 303, 10, 295, 94, 54, 97, 98, 99, 100, 101,
+ 102, 103, 104, 105, 106, 107, 108, 54, 178, 49,
+ 70, 65, 67, 114, 139, 54, 64, 55, 56, 322,
+ 67, 123, 325, 320, 5, 171, 323, 9, 67, 50,
+ 131, 50, 50, 1, 135, 54, 97, 98, 99, 100,
+ 101, 102, 103, 104, 105, 106, 107, 108, 67, 150,
+ 152, 27, 4, 80, 73, 73, 24, 25, 12, 13,
+ 38, 67, 123, 90, 13, 40, 191, 192, 3, 4,
+ 195, 66, 197, 55, 56, 66, 201, 231, 66, 66,
+ 73, 206, 50, 139, 4, 61, 59, 60, 61, 43,
+ 44, 64, 26, 67, 240, 196, 266, 51, 244, 245,
+ 10, 226, 66, 242, 72, 132, 20, 208, 53, 72,
+ 45, 46, 7, 7, 215, 216, 241, 30, 219, 220,
+ 259, 9, 268, 297, 249, 280, 14, 25, 251, 152,
+ 231, 277, 311, 68, 216, 191, 192, 139, 284, 195,
+ 259, 197, 172, -1, -1, 201, 274, 7, 8, -1,
+ 251, -1, 40, 278, -1, -1, -1, -1, 304, -1,
+ -1, 286, 189, -1, -1, -1, -1, 55, 56, 315,
+ 226, 198, -1, -1, -1, 276, 9, 278, 280, -1,
+ 207, 14, -1, -1, 211, 241, 288, 9, -1, 191,
+ 192, 51, 14, 195, -1, 197, -1, 57, 58, 201,
+ 60, -1, -1, -1, -1, -1, 233, 40, 41, -1,
+ 9, -1, -1, -1, -1, 14, -1, -1, 40, 41,
+ 42, -1, 55, 56, 226, -1, -1, 288, -1, 256,
+ 52, -1, -1, 55, 56, -1, 263, 264, -1, 241,
+ 267, 40, 41, 42, -1, 57, 58, 59, 60, 61,
+ 9, 73, 64, 52, 53, 14, 55, 56, 285, -1,
+ 287, -1, 289, 290, 291, -1, 293, 0, 1, -1,
+ 3, 4, -1, -1, 7, 8, -1, -1, -1, -1,
+ -1, 40, 41, 42, 17, 18, 313, -1, -1, 316,
+ -1, -1, 319, 52, 321, -1, 55, 56, -1, -1,
+ -1, -1, 35, 36, 37, 38, -1, -1, 67, -1,
+ 43, 44, 45, 46, 47, -1, -1, 50, 51, 57,
+ 58, 59, 60, 61, 57, 58, 64, 60, -1, 62,
+ -1, -1, 65, 66, -1, 68, -1, -1, 71, 1,
+ 73, 3, 4, -1, -1, 7, 8, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, 19, -1, 21,
+ 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
+ 32, 33, 34, -1, -1, -1, 38, 39, -1, -1,
-1, 43, 44, 45, 46, -1, -1, -1, 50, 51,
-1, -1, -1, -1, -1, 57, 58, -1, 60, -1,
- 62, -1, -1, 65, 66, 67, 68, -1, 3, 4,
- -1, 73, 7, 8, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, 19, -1, 21, 22, 23, -1,
- -1, 26, 27, 28, 29, 30, 31, 32, 33, 34,
- -1, -1, -1, 38, 39, -1, -1, -1, 43, 44,
- 45, 46, -1, 3, 4, -1, 51, 7, 8, -1,
- -1, -1, 57, 58, -1, 60, -1, 62, -1, -1,
- 65, 66, -1, 68, -1, -1, 71, 1, 73, 3,
- 4, -1, -1, 7, 8, -1, -1, -1, 38, -1,
- -1, -1, -1, 43, 44, 45, 46, -1, -1, -1,
- -1, 51, -1, -1, -1, -1, -1, 57, 58, -1,
- 60, -1, 62, -1, 38, 65, 66, -1, 68, 43,
- 44, 45, 46, 73, -1, -1, -1, 51, -1, -1,
- -1, -1, -1, 57, 58, -1, 60, -1, 62, -1,
- -1, 65, 66, 67, 68, 1, -1, 3, 4, -1,
+ 62, -1, -1, 65, 66, -1, 68, -1, -1, 71,
+ 72, 73, 1, -1, 3, 4, -1, -1, 7, 8,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ 19, -1, 21, 22, 23, 24, 25, 26, 27, 28,
+ 29, 30, 31, 32, 33, 34, -1, -1, -1, 38,
+ 39, -1, -1, -1, 43, 44, 45, 46, -1, -1,
+ -1, 50, 51, -1, -1, -1, -1, -1, 57, 58,
+ -1, 60, -1, 62, -1, -1, 65, 66, -1, 68,
+ -1, -1, 71, 72, 73, 1, -1, 3, 4, -1,
-1, 7, 8, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, 19, -1, 21, 22, 23, -1, -1,
+ 26, 27, 28, 29, 30, 31, 32, 33, 34, -1,
+ -1, -1, 38, 39, -1, -1, -1, 43, 44, 45,
+ 46, 1, -1, 3, 4, 51, -1, 7, 8, -1,
+ 10, 57, 58, -1, 60, -1, 62, -1, -1, 65,
+ 66, -1, 68, -1, -1, 71, 72, 73, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, 38, -1,
+ -1, -1, -1, 43, 44, 45, 46, -1, -1, -1,
+ 50, 51, -1, -1, -1, -1, -1, 57, 58, -1,
+ 60, -1, 62, -1, -1, 65, 66, 67, 68, -1,
+ 3, 4, -1, 73, 7, 8, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, 19, -1, 21, 22,
+ 23, -1, -1, 26, 27, 28, 29, 30, 31, 32,
+ 33, 34, -1, -1, -1, 38, 39, -1, -1, -1,
+ 43, 44, 45, 46, -1, 3, 4, -1, 51, 7,
+ 8, -1, -1, -1, 57, 58, -1, 60, -1, 62,
+ -1, -1, 65, 66, -1, 68, -1, -1, 71, 1,
+ 73, 3, 4, -1, -1, 7, 8, -1, -1, -1,
+ 38, -1, -1, -1, -1, 43, 44, 45, 46, -1,
+ -1, -1, -1, 51, -1, -1, -1, -1, -1, 57,
+ 58, -1, 60, -1, 62, -1, 38, 65, 66, -1,
+ 68, 43, 44, 45, 46, 73, -1, -1, -1, 51,
+ -1, -1, -1, -1, -1, 57, 58, -1, 60, -1,
+ 62, -1, -1, 65, 66, 67, 68, 1, -1, 3,
+ 4, -1, -1, 7, 8, -1, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, 1, -1, 3, 4, -1, -1, 7, 8, -1,
+ -1, -1, -1, 1, -1, 3, 4, -1, -1, 7,
+ 8, -1, -1, -1, 38, -1, -1, -1, -1, 43,
+ 44, 45, 46, -1, -1, -1, -1, 51, -1, -1,
+ -1, -1, -1, 57, 58, -1, 60, -1, 62, -1,
+ 38, 65, 66, -1, 68, 43, 44, 45, 46, -1,
+ 3, 4, -1, 51, 7, 8, -1, -1, -1, 57,
+ 58, -1, 60, -1, 62, -1, -1, 65, 66, 22,
+ 68, -1, -1, -1, -1, -1, -1, -1, 31, 32,
+ -1, -1, 3, 4, -1, 38, 7, 8, -1, -1,
+ 43, 44, 45, 46, -1, -1, -1, -1, 51, -1,
+ -1, 22, -1, -1, 57, 58, -1, 60, -1, 62,
+ 31, 32, 65, 66, -1, 68, -1, 38, -1, -1,
+ -1, -1, 43, 44, 45, 46, -1, 3, 4, -1,
+ 51, 7, 8, -1, -1, 11, 57, 58, -1, 60,
+ -1, 62, -1, -1, 65, 66, -1, 68, -1, -1,
+ -1, -1, -1, 3, 4, -1, -1, 7, 8, -1,
-1, -1, 38, -1, -1, -1, -1, 43, 44, 45,
46, -1, -1, -1, -1, 51, -1, -1, -1, -1,
-1, 57, 58, -1, 60, -1, 62, -1, 38, 65,
66, -1, 68, 43, 44, 45, 46, -1, 3, 4,
-1, 51, 7, 8, -1, -1, -1, 57, 58, -1,
- 60, -1, 62, -1, -1, 65, 66, 22, 68, -1,
- -1, -1, -1, -1, -1, -1, 31, 32, -1, -1,
- 3, 4, -1, 38, 7, 8, -1, -1, 43, 44,
- 45, 46, -1, -1, -1, -1, 51, -1, -1, 22,
- -1, -1, 57, 58, -1, 60, -1, 62, 31, 32,
- 65, 66, -1, 68, -1, 38, -1, -1, -1, -1,
- 43, 44, 45, 46, -1, 3, 4, -1, 51, 7,
- 8, -1, -1, 11, 57, 58, -1, 60, -1, 62,
- -1, -1, 65, 66, -1, 68, -1, -1, -1, -1,
- -1, 3, 4, -1, -1, 7, 8, -1, -1, -1,
- 38, -1, -1, -1, -1, 43, 44, 45, 46, -1,
- -1, -1, -1, 51, -1, -1, -1, -1, -1, 57,
- 58, -1, 60, -1, 62, -1, 38, 65, 66, -1,
- 68, 43, 44, 45, 46, -1, 3, 4, -1, 51,
- 7, 8, -1, -1, -1, 57, 58, -1, 60, -1,
- 62, -1, -1, 65, 66, -1, 68, -1, -1, -1,
+ 60, -1, 62, -1, -1, 65, 66, -1, 68, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, 9, 43, 44, 45, 46,
- 14, 9, -1, -1, 51, -1, 14, -1, -1, -1,
- 57, 58, -1, 60, -1, 62, -1, -1, 65, 66,
- 9, 68, -1, -1, -1, 14, 40, 41, 42, -1,
- -1, -1, 40, 41, 42, -1, -1, -1, 52, -1,
- 9, 55, 56, -1, 52, 14, 54, 55, 56, -1,
- -1, 40, 41, 42, -1, -1, -1, -1, -1, 73,
- -1, -1, -1, 52, 53, -1, 55, 56, -1, -1,
- -1, 40, 41, 42, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 52, -1, -1, 55, 56
+ -1, -1, -1, -1, -1, -1, -1, 9, 43, 44,
+ 45, 46, 14, 9, -1, -1, 51, -1, 14, -1,
+ -1, -1, 57, 58, -1, 60, -1, 62, -1, -1,
+ 65, 66, -1, 68, -1, -1, -1, -1, 40, 41,
+ 42, -1, -1, -1, 40, 41, 42, -1, -1, -1,
+ 52, -1, 54, 55, 56, -1, 52, -1, -1, 55,
+ 56
};
/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
@@ -1209,36 +1183,36 @@ static const yytype_uint8 yystos[] =
0, 75, 0, 1, 3, 4, 7, 8, 17, 18,
35, 36, 37, 38, 43, 44, 45, 46, 47, 50,
51, 57, 58, 60, 62, 65, 66, 68, 76, 78,
- 82, 84, 86, 104, 112, 116, 117, 118, 119, 120,
- 121, 129, 130, 66, 69, 126, 127, 128, 83, 122,
- 130, 130, 130, 66, 66, 68, 117, 130, 117, 117,
- 66, 119, 130, 1, 111, 112, 48, 121, 71, 73,
- 79, 88, 104, 132, 136, 79, 85, 50, 9, 14,
- 40, 41, 42, 52, 54, 55, 56, 114, 115, 11,
- 117, 57, 58, 59, 60, 61, 64, 57, 58, 59,
- 60, 61, 64, 12, 13, 43, 44, 51, 113, 110,
- 111, 112, 111, 16, 126, 3, 4, 45, 46, 68,
- 80, 81, 55, 106, 110, 110, 112, 43, 44, 131,
- 1, 54, 67, 134, 138, 134, 1, 6, 77, 104,
- 105, 87, 105, 5, 112, 129, 112, 112, 112, 105,
- 112, 38, 117, 117, 117, 117, 117, 117, 117, 117,
- 117, 117, 117, 117, 13, 112, 134, 70, 49, 66,
- 117, 134, 134, 112, 105, 40, 1, 112, 1, 88,
- 1, 19, 21, 22, 23, 26, 27, 28, 29, 30,
- 31, 32, 33, 34, 39, 72, 89, 90, 92, 99,
- 103, 112, 132, 133, 136, 53, 112, 122, 1, 4,
- 107, 108, 129, 66, 91, 4, 66, 66, 66, 105,
- 66, 88, 88, 88, 109, 112, 88, 105, 88, 93,
- 87, 135, 136, 105, 112, 134, 1, 138, 112, 109,
- 94, 4, 112, 112, 89, 4, 92, 95, 88, 66,
- 100, 110, 133, 105, 105, 1, 4, 134, 88, 123,
- 124, 125, 126, 67, 134, 134, 26, 40, 136, 111,
- 10, 101, 105, 16, 125, 105, 105, 66, 129, 105,
- 134, 102, 89, 132, 89, 112, 134, 112, 136, 116,
- 20, 96, 134, 105, 136, 105, 105, 1, 24, 25,
- 97, 105, 105, 89, 105, 95, 89, 7, 8, 57,
- 58, 84, 98, 53, 137, 133, 95, 134, 7, 7,
- 137, 105, 134, 105, 105, 87, 105, 89, 87, 89
+ 82, 83, 85, 103, 111, 115, 116, 117, 118, 119,
+ 120, 128, 129, 66, 69, 125, 126, 127, 3, 4,
+ 45, 46, 68, 80, 81, 121, 129, 129, 129, 66,
+ 66, 68, 116, 129, 116, 116, 66, 118, 129, 1,
+ 110, 111, 48, 120, 71, 73, 79, 87, 103, 131,
+ 135, 79, 84, 50, 9, 14, 40, 41, 42, 52,
+ 54, 55, 56, 113, 114, 11, 116, 57, 58, 59,
+ 60, 61, 64, 57, 58, 59, 60, 61, 64, 12,
+ 13, 43, 44, 51, 112, 109, 110, 111, 110, 16,
+ 125, 49, 66, 55, 105, 109, 109, 111, 43, 44,
+ 130, 1, 54, 67, 133, 137, 133, 1, 6, 77,
+ 103, 104, 86, 104, 5, 111, 128, 111, 111, 111,
+ 104, 111, 38, 116, 116, 116, 116, 116, 116, 116,
+ 116, 116, 116, 116, 116, 13, 111, 133, 70, 1,
+ 4, 106, 107, 116, 133, 133, 111, 104, 40, 1,
+ 111, 1, 87, 1, 19, 21, 22, 23, 26, 27,
+ 28, 29, 30, 31, 32, 33, 34, 39, 72, 88,
+ 89, 91, 98, 102, 111, 131, 132, 135, 53, 111,
+ 121, 133, 1, 137, 128, 66, 90, 4, 66, 66,
+ 66, 104, 66, 87, 87, 87, 108, 111, 87, 104,
+ 87, 92, 86, 134, 135, 104, 111, 104, 1, 4,
+ 111, 108, 93, 4, 111, 111, 88, 4, 91, 94,
+ 87, 66, 99, 109, 132, 104, 133, 87, 122, 123,
+ 124, 125, 67, 133, 133, 26, 40, 135, 110, 10,
+ 100, 104, 16, 124, 104, 104, 66, 128, 104, 133,
+ 101, 88, 131, 88, 111, 133, 111, 135, 115, 20,
+ 95, 133, 104, 135, 104, 104, 1, 24, 25, 96,
+ 104, 104, 88, 104, 94, 88, 7, 8, 57, 58,
+ 83, 97, 53, 136, 132, 94, 133, 7, 7, 136,
+ 104, 133, 104, 104, 86, 104, 88, 86, 88
};
#define yyerrok (yyerrstatus = 0)
@@ -2066,7 +2040,7 @@ yyreduce:
case 3:
/* Line 1806 of yacc.c */
-#line 221 "awkgram.y"
+#line 195 "awkgram.y"
{
rule = 0;
yyerrok;
@@ -2076,7 +2050,7 @@ yyreduce:
case 5:
/* Line 1806 of yacc.c */
-#line 227 "awkgram.y"
+#line 201 "awkgram.y"
{
next_sourcefile();
}
@@ -2085,7 +2059,7 @@ yyreduce:
case 6:
/* Line 1806 of yacc.c */
-#line 231 "awkgram.y"
+#line 205 "awkgram.y"
{
rule = 0;
/*
@@ -2099,7 +2073,7 @@ yyreduce:
case 7:
/* Line 1806 of yacc.c */
-#line 243 "awkgram.y"
+#line 217 "awkgram.y"
{
(void) append_rule((yyvsp[(1) - (2)]), (yyvsp[(2) - (2)]));
}
@@ -2108,7 +2082,7 @@ yyreduce:
case 8:
/* Line 1806 of yacc.c */
-#line 247 "awkgram.y"
+#line 221 "awkgram.y"
{
if (rule != Rule) {
msg(_("%s blocks must have an action part"), ruletab[rule]);
@@ -2124,12 +2098,10 @@ yyreduce:
case 9:
/* Line 1806 of yacc.c */
-#line 258 "awkgram.y"
+#line 232 "awkgram.y"
{
- can_return = FALSE;
- if ((yyvsp[(1) - (2)]) && func_install((yyvsp[(1) - (2)]), (yyvsp[(2) - (2)])) < 0)
- YYABORT;
- func_params = NULL;
+ in_function = NULL;
+ (void) mk_function((yyvsp[(1) - (2)]), (yyvsp[(2) - (2)]));
yyerrok;
}
break;
@@ -2137,7 +2109,7 @@ yyreduce:
case 10:
/* Line 1806 of yacc.c */
-#line 266 "awkgram.y"
+#line 238 "awkgram.y"
{
want_source = FALSE;
yyerrok;
@@ -2147,7 +2119,7 @@ yyreduce:
case 11:
/* Line 1806 of yacc.c */
-#line 274 "awkgram.y"
+#line 246 "awkgram.y"
{
if (include_source((yyvsp[(1) - (1)])) < 0)
YYABORT;
@@ -2160,35 +2132,35 @@ yyreduce:
case 12:
/* Line 1806 of yacc.c */
-#line 282 "awkgram.y"
+#line 254 "awkgram.y"
{ (yyval) = NULL; }
break;
case 13:
/* Line 1806 of yacc.c */
-#line 284 "awkgram.y"
+#line 256 "awkgram.y"
{ (yyval) = NULL; }
break;
case 14:
/* Line 1806 of yacc.c */
-#line 289 "awkgram.y"
+#line 261 "awkgram.y"
{ (yyval) = NULL; rule = Rule; }
break;
case 15:
/* Line 1806 of yacc.c */
-#line 291 "awkgram.y"
+#line 263 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); rule = Rule; }
break;
case 16:
/* Line 1806 of yacc.c */
-#line 293 "awkgram.y"
+#line 265 "awkgram.y"
{
INSTRUCTION *tp;
@@ -2196,7 +2168,7 @@ yyreduce:
add_lint((yyvsp[(4) - (4)]), LINT_assign_in_cond);
tp = instruction(Op_no_op);
- list_prepend((yyvsp[(1) - (4)]), bcalloc(Op_line_range, !!do_profiling + 1, 0));
+ list_prepend((yyvsp[(1) - (4)]), bcalloc(Op_line_range, !!do_pretty_print + 1, 0));
(yyvsp[(1) - (4)])->nexti->triggered = FALSE;
(yyvsp[(1) - (4)])->nexti->target_jmp = (yyvsp[(4) - (4)])->nexti;
@@ -2207,7 +2179,7 @@ yyreduce:
list_append((yyvsp[(4) - (4)]), instruction(Op_cond_pair));
(yyvsp[(4) - (4)])->lasti->line_range = (yyvsp[(1) - (4)])->nexti;
(yyvsp[(4) - (4)])->lasti->target_jmp = tp;
- if (do_profiling) {
+ if (do_pretty_print) {
((yyvsp[(1) - (4)])->nexti + 1)->condpair_left = (yyvsp[(1) - (4)])->lasti;
((yyvsp[(1) - (4)])->nexti + 1)->condpair_right = (yyvsp[(4) - (4)])->lasti;
}
@@ -2219,7 +2191,7 @@ yyreduce:
case 17:
/* Line 1806 of yacc.c */
-#line 319 "awkgram.y"
+#line 291 "awkgram.y"
{
static int begin_seen = 0;
if (do_lint_old && ++begin_seen == 2)
@@ -2235,7 +2207,7 @@ yyreduce:
case 18:
/* Line 1806 of yacc.c */
-#line 330 "awkgram.y"
+#line 302 "awkgram.y"
{
static int end_seen = 0;
if (do_lint_old && ++end_seen == 2)
@@ -2251,7 +2223,7 @@ yyreduce:
case 19:
/* Line 1806 of yacc.c */
-#line 341 "awkgram.y"
+#line 313 "awkgram.y"
{
(yyvsp[(1) - (1)])->in_rule = rule = BEGINFILE;
(yyvsp[(1) - (1)])->source_file = source;
@@ -2262,7 +2234,7 @@ yyreduce:
case 20:
/* Line 1806 of yacc.c */
-#line 347 "awkgram.y"
+#line 319 "awkgram.y"
{
(yyvsp[(1) - (1)])->in_rule = rule = ENDFILE;
(yyvsp[(1) - (1)])->source_file = source;
@@ -2273,7 +2245,7 @@ yyreduce:
case 21:
/* Line 1806 of yacc.c */
-#line 356 "awkgram.y"
+#line 328 "awkgram.y"
{
if ((yyvsp[(2) - (5)]) == NULL)
(yyval) = list_create(instruction(Op_no_op));
@@ -2285,89 +2257,69 @@ yyreduce:
case 22:
/* Line 1806 of yacc.c */
-#line 366 "awkgram.y"
+#line 338 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 23:
/* Line 1806 of yacc.c */
-#line 368 "awkgram.y"
+#line 340 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 24:
/* Line 1806 of yacc.c */
-#line 370 "awkgram.y"
+#line 342 "awkgram.y"
{
yyerror(_("`%s' is a built-in function, it cannot be redefined"),
- tokstart);
- (yyvsp[(1) - (1)])->opcode = Op_symbol; /* Op_symbol instead of Op_token so that
- * free_bc_internal does not try to free it
- */
- (yyvsp[(1) - (1)])->lextok = builtin_func;
- (yyval) = (yyvsp[(1) - (1)]);
- /* yyerrok; */
+ tokstart);
+ YYABORT;
}
break;
case 25:
/* Line 1806 of yacc.c */
-#line 381 "awkgram.y"
+#line 348 "awkgram.y"
{ (yyval) = (yyvsp[(2) - (2)]); }
break;
case 28:
/* Line 1806 of yacc.c */
-#line 391 "awkgram.y"
+#line 358 "awkgram.y"
{
- param_counter = 0;
- func_params = NULL;
+ (yyvsp[(1) - (6)])->source_file = source;
+ if (install_function((yyvsp[(2) - (6)])->lextok, (yyvsp[(1) - (6)]), (yyvsp[(4) - (6)])) < 0)
+ YYABORT;
+ in_function = (yyvsp[(2) - (6)])->lextok;
+ (yyvsp[(2) - (6)])->lextok = NULL;
+ bcfree((yyvsp[(2) - (6)]));
+ /* $4 already free'd in install_function */
+ (yyval) = (yyvsp[(1) - (6)]);
}
break;
case 29:
/* Line 1806 of yacc.c */
-#line 396 "awkgram.y"
- {
- NODE *t;
-
- (yyvsp[(1) - (7)])->source_file = source;
- t = make_param((yyvsp[(3) - (7)])->lextok);
- (yyvsp[(3) - (7)])->lextok = NULL;
- bcfree((yyvsp[(3) - (7)]));
- t->flags |= FUNC;
- t->rnode = func_params;
- func_params = t;
- (yyval) = (yyvsp[(1) - (7)]);
- can_return = TRUE;
- /* check for duplicate parameter names */
- if (dup_parms((yyvsp[(1) - (7)]), t))
- errcount++;
- }
- break;
-
- case 30:
-
-/* Line 1806 of yacc.c */
-#line 420 "awkgram.y"
+#line 376 "awkgram.y"
{ ++want_regexp; }
break;
- case 31:
+ case 30:
/* Line 1806 of yacc.c */
-#line 422 "awkgram.y"
+#line 378 "awkgram.y"
{
NODE *n, *exp;
char *re;
size_t len;
re = (yyvsp[(3) - (3)])->lextok;
+ (yyvsp[(3) - (3)])->lextok = NULL;
len = strlen(re);
if (do_lint) {
if (len == 0)
@@ -2391,24 +2343,24 @@ yyreduce:
}
break;
- case 32:
+ case 31:
/* Line 1806 of yacc.c */
-#line 453 "awkgram.y"
+#line 410 "awkgram.y"
{ bcfree((yyvsp[(1) - (1)])); }
break;
- case 34:
+ case 33:
/* Line 1806 of yacc.c */
-#line 459 "awkgram.y"
+#line 416 "awkgram.y"
{ (yyval) = NULL; }
break;
- case 35:
+ case 34:
/* Line 1806 of yacc.c */
-#line 461 "awkgram.y"
+#line 418 "awkgram.y"
{
if ((yyvsp[(2) - (2)]) == NULL)
(yyval) = (yyvsp[(1) - (2)]);
@@ -2423,43 +2375,43 @@ yyreduce:
}
break;
- case 36:
+ case 35:
/* Line 1806 of yacc.c */
-#line 474 "awkgram.y"
+#line 431 "awkgram.y"
{ (yyval) = NULL; }
break;
- case 39:
+ case 38:
/* Line 1806 of yacc.c */
-#line 484 "awkgram.y"
+#line 441 "awkgram.y"
{ (yyval) = NULL; }
break;
- case 40:
+ case 39:
/* Line 1806 of yacc.c */
-#line 486 "awkgram.y"
+#line 443 "awkgram.y"
{ (yyval) = (yyvsp[(2) - (3)]); }
break;
- case 41:
+ case 40:
/* Line 1806 of yacc.c */
-#line 488 "awkgram.y"
+#line 445 "awkgram.y"
{
- if (do_profiling)
+ if (do_pretty_print)
(yyval) = list_prepend((yyvsp[(1) - (1)]), instruction(Op_exec_count));
else
(yyval) = (yyvsp[(1) - (1)]);
}
break;
- case 42:
+ case 41:
/* Line 1806 of yacc.c */
-#line 495 "awkgram.y"
+#line 452 "awkgram.y"
{
INSTRUCTION *dflt, *curr = NULL, *cexp, *cstmt;
INSTRUCTION *ip, *nextc, *tbreak;
@@ -2518,7 +2470,7 @@ yyreduce:
else
dflt->target_jmp = casestmt->nexti;
- if (do_profiling) {
+ if (do_pretty_print) {
curr->stmt_start = casestmt->nexti;
curr->stmt_end = casestmt->lasti;
(void) list_prepend(cexp, curr);
@@ -2533,7 +2485,7 @@ yyreduce:
efree(case_values);
ip = (yyvsp[(3) - (9)]);
- if (do_profiling) {
+ if (do_pretty_print) {
(void) list_prepend(ip, (yyvsp[(1) - (9)]));
(void) list_prepend(ip, instruction(Op_exec_count));
(yyvsp[(1) - (9)])->target_break = tbreak;
@@ -2551,10 +2503,10 @@ yyreduce:
}
break;
- case 43:
+ case 42:
/* Line 1806 of yacc.c */
-#line 585 "awkgram.y"
+#line 542 "awkgram.y"
{
/*
* -----------------
@@ -2577,7 +2529,7 @@ yyreduce:
ip = list_append((yyvsp[(3) - (6)]), instruction(Op_jmp_false));
ip->lasti->target_jmp = tbreak;
- if (do_profiling) {
+ if (do_pretty_print) {
(void) list_append(ip, instruction(Op_exec_count));
(yyvsp[(1) - (6)])->target_break = tbreak;
(yyvsp[(1) - (6)])->target_continue = tcont;
@@ -2598,10 +2550,10 @@ yyreduce:
}
break;
- case 44:
+ case 43:
/* Line 1806 of yacc.c */
-#line 627 "awkgram.y"
+#line 584 "awkgram.y"
{
/*
* -----------------
@@ -2624,7 +2576,7 @@ yyreduce:
ip = list_merge((yyvsp[(3) - (8)]), (yyvsp[(6) - (8)]));
else
ip = list_prepend((yyvsp[(6) - (8)]), instruction(Op_no_op));
- if (do_profiling)
+ if (do_pretty_print)
(void) list_prepend(ip, instruction(Op_exec_count));
(void) list_append(ip, instruction(Op_jmp_true));
ip->lasti->target_jmp = ip->nexti;
@@ -2634,7 +2586,7 @@ yyreduce:
continue_allowed--;
fix_break_continue(ip, tbreak, tcont);
- if (do_profiling) {
+ if (do_pretty_print) {
(yyvsp[(1) - (8)])->target_break = tbreak;
(yyvsp[(1) - (8)])->target_continue = tcont;
((yyvsp[(1) - (8)]) + 1)->doloop_cond = tcont;
@@ -2645,10 +2597,10 @@ yyreduce:
}
break;
- case 45:
+ case 44:
/* Line 1806 of yacc.c */
-#line 669 "awkgram.y"
+#line 626 "awkgram.y"
{
INSTRUCTION *ip;
char *var_name = (yyvsp[(3) - (8)])->lextok;
@@ -2699,30 +2651,30 @@ yyreduce:
} else {
INSTRUCTION *tbreak, *tcont;
- /* [ Op_push_array a ]
- * [ Op_arrayfor_init | ib ]
- * ic:[ Op_arrayfor_incr | ib ]
- * [ Op_var_assign if any ]
- *
- * body
- *
- * [Op_jmp | ic ]
- * ib:[Op_arrayfor_final ]
- */
+ /* [ Op_push_array a ]
+ * [ Op_arrayfor_init | ib ]
+ * ic:[ Op_arrayfor_incr | ib ]
+ * [ Op_var_assign if any ]
+ *
+ * body
+ *
+ * [Op_jmp | ic ]
+ * ib:[Op_arrayfor_final ]
+ */
regular_loop:
ip = (yyvsp[(5) - (8)]);
ip->nexti->opcode = Op_push_array;
tbreak = instruction(Op_arrayfor_final);
(yyvsp[(4) - (8)])->opcode = Op_arrayfor_incr;
- (yyvsp[(4) - (8)])->array_var = variable(var_name, Node_var);
+ (yyvsp[(4) - (8)])->array_var = variable((yyvsp[(3) - (8)])->source_line, var_name, Node_var);
(yyvsp[(4) - (8)])->target_jmp = tbreak;
tcont = (yyvsp[(4) - (8)]);
(yyvsp[(3) - (8)])->opcode = Op_arrayfor_init;
(yyvsp[(3) - (8)])->target_jmp = tbreak;
(void) list_append(ip, (yyvsp[(3) - (8)]));
- if (do_profiling) {
+ if (do_pretty_print) {
(yyvsp[(1) - (8)])->opcode = Op_K_arrayfor;
(yyvsp[(1) - (8)])->target_continue = tcont;
(yyvsp[(1) - (8)])->target_break = tbreak;
@@ -2743,7 +2695,7 @@ regular_loop:
ip->lasti->assign_var = (yyvsp[(4) - (8)])->array_var->var_assign;
}
- if (do_profiling) {
+ if (do_pretty_print) {
(void) list_append(ip, instruction(Op_exec_count));
((yyvsp[(1) - (8)]) + 1)->forloop_cond = (yyvsp[(4) - (8)]);
((yyvsp[(1) - (8)]) + 1)->forloop_body = ip->lasti;
@@ -2763,10 +2715,10 @@ regular_loop:
}
break;
- case 46:
+ case 45:
/* Line 1806 of yacc.c */
-#line 782 "awkgram.y"
+#line 739 "awkgram.y"
{
(yyval) = mk_for_loop((yyvsp[(1) - (12)]), (yyvsp[(3) - (12)]), (yyvsp[(6) - (12)]), (yyvsp[(9) - (12)]), (yyvsp[(12) - (12)]));
@@ -2775,10 +2727,10 @@ regular_loop:
}
break;
- case 47:
+ case 46:
/* Line 1806 of yacc.c */
-#line 789 "awkgram.y"
+#line 746 "awkgram.y"
{
(yyval) = mk_for_loop((yyvsp[(1) - (11)]), (yyvsp[(3) - (11)]), (INSTRUCTION *) NULL, (yyvsp[(8) - (11)]), (yyvsp[(11) - (11)]));
@@ -2787,22 +2739,22 @@ regular_loop:
}
break;
- case 48:
+ case 47:
/* Line 1806 of yacc.c */
-#line 796 "awkgram.y"
+#line 753 "awkgram.y"
{
- if (do_profiling)
+ if (do_pretty_print)
(yyval) = list_prepend((yyvsp[(1) - (1)]), instruction(Op_exec_count));
else
(yyval) = (yyvsp[(1) - (1)]);
}
break;
- case 49:
+ case 48:
/* Line 1806 of yacc.c */
-#line 806 "awkgram.y"
+#line 763 "awkgram.y"
{
if (! break_allowed)
error_ln((yyvsp[(1) - (2)])->source_line,
@@ -2813,10 +2765,10 @@ regular_loop:
}
break;
- case 50:
+ case 49:
/* Line 1806 of yacc.c */
-#line 815 "awkgram.y"
+#line 772 "awkgram.y"
{
if (! continue_allowed)
error_ln((yyvsp[(1) - (2)])->source_line,
@@ -2827,10 +2779,10 @@ regular_loop:
}
break;
- case 51:
+ case 50:
/* Line 1806 of yacc.c */
-#line 824 "awkgram.y"
+#line 781 "awkgram.y"
{
/* if inside function (rule = 0), resolve context at run-time */
if (rule && rule != Rule)
@@ -2841,10 +2793,10 @@ regular_loop:
}
break;
- case 52:
+ case 51:
/* Line 1806 of yacc.c */
-#line 833 "awkgram.y"
+#line 790 "awkgram.y"
{
if (do_traditional)
error_ln((yyvsp[(1) - (2)])->source_line,
@@ -2861,10 +2813,10 @@ regular_loop:
}
break;
- case 53:
+ case 52:
/* Line 1806 of yacc.c */
-#line 848 "awkgram.y"
+#line 805 "awkgram.y"
{
/* Initialize the two possible jump targets, the actual target
* is resolved at run-time.
@@ -2875,47 +2827,59 @@ regular_loop:
if ((yyvsp[(2) - (3)]) == NULL) {
(yyval) = list_create((yyvsp[(1) - (3)]));
(void) list_prepend((yyval), instruction(Op_push_i));
- (yyval)->nexti->memory = Nnull_string;
+ (yyval)->nexti->memory = dupnode(Nnull_string);
} else
(yyval) = list_append((yyvsp[(2) - (3)]), (yyvsp[(1) - (3)]));
}
break;
- case 54:
+ case 53:
/* Line 1806 of yacc.c */
-#line 863 "awkgram.y"
+#line 820 "awkgram.y"
{
- if (! can_return)
+ if (! in_function)
yyerror(_("`return' used outside function context"));
}
break;
- case 55:
+ case 54:
/* Line 1806 of yacc.c */
-#line 866 "awkgram.y"
+#line 823 "awkgram.y"
{
if ((yyvsp[(3) - (4)]) == NULL) {
(yyval) = list_create((yyvsp[(1) - (4)]));
(void) list_prepend((yyval), instruction(Op_push_i));
- (yyval)->nexti->memory = Nnull_string;
- } else
+ (yyval)->nexti->memory = dupnode(Nnull_string);
+ } else {
+ if (do_optimize > 1
+ && (yyvsp[(3) - (4)])->lasti->opcode == Op_func_call
+ && strcmp((yyvsp[(3) - (4)])->lasti->func_name, in_function) == 0
+ ) {
+ /* Do tail recursion optimization. Tail
+ * call without a return value is recognized
+ * in mk_function().
+ */
+ ((yyvsp[(3) - (4)])->lasti + 1)->tail_call = TRUE;
+ }
+
(yyval) = list_append((yyvsp[(3) - (4)]), (yyvsp[(1) - (4)]));
+ }
}
break;
- case 57:
+ case 56:
/* Line 1806 of yacc.c */
-#line 886 "awkgram.y"
+#line 855 "awkgram.y"
{ in_print = TRUE; in_parens = 0; }
break;
- case 58:
+ case 57:
/* Line 1806 of yacc.c */
-#line 887 "awkgram.y"
+#line 856 "awkgram.y"
{
/*
* Optimization: plain `print' has no expression list, so $3 is null.
@@ -2924,13 +2888,12 @@ regular_loop:
*/
if ((yyvsp[(1) - (4)])->opcode == Op_K_print &&
- ((yyvsp[(3) - (4)]) == NULL
- || ((yyvsp[(3) - (4)])->lasti->opcode == Op_field_spec
- && (yyvsp[(3) - (4)])->nexti->nexti->nexti == (yyvsp[(3) - (4)])->lasti
- && (yyvsp[(3) - (4)])->nexti->nexti->opcode == Op_push_i
- && (yyvsp[(3) - (4)])->nexti->nexti->memory->type == Node_val
- && (yyvsp[(3) - (4)])->nexti->nexti->memory->numbr == 0.0)
- )
+ ((yyvsp[(3) - (4)]) == NULL
+ || ((yyvsp[(3) - (4)])->lasti->opcode == Op_field_spec
+ && (yyvsp[(3) - (4)])->nexti->nexti->nexti == (yyvsp[(3) - (4)])->lasti
+ && (yyvsp[(3) - (4)])->nexti->nexti->opcode == Op_push_i
+ && (yyvsp[(3) - (4)])->nexti->nexti->memory->type == Node_val)
+ )
) {
static short warned = FALSE;
/* -----------------
@@ -2943,13 +2906,16 @@ regular_loop:
*/
if ((yyvsp[(3) - (4)]) != NULL) {
- bcfree((yyvsp[(3) - (4)])->lasti); /* Op_field_spec */
- (yyvsp[(3) - (4)])->nexti->nexti->memory->flags &= ~PERM;
- (yyvsp[(3) - (4)])->nexti->nexti->memory->flags |= MALLOC;
- unref((yyvsp[(3) - (4)])->nexti->nexti->memory); /* Node_val */
+ NODE *n = (yyvsp[(3) - (4)])->nexti->nexti->memory;
+
+ if (! iszero(n))
+ goto regular_print;
+
+ bcfree((yyvsp[(3) - (4)])->lasti); /* Op_field_spec */
+ unref(n); /* Node_val */
bcfree((yyvsp[(3) - (4)])->nexti->nexti); /* Op_push_i */
- bcfree((yyvsp[(3) - (4)])->nexti); /* Op_list */
- bcfree((yyvsp[(3) - (4)])); /* Op_list */
+ bcfree((yyvsp[(3) - (4)])->nexti); /* Op_list */
+ bcfree((yyvsp[(3) - (4)])); /* Op_list */
} else {
if (do_lint && (rule == BEGIN || rule == END) && ! warned) {
warned = TRUE;
@@ -2961,7 +2927,7 @@ regular_loop:
(yyvsp[(1) - (4)])->expr_count = 0;
(yyvsp[(1) - (4)])->opcode = Op_K_print_rec;
if ((yyvsp[(4) - (4)]) == NULL) { /* no redircetion */
- (yyvsp[(1) - (4)])->redir_type = 0;
+ (yyvsp[(1) - (4)])->redir_type = redirect_none;
(yyval) = list_create((yyvsp[(1) - (4)]));
} else {
INSTRUCTION *ip;
@@ -2981,16 +2947,16 @@ regular_loop:
* [$1 | NULL | redir_type | expr_count]
*
*/
-
+regular_print:
if ((yyvsp[(4) - (4)]) == NULL) { /* no redirection */
if ((yyvsp[(3) - (4)]) == NULL) { /* printf without arg */
(yyvsp[(1) - (4)])->expr_count = 0;
- (yyvsp[(1) - (4)])->redir_type = 0;
+ (yyvsp[(1) - (4)])->redir_type = redirect_none;
(yyval) = list_create((yyvsp[(1) - (4)]));
} else {
INSTRUCTION *t = (yyvsp[(3) - (4)]);
(yyvsp[(1) - (4)])->expr_count = count_expressions(&t, FALSE);
- (yyvsp[(1) - (4)])->redir_type = 0;
+ (yyvsp[(1) - (4)])->redir_type = redirect_none;
(yyval) = list_append(t, (yyvsp[(1) - (4)]));
}
} else {
@@ -3012,22 +2978,22 @@ regular_loop:
}
break;
- case 59:
+ case 58:
/* Line 1806 of yacc.c */
-#line 982 "awkgram.y"
+#line 953 "awkgram.y"
{ sub_counter = 0; }
break;
- case 60:
+ case 59:
/* Line 1806 of yacc.c */
-#line 983 "awkgram.y"
+#line 954 "awkgram.y"
{
char *arr = (yyvsp[(2) - (4)])->lextok;
(yyvsp[(2) - (4)])->opcode = Op_push_array;
- (yyvsp[(2) - (4)])->memory = variable(arr, Node_var_new);
+ (yyvsp[(2) - (4)])->memory = variable((yyvsp[(2) - (4)])->source_line, arr, Node_var_new);
if ((yyvsp[(4) - (4)]) == NULL) {
static short warned = FALSE;
@@ -3049,10 +3015,10 @@ regular_loop:
}
break;
- case 61:
+ case 60:
/* Line 1806 of yacc.c */
-#line 1012 "awkgram.y"
+#line 983 "awkgram.y"
{
static short warned = FALSE;
char *arr = (yyvsp[(3) - (4)])->lextok;
@@ -3066,45 +3032,45 @@ regular_loop:
error_ln((yyvsp[(1) - (4)])->source_line,
_("`delete array' is a gawk extension"));
}
- (yyvsp[(3) - (4)])->memory = variable(arr, Node_var_new);
+ (yyvsp[(3) - (4)])->memory = variable((yyvsp[(3) - (4)])->source_line, arr, Node_var_new);
(yyvsp[(3) - (4)])->opcode = Op_push_array;
(yyvsp[(1) - (4)])->expr_count = 0;
(yyval) = list_append(list_create((yyvsp[(3) - (4)])), (yyvsp[(1) - (4)]));
}
break;
- case 62:
+ case 61:
/* Line 1806 of yacc.c */
-#line 1031 "awkgram.y"
+#line 1002 "awkgram.y"
{ (yyval) = optimize_assignment((yyvsp[(1) - (1)])); }
break;
- case 63:
+ case 62:
/* Line 1806 of yacc.c */
-#line 1036 "awkgram.y"
+#line 1007 "awkgram.y"
{ (yyval) = NULL; }
break;
- case 64:
+ case 63:
/* Line 1806 of yacc.c */
-#line 1038 "awkgram.y"
+#line 1009 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
- case 65:
+ case 64:
/* Line 1806 of yacc.c */
-#line 1043 "awkgram.y"
+#line 1014 "awkgram.y"
{ (yyval) = NULL; }
break;
- case 66:
+ case 65:
/* Line 1806 of yacc.c */
-#line 1045 "awkgram.y"
+#line 1016 "awkgram.y"
{
if ((yyvsp[(1) - (2)]) == NULL)
(yyval) = list_create((yyvsp[(2) - (2)]));
@@ -3113,22 +3079,22 @@ regular_loop:
}
break;
- case 67:
+ case 66:
/* Line 1806 of yacc.c */
-#line 1052 "awkgram.y"
+#line 1023 "awkgram.y"
{ (yyval) = NULL; }
break;
- case 68:
+ case 67:
/* Line 1806 of yacc.c */
-#line 1057 "awkgram.y"
+#line 1028 "awkgram.y"
{
INSTRUCTION *casestmt = (yyvsp[(5) - (5)]);
if ((yyvsp[(5) - (5)]) == NULL)
casestmt = list_create(instruction(Op_no_op));
- if (do_profiling)
+ if (do_pretty_print)
(void) list_prepend(casestmt, instruction(Op_exec_count));
(yyvsp[(1) - (5)])->case_exp = (yyvsp[(2) - (5)]);
(yyvsp[(1) - (5)])->case_stmt = casestmt;
@@ -3137,15 +3103,15 @@ regular_loop:
}
break;
- case 69:
+ case 68:
/* Line 1806 of yacc.c */
-#line 1069 "awkgram.y"
+#line 1040 "awkgram.y"
{
INSTRUCTION *casestmt = (yyvsp[(4) - (4)]);
if ((yyvsp[(4) - (4)]) == NULL)
casestmt = list_create(instruction(Op_no_op));
- if (do_profiling)
+ if (do_pretty_print)
(void) list_prepend(casestmt, instruction(Op_exec_count));
bcfree((yyvsp[(2) - (4)]));
(yyvsp[(1) - (4)])->case_stmt = casestmt;
@@ -3153,78 +3119,80 @@ regular_loop:
}
break;
- case 70:
+ case 69:
/* Line 1806 of yacc.c */
-#line 1083 "awkgram.y"
+#line 1054 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
- case 71:
+ case 70:
/* Line 1806 of yacc.c */
-#line 1085 "awkgram.y"
+#line 1056 "awkgram.y"
{
- (yyvsp[(2) - (2)])->memory->numbr = -(force_number((yyvsp[(2) - (2)])->memory));
+ NODE *n = (yyvsp[(2) - (2)])->memory;
+ (void) force_number(n);
+ negate_num(n);
bcfree((yyvsp[(1) - (2)]));
(yyval) = (yyvsp[(2) - (2)]);
}
break;
- case 72:
+ case 71:
/* Line 1806 of yacc.c */
-#line 1091 "awkgram.y"
+#line 1064 "awkgram.y"
{
bcfree((yyvsp[(1) - (2)]));
(yyval) = (yyvsp[(2) - (2)]);
}
break;
- case 73:
+ case 72:
/* Line 1806 of yacc.c */
-#line 1096 "awkgram.y"
+#line 1069 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
- case 74:
+ case 73:
/* Line 1806 of yacc.c */
-#line 1098 "awkgram.y"
+#line 1071 "awkgram.y"
{
(yyvsp[(1) - (1)])->opcode = Op_push_re;
(yyval) = (yyvsp[(1) - (1)]);
}
break;
- case 75:
+ case 74:
/* Line 1806 of yacc.c */
-#line 1106 "awkgram.y"
+#line 1079 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
- case 76:
+ case 75:
/* Line 1806 of yacc.c */
-#line 1108 "awkgram.y"
+#line 1081 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
- case 78:
+ case 77:
/* Line 1806 of yacc.c */
-#line 1118 "awkgram.y"
+#line 1091 "awkgram.y"
{
(yyval) = (yyvsp[(2) - (3)]);
}
break;
- case 79:
+ case 78:
/* Line 1806 of yacc.c */
-#line 1125 "awkgram.y"
+#line 1098 "awkgram.y"
{
in_print = FALSE;
in_parens = 0;
@@ -3232,17 +3200,17 @@ regular_loop:
}
break;
- case 80:
+ case 79:
/* Line 1806 of yacc.c */
-#line 1130 "awkgram.y"
+#line 1103 "awkgram.y"
{ in_print = FALSE; in_parens = 0; }
break;
- case 81:
+ case 80:
/* Line 1806 of yacc.c */
-#line 1131 "awkgram.y"
+#line 1104 "awkgram.y"
{
if ((yyvsp[(1) - (3)])->redir_type == redirect_twoway
&& (yyvsp[(3) - (3)])->lasti->opcode == Op_K_getline_redir
@@ -3252,162 +3220,174 @@ regular_loop:
}
break;
- case 82:
+ case 81:
/* Line 1806 of yacc.c */
-#line 1142 "awkgram.y"
+#line 1115 "awkgram.y"
{
(yyval) = mk_condition((yyvsp[(3) - (6)]), (yyvsp[(1) - (6)]), (yyvsp[(6) - (6)]), NULL, NULL);
}
break;
- case 83:
+ case 82:
/* Line 1806 of yacc.c */
-#line 1147 "awkgram.y"
+#line 1120 "awkgram.y"
{
(yyval) = mk_condition((yyvsp[(3) - (9)]), (yyvsp[(1) - (9)]), (yyvsp[(6) - (9)]), (yyvsp[(7) - (9)]), (yyvsp[(9) - (9)]));
}
break;
- case 88:
+ case 87:
/* Line 1806 of yacc.c */
-#line 1164 "awkgram.y"
+#line 1137 "awkgram.y"
{ (yyval) = NULL; }
break;
- case 89:
+ case 88:
/* Line 1806 of yacc.c */
-#line 1166 "awkgram.y"
+#line 1139 "awkgram.y"
{
bcfree((yyvsp[(1) - (2)]));
(yyval) = (yyvsp[(2) - (2)]);
}
break;
- case 92:
+ case 89:
/* Line 1806 of yacc.c */
-#line 1179 "awkgram.y"
+#line 1147 "awkgram.y"
+ { (yyval) = NULL; }
+ break;
+
+ case 90:
+
+/* Line 1806 of yacc.c */
+#line 1149 "awkgram.y"
+ { (yyval) = (yyvsp[(1) - (1)]) ; }
+ break;
+
+ case 91:
+
+/* Line 1806 of yacc.c */
+#line 1154 "awkgram.y"
{
- append_param((yyvsp[(1) - (1)])->lextok);
- (yyvsp[(1) - (1)])->lextok = NULL;
- bcfree((yyvsp[(1) - (1)]));
+ (yyvsp[(1) - (1)])->param_count = 0;
+ (yyval) = list_create((yyvsp[(1) - (1)]));
}
break;
- case 93:
+ case 92:
/* Line 1806 of yacc.c */
-#line 1185 "awkgram.y"
+#line 1159 "awkgram.y"
{
- append_param((yyvsp[(3) - (3)])->lextok);
- (yyvsp[(3) - (3)])->lextok = NULL;
- bcfree((yyvsp[(3) - (3)]));
+ (yyvsp[(3) - (3)])->param_count = (yyvsp[(1) - (3)])->lasti->param_count + 1;
+ (yyval) = list_append((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]));
yyerrok;
}
break;
- case 94:
+ case 93:
/* Line 1806 of yacc.c */
-#line 1192 "awkgram.y"
- { /* func_params = NULL; */ }
+#line 1165 "awkgram.y"
+ { (yyval) = NULL; }
break;
- case 95:
+ case 94:
/* Line 1806 of yacc.c */
-#line 1194 "awkgram.y"
- { /* func_params = NULL; */ }
+#line 1167 "awkgram.y"
+ { (yyval) = (yyvsp[(1) - (2)]); }
break;
- case 96:
+ case 95:
/* Line 1806 of yacc.c */
-#line 1196 "awkgram.y"
- { /* func_params = NULL; */ }
+#line 1169 "awkgram.y"
+ { (yyval) = (yyvsp[(1) - (3)]); }
break;
- case 97:
+ case 96:
/* Line 1806 of yacc.c */
-#line 1202 "awkgram.y"
+#line 1175 "awkgram.y"
{ (yyval) = NULL; }
break;
- case 98:
+ case 97:
/* Line 1806 of yacc.c */
-#line 1204 "awkgram.y"
+#line 1177 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
- case 99:
+ case 98:
/* Line 1806 of yacc.c */
-#line 1209 "awkgram.y"
+#line 1182 "awkgram.y"
{ (yyval) = NULL; }
break;
- case 100:
+ case 99:
/* Line 1806 of yacc.c */
-#line 1211 "awkgram.y"
+#line 1184 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
- case 101:
+ case 100:
/* Line 1806 of yacc.c */
-#line 1216 "awkgram.y"
+#line 1189 "awkgram.y"
{ (yyval) = mk_expression_list(NULL, (yyvsp[(1) - (1)])); }
break;
- case 102:
+ case 101:
/* Line 1806 of yacc.c */
-#line 1218 "awkgram.y"
+#line 1191 "awkgram.y"
{
(yyval) = mk_expression_list((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]));
yyerrok;
}
break;
- case 103:
+ case 102:
/* Line 1806 of yacc.c */
-#line 1223 "awkgram.y"
+#line 1196 "awkgram.y"
{ (yyval) = NULL; }
break;
- case 104:
+ case 103:
/* Line 1806 of yacc.c */
-#line 1225 "awkgram.y"
+#line 1198 "awkgram.y"
{ (yyval) = NULL; }
break;
- case 105:
+ case 104:
/* Line 1806 of yacc.c */
-#line 1227 "awkgram.y"
+#line 1200 "awkgram.y"
{ (yyval) = NULL; }
break;
- case 106:
+ case 105:
/* Line 1806 of yacc.c */
-#line 1229 "awkgram.y"
+#line 1202 "awkgram.y"
{ (yyval) = NULL; }
break;
- case 107:
+ case 106:
/* Line 1806 of yacc.c */
-#line 1235 "awkgram.y"
+#line 1208 "awkgram.y"
{
if (do_lint && (yyvsp[(3) - (3)])->lasti->opcode == Op_match_rec)
lintwarn_ln((yyvsp[(2) - (3)])->source_line,
@@ -3416,24 +3396,24 @@ regular_loop:
}
break;
- case 108:
+ case 107:
/* Line 1806 of yacc.c */
-#line 1242 "awkgram.y"
+#line 1215 "awkgram.y"
{ (yyval) = mk_boolean((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
- case 109:
+ case 108:
/* Line 1806 of yacc.c */
-#line 1244 "awkgram.y"
+#line 1217 "awkgram.y"
{ (yyval) = mk_boolean((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
- case 110:
+ case 109:
/* Line 1806 of yacc.c */
-#line 1246 "awkgram.y"
+#line 1219 "awkgram.y"
{
if ((yyvsp[(1) - (3)])->lasti->opcode == Op_match_rec)
warning_ln((yyvsp[(2) - (3)])->source_line,
@@ -3451,13 +3431,13 @@ regular_loop:
}
break;
- case 111:
+ case 110:
/* Line 1806 of yacc.c */
-#line 1262 "awkgram.y"
+#line 1235 "awkgram.y"
{
if (do_lint_old)
- warning_ln((yyvsp[(2) - (3)])->source_line,
+ warning_ln((yyvsp[(2) - (3)])->source_line,
_("old awk does not support the keyword `in' except after `for'"));
(yyvsp[(3) - (3)])->nexti->opcode = Op_push_array;
(yyvsp[(2) - (3)])->opcode = Op_in_array;
@@ -3466,10 +3446,10 @@ regular_loop:
}
break;
- case 112:
+ case 111:
/* Line 1806 of yacc.c */
-#line 1272 "awkgram.y"
+#line 1245 "awkgram.y"
{
if (do_lint && (yyvsp[(3) - (3)])->lasti->opcode == Op_match_rec)
lintwarn_ln((yyvsp[(2) - (3)])->source_line,
@@ -3478,90 +3458,90 @@ regular_loop:
}
break;
- case 113:
+ case 112:
/* Line 1806 of yacc.c */
-#line 1279 "awkgram.y"
+#line 1252 "awkgram.y"
{ (yyval) = mk_condition((yyvsp[(1) - (5)]), (yyvsp[(2) - (5)]), (yyvsp[(3) - (5)]), (yyvsp[(4) - (5)]), (yyvsp[(5) - (5)])); }
break;
- case 114:
+ case 113:
/* Line 1806 of yacc.c */
-#line 1281 "awkgram.y"
+#line 1254 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
- case 115:
+ case 114:
/* Line 1806 of yacc.c */
-#line 1286 "awkgram.y"
+#line 1259 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
- case 116:
+ case 115:
/* Line 1806 of yacc.c */
-#line 1288 "awkgram.y"
+#line 1261 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
- case 117:
+ case 116:
/* Line 1806 of yacc.c */
-#line 1290 "awkgram.y"
+#line 1263 "awkgram.y"
{
(yyvsp[(2) - (2)])->opcode = Op_assign_quotient;
(yyval) = (yyvsp[(2) - (2)]);
}
break;
+ case 117:
+
+/* Line 1806 of yacc.c */
+#line 1271 "awkgram.y"
+ { (yyval) = (yyvsp[(1) - (1)]); }
+ break;
+
case 118:
/* Line 1806 of yacc.c */
-#line 1298 "awkgram.y"
+#line 1273 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 119:
/* Line 1806 of yacc.c */
-#line 1300 "awkgram.y"
+#line 1278 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 120:
/* Line 1806 of yacc.c */
-#line 1305 "awkgram.y"
+#line 1280 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 121:
/* Line 1806 of yacc.c */
-#line 1307 "awkgram.y"
+#line 1285 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 122:
/* Line 1806 of yacc.c */
-#line 1312 "awkgram.y"
+#line 1287 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
case 123:
/* Line 1806 of yacc.c */
-#line 1314 "awkgram.y"
- { (yyval) = (yyvsp[(1) - (1)]); }
- break;
-
- case 124:
-
-/* Line 1806 of yacc.c */
-#line 1316 "awkgram.y"
+#line 1289 "awkgram.y"
{
int count = 2;
int is_simple_var = FALSE;
@@ -3573,32 +3553,29 @@ regular_loop:
(yyvsp[(1) - (2)])->lasti->opcode = Op_no_op;
} else {
is_simple_var = ((yyvsp[(1) - (2)])->nexti->opcode == Op_push
- && (yyvsp[(1) - (2)])->lasti == (yyvsp[(1) - (2)])->nexti); /* first exp. is a simple
- * variable?; kludge for use
- * in Op_assign_concat.
- */
+ && (yyvsp[(1) - (2)])->lasti == (yyvsp[(1) - (2)])->nexti); /* first exp. is a simple
+ * variable?; kludge for use
+ * in Op_assign_concat.
+ */
}
if (do_optimize > 1
- && (yyvsp[(1) - (2)])->nexti == (yyvsp[(1) - (2)])->lasti && (yyvsp[(1) - (2)])->nexti->opcode == Op_push_i
- && (yyvsp[(2) - (2)])->nexti == (yyvsp[(2) - (2)])->lasti && (yyvsp[(2) - (2)])->nexti->opcode == Op_push_i
+ && (yyvsp[(1) - (2)])->nexti == (yyvsp[(1) - (2)])->lasti && (yyvsp[(1) - (2)])->nexti->opcode == Op_push_i
+ && (yyvsp[(2) - (2)])->nexti == (yyvsp[(2) - (2)])->lasti && (yyvsp[(2) - (2)])->nexti->opcode == Op_push_i
) {
NODE *n1 = (yyvsp[(1) - (2)])->nexti->memory;
NODE *n2 = (yyvsp[(2) - (2)])->nexti->memory;
size_t nlen;
- (void) force_string(n1);
- (void) force_string(n2);
+ n1 = force_string(n1);
+ n2 = force_string(n2);
nlen = n1->stlen + n2->stlen;
erealloc(n1->stptr, char *, nlen + 2, "constant fold");
memcpy(n1->stptr + n1->stlen, n2->stptr, n2->stlen);
n1->stlen = nlen;
n1->stptr[nlen] = '\0';
- n1->flags &= ~(NUMCUR|NUMBER);
+ n1->flags &= ~(NUMCUR|NUMBER|NUMINT);
n1->flags |= (STRING|STRCUR);
-
- n2->flags &= ~PERM;
- n2->flags |= MALLOC;
unref(n2);
bcfree((yyvsp[(2) - (2)])->nexti);
bcfree((yyvsp[(2) - (2)]));
@@ -3613,52 +3590,52 @@ regular_loop:
}
break;
+ case 125:
+
+/* Line 1806 of yacc.c */
+#line 1341 "awkgram.y"
+ { (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
+ break;
+
case 126:
/* Line 1806 of yacc.c */
-#line 1371 "awkgram.y"
+#line 1343 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 127:
/* Line 1806 of yacc.c */
-#line 1373 "awkgram.y"
+#line 1345 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 128:
/* Line 1806 of yacc.c */
-#line 1375 "awkgram.y"
+#line 1347 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 129:
/* Line 1806 of yacc.c */
-#line 1377 "awkgram.y"
+#line 1349 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 130:
/* Line 1806 of yacc.c */
-#line 1379 "awkgram.y"
+#line 1351 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 131:
/* Line 1806 of yacc.c */
-#line 1381 "awkgram.y"
- { (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
- break;
-
- case 132:
-
-/* Line 1806 of yacc.c */
-#line 1383 "awkgram.y"
+#line 1353 "awkgram.y"
{
/*
* In BEGINFILE/ENDFILE, allow `getline var < file'
@@ -3683,30 +3660,30 @@ regular_loop:
}
break;
- case 133:
+ case 132:
/* Line 1806 of yacc.c */
-#line 1406 "awkgram.y"
+#line 1376 "awkgram.y"
{
(yyvsp[(2) - (2)])->opcode = Op_postincrement;
(yyval) = mk_assignment((yyvsp[(1) - (2)]), NULL, (yyvsp[(2) - (2)]));
}
break;
- case 134:
+ case 133:
/* Line 1806 of yacc.c */
-#line 1411 "awkgram.y"
+#line 1381 "awkgram.y"
{
(yyvsp[(2) - (2)])->opcode = Op_postdecrement;
(yyval) = mk_assignment((yyvsp[(1) - (2)]), NULL, (yyvsp[(2) - (2)]));
}
break;
- case 135:
+ case 134:
/* Line 1806 of yacc.c */
-#line 1416 "awkgram.y"
+#line 1386 "awkgram.y"
{
if (do_lint_old) {
warning_ln((yyvsp[(4) - (5)])->source_line,
@@ -3728,81 +3705,82 @@ regular_loop:
}
break;
- case 136:
+ case 135:
/* Line 1806 of yacc.c */
-#line 1441 "awkgram.y"
+#line 1411 "awkgram.y"
{
(yyval) = mk_getline((yyvsp[(3) - (4)]), (yyvsp[(4) - (4)]), (yyvsp[(1) - (4)]), (yyvsp[(2) - (4)])->redir_type);
bcfree((yyvsp[(2) - (4)]));
}
break;
+ case 136:
+
+/* Line 1806 of yacc.c */
+#line 1417 "awkgram.y"
+ { (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
+ break;
+
case 137:
/* Line 1806 of yacc.c */
-#line 1447 "awkgram.y"
+#line 1419 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 138:
/* Line 1806 of yacc.c */
-#line 1449 "awkgram.y"
+#line 1421 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 139:
/* Line 1806 of yacc.c */
-#line 1451 "awkgram.y"
+#line 1423 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 140:
/* Line 1806 of yacc.c */
-#line 1453 "awkgram.y"
+#line 1425 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 141:
/* Line 1806 of yacc.c */
-#line 1455 "awkgram.y"
+#line 1427 "awkgram.y"
{ (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
break;
case 142:
/* Line 1806 of yacc.c */
-#line 1457 "awkgram.y"
- { (yyval) = mk_binary((yyvsp[(1) - (3)]), (yyvsp[(3) - (3)]), (yyvsp[(2) - (3)])); }
- break;
-
- case 143:
-
-/* Line 1806 of yacc.c */
-#line 1462 "awkgram.y"
+#line 1432 "awkgram.y"
{
(yyval) = list_create((yyvsp[(1) - (1)]));
}
break;
- case 144:
+ case 143:
/* Line 1806 of yacc.c */
-#line 1466 "awkgram.y"
+#line 1436 "awkgram.y"
{
if ((yyvsp[(2) - (2)])->opcode == Op_match_rec) {
(yyvsp[(2) - (2)])->opcode = Op_nomatch;
(yyvsp[(1) - (2)])->opcode = Op_push_i;
- (yyvsp[(1) - (2)])->memory = mk_number(0.0, (PERM|NUMCUR|NUMBER));
+ (yyvsp[(1) - (2)])->memory = make_number(0.0);
(yyval) = list_append(list_append(list_create((yyvsp[(1) - (2)])),
- instruction(Op_field_spec)), (yyvsp[(2) - (2)]));
+ instruction(Op_field_spec)), (yyvsp[(2) - (2)]));
} else {
if (do_optimize > 1 && (yyvsp[(2) - (2)])->nexti == (yyvsp[(2) - (2)])->lasti
- && (yyvsp[(2) - (2)])->nexti->opcode == Op_push_i
+ && (yyvsp[(2) - (2)])->nexti->opcode == Op_push_i
+ && ((yyvsp[(2) - (2)])->nexti->memory->flags & (MPFN|MPZN)) == 0
) {
NODE *n = (yyvsp[(2) - (2)])->nexti->memory;
if ((n->flags & (STRCUR|STRING)) != 0) {
@@ -3825,17 +3803,17 @@ regular_loop:
}
break;
- case 145:
+ case 144:
/* Line 1806 of yacc.c */
-#line 1497 "awkgram.y"
+#line 1468 "awkgram.y"
{ (yyval) = (yyvsp[(2) - (3)]); }
break;
- case 146:
+ case 145:
/* Line 1806 of yacc.c */
-#line 1499 "awkgram.y"
+#line 1470 "awkgram.y"
{
(yyval) = snode((yyvsp[(3) - (4)]), (yyvsp[(1) - (4)]));
if ((yyval) == NULL)
@@ -3843,10 +3821,10 @@ regular_loop:
}
break;
- case 147:
+ case 146:
/* Line 1806 of yacc.c */
-#line 1505 "awkgram.y"
+#line 1476 "awkgram.y"
{
(yyval) = snode((yyvsp[(3) - (4)]), (yyvsp[(1) - (4)]));
if ((yyval) == NULL)
@@ -3854,10 +3832,10 @@ regular_loop:
}
break;
- case 148:
+ case 147:
/* Line 1806 of yacc.c */
-#line 1511 "awkgram.y"
+#line 1482 "awkgram.y"
{
static short warned1 = FALSE;
@@ -3872,52 +3850,55 @@ regular_loop:
}
break;
- case 151:
+ case 150:
/* Line 1806 of yacc.c */
-#line 1526 "awkgram.y"
+#line 1497 "awkgram.y"
{
(yyvsp[(1) - (2)])->opcode = Op_preincrement;
(yyval) = mk_assignment((yyvsp[(2) - (2)]), NULL, (yyvsp[(1) - (2)]));
}
break;
- case 152:
+ case 151:
/* Line 1806 of yacc.c */
-#line 1531 "awkgram.y"
+#line 1502 "awkgram.y"
{
(yyvsp[(1) - (2)])->opcode = Op_predecrement;
(yyval) = mk_assignment((yyvsp[(2) - (2)]), NULL, (yyvsp[(1) - (2)]));
}
break;
- case 153:
+ case 152:
/* Line 1806 of yacc.c */
-#line 1536 "awkgram.y"
+#line 1507 "awkgram.y"
{
(yyval) = list_create((yyvsp[(1) - (1)]));
}
break;
- case 154:
+ case 153:
/* Line 1806 of yacc.c */
-#line 1540 "awkgram.y"
+#line 1511 "awkgram.y"
{
(yyval) = list_create((yyvsp[(1) - (1)]));
}
break;
- case 155:
+ case 154:
/* Line 1806 of yacc.c */
-#line 1544 "awkgram.y"
+#line 1515 "awkgram.y"
{
if ((yyvsp[(2) - (2)])->lasti->opcode == Op_push_i
- && ((yyvsp[(2) - (2)])->lasti->memory->flags & (STRCUR|STRING)) == 0) {
- (yyvsp[(2) - (2)])->lasti->memory->numbr = -(force_number((yyvsp[(2) - (2)])->lasti->memory));
+ && ((yyvsp[(2) - (2)])->lasti->memory->flags & (STRCUR|STRING)) == 0
+ ) {
+ NODE *n = (yyvsp[(2) - (2)])->lasti->memory;
+ (void) force_number(n);
+ negate_num(n);
(yyval) = (yyvsp[(2) - (2)]);
bcfree((yyvsp[(1) - (2)]));
} else {
@@ -3927,35 +3908,35 @@ regular_loop:
}
break;
- case 156:
+ case 155:
/* Line 1806 of yacc.c */
-#line 1556 "awkgram.y"
+#line 1530 "awkgram.y"
{
/*
* was: $$ = $2
* POSIX semantics: force a conversion to numeric type
*/
(yyvsp[(1) - (2)])->opcode = Op_plus_i;
- (yyvsp[(1) - (2)])->memory = mk_number((AWKNUM) 0.0, (PERM|NUMCUR|NUMBER));
+ (yyvsp[(1) - (2)])->memory = make_number(0.0);
(yyval) = list_append((yyvsp[(2) - (2)]), (yyvsp[(1) - (2)]));
}
break;
- case 157:
+ case 156:
/* Line 1806 of yacc.c */
-#line 1569 "awkgram.y"
+#line 1543 "awkgram.y"
{
func_use((yyvsp[(1) - (1)])->lasti->func_name, FUNC_USE);
(yyval) = (yyvsp[(1) - (1)]);
}
break;
- case 158:
+ case 157:
/* Line 1806 of yacc.c */
-#line 1574 "awkgram.y"
+#line 1548 "awkgram.y"
{
/* indirect function call */
INSTRUCTION *f, *t;
@@ -3976,7 +3957,7 @@ regular_loop:
name = estrdup(f->func_name, strlen(f->func_name));
if (is_std_var(name))
yyerror(_("can not use special variable `%s' for indirect function call"), name);
- indirect_var = variable(name, Node_var_new);
+ indirect_var = variable(f->source_line, name, Node_var_new);
t = instruction(Op_push);
t->memory = indirect_var;
@@ -3990,10 +3971,10 @@ regular_loop:
}
break;
- case 159:
+ case 158:
/* Line 1806 of yacc.c */
-#line 1610 "awkgram.y"
+#line 1584 "awkgram.y"
{
param_sanity((yyvsp[(3) - (4)]));
(yyvsp[(1) - (4)])->opcode = Op_func_call;
@@ -4009,54 +3990,54 @@ regular_loop:
}
break;
- case 160:
+ case 159:
/* Line 1806 of yacc.c */
-#line 1627 "awkgram.y"
+#line 1601 "awkgram.y"
{ (yyval) = NULL; }
break;
- case 161:
+ case 160:
/* Line 1806 of yacc.c */
-#line 1629 "awkgram.y"
+#line 1603 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
- case 162:
+ case 161:
/* Line 1806 of yacc.c */
-#line 1634 "awkgram.y"
+#line 1608 "awkgram.y"
{ (yyval) = NULL; }
break;
- case 163:
+ case 162:
/* Line 1806 of yacc.c */
-#line 1636 "awkgram.y"
+#line 1610 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (2)]); }
break;
- case 164:
+ case 163:
/* Line 1806 of yacc.c */
-#line 1641 "awkgram.y"
+#line 1615 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
- case 165:
+ case 164:
/* Line 1806 of yacc.c */
-#line 1643 "awkgram.y"
+#line 1617 "awkgram.y"
{
(yyval) = list_merge((yyvsp[(1) - (2)]), (yyvsp[(2) - (2)]));
}
break;
- case 166:
+ case 165:
/* Line 1806 of yacc.c */
-#line 1650 "awkgram.y"
+#line 1624 "awkgram.y"
{
INSTRUCTION *ip = (yyvsp[(1) - (1)])->lasti;
int count = ip->sub_count; /* # of SUBSEP-seperated expressions */
@@ -4072,10 +4053,10 @@ regular_loop:
}
break;
- case 167:
+ case 166:
/* Line 1806 of yacc.c */
-#line 1667 "awkgram.y"
+#line 1641 "awkgram.y"
{
INSTRUCTION *t = (yyvsp[(2) - (3)]);
if ((yyvsp[(2) - (3)]) == NULL) {
@@ -4083,7 +4064,7 @@ regular_loop:
_("invalid subscript expression"));
/* install Null string as subscript. */
t = list_create(instruction(Op_push_i));
- t->nexti->memory = Nnull_string;
+ t->nexti->memory = dupnode(Nnull_string);
(yyvsp[(3) - (3)])->sub_count = 1;
} else
(yyvsp[(3) - (3)])->sub_count = count_expressions(&t, FALSE);
@@ -4091,67 +4072,63 @@ regular_loop:
}
break;
- case 168:
+ case 167:
/* Line 1806 of yacc.c */
-#line 1684 "awkgram.y"
+#line 1658 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); }
break;
- case 169:
+ case 168:
/* Line 1806 of yacc.c */
-#line 1686 "awkgram.y"
+#line 1660 "awkgram.y"
{
(yyval) = list_merge((yyvsp[(1) - (2)]), (yyvsp[(2) - (2)]));
}
break;
- case 170:
+ case 169:
/* Line 1806 of yacc.c */
-#line 1693 "awkgram.y"
+#line 1667 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (2)]); }
break;
- case 171:
+ case 170:
/* Line 1806 of yacc.c */
-#line 1698 "awkgram.y"
+#line 1672 "awkgram.y"
{
char *var_name = (yyvsp[(1) - (1)])->lextok;
(yyvsp[(1) - (1)])->opcode = Op_push;
- (yyvsp[(1) - (1)])->memory = variable(var_name, Node_var_new);
+ (yyvsp[(1) - (1)])->memory = variable((yyvsp[(1) - (1)])->source_line, var_name, Node_var_new);
(yyval) = list_create((yyvsp[(1) - (1)]));
}
break;
- case 172:
+ case 171:
/* Line 1806 of yacc.c */
-#line 1706 "awkgram.y"
+#line 1680 "awkgram.y"
{
- NODE *n;
-
char *arr = (yyvsp[(1) - (2)])->lextok;
- if ((n = lookup(arr)) != NULL && ! isarray(n))
- yyerror(_("use of non-array as array"));
- (yyvsp[(1) - (2)])->memory = variable(arr, Node_var_new);
+ (yyvsp[(1) - (2)])->memory = variable((yyvsp[(1) - (2)])->source_line, arr, Node_var_new);
(yyvsp[(1) - (2)])->opcode = Op_push_array;
(yyval) = list_prepend((yyvsp[(2) - (2)]), (yyvsp[(1) - (2)]));
}
break;
- case 173:
+ case 172:
/* Line 1806 of yacc.c */
-#line 1720 "awkgram.y"
+#line 1690 "awkgram.y"
{
INSTRUCTION *ip = (yyvsp[(1) - (1)])->nexti;
if (ip->opcode == Op_push
- && ip->memory->type == Node_var
- && ip->memory->var_update
+ && ip->memory->type == Node_var
+ && ip->memory->var_update
) {
(yyval) = list_prepend((yyvsp[(1) - (1)]), instruction(Op_var_update));
(yyval)->nexti->update_var = ip->memory->var_update;
@@ -4160,81 +4137,81 @@ regular_loop:
}
break;
- case 174:
+ case 173:
/* Line 1806 of yacc.c */
-#line 1732 "awkgram.y"
+#line 1702 "awkgram.y"
{
(yyval) = list_append((yyvsp[(2) - (3)]), (yyvsp[(1) - (3)]));
if ((yyvsp[(3) - (3)]) != NULL)
- mk_assignment((yyvsp[(2) - (3)]), NULL, (yyvsp[(3) - (3)]));
+ mk_assignment((yyvsp[(2) - (3)]), NULL, (yyvsp[(3) - (3)]));
}
break;
- case 175:
+ case 174:
/* Line 1806 of yacc.c */
-#line 1741 "awkgram.y"
+#line 1711 "awkgram.y"
{
(yyvsp[(1) - (1)])->opcode = Op_postincrement;
}
break;
- case 176:
+ case 175:
/* Line 1806 of yacc.c */
-#line 1745 "awkgram.y"
+#line 1715 "awkgram.y"
{
(yyvsp[(1) - (1)])->opcode = Op_postdecrement;
}
break;
- case 177:
+ case 176:
/* Line 1806 of yacc.c */
-#line 1748 "awkgram.y"
+#line 1718 "awkgram.y"
{ (yyval) = NULL; }
break;
- case 179:
+ case 178:
/* Line 1806 of yacc.c */
-#line 1756 "awkgram.y"
+#line 1726 "awkgram.y"
{ yyerrok; }
break;
- case 180:
+ case 179:
/* Line 1806 of yacc.c */
-#line 1760 "awkgram.y"
+#line 1730 "awkgram.y"
{ yyerrok; }
break;
- case 183:
+ case 182:
/* Line 1806 of yacc.c */
-#line 1769 "awkgram.y"
+#line 1739 "awkgram.y"
{ yyerrok; }
break;
- case 184:
+ case 183:
/* Line 1806 of yacc.c */
-#line 1773 "awkgram.y"
+#line 1743 "awkgram.y"
{ (yyval) = (yyvsp[(1) - (1)]); yyerrok; }
break;
- case 185:
+ case 184:
/* Line 1806 of yacc.c */
-#line 1777 "awkgram.y"
+#line 1747 "awkgram.y"
{ yyerrok; }
break;
/* Line 1806 of yacc.c */
-#line 4250 "awkgram.c"
+#line 4227 "awkgram.c"
default: break;
}
/* User semantic actions sometimes alter yychar, and that requires
@@ -4465,7 +4442,7 @@ yyreturn:
/* Line 2067 of yacc.c */
-#line 1779 "awkgram.y"
+#line 1749 "awkgram.y"
struct token {
@@ -4484,6 +4461,7 @@ struct token {
# define CONTINUE 0x2000 /* continue allowed inside */
NODE *(*ptr)(int); /* function that implements this keyword */
+ NODE *(*ptr2)(int); /* alternate arbitrary-precision function */
};
#if 'a' == 0x81 /* it's EBCDIC */
@@ -4507,81 +4485,84 @@ tokcompare(const void *l, const void *r)
* Function pointers come from declarations in awk.h.
*/
+#ifdef HAVE_MPFR
+#define MPF(F) do_mpfr_##F
+#else
+#define MPF(F) 0
+#endif
+
static const struct token tokentab[] = {
-{"BEGIN", Op_rule, LEX_BEGIN, 0, 0},
-{"BEGINFILE", Op_rule, LEX_BEGINFILE, GAWKX, 0},
-{"END", Op_rule, LEX_END, 0, 0},
-{"ENDFILE", Op_rule, LEX_ENDFILE, GAWKX, 0},
+{"BEGIN", Op_rule, LEX_BEGIN, 0, 0, 0},
+{"BEGINFILE", Op_rule, LEX_BEGINFILE, GAWKX, 0, 0},
+{"END", Op_rule, LEX_END, 0, 0, 0},
+{"ENDFILE", Op_rule, LEX_ENDFILE, GAWKX, 0, 0},
#ifdef ARRAYDEBUG
-{"adump", Op_builtin, LEX_BUILTIN, GAWKX|A(1), do_adump},
+{"adump", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2), do_adump, 0},
#endif
-{"and", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_and},
-{"asort", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2)|A(3), do_asort},
-{"asorti", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2)|A(3), do_asorti},
-{"atan2", Op_builtin, LEX_BUILTIN, NOT_OLD|A(2), do_atan2},
-{"bindtextdomain", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2), do_bindtextdomain},
-{"break", Op_K_break, LEX_BREAK, 0, 0},
-{"case", Op_K_case, LEX_CASE, GAWKX, 0},
-{"close", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1)|A(2), do_close},
-{"compl", Op_builtin, LEX_BUILTIN, GAWKX|A(1), do_compl},
-{"continue", Op_K_continue, LEX_CONTINUE, 0, 0},
-{"cos", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_cos},
-{"dcgettext", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2)|A(3), do_dcgettext},
-{"dcngettext", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2)|A(3)|A(4)|A(5), do_dcngettext},
-{"default", Op_K_default, LEX_DEFAULT, GAWKX, 0},
-{"delete", Op_K_delete, LEX_DELETE, NOT_OLD, 0},
-{"do", Op_K_do, LEX_DO, NOT_OLD|BREAK|CONTINUE, 0},
-{"else", Op_K_else, LEX_ELSE, 0, 0},
-{"eval", Op_symbol, LEX_EVAL, 0, 0},
-{"exit", Op_K_exit, LEX_EXIT, 0, 0},
-{"exp", Op_builtin, LEX_BUILTIN, A(1), do_exp},
-{"extension", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_ext},
-{"fflush", Op_builtin, LEX_BUILTIN, RESX|A(0)|A(1), do_fflush},
-{"for", Op_K_for, LEX_FOR, BREAK|CONTINUE, 0},
-{"func", Op_func, LEX_FUNCTION, NOT_POSIX|NOT_OLD, 0},
-{"function",Op_func, LEX_FUNCTION, NOT_OLD, 0},
-{"gensub", Op_sub_builtin, LEX_BUILTIN, GAWKX|A(3)|A(4), 0},
-{"getline", Op_K_getline_redir, LEX_GETLINE, NOT_OLD, 0},
-{"gsub", Op_sub_builtin, LEX_BUILTIN, NOT_OLD|A(2)|A(3), 0},
-{"if", Op_K_if, LEX_IF, 0, 0},
-{"in", Op_symbol, LEX_IN, 0, 0},
-{"include", Op_symbol, LEX_INCLUDE, GAWKX, 0},
-{"index", Op_builtin, LEX_BUILTIN, A(2), do_index},
-{"int", Op_builtin, LEX_BUILTIN, A(1), do_int},
-{"isarray", Op_builtin, LEX_BUILTIN, GAWKX|A(1), do_isarray},
-{"length", Op_builtin, LEX_LENGTH, A(0)|A(1), do_length},
-{"log", Op_builtin, LEX_BUILTIN, A(1), do_log},
-{"lshift", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_lshift},
-{"match", Op_builtin, LEX_BUILTIN, NOT_OLD|A(2)|A(3), do_match},
-{"mktime", Op_builtin, LEX_BUILTIN, GAWKX|A(1), do_mktime},
-{"next", Op_K_next, LEX_NEXT, 0, 0},
-{"nextfile", Op_K_nextfile, LEX_NEXTFILE, GAWKX, 0},
-{"or", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_or},
-{"patsplit", Op_builtin, LEX_BUILTIN, GAWKX|A(2)|A(3)|A(4), do_patsplit},
-{"print", Op_K_print, LEX_PRINT, 0, 0},
-{"printf", Op_K_printf, LEX_PRINTF, 0, 0},
-{"rand", Op_builtin, LEX_BUILTIN, NOT_OLD|A(0), do_rand},
-{"return", Op_K_return, LEX_RETURN, NOT_OLD, 0},
-{"rshift", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_rshift},
-{"sin", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_sin},
-{"split", Op_builtin, LEX_BUILTIN, A(2)|A(3)|A(4), do_split},
-{"sprintf", Op_builtin, LEX_BUILTIN, 0, do_sprintf},
-{"sqrt", Op_builtin, LEX_BUILTIN, A(1), do_sqrt},
-{"srand", Op_builtin, LEX_BUILTIN, NOT_OLD|A(0)|A(1), do_srand},
-#if defined(GAWKDEBUG) || defined(ARRAYDEBUG) /* || ... */
-{"stopme", Op_builtin, LEX_BUILTIN, GAWKX|A(0), stopme},
-#endif
-{"strftime", Op_builtin, LEX_BUILTIN, GAWKX|A(0)|A(1)|A(2)|A(3), do_strftime},
-{"strtonum", Op_builtin, LEX_BUILTIN, GAWKX|A(1), do_strtonum},
-{"sub", Op_sub_builtin, LEX_BUILTIN, NOT_OLD|A(2)|A(3), 0},
-{"substr", Op_builtin, LEX_BUILTIN, A(2)|A(3), do_substr},
-{"switch", Op_K_switch, LEX_SWITCH, GAWKX|BREAK, 0},
-{"system", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_system},
-{"systime", Op_builtin, LEX_BUILTIN, GAWKX|A(0), do_systime},
-{"tolower", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_tolower},
-{"toupper", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_toupper},
-{"while", Op_K_while, LEX_WHILE, BREAK|CONTINUE, 0},
-{"xor", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_xor},
+{"and", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_and, MPF(and)},
+{"asort", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2)|A(3), do_asort, 0},
+{"asorti", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2)|A(3), do_asorti, 0},
+{"atan2", Op_builtin, LEX_BUILTIN, NOT_OLD|A(2), do_atan2, MPF(atan2)},
+{"bindtextdomain", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2), do_bindtextdomain, 0},
+{"break", Op_K_break, LEX_BREAK, 0, 0, 0},
+{"case", Op_K_case, LEX_CASE, GAWKX, 0, 0},
+{"close", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1)|A(2), do_close, 0},
+{"compl", Op_builtin, LEX_BUILTIN, GAWKX|A(1), do_compl, MPF(compl)},
+{"continue", Op_K_continue, LEX_CONTINUE, 0, 0, 0},
+{"cos", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_cos, MPF(cos)},
+{"dcgettext", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2)|A(3), do_dcgettext, 0},
+{"dcngettext", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2)|A(3)|A(4)|A(5), do_dcngettext, 0},
+{"default", Op_K_default, LEX_DEFAULT, GAWKX, 0, 0},
+{"delete", Op_K_delete, LEX_DELETE, NOT_OLD, 0, 0},
+{"do", Op_K_do, LEX_DO, NOT_OLD|BREAK|CONTINUE, 0, 0},
+{"else", Op_K_else, LEX_ELSE, 0, 0, 0},
+{"eval", Op_symbol, LEX_EVAL, 0, 0, 0},
+{"exit", Op_K_exit, LEX_EXIT, 0, 0, 0},
+{"exp", Op_builtin, LEX_BUILTIN, A(1), do_exp, MPF(exp)},
+{"extension", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_ext, 0},
+{"fflush", Op_builtin, LEX_BUILTIN, RESX|A(0)|A(1), do_fflush, 0},
+{"for", Op_K_for, LEX_FOR, BREAK|CONTINUE, 0, 0},
+{"func", Op_func, LEX_FUNCTION, NOT_POSIX|NOT_OLD, 0, 0},
+{"function",Op_func, LEX_FUNCTION, NOT_OLD, 0, 0},
+{"gensub", Op_sub_builtin, LEX_BUILTIN, GAWKX|A(3)|A(4), 0, 0},
+{"getline", Op_K_getline_redir, LEX_GETLINE, NOT_OLD, 0, 0},
+{"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},
+{"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},
+{"length", Op_builtin, LEX_LENGTH, A(0)|A(1), do_length, 0},
+{"log", Op_builtin, LEX_BUILTIN, A(1), do_log, MPF(log)},
+{"lshift", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_lshift, MPF(lshift)},
+{"match", Op_builtin, LEX_BUILTIN, NOT_OLD|A(2)|A(3), do_match, 0},
+{"mktime", Op_builtin, LEX_BUILTIN, GAWKX|A(1), do_mktime, 0},
+{"next", Op_K_next, LEX_NEXT, 0, 0, 0},
+{"nextfile", Op_K_nextfile, LEX_NEXTFILE, GAWKX, 0, 0},
+{"or", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_or, MPF(or)},
+{"patsplit", Op_builtin, LEX_BUILTIN, GAWKX|A(2)|A(3)|A(4), do_patsplit, 0},
+{"print", Op_K_print, LEX_PRINT, 0, 0, 0},
+{"printf", Op_K_printf, LEX_PRINTF, 0, 0, 0},
+{"rand", Op_builtin, LEX_BUILTIN, NOT_OLD|A(0), do_rand, MPF(rand)},
+{"return", Op_K_return, LEX_RETURN, NOT_OLD, 0, 0},
+{"rshift", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_rshift, MPF(rhift)},
+{"sin", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_sin, MPF(sin)},
+{"split", Op_builtin, LEX_BUILTIN, A(2)|A(3)|A(4), do_split, 0},
+{"sprintf", Op_builtin, LEX_BUILTIN, 0, do_sprintf, 0},
+{"sqrt", Op_builtin, LEX_BUILTIN, A(1), do_sqrt, MPF(sqrt)},
+{"srand", Op_builtin, LEX_BUILTIN, NOT_OLD|A(0)|A(1), do_srand, MPF(srand)},
+{"strftime", Op_builtin, LEX_BUILTIN, GAWKX|A(0)|A(1)|A(2)|A(3), do_strftime, 0},
+{"strtonum", Op_builtin, LEX_BUILTIN, GAWKX|A(1), do_strtonum, MPF(strtonum)},
+{"sub", Op_sub_builtin, LEX_BUILTIN, NOT_OLD|A(2)|A(3), 0, 0},
+{"substr", Op_builtin, LEX_BUILTIN, A(2)|A(3), do_substr, 0},
+{"switch", Op_K_switch, LEX_SWITCH, GAWKX|BREAK, 0, 0},
+{"system", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_system, 0},
+{"systime", Op_builtin, LEX_BUILTIN, GAWKX|A(0), do_systime, 0},
+{"tolower", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_tolower, 0},
+{"toupper", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_toupper, 0},
+{"while", Op_K_while, LEX_WHILE, BREAK|CONTINUE, 0, 0},
+{"xor", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_xor, MPF(xor)},
};
#if MBS_SUPPORT
@@ -4617,6 +4598,23 @@ getfname(NODE *(*fptr)(int))
return NULL;
}
+/* negate_num --- negate a number in NODE */
+
+void
+negate_num(NODE *n)
+{
+#ifdef HAVE_MPFR
+ if (is_mpg_float(n)) {
+ int tval;
+ tval = mpfr_neg(n->mpg_numbr, n->mpg_numbr, ROUND_MODE);
+ IEEE_FMT(n->mpg_numbr, tval);
+ } else if (is_mpg_integer(n)) {
+ mpz_neg(n->mpg_i, n->mpg_i);
+ } else
+#endif
+ n->numbr = -n->numbr;
+}
+
/* print_included_from --- print `Included from ..' file names and locations */
static void
@@ -4640,7 +4638,7 @@ print_included_from()
line--;
msg("%s %s:%d%c",
s->prev == sourcefile ? "In file included from"
- : " from",
+ : " from",
(s->stype == SRC_INC ||
s->stype == SRC_FILE) ? s->src : "cmd. line",
line,
@@ -4922,7 +4920,10 @@ parse_program(INSTRUCTION **pcode)
ip_atexit = instruction(Op_atexit); /* target for `exit' in END block */
}
- sourcefile = srcfiles->next;
+ for (sourcefile = srcfiles->next; sourcefile->stype == SRC_EXTLIB;
+ sourcefile = sourcefile->next)
+ ;
+
lexeof = FALSE;
lexptr = NULL;
lasttok = 0;
@@ -4939,6 +4940,11 @@ parse_program(INSTRUCTION **pcode)
if (ret == 0) /* avoid spurious warning if parser aborted with YYABORT */
check_funcs();
+ if (args_array == NULL)
+ emalloc(args_array, NODE **, (max_args + 2) * sizeof(NODE *), "parse_program");
+ else
+ erealloc(args_array, NODE **, (max_args + 2) * sizeof(NODE *), "parse_program");
+
return (ret || errcount);
}
@@ -4981,7 +4987,7 @@ add_srcfile(int stype, char *src, SRCFILE *thisfile, int *already_included, int
if (stype == SRC_CMDLINE || stype == SRC_STDIN)
return do_add_srcfile(stype, src, NULL, thisfile);
- path = find_source(src, &sbuf, &errno_val);
+ path = find_source(src, & sbuf, &errno_val, stype == SRC_EXTLIB);
if (path == NULL) {
if (errcode) {
*errcode = errno_val;
@@ -4992,7 +4998,7 @@ add_srcfile(int stype, char *src, SRCFILE *thisfile, int *already_included, int
}
for (s = srcfiles->next; s != srcfiles; s = s->next) {
- if ((s->stype == SRC_FILE || s->stype == SRC_INC)
+ if ((s->stype == SRC_FILE || s->stype == SRC_INC || s->stype == SRC_EXTLIB)
&& files_are_same(path, s)
) {
if (do_lint) {
@@ -5094,6 +5100,7 @@ next_sourcefile()
*
* assert(lexeof == TRUE);
*/
+
lexeof = FALSE;
eof_warned = FALSE;
sourcefile->srclines = sourceline; /* total no of lines in current file */
@@ -5108,9 +5115,12 @@ next_sourcefile()
sourcefile->lexptr_begin = NULL;
}
- sourcefile = sourcefile->next;
- if (sourcefile == srcfiles)
- return;
+ while ((sourcefile = sourcefile->next) != NULL) {
+ if (sourcefile == srcfiles)
+ return;
+ if (sourcefile->stype != SRC_EXTLIB)
+ break;
+ }
if (sourcefile->lexptr_begin != NULL) {
/* resume reading from already opened file (postponed to process '@include') */
@@ -5506,10 +5516,12 @@ yylex(void)
int seen_point = FALSE;
int esc_seen; /* for literal strings */
int mid;
+ int base;
static int did_newline = FALSE;
char *tokkey;
int inhex = FALSE;
int intlstr = FALSE;
+ AWKNUM d;
#define GET_INSTRUCTION(op) bcalloc(op, 1, sourceline)
@@ -5940,9 +5952,7 @@ retry:
yylval->opcode = Op_push_i;
yylval->memory = make_str_node(tokstart,
- tok - tokstart, esc_seen ? SCAN : 0);
- yylval->memory->flags &= ~MALLOC;
- yylval->memory->flags |= PERM;
+ tok - tokstart, esc_seen ? SCAN : 0);
if (intlstr) {
yylval->memory->flags |= INTLSTR;
intlstr = FALSE;
@@ -6075,19 +6085,46 @@ retry:
tokadd('\0');
yylval = GET_INSTRUCTION(Op_push_i);
- if (! do_traditional && isnondecimal(tokstart, FALSE)) {
+
+ base = 10;
+ if (! do_traditional) {
+ base = get_numbase(tokstart, FALSE);
if (do_lint) {
- if (isdigit((unsigned char) tokstart[1])) /* not an 'x' or 'X' */
+ if (base == 8)
lintwarn("numeric constant `%.*s' treated as octal",
(int) strlen(tokstart)-1, tokstart);
- else if (tokstart[1] == 'x' || tokstart[1] == 'X')
+ else if (base == 16)
lintwarn("numeric constant `%.*s' treated as hexadecimal",
(int) strlen(tokstart)-1, tokstart);
}
- yylval->memory = mk_number(nondec2awknum(tokstart, strlen(tokstart)),
- PERM|NUMCUR|NUMBER);
- } else
- yylval->memory = mk_number(atof(tokstart), PERM|NUMCUR|NUMBER);
+ }
+
+#ifdef HAVE_MPFR
+ if (do_mpfr) {
+ NODE *r;
+
+ if (! seen_point && ! seen_e) {
+ r = mpg_integer();
+ mpg_strtoui(r->mpg_i, tokstart, strlen(tokstart), NULL, base);
+ errno = 0;
+ } else {
+ int tval;
+ r = mpg_float();
+ tval = mpfr_strtofr(r->mpg_numbr, tokstart, NULL, base, ROUND_MODE);
+ errno = 0;
+ IEEE_FMT(r->mpg_numbr, tval);
+ }
+ yylval->memory = r;
+ return lasttok = YNUMBER;
+ }
+#endif
+ if (base != 10)
+ d = nondec2awknum(tokstart, strlen(tokstart));
+ else
+ d = atof(tokstart);
+ yylval->memory = make_number(d);
+ if (d <= INT32_MAX && d >= INT32_MIN && d == (int32_t) d)
+ yylval->memory->flags |= NUMINT;
return lasttok = YNUMBER;
case '&':
@@ -6224,7 +6261,7 @@ retry:
case LEX_WHILE:
case LEX_DO:
case LEX_SWITCH:
- if (! do_profiling)
+ if (! do_pretty_print)
return lasttok = class;
/* fall through */
case LEX_CASE:
@@ -6264,23 +6301,6 @@ out:
#undef NEWLINE_EOF
}
-/* mk_symbol --- allocates a symbol for the symbol table. */
-
-NODE *
-mk_symbol(NODETYPE type, NODE *value)
-{
- NODE *r;
-
- getnode(r);
- r->type = type;
- r->flags = MALLOC;
- r->lnode = value;
- r->rnode = NULL;
- r->parent_array = NULL;
- r->var_assign = (Func_ptr) 0;
- return r;
-}
-
/* snode --- instructions for builtin functions. Checks for arg. count
and supplies defaults where possible. */
@@ -6332,7 +6352,7 @@ snode(INSTRUCTION *subn, INSTRUCTION *r)
INSTRUCTION *expr;
expr = list_create(instruction(Op_push_i));
- expr->nexti->memory = mk_number((AWKNUM) 0.0, (PERM|NUMCUR|NUMBER));
+ expr->nexti->memory = make_number(0.0);
(void) mk_expression_list(subn,
list_append(expr, instruction(Op_field_spec)));
}
@@ -6376,7 +6396,7 @@ snode(INSTRUCTION *subn, INSTRUCTION *r)
r->sub_flags |= GENSUB;
if (nexp == 3) {
ip = instruction(Op_push_i);
- ip->memory = mk_number((AWKNUM) 0.0, (PERM|NUMCUR|NUMBER));
+ ip->memory = make_number(0.0);
(void) mk_expression_list(subn,
list_append(list_create(ip), instruction(Op_field_spec)));
}
@@ -6386,7 +6406,13 @@ snode(INSTRUCTION *subn, INSTRUCTION *r)
}
}
- r->builtin = tokentab[idx].ptr;
+#ifdef HAVE_MPFR
+ /* N.B.: There isn't any special processing for an alternate function below */
+ if (do_mpfr && tokentab[idx].ptr2)
+ r->builtin = tokentab[idx].ptr2;
+ else
+#endif
+ r->builtin = tokentab[idx].ptr;
/* special case processing for a few builtins */
@@ -6399,7 +6425,7 @@ snode(INSTRUCTION *subn, INSTRUCTION *r)
list = list_create(r);
(void) list_prepend(list, instruction(Op_field_spec));
(void) list_prepend(list, instruction(Op_push_i));
- list->nexti->memory = mk_number((AWKNUM) 0.0, (PERM|NUMCUR|NUMBER));
+ list->nexti->memory = make_number(0.0);
return list;
} else {
arg = subn->nexti;
@@ -6527,7 +6553,7 @@ snode(INSTRUCTION *subn, INSTRUCTION *r)
if (ip->opcode == Op_push)
ip->opcode = Op_push_array;
}
-#endif
+#endif
if (subn != NULL) {
r->expr_count = count_expressions(&subn, FALSE);
@@ -6538,75 +6564,6 @@ snode(INSTRUCTION *subn, INSTRUCTION *r)
return list_create(r);
}
-/* append_param --- append PNAME to the list of parameters
- * for the current function.
- */
-
-static void
-append_param(char *pname)
-{
- static NODE *savetail = NULL;
- NODE *p;
-
- p = make_param(pname);
- if (func_params == NULL) {
- func_params = p;
- savetail = p;
- } else if (savetail != NULL) {
- savetail->rnode = p;
- savetail = p;
- }
-}
-
-/* dup_parms --- return TRUE if there are duplicate parameters */
-
-static int
-dup_parms(INSTRUCTION *fp, NODE *func)
-{
- NODE *np;
- const char *fname, **names;
- int count, i, j, dups;
- NODE *params;
-
- if (func == NULL) /* error earlier */
- return TRUE;
-
- fname = func->param;
- count = func->param_cnt;
- params = func->rnode;
-
- if (count == 0) /* no args, no problem */
- return FALSE;
-
- if (params == NULL) /* error earlier */
- return TRUE;
-
- emalloc(names, const char **, count * sizeof(char *), "dup_parms");
-
- i = 0;
- for (np = params; np != NULL; np = np->rnode) {
- if (np->param == NULL) { /* error earlier, give up, go home */
- efree(names);
- return TRUE;
- }
- names[i++] = np->param;
- }
-
- dups = 0;
- for (i = 1; i < count; i++) {
- for (j = 0; j < i; j++) {
- if (strcmp(names[i], names[j]) == 0) {
- dups++;
- error_ln(fp->source_line,
- _("function `%s': parameter #%d, `%s', duplicates parameter #%d"),
- fname, i + 1, names[j], j+1);
- }
- }
- }
-
- efree(names);
- return (dups > 0 ? TRUE : FALSE);
-}
/* parms_shadow --- check if parameters shadow globals */
@@ -6615,18 +6572,19 @@ parms_shadow(INSTRUCTION *pc, int *shadow)
{
int pcount, i;
int ret = FALSE;
- NODE *func;
+ NODE *func, *fp;
char *fname;
func = pc->func_body;
- fname = func->lnode->param;
-
+ fname = func->vname;
+ fp = func->fparms;
+
#if 0 /* can't happen, already exited if error ? */
if (fname == NULL || func == NULL) /* error earlier */
return FALSE;
#endif
- pcount = func->lnode->param_cnt;
+ pcount = func->param_cnt;
if (pcount == 0) /* no args, no problem */
return 0;
@@ -6638,10 +6596,10 @@ parms_shadow(INSTRUCTION *pc, int *shadow)
* about all shadowed parameters.
*/
for (i = 0; i < pcount; i++) {
- if (lookup(func->parmlist[i]) != NULL) {
+ if (lookup(fp[i].param) != NULL) {
warning(
_("function `%s': parameter `%s' shadows global variable"),
- fname, func->parmlist[i]);
+ fname, fp[i].param);
ret = TRUE;
}
}
@@ -6650,143 +6608,41 @@ parms_shadow(INSTRUCTION *pc, int *shadow)
return 0;
}
-
-/*
- * install_symbol:
- * Install a name in the symbol table, even if it is already there.
- * Caller must check against redefinition if that is desired.
- */
-
-
-NODE *
-install_symbol(char *name, NODE *value)
-{
- NODE *hp;
- size_t len;
- int bucket;
-
- if (install_func)
- (*install_func)(name);
-
- var_count++;
- len = strlen(name);
- bucket = hash(name, len, (unsigned long) HASHSIZE, NULL);
- getnode(hp);
- hp->type = Node_hashnode;
- hp->hnext = variables[bucket];
- variables[bucket] = hp;
- hp->hlength = len;
- hp->hvalue = value;
- hp->hname = name;
- hp->hvalue->vname = name;
- return hp->hvalue;
-}
-
-/* lookup --- find the most recent hash node for name installed by install_symbol */
-
-NODE *
-lookup(const char *name)
-{
- NODE *bucket;
- size_t len;
-
- len = strlen(name);
- for (bucket = variables[hash(name, len, (unsigned long) HASHSIZE, NULL)];
- bucket != NULL; bucket = bucket->hnext)
- if (bucket->hlength == len && strncmp(bucket->hname, name, len) == 0)
- return bucket->hvalue;
- return NULL;
-}
-
-/* sym_comp --- compare two symbol (variable or function) names */
-
-static int
-sym_comp(const void *v1, const void *v2)
-{
- const NODE *const *npp1, *const *npp2;
- const NODE *n1, *n2;
- int minlen;
-
- npp1 = (const NODE *const *) v1;
- npp2 = (const NODE *const *) v2;
- n1 = *npp1;
- n2 = *npp2;
-
- if (n1->hlength > n2->hlength)
- minlen = n1->hlength;
- else
- minlen = n2->hlength;
-
- return strncmp(n1->hname, n2->hname, minlen);
-}
-
/* valinfo --- dump var info */
void
-valinfo(NODE *n, int (*print_func)(FILE *, const char *, ...), FILE *fp)
+valinfo(NODE *n, Func_print print_func, FILE *fp)
{
if (n == Nnull_string)
print_func(fp, "uninitialized scalar\n");
else if (n->flags & STRING) {
pp_string_fp(print_func, fp, n->stptr, n->stlen, '"', FALSE);
print_func(fp, "\n");
- } else if (n->flags & NUMBER)
+ } else if (n->flags & NUMBER) {
+#ifdef HAVE_MPFR
+ if (is_mpg_float(n))
+ print_func(fp, "%s\n", mpg_fmt("%.17R*g", ROUND_MODE, n->mpg_numbr));
+ else if (is_mpg_integer(n))
+ print_func(fp, "%s\n", mpg_fmt("%Zd", n->mpg_i));
+ else
+#endif
print_func(fp, "%.17g\n", n->numbr);
- else if (n->flags & STRCUR) {
+ } else if (n->flags & STRCUR) {
pp_string_fp(print_func, fp, n->stptr, n->stlen, '"', FALSE);
print_func(fp, "\n");
- } else if (n->flags & NUMCUR)
+ } else if (n->flags & NUMCUR) {
+#ifdef HAVE_MPFR
+ if (is_mpg_float(n))
+ print_func(fp, "%s\n", mpg_fmt("%.17R*g", ROUND_MODE, n->mpg_numbr));
+ else if (is_mpg_integer(n))
+ print_func(fp, "%s\n", mpg_fmt("%Zd", n->mpg_i));
+ else
+#endif
print_func(fp, "%.17g\n", n->numbr);
- else
+ } else
print_func(fp, "?? flags %s\n", flags2str(n->flags));
}
-/* get_varlist --- list of global variables */
-
-NODE **
-get_varlist()
-{
- int i, j;
- NODE **table;
- NODE *p;
-
- emalloc(table, NODE **, (var_count + 1) * sizeof(NODE *), "get_varlist");
- update_global_values();
- for (i = j = 0; i < HASHSIZE; i++)
- for (p = variables[i]; p != NULL; p = p->hnext)
- table[j++] = p;
- assert(j == var_count);
-
- /* Shazzam! */
- qsort(table, j, sizeof(NODE *), sym_comp);
-
- table[j] = NULL;
- return table;
-}
-
-/* print_vars --- print names and values of global variables */
-
-void
-print_vars(int (*print_func)(FILE *, const char *, ...), FILE *fp)
-{
- int i;
- NODE **table;
- NODE *p;
-
- table = get_varlist();
- for (i = 0; (p = table[i]) != NULL; i++) {
- if (p->hvalue->type == Node_func)
- continue;
- print_func(fp, "%.*s: ", (int) p->hlength, p->hname);
- if (p->hvalue->type == Node_var_array)
- print_func(fp, "array, %ld elements\n", p->hvalue->table_size);
- else if (p->hvalue->type == Node_var_new)
- print_func(fp, "untyped variable\n");
- else if (p->hvalue->type == Node_var)
- valinfo(p->hvalue->var_value, print_func, fp);
- }
- efree(table);
-}
/* dump_vars --- dump the symbol table */
@@ -6794,6 +6650,7 @@ void
dump_vars(const char *fname)
{
FILE *fp;
+ NODE **vars;
if (fname == NULL)
fp = stderr;
@@ -6803,48 +6660,25 @@ dump_vars(const char *fname)
fp = stderr;
}
- print_vars(fprintf, fp);
+ vars = variable_list();
+ print_vars(vars, fprintf, fp);
+ efree(vars);
if (fp != stderr && fclose(fp) != 0)
warning(_("%s: close failed (%s)"), fname, strerror(errno));
}
-/* release_all_vars --- free all variable memory */
-
-void
-release_all_vars()
-{
- int i;
- NODE *p, *next;
-
- for (i = 0; i < HASHSIZE; i++) {
- for (p = variables[i]; p != NULL; p = next) {
- next = p->hnext;
-
- if (p->hvalue->type == Node_func)
- continue;
- else if (p->hvalue->type == Node_var_array)
- assoc_clear(p->hvalue);
- else if (p->hvalue->type != Node_var_new)
- unref(p->hvalue->var_value);
-
- efree(p->hname);
- freenode(p->hvalue);
- freenode(p);
- }
- }
-}
-
/* dump_funcs --- print all functions */
void
dump_funcs()
{
- if (func_count <= 0)
- return;
-
- (void) foreach_func((int (*)(INSTRUCTION *, void *)) pp_func, TRUE, (void *) 0);
+ NODE **funcs;
+ funcs = function_list(TRUE);
+ (void) foreach_func(funcs, (int (*)(INSTRUCTION *, void *)) pp_func, (void *) 0);
+ efree(funcs);
}
+
/* shadow_funcs --- check all functions for parameters that shadow globals */
void
@@ -6852,175 +6686,164 @@ shadow_funcs()
{
static int calls = 0;
int shadow = FALSE;
-
- if (func_count <= 0)
- return;
+ NODE **funcs;
if (calls++ != 0)
fatal(_("shadow_funcs() called twice!"));
- (void) foreach_func((int (*)(INSTRUCTION *, void *)) parms_shadow, TRUE, &shadow);
+ funcs = function_list(TRUE);
+ (void) foreach_func(funcs, (int (*)(INSTRUCTION *, void *)) parms_shadow, & shadow);
+ efree(funcs);
/* End with fatal if the user requested it. */
if (shadow && lintfunc != warning)
lintwarn(_("there were shadowed variables."));
}
-/*
- * func_install:
- * check if name is already installed; if so, it had better have Null value,
- * in which case def is added as the value. Otherwise, install name with def
- * as value.
- *
- * Extra work, build up and save a list of the parameter names in a table
- * and hang it off params->parmlist. This is used to set the `vname' field
- * of each function parameter during a function call. See eval.c.
+
+/* mk_function --- finalize function definition node; remove parameters
+ * out of the symbol table.
*/
-static int
-func_install(INSTRUCTION *func, INSTRUCTION *def)
+static INSTRUCTION *
+mk_function(INSTRUCTION *fi, INSTRUCTION *def)
{
- NODE *params;
- NODE *r, *n, *thisfunc, *hp;
- char **pnames = NULL;
- char *fname;
- int pcount = 0;
- int i;
+ NODE *thisfunc;
- params = func_params;
+ thisfunc = fi->func_body;
+ assert(thisfunc != NULL);
- /* check for function foo(foo) { ... }. bleah. */
- for (n = params->rnode; n != NULL; n = n->rnode) {
- if (strcmp(n->param, params->param) == 0) {
- error_ln(func->source_line,
- _("function `%s': can't use function name as parameter name"), params->param);
- return -1;
- } else if (is_std_var(n->param)) {
- error_ln(func->source_line,
- _("function `%s': can't use special variable `%s' as a function parameter"),
- params->param, n->param);
- return -1;
- }
- }
+ if (do_optimize > 1 && def->lasti->opcode == Op_pop) {
+ /* tail call which does not return any value. */
- thisfunc = NULL; /* turn off warnings */
+ INSTRUCTION *t;
- fname = params->param;
- /* symbol table management */
- hp = remove_symbol(params->param); /* remove function name out of symbol table */
- if (hp != NULL)
- freenode(hp);
- r = lookup(fname);
- if (r != NULL) {
- error_ln(func->source_line,
- _("function name `%s' previously defined"), fname);
- return -1;
- } else if (fname == builtin_func) /* not a valid function name */
- goto remove_params;
+ for (t = def->nexti; t->nexti != def->lasti; t = t->nexti)
+ ;
+ if (t->opcode == Op_func_call
+ && strcmp(t->func_name, thisfunc->vname) == 0)
+ (t + 1)->tail_call = TRUE;
+ }
/* add an implicit return at end;
* also used by 'return' command in debugger
*/
-
+
(void) list_append(def, instruction(Op_push_i));
- def->lasti->memory = Nnull_string;
+ def->lasti->memory = dupnode(Nnull_string);
(void) list_append(def, instruction(Op_K_return));
- if (do_profiling)
+ if (do_pretty_print)
(void) list_prepend(def, instruction(Op_exec_count));
- /* func->opcode is Op_func */
- (func + 1)->firsti = def->nexti;
- (func + 1)->lasti = def->lasti;
- (func + 2)->first_line = func->source_line;
- (func + 2)->last_line = lastline;
-
- func->nexti = def->nexti;
+ /* fi->opcode = Op_func */
+ (fi + 1)->firsti = def->nexti;
+ (fi + 1)->lasti = def->lasti;
+ (fi + 2)->first_line = fi->source_line;
+ (fi + 2)->last_line = lastline;
+ fi->nexti = def->nexti;
bcfree(def);
- (void) list_append(rule_list, func + 1); /* debugging */
-
- /* install the function */
- thisfunc = mk_symbol(Node_func, params);
- (void) install_symbol(fname, thisfunc);
- thisfunc->code_ptr = func;
- func->func_body = thisfunc;
-
- for (n = params->rnode; n != NULL; n = n->rnode)
- pcount++;
-
- if (pcount != 0) {
- emalloc(pnames, char **, (pcount + 1) * sizeof(char *), "func_install");
- for (i = 0, n = params->rnode; i < pcount; i++, n = n->rnode)
- pnames[i] = n->param;
- pnames[pcount] = NULL;
- }
- thisfunc->parmlist = pnames;
+ (void) list_append(rule_list, fi + 1); /* debugging */
/* update lint table info */
- func_use(fname, FUNC_DEFINE);
-
- func_count++; /* used in profiler / pretty printer */
+ func_use(thisfunc->vname, FUNC_DEFINE);
-remove_params:
/* remove params from symbol table */
- pop_params(params->rnode);
- return 0;
+ remove_params(thisfunc);
+ return fi;
}
-/* remove_symbol --- remove a variable from the symbol table */
+/*
+ * install_function:
+ * install function name in the symbol table.
+ * Extra work, build up and install a list of the parameter names.
+ */
-NODE *
-remove_symbol(char *name)
+static int
+install_function(char *fname, INSTRUCTION *fi, INSTRUCTION *plist)
{
- NODE *bucket, **save;
- size_t len;
+ NODE *r, *f;
+ int pcount = 0;
- len = strlen(name);
- save = &(variables[hash(name, len, (unsigned long) HASHSIZE, NULL)]);
- for (bucket = *save; bucket != NULL; bucket = bucket->hnext) {
- if (len == bucket->hlength && strncmp(bucket->hname, name, len) == 0) {
- var_count--;
- *save = bucket->hnext;
- return bucket;
- }
- save = &(bucket->hnext);
+ r = lookup(fname);
+ if (r != NULL) {
+ error_ln(fi->source_line, _("function name `%s' previously defined"), fname);
+ return -1;
}
- return NULL;
+
+ if (plist != NULL)
+ pcount = plist->lasti->param_count + 1;
+ f = install_symbol(fname, Node_func);
+ fi->func_body = f;
+ f->param_cnt = pcount;
+ f->code_ptr = fi;
+ f->fparms = NULL;
+ if (pcount > 0) {
+ char **pnames;
+ pnames = check_params(fname, pcount, plist); /* frees plist */
+ f->fparms = make_params(pnames, pcount);
+ efree(pnames);
+ install_params(f);
+ }
+ return 0;
}
-/* pop_params --- remove list of function parameters from symbol table */
-/*
- * pop parameters out of the symbol table. do this in reverse order to
- * avoid reading freed memory if there were duplicated parameters.
+/* check_params --- build a list of function parameter names after
+ * making sure that the names are valid and there are no duplicates.
*/
-static void
-pop_params(NODE *params)
+
+static char **
+check_params(char *fname, int pcount, INSTRUCTION *list)
{
- NODE *hp;
- if (params == NULL)
- return;
- pop_params(params->rnode);
- hp = remove_symbol(params->param);
- if (hp != NULL)
- freenode(hp);
-}
+ INSTRUCTION *p, *np;
+ int i, j;
+ char *name;
+ char **pnames;
-/* make_param --- make NAME into a function parameter */
+ assert(pcount > 0);
-static NODE *
-make_param(char *name)
-{
- NODE *r;
+ emalloc(pnames, char **, pcount * sizeof(char *), "check_params");
- getnode(r);
- r->type = Node_param_list;
- r->rnode = NULL;
- r->param_cnt = param_counter++;
- return (install_symbol(name, r));
+ for (i = 0, p = list->nexti; p != NULL; i++, p = np) {
+ np = p->nexti;
+ name = p->lextok;
+ p->lextok = NULL;
+
+ if (strcmp(name, fname) == 0) {
+ /* check for function foo(foo) { ... }. bleah. */
+ error_ln(p->source_line,
+ _("function `%s': can't use function name as parameter name"), fname);
+ } else if (is_std_var(name)) {
+ error_ln(p->source_line,
+ _("function `%s': can't use special variable `%s' as a function parameter"),
+ fname, name);
+ }
+
+ /* check for duplicate parameters */
+ for (j = 0; j < i; j++) {
+ if (strcmp(name, pnames[j]) == 0) {
+ error_ln(p->source_line,
+ _("function `%s': parameter #%d, `%s', duplicates parameter #%d"),
+ fname, i + 1, name, j + 1);
+ }
+ }
+
+ pnames[i] = name;
+ bcfree(p);
+ }
+ bcfree(list);
+
+ return pnames;
}
+
+#ifdef HASHSIZE
+undef HASHSIZE
+#endif
+#define HASHSIZE 1021
+
static struct fdesc {
char *name;
short used;
@@ -7128,69 +6951,6 @@ param_sanity(INSTRUCTION *arglist)
}
}
-/* foreach_func --- execute given function for each awk function in symbol table. */
-
-int
-foreach_func(int (*pfunc)(INSTRUCTION *, void *), int sort, void *data)
-{
- int i, j;
- NODE *p;
- int ret = 0;
-
- if (sort) {
- NODE **tab;
-
- /*
- * Walk through symbol table counting functions.
- * Could be more than func_count if there are
- * extension functions.
- */
- for (i = j = 0; i < HASHSIZE; i++) {
- for (p = variables[i]; p != NULL; p = p->hnext) {
- if (p->hvalue->type == Node_func) {
- j++;
- }
- }
- }
-
- if (j == 0)
- return 0;
-
- emalloc(tab, NODE **, j * sizeof(NODE *), "foreach_func");
-
- /* now walk again, copying info */
- for (i = j = 0; i < HASHSIZE; i++) {
- for (p = variables[i]; p != NULL; p = p->hnext) {
- if (p->hvalue->type == Node_func) {
- tab[j] = p;
- j++;
- }
- }
- }
-
- /* Shazzam! */
- qsort(tab, j, sizeof(NODE *), sym_comp);
-
- for (i = 0; i < j; i++) {
- if ((ret = pfunc(tab[i]->hvalue->code_ptr, data)) != 0)
- break;
- }
-
- efree(tab);
- return ret;
- }
-
- /* unsorted */
- for (i = 0; i < HASHSIZE; i++) {
- for (p = variables[i]; p != NULL; p = p->hnext) {
- if (p->hvalue->type == Node_func
- && (ret = pfunc(p->hvalue->code_ptr, data)) != 0)
- return ret;
- }
- }
- return 0;
-}
-
/* deferred variables --- those that are only defined if needed. */
/*
@@ -7225,17 +6985,14 @@ register_deferred_variable(const char *name, NODE *(*load_func)(void))
/* variable --- make sure NAME is in the symbol table */
NODE *
-variable(char *name, NODETYPE type)
+variable(int location, char *name, NODETYPE type)
{
NODE *r;
if ((r = lookup(name)) != NULL) {
- if (r->type == Node_func) {
- error(_("function `%s' called with space between name and `(',\nor used as a variable or an array"),
+ if (r->type == Node_func || r->type == Node_ext_func )
+ error_ln(location, _("function `%s' called with space between name and `(',\nor used as a variable or an array"),
r->vname);
- errcount++;
- r->type = Node_var_new; /* continue parsing instead of exiting */
- }
} else {
/* not found */
struct deferred_variable *dv;
@@ -7245,11 +7002,7 @@ variable(char *name, NODETYPE type)
/*
* This is the only case in which we may not free the string.
*/
- if (type == Node_var)
- r = mk_symbol(type, Nnull_string);
- else
- r = mk_symbol(type, (NODE *) NULL);
- return install_symbol(name, r);
+ return install_symbol(name, type);
}
if (strcmp(name, dv->name) == 0) {
r = (*dv->load_func)();
@@ -7356,9 +7109,6 @@ make_assignable(INSTRUCTION *ip)
{
switch (ip->opcode) {
case Op_push:
- if (ip->memory->type == Node_param_list
- && (ip->memory->flags & FUNC) != 0)
- return NULL;
ip->opcode = Op_push_lhs;
return ip;
case Op_field_spec:
@@ -7373,14 +7123,6 @@ make_assignable(INSTRUCTION *ip)
return NULL;
}
-/* stopme --- for debugging */
-
-NODE *
-stopme(int nargs ATTRIBUTE_UNUSED)
-{
- return (NODE *) 0;
-}
-
/* dumpintlstr --- write out an initial .po file entry for the string */
static void
@@ -7430,27 +7172,6 @@ dumpintlstr2(const char *str1, size_t len1, const char *str2, size_t len2)
fflush(stdout);
}
-/* isarray --- can this type be subscripted? */
-
-static int
-isarray(NODE *n)
-{
- switch (n->type) {
- case Node_var_new:
- case Node_var_array:
- return TRUE;
- case Node_param_list:
- return (n->flags & FUNC) == 0;
- case Node_array_ref:
- cant_happen();
- break;
- default:
- break; /* keeps gcc -Wall happy */
- }
-
- return FALSE;
-}
-
/* mk_binary --- instructions for binary operators */
static INSTRUCTION *
@@ -7465,11 +7186,11 @@ mk_binary(INSTRUCTION *s1, INSTRUCTION *s2, INSTRUCTION *op)
ip1 = s1->nexti;
if (do_optimize > 1
&& ip1 == s1->lasti && ip1->opcode == Op_push_i
- && (ip1->memory->flags & (STRCUR|STRING)) == 0
- && (ip2->memory->flags & (STRCUR|STRING)) == 0
+ && (ip1->memory->flags & (MPFN|MPZN|STRCUR|STRING)) == 0
+ && (ip2->memory->flags & (MPFN|MPZN|STRCUR|STRING)) == 0
) {
NODE *n1 = ip1->memory, *n2 = ip2->memory;
- res = force_number(n1);
+ res = force_number(n1)->numbr;
(void) force_number(n2);
switch (op->opcode) {
case Op_times:
@@ -7511,11 +7232,7 @@ mk_binary(INSTRUCTION *s1, INSTRUCTION *s2, INSTRUCTION *op)
}
op->opcode = Op_push_i;
- op->memory = mk_number(res, (PERM|NUMCUR|NUMBER));
- n1->flags &= ~PERM;
- n1->flags |= MALLOC;
- n2->flags &= ~PERM;
- n2->flags |= MALLOC;
+ op->memory = make_number(res);
unref(n1);
unref(n2);
bcfree(ip1);
@@ -7641,7 +7358,7 @@ mk_condition(INSTRUCTION *cond, INSTRUCTION *ifp, INSTRUCTION *true_branch,
if (false_branch == NULL) {
false_branch = list_create(instruction(Op_no_op));
if (elsep != NULL) { /* else { } */
- if (do_profiling)
+ if (do_pretty_print)
(void) list_prepend(false_branch, elsep);
else
bcfree(elsep);
@@ -7652,7 +7369,7 @@ mk_condition(INSTRUCTION *cond, INSTRUCTION *ifp, INSTRUCTION *true_branch,
/* avoid a series of no_op's: if .. else if .. else if .. */
if (false_branch->lasti->opcode != Op_no_op)
(void) list_append(false_branch, instruction(Op_no_op));
- if (do_profiling) {
+ if (do_pretty_print) {
(void) list_prepend(false_branch, elsep);
false_branch->nexti->branch_end = false_branch->lasti;
(void) list_prepend(false_branch, instruction(Op_exec_count));
@@ -7667,7 +7384,7 @@ mk_condition(INSTRUCTION *cond, INSTRUCTION *ifp, INSTRUCTION *true_branch,
ip = list_append(cond, instruction(Op_jmp_false));
ip->lasti->target_jmp = false_branch->nexti->nexti;
- if (do_profiling) {
+ if (do_pretty_print) {
(void) list_prepend(ip, ifp);
(void) list_append(ip, instruction(Op_exec_count));
ip->nexti->branch_if = ip->lasti;
@@ -7729,7 +7446,7 @@ append_rule(INSTRUCTION *pattern, INSTRUCTION *action)
if (rule != Rule) {
rp = pattern;
- if (do_profiling)
+ if (do_pretty_print)
(void) list_append(action, instruction(Op_no_op));
(rp + 1)->firsti = action->nexti;
(rp + 1)->lasti = action->lasti;
@@ -7745,7 +7462,7 @@ append_rule(INSTRUCTION *pattern, INSTRUCTION *action)
if (pattern == NULL) {
/* assert(action != NULL); */
- if (do_profiling)
+ if (do_pretty_print)
(void) list_prepend(action, instruction(Op_exec_count));
(rp + 1)->firsti = action->nexti;
(rp + 1)->lasti = tp;
@@ -7761,12 +7478,12 @@ append_rule(INSTRUCTION *pattern, INSTRUCTION *action)
if (action == NULL) {
(rp + 2)->last_line = find_line(pattern, LAST_LINE);
action = list_create(instruction(Op_K_print_rec));
- if (do_profiling)
+ if (do_pretty_print)
(void) list_prepend(action, instruction(Op_exec_count));
} else
(rp + 2)->last_line = lastline;
- if (do_profiling) {
+ if (do_pretty_print) {
(void) list_prepend(pattern, instruction(Op_exec_count));
(void) list_prepend(action, instruction(Op_exec_count));
}
@@ -7846,9 +7563,7 @@ mk_assignment(INSTRUCTION *lhs, INSTRUCTION *rhs, INSTRUCTION *op)
static INSTRUCTION *
optimize_assignment(INSTRUCTION *exp)
{
- INSTRUCTION *i1;
- INSTRUCTION *i2;
- INSTRUCTION *i3;
+ INSTRUCTION *i1, *i2, *i3;
/*
* Optimize assignment statements array[subs] = x; var = x; $n = x;
@@ -7884,7 +7599,7 @@ optimize_assignment(INSTRUCTION *exp)
if ( ! do_optimize
|| ( i1->opcode != Op_assign
&& i1->opcode != Op_field_assign)
- )
+ )
return list_append(exp, instruction(Op_pop));
for (i2 = exp->nexti; i2 != i1; i2 = i2->nexti) {
@@ -7969,13 +7684,26 @@ optimize_assignment(INSTRUCTION *exp)
case Op_push_lhs:
if (i2->nexti == i1
- && i1->opcode == Op_assign
+ && i1->opcode == Op_assign
) {
/* var = .. */
i2->opcode = Op_store_var;
i2->nexti = NULL;
bcfree(i1); /* Op_assign */
exp->lasti = i2; /* update Op_list */
+
+ i3 = exp->nexti;
+ if (i3->opcode == Op_push_i
+ && (i3->memory->flags & INTLSTR) == 0
+ && i3->nexti == i2
+ ) {
+ /* constant initializer */
+ i2->initval = i3->memory;
+ bcfree(i3);
+ exp->nexti = i2;
+ } else
+ i2->initval = NULL;
+
return exp;
}
break;
@@ -8045,7 +7773,7 @@ mk_getline(INSTRUCTION *op, INSTRUCTION *var, INSTRUCTION *redir, int redirtype)
else
ip = list_create(op);
op->into_var = (var != NULL);
- op->redir_type = (redir != NULL) ? redirtype : 0;
+ op->redir_type = (redir != NULL) ? redirtype : redirect_none;
return (asgn == NULL ? ip : list_append(ip, asgn));
}
@@ -8096,7 +7824,7 @@ mk_for_loop(INSTRUCTION *forp, INSTRUCTION *init, INSTRUCTION *cond,
if (init != NULL)
ip = list_merge(init, ip);
- if (do_profiling) {
+ if (do_pretty_print) {
(void) list_append(ip, instruction(Op_exec_count));
(forp + 1)->forloop_cond = pp_cond;
(forp + 1)->forloop_body = ip->lasti;
@@ -8118,7 +7846,7 @@ mk_for_loop(INSTRUCTION *forp, INSTRUCTION *init, INSTRUCTION *cond,
ret = list_append(ip, tbreak);
fix_break_continue(ret, tbreak, tcont);
- if (do_profiling) {
+ if (do_pretty_print) {
forp->target_break = tbreak;
forp->target_continue = tcont;
ret = list_prepend(ret, forp);
@@ -8277,320 +8005,6 @@ fix_break_continue(INSTRUCTION *list, INSTRUCTION *b_target, INSTRUCTION *c_targ
}
}
-
-/* append_symbol --- append symbol to the list of symbols
- * installed in the symbol table.
- */
-
-void
-append_symbol(char *name)
-{
- NODE *hp;
-
- /* N.B.: func_install removes func name and reinstalls it;
- * and we get two entries for it here!. destroy_symbol()
- * will find and destroy the Node_func which is what we want.
- */
-
- getnode(hp);
- hp->hname = name; /* shallow copy */
- hp->hnext = symbol_list->hnext;
- symbol_list->hnext = hp;
-}
-
-/* release_symbol --- free symbol list and optionally remove symbol from symbol table */
-
-void
-release_symbols(NODE *symlist, int keep_globals)
-{
- NODE *hp, *n;
-
- for (hp = symlist->hnext; hp != NULL; hp = n) {
- if (! keep_globals) {
- /* destroys globals, function, and params
- * if still in symbol table and not removed by func_install
- * due to syntax error.
- */
- destroy_symbol(hp->hname);
- }
- n = hp->hnext;
- freenode(hp);
- }
- symlist->hnext = NULL;
-}
-
-/* destroy_symbol --- remove a symbol from symbol table
-* and free all associated memory.
-*/
-
-void
-destroy_symbol(char *name)
-{
- NODE *symbol, *hp;
-
- symbol = lookup(name);
- if (symbol == NULL)
- return;
-
- if (symbol->type == Node_func) {
- char **varnames;
- NODE *func, *n;
-
- func = symbol;
- varnames = func->parmlist;
- if (varnames != NULL)
- efree(varnames);
-
- /* function parameters of type Node_param_list */
- for (n = func->lnode->rnode; n != NULL; ) {
- NODE *np;
- np = n->rnode;
- efree(n->param);
- freenode(n);
- n = np;
- }
- freenode(func->lnode);
- func_count--;
-
- } else if (symbol->type == Node_var_array)
- assoc_clear(symbol);
- else if (symbol->type == Node_var)
- unref(symbol->var_value);
-
- /* remove from symbol table */
- hp = remove_symbol(name);
- efree(hp->hname);
- freenode(hp->hvalue);
- freenode(hp);
-}
-
-#define pool_size d.dl
-#define freei x.xi
-static INSTRUCTION *pool_list;
-static AWK_CONTEXT *curr_ctxt = NULL;
-
-/* new_context --- create a new execution context. */
-
-AWK_CONTEXT *
-new_context()
-{
- AWK_CONTEXT *ctxt;
-
- emalloc(ctxt, AWK_CONTEXT *, sizeof(AWK_CONTEXT), "new_context");
- memset(ctxt, 0, sizeof(AWK_CONTEXT));
- ctxt->srcfiles.next = ctxt->srcfiles.prev = &ctxt->srcfiles;
- ctxt->rule_list.opcode = Op_list;
- ctxt->rule_list.lasti = &ctxt->rule_list;
- return ctxt;
-}
-
-/* set_context --- change current execution context. */
-
-static void
-set_context(AWK_CONTEXT *ctxt)
-{
- pool_list = &ctxt->pools;
- symbol_list = &ctxt->symbols;
- srcfiles = &ctxt->srcfiles;
- rule_list = &ctxt->rule_list;
- install_func = ctxt->install_func;
- curr_ctxt = ctxt;
-}
-
-/*
- * push_context:
- *
- * Switch to the given context after saving the current one. The set
- * of active execution contexts forms a stack; the global or main context
- * is at the bottom of the stack.
- */
-
-void
-push_context(AWK_CONTEXT *ctxt)
-{
- ctxt->prev = curr_ctxt;
- /* save current source and sourceline */
- if (curr_ctxt != NULL) {
- curr_ctxt->sourceline = sourceline;
- curr_ctxt->source = source;
- }
- sourceline = 0;
- source = NULL;
- set_context(ctxt);
-}
-
-/* pop_context --- switch to previous execution context. */
-
-void
-pop_context()
-{
- AWK_CONTEXT *ctxt;
-
- assert(curr_ctxt != NULL);
- ctxt = curr_ctxt->prev;
- /* restore source and sourceline */
- sourceline = ctxt->sourceline;
- source = ctxt->source;
- set_context(ctxt);
-}
-
-/* in_main_context --- are we in the main context ? */
-
-int
-in_main_context()
-{
- assert(curr_ctxt != NULL);
- return (curr_ctxt->prev == NULL);
-}
-
-/* free_context --- free context structure and related data. */
-
-void
-free_context(AWK_CONTEXT *ctxt, int keep_globals)
-{
- SRCFILE *s, *sn;
-
- if (ctxt == NULL)
- return;
-
- assert(curr_ctxt != ctxt);
-
- /* free all code including function codes */
- free_bcpool(&ctxt->pools);
- /* free symbols */
- release_symbols(&ctxt->symbols, keep_globals);
- /* free srcfiles */
- for (s = &ctxt->srcfiles; s != &ctxt->srcfiles; s = sn) {
- sn = s->next;
- if (s->stype != SRC_CMDLINE && s->stype != SRC_STDIN)
- efree(s->fullpath);
- efree(s->src);
- efree(s);
- }
- efree(ctxt);
-}
-
-/* free_bc_internal --- free internal memory of an instruction. */
-
-static void
-free_bc_internal(INSTRUCTION *cp)
-{
- NODE *m;
-
- switch(cp->opcode) {
- case Op_func_call:
- if (cp->func_name != NULL
- && cp->func_name != builtin_func
- )
- efree(cp->func_name);
- break;
- case Op_push_re:
- case Op_match_rec:
- case Op_match:
- case Op_nomatch:
- m = cp->memory;
- if (m->re_reg != NULL)
- refree(m->re_reg);
- if (m->re_exp != NULL)
- unref(m->re_exp);
- if (m->re_text != NULL)
- unref(m->re_text);
- freenode(m);
- break;
- case Op_token: /* token lost during error recovery in yyparse */
- if (cp->lextok != NULL)
- efree(cp->lextok);
- break;
- case Op_illegal:
- cant_happen();
- default:
- break;
- }
-}
-
-
-/* INSTR_CHUNK must be > largest code size (3) */
-#define INSTR_CHUNK 127
-
-/* bcfree --- deallocate instruction */
-
-void
-bcfree(INSTRUCTION *cp)
-{
- cp->opcode = 0;
- cp->nexti = pool_list->freei;
- pool_list->freei = cp;
-}
-
-/* bcalloc --- allocate a new instruction */
-
-INSTRUCTION *
-bcalloc(OPCODE op, int size, int srcline)
-{
- INSTRUCTION *cp;
-
- if (size > 1) {
- /* wide instructions Op_rule, Op_func_call .. */
- emalloc(cp, INSTRUCTION *, (size + 1) * sizeof(INSTRUCTION), "bcalloc");
- cp->pool_size = size;
- cp->nexti = pool_list->nexti;
- pool_list->nexti = cp++;
- } else {
- INSTRUCTION *pool;
-
- pool = pool_list->freei;
- if (pool == NULL) {
- INSTRUCTION *last;
- emalloc(cp, INSTRUCTION *, (INSTR_CHUNK + 1) * sizeof(INSTRUCTION), "bcalloc");
-
- cp->pool_size = INSTR_CHUNK;
- cp->nexti = pool_list->nexti;
- pool_list->nexti = cp;
- pool = ++cp;
- last = &pool[INSTR_CHUNK - 1];
- for (; cp <= last; cp++) {
- cp->opcode = 0;
- cp->nexti = cp + 1;
- }
- --cp;
- cp->nexti = NULL;
- }
- cp = pool;
- pool_list->freei = cp->nexti;
- }
-
- memset(cp, 0, size * sizeof(INSTRUCTION));
- cp->opcode = op;
- cp->source_line = srcline;
- return cp;
-}
-
-/* free_bcpool --- free list of instruction memory pools */
-
-static void
-free_bcpool(INSTRUCTION *pl)
-{
- INSTRUCTION *pool, *tmp;
-
- for (pool = pl->nexti; pool != NULL; pool = tmp) {
- INSTRUCTION *cp, *last;
- long psiz;
- psiz = pool->pool_size;
- if (psiz == INSTR_CHUNK)
- last = pool + psiz;
- else
- last = pool + 1;
- for (cp = pool + 1; cp <= last ; cp++) {
- if (cp->opcode != 0)
- free_bc_internal(cp);
- }
- tmp = pool->nexti;
- efree(pool);
- }
- memset(pl, 0, sizeof(INSTRUCTION));
-}
-
-
static inline INSTRUCTION *
list_create(INSTRUCTION *x)
{
@@ -8728,3 +8142,4 @@ one_line_close(int fd)
}
+
diff --git a/awkgram.y b/awkgram.y
index f5d104d7..22d8889d 100644
--- a/awkgram.y
+++ b/awkgram.y
@@ -42,19 +42,15 @@ static char *get_src_buf(void);
static int yylex(void);
int yyparse(void);
static INSTRUCTION *snode(INSTRUCTION *subn, INSTRUCTION *op);
-static int func_install(INSTRUCTION *fp, INSTRUCTION *def);
-static void pop_params(NODE *params);
-static NODE *make_param(char *pname);
+static char **check_params(char *fname, int pcount, INSTRUCTION *list);
+static int install_function(char *fname, INSTRUCTION *fi, INSTRUCTION *plist);
static NODE *mk_rexp(INSTRUCTION *exp);
-static void append_param(char *pname);
-static int dup_parms(INSTRUCTION *fp, NODE *func);
static void param_sanity(INSTRUCTION *arglist);
static int parms_shadow(INSTRUCTION *pc, int *shadow);
static int isnoeffect(OPCODE type);
static INSTRUCTION *make_assignable(INSTRUCTION *ip);
static void dumpintlstr(const char *str, size_t len);
static void dumpintlstr2(const char *str1, size_t len1, const char *str2, size_t len2);
-static int isarray(NODE *n);
static int include_source(INSTRUCTION *file);
static void next_sourcefile(void);
static char *tokexpand(void);
@@ -63,6 +59,7 @@ static char *tokexpand(void);
static INSTRUCTION *mk_program(void);
static INSTRUCTION *append_rule(INSTRUCTION *pattern, INSTRUCTION *action);
+static INSTRUCTION *mk_function(INSTRUCTION *fi, INSTRUCTION *def);
static INSTRUCTION *mk_condition(INSTRUCTION *cond, INSTRUCTION *ifp, INSTRUCTION *true_branch,
INSTRUCTION *elsep, INSTRUCTION *false_branch);
static INSTRUCTION *mk_expression_list(INSTRUCTION *list, INSTRUCTION *s1);
@@ -81,16 +78,13 @@ static void add_lint(INSTRUCTION *list, LINTTYPE linttype);
enum defref { FUNC_DEFINE, FUNC_USE };
static void func_use(const char *name, enum defref how);
static void check_funcs(void);
-static void free_bcpool(INSTRUCTION *pl);
static ssize_t read_one_line(int fd, void *buffer, size_t count);
static int one_line_close(int fd);
-static void (*install_func)(char *) = NULL;
-
static int want_source = FALSE;
static int want_regexp; /* lexical scanning kludge */
-static int can_return; /* parsing kludge */
+static char *in_function; /* parsing kludge */
static int rule = 0;
const char *const ruletab[] = {
@@ -125,27 +119,17 @@ static int continue_allowed; /* kludge for continue */
#define END_SRC -2000
#define YYDEBUG_LEXER_TEXT (lexeme)
-static int param_counter;
-static NODE *func_params; /* list of parameters for the current function */
static char *tokstart = NULL;
static char *tok = NULL;
static char *tokend;
static int errcount = 0;
-static NODE *symbol_list;
-extern void destroy_symbol(char *name);
-
-static long func_count; /* total number of functions */
-
-#define HASHSIZE 1021 /* this constant only used here */
-NODE *variables[HASHSIZE];
-static int var_count; /* total number of global variables */
-
extern char *source;
extern int sourceline;
extern SRCFILE *srcfiles;
extern INSTRUCTION *rule_list;
extern int max_args;
+extern NODE **args_array;
static INSTRUCTION *rule_block[sizeof(ruletab)];
@@ -162,16 +146,6 @@ static inline INSTRUCTION *list_prepend(INSTRUCTION *l, INSTRUCTION *x);
static inline INSTRUCTION *list_merge(INSTRUCTION *l1, INSTRUCTION *l2);
extern double fmod(double x, double y);
-/*
- * This string cannot occur as a real awk identifier.
- * Use it as a special token to make function parsing
- * uniform, but if it's seen, don't install the function.
- * e.g.
- * function split(x) { return x }
- * function x(a) { return a }
- * should only produce one error message, and not core dump.
- */
-static char builtin_func[] = "@builtin";
#define YYSTYPE INSTRUCTION *
%}
@@ -256,10 +230,8 @@ rule
}
| function_prologue action
{
- can_return = FALSE;
- if ($1 && func_install($1, $2) < 0)
- YYABORT;
- func_params = NULL;
+ in_function = NULL;
+ (void) mk_function($1, $2);
yyerrok;
}
| '@' LEX_INCLUDE source statement_term
@@ -297,7 +269,7 @@ pattern
add_lint($4, LINT_assign_in_cond);
tp = instruction(Op_no_op);
- list_prepend($1, bcalloc(Op_line_range, !!do_profiling + 1, 0));
+ list_prepend($1, bcalloc(Op_line_range, !!do_pretty_print + 1, 0));
$1->nexti->triggered = FALSE;
$1->nexti->target_jmp = $4->nexti;
@@ -308,7 +280,7 @@ pattern
list_append($4, instruction(Op_cond_pair));
$4->lasti->line_range = $1->nexti;
$4->lasti->target_jmp = tp;
- if (do_profiling) {
+ if (do_pretty_print) {
($1->nexti + 1)->condpair_left = $1->lasti;
($1->nexti + 1)->condpair_right = $4->lasti;
}
@@ -369,13 +341,8 @@ func_name
| lex_builtin
{
yyerror(_("`%s' is a built-in function, it cannot be redefined"),
- tokstart);
- $1->opcode = Op_symbol; /* Op_symbol instead of Op_token so that
- * free_bc_internal does not try to free it
- */
- $1->lextok = builtin_func;
- $$ = $1;
- /* yyerrok; */
+ tokstart);
+ YYABORT;
}
| '@' LEX_EVAL
{ $$ = $2; }
@@ -387,28 +354,17 @@ lex_builtin
;
function_prologue
- : LEX_FUNCTION
+ : LEX_FUNCTION func_name '(' opt_param_list r_paren opt_nls
{
- param_counter = 0;
- func_params = NULL;
+ $1->source_file = source;
+ if (install_function($2->lextok, $1, $4) < 0)
+ YYABORT;
+ in_function = $2->lextok;
+ $2->lextok = NULL;
+ bcfree($2);
+ /* $4 already free'd in install_function */
+ $$ = $1;
}
- func_name '(' opt_param_list r_paren opt_nls
- {
- NODE *t;
-
- $1->source_file = source;
- t = make_param($3->lextok);
- $3->lextok = NULL;
- bcfree($3);
- t->flags |= FUNC;
- t->rnode = func_params;
- func_params = t;
- $$ = $1;
- can_return = TRUE;
- /* check for duplicate parameter names */
- if (dup_parms($1, t))
- errcount++;
- }
;
regexp
@@ -425,6 +381,7 @@ regexp
size_t len;
re = $3->lextok;
+ $3->lextok = NULL;
len = strlen(re);
if (do_lint) {
if (len == 0)
@@ -486,7 +443,7 @@ statement
{ $$ = $2; }
| if_statement
{
- if (do_profiling)
+ if (do_pretty_print)
$$ = list_prepend($1, instruction(Op_exec_count));
else
$$ = $1;
@@ -550,7 +507,7 @@ statement
else
dflt->target_jmp = casestmt->nexti;
- if (do_profiling) {
+ if (do_pretty_print) {
curr->stmt_start = casestmt->nexti;
curr->stmt_end = casestmt->lasti;
(void) list_prepend(cexp, curr);
@@ -565,7 +522,7 @@ statement
efree(case_values);
ip = $3;
- if (do_profiling) {
+ if (do_pretty_print) {
(void) list_prepend(ip, $1);
(void) list_prepend(ip, instruction(Op_exec_count));
$1->target_break = tbreak;
@@ -604,7 +561,7 @@ statement
ip = list_append($3, instruction(Op_jmp_false));
ip->lasti->target_jmp = tbreak;
- if (do_profiling) {
+ if (do_pretty_print) {
(void) list_append(ip, instruction(Op_exec_count));
$1->target_break = tbreak;
$1->target_continue = tcont;
@@ -646,7 +603,7 @@ statement
ip = list_merge($3, $6);
else
ip = list_prepend($6, instruction(Op_no_op));
- if (do_profiling)
+ if (do_pretty_print)
(void) list_prepend(ip, instruction(Op_exec_count));
(void) list_append(ip, instruction(Op_jmp_true));
ip->lasti->target_jmp = ip->nexti;
@@ -656,7 +613,7 @@ statement
continue_allowed--;
fix_break_continue(ip, tbreak, tcont);
- if (do_profiling) {
+ if (do_pretty_print) {
$1->target_break = tbreak;
$1->target_continue = tcont;
($1 + 1)->doloop_cond = tcont;
@@ -716,30 +673,30 @@ statement
} else {
INSTRUCTION *tbreak, *tcont;
- /* [ Op_push_array a ]
- * [ Op_arrayfor_init | ib ]
- * ic:[ Op_arrayfor_incr | ib ]
- * [ Op_var_assign if any ]
- *
- * body
- *
- * [Op_jmp | ic ]
- * ib:[Op_arrayfor_final ]
- */
+ /* [ Op_push_array a ]
+ * [ Op_arrayfor_init | ib ]
+ * ic:[ Op_arrayfor_incr | ib ]
+ * [ Op_var_assign if any ]
+ *
+ * body
+ *
+ * [Op_jmp | ic ]
+ * ib:[Op_arrayfor_final ]
+ */
regular_loop:
ip = $5;
ip->nexti->opcode = Op_push_array;
tbreak = instruction(Op_arrayfor_final);
$4->opcode = Op_arrayfor_incr;
- $4->array_var = variable(var_name, Node_var);
+ $4->array_var = variable($3->source_line, var_name, Node_var);
$4->target_jmp = tbreak;
tcont = $4;
$3->opcode = Op_arrayfor_init;
$3->target_jmp = tbreak;
(void) list_append(ip, $3);
- if (do_profiling) {
+ if (do_pretty_print) {
$1->opcode = Op_K_arrayfor;
$1->target_continue = tcont;
$1->target_break = tbreak;
@@ -760,7 +717,7 @@ regular_loop:
ip->lasti->assign_var = $4->array_var->var_assign;
}
- if (do_profiling) {
+ if (do_pretty_print) {
(void) list_append(ip, instruction(Op_exec_count));
($1 + 1)->forloop_cond = $4;
($1 + 1)->forloop_body = ip->lasti;
@@ -794,7 +751,7 @@ regular_loop:
}
| non_compound_stmt
{
- if (do_profiling)
+ if (do_pretty_print)
$$ = list_prepend($1, instruction(Op_exec_count));
else
$$ = $1;
@@ -855,21 +812,33 @@ non_compound_stmt
if ($2 == NULL) {
$$ = list_create($1);
(void) list_prepend($$, instruction(Op_push_i));
- $$->nexti->memory = Nnull_string;
+ $$->nexti->memory = dupnode(Nnull_string);
} else
$$ = list_append($2, $1);
}
| LEX_RETURN
{
- if (! can_return)
+ if (! in_function)
yyerror(_("`return' used outside function context"));
} opt_exp statement_term {
if ($3 == NULL) {
$$ = list_create($1);
(void) list_prepend($$, instruction(Op_push_i));
- $$->nexti->memory = Nnull_string;
- } else
+ $$->nexti->memory = dupnode(Nnull_string);
+ } else {
+ if (do_optimize > 1
+ && $3->lasti->opcode == Op_func_call
+ && strcmp($3->lasti->func_name, in_function) == 0
+ ) {
+ /* Do tail recursion optimization. Tail
+ * call without a return value is recognized
+ * in mk_function().
+ */
+ ($3->lasti + 1)->tail_call = TRUE;
+ }
+
$$ = list_append($3, $1);
+ }
}
| simple_stmt statement_term
;
@@ -892,13 +861,12 @@ simple_stmt
*/
if ($1->opcode == Op_K_print &&
- ($3 == NULL
- || ($3->lasti->opcode == Op_field_spec
- && $3->nexti->nexti->nexti == $3->lasti
- && $3->nexti->nexti->opcode == Op_push_i
- && $3->nexti->nexti->memory->type == Node_val
- && $3->nexti->nexti->memory->numbr == 0.0)
- )
+ ($3 == NULL
+ || ($3->lasti->opcode == Op_field_spec
+ && $3->nexti->nexti->nexti == $3->lasti
+ && $3->nexti->nexti->opcode == Op_push_i
+ && $3->nexti->nexti->memory->type == Node_val)
+ )
) {
static short warned = FALSE;
/* -----------------
@@ -911,13 +879,16 @@ simple_stmt
*/
if ($3 != NULL) {
- bcfree($3->lasti); /* Op_field_spec */
- $3->nexti->nexti->memory->flags &= ~PERM;
- $3->nexti->nexti->memory->flags |= MALLOC;
- unref($3->nexti->nexti->memory); /* Node_val */
+ NODE *n = $3->nexti->nexti->memory;
+
+ if (! iszero(n))
+ goto regular_print;
+
+ bcfree($3->lasti); /* Op_field_spec */
+ unref(n); /* Node_val */
bcfree($3->nexti->nexti); /* Op_push_i */
- bcfree($3->nexti); /* Op_list */
- bcfree($3); /* Op_list */
+ bcfree($3->nexti); /* Op_list */
+ bcfree($3); /* Op_list */
} else {
if (do_lint && (rule == BEGIN || rule == END) && ! warned) {
warned = TRUE;
@@ -929,7 +900,7 @@ simple_stmt
$1->expr_count = 0;
$1->opcode = Op_K_print_rec;
if ($4 == NULL) { /* no redircetion */
- $1->redir_type = 0;
+ $1->redir_type = redirect_none;
$$ = list_create($1);
} else {
INSTRUCTION *ip;
@@ -949,16 +920,16 @@ simple_stmt
* [$1 | NULL | redir_type | expr_count]
*
*/
-
+regular_print:
if ($4 == NULL) { /* no redirection */
if ($3 == NULL) { /* printf without arg */
$1->expr_count = 0;
- $1->redir_type = 0;
+ $1->redir_type = redirect_none;
$$ = list_create($1);
} else {
INSTRUCTION *t = $3;
$1->expr_count = count_expressions(&t, FALSE);
- $1->redir_type = 0;
+ $1->redir_type = redirect_none;
$$ = list_append(t, $1);
}
} else {
@@ -984,7 +955,7 @@ simple_stmt
char *arr = $2->lextok;
$2->opcode = Op_push_array;
- $2->memory = variable(arr, Node_var_new);
+ $2->memory = variable($2->source_line, arr, Node_var_new);
if ($4 == NULL) {
static short warned = FALSE;
@@ -1022,7 +993,7 @@ simple_stmt
error_ln($1->source_line,
_("`delete array' is a gawk extension"));
}
- $3->memory = variable(arr, Node_var_new);
+ $3->memory = variable($3->source_line, arr, Node_var_new);
$3->opcode = Op_push_array;
$1->expr_count = 0;
$$ = list_append(list_create($3), $1);
@@ -1058,7 +1029,7 @@ case_statement
INSTRUCTION *casestmt = $5;
if ($5 == NULL)
casestmt = list_create(instruction(Op_no_op));
- if (do_profiling)
+ if (do_pretty_print)
(void) list_prepend(casestmt, instruction(Op_exec_count));
$1->case_exp = $2;
$1->case_stmt = casestmt;
@@ -1070,7 +1041,7 @@ case_statement
INSTRUCTION *casestmt = $4;
if ($4 == NULL)
casestmt = list_create(instruction(Op_no_op));
- if (do_profiling)
+ if (do_pretty_print)
(void) list_prepend(casestmt, instruction(Op_exec_count));
bcfree($2);
$1->case_stmt = casestmt;
@@ -1083,7 +1054,9 @@ case_value
{ $$ = $1; }
| '-' YNUMBER %prec UNARY
{
- $2->memory->numbr = -(force_number($2->memory));
+ NODE *n = $2->memory;
+ (void) force_number(n);
+ negate_num(n);
bcfree($1);
$$ = $2;
}
@@ -1171,29 +1144,29 @@ input_redir
opt_param_list
: /* empty */
+ { $$ = NULL; }
| param_list
+ { $$ = $1 ; }
;
param_list
: NAME
{
- append_param($1->lextok);
- $1->lextok = NULL;
- bcfree($1);
+ $1->param_count = 0;
+ $$ = list_create($1);
}
| param_list comma NAME
{
- append_param($3->lextok);
- $3->lextok = NULL;
- bcfree($3);
+ $3->param_count = $1->lasti->param_count + 1;
+ $$ = list_append($1, $3);
yyerrok;
}
| error
- { /* func_params = NULL; */ }
+ { $$ = NULL; }
| param_list error
- { /* func_params = NULL; */ }
+ { $$ = $1; }
| param_list comma error
- { /* func_params = NULL; */ }
+ { $$ = $1; }
;
/* optional expression, as in for loop */
@@ -1261,7 +1234,7 @@ exp
| exp LEX_IN simple_variable
{
if (do_lint_old)
- warning_ln($2->source_line,
+ warning_ln($2->source_line,
_("old awk does not support the keyword `in' except after `for'"));
$3->nexti->opcode = Op_push_array;
$2->opcode = Op_in_array;
@@ -1324,32 +1297,29 @@ common_exp
$1->lasti->opcode = Op_no_op;
} else {
is_simple_var = ($1->nexti->opcode == Op_push
- && $1->lasti == $1->nexti); /* first exp. is a simple
- * variable?; kludge for use
- * in Op_assign_concat.
- */
+ && $1->lasti == $1->nexti); /* first exp. is a simple
+ * variable?; kludge for use
+ * in Op_assign_concat.
+ */
}
if (do_optimize > 1
- && $1->nexti == $1->lasti && $1->nexti->opcode == Op_push_i
- && $2->nexti == $2->lasti && $2->nexti->opcode == Op_push_i
+ && $1->nexti == $1->lasti && $1->nexti->opcode == Op_push_i
+ && $2->nexti == $2->lasti && $2->nexti->opcode == Op_push_i
) {
NODE *n1 = $1->nexti->memory;
NODE *n2 = $2->nexti->memory;
size_t nlen;
- (void) force_string(n1);
- (void) force_string(n2);
+ n1 = force_string(n1);
+ n2 = force_string(n2);
nlen = n1->stlen + n2->stlen;
erealloc(n1->stptr, char *, nlen + 2, "constant fold");
memcpy(n1->stptr + n1->stlen, n2->stptr, n2->stlen);
n1->stlen = nlen;
n1->stptr[nlen] = '\0';
- n1->flags &= ~(NUMCUR|NUMBER);
+ n1->flags &= ~(NUMCUR|NUMBER|NUMINT);
n1->flags |= (STRING|STRCUR);
-
- n2->flags &= ~PERM;
- n2->flags |= MALLOC;
unref(n2);
bcfree($2->nexti);
bcfree($2);
@@ -1467,12 +1437,13 @@ non_post_simp_exp
if ($2->opcode == Op_match_rec) {
$2->opcode = Op_nomatch;
$1->opcode = Op_push_i;
- $1->memory = mk_number(0.0, (PERM|NUMCUR|NUMBER));
+ $1->memory = make_number(0.0);
$$ = list_append(list_append(list_create($1),
- instruction(Op_field_spec)), $2);
+ instruction(Op_field_spec)), $2);
} else {
if (do_optimize > 1 && $2->nexti == $2->lasti
- && $2->nexti->opcode == Op_push_i
+ && $2->nexti->opcode == Op_push_i
+ && ($2->nexti->memory->flags & (MPFN|MPZN)) == 0
) {
NODE *n = $2->nexti->memory;
if ((n->flags & (STRCUR|STRING)) != 0) {
@@ -1543,8 +1514,11 @@ non_post_simp_exp
| '-' simp_exp %prec UNARY
{
if ($2->lasti->opcode == Op_push_i
- && ($2->lasti->memory->flags & (STRCUR|STRING)) == 0) {
- $2->lasti->memory->numbr = -(force_number($2->lasti->memory));
+ && ($2->lasti->memory->flags & (STRCUR|STRING)) == 0
+ ) {
+ NODE *n = $2->lasti->memory;
+ (void) force_number(n);
+ negate_num(n);
$$ = $2;
bcfree($1);
} else {
@@ -1559,7 +1533,7 @@ non_post_simp_exp
* POSIX semantics: force a conversion to numeric type
*/
$1->opcode = Op_plus_i;
- $1->memory = mk_number((AWKNUM) 0.0, (PERM|NUMCUR|NUMBER));
+ $1->memory = make_number(0.0);
$$ = list_append($2, $1);
}
;
@@ -1591,7 +1565,7 @@ func_call
name = estrdup(f->func_name, strlen(f->func_name));
if (is_std_var(name))
yyerror(_("can not use special variable `%s' for indirect function call"), name);
- indirect_var = variable(name, Node_var_new);
+ indirect_var = variable(f->source_line, name, Node_var_new);
t = instruction(Op_push);
t->memory = indirect_var;
@@ -1671,7 +1645,7 @@ bracketed_exp_list
_("invalid subscript expression"));
/* install Null string as subscript. */
t = list_create(instruction(Op_push_i));
- t->nexti->memory = Nnull_string;
+ t->nexti->memory = dupnode(Nnull_string);
$3->sub_count = 1;
} else
$3->sub_count = count_expressions(&t, FALSE);
@@ -1699,17 +1673,13 @@ simple_variable
char *var_name = $1->lextok;
$1->opcode = Op_push;
- $1->memory = variable(var_name, Node_var_new);
+ $1->memory = variable($1->source_line, var_name, Node_var_new);
$$ = list_create($1);
}
| NAME subscript_list
{
- NODE *n;
-
char *arr = $1->lextok;
- if ((n = lookup(arr)) != NULL && ! isarray(n))
- yyerror(_("use of non-array as array"));
- $1->memory = variable(arr, Node_var_new);
+ $1->memory = variable($1->source_line, arr, Node_var_new);
$1->opcode = Op_push_array;
$$ = list_prepend($2, $1);
}
@@ -1720,8 +1690,8 @@ variable
{
INSTRUCTION *ip = $1->nexti;
if (ip->opcode == Op_push
- && ip->memory->type == Node_var
- && ip->memory->var_update
+ && ip->memory->type == Node_var
+ && ip->memory->var_update
) {
$$ = list_prepend($1, instruction(Op_var_update));
$$->nexti->update_var = ip->memory->var_update;
@@ -1732,7 +1702,7 @@ variable
{
$$ = list_append($2, $1);
if ($3 != NULL)
- mk_assignment($2, NULL, $3);
+ mk_assignment($2, NULL, $3);
}
;
@@ -1794,6 +1764,7 @@ struct token {
# define CONTINUE 0x2000 /* continue allowed inside */
NODE *(*ptr)(int); /* function that implements this keyword */
+ NODE *(*ptr2)(int); /* alternate arbitrary-precision function */
};
#if 'a' == 0x81 /* it's EBCDIC */
@@ -1817,81 +1788,84 @@ tokcompare(const void *l, const void *r)
* Function pointers come from declarations in awk.h.
*/
+#ifdef HAVE_MPFR
+#define MPF(F) do_mpfr_##F
+#else
+#define MPF(F) 0
+#endif
+
static const struct token tokentab[] = {
-{"BEGIN", Op_rule, LEX_BEGIN, 0, 0},
-{"BEGINFILE", Op_rule, LEX_BEGINFILE, GAWKX, 0},
-{"END", Op_rule, LEX_END, 0, 0},
-{"ENDFILE", Op_rule, LEX_ENDFILE, GAWKX, 0},
+{"BEGIN", Op_rule, LEX_BEGIN, 0, 0, 0},
+{"BEGINFILE", Op_rule, LEX_BEGINFILE, GAWKX, 0, 0},
+{"END", Op_rule, LEX_END, 0, 0, 0},
+{"ENDFILE", Op_rule, LEX_ENDFILE, GAWKX, 0, 0},
#ifdef ARRAYDEBUG
-{"adump", Op_builtin, LEX_BUILTIN, GAWKX|A(1), do_adump},
+{"adump", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2), do_adump, 0},
#endif
-{"and", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_and},
-{"asort", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2)|A(3), do_asort},
-{"asorti", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2)|A(3), do_asorti},
-{"atan2", Op_builtin, LEX_BUILTIN, NOT_OLD|A(2), do_atan2},
-{"bindtextdomain", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2), do_bindtextdomain},
-{"break", Op_K_break, LEX_BREAK, 0, 0},
-{"case", Op_K_case, LEX_CASE, GAWKX, 0},
-{"close", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1)|A(2), do_close},
-{"compl", Op_builtin, LEX_BUILTIN, GAWKX|A(1), do_compl},
-{"continue", Op_K_continue, LEX_CONTINUE, 0, 0},
-{"cos", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_cos},
-{"dcgettext", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2)|A(3), do_dcgettext},
-{"dcngettext", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2)|A(3)|A(4)|A(5), do_dcngettext},
-{"default", Op_K_default, LEX_DEFAULT, GAWKX, 0},
-{"delete", Op_K_delete, LEX_DELETE, NOT_OLD, 0},
-{"do", Op_K_do, LEX_DO, NOT_OLD|BREAK|CONTINUE, 0},
-{"else", Op_K_else, LEX_ELSE, 0, 0},
-{"eval", Op_symbol, LEX_EVAL, 0, 0},
-{"exit", Op_K_exit, LEX_EXIT, 0, 0},
-{"exp", Op_builtin, LEX_BUILTIN, A(1), do_exp},
-{"extension", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_ext},
-{"fflush", Op_builtin, LEX_BUILTIN, RESX|A(0)|A(1), do_fflush},
-{"for", Op_K_for, LEX_FOR, BREAK|CONTINUE, 0},
-{"func", Op_func, LEX_FUNCTION, NOT_POSIX|NOT_OLD, 0},
-{"function",Op_func, LEX_FUNCTION, NOT_OLD, 0},
-{"gensub", Op_sub_builtin, LEX_BUILTIN, GAWKX|A(3)|A(4), 0},
-{"getline", Op_K_getline_redir, LEX_GETLINE, NOT_OLD, 0},
-{"gsub", Op_sub_builtin, LEX_BUILTIN, NOT_OLD|A(2)|A(3), 0},
-{"if", Op_K_if, LEX_IF, 0, 0},
-{"in", Op_symbol, LEX_IN, 0, 0},
-{"include", Op_symbol, LEX_INCLUDE, GAWKX, 0},
-{"index", Op_builtin, LEX_BUILTIN, A(2), do_index},
-{"int", Op_builtin, LEX_BUILTIN, A(1), do_int},
-{"isarray", Op_builtin, LEX_BUILTIN, GAWKX|A(1), do_isarray},
-{"length", Op_builtin, LEX_LENGTH, A(0)|A(1), do_length},
-{"log", Op_builtin, LEX_BUILTIN, A(1), do_log},
-{"lshift", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_lshift},
-{"match", Op_builtin, LEX_BUILTIN, NOT_OLD|A(2)|A(3), do_match},
-{"mktime", Op_builtin, LEX_BUILTIN, GAWKX|A(1), do_mktime},
-{"next", Op_K_next, LEX_NEXT, 0, 0},
-{"nextfile", Op_K_nextfile, LEX_NEXTFILE, GAWKX, 0},
-{"or", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_or},
-{"patsplit", Op_builtin, LEX_BUILTIN, GAWKX|A(2)|A(3)|A(4), do_patsplit},
-{"print", Op_K_print, LEX_PRINT, 0, 0},
-{"printf", Op_K_printf, LEX_PRINTF, 0, 0},
-{"rand", Op_builtin, LEX_BUILTIN, NOT_OLD|A(0), do_rand},
-{"return", Op_K_return, LEX_RETURN, NOT_OLD, 0},
-{"rshift", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_rshift},
-{"sin", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_sin},
-{"split", Op_builtin, LEX_BUILTIN, A(2)|A(3)|A(4), do_split},
-{"sprintf", Op_builtin, LEX_BUILTIN, 0, do_sprintf},
-{"sqrt", Op_builtin, LEX_BUILTIN, A(1), do_sqrt},
-{"srand", Op_builtin, LEX_BUILTIN, NOT_OLD|A(0)|A(1), do_srand},
-#if defined(GAWKDEBUG) || defined(ARRAYDEBUG) /* || ... */
-{"stopme", Op_builtin, LEX_BUILTIN, GAWKX|A(0), stopme},
-#endif
-{"strftime", Op_builtin, LEX_BUILTIN, GAWKX|A(0)|A(1)|A(2)|A(3), do_strftime},
-{"strtonum", Op_builtin, LEX_BUILTIN, GAWKX|A(1), do_strtonum},
-{"sub", Op_sub_builtin, LEX_BUILTIN, NOT_OLD|A(2)|A(3), 0},
-{"substr", Op_builtin, LEX_BUILTIN, A(2)|A(3), do_substr},
-{"switch", Op_K_switch, LEX_SWITCH, GAWKX|BREAK, 0},
-{"system", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_system},
-{"systime", Op_builtin, LEX_BUILTIN, GAWKX|A(0), do_systime},
-{"tolower", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_tolower},
-{"toupper", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_toupper},
-{"while", Op_K_while, LEX_WHILE, BREAK|CONTINUE, 0},
-{"xor", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_xor},
+{"and", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_and, MPF(and)},
+{"asort", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2)|A(3), do_asort, 0},
+{"asorti", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2)|A(3), do_asorti, 0},
+{"atan2", Op_builtin, LEX_BUILTIN, NOT_OLD|A(2), do_atan2, MPF(atan2)},
+{"bindtextdomain", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2), do_bindtextdomain, 0},
+{"break", Op_K_break, LEX_BREAK, 0, 0, 0},
+{"case", Op_K_case, LEX_CASE, GAWKX, 0, 0},
+{"close", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1)|A(2), do_close, 0},
+{"compl", Op_builtin, LEX_BUILTIN, GAWKX|A(1), do_compl, MPF(compl)},
+{"continue", Op_K_continue, LEX_CONTINUE, 0, 0, 0},
+{"cos", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_cos, MPF(cos)},
+{"dcgettext", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2)|A(3), do_dcgettext, 0},
+{"dcngettext", Op_builtin, LEX_BUILTIN, GAWKX|A(1)|A(2)|A(3)|A(4)|A(5), do_dcngettext, 0},
+{"default", Op_K_default, LEX_DEFAULT, GAWKX, 0, 0},
+{"delete", Op_K_delete, LEX_DELETE, NOT_OLD, 0, 0},
+{"do", Op_K_do, LEX_DO, NOT_OLD|BREAK|CONTINUE, 0, 0},
+{"else", Op_K_else, LEX_ELSE, 0, 0, 0},
+{"eval", Op_symbol, LEX_EVAL, 0, 0, 0},
+{"exit", Op_K_exit, LEX_EXIT, 0, 0, 0},
+{"exp", Op_builtin, LEX_BUILTIN, A(1), do_exp, MPF(exp)},
+{"extension", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_ext, 0},
+{"fflush", Op_builtin, LEX_BUILTIN, RESX|A(0)|A(1), do_fflush, 0},
+{"for", Op_K_for, LEX_FOR, BREAK|CONTINUE, 0, 0},
+{"func", Op_func, LEX_FUNCTION, NOT_POSIX|NOT_OLD, 0, 0},
+{"function",Op_func, LEX_FUNCTION, NOT_OLD, 0, 0},
+{"gensub", Op_sub_builtin, LEX_BUILTIN, GAWKX|A(3)|A(4), 0, 0},
+{"getline", Op_K_getline_redir, LEX_GETLINE, NOT_OLD, 0, 0},
+{"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},
+{"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},
+{"length", Op_builtin, LEX_LENGTH, A(0)|A(1), do_length, 0},
+{"log", Op_builtin, LEX_BUILTIN, A(1), do_log, MPF(log)},
+{"lshift", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_lshift, MPF(lshift)},
+{"match", Op_builtin, LEX_BUILTIN, NOT_OLD|A(2)|A(3), do_match, 0},
+{"mktime", Op_builtin, LEX_BUILTIN, GAWKX|A(1), do_mktime, 0},
+{"next", Op_K_next, LEX_NEXT, 0, 0, 0},
+{"nextfile", Op_K_nextfile, LEX_NEXTFILE, GAWKX, 0, 0},
+{"or", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_or, MPF(or)},
+{"patsplit", Op_builtin, LEX_BUILTIN, GAWKX|A(2)|A(3)|A(4), do_patsplit, 0},
+{"print", Op_K_print, LEX_PRINT, 0, 0, 0},
+{"printf", Op_K_printf, LEX_PRINTF, 0, 0, 0},
+{"rand", Op_builtin, LEX_BUILTIN, NOT_OLD|A(0), do_rand, MPF(rand)},
+{"return", Op_K_return, LEX_RETURN, NOT_OLD, 0, 0},
+{"rshift", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_rshift, MPF(rhift)},
+{"sin", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_sin, MPF(sin)},
+{"split", Op_builtin, LEX_BUILTIN, A(2)|A(3)|A(4), do_split, 0},
+{"sprintf", Op_builtin, LEX_BUILTIN, 0, do_sprintf, 0},
+{"sqrt", Op_builtin, LEX_BUILTIN, A(1), do_sqrt, MPF(sqrt)},
+{"srand", Op_builtin, LEX_BUILTIN, NOT_OLD|A(0)|A(1), do_srand, MPF(srand)},
+{"strftime", Op_builtin, LEX_BUILTIN, GAWKX|A(0)|A(1)|A(2)|A(3), do_strftime, 0},
+{"strtonum", Op_builtin, LEX_BUILTIN, GAWKX|A(1), do_strtonum, MPF(strtonum)},
+{"sub", Op_sub_builtin, LEX_BUILTIN, NOT_OLD|A(2)|A(3), 0, 0},
+{"substr", Op_builtin, LEX_BUILTIN, A(2)|A(3), do_substr, 0},
+{"switch", Op_K_switch, LEX_SWITCH, GAWKX|BREAK, 0, 0},
+{"system", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_system, 0},
+{"systime", Op_builtin, LEX_BUILTIN, GAWKX|A(0), do_systime, 0},
+{"tolower", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_tolower, 0},
+{"toupper", Op_builtin, LEX_BUILTIN, NOT_OLD|A(1), do_toupper, 0},
+{"while", Op_K_while, LEX_WHILE, BREAK|CONTINUE, 0, 0},
+{"xor", Op_builtin, LEX_BUILTIN, GAWKX|A(2), do_xor, MPF(xor)},
};
#if MBS_SUPPORT
@@ -1927,6 +1901,23 @@ getfname(NODE *(*fptr)(int))
return NULL;
}
+/* negate_num --- negate a number in NODE */
+
+void
+negate_num(NODE *n)
+{
+#ifdef HAVE_MPFR
+ if (is_mpg_float(n)) {
+ int tval;
+ tval = mpfr_neg(n->mpg_numbr, n->mpg_numbr, ROUND_MODE);
+ IEEE_FMT(n->mpg_numbr, tval);
+ } else if (is_mpg_integer(n)) {
+ mpz_neg(n->mpg_i, n->mpg_i);
+ } else
+#endif
+ n->numbr = -n->numbr;
+}
+
/* print_included_from --- print `Included from ..' file names and locations */
static void
@@ -1950,7 +1941,7 @@ print_included_from()
line--;
msg("%s %s:%d%c",
s->prev == sourcefile ? "In file included from"
- : " from",
+ : " from",
(s->stype == SRC_INC ||
s->stype == SRC_FILE) ? s->src : "cmd. line",
line,
@@ -2232,7 +2223,10 @@ parse_program(INSTRUCTION **pcode)
ip_atexit = instruction(Op_atexit); /* target for `exit' in END block */
}
- sourcefile = srcfiles->next;
+ for (sourcefile = srcfiles->next; sourcefile->stype == SRC_EXTLIB;
+ sourcefile = sourcefile->next)
+ ;
+
lexeof = FALSE;
lexptr = NULL;
lasttok = 0;
@@ -2249,6 +2243,11 @@ parse_program(INSTRUCTION **pcode)
if (ret == 0) /* avoid spurious warning if parser aborted with YYABORT */
check_funcs();
+ if (args_array == NULL)
+ emalloc(args_array, NODE **, (max_args + 2) * sizeof(NODE *), "parse_program");
+ else
+ erealloc(args_array, NODE **, (max_args + 2) * sizeof(NODE *), "parse_program");
+
return (ret || errcount);
}
@@ -2291,7 +2290,7 @@ add_srcfile(int stype, char *src, SRCFILE *thisfile, int *already_included, int
if (stype == SRC_CMDLINE || stype == SRC_STDIN)
return do_add_srcfile(stype, src, NULL, thisfile);
- path = find_source(src, &sbuf, &errno_val);
+ path = find_source(src, & sbuf, &errno_val, stype == SRC_EXTLIB);
if (path == NULL) {
if (errcode) {
*errcode = errno_val;
@@ -2302,7 +2301,7 @@ add_srcfile(int stype, char *src, SRCFILE *thisfile, int *already_included, int
}
for (s = srcfiles->next; s != srcfiles; s = s->next) {
- if ((s->stype == SRC_FILE || s->stype == SRC_INC)
+ if ((s->stype == SRC_FILE || s->stype == SRC_INC || s->stype == SRC_EXTLIB)
&& files_are_same(path, s)
) {
if (do_lint) {
@@ -2404,6 +2403,7 @@ next_sourcefile()
*
* assert(lexeof == TRUE);
*/
+
lexeof = FALSE;
eof_warned = FALSE;
sourcefile->srclines = sourceline; /* total no of lines in current file */
@@ -2418,9 +2418,12 @@ next_sourcefile()
sourcefile->lexptr_begin = NULL;
}
- sourcefile = sourcefile->next;
- if (sourcefile == srcfiles)
- return;
+ while ((sourcefile = sourcefile->next) != NULL) {
+ if (sourcefile == srcfiles)
+ return;
+ if (sourcefile->stype != SRC_EXTLIB)
+ break;
+ }
if (sourcefile->lexptr_begin != NULL) {
/* resume reading from already opened file (postponed to process '@include') */
@@ -2816,10 +2819,12 @@ yylex(void)
int seen_point = FALSE;
int esc_seen; /* for literal strings */
int mid;
+ int base;
static int did_newline = FALSE;
char *tokkey;
int inhex = FALSE;
int intlstr = FALSE;
+ AWKNUM d;
#define GET_INSTRUCTION(op) bcalloc(op, 1, sourceline)
@@ -3250,9 +3255,7 @@ retry:
yylval->opcode = Op_push_i;
yylval->memory = make_str_node(tokstart,
- tok - tokstart, esc_seen ? SCAN : 0);
- yylval->memory->flags &= ~MALLOC;
- yylval->memory->flags |= PERM;
+ tok - tokstart, esc_seen ? SCAN : 0);
if (intlstr) {
yylval->memory->flags |= INTLSTR;
intlstr = FALSE;
@@ -3385,19 +3388,46 @@ retry:
tokadd('\0');
yylval = GET_INSTRUCTION(Op_push_i);
- if (! do_traditional && isnondecimal(tokstart, FALSE)) {
+
+ base = 10;
+ if (! do_traditional) {
+ base = get_numbase(tokstart, FALSE);
if (do_lint) {
- if (isdigit((unsigned char) tokstart[1])) /* not an 'x' or 'X' */
+ if (base == 8)
lintwarn("numeric constant `%.*s' treated as octal",
(int) strlen(tokstart)-1, tokstart);
- else if (tokstart[1] == 'x' || tokstart[1] == 'X')
+ else if (base == 16)
lintwarn("numeric constant `%.*s' treated as hexadecimal",
(int) strlen(tokstart)-1, tokstart);
}
- yylval->memory = mk_number(nondec2awknum(tokstart, strlen(tokstart)),
- PERM|NUMCUR|NUMBER);
- } else
- yylval->memory = mk_number(atof(tokstart), PERM|NUMCUR|NUMBER);
+ }
+
+#ifdef HAVE_MPFR
+ if (do_mpfr) {
+ NODE *r;
+
+ if (! seen_point && ! seen_e) {
+ r = mpg_integer();
+ mpg_strtoui(r->mpg_i, tokstart, strlen(tokstart), NULL, base);
+ errno = 0;
+ } else {
+ int tval;
+ r = mpg_float();
+ tval = mpfr_strtofr(r->mpg_numbr, tokstart, NULL, base, ROUND_MODE);
+ errno = 0;
+ IEEE_FMT(r->mpg_numbr, tval);
+ }
+ yylval->memory = r;
+ return lasttok = YNUMBER;
+ }
+#endif
+ if (base != 10)
+ d = nondec2awknum(tokstart, strlen(tokstart));
+ else
+ d = atof(tokstart);
+ yylval->memory = make_number(d);
+ if (d <= INT32_MAX && d >= INT32_MIN && d == (int32_t) d)
+ yylval->memory->flags |= NUMINT;
return lasttok = YNUMBER;
case '&':
@@ -3534,7 +3564,7 @@ retry:
case LEX_WHILE:
case LEX_DO:
case LEX_SWITCH:
- if (! do_profiling)
+ if (! do_pretty_print)
return lasttok = class;
/* fall through */
case LEX_CASE:
@@ -3574,23 +3604,6 @@ out:
#undef NEWLINE_EOF
}
-/* mk_symbol --- allocates a symbol for the symbol table. */
-
-NODE *
-mk_symbol(NODETYPE type, NODE *value)
-{
- NODE *r;
-
- getnode(r);
- r->type = type;
- r->flags = MALLOC;
- r->lnode = value;
- r->rnode = NULL;
- r->parent_array = NULL;
- r->var_assign = (Func_ptr) 0;
- return r;
-}
-
/* snode --- instructions for builtin functions. Checks for arg. count
and supplies defaults where possible. */
@@ -3642,7 +3655,7 @@ snode(INSTRUCTION *subn, INSTRUCTION *r)
INSTRUCTION *expr;
expr = list_create(instruction(Op_push_i));
- expr->nexti->memory = mk_number((AWKNUM) 0.0, (PERM|NUMCUR|NUMBER));
+ expr->nexti->memory = make_number(0.0);
(void) mk_expression_list(subn,
list_append(expr, instruction(Op_field_spec)));
}
@@ -3686,7 +3699,7 @@ snode(INSTRUCTION *subn, INSTRUCTION *r)
r->sub_flags |= GENSUB;
if (nexp == 3) {
ip = instruction(Op_push_i);
- ip->memory = mk_number((AWKNUM) 0.0, (PERM|NUMCUR|NUMBER));
+ ip->memory = make_number(0.0);
(void) mk_expression_list(subn,
list_append(list_create(ip), instruction(Op_field_spec)));
}
@@ -3696,7 +3709,13 @@ snode(INSTRUCTION *subn, INSTRUCTION *r)
}
}
- r->builtin = tokentab[idx].ptr;
+#ifdef HAVE_MPFR
+ /* N.B.: There isn't any special processing for an alternate function below */
+ if (do_mpfr && tokentab[idx].ptr2)
+ r->builtin = tokentab[idx].ptr2;
+ else
+#endif
+ r->builtin = tokentab[idx].ptr;
/* special case processing for a few builtins */
@@ -3709,7 +3728,7 @@ snode(INSTRUCTION *subn, INSTRUCTION *r)
list = list_create(r);
(void) list_prepend(list, instruction(Op_field_spec));
(void) list_prepend(list, instruction(Op_push_i));
- list->nexti->memory = mk_number((AWKNUM) 0.0, (PERM|NUMCUR|NUMBER));
+ list->nexti->memory = make_number(0.0);
return list;
} else {
arg = subn->nexti;
@@ -3837,7 +3856,7 @@ snode(INSTRUCTION *subn, INSTRUCTION *r)
if (ip->opcode == Op_push)
ip->opcode = Op_push_array;
}
-#endif
+#endif
if (subn != NULL) {
r->expr_count = count_expressions(&subn, FALSE);
@@ -3848,75 +3867,6 @@ snode(INSTRUCTION *subn, INSTRUCTION *r)
return list_create(r);
}
-/* append_param --- append PNAME to the list of parameters
- * for the current function.
- */
-
-static void
-append_param(char *pname)
-{
- static NODE *savetail = NULL;
- NODE *p;
-
- p = make_param(pname);
- if (func_params == NULL) {
- func_params = p;
- savetail = p;
- } else if (savetail != NULL) {
- savetail->rnode = p;
- savetail = p;
- }
-}
-
-/* dup_parms --- return TRUE if there are duplicate parameters */
-
-static int
-dup_parms(INSTRUCTION *fp, NODE *func)
-{
- NODE *np;
- const char *fname, **names;
- int count, i, j, dups;
- NODE *params;
-
- if (func == NULL) /* error earlier */
- return TRUE;
-
- fname = func->param;
- count = func->param_cnt;
- params = func->rnode;
-
- if (count == 0) /* no args, no problem */
- return FALSE;
-
- if (params == NULL) /* error earlier */
- return TRUE;
-
- emalloc(names, const char **, count * sizeof(char *), "dup_parms");
-
- i = 0;
- for (np = params; np != NULL; np = np->rnode) {
- if (np->param == NULL) { /* error earlier, give up, go home */
- efree(names);
- return TRUE;
- }
- names[i++] = np->param;
- }
-
- dups = 0;
- for (i = 1; i < count; i++) {
- for (j = 0; j < i; j++) {
- if (strcmp(names[i], names[j]) == 0) {
- dups++;
- error_ln(fp->source_line,
- _("function `%s': parameter #%d, `%s', duplicates parameter #%d"),
- fname, i + 1, names[j], j+1);
- }
- }
- }
-
- efree(names);
- return (dups > 0 ? TRUE : FALSE);
-}
/* parms_shadow --- check if parameters shadow globals */
@@ -3925,18 +3875,19 @@ parms_shadow(INSTRUCTION *pc, int *shadow)
{
int pcount, i;
int ret = FALSE;
- NODE *func;
+ NODE *func, *fp;
char *fname;
func = pc->func_body;
- fname = func->lnode->param;
-
+ fname = func->vname;
+ fp = func->fparms;
+
#if 0 /* can't happen, already exited if error ? */
if (fname == NULL || func == NULL) /* error earlier */
return FALSE;
#endif
- pcount = func->lnode->param_cnt;
+ pcount = func->param_cnt;
if (pcount == 0) /* no args, no problem */
return 0;
@@ -3948,10 +3899,10 @@ parms_shadow(INSTRUCTION *pc, int *shadow)
* about all shadowed parameters.
*/
for (i = 0; i < pcount; i++) {
- if (lookup(func->parmlist[i]) != NULL) {
+ if (lookup(fp[i].param) != NULL) {
warning(
_("function `%s': parameter `%s' shadows global variable"),
- fname, func->parmlist[i]);
+ fname, fp[i].param);
ret = TRUE;
}
}
@@ -3960,143 +3911,41 @@ parms_shadow(INSTRUCTION *pc, int *shadow)
return 0;
}
-
-/*
- * install_symbol:
- * Install a name in the symbol table, even if it is already there.
- * Caller must check against redefinition if that is desired.
- */
-
-
-NODE *
-install_symbol(char *name, NODE *value)
-{
- NODE *hp;
- size_t len;
- int bucket;
-
- if (install_func)
- (*install_func)(name);
-
- var_count++;
- len = strlen(name);
- bucket = hash(name, len, (unsigned long) HASHSIZE, NULL);
- getnode(hp);
- hp->type = Node_hashnode;
- hp->hnext = variables[bucket];
- variables[bucket] = hp;
- hp->hlength = len;
- hp->hvalue = value;
- hp->hname = name;
- hp->hvalue->vname = name;
- return hp->hvalue;
-}
-
-/* lookup --- find the most recent hash node for name installed by install_symbol */
-
-NODE *
-lookup(const char *name)
-{
- NODE *bucket;
- size_t len;
-
- len = strlen(name);
- for (bucket = variables[hash(name, len, (unsigned long) HASHSIZE, NULL)];
- bucket != NULL; bucket = bucket->hnext)
- if (bucket->hlength == len && strncmp(bucket->hname, name, len) == 0)
- return bucket->hvalue;
- return NULL;
-}
-
-/* sym_comp --- compare two symbol (variable or function) names */
-
-static int
-sym_comp(const void *v1, const void *v2)
-{
- const NODE *const *npp1, *const *npp2;
- const NODE *n1, *n2;
- int minlen;
-
- npp1 = (const NODE *const *) v1;
- npp2 = (const NODE *const *) v2;
- n1 = *npp1;
- n2 = *npp2;
-
- if (n1->hlength > n2->hlength)
- minlen = n1->hlength;
- else
- minlen = n2->hlength;
-
- return strncmp(n1->hname, n2->hname, minlen);
-}
-
/* valinfo --- dump var info */
void
-valinfo(NODE *n, int (*print_func)(FILE *, const char *, ...), FILE *fp)
+valinfo(NODE *n, Func_print print_func, FILE *fp)
{
if (n == Nnull_string)
print_func(fp, "uninitialized scalar\n");
else if (n->flags & STRING) {
pp_string_fp(print_func, fp, n->stptr, n->stlen, '"', FALSE);
print_func(fp, "\n");
- } else if (n->flags & NUMBER)
+ } else if (n->flags & NUMBER) {
+#ifdef HAVE_MPFR
+ if (is_mpg_float(n))
+ print_func(fp, "%s\n", mpg_fmt("%.17R*g", ROUND_MODE, n->mpg_numbr));
+ else if (is_mpg_integer(n))
+ print_func(fp, "%s\n", mpg_fmt("%Zd", n->mpg_i));
+ else
+#endif
print_func(fp, "%.17g\n", n->numbr);
- else if (n->flags & STRCUR) {
+ } else if (n->flags & STRCUR) {
pp_string_fp(print_func, fp, n->stptr, n->stlen, '"', FALSE);
print_func(fp, "\n");
- } else if (n->flags & NUMCUR)
+ } else if (n->flags & NUMCUR) {
+#ifdef HAVE_MPFR
+ if (is_mpg_float(n))
+ print_func(fp, "%s\n", mpg_fmt("%.17R*g", ROUND_MODE, n->mpg_numbr));
+ else if (is_mpg_integer(n))
+ print_func(fp, "%s\n", mpg_fmt("%Zd", n->mpg_i));
+ else
+#endif
print_func(fp, "%.17g\n", n->numbr);
- else
+ } else
print_func(fp, "?? flags %s\n", flags2str(n->flags));
}
-/* get_varlist --- list of global variables */
-
-NODE **
-get_varlist()
-{
- int i, j;
- NODE **table;
- NODE *p;
-
- emalloc(table, NODE **, (var_count + 1) * sizeof(NODE *), "get_varlist");
- update_global_values();
- for (i = j = 0; i < HASHSIZE; i++)
- for (p = variables[i]; p != NULL; p = p->hnext)
- table[j++] = p;
- assert(j == var_count);
-
- /* Shazzam! */
- qsort(table, j, sizeof(NODE *), sym_comp);
-
- table[j] = NULL;
- return table;
-}
-
-/* print_vars --- print names and values of global variables */
-
-void
-print_vars(int (*print_func)(FILE *, const char *, ...), FILE *fp)
-{
- int i;
- NODE **table;
- NODE *p;
-
- table = get_varlist();
- for (i = 0; (p = table[i]) != NULL; i++) {
- if (p->hvalue->type == Node_func)
- continue;
- print_func(fp, "%.*s: ", (int) p->hlength, p->hname);
- if (p->hvalue->type == Node_var_array)
- print_func(fp, "array, %ld elements\n", p->hvalue->table_size);
- else if (p->hvalue->type == Node_var_new)
- print_func(fp, "untyped variable\n");
- else if (p->hvalue->type == Node_var)
- valinfo(p->hvalue->var_value, print_func, fp);
- }
- efree(table);
-}
/* dump_vars --- dump the symbol table */
@@ -4104,6 +3953,7 @@ void
dump_vars(const char *fname)
{
FILE *fp;
+ NODE **vars;
if (fname == NULL)
fp = stderr;
@@ -4113,48 +3963,25 @@ dump_vars(const char *fname)
fp = stderr;
}
- print_vars(fprintf, fp);
+ vars = variable_list();
+ print_vars(vars, fprintf, fp);
+ efree(vars);
if (fp != stderr && fclose(fp) != 0)
warning(_("%s: close failed (%s)"), fname, strerror(errno));
}
-/* release_all_vars --- free all variable memory */
-
-void
-release_all_vars()
-{
- int i;
- NODE *p, *next;
-
- for (i = 0; i < HASHSIZE; i++) {
- for (p = variables[i]; p != NULL; p = next) {
- next = p->hnext;
-
- if (p->hvalue->type == Node_func)
- continue;
- else if (p->hvalue->type == Node_var_array)
- assoc_clear(p->hvalue);
- else if (p->hvalue->type != Node_var_new)
- unref(p->hvalue->var_value);
-
- efree(p->hname);
- freenode(p->hvalue);
- freenode(p);
- }
- }
-}
-
/* dump_funcs --- print all functions */
void
dump_funcs()
{
- if (func_count <= 0)
- return;
-
- (void) foreach_func((int (*)(INSTRUCTION *, void *)) pp_func, TRUE, (void *) 0);
+ NODE **funcs;
+ funcs = function_list(TRUE);
+ (void) foreach_func(funcs, (int (*)(INSTRUCTION *, void *)) pp_func, (void *) 0);
+ efree(funcs);
}
+
/* shadow_funcs --- check all functions for parameters that shadow globals */
void
@@ -4162,175 +3989,164 @@ shadow_funcs()
{
static int calls = 0;
int shadow = FALSE;
-
- if (func_count <= 0)
- return;
+ NODE **funcs;
if (calls++ != 0)
fatal(_("shadow_funcs() called twice!"));
- (void) foreach_func((int (*)(INSTRUCTION *, void *)) parms_shadow, TRUE, &shadow);
+ funcs = function_list(TRUE);
+ (void) foreach_func(funcs, (int (*)(INSTRUCTION *, void *)) parms_shadow, & shadow);
+ efree(funcs);
/* End with fatal if the user requested it. */
if (shadow && lintfunc != warning)
lintwarn(_("there were shadowed variables."));
}
-/*
- * func_install:
- * check if name is already installed; if so, it had better have Null value,
- * in which case def is added as the value. Otherwise, install name with def
- * as value.
- *
- * Extra work, build up and save a list of the parameter names in a table
- * and hang it off params->parmlist. This is used to set the `vname' field
- * of each function parameter during a function call. See eval.c.
+
+/* mk_function --- finalize function definition node; remove parameters
+ * out of the symbol table.
*/
-static int
-func_install(INSTRUCTION *func, INSTRUCTION *def)
+static INSTRUCTION *
+mk_function(INSTRUCTION *fi, INSTRUCTION *def)
{
- NODE *params;
- NODE *r, *n, *thisfunc, *hp;
- char **pnames = NULL;
- char *fname;
- int pcount = 0;
- int i;
+ NODE *thisfunc;
- params = func_params;
+ thisfunc = fi->func_body;
+ assert(thisfunc != NULL);
- /* check for function foo(foo) { ... }. bleah. */
- for (n = params->rnode; n != NULL; n = n->rnode) {
- if (strcmp(n->param, params->param) == 0) {
- error_ln(func->source_line,
- _("function `%s': can't use function name as parameter name"), params->param);
- return -1;
- } else if (is_std_var(n->param)) {
- error_ln(func->source_line,
- _("function `%s': can't use special variable `%s' as a function parameter"),
- params->param, n->param);
- return -1;
- }
- }
+ if (do_optimize > 1 && def->lasti->opcode == Op_pop) {
+ /* tail call which does not return any value. */
- thisfunc = NULL; /* turn off warnings */
+ INSTRUCTION *t;
- fname = params->param;
- /* symbol table management */
- hp = remove_symbol(params->param); /* remove function name out of symbol table */
- if (hp != NULL)
- freenode(hp);
- r = lookup(fname);
- if (r != NULL) {
- error_ln(func->source_line,
- _("function name `%s' previously defined"), fname);
- return -1;
- } else if (fname == builtin_func) /* not a valid function name */
- goto remove_params;
+ for (t = def->nexti; t->nexti != def->lasti; t = t->nexti)
+ ;
+ if (t->opcode == Op_func_call
+ && strcmp(t->func_name, thisfunc->vname) == 0)
+ (t + 1)->tail_call = TRUE;
+ }
/* add an implicit return at end;
* also used by 'return' command in debugger
*/
-
+
(void) list_append(def, instruction(Op_push_i));
- def->lasti->memory = Nnull_string;
+ def->lasti->memory = dupnode(Nnull_string);
(void) list_append(def, instruction(Op_K_return));
- if (do_profiling)
+ if (do_pretty_print)
(void) list_prepend(def, instruction(Op_exec_count));
- /* func->opcode is Op_func */
- (func + 1)->firsti = def->nexti;
- (func + 1)->lasti = def->lasti;
- (func + 2)->first_line = func->source_line;
- (func + 2)->last_line = lastline;
-
- func->nexti = def->nexti;
+ /* fi->opcode = Op_func */
+ (fi + 1)->firsti = def->nexti;
+ (fi + 1)->lasti = def->lasti;
+ (fi + 2)->first_line = fi->source_line;
+ (fi + 2)->last_line = lastline;
+ fi->nexti = def->nexti;
bcfree(def);
- (void) list_append(rule_list, func + 1); /* debugging */
-
- /* install the function */
- thisfunc = mk_symbol(Node_func, params);
- (void) install_symbol(fname, thisfunc);
- thisfunc->code_ptr = func;
- func->func_body = thisfunc;
-
- for (n = params->rnode; n != NULL; n = n->rnode)
- pcount++;
-
- if (pcount != 0) {
- emalloc(pnames, char **, (pcount + 1) * sizeof(char *), "func_install");
- for (i = 0, n = params->rnode; i < pcount; i++, n = n->rnode)
- pnames[i] = n->param;
- pnames[pcount] = NULL;
- }
- thisfunc->parmlist = pnames;
+ (void) list_append(rule_list, fi + 1); /* debugging */
/* update lint table info */
- func_use(fname, FUNC_DEFINE);
+ func_use(thisfunc->vname, FUNC_DEFINE);
- func_count++; /* used in profiler / pretty printer */
-
-remove_params:
/* remove params from symbol table */
- pop_params(params->rnode);
- return 0;
+ remove_params(thisfunc);
+ return fi;
}
-/* remove_symbol --- remove a variable from the symbol table */
+/*
+ * install_function:
+ * install function name in the symbol table.
+ * Extra work, build up and install a list of the parameter names.
+ */
-NODE *
-remove_symbol(char *name)
+static int
+install_function(char *fname, INSTRUCTION *fi, INSTRUCTION *plist)
{
- NODE *bucket, **save;
- size_t len;
+ NODE *r, *f;
+ int pcount = 0;
- len = strlen(name);
- save = &(variables[hash(name, len, (unsigned long) HASHSIZE, NULL)]);
- for (bucket = *save; bucket != NULL; bucket = bucket->hnext) {
- if (len == bucket->hlength && strncmp(bucket->hname, name, len) == 0) {
- var_count--;
- *save = bucket->hnext;
- return bucket;
- }
- save = &(bucket->hnext);
+ r = lookup(fname);
+ if (r != NULL) {
+ error_ln(fi->source_line, _("function name `%s' previously defined"), fname);
+ return -1;
}
- return NULL;
+
+ if (plist != NULL)
+ pcount = plist->lasti->param_count + 1;
+ f = install_symbol(fname, Node_func);
+ fi->func_body = f;
+ f->param_cnt = pcount;
+ f->code_ptr = fi;
+ f->fparms = NULL;
+ if (pcount > 0) {
+ char **pnames;
+ pnames = check_params(fname, pcount, plist); /* frees plist */
+ f->fparms = make_params(pnames, pcount);
+ efree(pnames);
+ install_params(f);
+ }
+ return 0;
}
-/* pop_params --- remove list of function parameters from symbol table */
-/*
- * pop parameters out of the symbol table. do this in reverse order to
- * avoid reading freed memory if there were duplicated parameters.
+/* check_params --- build a list of function parameter names after
+ * making sure that the names are valid and there are no duplicates.
*/
-static void
-pop_params(NODE *params)
+
+static char **
+check_params(char *fname, int pcount, INSTRUCTION *list)
{
- NODE *hp;
- if (params == NULL)
- return;
- pop_params(params->rnode);
- hp = remove_symbol(params->param);
- if (hp != NULL)
- freenode(hp);
-}
+ INSTRUCTION *p, *np;
+ int i, j;
+ char *name;
+ char **pnames;
-/* make_param --- make NAME into a function parameter */
+ assert(pcount > 0);
-static NODE *
-make_param(char *name)
-{
- NODE *r;
+ emalloc(pnames, char **, pcount * sizeof(char *), "check_params");
+
+ for (i = 0, p = list->nexti; p != NULL; i++, p = np) {
+ np = p->nexti;
+ name = p->lextok;
+ p->lextok = NULL;
+
+ if (strcmp(name, fname) == 0) {
+ /* check for function foo(foo) { ... }. bleah. */
+ error_ln(p->source_line,
+ _("function `%s': can't use function name as parameter name"), fname);
+ } else if (is_std_var(name)) {
+ error_ln(p->source_line,
+ _("function `%s': can't use special variable `%s' as a function parameter"),
+ fname, name);
+ }
- getnode(r);
- r->type = Node_param_list;
- r->rnode = NULL;
- r->param_cnt = param_counter++;
- return (install_symbol(name, r));
+ /* check for duplicate parameters */
+ for (j = 0; j < i; j++) {
+ if (strcmp(name, pnames[j]) == 0) {
+ error_ln(p->source_line,
+ _("function `%s': parameter #%d, `%s', duplicates parameter #%d"),
+ fname, i + 1, name, j + 1);
+ }
+ }
+
+ pnames[i] = name;
+ bcfree(p);
+ }
+ bcfree(list);
+
+ return pnames;
}
+
+#ifdef HASHSIZE
+undef HASHSIZE
+#endif
+#define HASHSIZE 1021
+
static struct fdesc {
char *name;
short used;
@@ -4438,69 +4254,6 @@ param_sanity(INSTRUCTION *arglist)
}
}
-/* foreach_func --- execute given function for each awk function in symbol table. */
-
-int
-foreach_func(int (*pfunc)(INSTRUCTION *, void *), int sort, void *data)
-{
- int i, j;
- NODE *p;
- int ret = 0;
-
- if (sort) {
- NODE **tab;
-
- /*
- * Walk through symbol table counting functions.
- * Could be more than func_count if there are
- * extension functions.
- */
- for (i = j = 0; i < HASHSIZE; i++) {
- for (p = variables[i]; p != NULL; p = p->hnext) {
- if (p->hvalue->type == Node_func) {
- j++;
- }
- }
- }
-
- if (j == 0)
- return 0;
-
- emalloc(tab, NODE **, j * sizeof(NODE *), "foreach_func");
-
- /* now walk again, copying info */
- for (i = j = 0; i < HASHSIZE; i++) {
- for (p = variables[i]; p != NULL; p = p->hnext) {
- if (p->hvalue->type == Node_func) {
- tab[j] = p;
- j++;
- }
- }
- }
-
- /* Shazzam! */
- qsort(tab, j, sizeof(NODE *), sym_comp);
-
- for (i = 0; i < j; i++) {
- if ((ret = pfunc(tab[i]->hvalue->code_ptr, data)) != 0)
- break;
- }
-
- efree(tab);
- return ret;
- }
-
- /* unsorted */
- for (i = 0; i < HASHSIZE; i++) {
- for (p = variables[i]; p != NULL; p = p->hnext) {
- if (p->hvalue->type == Node_func
- && (ret = pfunc(p->hvalue->code_ptr, data)) != 0)
- return ret;
- }
- }
- return 0;
-}
-
/* deferred variables --- those that are only defined if needed. */
/*
@@ -4535,17 +4288,14 @@ register_deferred_variable(const char *name, NODE *(*load_func)(void))
/* variable --- make sure NAME is in the symbol table */
NODE *
-variable(char *name, NODETYPE type)
+variable(int location, char *name, NODETYPE type)
{
NODE *r;
if ((r = lookup(name)) != NULL) {
- if (r->type == Node_func) {
- error(_("function `%s' called with space between name and `(',\nor used as a variable or an array"),
+ if (r->type == Node_func || r->type == Node_ext_func )
+ error_ln(location, _("function `%s' called with space between name and `(',\nor used as a variable or an array"),
r->vname);
- errcount++;
- r->type = Node_var_new; /* continue parsing instead of exiting */
- }
} else {
/* not found */
struct deferred_variable *dv;
@@ -4555,11 +4305,7 @@ variable(char *name, NODETYPE type)
/*
* This is the only case in which we may not free the string.
*/
- if (type == Node_var)
- r = mk_symbol(type, Nnull_string);
- else
- r = mk_symbol(type, (NODE *) NULL);
- return install_symbol(name, r);
+ return install_symbol(name, type);
}
if (strcmp(name, dv->name) == 0) {
r = (*dv->load_func)();
@@ -4666,9 +4412,6 @@ make_assignable(INSTRUCTION *ip)
{
switch (ip->opcode) {
case Op_push:
- if (ip->memory->type == Node_param_list
- && (ip->memory->flags & FUNC) != 0)
- return NULL;
ip->opcode = Op_push_lhs;
return ip;
case Op_field_spec:
@@ -4683,14 +4426,6 @@ make_assignable(INSTRUCTION *ip)
return NULL;
}
-/* stopme --- for debugging */
-
-NODE *
-stopme(int nargs ATTRIBUTE_UNUSED)
-{
- return (NODE *) 0;
-}
-
/* dumpintlstr --- write out an initial .po file entry for the string */
static void
@@ -4740,27 +4475,6 @@ dumpintlstr2(const char *str1, size_t len1, const char *str2, size_t len2)
fflush(stdout);
}
-/* isarray --- can this type be subscripted? */
-
-static int
-isarray(NODE *n)
-{
- switch (n->type) {
- case Node_var_new:
- case Node_var_array:
- return TRUE;
- case Node_param_list:
- return (n->flags & FUNC) == 0;
- case Node_array_ref:
- cant_happen();
- break;
- default:
- break; /* keeps gcc -Wall happy */
- }
-
- return FALSE;
-}
-
/* mk_binary --- instructions for binary operators */
static INSTRUCTION *
@@ -4775,11 +4489,11 @@ mk_binary(INSTRUCTION *s1, INSTRUCTION *s2, INSTRUCTION *op)
ip1 = s1->nexti;
if (do_optimize > 1
&& ip1 == s1->lasti && ip1->opcode == Op_push_i
- && (ip1->memory->flags & (STRCUR|STRING)) == 0
- && (ip2->memory->flags & (STRCUR|STRING)) == 0
+ && (ip1->memory->flags & (MPFN|MPZN|STRCUR|STRING)) == 0
+ && (ip2->memory->flags & (MPFN|MPZN|STRCUR|STRING)) == 0
) {
NODE *n1 = ip1->memory, *n2 = ip2->memory;
- res = force_number(n1);
+ res = force_number(n1)->numbr;
(void) force_number(n2);
switch (op->opcode) {
case Op_times:
@@ -4821,11 +4535,7 @@ mk_binary(INSTRUCTION *s1, INSTRUCTION *s2, INSTRUCTION *op)
}
op->opcode = Op_push_i;
- op->memory = mk_number(res, (PERM|NUMCUR|NUMBER));
- n1->flags &= ~PERM;
- n1->flags |= MALLOC;
- n2->flags &= ~PERM;
- n2->flags |= MALLOC;
+ op->memory = make_number(res);
unref(n1);
unref(n2);
bcfree(ip1);
@@ -4951,7 +4661,7 @@ mk_condition(INSTRUCTION *cond, INSTRUCTION *ifp, INSTRUCTION *true_branch,
if (false_branch == NULL) {
false_branch = list_create(instruction(Op_no_op));
if (elsep != NULL) { /* else { } */
- if (do_profiling)
+ if (do_pretty_print)
(void) list_prepend(false_branch, elsep);
else
bcfree(elsep);
@@ -4962,7 +4672,7 @@ mk_condition(INSTRUCTION *cond, INSTRUCTION *ifp, INSTRUCTION *true_branch,
/* avoid a series of no_op's: if .. else if .. else if .. */
if (false_branch->lasti->opcode != Op_no_op)
(void) list_append(false_branch, instruction(Op_no_op));
- if (do_profiling) {
+ if (do_pretty_print) {
(void) list_prepend(false_branch, elsep);
false_branch->nexti->branch_end = false_branch->lasti;
(void) list_prepend(false_branch, instruction(Op_exec_count));
@@ -4977,7 +4687,7 @@ mk_condition(INSTRUCTION *cond, INSTRUCTION *ifp, INSTRUCTION *true_branch,
ip = list_append(cond, instruction(Op_jmp_false));
ip->lasti->target_jmp = false_branch->nexti->nexti;
- if (do_profiling) {
+ if (do_pretty_print) {
(void) list_prepend(ip, ifp);
(void) list_append(ip, instruction(Op_exec_count));
ip->nexti->branch_if = ip->lasti;
@@ -5039,7 +4749,7 @@ append_rule(INSTRUCTION *pattern, INSTRUCTION *action)
if (rule != Rule) {
rp = pattern;
- if (do_profiling)
+ if (do_pretty_print)
(void) list_append(action, instruction(Op_no_op));
(rp + 1)->firsti = action->nexti;
(rp + 1)->lasti = action->lasti;
@@ -5055,7 +4765,7 @@ append_rule(INSTRUCTION *pattern, INSTRUCTION *action)
if (pattern == NULL) {
/* assert(action != NULL); */
- if (do_profiling)
+ if (do_pretty_print)
(void) list_prepend(action, instruction(Op_exec_count));
(rp + 1)->firsti = action->nexti;
(rp + 1)->lasti = tp;
@@ -5071,12 +4781,12 @@ append_rule(INSTRUCTION *pattern, INSTRUCTION *action)
if (action == NULL) {
(rp + 2)->last_line = find_line(pattern, LAST_LINE);
action = list_create(instruction(Op_K_print_rec));
- if (do_profiling)
+ if (do_pretty_print)
(void) list_prepend(action, instruction(Op_exec_count));
} else
(rp + 2)->last_line = lastline;
- if (do_profiling) {
+ if (do_pretty_print) {
(void) list_prepend(pattern, instruction(Op_exec_count));
(void) list_prepend(action, instruction(Op_exec_count));
}
@@ -5156,9 +4866,7 @@ mk_assignment(INSTRUCTION *lhs, INSTRUCTION *rhs, INSTRUCTION *op)
static INSTRUCTION *
optimize_assignment(INSTRUCTION *exp)
{
- INSTRUCTION *i1;
- INSTRUCTION *i2;
- INSTRUCTION *i3;
+ INSTRUCTION *i1, *i2, *i3;
/*
* Optimize assignment statements array[subs] = x; var = x; $n = x;
@@ -5194,7 +4902,7 @@ optimize_assignment(INSTRUCTION *exp)
if ( ! do_optimize
|| ( i1->opcode != Op_assign
&& i1->opcode != Op_field_assign)
- )
+ )
return list_append(exp, instruction(Op_pop));
for (i2 = exp->nexti; i2 != i1; i2 = i2->nexti) {
@@ -5279,13 +4987,26 @@ optimize_assignment(INSTRUCTION *exp)
case Op_push_lhs:
if (i2->nexti == i1
- && i1->opcode == Op_assign
+ && i1->opcode == Op_assign
) {
/* var = .. */
i2->opcode = Op_store_var;
i2->nexti = NULL;
bcfree(i1); /* Op_assign */
exp->lasti = i2; /* update Op_list */
+
+ i3 = exp->nexti;
+ if (i3->opcode == Op_push_i
+ && (i3->memory->flags & INTLSTR) == 0
+ && i3->nexti == i2
+ ) {
+ /* constant initializer */
+ i2->initval = i3->memory;
+ bcfree(i3);
+ exp->nexti = i2;
+ } else
+ i2->initval = NULL;
+
return exp;
}
break;
@@ -5355,7 +5076,7 @@ mk_getline(INSTRUCTION *op, INSTRUCTION *var, INSTRUCTION *redir, int redirtype)
else
ip = list_create(op);
op->into_var = (var != NULL);
- op->redir_type = (redir != NULL) ? redirtype : 0;
+ op->redir_type = (redir != NULL) ? redirtype : redirect_none;
return (asgn == NULL ? ip : list_append(ip, asgn));
}
@@ -5406,7 +5127,7 @@ mk_for_loop(INSTRUCTION *forp, INSTRUCTION *init, INSTRUCTION *cond,
if (init != NULL)
ip = list_merge(init, ip);
- if (do_profiling) {
+ if (do_pretty_print) {
(void) list_append(ip, instruction(Op_exec_count));
(forp + 1)->forloop_cond = pp_cond;
(forp + 1)->forloop_body = ip->lasti;
@@ -5428,7 +5149,7 @@ mk_for_loop(INSTRUCTION *forp, INSTRUCTION *init, INSTRUCTION *cond,
ret = list_append(ip, tbreak);
fix_break_continue(ret, tbreak, tcont);
- if (do_profiling) {
+ if (do_pretty_print) {
forp->target_break = tbreak;
forp->target_continue = tcont;
ret = list_prepend(ret, forp);
@@ -5587,320 +5308,6 @@ fix_break_continue(INSTRUCTION *list, INSTRUCTION *b_target, INSTRUCTION *c_targ
}
}
-
-/* append_symbol --- append symbol to the list of symbols
- * installed in the symbol table.
- */
-
-void
-append_symbol(char *name)
-{
- NODE *hp;
-
- /* N.B.: func_install removes func name and reinstalls it;
- * and we get two entries for it here!. destroy_symbol()
- * will find and destroy the Node_func which is what we want.
- */
-
- getnode(hp);
- hp->hname = name; /* shallow copy */
- hp->hnext = symbol_list->hnext;
- symbol_list->hnext = hp;
-}
-
-/* release_symbol --- free symbol list and optionally remove symbol from symbol table */
-
-void
-release_symbols(NODE *symlist, int keep_globals)
-{
- NODE *hp, *n;
-
- for (hp = symlist->hnext; hp != NULL; hp = n) {
- if (! keep_globals) {
- /* destroys globals, function, and params
- * if still in symbol table and not removed by func_install
- * due to parse error.
- */
- destroy_symbol(hp->hname);
- }
- n = hp->hnext;
- freenode(hp);
- }
- symlist->hnext = NULL;
-}
-
-/* destroy_symbol --- remove a symbol from symbol table
-* and free all associated memory.
-*/
-
-void
-destroy_symbol(char *name)
-{
- NODE *symbol, *hp;
-
- symbol = lookup(name);
- if (symbol == NULL)
- return;
-
- if (symbol->type == Node_func) {
- char **varnames;
- NODE *func, *n;
-
- func = symbol;
- varnames = func->parmlist;
- if (varnames != NULL)
- efree(varnames);
-
- /* function parameters of type Node_param_list */
- for (n = func->lnode->rnode; n != NULL; ) {
- NODE *np;
- np = n->rnode;
- efree(n->param);
- freenode(n);
- n = np;
- }
- freenode(func->lnode);
- func_count--;
-
- } else if (symbol->type == Node_var_array)
- assoc_clear(symbol);
- else if (symbol->type == Node_var)
- unref(symbol->var_value);
-
- /* remove from symbol table */
- hp = remove_symbol(name);
- efree(hp->hname);
- freenode(hp->hvalue);
- freenode(hp);
-}
-
-#define pool_size d.dl
-#define freei x.xi
-static INSTRUCTION *pool_list;
-static AWK_CONTEXT *curr_ctxt = NULL;
-
-/* new_context --- create a new execution context. */
-
-AWK_CONTEXT *
-new_context()
-{
- AWK_CONTEXT *ctxt;
-
- emalloc(ctxt, AWK_CONTEXT *, sizeof(AWK_CONTEXT), "new_context");
- memset(ctxt, 0, sizeof(AWK_CONTEXT));
- ctxt->srcfiles.next = ctxt->srcfiles.prev = &ctxt->srcfiles;
- ctxt->rule_list.opcode = Op_list;
- ctxt->rule_list.lasti = &ctxt->rule_list;
- return ctxt;
-}
-
-/* set_context --- change current execution context. */
-
-static void
-set_context(AWK_CONTEXT *ctxt)
-{
- pool_list = &ctxt->pools;
- symbol_list = &ctxt->symbols;
- srcfiles = &ctxt->srcfiles;
- rule_list = &ctxt->rule_list;
- install_func = ctxt->install_func;
- curr_ctxt = ctxt;
-}
-
-/*
- * push_context:
- *
- * Switch to the given context after saving the current one. The set
- * of active execution contexts forms a stack; the global or main context
- * is at the bottom of the stack.
- */
-
-void
-push_context(AWK_CONTEXT *ctxt)
-{
- ctxt->prev = curr_ctxt;
- /* save current source and sourceline */
- if (curr_ctxt != NULL) {
- curr_ctxt->sourceline = sourceline;
- curr_ctxt->source = source;
- }
- sourceline = 0;
- source = NULL;
- set_context(ctxt);
-}
-
-/* pop_context --- switch to previous execution context. */
-
-void
-pop_context()
-{
- AWK_CONTEXT *ctxt;
-
- assert(curr_ctxt != NULL);
- ctxt = curr_ctxt->prev;
- /* restore source and sourceline */
- sourceline = ctxt->sourceline;
- source = ctxt->source;
- set_context(ctxt);
-}
-
-/* in_main_context --- are we in the main context ? */
-
-int
-in_main_context()
-{
- assert(curr_ctxt != NULL);
- return (curr_ctxt->prev == NULL);
-}
-
-/* free_context --- free context structure and related data. */
-
-void
-free_context(AWK_CONTEXT *ctxt, int keep_globals)
-{
- SRCFILE *s, *sn;
-
- if (ctxt == NULL)
- return;
-
- assert(curr_ctxt != ctxt);
-
- /* free all code including function codes */
- free_bcpool(&ctxt->pools);
- /* free symbols */
- release_symbols(&ctxt->symbols, keep_globals);
- /* free srcfiles */
- for (s = &ctxt->srcfiles; s != &ctxt->srcfiles; s = sn) {
- sn = s->next;
- if (s->stype != SRC_CMDLINE && s->stype != SRC_STDIN)
- efree(s->fullpath);
- efree(s->src);
- efree(s);
- }
- efree(ctxt);
-}
-
-/* free_bc_internal --- free internal memory of an instruction. */
-
-static void
-free_bc_internal(INSTRUCTION *cp)
-{
- NODE *m;
-
- switch(cp->opcode) {
- case Op_func_call:
- if (cp->func_name != NULL
- && cp->func_name != builtin_func
- )
- efree(cp->func_name);
- break;
- case Op_push_re:
- case Op_match_rec:
- case Op_match:
- case Op_nomatch:
- m = cp->memory;
- if (m->re_reg != NULL)
- refree(m->re_reg);
- if (m->re_exp != NULL)
- unref(m->re_exp);
- if (m->re_text != NULL)
- unref(m->re_text);
- freenode(m);
- break;
- case Op_token: /* token lost during error recovery in yyparse */
- if (cp->lextok != NULL)
- efree(cp->lextok);
- break;
- case Op_illegal:
- cant_happen();
- default:
- break;
- }
-}
-
-
-/* INSTR_CHUNK must be > largest code size (3) */
-#define INSTR_CHUNK 127
-
-/* bcfree --- deallocate instruction */
-
-void
-bcfree(INSTRUCTION *cp)
-{
- cp->opcode = 0;
- cp->nexti = pool_list->freei;
- pool_list->freei = cp;
-}
-
-/* bcalloc --- allocate a new instruction */
-
-INSTRUCTION *
-bcalloc(OPCODE op, int size, int srcline)
-{
- INSTRUCTION *cp;
-
- if (size > 1) {
- /* wide instructions Op_rule, Op_func_call .. */
- emalloc(cp, INSTRUCTION *, (size + 1) * sizeof(INSTRUCTION), "bcalloc");
- cp->pool_size = size;
- cp->nexti = pool_list->nexti;
- pool_list->nexti = cp++;
- } else {
- INSTRUCTION *pool;
-
- pool = pool_list->freei;
- if (pool == NULL) {
- INSTRUCTION *last;
- emalloc(cp, INSTRUCTION *, (INSTR_CHUNK + 1) * sizeof(INSTRUCTION), "bcalloc");
-
- cp->pool_size = INSTR_CHUNK;
- cp->nexti = pool_list->nexti;
- pool_list->nexti = cp;
- pool = ++cp;
- last = &pool[INSTR_CHUNK - 1];
- for (; cp <= last; cp++) {
- cp->opcode = 0;
- cp->nexti = cp + 1;
- }
- --cp;
- cp->nexti = NULL;
- }
- cp = pool;
- pool_list->freei = cp->nexti;
- }
-
- memset(cp, 0, size * sizeof(INSTRUCTION));
- cp->opcode = op;
- cp->source_line = srcline;
- return cp;
-}
-
-/* free_bcpool --- free list of instruction memory pools */
-
-static void
-free_bcpool(INSTRUCTION *pl)
-{
- INSTRUCTION *pool, *tmp;
-
- for (pool = pl->nexti; pool != NULL; pool = tmp) {
- INSTRUCTION *cp, *last;
- long psiz;
- psiz = pool->pool_size;
- if (psiz == INSTR_CHUNK)
- last = pool + psiz;
- else
- last = pool + 1;
- for (cp = pool + 1; cp <= last ; cp++) {
- if (cp->opcode != 0)
- free_bc_internal(cp);
- }
- tmp = pool->nexti;
- efree(pool);
- }
- memset(pl, 0, sizeof(INSTRUCTION));
-}
-
-
static inline INSTRUCTION *
list_create(INSTRUCTION *x)
{
@@ -6037,3 +5444,4 @@ one_line_close(int fd)
return ret;
}
+
diff --git a/awklib/.gitignore b/awklib/.gitignore
new file mode 100644
index 00000000..b46084d4
--- /dev/null
+++ b/awklib/.gitignore
@@ -0,0 +1,8 @@
+# Ignore files that are created by a build.
+# For example objects and archives.
+grcat
+group.awk
+igawk
+passwd.awk
+pwcat
+
diff --git a/awklib/Makefile.in b/awklib/Makefile.in
index 73330766..793e8ee8 100644
--- a/awklib/Makefile.in
+++ b/awklib/Makefile.in
@@ -84,11 +84,11 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/arch.m4 \
$(top_srcdir)/m4/isc-posix.m4 $(top_srcdir)/m4/lcmessage.m4 \
$(top_srcdir)/m4/lib-ld.m4 $(top_srcdir)/m4/lib-link.m4 \
$(top_srcdir)/m4/lib-prefix.m4 $(top_srcdir)/m4/libsigsegv.m4 \
- $(top_srcdir)/m4/longlong.m4 $(top_srcdir)/m4/nls.m4 \
- $(top_srcdir)/m4/noreturn.m4 $(top_srcdir)/m4/po.m4 \
- $(top_srcdir)/m4/progtest.m4 $(top_srcdir)/m4/readline.m4 \
- $(top_srcdir)/m4/socket.m4 $(top_srcdir)/m4/ulonglong.m4 \
- $(top_srcdir)/configure.ac
+ $(top_srcdir)/m4/longlong.m4 $(top_srcdir)/m4/mpfr.m4 \
+ $(top_srcdir)/m4/nls.m4 $(top_srcdir)/m4/noreturn.m4 \
+ $(top_srcdir)/m4/po.m4 $(top_srcdir)/m4/progtest.m4 \
+ $(top_srcdir)/m4/readline.m4 $(top_srcdir)/m4/socket.m4 \
+ $(top_srcdir)/m4/ulonglong.m4 $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
@@ -185,6 +185,7 @@ INTL_MACOSX_LIBS = @INTL_MACOSX_LIBS@
LDFLAGS = @LDFLAGS@
LIBICONV = @LIBICONV@
LIBINTL = @LIBINTL@
+LIBMPFR = @LIBMPFR@
LIBOBJS = @LIBOBJS@
LIBREADLINE = @LIBREADLINE@
LIBS = @LIBS@
diff --git a/builtin.c b/builtin.c
index 44e0b85c..9134e024 100644
--- a/builtin.c
+++ b/builtin.c
@@ -80,8 +80,10 @@ extern FILE *output_fp;
#define POP_TWO_SCALARS(s1, s2) \
s2 = POP_SCALAR(); \
s1 = POP(); \
-if ((s1)->type == Node_var_array) \
- DEREF(s2), fatal(_("attempt to use array `%s' in a scalar context"), array_vname(s1)), 0
+do { if (s1->type == Node_var_array) { \
+DEREF(s2); \
+fatal(_("attempt to use array `%s' in a scalar context"), array_vname(s1)); \
+}} while (FALSE)
/*
@@ -133,7 +135,7 @@ do_exp(int nargs)
tmp = POP_SCALAR();
if (do_lint && (tmp->flags & (NUMCUR|NUMBER)) == 0)
lintwarn(_("exp: received non-numeric argument"));
- d = force_number(tmp);
+ d = force_number(tmp)->numbr;
DEREF(tmp);
errno = 0;
res = exp(d);
@@ -334,8 +336,10 @@ do_index(int nargs)
if ((s2->flags & (STRING|STRCUR)) == 0)
lintwarn(_("index: received non-string second argument"));
}
- force_string(s1);
- force_string(s2);
+
+ s1 = force_string(s1);
+ s2 = force_string(s2);
+
p1 = s1->stptr;
p2 = s2->stptr;
l1 = s1->stlen;
@@ -455,7 +459,7 @@ do_int(int nargs)
tmp = POP_SCALAR();
if (do_lint && (tmp->flags & (NUMCUR|NUMBER)) == 0)
lintwarn(_("int: received non-numeric argument"));
- d = force_number(tmp);
+ d = force_number(tmp)->numbr;
d = double_to_int(d);
DEREF(tmp);
return make_number((AWKNUM) d);
@@ -502,7 +506,7 @@ do_length(int nargs)
if (do_lint && (tmp->flags & (STRING|STRCUR)) == 0)
lintwarn(_("length: received non-string argument"));
- (void) force_string(tmp);
+ tmp = force_string(tmp);
#if MBS_SUPPORT
if (gawk_mb_cur_max > 1) {
@@ -533,7 +537,7 @@ do_log(int nargs)
tmp = POP_SCALAR();
if (do_lint && (tmp->flags & (NUMCUR|NUMBER)) == 0)
lintwarn(_("log: received non-numeric argument"));
- arg = (double) force_number(tmp);
+ arg = force_number(tmp)->numbr;
if (arg < 0.0)
warning(_("log: received negative argument %g"), arg);
d = log(arg);
@@ -542,6 +546,42 @@ do_log(int nargs)
}
+#ifdef HAVE_MPFR
+
+/*
+ * mpz2mpfr --- convert an arbitrary-precision integer to a float
+ * without any loss of precision. The returned value is only
+ * good for temporary use.
+ */
+
+
+static mpfr_ptr
+mpz2mpfr(mpz_ptr zi)
+{
+ size_t prec;
+ static mpfr_t mpfrval;
+ static int inited = FALSE;
+ int tval;
+
+ /* estimate minimum precision for exact conversion */
+ prec = mpz_sizeinbase(zi, 2); /* most significant 1 bit position starting at 1 */
+ prec -= (size_t) mpz_scan1(zi, 0); /* least significant 1 bit index starting at 0 */
+ if (prec < MPFR_PREC_MIN)
+ prec = MPFR_PREC_MIN;
+ else if (prec > MPFR_PREC_MAX)
+ prec = MPFR_PREC_MAX;
+
+ if (! inited) {
+ mpfr_init2(mpfrval, prec);
+ inited = TRUE;
+ } else
+ mpfr_set_prec(mpfrval, prec);
+ tval = mpfr_set_z(mpfrval, zi, ROUND_MODE);
+ IEEE_FMT(mpfrval, tval);
+ return mpfrval;
+}
+#endif
+
/*
* format_tree() formats arguments of sprintf,
* and accordingly to a fmt_string providing a format like in
@@ -599,7 +639,7 @@ format_tree(
size_t cur_arg = 0;
NODE *r = NULL;
- int i;
+ int i, nc;
int toofew = FALSE;
char *obuf, *obufout;
size_t osiz, ofre;
@@ -631,7 +671,7 @@ format_tree(
char *cend = &cpbufs[0].stackbuf[sizeof(cpbufs[0].stackbuf)];
char *cp;
const char *fill;
- AWKNUM tmpval;
+ AWKNUM tmpval = 0.0;
char signchar = FALSE;
size_t len;
int zero_flag = FALSE;
@@ -639,6 +679,12 @@ format_tree(
int ii, jj;
char *chp;
size_t copy_count, char_count;
+#ifdef HAVE_MPFR
+ mpz_ptr zi;
+ mpfr_ptr mf;
+#endif
+ enum { MP_INT_WITH_PREC = 1, MP_INT_WITHOUT_PREC, MP_FLOAT } fmt_type;
+
static const char sp[] = " ";
static const char zero_string[] = "0";
static const char lchbuf[] = "0123456789abcdef";
@@ -726,10 +772,17 @@ format_tree(
prec = 0;
base = 0;
argnum = 0;
+ base = 0;
have_prec = FALSE;
signchar = FALSE;
zero_flag = FALSE;
quote_flag = FALSE;
+#ifdef HAVE_MPFR
+ mf = NULL;
+ zi = NULL;
+#endif
+ fmt_type = 0;
+
lj = alt = big_flag = bigbig_flag = small_flag = FALSE;
fill = sp;
cp = cend;
@@ -861,7 +914,8 @@ check_pos:
} else {
parse_next_arg();
}
- *cur = force_number(arg);
+ (void) force_number(arg);
+ *cur = get_number_si(arg);
if (*cur < 0 && cur == &fw) {
*cur = -*cur;
lj++;
@@ -969,7 +1023,7 @@ check_pos:
if ((arg->flags & (MAYBE_NUM|NUMBER)) == MAYBE_NUM)
(void) force_number(arg);
if (arg->flags & NUMBER) {
- uval = (uintmax_t) arg->numbr;
+ uval = get_number_uj(arg);
#if MBS_SUPPORT
if (gawk_mb_cur_max > 1) {
char buf[100];
@@ -1052,7 +1106,16 @@ out2:
case 'i':
need_format = FALSE;
parse_next_arg();
- tmpval = force_number(arg);
+ (void) force_number(arg);
+#ifdef HAVE_MPFR
+ if (is_mpg_float(arg))
+ goto mpf0;
+ else if (is_mpg_integer(arg))
+ goto mpz0;
+ else
+#endif
+ tmpval = arg->numbr;
+
/*
* Check for Nan or Inf.
*/
@@ -1163,7 +1226,78 @@ out2:
base += 8;
need_format = FALSE;
parse_next_arg();
- tmpval = force_number(arg);
+ (void) force_number(arg);
+#ifdef HAVE_MPFR
+ if (is_mpg_integer(arg)) {
+mpz0:
+ zi = arg->mpg_i;
+
+ if (cs1 != 'd' && cs1 != 'i') {
+ if (mpz_sgn(zi) <= 0) {
+ /*
+ * Negative value or 0 requires special handling.
+ * Unlike MPFR, GMP does not allow conversion
+ * to (u)intmax_t. So we first convert GMP type to
+ * a MPFR type.
+ */
+ mf = mpz2mpfr(zi);
+ goto mpf1;
+ }
+ signchar = FALSE; /* Don't print '+' */
+ }
+
+ /* See comments above about when to fill with zeros */
+ zero_flag = (! lj
+ && ((zero_flag && ! have_prec)
+ || (fw == 0 && have_prec)));
+
+ fmt_type = have_prec ? MP_INT_WITH_PREC : MP_INT_WITHOUT_PREC;
+ goto fmt0;
+
+ } else if (is_mpg_float(arg)) {
+mpf0:
+ mf = arg->mpg_numbr;
+ if (! mpfr_number_p(mf)) {
+ /* inf or NaN */
+ cs1 = 'g';
+ fmt_type = MP_FLOAT;
+ goto fmt1;
+ }
+
+ if (cs1 != 'd' && cs1 != 'i') {
+mpf1:
+ /*
+ * The output of printf("%#.0x", 0) is 0 instead of 0x, hence <= in
+ * the comparison below.
+ */
+ if (mpfr_sgn(mf) <= 0) {
+ if (! mpfr_fits_intmax_p(mf, ROUND_MODE)) {
+ /* -ve number is too large */
+ cs1 = 'g';
+ fmt_type = MP_FLOAT;
+ goto fmt1;
+ }
+
+ tmpval = uval = (uintmax_t) mpfr_get_sj(mf, ROUND_MODE);
+ if (! alt && have_prec && prec == 0 && tmpval == 0)
+ goto pr_tail; /* printf("%.0x", 0) is no characters */
+ goto int0;
+ }
+ signchar = FALSE; /* Don't print '+' */
+ }
+
+ /* See comments above about when to fill with zeros */
+ zero_flag = (! lj
+ && ((zero_flag && ! have_prec)
+ || (fw == 0 && have_prec)));
+
+ (void) mpfr_get_z(mpzval, mf, MPFR_RNDZ); /* convert to GMP integer */
+ fmt_type = have_prec ? MP_INT_WITH_PREC : MP_INT_WITHOUT_PREC;
+ zi = mpzval;
+ goto fmt0;
+ } else
+#endif
+ tmpval = arg->numbr;
/*
* ``The result of converting a zero value with a
@@ -1182,14 +1316,16 @@ out2:
if (tmpval < 0) {
uval = (uintmax_t) (intmax_t) tmpval;
- if ((AWKNUM)(intmax_t)uval !=
- double_to_int(tmpval))
+ if ((AWKNUM)(intmax_t)uval != double_to_int(tmpval))
goto out_of_range;
} else {
uval = (uintmax_t) tmpval;
if ((AWKNUM)uval != double_to_int(tmpval))
goto out_of_range;
}
+#ifdef HAVE_MPFR
+ int0:
+#endif
/*
* When to fill with zeroes is of course not simple.
* First: No zero fill if left-justifying.
@@ -1272,7 +1408,7 @@ out2:
lintwarn(_("[s]printf: value %g is out of range for `%%%c' format"),
(double) tmpval, cs1);
cs1 = 'g';
- goto format_float;
+ goto fmt1;
case 'F':
#if ! defined(PRINTF_HAS_F_FORMAT) || PRINTF_HAS_F_FORMAT != 1
@@ -1286,11 +1422,28 @@ out2:
case 'E':
need_format = FALSE;
parse_next_arg();
- tmpval = force_number(arg);
- format_float:
+ (void) force_number(arg);
+
+ if (! is_mpg_number(arg))
+ tmpval = arg->numbr;
+#ifdef HAVE_MPFR
+ else if (is_mpg_float(arg)) {
+ mf = arg->mpg_numbr;
+ fmt_type = MP_FLOAT;
+ } else {
+ /* arbitrary-precision integer, convert to MPFR float */
+ assert(mf == NULL);
+ mf = mpz2mpfr(arg->mpg_i);
+ fmt_type = MP_FLOAT;
+ }
+#endif
+ fmt1:
if (! have_prec)
prec = DEFAULT_G_PRECISION;
- chksize(fw + prec + 9); /* 9 == slop */
+#ifdef HAVE_MPFR
+ fmt0:
+#endif
+ chksize(fw + prec + 11); /* 11 == slop */
cp = cpbuf;
*cp++ = '%';
if (lj)
@@ -1303,25 +1456,46 @@ out2:
*cp++ = '0';
if (quote_flag)
*cp++ = '\'';
- strcpy(cp, "*.*");
- cp += 3;
- *cp++ = cs1;
- *cp = '\0';
+
#if defined(LC_NUMERIC)
if (quote_flag && ! use_lc_numeric)
setlocale(LC_NUMERIC, "");
#endif
- {
- int n;
- while ((n = snprintf(obufout, ofre, cpbuf,
- (int) fw, (int) prec,
- (double) tmpval)) >= ofre)
- chksize(n)
+
+ switch (fmt_type) {
+#ifdef HAVE_MPFR
+ case MP_INT_WITH_PREC:
+ sprintf(cp, "*.*Z%c", cs1);
+ while ((nc = mpfr_snprintf(obufout, ofre, cpbuf,
+ (int) fw, (int) prec, zi)) >= ofre)
+ chksize(nc)
+ break;
+ case MP_INT_WITHOUT_PREC:
+ sprintf(cp, "*Z%c", cs1);
+ while ((nc = mpfr_snprintf(obufout, ofre, cpbuf,
+ (int) fw, zi)) >= ofre)
+ chksize(nc)
+ break;
+ case MP_FLOAT:
+ sprintf(cp, "*.*R*%c", cs1);
+ while ((nc = mpfr_snprintf(obufout, ofre, cpbuf,
+ (int) fw, (int) prec, ROUND_MODE, mf)) >= ofre)
+ chksize(nc)
+ break;
+#endif
+ default:
+ sprintf(cp, "*.*%c", cs1);
+ while ((nc = snprintf(obufout, ofre, cpbuf,
+ (int) fw, (int) prec,
+ (double) tmpval)) >= ofre)
+ chksize(nc)
}
+
#if defined(LC_NUMERIC)
if (quote_flag && ! use_lc_numeric)
setlocale(LC_NUMERIC, "C");
#endif
+
len = strlen(obufout);
ofre -= len;
obufout += len;
@@ -1362,6 +1536,7 @@ out:
if (obuf != NULL)
efree(obuf);
}
+
if (r == NULL)
gawk_exit(EXIT_FATAL);
return r;
@@ -1386,7 +1561,7 @@ printf_common(int nargs)
}
}
- force_string(args_array[0]);
+ args_array[0] = force_string(args_array[0]);
r = format_tree(args_array[0]->stptr, args_array[0]->stlen, args_array, nargs);
for (i = 0; i < nargs; i++)
DEREF(args_array[i]);
@@ -1473,7 +1648,7 @@ do_sqrt(int nargs)
tmp = POP_SCALAR();
if (do_lint && (tmp->flags & (NUMCUR|NUMBER)) == 0)
lintwarn(_("sqrt: received non-numeric argument"));
- arg = (double) force_number(tmp);
+ arg = (double) force_number(tmp)->numbr;
DEREF(tmp);
if (arg < 0.0)
warning(_("sqrt: called with negative argument %g"), arg);
@@ -1492,19 +1667,26 @@ do_substr(int nargs)
double d_index = 0, d_length = 0;
size_t src_len;
- if (nargs == 3)
- POP_NUMBER(d_length);
- POP_NUMBER(d_index);
+ if (nargs == 3) {
+ t1 = POP_NUMBER();
+ d_length = get_number_d(t1);
+ DEREF(t1);
+ }
+
+ t1 = POP_NUMBER();
+ d_index = get_number_d(t1);
+ DEREF(t1);
+
t1 = POP_STRING();
if (nargs == 3) {
if (! (d_length >= 1)) {
- if (do_lint == LINT_ALL)
+ if (do_lint == DO_LINT_ALL)
lintwarn(_("substr: length %g is not >= 1"), d_length);
- else if (do_lint == LINT_INVALID && ! (d_length >= 0))
+ else if (do_lint == DO_LINT_INVALID && ! (d_length >= 0))
lintwarn(_("substr: length %g is not >= 0"), d_length);
DEREF(t1);
- return Nnull_string;
+ return dupnode(Nnull_string);
}
if (do_lint) {
if (double_to_int(d_length) != d_length)
@@ -1555,10 +1737,10 @@ do_substr(int nargs)
if (t1->stlen == 0) {
/* substr("", 1, 0) produces a warning only if LINT_ALL */
- if (do_lint && (do_lint == LINT_ALL || ((indx | length) != 0)))
+ if (do_lint && (do_lint == DO_LINT_ALL || ((indx | length) != 0)))
lintwarn(_("substr: source string is zero length"));
DEREF(t1);
- return Nnull_string;
+ return dupnode(Nnull_string);
}
/* get total len of input string, for following checks */
@@ -1575,7 +1757,7 @@ do_substr(int nargs)
lintwarn(_("substr: start index %g is past end of string"),
d_index);
DEREF(t1);
- return Nnull_string;
+ return dupnode(Nnull_string);
}
if (length > src_len - indx) {
if (do_lint)
@@ -1673,12 +1855,13 @@ do_strftime(int nargs)
do_gmt = (t3->stlen > 0);
DEREF(t3);
}
-
+
if (nargs >= 2) {
t2 = POP_SCALAR();
if (do_lint && (t2->flags & (NUMCUR|NUMBER)) == 0)
lintwarn(_("strftime: received non-numeric second argument"));
- clock_val = (long) force_number(t2);
+ (void) force_number(t2);
+ clock_val = get_number_si(t2);
if (clock_val < 0)
fatal(_("strftime: second argument less than 0 or too big for time_t"));
fclock = (time_t) clock_val;
@@ -1688,6 +1871,7 @@ do_strftime(int nargs)
tmp = POP_SCALAR();
if (do_lint && (tmp->flags & (STRING|STRCUR)) == 0)
lintwarn(_("strftime: received non-string first argument"));
+
t1 = force_string(tmp);
format = t1->stptr;
formatlen = t1->stlen;
@@ -1770,13 +1954,13 @@ do_mktime(int nargs)
& hour, & minute, & second,
& dst);
- if (do_lint /* Ready? Set! Go: */
- && ( (second < 0 || second > 60)
- || (minute < 0 || minute > 60)
- || (hour < 0 || hour > 23)
- || (day < 1 || day > 31)
- || (month < 1 || month > 12) ))
- lintwarn(_("mktime: at least one of the values is out of the default range"));
+ if (do_lint /* Ready? Set! Go: */
+ && ( (second < 0 || second > 60)
+ || (minute < 0 || minute > 60)
+ || (hour < 0 || hour > 23)
+ || (day < 1 || day > 31)
+ || (month < 1 || month > 12) ))
+ lintwarn(_("mktime: at least one of the values is out of the default range"));
t1->stptr[t1->stlen] = save;
DEREF(t1);
@@ -1837,11 +2021,9 @@ do_system(int nargs)
return make_number((AWKNUM) ret);
}
-extern NODE **fmt_list; /* declared in eval.c */
-
/* do_print --- print items, separated by OFS, terminated with ORS */
-void
+void
do_print(int nargs, int redirtype)
{
struct redirect *rp = NULL;
@@ -1849,7 +2031,7 @@ do_print(int nargs, int redirtype)
FILE *fp = NULL;
int i;
NODE *redir_exp = NULL;
- NODE *tmp;
+ NODE *tmp = NULL;
assert(nargs <= max_args);
@@ -1870,12 +2052,10 @@ do_print(int nargs, int redirtype)
DEREF(args_array[i]);
fatal(_("attempt to use array `%s' in a scalar context"), array_vname(tmp));
}
- if (do_lint && tmp->type == Node_var_new)
- lintwarn(_("reference to uninitialized variable `%s'"),
- tmp->vname);
+
if ((tmp->flags & (NUMBER|STRING)) == NUMBER) {
if (OFMTidx == CONVFMTidx)
- (void) force_string(tmp);
+ args_array[i] = force_string(tmp);
else
args_array[i] = format_val(OFMT, OFMTidx, tmp);
}
@@ -2099,8 +2279,8 @@ do_atan2(int nargs)
if ((t2->flags & (NUMCUR|NUMBER)) == 0)
lintwarn(_("atan2: received non-numeric second argument"));
}
- d1 = force_number(t1);
- d2 = force_number(t2);
+ d1 = force_number(t1)->numbr;
+ d2 = force_number(t2)->numbr;
DEREF(t1);
DEREF(t2);
return make_number((AWKNUM) atan2(d1, d2));
@@ -2117,7 +2297,7 @@ do_sin(int nargs)
tmp = POP_SCALAR();
if (do_lint && (tmp->flags & (NUMCUR|NUMBER)) == 0)
lintwarn(_("sin: received non-numeric argument"));
- d = sin((double) force_number(tmp));
+ d = sin((double) force_number(tmp)->numbr);
DEREF(tmp);
return make_number((AWKNUM) d);
}
@@ -2133,7 +2313,7 @@ do_cos(int nargs)
tmp = POP_SCALAR();
if (do_lint && (tmp->flags & (NUMCUR|NUMBER)) == 0)
lintwarn(_("cos: received non-numeric argument"));
- d = cos((double) force_number(tmp));
+ d = cos((double) force_number(tmp)->numbr);
DEREF(tmp);
return make_number((AWKNUM) d);
}
@@ -2186,7 +2366,7 @@ do_srand(int nargs)
tmp = POP_SCALAR();
if (do_lint && (tmp->flags & (NUMCUR|NUMBER)) == 0)
lintwarn(_("srand: received non-numeric argument"));
- srandom((unsigned int) (save_seed = (long) force_number(tmp)));
+ srandom((unsigned int) (save_seed = (long) force_number(tmp)->numbr));
DEREF(tmp);
}
return make_number((AWKNUM) ret);
@@ -2267,7 +2447,7 @@ do_match(int nargs)
it->flags |= MAYBE_NUM; /* user input */
sub = make_number((AWKNUM) (ii));
- lhs = assoc_lookup(dest, sub, FALSE);
+ lhs = assoc_lookup(dest, sub);
unref(*lhs);
*lhs = it;
unref(sub);
@@ -2290,7 +2470,7 @@ do_match(int nargs)
it = make_number((AWKNUM) subpat_start + 1);
sub = make_string(buf, slen);
- lhs = assoc_lookup(dest, sub, FALSE);
+ lhs = assoc_lookup(dest, sub);
unref(*lhs);
*lhs = it;
unref(sub);
@@ -2303,7 +2483,7 @@ do_match(int nargs)
it = make_number((AWKNUM) subpat_len);
sub = make_string(buf, slen);
- lhs = assoc_lookup(dest, sub, FALSE);
+ lhs = assoc_lookup(dest, sub);
unref(*lhs);
*lhs = it;
unref(sub);
@@ -2463,15 +2643,16 @@ do_sub(int nargs, unsigned int flags)
if (t1->stlen > 0 && (t1->stptr[0] == 'g' || t1->stptr[0] == 'G'))
how_many = -1;
else {
- d = force_number(t1);
-
+ (void) force_number(t1);
+ d = get_number_d(t1);
if ((t1->flags & NUMCUR) != 0)
goto set_how_many;
how_many = 1;
}
} else {
- d = force_number(t1);
+ (void) force_number(t1);
+ d = get_number_d(t1);
set_how_many:
if (d < 1)
how_many = 1;
@@ -2777,8 +2958,8 @@ do_lshift(int nargs)
if ((s2->flags & (NUMCUR|NUMBER)) == 0)
lintwarn(_("lshift: received non-numeric second argument"));
}
- val = force_number(s1);
- shift = force_number(s2);
+ val = force_number(s1)->numbr;
+ shift = force_number(s2)->numbr;
if (do_lint) {
if (val < 0 || shift < 0)
lintwarn(_("lshift(%lf, %lf): negative values will give strange results"), val, shift);
@@ -2814,8 +2995,8 @@ do_rshift(int nargs)
if ((s2->flags & (NUMCUR|NUMBER)) == 0)
lintwarn(_("rshift: received non-numeric second argument"));
}
- val = force_number(s1);
- shift = force_number(s2);
+ val = force_number(s1)->numbr;
+ shift = force_number(s2)->numbr;
if (do_lint) {
if (val < 0 || shift < 0)
lintwarn(_("rshift(%lf, %lf): negative values will give strange results"), val, shift);
@@ -2851,8 +3032,8 @@ do_and(int nargs)
if ((s2->flags & (NUMCUR|NUMBER)) == 0)
lintwarn(_("and: received non-numeric second argument"));
}
- left = force_number(s1);
- right = force_number(s2);
+ left = force_number(s1)->numbr;
+ right = force_number(s2)->numbr;
if (do_lint) {
if (left < 0 || right < 0)
lintwarn(_("and(%lf, %lf): negative values will give strange results"), left, right);
@@ -2886,8 +3067,8 @@ do_or(int nargs)
if ((s2->flags & (NUMCUR|NUMBER)) == 0)
lintwarn(_("or: received non-numeric second argument"));
}
- left = force_number(s1);
- right = force_number(s2);
+ left = force_number(s1)->numbr;
+ right = force_number(s2)->numbr;
if (do_lint) {
if (left < 0 || right < 0)
lintwarn(_("or(%lf, %lf): negative values will give strange results"), left, right);
@@ -2915,8 +3096,6 @@ do_xor(int nargs)
AWKNUM left, right;
POP_TWO_SCALARS(s1, s2);
- left = force_number(s1);
- right = force_number(s2);
if (do_lint) {
if ((s1->flags & (NUMCUR|NUMBER)) == 0)
@@ -2924,8 +3103,8 @@ do_xor(int nargs)
if ((s2->flags & (NUMCUR|NUMBER)) == 0)
lintwarn(_("xor: received non-numeric second argument"));
}
- left = force_number(s1);
- right = force_number(s2);
+ left = force_number(s1)->numbr;
+ right = force_number(s2)->numbr;
if (do_lint) {
if (left < 0 || right < 0)
lintwarn(_("xor(%lf, %lf): negative values will give strange results"), left, right);
@@ -2955,12 +3134,10 @@ do_compl(int nargs)
tmp = POP_SCALAR();
if (do_lint && (tmp->flags & (NUMCUR|NUMBER)) == 0)
lintwarn(_("compl: received non-numeric argument"));
- d = force_number(tmp);
+ d = force_number(tmp)->numbr;
DEREF(tmp);
if (do_lint) {
- if ((tmp->flags & (NUMCUR|NUMBER)) == 0)
- lintwarn(_("compl: received non-numeric argument"));
if (d < 0)
lintwarn(_("compl(%lf): negative value will give strange results"), d);
if (double_to_int(d) != d)
@@ -2982,11 +3159,11 @@ do_strtonum(int nargs)
tmp = POP_SCALAR();
if ((tmp->flags & (NUMBER|NUMCUR)) != 0)
- d = (AWKNUM) force_number(tmp);
- else if (isnondecimal(tmp->stptr, use_lc_numeric))
+ d = (AWKNUM) force_number(tmp)->numbr;
+ else if (get_numbase(tmp->stptr, use_lc_numeric) != 10)
d = nondec2awknum(tmp->stptr, tmp->stlen);
else
- d = (AWKNUM) force_number(tmp);
+ d = (AWKNUM) force_number(tmp)->numbr;
DEREF(tmp);
return make_number((AWKNUM) d);
@@ -3236,7 +3413,10 @@ do_dcngettext(int nargs)
}
#endif
- POP_NUMBER(d); /* third argument */
+ t2 = POP_NUMBER(); /* third argument */
+ d = get_number_d(t2);
+ DEREF(t2);
+
number = (unsigned long) double_to_int(d);
t2 = POP_STRING(); /* second argument */
string2 = t2->stptr;
diff --git a/cint_array.c b/cint_array.c
new file mode 100644
index 00000000..f82eb4b6
--- /dev/null
+++ b/cint_array.c
@@ -0,0 +1,1217 @@
+/*
+ * cint_array.c - routines for arrays of (mostly) consecutive positive integer indices.
+ */
+
+/*
+ * Copyright (C) 1986, 1988, 1989, 1991-2011 the Free Software Foundation, Inc.
+ *
+ * This file is part of GAWK, the GNU implementation of the
+ * AWK Programming Language.
+ *
+ * GAWK is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * GAWK is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
+ */
+
+#include "awk.h"
+
+extern FILE *output_fp;
+extern void indent(int indent_level);
+extern NODE **is_integer(NODE *symbol, NODE *subs);
+
+/*
+ * NHAT --- maximum size of a leaf array (2^NHAT).
+ * THRESHOLD --- Maximum capacity waste; THRESHOLD >= 2^(NHAT + 1).
+ */
+
+static int NHAT = 10;
+static long THRESHOLD;
+
+/* What is the optimium NHAT ? timing results suggest that 10 is a good choice,
+ * although differences aren't that significant for > 10.
+ */
+
+
+static NODE **cint_array_init(NODE *symbol, NODE *subs);
+static NODE **is_uinteger(NODE *symbol, NODE *subs);
+static NODE **cint_lookup(NODE *symbol, NODE *subs);
+static NODE **cint_exists(NODE *symbol, NODE *subs);
+static NODE **cint_clear(NODE *symbol, NODE *subs);
+static NODE **cint_remove(NODE *symbol, NODE *subs);
+static NODE **cint_list(NODE *symbol, NODE *t);
+static NODE **cint_copy(NODE *symbol, NODE *newsymb);
+static NODE **cint_dump(NODE *symbol, NODE *ndump);
+#ifdef ARRAYDEBUG
+static void cint_print(NODE *symbol);
+#endif
+
+array_ptr cint_array_func[] = {
+ cint_array_init,
+ is_uinteger,
+ cint_lookup,
+ cint_exists,
+ cint_clear,
+ cint_remove,
+ cint_list,
+ cint_copy,
+ cint_dump,
+};
+
+static inline int cint_hash(long k);
+static inline NODE **cint_find(NODE *symbol, long k, int h1);
+
+static inline NODE *make_node(NODETYPE type);
+
+static NODE **tree_lookup(NODE *symbol, NODE *tree, long k, int m, long base);
+static NODE **tree_exists(NODE *tree, long k);
+static void tree_clear(NODE *tree);
+static int tree_remove(NODE *symbol, NODE *tree, long k);
+static void tree_copy(NODE *newsymb, NODE *tree, NODE *newtree);
+static long tree_list(NODE *tree, NODE **list, unsigned int flags);
+static inline NODE **tree_find(NODE *tree, long k, int i);
+static void tree_info(NODE *tree, NODE *ndump, const char *aname);
+static size_t tree_kilobytes(NODE *tree);
+#ifdef ARRAYDEBUG
+static void tree_print(NODE *tree, size_t bi, int indent_level);
+#endif
+
+static inline NODE **leaf_lookup(NODE *symbol, NODE *array, long k, long size, long base);
+static inline NODE **leaf_exists(NODE *array, long k);
+static void leaf_clear(NODE *array);
+static int leaf_remove(NODE *symbol, NODE *array, long k);
+static void leaf_copy(NODE *newsymb, NODE *array, NODE *newarray);
+static long leaf_list(NODE *array, NODE **list, unsigned int flags);
+static void leaf_info(NODE *array, NODE *ndump, const char *aname);
+#ifdef ARRAYDEBUG
+static void leaf_print(NODE *array, size_t bi, int indent_level);
+#endif
+
+/* powers of 2 table upto 2^30 */
+static const long power_two_table[] = {
+ 1, 2, 4, 8, 16, 32, 64,
+ 128, 256, 512, 1024, 2048, 4096,
+ 8192, 16384, 32768, 65536, 131072, 262144,
+ 524288, 1048576, 2097152, 4194304, 8388608, 16777216,
+ 33554432, 67108864, 134217728, 268435456, 536870912, 1073741824
+};
+
+
+#define ISUINT(a, s) ((((s)->flags & NUMINT) != 0 || is_integer(a, s) != NULL) \
+ && (s)->numbr >= 0)
+
+/*
+ * To store 2^n integers, allocate top-level array of size n, elements
+ * of which are 1-Dimensional (leaf-array) of geometrically increasing
+ * size (power of 2).
+ *
+ * [0] --> [ 0 ]
+ * [1] --> [ 1 ]
+ * |2| --> [ 2 | 3 ]
+ * |3| --> [ 4 | 5 | 6 | 7 ]
+ * |.|
+ * |k| --> [ 2^(k - 1)| ... | 2^k - 1 ]
+ * ...
+ *
+ * For a given integer n (> 0), the leaf-array is at 1 + floor(log2(n)).
+ *
+ * The idea for the geometrically increasing array sizes is from:
+ * Fast Functional Lists, Hash-Lists, Deques and Variable Length Arrays.
+ * Bagwell, Phil (2002).
+ * http://infoscience.epfl.ch/record/64410/files/techlists.pdf
+ *
+ * Disadvantage:
+ * Worst case memory waste > 99% and will happen when each of the
+ * leaf arrays contains only a single element. Even with consecutive
+ * integers, memory waste can be as high as 50%.
+ *
+ * Solution: Hashed Array Trees (HATs).
+ *
+ */
+
+/* cint_array_init --- check relevant environment variables */
+
+static NODE **
+cint_array_init(NODE *symbol ATTRIBUTE_UNUSED, NODE *subs ATTRIBUTE_UNUSED)
+{
+ long newval;
+
+ if ((newval = getenv_long("NHAT")) > 1 && newval < INT32_BIT)
+ NHAT = newval;
+ THRESHOLD = power_two_table[NHAT + 1];
+ return (NODE **) ! NULL;
+}
+
+
+/* is_uinteger --- test if the subscript is an integer >= 0 */
+
+NODE **
+is_uinteger(NODE *symbol, NODE *subs)
+{
+ if (is_integer(symbol, subs) != NULL && subs->numbr >= 0)
+ return (NODE **) ! NULL;
+ return NULL;
+}
+
+
+/* cint_lookup --- Find the subscript in the array; Install it if it isn't there. */
+
+static NODE **
+cint_lookup(NODE *symbol, NODE *subs)
+{
+ NODE **lhs;
+ long k;
+ int h1 = -1, m, li;
+ NODE *tn, *xn;
+ long cint_size, capacity;
+
+ k = -1;
+ if (ISUINT(symbol, subs)) {
+ k = subs->numbr; /* k >= 0 */
+ h1 = cint_hash(k); /* h1 >= NHAT */
+ if ((lhs = cint_find(symbol, k, h1)) != NULL)
+ return lhs;
+ }
+ xn = symbol->xarray;
+ if (xn != NULL && (lhs = xn->aexists(xn, subs)) != NULL)
+ return lhs;
+
+ /* It's not there, install it */
+
+ if (k < 0)
+ goto xinstall;
+
+ m = h1 - 1; /* m >= (NHAT- 1) */
+
+ /* Estimate capacity upper bound.
+ * capacity upper bound = current capacity + leaf array size.
+ */
+ li = m > NHAT ? m : NHAT;
+ while (li >= NHAT) {
+ /* leaf-array of a HAT */
+ li = (li + 1) / 2;
+ }
+ capacity = symbol->array_capacity + power_two_table[li];
+
+ cint_size = (xn == NULL) ? symbol->table_size
+ : (symbol->table_size - xn->table_size);
+ assert(cint_size >= 0);
+ if ((capacity - cint_size) > THRESHOLD)
+ goto xinstall;
+
+ if (symbol->nodes == NULL) {
+ symbol->array_capacity = 0;
+ assert(symbol->table_size == 0);
+
+ /* nodes[0] .. nodes[NHAT- 1] not used */
+ emalloc(symbol->nodes, NODE **, INT32_BIT * sizeof(NODE *), "cint_lookup");
+ memset(symbol->nodes, '\0', INT32_BIT * sizeof(NODE *));
+ }
+
+ symbol->table_size++; /* one more element in array */
+
+ tn = symbol->nodes[h1];
+ if (tn == NULL) {
+ tn = make_node(Node_array_tree);
+ symbol->nodes[h1] = tn;
+ }
+
+ if (m < NHAT)
+ return tree_lookup(symbol, tn, k, NHAT, 0);
+ return tree_lookup(symbol, tn, k, m, power_two_table[m]);
+
+xinstall:
+
+ symbol->table_size++;
+ if (xn == NULL) {
+ extern array_ptr int_array_func[];
+ extern array_ptr str_array_func[];
+
+ xn = symbol->xarray = make_array();
+ xn->vname = symbol->vname; /* shallow copy */
+
+ /* Avoid using assoc_lookup(xn, subs) which may lead
+ * to infinite recursion.
+ */
+
+ if (is_integer(xn, subs))
+ xn->array_funcs = int_array_func;
+ else
+ xn->array_funcs = str_array_func;
+ xn->flags |= XARRAY;
+ }
+ return xn->alookup(xn, subs);
+}
+
+
+/* cint_exists --- test whether an index is in the array or not. */
+
+static NODE **
+cint_exists(NODE *symbol, NODE *subs)
+{
+ NODE *xn;
+
+ if (ISUINT(symbol, subs)) {
+ long k = subs->numbr;
+ NODE **lhs;
+ if ((lhs = cint_find(symbol, k, cint_hash(k))) != NULL)
+ return lhs;
+ }
+ if ((xn = symbol->xarray) == NULL)
+ return NULL;
+ return xn->aexists(xn, subs);
+}
+
+
+/* cint_clear --- flush all the values in symbol[] */
+
+static NODE **
+cint_clear(NODE *symbol, NODE *subs ATTRIBUTE_UNUSED)
+{
+ size_t i;
+ NODE *tn;
+
+ assert(symbol->nodes != NULL);
+
+ if (symbol->xarray != NULL) {
+ NODE *xn = symbol->xarray;
+ assoc_clear(xn);
+ freenode(xn);
+ symbol->xarray = NULL;
+ }
+
+ for (i = NHAT; i < INT32_BIT; i++) {
+ tn = symbol->nodes[i];
+ if (tn != NULL) {
+ tree_clear(tn);
+ freenode(tn);
+ }
+ }
+
+ efree(symbol->nodes);
+ init_array(symbol); /* re-initialize symbol */
+ return NULL;
+}
+
+
+/* cint_remove --- remove an index from the array */
+
+static NODE **
+cint_remove(NODE *symbol, NODE *subs)
+{
+ long k;
+ int h1;
+ NODE *tn, *xn = symbol->xarray;
+
+ if (symbol->table_size == 0)
+ return NULL;
+
+ if (! ISUINT(symbol, subs))
+ goto xremove;
+
+ assert(symbol->nodes != NULL);
+
+ k = subs->numbr;
+ h1 = cint_hash(k);
+ tn = symbol->nodes[h1];
+ if (tn == NULL || ! tree_remove(symbol, tn, k))
+ goto xremove;
+
+ if (tn->table_size == 0) {
+ freenode(tn);
+ symbol->nodes[h1] = NULL;
+ }
+
+ symbol->table_size--;
+
+ if (xn == NULL && symbol->table_size == 0) {
+ efree(symbol->nodes);
+ init_array(symbol); /* re-initialize array 'symbol' */
+ } else if(xn != NULL && symbol->table_size == xn->table_size) {
+ /* promote xn to symbol */
+
+ xn->flags &= ~XARRAY;
+ xn->parent_array = symbol->parent_array;
+ efree(symbol->nodes);
+ *symbol = *xn;
+ freenode(xn);
+ }
+
+ return (NODE **) ! NULL;
+
+xremove:
+ xn = symbol->xarray;
+ if (xn == NULL || xn->aremove(xn, subs) == NULL)
+ return NULL;
+ if (xn->table_size == 0) {
+ freenode(xn);
+ symbol->xarray = NULL;
+ }
+ symbol->table_size--;
+ assert(symbol->table_size > 0);
+
+ return (NODE **) ! NULL;
+}
+
+
+/* cint_copy --- duplicate input array "symbol" */
+
+static NODE **
+cint_copy(NODE *symbol, NODE *newsymb)
+{
+ NODE **old, **new;
+ size_t i;
+
+ assert(symbol->nodes != NULL);
+
+ /* allocate new table */
+ emalloc(new, NODE **, INT32_BIT * sizeof(NODE *), "cint_copy");
+ memset(new, '\0', INT32_BIT * sizeof(NODE *));
+
+ old = symbol->nodes;
+ for (i = NHAT; i < INT32_BIT; i++) {
+ if (old[i] == NULL)
+ continue;
+ new[i] = make_node(Node_array_tree);
+ tree_copy(newsymb, old[i], new[i]);
+ }
+
+ if (symbol->xarray != NULL) {
+ NODE *xn, *n;
+ xn = symbol->xarray;
+ n = make_array();
+ n->vname = newsymb->vname;
+ (void) xn->acopy(xn, n);
+ newsymb->xarray = n;
+ } else
+ newsymb->xarray = NULL;
+
+ newsymb->nodes = new;
+ newsymb->table_size = symbol->table_size;
+ newsymb->array_capacity = symbol->array_capacity;
+ newsymb->flags = symbol->flags;
+
+ return NULL;
+}
+
+
+/* cint_list --- return a list of items */
+
+static NODE**
+cint_list(NODE *symbol, NODE *t)
+{
+ NODE **list = NULL;
+ NODE *tn, *xn;
+ unsigned long k = 0, num_elems, list_size;
+ size_t j, ja, jd;
+ int elem_size = 1;
+
+ num_elems = symbol->table_size;
+ if (num_elems == 0)
+ return NULL;
+
+ if ((t->flags & (AINDEX|AVALUE|ADELETE)) == (AINDEX|ADELETE))
+ num_elems = 1;
+
+ if ((t->flags & (AINDEX|AVALUE)) == (AINDEX|AVALUE))
+ elem_size = 2;
+ list_size = num_elems * elem_size;
+
+ if (symbol->xarray != NULL) {
+ xn = symbol->xarray;
+ list = xn->alist(xn, t);
+ assert(list != NULL);
+ t->flags &= ~(AASC|ADESC);
+ if (num_elems == 1 || num_elems == xn->table_size)
+ return list;
+ erealloc(list, NODE **, list_size * sizeof(NODE *), "cint_list");
+ k = elem_size * xn->table_size;
+ } else
+ emalloc(list, NODE **, list_size * sizeof(NODE *), "cint_list");
+
+
+ if ((t->flags & AINUM) == 0) /* not sorting by "index num" */
+ t->flags &= ~(AASC|ADESC);
+
+ /* populate it with index in ascending or descending order */
+
+ for (ja = NHAT, jd = INT32_BIT - 1; ja < INT32_BIT && jd >= NHAT; ) {
+ j = (t->flags & ADESC) ? jd-- : ja++;
+ tn = symbol->nodes[j];
+ if (tn == NULL)
+ continue;
+ k += tree_list(tn, list + k, t->flags);
+ if (k >= list_size)
+ return list;
+ }
+ return list;
+}
+
+
+/* cint_dump --- dump array info */
+
+static NODE **
+cint_dump(NODE *symbol, NODE *ndump)
+{
+ NODE *tn, *xn = NULL;
+ int indent_level;
+ size_t i;
+ long cint_size = 0, xsize = 0;
+ AWKNUM kb = 0;
+ extern AWKNUM int_kilobytes(NODE *symbol);
+ extern AWKNUM str_kilobytes(NODE *symbol);
+ extern array_ptr int_array_func[];
+
+ indent_level = ndump->alevel;
+
+ if (symbol->xarray != NULL) {
+ xn = symbol->xarray;
+ xsize = xn->table_size;
+ }
+ cint_size = symbol->table_size - xsize;
+
+ if ((symbol->flags & XARRAY) == 0)
+ fprintf(output_fp, "%s `%s'\n",
+ (symbol->parent_array == NULL) ? "array" : "sub-array",
+ array_vname(symbol));
+ indent_level++;
+ indent(indent_level);
+ fprintf(output_fp, "array_func: cint_array_func\n");
+ if (symbol->flags != 0) {
+ indent(indent_level);
+ fprintf(output_fp, "flags: %s\n", flags2str(symbol->flags));
+ }
+ indent(indent_level);
+ fprintf(output_fp, "NHAT: %d\n", NHAT);
+ indent(indent_level);
+ fprintf(output_fp, "THRESHOLD: %ld\n", THRESHOLD);
+ indent(indent_level);
+ fprintf(output_fp, "table_size: %ld (total), %ld (cint), %ld (int + str)\n",
+ symbol->table_size, cint_size, xsize);
+ indent(indent_level);
+ fprintf(output_fp, "array_capacity: %lu\n", (unsigned long) symbol->array_capacity);
+ indent(indent_level);
+ fprintf(output_fp, "Load Factor: %.2g\n", (AWKNUM) cint_size / symbol->array_capacity);
+
+ for (i = NHAT; i < INT32_BIT; i++) {
+ tn = symbol->nodes[i];
+ if (tn == NULL)
+ continue;
+ /* Node_array_tree + HAT */
+ kb += (sizeof(NODE) + tree_kilobytes(tn)) / 1024.0;
+ }
+ kb += (INT32_BIT * sizeof(NODE *)) / 1024.0; /* symbol->nodes */
+ kb += (symbol->array_capacity * sizeof(NODE *)) / 1024.0; /* value nodes in Node_array_leaf(s) */
+ if (xn != NULL) {
+ if (xn->array_funcs == int_array_func)
+ kb += int_kilobytes(xn);
+ else
+ kb += str_kilobytes(xn);
+ }
+
+ indent(indent_level);
+ fprintf(output_fp, "memory: %.2g kB (total)\n", kb);
+
+ /* dump elements */
+
+ if (ndump->adepth >= 0) {
+ const char *aname;
+
+ fprintf(output_fp, "\n");
+ aname = make_aname(symbol);
+ for (i = NHAT; i < INT32_BIT; i++) {
+ tn = symbol->nodes[i];
+ if (tn != NULL)
+ tree_info(tn, ndump, aname);
+ }
+ }
+
+ if (xn != NULL) {
+ fprintf(output_fp, "\n");
+ xn->adump(xn, ndump);
+ }
+
+#ifdef ARRAYDEBUG
+ if (ndump->adepth < -999)
+ cint_print(symbol);
+#endif
+
+ return NULL;
+}
+
+
+/* cint_hash --- locate the HAT for a given number 'k' */
+
+static inline int
+cint_hash(long k)
+{
+ uint32_t num, r, shift;
+
+ assert(k >= 0);
+ if (k == 0)
+ return NHAT;
+ num = k;
+
+ /* Find the Floor(log base 2 of 32-bit integer) */
+
+ /* Warren Jr., Henry S. (2002). Hacker's Delight.
+ * Addison Wesley. pp. pp. 215. ISBN 978-0201914658.
+ *
+ * r = 0;
+ * if (num >= 1<<16) { num >>= 16; r += 16; }
+ * if (num >= 1<< 8) { num >>= 8; r += 8; }
+ * if (num >= 1<< 4) { num >>= 4; r += 4; }
+ * if (num >= 1<< 2) { num >>= 2; r += 2; }
+ * if (num >= 1<< 1) { r += 1; }
+ */
+
+
+ /* Slightly different code copied from:
+ *
+ * http://www-graphics.stanford.edu/~seander/bithacks.html
+ * Bit Twiddling Hacks
+ * By Sean Eron Anderson
+ * seander@cs.stanford.edu
+ * Individually, the code snippets here are in the public domain
+ * (unless otherwise noted) — feel free to use them however you please.
+ * The aggregate collection and descriptions are © 1997-2005
+ * Sean Eron Anderson. The code and descriptions are distributed in the
+ * hope that they will be useful, but WITHOUT ANY WARRANTY and without
+ * even the implied warranty of merchantability or fitness for a particular
+ * purpose.
+ *
+ */
+
+ r = (num > 0xFFFF) << 4; num >>= r;
+ shift = (num > 0xFF) << 3; num >>= shift; r |= shift;
+ shift = (num > 0x0F) << 2; num >>= shift; r |= shift;
+ shift = (num > 0x03) << 1; num >>= shift; r |= shift;
+ r |= (num >> 1);
+
+ /* We use a single HAT for 0 <= num < 2^NHAT */
+ if (r < NHAT)
+ return NHAT;
+
+ return (1 + r);
+}
+
+
+/* cint_find --- locate the integer subscript */
+
+static inline NODE **
+cint_find(NODE *symbol, long k, int h1)
+{
+ NODE *tn;
+
+ if (symbol->nodes == NULL || (tn = symbol->nodes[h1]) == NULL)
+ return NULL;
+ return tree_exists(tn, k);
+}
+
+
+#ifdef ARRAYDEBUG
+
+/* cint_print --- print structural info */
+
+static void
+cint_print(NODE *symbol)
+{
+ NODE *tn;
+ size_t i;
+
+ fprintf(output_fp, "I[%4lu:%-4lu]\n", (unsigned long) INT32_BIT,
+ (unsigned long) symbol->table_size);
+ for (i = NHAT; i < INT32_BIT; i++) {
+ tn = symbol->nodes[i];
+ if (tn == NULL)
+ continue;
+ tree_print(tn, i, 1);
+ }
+}
+
+#endif
+
+
+/*------------------------ Hashed Array Trees -----------------------------*/
+
+/*
+ * HATs: Hashed Array Trees
+ * Fast variable-length arrays
+ * Edward Sitarski
+ * http://www.drdobbs.com/architecture-and-design/184409965
+ *
+ * HAT has a top-level array containing a power of two
+ * number of leaf arrays. All leaf arrays are the same size as the
+ * top-level array. A full HAT can hold n^2 elements,
+ * where n (some power of 2) is the size of each leaf array.
+ * [i/n][i & (n - 1)] locates the `i th' element in a HAT.
+ *
+ */
+
+/*
+ * A half HAT is defined here as a HAT with a top-level array of size n^2/2
+ * and holds the first n^2/2 elements.
+ *
+ * 1. 2^8 elements can be stored in a full HAT of size 2^4.
+ * 2. 2^9 elements can be stored in a half HAT of size 2^5.
+ * 3. When the number of elements is some power of 2, it
+ * can be stored in a full or a half HAT.
+ * 4. When the number of elements is some power of 2, it
+ * can be stored in a HAT (full or half) with HATs as leaf elements
+ * (full or half), and so on (e.g. 2^8 elements in a HAT of size 2^4 (top-level
+ * array dimension) with each leaf array being a HAT of size 2^2).
+ *
+ * IMPLEMENTATION DETAILS:
+ * 1. A HAT of 2^12 elements needs 2^6 house-keeping NODEs
+ * of Node_array_leaf.
+ *
+ * 2. A HAT of HATS of 2^12 elements needs
+ * 2^6 * (1 Node_array_tree + 2^3 Node_array_leaf)
+ * ~ 2^9 house-keeping NODEs.
+ *
+ * 3. When a leaf array (or leaf HAT) becomes empty, the memory
+ * is deallocated, and when there is no leaf array (or leaf HAT) left,
+ * the HAT is deleted.
+ *
+ * 4. A HAT stores the base (first) element, and locates the leaf array/HAT
+ * for the `i th' element using integer division
+ * (i - base)/n where n is the size of the top-level array.
+ *
+ */
+
+/* make_node --- initialize a NODE */
+
+static inline NODE *
+make_node(NODETYPE type)
+{
+ NODE *n;
+ getnode(n);
+ memset(n, '\0', sizeof(NODE));
+ n->type = type;
+ return n;
+}
+
+
+/* tree_lookup --- Find an integer subscript in a HAT; Install it if it isn't there */
+
+static NODE **
+tree_lookup(NODE *symbol, NODE *tree, long k, int m, long base)
+{
+ NODE **lhs;
+ NODE *tn;
+ int i, n;
+ size_t size;
+ long num = k;
+
+ /*
+ * HAT size (size of Top & Leaf array) = 2^n
+ * where n = Floor ((m + 1)/2). For an odd value of m,
+ * only the first half of the HAT is needed.
+ */
+
+ n = (m + 1) / 2;
+
+ if (tree->table_size == 0) {
+ size_t actual_size;
+ NODE **table;
+
+ assert(tree->nodes == NULL);
+
+ /* initialize top-level array */
+ size = actual_size = power_two_table[n];
+ tree->array_base = base;
+ tree->array_size = size;
+ tree->table_size = 0; /* # of elements in the array */
+ if (n > m/2) {
+ /* only first half of the array used */
+ actual_size /= 2;
+ tree->flags |= HALFHAT;
+ }
+ emalloc(table, NODE **, actual_size * sizeof(NODE *), "tree_lookup");
+ memset(table, '\0', actual_size * sizeof(NODE *));
+ tree->nodes = table;
+ } else
+ size = tree->array_size;
+
+ num -= tree->array_base;
+ i = num / size; /* top-level array index */
+ assert(i >= 0);
+
+ if ((lhs = tree_find(tree, k, i)) != NULL)
+ return lhs;
+
+ /* It's not there, install it */
+
+ tree->table_size++;
+ base += (size * i);
+ tn = tree->nodes[i];
+ if (n > NHAT) {
+ if (tn == NULL)
+ tn = tree->nodes[i] = make_node(Node_array_tree);
+ return tree_lookup(symbol, tn, k, n, base);
+ } else {
+ if (tn == NULL)
+ tn = tree->nodes[i] = make_node(Node_array_leaf);
+ return leaf_lookup(symbol, tn, k, size, base);
+ }
+}
+
+
+/* tree_exists --- test whether integer subscript `k' exists or not */
+
+static NODE **
+tree_exists(NODE *tree, long k)
+{
+ int i;
+ NODE *tn;
+
+ i = (k - tree->array_base) / tree->array_size;
+ assert(i >= 0);
+ tn = tree->nodes[i];
+ if (tn == NULL)
+ return NULL;
+ if (tn->type == Node_array_tree)
+ return tree_exists(tn, k);
+ return leaf_exists(tn, k);
+}
+
+/* tree_clear --- flush all the values */
+
+static void
+tree_clear(NODE *tree)
+{
+ NODE *tn;
+ size_t j, hsize;
+
+ hsize = tree->array_size;
+ if ((tree->flags & HALFHAT) != 0)
+ hsize /= 2;
+
+ for (j = 0; j < hsize; j++) {
+ tn = tree->nodes[j];
+ if (tn == NULL)
+ continue;
+ if (tn->type == Node_array_tree)
+ tree_clear(tn);
+ else
+ leaf_clear(tn);
+ freenode(tn);
+ }
+
+ efree(tree->nodes);
+ memset(tree, '\0', sizeof(NODE));
+ tree->type = Node_array_tree;
+}
+
+
+/* tree_remove --- If the integer subscript is in the HAT, remove it */
+
+static int
+tree_remove(NODE *symbol, NODE *tree, long k)
+{
+ int i;
+ NODE *tn;
+
+ i = (k - tree->array_base) / tree->array_size;
+ assert(i >= 0);
+ tn = tree->nodes[i];
+ if (tn == NULL)
+ return FALSE;
+
+ if (tn->type == Node_array_tree
+ && ! tree_remove(symbol, tn, k))
+ return FALSE;
+ else if (tn->type == Node_array_leaf
+ && ! leaf_remove(symbol, tn, k))
+ return FALSE;
+
+ if (tn->table_size == 0) {
+ freenode(tn);
+ tree->nodes[i] = NULL;
+ }
+
+ /* one less item in array */
+ if (--tree->table_size == 0) {
+ efree(tree->nodes);
+ memset(tree, '\0', sizeof(NODE));
+ tree->type = Node_array_tree;
+ }
+ return TRUE;
+}
+
+
+/* tree_find --- locate an interger subscript in the HAT */
+
+static inline NODE **
+tree_find(NODE *tree, long k, int i)
+{
+ NODE *tn;
+
+ assert(tree->nodes != NULL);
+ tn = tree->nodes[i];
+ if (tn != NULL) {
+ if (tn->type == Node_array_tree)
+ return tree_exists(tn, k);
+ return leaf_exists(tn, k);
+ }
+ return NULL;
+}
+
+
+/* tree_list --- return a list of items in the HAT */
+
+static long
+tree_list(NODE *tree, NODE **list, unsigned int flags)
+{
+ NODE *tn;
+ size_t j, cj, hsize;
+ long k = 0;
+
+ assert(list != NULL);
+
+ hsize = tree->array_size;
+ if ((tree->flags & HALFHAT) != 0)
+ hsize /= 2;
+
+ for (j = 0; j < hsize; j++) {
+ cj = (flags & ADESC) ? (hsize - 1 - j) : j;
+ tn = tree->nodes[cj];
+ if (tn == NULL)
+ continue;
+ if (tn->type == Node_array_tree)
+ k += tree_list(tn, list + k, flags);
+ else
+ k += leaf_list(tn, list + k, flags);
+ if ((flags & ADELETE) != 0 && k >= 1)
+ return k;
+ }
+ return k;
+}
+
+
+/* tree_copy --- duplicate a HAT */
+
+static void
+tree_copy(NODE *newsymb, NODE *tree, NODE *newtree)
+{
+ NODE **old, **new;
+ size_t j, hsize;
+
+ hsize = tree->array_size;
+ if ((tree->flags & HALFHAT) != 0)
+ hsize /= 2;
+
+ emalloc(new, NODE **, hsize * sizeof(NODE *), "tree_copy");
+ memset(new, '\0', hsize * sizeof(NODE *));
+ newtree->nodes = new;
+ newtree->array_base = tree->array_base;
+ newtree->array_size = tree->array_size;
+ newtree->table_size = tree->table_size;
+ newtree->flags = tree->flags;
+
+ old = tree->nodes;
+ for (j = 0; j < hsize; j++) {
+ if (old[j] == NULL)
+ continue;
+ if (old[j]->type == Node_array_tree) {
+ new[j] = make_node(Node_array_tree);
+ tree_copy(newsymb, old[j], new[j]);
+ } else {
+ new[j] = make_node(Node_array_leaf);
+ leaf_copy(newsymb, old[j], new[j]);
+ }
+ }
+}
+
+
+/* tree_info --- print index, value info */
+
+static void
+tree_info(NODE *tree, NODE *ndump, const char *aname)
+{
+ NODE *tn;
+ size_t j, hsize;
+
+ hsize = tree->array_size;
+ if ((tree->flags & HALFHAT) != 0)
+ hsize /= 2;
+
+ for (j = 0; j < hsize; j++) {
+ tn = tree->nodes[j];
+ if (tn == NULL)
+ continue;
+ if (tn->type == Node_array_tree)
+ tree_info(tn, ndump, aname);
+ else
+ leaf_info(tn, ndump, aname);
+ }
+}
+
+
+/* tree_kilobytes --- calculate memory consumption of a HAT */
+
+static size_t
+tree_kilobytes(NODE *tree)
+{
+ NODE *tn;
+ size_t j, hsize;
+ size_t sz = 0;
+
+ hsize = tree->array_size;
+ if ((tree->flags & HALFHAT) != 0)
+ hsize /= 2;
+ for (j = 0; j < hsize; j++) {
+ tn = tree->nodes[j];
+ if (tn == NULL)
+ continue;
+ sz += sizeof(NODE); /* Node_array_tree or Node_array_leaf */
+ if (tn->type == Node_array_tree)
+ sz += tree_kilobytes(tn);
+ }
+ sz += hsize * sizeof(NODE *); /* tree->nodes */
+ return sz;
+}
+
+#ifdef ARRAYDEBUG
+
+/* tree_print --- print the HAT structures */
+
+static void
+tree_print(NODE *tree, size_t bi, int indent_level)
+{
+ NODE *tn;
+ size_t j, hsize;
+
+ indent(indent_level);
+
+ hsize = tree->array_size;
+ if ((tree->flags & HALFHAT) != 0)
+ hsize /= 2;
+ fprintf(output_fp, "%4lu:%s[%4lu:%-4lu]\n", bi,
+ (tree->flags & HALFHAT) ? "HH" : "H",
+ (unsigned long) hsize, (unsigned long) tree->table_size);
+
+ for (j = 0; j < hsize; j++) {
+ tn = tree->nodes[j];
+ if (tn == NULL)
+ continue;
+ if (tn->type == Node_array_tree)
+ tree_print(tn, j, indent_level + 1);
+ else
+ leaf_print(tn, j, indent_level + 1);
+ }
+}
+#endif
+
+/*--------------------- leaf (linear 1-D) array --------------------*/
+
+/* leaf_lookup --- find an integer subscript in the array; Install it if
+ it isn't there.
+*/
+
+static inline NODE **
+leaf_lookup(NODE *symbol, NODE *array, long k, long size, long base)
+{
+ NODE **lhs;
+
+ if (array->nodes == NULL) {
+ array->table_size = 0; /* sanity */
+ array->array_size = size;
+ array->array_base = base;
+ emalloc(array->nodes, NODE **, size * sizeof(NODE *), "leaf_lookup");
+ memset(array->nodes, '\0', size * sizeof(NODE *));
+ symbol->array_capacity += size;
+ }
+
+ lhs = array->nodes + (k - base); /* leaf element */
+ if (*lhs == NULL) {
+ array->table_size++; /* one more element in leaf array */
+ *lhs = dupnode(Nnull_string);
+ }
+ return lhs;
+}
+
+
+/* leaf_exists --- check if the array contains an integer subscript */
+
+static inline NODE **
+leaf_exists(NODE *array, long k)
+{
+ NODE **lhs;
+ lhs = array->nodes + (k - array->array_base);
+ return (*lhs != NULL) ? lhs : NULL;
+}
+
+
+/* leaf_clear --- flush all values in the array */
+
+static void
+leaf_clear(NODE *array)
+{
+ long i, size = array->array_size;
+ NODE *r;
+
+ for (i = 0; i < size; i++) {
+ r = array->nodes[i];
+ if (r == NULL)
+ continue;
+ if (r->type == Node_var_array) {
+ assoc_clear(r); /* recursively clear all sub-arrays */
+ efree(r->vname);
+ freenode(r);
+ } else
+ unref(r);
+ }
+ efree(array->nodes);
+ array->nodes = NULL;
+ array->array_size = array->table_size = 0;
+}
+
+
+/* leaf_remove --- remove an integer subscript from the array */
+
+static int
+leaf_remove(NODE *symbol, NODE *array, long k)
+{
+ NODE **lhs;
+
+ lhs = array->nodes + (k - array->array_base);
+ if (*lhs == NULL)
+ return FALSE;
+ *lhs = NULL;
+ if (--array->table_size == 0) {
+ efree(array->nodes);
+ array->nodes = NULL;
+ symbol->array_capacity -= array->array_size;
+ array->array_size = 0; /* sanity */
+ }
+ return TRUE;
+}
+
+
+/* leaf_copy --- duplicate a leaf array */
+
+static void
+leaf_copy(NODE *newsymb, NODE *array, NODE *newarray)
+{
+ NODE **old, **new;
+ long size, i;
+
+ size = array->array_size;
+ emalloc(new, NODE **, size * sizeof(NODE *), "leaf_copy");
+ memset(new, '\0', size * sizeof(NODE *));
+ newarray->nodes = new;
+ newarray->array_size = size;
+ newarray->array_base = array->array_base;
+ newarray->flags = array->flags;
+ newarray->table_size = array->table_size;
+
+ old = array->nodes;
+ for (i = 0; i < size; i++) {
+ if (old[i] == NULL)
+ continue;
+ if (old[i]->type == Node_val)
+ new[i] = dupnode(old[i]);
+ else {
+ NODE *r;
+ r = make_array();
+ r->vname = estrdup(old[i]->vname, strlen(old[i]->vname));
+ r->parent_array = newsymb;
+ new[i] = assoc_copy(old[i], r);
+ }
+ }
+}
+
+
+/* leaf_list --- return a list of items */
+
+static long
+leaf_list(NODE *array, NODE **list, unsigned int flags)
+{
+ NODE *r, *subs;
+ long num, i, ci, k = 0;
+ long size = array->array_size;
+ static char buf[100];
+
+ for (i = 0; i < size; i++) {
+ ci = (flags & ADESC) ? (size - 1 - i) : i;
+ r = array->nodes[ci];
+ if (r == NULL)
+ continue;
+
+ /* index */
+ num = array->array_base + ci;
+ if (flags & AISTR) {
+ sprintf(buf, "%ld", num);
+ subs = make_string(buf, strlen(buf));
+ subs->numbr = num;
+ subs->flags |= (NUMCUR|NUMINT);
+ } else {
+ subs = make_number((AWKNUM) num);
+ subs->flags |= (INTIND|NUMINT);
+ }
+ list[k++] = subs;
+
+ /* value */
+ if (flags & AVALUE) {
+ if (r->type == Node_val) {
+ if ((flags & AVNUM) != 0)
+ (void) force_number(r);
+ else if ((flags & AVSTR) != 0)
+ r = force_string(r);
+ }
+ list[k++] = r;
+ }
+ if ((flags & ADELETE) != 0 && k >= 1)
+ return k;
+ }
+
+ return k;
+}
+
+
+/* leaf_info --- print index, value info */
+
+static void
+leaf_info(NODE *array, NODE *ndump, const char *aname)
+{
+ NODE *subs, *val;
+ size_t i, size;
+
+ size = array->array_size;
+
+ subs = make_number((AWKNUM) 0.0);
+ subs->flags |= (INTIND|NUMINT);
+ for (i = 0; i < size; i++) {
+ val = array->nodes[i];
+ if (val == NULL)
+ continue;
+ subs->numbr = array->array_base + i;
+ assoc_info(subs, val, ndump, aname);
+ }
+ unref(subs);
+}
+
+#ifdef ARRAYDEBUG
+
+/* leaf_print --- print the leaf-array structure */
+
+
+static void
+leaf_print(NODE *array, size_t bi, int indent_level)
+{
+ indent(indent_level);
+ fprintf(output_fp, "%4lu:L[%4lu:%-4lu]\n", bi,
+ (unsigned long) array->array_size,
+ (unsigned long) array->table_size);
+}
+#endif
diff --git a/cmd.h b/cmd.h
index b5f4abfe..af6af8d8 100644
--- a/cmd.h
+++ b/cmd.h
@@ -28,8 +28,7 @@
#include <readline/history.h>
extern char **command_completion(const char *text, int start, int end);
extern void initialize_pager(FILE *fp); /* debug.c */
-extern NODE **get_varlist(void);
-extern char **get_parmlist(void);
+extern NODE *get_function(void);
#else
#define initialize_pager(x) /* nothing */
#define add_history(x) /* nothing */
diff --git a/command.c b/command.c
index 529a1958..f813a5a9 100644
--- a/command.c
+++ b/command.c
@@ -102,7 +102,7 @@ static int num_dim;
static int in_eval = FALSE;
static const char start_EVAL[] = "function @eval(){";
static const char end_EVAL[] = "}";
-static CMDARG *append_statement(CMDARG *alist, char *stmt);
+static CMDARG *append_statement(CMDARG *stmt_list, char *stmt);
static char *next_word(char *p, int len, char **endp);
static NODE *concat_args(CMDARG *a, int count);
@@ -2430,7 +2430,7 @@ yyreduce:
if ((n->flags & NUMBER) == 0)
yyerror(_("non-numeric value found, numeric expected"));
else
- (yyvsp[(2) - (2)])->a_node->numbr = - n->numbr;
+ negate_num(n);
(yyval) = (yyvsp[(2) - (2)]);
}
break;
@@ -2764,7 +2764,7 @@ yyreturn:
/* append_statement --- append 'stmt' to the list of eval awk statements */
static CMDARG *
-append_statement(CMDARG *alist, char *stmt)
+append_statement(CMDARG *stmt_list, char *stmt)
{
CMDARG *a, *arg;
char *s;
@@ -2774,7 +2774,7 @@ append_statement(CMDARG *alist, char *stmt)
if (stmt == start_EVAL) {
len = sizeof(start_EVAL);
- for (a = alist; a != NULL; a = a->next)
+ for (a = stmt_list; a != NULL; a = a->next)
len += strlen(a->a_string) + 1; /* 1 for ',' */
len += EVALSIZE;
@@ -2786,7 +2786,7 @@ append_statement(CMDARG *alist, char *stmt)
slen = sizeof("function @eval(") - 1;
memcpy(s, start_EVAL, slen);
- for (a = alist; a != NULL; a = a->next) {
+ for (a = stmt_list; a != NULL; a = a->next) {
len = strlen(a->a_string);
memcpy(s + slen, a->a_string, len);
slen += len;
@@ -2800,14 +2800,14 @@ append_statement(CMDARG *alist, char *stmt)
}
len = strlen(stmt) + 1; /* 1 for newline */
- s = alist->a_string;
+ s = stmt_list->a_string;
slen = strlen(s);
- ssize = alist->a_count;
+ ssize = stmt_list->a_count;
if (len > ssize - slen) {
ssize = slen + len + EVALSIZE;
erealloc(s, char *, (ssize + 2) * sizeof(char), "append_statement");
- alist->a_string = s;
- alist->a_count = ssize;
+ stmt_list->a_string = s;
+ stmt_list->a_count = ssize;
}
memcpy(s + slen, stmt, len);
slen += len;
@@ -2817,8 +2817,8 @@ append_statement(CMDARG *alist, char *stmt)
}
if (stmt == end_EVAL)
- erealloc(alist->a_string, char *, slen + 2, "append_statement");
- return alist;
+ erealloc(stmt_list->a_string, char *, slen + 2, "append_statement");
+ return stmt_list;
#undef EVALSIZE
}
@@ -3207,7 +3207,7 @@ err:
if (! want_nodeval) {
yylval = mk_cmdarg(D_string);
- yylval->a_string = estrdup(str, p - str);
+ yylval->a_string = str;
append_cmdarg(yylval);
return D_STRING;
} else { /* awk string */
@@ -3253,22 +3253,37 @@ err:
return D_STRING;
}
- /* assert(want_nodval == TRUE); */
-
/* look for awk number */
if (isdigit((unsigned char) tokstart[0])) {
- double d;
+ NODE *r = NULL;
errno = 0;
- d = strtod(tokstart, &lexptr);
+#ifdef HAVE_MPFR
+ if (do_mpfr) {
+ int tval;
+ r = mpg_float();
+ tval = mpfr_strtofr(r->mpg_numbr, tokstart, & lexptr, 0, ROUND_MODE);
+ IEEE_FMT(r->mpg_numbr, tval);
+ if (mpfr_integer_p(r->mpg_numbr)) {
+ /* integral value, convert to a GMP type. */
+ NODE *tmp = r;
+ r = mpg_integer();
+ mpfr_get_z(r->mpg_i, tmp->mpg_numbr, MPFR_RNDZ);
+ unref(tmp);
+ }
+ } else
+#endif
+ r = make_number(strtod(tokstart, & lexptr));
+
if (errno != 0) {
yyerror(strerror(errno));
+ unref(r);
errno = 0;
return '\n';
}
yylval = mk_cmdarg(D_node);
- yylval->a_node = make_number(d);
+ yylval->a_node = r;
append_cmdarg(yylval);
return D_NODE;
}
@@ -3398,8 +3413,10 @@ find_command(const char *token, size_t toklen)
&& strncmp(name, token, toklen) == 0
)
return i;
- if (*name > *token)
+
+ if (*name > *token || i == (k - 1))
try_exact = FALSE;
+
if (abrv_match < 0) {
abrv = cmdtab[i].abbrvn;
if (abrv[0] == token[0]) {
@@ -3539,6 +3556,7 @@ command_completion(const char *text, int start, int end)
return NULL;
}
}
+
if (this_cmd == D_print || this_cmd == D_printf)
return rl_completion_matches(text, variable_generator);
return NULL;
@@ -3599,7 +3617,7 @@ argument_generator(const char *text, int state)
{
static size_t textlen;
static int idx;
- char *name;
+ const char *name;
if (! state) { /* first time */
textlen = strlen(text);
@@ -3607,12 +3625,12 @@ argument_generator(const char *text, int state)
}
if (this_cmd == D_help) {
- while ((name = (char *) cmdtab[idx++].name) != NULL) {
+ while ((name = cmdtab[idx++].name) != NULL) {
if (strncmp(name, text, textlen) == 0)
return estrdup(name, strlen(name));
}
} else {
- while ((name = (char *) argtab[idx].name) != NULL) {
+ while ((name = argtab[idx].name) != NULL) {
if (this_cmd != argtab[idx++].cmd)
continue;
if (strncmp(name, text, textlen) == 0)
@@ -3629,45 +3647,39 @@ variable_generator(const char *text, int state)
{
static size_t textlen;
static int idx = 0;
- static char **pnames = NULL;
- static NODE **var_table = NULL;
- char *name;
- NODE *hp;
+ static NODE *func = NULL;
+ static NODE **vars = NULL;
+ const char *name;
+ NODE *r;
if (! state) { /* first time */
textlen = strlen(text);
- if (var_table != NULL)
- efree(var_table);
- var_table = get_varlist();
+ if (vars != NULL)
+ efree(vars);
+ vars = variable_list();
idx = 0;
- pnames = get_parmlist(); /* names of function params in
- * current context; the array
- * is NULL terminated in
- * awkgram.y (func_install).
- */
+ func = get_function(); /* function in current context */
}
/* function params */
- while (pnames != NULL) {
- name = pnames[idx];
- if (name == NULL) {
- pnames = NULL; /* don't try to match params again */
+ while (func != NULL) {
+ if (idx >= func->param_cnt) {
+ func = NULL; /* don't try to match params again */
idx = 0;
break;
}
- idx++;
+ name = func->fparms[idx++].param;
if (strncmp(name, text, textlen) == 0)
return estrdup(name, strlen(name));
}
/* globals */
- while ((hp = var_table[idx]) != NULL) {
- idx++;
- if (hp->hvalue->type == Node_func)
- continue;
- if (strncmp(hp->hname, text, textlen) == 0)
- return estrdup(hp->hname, hp->hlength);
+ while ((r = vars[idx++]) != NULL) {
+ name = r->vname;
+ if (strncmp(name, text, textlen) == 0)
+ return estrdup(name, strlen(name));
}
+
return NULL;
}
@@ -3693,4 +3705,3 @@ history_expand_line(char **line)
#endif
-
diff --git a/command.y b/command.y
index f2044bc9..a5a711b2 100644
--- a/command.y
+++ b/command.y
@@ -50,7 +50,7 @@ static int num_dim;
static int in_eval = FALSE;
static const char start_EVAL[] = "function @eval(){";
static const char end_EVAL[] = "}";
-static CMDARG *append_statement(CMDARG *alist, char *stmt);
+static CMDARG *append_statement(CMDARG *stmt_list, char *stmt);
static char *next_word(char *p, int len, char **endp);
static NODE *concat_args(CMDARG *a, int count);
@@ -686,7 +686,7 @@ node
if ((n->flags & NUMBER) == 0)
yyerror(_("non-numeric value found, numeric expected"));
else
- $2->a_node->numbr = - n->numbr;
+ negate_num(n);
$$ = $2;
}
;
@@ -750,7 +750,7 @@ nls
/* append_statement --- append 'stmt' to the list of eval awk statements */
static CMDARG *
-append_statement(CMDARG *alist, char *stmt)
+append_statement(CMDARG *stmt_list, char *stmt)
{
CMDARG *a, *arg;
char *s;
@@ -760,7 +760,7 @@ append_statement(CMDARG *alist, char *stmt)
if (stmt == start_EVAL) {
len = sizeof(start_EVAL);
- for (a = alist; a != NULL; a = a->next)
+ for (a = stmt_list; a != NULL; a = a->next)
len += strlen(a->a_string) + 1; /* 1 for ',' */
len += EVALSIZE;
@@ -772,7 +772,7 @@ append_statement(CMDARG *alist, char *stmt)
slen = sizeof("function @eval(") - 1;
memcpy(s, start_EVAL, slen);
- for (a = alist; a != NULL; a = a->next) {
+ for (a = stmt_list; a != NULL; a = a->next) {
len = strlen(a->a_string);
memcpy(s + slen, a->a_string, len);
slen += len;
@@ -786,14 +786,14 @@ append_statement(CMDARG *alist, char *stmt)
}
len = strlen(stmt) + 1; /* 1 for newline */
- s = alist->a_string;
+ s = stmt_list->a_string;
slen = strlen(s);
- ssize = alist->a_count;
+ ssize = stmt_list->a_count;
if (len > ssize - slen) {
ssize = slen + len + EVALSIZE;
erealloc(s, char *, (ssize + 2) * sizeof(char), "append_statement");
- alist->a_string = s;
- alist->a_count = ssize;
+ stmt_list->a_string = s;
+ stmt_list->a_count = ssize;
}
memcpy(s + slen, stmt, len);
slen += len;
@@ -803,8 +803,8 @@ append_statement(CMDARG *alist, char *stmt)
}
if (stmt == end_EVAL)
- erealloc(alist->a_string, char *, slen + 2, "append_statement");
- return alist;
+ erealloc(stmt_list->a_string, char *, slen + 2, "append_statement");
+ return stmt_list;
#undef EVALSIZE
}
@@ -1193,7 +1193,7 @@ err:
if (! want_nodeval) {
yylval = mk_cmdarg(D_string);
- yylval->a_string = estrdup(str, p - str);
+ yylval->a_string = str;
append_cmdarg(yylval);
return D_STRING;
} else { /* awk string */
@@ -1239,22 +1239,37 @@ err:
return D_STRING;
}
- /* assert(want_nodval == TRUE); */
-
/* look for awk number */
if (isdigit((unsigned char) tokstart[0])) {
- double d;
+ NODE *r = NULL;
errno = 0;
- d = strtod(tokstart, &lexptr);
+#ifdef HAVE_MPFR
+ if (do_mpfr) {
+ int tval;
+ r = mpg_float();
+ tval = mpfr_strtofr(r->mpg_numbr, tokstart, & lexptr, 0, ROUND_MODE);
+ IEEE_FMT(r->mpg_numbr, tval);
+ if (mpfr_integer_p(r->mpg_numbr)) {
+ /* integral value, convert to a GMP type. */
+ NODE *tmp = r;
+ r = mpg_integer();
+ mpfr_get_z(r->mpg_i, tmp->mpg_numbr, MPFR_RNDZ);
+ unref(tmp);
+ }
+ } else
+#endif
+ r = make_number(strtod(tokstart, & lexptr));
+
if (errno != 0) {
yyerror(strerror(errno));
+ unref(r);
errno = 0;
return '\n';
}
yylval = mk_cmdarg(D_node);
- yylval->a_node = make_number(d);
+ yylval->a_node = r;
append_cmdarg(yylval);
return D_NODE;
}
@@ -1384,8 +1399,10 @@ find_command(const char *token, size_t toklen)
&& strncmp(name, token, toklen) == 0
)
return i;
- if (*name > *token)
+
+ if (*name > *token || i == (k - 1))
try_exact = FALSE;
+
if (abrv_match < 0) {
abrv = cmdtab[i].abbrvn;
if (abrv[0] == token[0]) {
@@ -1525,6 +1542,7 @@ command_completion(const char *text, int start, int end)
return NULL;
}
}
+
if (this_cmd == D_print || this_cmd == D_printf)
return rl_completion_matches(text, variable_generator);
return NULL;
@@ -1585,7 +1603,7 @@ argument_generator(const char *text, int state)
{
static size_t textlen;
static int idx;
- char *name;
+ const char *name;
if (! state) { /* first time */
textlen = strlen(text);
@@ -1593,12 +1611,12 @@ argument_generator(const char *text, int state)
}
if (this_cmd == D_help) {
- while ((name = (char *) cmdtab[idx++].name) != NULL) {
+ while ((name = cmdtab[idx++].name) != NULL) {
if (strncmp(name, text, textlen) == 0)
return estrdup(name, strlen(name));
}
} else {
- while ((name = (char *) argtab[idx].name) != NULL) {
+ while ((name = argtab[idx].name) != NULL) {
if (this_cmd != argtab[idx++].cmd)
continue;
if (strncmp(name, text, textlen) == 0)
@@ -1615,45 +1633,39 @@ variable_generator(const char *text, int state)
{
static size_t textlen;
static int idx = 0;
- static char **pnames = NULL;
- static NODE **var_table = NULL;
- char *name;
- NODE *hp;
+ static NODE *func = NULL;
+ static NODE **vars = NULL;
+ const char *name;
+ NODE *r;
if (! state) { /* first time */
textlen = strlen(text);
- if (var_table != NULL)
- efree(var_table);
- var_table = get_varlist();
+ if (vars != NULL)
+ efree(vars);
+ vars = variable_list();
idx = 0;
- pnames = get_parmlist(); /* names of function params in
- * current context; the array
- * is NULL terminated in
- * awkgram.y (func_install).
- */
+ func = get_function(); /* function in current context */
}
/* function params */
- while (pnames != NULL) {
- name = pnames[idx];
- if (name == NULL) {
- pnames = NULL; /* don't try to match params again */
+ while (func != NULL) {
+ if (idx >= func->param_cnt) {
+ func = NULL; /* don't try to match params again */
idx = 0;
break;
}
- idx++;
+ name = func->fparms[idx++].param;
if (strncmp(name, text, textlen) == 0)
return estrdup(name, strlen(name));
}
/* globals */
- while ((hp = var_table[idx]) != NULL) {
- idx++;
- if (hp->hvalue->type == Node_func)
- continue;
- if (strncmp(hp->hname, text, textlen) == 0)
- return estrdup(hp->hname, hp->hlength);
+ while ((r = vars[idx++]) != NULL) {
+ name = r->vname;
+ if (strncmp(name, text, textlen) == 0)
+ return estrdup(name, strlen(name));
}
+
return NULL;
}
@@ -1678,4 +1690,3 @@ history_expand_line(char **line)
}
#endif
-
diff --git a/configh.in b/configh.in
index b186fec3..145615b3 100644
--- a/configh.in
+++ b/configh.in
@@ -150,6 +150,9 @@
/* we have the mktime function */
#undef HAVE_MKTIME
+/* Define to 1 if you have fully functional mpfr and gmp libraries. */
+#undef HAVE_MPFR
+
/* Define to 1 if you have the <netdb.h> header file. */
#undef HAVE_NETDB_H
diff --git a/configure b/configure
index e678fb13..08f64b5e 100755
--- a/configure
+++ b/configure
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for GNU Awk 4.0.1a.
+# Generated by GNU Autoconf 2.69 for GNU Awk 4.0.70.
#
# Report bugs to <bug-gawk@gnu.org>.
#
@@ -580,8 +580,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='GNU Awk'
PACKAGE_TARNAME='gawk'
-PACKAGE_VERSION='4.0.1a'
-PACKAGE_STRING='GNU Awk 4.0.1a'
+PACKAGE_VERSION='4.0.70'
+PACKAGE_STRING='GNU Awk 4.0.70'
PACKAGE_BUGREPORT='bug-gawk@gnu.org'
PACKAGE_URL='http://www.gnu.org/software/gawk/'
@@ -627,6 +627,7 @@ ac_func_list=
ac_subst_vars='am__EXEEXT_FALSE
am__EXEEXT_TRUE
LTLIBOBJS
+LIBMPFR
LIBREADLINE
SOCKET_LIBS
LIBSIGSEGV_PREFIX
@@ -757,6 +758,7 @@ with_libiconv_prefix
with_libintl_prefix
with_libsigsegv_prefix
with_readline
+with_mpfr
'
ac_precious_vars='build_alias
host_alias
@@ -1309,7 +1311,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures GNU Awk 4.0.1a to adapt to many kinds of systems.
+\`configure' configures GNU Awk 4.0.70 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1379,7 +1381,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of GNU Awk 4.0.1a:";;
+ short | recursive ) echo "Configuration of GNU Awk 4.0.70:";;
esac
cat <<\_ACEOF
@@ -1408,6 +1410,7 @@ Optional Packages:
--with-libsigsegv-prefix[=DIR] search for libsigsegv in DIR/include and DIR/lib
--without-libsigsegv-prefix don't search for libsigsegv in includedir and libdir
--with-readline=DIR look for the readline library in DIR
+ --with-mpfr=DIR look for the mpfr and gmp libraries in DIR
Some influential environment variables:
CC C compiler command
@@ -1493,7 +1496,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-GNU Awk configure 4.0.1a
+GNU Awk configure 4.0.70
generated by GNU Autoconf 2.69
Copyright (C) 2012 Free Software Foundation, Inc.
@@ -2202,7 +2205,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by GNU Awk $as_me 4.0.1a, which was
+It was created by GNU Awk $as_me 4.0.70, which was
generated by GNU Autoconf 2.69. Invocation command line was
$ $0 $@
@@ -3052,7 +3055,7 @@ fi
# Define the identity of the package.
PACKAGE='gawk'
- VERSION='4.0.1a'
+ VERSION='4.0.70'
cat >>confdefs.h <<_ACEOF
@@ -5528,7 +5531,7 @@ $as_echo_n "checking for special development options... " >&6; }
if test -f $srcdir/.developing
then
# add other debug flags as appropriate, save GAWKDEBUG for emergencies
- CFLAGS="$CFLAGS -DARRAYDEBUG -DYYDEBUG"
+ CFLAGS="$CFLAGS -DARRAYDEBUG"
if grep dbug $srcdir/.developing
then
CFLAGS="$CFLAGS -DDBUG"
@@ -5538,7 +5541,7 @@ then
# enable debugging using macros also
if test "$GCC" = yes
then
- CFLAGS="$CFLAGS -Wall -fno-builtin -g3 -gdwarf-2"
+ CFLAGS="$CFLAGS -Wall"
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
$as_echo "yes" >&6; }
@@ -10297,6 +10300,81 @@ $as_echo "#define HAVE_LIBREADLINE 1" >>confdefs.h
fi
+
+
+# Check whether --with-mpfr was given.
+if test "${with_mpfr+set}" = set; then :
+ withval=$with_mpfr; _do_mpfr=$withval
+else
+ _do_mpfr=yes
+fi
+
+
+ if test "$_do_mpfr" != "no" ; then
+ if test -d "$withval" ; then
+ CPPFLAGS="${CPPFLAGS} -I$withval/include"
+ LDFLAGS="${LDFLAGS} -L$withval/lib"
+ fi
+
+ _mpfr_save_libs=$LIBS
+ _combo="-lmpfr -lgmp"
+ LIBS="$LIBS $_combo"
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mpfr via \"$_combo\" is present and usable" >&5
+$as_echo_n "checking whether mpfr via \"$_combo\" is present and usable... " >&6; }
+
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+
+
+#include <stdio.h>
+#include <mpfr.h>
+#include <gmp.h>
+
+int
+main ()
+{
+
+mpfr_t p;
+mpz_t z;
+mpfr_init(p);
+mpz_init(z);
+mpfr_printf("%Rf%Zd", p, z);
+mpfr_clear(p);
+mpz_clear(z);
+
+ ;
+ return 0;
+}
+_ACEOF
+if ac_fn_c_try_link "$LINENO"; then :
+ _found_mpfr=yes
+else
+ _found_mpfr=no
+fi
+rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_found_mpfr" >&5
+$as_echo "$_found_mpfr" >&6; }
+
+ LIBS=$_mpfr_save_libs
+
+ if test $_found_mpfr = yes ; then
+
+$as_echo "#define HAVE_MPFR 1" >>confdefs.h
+
+ LIBMPFR=$_combo
+
+ break
+ fi
+
+ unset _mpfr_save_libs
+ unset _combo
+ unset _found_mpfr
+ fi
+
+
ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
if test "x$ac_cv_member_struct_stat_st_blksize" = xyes; then :
@@ -11219,7 +11297,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by GNU Awk $as_me 4.0.1a, which was
+This file was extended by GNU Awk $as_me 4.0.70, which was
generated by GNU Autoconf 2.69. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -11287,7 +11365,7 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
-GNU Awk config.status 4.0.1a
+GNU Awk config.status 4.0.70
configured by $0, generated by GNU Autoconf 2.69,
with options \\"\$ac_cs_config\\"
diff --git a/configure.ac b/configure.ac
index 274ec85b..dcf8c4b0 100644
--- a/configure.ac
+++ b/configure.ac
@@ -23,7 +23,7 @@ dnl
dnl Process this file with autoconf to produce a configure script.
-AC_INIT([GNU Awk], 4.0.1a, bug-gawk@gnu.org, gawk)
+AC_INIT([GNU Awk], 4.0.70, bug-gawk@gnu.org, gawk)
# This is a hack. Different versions of install on different systems
# are just too different. Chuck it and use install-sh.
@@ -80,7 +80,7 @@ AC_MSG_CHECKING([for special development options])
if test -f $srcdir/.developing
then
# add other debug flags as appropriate, save GAWKDEBUG for emergencies
- CFLAGS="$CFLAGS -DARRAYDEBUG -DYYDEBUG"
+ CFLAGS="$CFLAGS -DARRAYDEBUG"
if grep dbug $srcdir/.developing
then
CFLAGS="$CFLAGS -DDBUG"
@@ -90,7 +90,7 @@ then
# enable debugging using macros also
if test "$GCC" = yes
then
- CFLAGS="$CFLAGS -Wall -fno-builtin -g3 -gdwarf-2"
+ CFLAGS="$CFLAGS -Wall"
fi
AC_MSG_RESULT([yes])
else
@@ -342,6 +342,9 @@ GAWK_AC_LIB_SOCKETS
dnl check for readline support
GNUPG_CHECK_READLINE
+dnl check for mpfr support
+GNUPG_CHECK_MPFR
+
dnl checks for structure members
AC_STRUCT_ST_BLKSIZE
AC_HEADER_TIME
diff --git a/debug.c b/debug.c
index 4306392f..9f30ff9f 100644
--- a/debug.c
+++ b/debug.c
@@ -40,12 +40,9 @@ extern FILE *output_fp;
extern IOBUF *curfile;
extern const char *command_file;
extern const char *get_spec_varname(Func_ptr fptr);
-extern int r_interpret(INSTRUCTION *);
extern int zzparse(void);
#define read_command() (void) zzparse()
-extern int free_instruction(INSTRUCTION *, int *);
-extern void destroy_symbol(char *name);
extern const char *redir2str(int redirtype);
static char *linebuf = NULL; /* used to print a single line of source */
@@ -54,7 +51,7 @@ static size_t linebuf_len;
FILE *out_fp;
char *dbg_prompt;
char *commands_prompt = "> "; /* breakpoint or watchpoint commands list */
-char *eval_prompt = "@> "; /* awk statement(s) */
+char *eval_prompt = "@> "; /* awk statement(s) */
int input_from_tty = FALSE;
int input_fd;
@@ -176,7 +173,7 @@ static struct {
int break_point; /* non-zero (breakpoint number) if stopped at break point */
int watch_point; /* non-zero (watchpoint number) if stopped at watch point */
- int (*check_func)(INSTRUCTION **); /* function to decide when to suspend
+ int (*check_func)(INSTRUCTION **); /* function to decide when to suspend
* awk interpreter and return control
* to debugger command interpreter.
*/
@@ -216,9 +213,9 @@ struct dbg_option {
const char *help_txt;
};
-#define DEFAULT_HISTFILE "./.dgawk_history"
-#define DEFAULT_OPTFILE "./.dgawkrc"
-#define DEFAULT_PROMPT "dgawk> "
+#define DEFAULT_HISTFILE "./.gawk_history"
+#define DEFAULT_OPTFILE "./.gawkrc"
+#define DEFAULT_PROMPT "gawk> "
#define DEFAULT_LISTSIZE 15
#define DEFAULT_HISTSIZE 100
@@ -234,10 +231,10 @@ static const char *options_file = DEFAULT_OPTFILE;
static const char *history_file = DEFAULT_HISTFILE;
#endif
-/* keep all option variables in one place */
+/* debugger option related variables */
static char *output_file = "/dev/stdout"; /* gawk output redirection */
-char *dgawk_prompt = NULL; /* initialized in interpret */
+char *dgawk_prompt = NULL; /* initialized in interpret */
static int list_size = DEFAULT_LISTSIZE; /* # of lines that 'list' prints */
static int do_trace = FALSE;
static int do_save_history = TRUE;
@@ -267,7 +264,7 @@ static void save_options(const char *file);
/* pager */
jmp_buf pager_quit_tag;
-int pager_quit_tag_valid;
+int pager_quit_tag_valid = FALSE;
static int screen_width = INT_MAX; /* no of columns */
static int screen_height = INT_MAX; /* no of rows */
static int pager_lines_printed = 0; /* no of lines printed so far */
@@ -307,12 +304,13 @@ static struct list_item *add_item(struct list_item *list, int type, NODE *symbol
static void delete_item(struct list_item *d);
static int breakpoint_triggered(BREAKPOINT *b);
static int watchpoint_triggered(struct list_item *w);
-
static void print_instruction(INSTRUCTION *pc, Func_print print_func, FILE *fp, int in_dump);
+static int print_code(INSTRUCTION *pc, void *x);
static void next_command();
+static void debug_post_execute(INSTRUCTION *pc);
+static int debug_pre_execute(INSTRUCTION **pi);
static char *g_readline(const char *prompt);
static int prompt_yes_no(const char *, char , int , FILE *);
-
static struct pf_data {
Func_print print_func;
int defn;
@@ -328,16 +326,13 @@ struct command_source
char * (*read_func)(const char *);
int (*close_func)(int);
int eof_status; /* see push_cmd_src */
- int cmd; /* D_source or 0 */
- char *str; /* sourced file */
+ int cmd; /* D_source or 0 */
+ char *str; /* sourced file */
struct command_source *next;
};
static struct command_source *cmd_src = NULL;
-#define get_param_count(f) (f)->lnode->param_cnt
-#define get_params(f) (f)->parmlist
-
#define CHECK_PROG_RUNNING() \
do { \
@@ -490,11 +485,11 @@ source_find(char *src)
return s;
}
- path = find_source(src, &sbuf, &errno_val);
+ path = find_source(src, & sbuf, & errno_val, FALSE);
if (path != NULL) {
for (s = srcfiles->next; s != srcfiles; s = s->next) {
if ((s->stype == SRC_FILE || s->stype == SRC_INC)
- && files_are_same(path, s)) {
+ && files_are_same(path, s)) {
efree(path);
return s;
}
@@ -719,6 +714,8 @@ list:
int
do_info(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
{
+ NODE **table;
+
if (arg == NULL || arg->type != D_argument)
return FALSE;
@@ -804,7 +801,6 @@ do_info(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
INSTRUCTION *pc;
int arg_count, pcount;
int i, from, to;
- char **pnames;
CHECK_PROG_RUNNING();
f = find_frame(cur_frame);
@@ -815,8 +811,7 @@ do_info(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
return FALSE;
}
- pcount = get_param_count(func); /* # of defined params */
- pnames = get_params(func); /* param names */
+ pcount = func->param_cnt; /* # of defined params */
pc = (INSTRUCTION *) f->reti; /* Op_func_call instruction */
arg_count = (pc + 1)->expr_count; /* # of arguments supplied */
@@ -836,7 +831,7 @@ do_info(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
r = f->stack[i];
if (r->type == Node_array_ref)
r = r->orig_array;
- fprintf(out_fp, "%s = ", pnames[i]);
+ fprintf(out_fp, "%s = ", func->fparms[i].param);
print_symbol(r, TRUE);
}
if (to < from)
@@ -848,25 +843,28 @@ do_info(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
break;
case A_VARIABLES:
+ table = variable_list();
initialize_pager(out_fp);
if (setjmp(pager_quit_tag) == 0) {
gprintf(out_fp, _("All defined variables:\n\n"));
- print_vars(gprintf, out_fp);
+ print_vars(table, gprintf, out_fp);
}
+ efree(table);
break;
case A_FUNCTIONS:
+ table = function_list(TRUE);
initialize_pager(out_fp);
if (setjmp(pager_quit_tag) == 0) {
gprintf(out_fp, _("All defined functions:\n\n"));
pf_data.print_func = gprintf;
pf_data.fp = out_fp;
pf_data.defn = TRUE;
- (void) foreach_func((int (*)(INSTRUCTION *, void *)) print_function,
- FALSE, /* sort */
- &pf_data /* data */
- );
+ (void) foreach_func(table,
+ (int (*)(INSTRUCTION *, void *)) print_function,
+ &pf_data);
}
+ efree(table);
break;
case A_DISPLAY:
@@ -896,7 +894,7 @@ do_info(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
}
gprintf(out_fp, "\n");
} else if (IS_FIELD(d))
- gprintf(out_fp, "%d:\t$%ld\n", d->number, (long) symbol->numbr);
+ gprintf(out_fp, "%d:\t$%ld\n", d->number, get_number_si(symbol));
else
gprintf(out_fp, "%d:\t%s\n", d->number, d->sname);
if (d->cndn.code != NULL)
@@ -977,6 +975,7 @@ find_param(const char *name, long num, char **pname)
{
NODE *r = NULL;
NODE *f;
+ char *fparam;
if (pname)
*pname = NULL;
@@ -986,20 +985,18 @@ find_param(const char *name, long num, char **pname)
f = find_frame(num);
if (f->func_node != NULL) { /* in function */
NODE *func;
- char **pnames;
int i, pcount;
func = f->func_node;
- pnames = get_params(func);
- pcount = get_param_count(func);
-
+ pcount = func->param_cnt;
for (i = 0; i < pcount; i++) {
- if (strcmp(name, pnames[i]) == 0) {
+ fparam = func->fparms[i].param;
+ if (strcmp(name, fparam) == 0) {
r = f->stack[i];
if (r->type == Node_array_ref)
r = r->orig_array;
if (pname)
- *pname = pnames[i];
+ *pname = fparam;
break;
}
}
@@ -1059,7 +1056,7 @@ print_field(long field_num)
static int
print_array(volatile NODE *arr, char *arr_name)
{
- NODE *bucket;
+ NODE *subs;
NODE **list;
int i;
size_t num_elems = 0;
@@ -1067,7 +1064,7 @@ print_array(volatile NODE *arr, char *arr_name)
volatile int ret = 0;
volatile jmp_buf pager_quit_tag_stack;
- if (arr->var_array == NULL || arr->table_size == 0) {
+ if (array_empty(arr)) {
gprintf(out_fp, _("array `%s' is empty\n"), arr_name);
return 0;
}
@@ -1080,12 +1077,12 @@ print_array(volatile NODE *arr, char *arr_name)
PUSH_BINDING(pager_quit_tag_stack, pager_quit_tag, pager_quit_tag_valid);
if (setjmp(pager_quit_tag) == 0) {
for (i = 0; ret == 0 && i < num_elems; i++) {
- bucket = list[i];
- r = bucket->ahvalue;
+ subs = list[i];
+ r = *assoc_lookup((NODE *) arr, subs);
if (r->type == Node_var_array)
ret = print_array(r, r->vname);
else {
- gprintf(out_fp, "%s[\"%s\"] = ", arr_name, bucket->ahname_str);
+ gprintf(out_fp, "%s[\"%s\"] = ", arr_name, subs->stptr);
valinfo((NODE *) r, gprintf, out_fp);
}
}
@@ -1183,7 +1180,7 @@ do_print_var(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
break;
case D_field:
- print_field(a->a_node->numbr);
+ print_field(get_number_si(a->a_node));
break;
default:
@@ -1215,7 +1212,7 @@ do_set_var(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
switch (r->type) {
case Node_var_new:
r->type = Node_var;
- r->var_value = Nnull_string;
+ r->var_value = dupnode(Nnull_string);
/* fall through */
case Node_var:
lhs = &r->var_value;
@@ -1255,7 +1252,7 @@ do_set_var(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
else {
arg = arg->next;
val = arg->a_node;
- lhs = assoc_lookup(r, subs, FALSE);
+ lhs = assoc_lookup(r, subs);
unref(*lhs);
*lhs = dupnode(val);
fprintf(out_fp, "%s[\"%s\"] = ", name, subs->stptr);
@@ -1264,12 +1261,10 @@ do_set_var(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
} else {
if (value == NULL) {
NODE *array;
-
- getnode(array);
- array->type = Node_var_array;
- array->var_array = NULL;
+ array = make_array();
array->vname = estrdup(subs->stptr, subs->stlen);
- *assoc_lookup(r, subs, FALSE) = array;
+ array->parent_array = r;
+ *assoc_lookup(r, subs) = array;
r = array;
} else if (value->type != Node_var_array) {
d_error(_("attempt to use scalar `%s[\"%s\"]' as array"),
@@ -1289,7 +1284,7 @@ do_set_var(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
long field_num;
Func_ptr assign = NULL;
- field_num = (long) arg->a_node->numbr;
+ field_num = get_number_si(arg->a_node);
assert(field_num >= 0);
arg = arg->next;
val = arg->a_node;
@@ -1306,7 +1301,7 @@ do_set_var(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
break;
}
return FALSE;
-}
+}
/* find_item --- find an item in the watch/display list */
@@ -1378,14 +1373,18 @@ add_item(struct list_item *list, int type, NODE *symbol, char *pname)
d->fcall_count = fcall_count - cur_frame;
}
- if (type == D_field) { /* field number */
+ if (type == D_field) {
+ /* field number */
d->symbol = symbol;
d->flags |= FIELD_NUM;
- } else if (type == D_subscript) { /* subscript */
+ } else if (type == D_subscript) {
+ /* subscript */
d->symbol = symbol;
d->flags |= SUBSCRIPT;
- } else /* array or variable */
+ } else {
+ /* array or variable */
d->symbol = symbol;
+ }
/* add to list */
d->next = list->next;
@@ -1430,7 +1429,7 @@ do_add_item(struct list_item *list, CMDARG *arg)
for (i = 0; i < count; i++) {
arg = arg->next;
subs[i] = dupnode(arg->a_node);
- (void) force_string(subs[i]);
+ subs[i] = force_string(subs[i]);
}
item->subs = subs;
item->num_subs = count;
@@ -1535,7 +1534,7 @@ display(struct list_item *d)
} else if (IS_FIELD(d)) {
NODE *r = d->symbol;
fprintf(out_fp, "%d: ", d->number);
- print_field(r->numbr);
+ print_field(get_number_si(r));
} else {
print_sym:
fprintf(out_fp, "%d: %s = ", d->number, d->sname);
@@ -1592,13 +1591,12 @@ condition_triggered(struct condition *cndn)
return FALSE; /* not triggered */
force_number(r);
- di = (r->numbr != 0.0);
+ di = ! iszero(r);
DEREF(r);
return di;
}
-
static int
find_subscript(struct list_item *item, NODE **ptr)
{
@@ -1617,7 +1615,8 @@ find_subscript(struct list_item *item, NODE **ptr)
else if (i < count - 1)
return -1;
}
- *ptr = r;
+ if (r != NULL)
+ *ptr = r;
return 0;
}
@@ -1647,8 +1646,7 @@ cmp_val(struct list_item *w, NODE *old, NODE *new)
if (new->type == Node_val) /* 7 */
return TRUE;
/* new->type == Node_var_array */ /* 8 */
- if (new->var_array != NULL)
- size = new->table_size;
+ size = new->table_size;
if (w->cur_size == size)
return FALSE;
return TRUE;
@@ -1687,7 +1685,7 @@ watchpoint_triggered(struct list_item *w)
(void) find_subscript(w, &t2);
else if (IS_FIELD(w)) {
long field_num;
- field_num = (long) w->symbol->numbr;
+ field_num = get_number_si(w->symbol);
t2 = *get_field(field_num, NULL);
} else {
switch (symbol->type) {
@@ -1722,7 +1720,7 @@ watchpoint_triggered(struct list_item *w)
w->flags &= ~CUR_IS_ARRAY;
w->cur_value = dupnode(t2);
} else
- w->cur_size = (t2->var_array != NULL) ? t2->table_size : 0;
+ w->cur_size = (t2->type == Node_var_array) ? t2->table_size : 0;
} else if (! t1) { /* 1, 2 */
w->old_value = 0;
/* new != NULL */
@@ -1730,7 +1728,7 @@ watchpoint_triggered(struct list_item *w)
w->cur_value = dupnode(t2);
else {
w->flags |= CUR_IS_ARRAY;
- w->cur_size = (t2->var_array != NULL) ? t2->table_size : 0;
+ w->cur_size = (t2->type == Node_var_array) ? t2->table_size : 0;
}
} else /* if (t1->type == Node_val) */ { /* 4, 5, 6 */
w->old_value = w->cur_value;
@@ -1738,7 +1736,7 @@ watchpoint_triggered(struct list_item *w)
w->cur_value = 0;
else if (t2->type == Node_var_array) {
w->flags |= CUR_IS_ARRAY;
- w->cur_size = (t2->var_array != NULL) ? t2->table_size : 0;
+ w->cur_size = t2->table_size;
} else
w->cur_value = dupnode(t2);
}
@@ -1764,13 +1762,13 @@ initialize_watch_item(struct list_item *w)
w->cur_value = (NODE *) 0;
else if (r->type == Node_var_array) { /* it's a sub-array */
w->flags |= CUR_IS_ARRAY;
- w->cur_size = (r->var_array != NULL) ? r->table_size : 0;
+ w->cur_size = r->table_size;
} else
w->cur_value = dupnode(r);
} else if (IS_FIELD(w)) {
long field_num;
t = w->symbol;
- field_num = (long) t->numbr;
+ field_num = get_number_si(t);
r = *get_field(field_num, NULL);
w->cur_value = dupnode(r);
} else {
@@ -1781,7 +1779,7 @@ initialize_watch_item(struct list_item *w)
w->cur_value = dupnode(r);
} else if (symbol->type == Node_var_array) {
w->flags |= CUR_IS_ARRAY;
- w->cur_size = (symbol->var_array != NULL) ? symbol->table_size : 0;
+ w->cur_size = symbol->table_size;
} /* else
can't happen */
}
@@ -1809,7 +1807,7 @@ do_watch(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
fprintf(out_fp, "Watchpoint %d: ", w->number);
symbol = w->symbol;
-/* FIXME: common code also in print_watch_item */
+ /* FIXME: common code also in print_watch_item */
if (IS_SUBSCRIPT(w)) {
fprintf(out_fp, "%s", w->sname);
for (i = 0; i < w->num_subs; i++) {
@@ -1818,7 +1816,7 @@ do_watch(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
}
fprintf(out_fp, "\n");
} else if (IS_FIELD(w))
- fprintf(out_fp, "$%ld\n", (long) symbol->numbr);
+ fprintf(out_fp, "$%ld\n", get_number_si(symbol));
else
fprintf(out_fp, "%s\n", w->sname);
@@ -1873,19 +1871,17 @@ print_function(INSTRUCTION *pc, void *x)
{
NODE *func;
int i, pcount;
- char **pnames;
struct pf_data *data = (struct pf_data *) x;
int defn = data->defn;
Func_print print_func = data->print_func;
FILE *fp = data->fp;
func = pc->func_body;
- pcount = get_param_count(func);
- pnames = get_params(func);
+ pcount = func->param_cnt;
- print_func(fp, "%s(", func->lnode->param);
+ print_func(fp, "%s(", func->vname);
for (i = 0; i < pcount; i++) {
- print_func(fp, "%s", pnames[i]);
+ print_func(fp, "%s", func->fparms[i].param);
if (i < pcount - 1)
print_func(fp, ", ");
}
@@ -2368,7 +2364,7 @@ func:
rp = func->code_ptr;
if ((b = set_breakpoint_at(rp, rp->source_line, FALSE)) == NULL)
fprintf(out_fp, _("Can't set breakpoint in function `%s'\n"),
- func->lnode->param);
+ func->vname);
else if (temporary)
b->flags |= BP_TEMP;
lineno = b->bpi->source_line;
@@ -2495,7 +2491,7 @@ func:
}
if (! bp_found)
fprintf(out_fp, _("No breakpoint(s) at entry to function `%s'\n"),
- func->lnode->param);
+ func->vname);
else
fprintf(out_fp, "\n");
/* fall through */
@@ -2690,19 +2686,17 @@ do_disable_breakpoint(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
#ifdef HAVE_LIBREADLINE
-/* get_parmlist --- list of function params in current context */
+/* get_function --- function definition in current context */
-char **
-get_parmlist()
+NODE *
+get_function()
{
NODE *func;
if (! prog_running)
return NULL;
func = find_frame(cur_frame)->func_node;
- if (func == NULL) /* in main */
- return NULL;
- return func->parmlist;
+ return func;
}
/* initialize_readline --- initialize readline */
@@ -2728,10 +2722,19 @@ initialize_readline()
#endif
-/* interpret --- debugger entry point */
+/* init_debug --- register debugger exec hooks */
+
+void
+init_debug()
+{
+ register_exec_hook(debug_pre_execute, debug_post_execute);
+}
+
+
+/* debug_prog --- debugger entry point */
int
-interpret(INSTRUCTION *pc)
+debug_prog(INSTRUCTION *pc)
{
char *run;
@@ -2781,7 +2784,7 @@ interpret(INSTRUCTION *pc)
(void) do_run(NULL, 0);
} else if (command_file != NULL) {
- /* run commands from a file (--command=file or -R file) */
+ /* run commands from a file (--debug=file or -D file) */
int fd;
fd = open_readfd(command_file);
if (fd == INVALID_HANDLE) {
@@ -2928,14 +2931,14 @@ do_run(CMDARG *arg ATTRIBUTE_UNUSED, int cmd ATTRIBUTE_UNUSED)
prog_running = TRUE;
fatal_tag_valid = TRUE;
if (setjmp(fatal_tag) == 0)
- (void) r_interpret(code_block);
+ (void) interpret(code_block);
fatal_tag_valid = FALSE;
prog_running = FALSE;
fprintf(out_fp, _("Program exited %s with exit value: %d\n"),
- (! exiting && exit_val != EXIT_SUCCESS) ? "abnormally"
- : "normally",
- exit_val);
+ (! exiting && exit_val != EXIT_SUCCESS) ? "abnormally"
+ : "normally",
+ exit_val);
need_restart = TRUE;
return FALSE;
}
@@ -3135,7 +3138,6 @@ do_next(CMDARG *arg, int cmd)
static int
check_nexti(INSTRUCTION **pi)
{
-
/* make sure not to step inside function calls */
if (fcall_count < stop.fcall_count) {
@@ -3224,7 +3226,7 @@ check_return(INSTRUCTION **pi)
int
do_return(CMDARG *arg, int cmd)
{
- NODE *func;
+ NODE *func, *n;
CHECK_PROG_RUNNING();
func = find_frame(cur_frame)->func_node;
@@ -3241,12 +3243,11 @@ do_return(CMDARG *arg, int cmd)
stop.check_func = check_return;
- if (arg != NULL && arg->type == D_node) { /* optional return value */
- NODE *n;
+ if (arg != NULL && arg->type == D_node) /* optional return value */
n = dupnode(arg->a_node);
- PUSH(n);
- } else
- PUSH(Nnull_string);
+ else
+ n = dupnode(Nnull_string);
+ PUSH(n);
return TRUE;
}
@@ -3315,7 +3316,7 @@ do_until(CMDARG *arg, int cmd)
s = source_find(arg->a_string);
arg = arg->next;
if (s == NULL || arg == NULL
- || (arg->type != D_int && arg->type != D_func))
+ || (arg->type != D_int && arg->type != D_func))
return FALSE;
src = s->src;
if (arg->type == D_func)
@@ -3345,7 +3346,7 @@ func:
}
}
fprintf(out_fp, _("Can't find specified location in function `%s'\n"),
- func->lnode->param);
+ func->vname);
/* fall through */
default:
return FALSE;
@@ -3389,7 +3390,7 @@ print_watch_item(struct list_item *w)
}
fprintf(out_fp, "\n");
} else if (IS_FIELD(w))
- fprintf(out_fp, "$%ld\n", (long) symbol->numbr);
+ fprintf(out_fp, "$%ld\n", get_number_si(symbol));
else
fprintf(out_fp, "%s\n", w->sname);
@@ -3500,10 +3501,10 @@ no_output:
read_command(); /* zzparse */
}
-/* post_execute --- post_hook in the interpreter */
+/* debug_post_execute --- post_hook in the interpreter */
-void
-post_execute(INSTRUCTION *pc)
+static void
+debug_post_execute(INSTRUCTION *pc)
{
if (! in_main_context())
return;
@@ -3553,13 +3554,13 @@ post_execute(INSTRUCTION *pc)
}
}
-/* pre_execute --- pre_hook, called by the interpreter before execution;
+/* debug_pre_execute --- pre_hook, called by the interpreter before execution;
* checks if execution needs to be suspended and control
* transferred to the debugger.
*/
-int
-pre_execute(INSTRUCTION **pi)
+static int
+debug_pre_execute(INSTRUCTION **pi)
{
static int cant_stop = FALSE;
NODE *m;
@@ -3614,7 +3615,6 @@ pre_execute(INSTRUCTION **pi)
return TRUE;
case Op_func:
- case Op_ext_func:
case Op_var_update:
return TRUE;
@@ -3649,19 +3649,33 @@ pre_execute(INSTRUCTION **pi)
/* print_memory --- print a scalar value */
static void
-print_memory(NODE *m, char **fparms, Func_print print_func, FILE *fp)
+print_memory(NODE *m, NODE *func, Func_print print_func, FILE *fp)
{
switch (m->type) {
case Node_val:
if (m == Nnull_string)
print_func(fp, "Nnull_string");
- else if ((m->flags & NUMBER) != 0)
- print_func(fp, "%g", m->numbr);
- else if ((m->flags & STRING) != 0)
+ else if ((m->flags & NUMBER) != 0) {
+#ifdef HAVE_MPFR
+ if (m->flags & MPFN)
+ print_func(fp, "%s", mpg_fmt("%R*g", ROUND_MODE, m->mpg_numbr));
+ else if (m->flags & MPZN)
+ print_func(fp, "%s", mpg_fmt("%Zd", m->mpg_i));
+ else
+#endif
+ print_func(fp, "%g", m->numbr);
+ } else if ((m->flags & STRING) != 0)
pp_string_fp(print_func, fp, m->stptr, m->stlen, '"', FALSE);
- else if ((m->flags & NUMCUR) != 0)
- print_func(fp, "%g", m->numbr);
- else if ((m->flags & STRCUR) != 0)
+ else if ((m->flags & NUMCUR) != 0) {
+#ifdef HAVE_MPFR
+ if (m->flags & MPFN)
+ print_func(fp, "%s", mpg_fmt("%R*g", ROUND_MODE, m->mpg_numbr));
+ else if (m->flags & MPZN)
+ print_func(fp, "%s", mpg_fmt("%Zd", m->mpg_i));
+ else
+#endif
+ print_func(fp, "%g", m->numbr);
+ } else if ((m->flags & STRCUR) != 0)
pp_string_fp(print_func, fp, m->stptr, m->stlen, '"', FALSE);
else
print_func(fp, "-?-");
@@ -3676,8 +3690,8 @@ print_memory(NODE *m, char **fparms, Func_print print_func, FILE *fp)
break;
case Node_param_list:
- assert(fparms != NULL);
- print_func(fp, "%s", fparms[m->param_cnt]);
+ assert(func != NULL);
+ print_func(fp, "%s", func->fparms[m->param_cnt].param);
break;
case Node_var:
@@ -3696,9 +3710,8 @@ print_memory(NODE *m, char **fparms, Func_print print_func, FILE *fp)
static void
print_instruction(INSTRUCTION *pc, Func_print print_func, FILE *fp, int in_dump)
{
- static char **fparms = NULL;
int pcount = 0;
- NODE *func = NULL;
+ static NODE *func = NULL;
static int noffset = 0;
if (noffset == 0) {
@@ -3709,25 +3722,17 @@ print_instruction(INSTRUCTION *pc, Func_print print_func, FILE *fp, int in_dump)
if (pc->opcode == Op_func) {
func = pc->func_body;
- fparms = get_params(func);
- pcount = get_param_count(func);
+ pcount = func->param_cnt;
if (in_dump) {
int j;
- print_func(fp, "\n\t# Function: %s (", func->lnode->param);
+ print_func(fp, "\n\t# Function: %s (", func->vname);
for (j = 0; j < pcount; j++) {
- print_func(fp, "%s", fparms[j]);
+ print_func(fp, "%s", func->fparms[j].param);
if (j < pcount - 1)
print_func(fp, ", ");
}
print_func(fp, ")\n\n");
}
- } else if (pc->opcode == Op_ext_func) {
- func = pc->func_body;
- fparms = get_params(func);
- pcount = get_param_count(func);
- if (in_dump)
- print_func(fp, "\n\t# Extension function: %s (... %d params ...)\n\n",
- func->lnode->param, pcount);
} else if (pc->opcode == Op_rule) {
if (in_dump)
print_func(fp, "\n\t# %s\n\n", ruletab[pc->in_rule]);
@@ -3743,12 +3748,8 @@ print_instruction(INSTRUCTION *pc, Func_print print_func, FILE *fp, int in_dump)
pc->source_line, pc, opcode2str(pc->opcode));
if (prog_running && ! in_dump) {
- /* find params in the current frame */
+ /* find Node_func if in function */
func = find_frame(0)->func_node;
- if (func != NULL)
- fparms = get_params(func);
- /* else
- fparms = NULL; */
}
@@ -3774,10 +3775,6 @@ print_instruction(INSTRUCTION *pc, Func_print print_func, FILE *fp, int in_dump)
pc->target_assign, pc->do_reference ? "TRUE" : "FALSE");
break;
- case Op_ext_func:
- print_func(fp, "[param_cnt = %d]\n", pcount);
- break;
-
case Op_func:
print_func(fp, "[param_cnt = %d] [source_file = %s]\n", pcount,
pc->source_file ? pc->source_file : "cmd. line");
@@ -3852,7 +3849,7 @@ print_instruction(INSTRUCTION *pc, Func_print print_func, FILE *fp, int in_dump)
case Op_arrayfor_incr:
print_func(fp, "[array_var = %s] [target_jmp = %p]\n",
pc->array_var->type == Node_param_list ?
- fparms[pc->array_var->param_cnt] : pc->array_var->vname,
+ func->fparms[pc->array_var->param_cnt].param : pc->array_var->vname,
pc->target_jmp);
break;
@@ -3887,13 +3884,13 @@ print_instruction(INSTRUCTION *pc, Func_print print_func, FILE *fp, int in_dump)
break;
case Op_builtin:
- {
- const char *fname = getfname(pc->builtin);
- if (fname == NULL)
- print_func(fp, "(extension func) [arg_count = %ld]\n", pc->expr_count);
- else
- print_func(fp, "%s [arg_count = %ld]\n", fname, pc->expr_count);
- }
+ print_func(fp, "%s [arg_count = %ld]\n", getfname(pc->builtin),
+ pc->expr_count);
+ break;
+
+ case Op_ext_builtin:
+ print_func(fp, "%s [arg_count = %ld]\n", (pc + 1)->func_name,
+ pc->expr_count);
break;
case Op_subscript:
@@ -3902,7 +3899,7 @@ print_instruction(INSTRUCTION *pc, Func_print print_func, FILE *fp, int in_dump)
break;
case Op_store_sub:
- print_memory(pc->memory, fparms, print_func, fp);
+ print_memory(pc->memory, func, print_func, fp);
print_func(fp, " [sub_count = %ld]\n", pc->expr_count);
break;
@@ -3945,9 +3942,17 @@ print_instruction(INSTRUCTION *pc, Func_print print_func, FILE *fp, int in_dump)
print_func(fp, "[exec_count = %ld]\n", pc->exec_count);
break;
- case Op_store_var:
+ case Op_store_var:
+ print_memory(pc->memory, func, print_func, fp);
+ if (pc->initval != NULL) {
+ print_func(fp, " = ");
+ print_memory(pc->initval, func, print_func, fp);
+ }
+ print_func(fp, "\n");
+ break;
+
case Op_push_lhs:
- print_memory(pc->memory, fparms, print_func, fp);
+ print_memory(pc->memory, func, print_func, fp);
print_func(fp, " [do_reference = %s]\n",
pc->do_reference ? "TRUE" : "FALSE");
break;
@@ -3968,7 +3973,7 @@ print_instruction(INSTRUCTION *pc, Func_print print_func, FILE *fp, int in_dump)
case Op_quotient_i:
case Op_mod_i:
case Op_assign_concat:
- print_memory(pc->memory, fparms, print_func, fp);
+ print_memory(pc->memory, func, print_func, fp);
/* fall through */
default:
print_func(fp, "\n");
@@ -4006,7 +4011,8 @@ int
do_dump_instructions(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
{
FILE *fp;
-
+ NODE **funcs;
+
if (arg != NULL && arg->type == D_string) {
/* dump to a file */
if ((fp = fopen(arg->a_string, "w")) == NULL) {
@@ -4018,25 +4024,27 @@ do_dump_instructions(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
pf_data.fp = fp;
pf_data.defn = TRUE; /* in_dump = TRUE */
(void) print_code(code_block, &pf_data);
- (void) foreach_func((int (*)(INSTRUCTION *, void *)) print_code,
- FALSE, /* sort */
- &pf_data /* data */
- );
+ funcs = function_list(TRUE);
+ (void) foreach_func(funcs,
+ (int (*)(INSTRUCTION *, void *)) print_code,
+ &pf_data);
+ efree(funcs);
fclose(fp);
return FALSE;
}
+ funcs = function_list(TRUE);
initialize_pager(out_fp);
if (setjmp(pager_quit_tag) == 0) {
pf_data.print_func = gprintf;
pf_data.fp = out_fp;
pf_data.defn = TRUE; /* in_dump = TRUE */
(void) print_code(code_block, &pf_data);
- (void) foreach_func((int (*)(INSTRUCTION *, void *)) print_code,
- FALSE, /* sort */
- &pf_data /* data */
- );
+ (void) foreach_func(funcs,
+ (int (*)(INSTRUCTION *, void *)) print_code,
+ &pf_data);
}
+ efree(funcs);
return FALSE;
}
@@ -4378,7 +4386,7 @@ enlarge_buffer:
nchar = serialize_subscript(buf + bl, buflen - bl, wd);
else if (IS_FIELD(wd))
nchar = snprintf(buf + bl, buflen - bl, "%d%c%d%c%d%c",
- wd->number, FSEP, D_field, FSEP, (int) wd->symbol->numbr, FSEP);
+ wd->number, FSEP, D_field, FSEP, (int) get_number_si(wd->symbol), FSEP);
else
nchar = snprintf(buf + bl, buflen - bl, "%d%c%d%c%s%c",
wd->number, FSEP, D_variable, FSEP, wd->sname, FSEP);
@@ -4945,7 +4953,7 @@ do_print_f(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
{
long field_num;
r = a->a_node;
- field_num = (long) r->numbr;
+ field_num = get_number_si(r);
tmp[i] = *get_field(field_num, NULL);
}
break;
@@ -4958,7 +4966,7 @@ do_print_f(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
goto done;
for (; cnt > 0; cnt--) {
- NODE *value, *subs;
+ NODE *value, *subs;
a = a->next;
subs = a->a_node;
value = in_array(r, subs);
@@ -4996,7 +5004,7 @@ do_print_f(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
}
}
- force_string(tmp[0]);
+ tmp[0] = force_string(tmp[0]);
PUSH_BINDING(fatal_tag_stack, fatal_tag, fatal_tag_valid);
if (setjmp(fatal_tag) == 0)
@@ -5339,35 +5347,6 @@ close_all()
set_gawk_output(NULL); /* closes output_fp if not stdout */
}
-/* install_params --- install function parameters into the symbol table */
-
-static void
-install_params(NODE *func)
-{
- NODE *np;
-
- if (func == NULL)
- return;
- /* function parameters of type Node_param_list */
- np = func->lnode;
- for (np = np->rnode; np != NULL; np = np->rnode)
- install_symbol(np->param, np);
-}
-
-/* remove_params --- remove function parameters out of the symbol table */
-
-static void
-remove_params(NODE *func)
-{
- NODE *np;
-
- if (func == NULL)
- return;
- np = func->lnode;
- for (np = np->rnode; np != NULL; np = np->rnode)
- remove_symbol(np->param);
-}
-
/* pre_execute_code --- pre_hook for execute_code, called by pre_execute */
static int
@@ -5410,22 +5389,25 @@ execute_code(volatile INSTRUCTION *code)
volatile NODE *r = NULL;
volatile jmp_buf fatal_tag_stack;
long save_stack_size;
+ int save_flags = do_flags;
/* We use one global stack for all contexts.
* Save # of items in stack; in case of
* a fatal error, pop stack until it has that many items.
*/
+
save_stack_size = (stack_ptr - stack_bottom) + 1;
+ do_flags = FALSE;
PUSH_BINDING(fatal_tag_stack, fatal_tag, fatal_tag_valid);
if (setjmp(fatal_tag) == 0) {
- (void) r_interpret((INSTRUCTION *) code);
+ (void) interpret((INSTRUCTION *) code);
r = POP_SCALAR();
} else /* fatal error */
(void) unwind_stack(save_stack_size);
POP_BINDING(fatal_tag_stack, fatal_tag, fatal_tag_valid);
-
+ do_flags = save_flags;
if (exit_val != EXIT_SUCCESS) { /* must be EXIT_FATAL? */
exit_val = EXIT_SUCCESS;
return NULL;
@@ -5444,9 +5426,9 @@ do_eval(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
NODE **sp;
INSTRUCTION *eval, *code = NULL;
AWK_CONTEXT *ctxt;
- char **save_parmlist = NULL;
int ecount = 0, pcount = 0;
int ret;
+ int save_flags = do_flags;
if (prog_running) {
this_frame = find_frame(0);
@@ -5458,7 +5440,9 @@ do_eval(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
ctxt->install_func = append_symbol; /* keep track of newly installed globals */
push_context(ctxt);
(void) add_srcfile(SRC_CMDLINE, arg->a_string, srcfiles, NULL, NULL);
+ do_flags = FALSE;
ret = parse_program(&code);
+ do_flags = save_flags;
remove_params(this_func);
if (ret != 0) {
pop_context(); /* switch to prev context */
@@ -5480,9 +5464,7 @@ do_eval(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
} else {
/* execute as a part of the current function */
int i;
- char **varnames;
INSTRUCTION *t;
- NODE *np;
eval = f->code_ptr; /* Op_func */
eval->source_file = cur_srcfile->src;
@@ -5491,9 +5473,8 @@ do_eval(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
t->opcode = Op_stop;
/* add or append eval locals to the current frame stack */
- ecount = f->lnode->param_cnt; /* eval local count */
- pcount = this_func->lnode->param_cnt;
- save_parmlist = this_func->parmlist;
+ ecount = f->param_cnt; /* eval local count */
+ pcount = this_func->param_cnt;
if (ecount > 0) {
if (pcount == 0)
@@ -5501,26 +5482,22 @@ do_eval(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
else
erealloc(this_frame->stack, NODE **, (pcount + ecount) * sizeof(NODE *), "do_eval");
- emalloc(varnames, char **, (pcount + ecount + 1) * sizeof(char *), "do_eval");
- if (pcount > 0)
- memcpy(varnames, save_parmlist, pcount * sizeof(char *));
- for (np = f->lnode->rnode, i = 0; np != NULL; np = np->rnode, i++) {
- varnames[pcount + i] = np->param;
- np->param_cnt += pcount; /* appending eval locals: fixup param_cnt */
- }
- varnames[pcount + ecount] = NULL;
sp = this_frame->stack + pcount;
for (i = 0; i < ecount; i++) {
+ NODE *np;
+
+ np = f->fparms + i;
+ np->param_cnt += pcount; /* appending eval locals: fixup param_cnt */
+
getnode(r);
memset(r, 0, sizeof(NODE));
*sp++ = r;
/* local variable */
r->type = Node_var_new;
- r->vname = varnames[pcount + i];
+ r->vname = np->param;
}
- this_func->parmlist = varnames;
- this_func->lnode->param_cnt += ecount;
+ this_func->param_cnt += ecount;
}
}
@@ -5560,19 +5537,17 @@ do_eval(CMDARG *arg, int cmd ATTRIBUTE_UNUSED)
} /* else
restore_frame() will free it */
- efree(this_func->parmlist);
- this_func->parmlist = save_parmlist;
- this_func->lnode->param_cnt -= ecount;
+ this_func->param_cnt -= ecount;
}
/* always destroy symbol "@eval", however destroy all newly installed
- * globals only if fatal error in r_interpret (r == NULL).
+ * globals only if fatal error (execute_code() returing NULL).
*/
pop_context(); /* switch to prev context */
free_context(ctxt, (ret_val != NULL)); /* free all instructions and optionally symbols */
if (ret_val != NULL)
- destroy_symbol("@eval"); /* destroy "@eval" */
+ destroy_symbol(f); /* destroy "@eval" */
return FALSE;
}
@@ -5589,13 +5564,13 @@ an error message:
static int invalid_symbol = 0;
-void
-check_symbol(char *name)
+static void
+check_symbol(NODE *r)
{
invalid_symbol++;
- d_error(_("No symbol `%s' in current context"), name);
+ d_error(_("No symbol `%s' in current context"), r->vname);
/* install anyway, but keep track of it */
- append_symbol(name);
+ append_symbol(r);
}
/* parse_condition --- compile a condition expression */
@@ -5611,6 +5586,7 @@ parse_condition(int type, int num, char *expr)
NODE *this_func = NULL;
INSTRUCTION *it, *stop, *rule;
struct condition *cndn = NULL;
+ int save_flags = do_flags;
if (type == D_break && (b = find_breakpoint(num)) != NULL) {
INSTRUCTION *rp;
@@ -5634,7 +5610,9 @@ parse_condition(int type, int num, char *expr)
ctxt->install_func = check_symbol;
push_context(ctxt);
(void) add_srcfile(SRC_CMDLINE, expr, srcfiles, NULL, NULL);
+ do_flags = FALSE;
ret = parse_program(&code);
+ do_flags = save_flags;
remove_params(this_func);
pop_context();
@@ -5654,8 +5632,8 @@ parse_condition(int type, int num, char *expr)
it = rule->firsti; /* Op_K_print_rec */
assert(it->opcode == Op_K_print_rec);
- it->opcode = Op_push_i;
- it->memory = mk_number((AWKNUM) 1.0, PERM|NUMBER|NUMCUR);
+ it->opcode = Op_push_i;
+ it->memory = make_number(1.0);
it->nexti = bcalloc(Op_jmp, 1, 0);
it->nexti->target_jmp = stop;
it->nexti->nexti = rule->lasti;
@@ -5663,7 +5641,7 @@ parse_condition(int type, int num, char *expr)
it = rule->lasti; /* Op_no_op, target for Op_jmp_false */
assert(it->opcode == Op_no_op);
it->opcode = Op_push_i;
- it->memory = mk_number((AWKNUM) 0.0, PERM|NUMBER|NUMCUR);
+ it->memory = make_number(0.0);
it->nexti = stop;
out:
@@ -5743,7 +5721,7 @@ push_cmd_src(
cs->str = NULL;
cs->next = cmd_src;
cmd_src = cs;
-
+
input_fd = fd;
input_from_tty = istty;
read_a_line = readfunc;
diff --git a/doc/ChangeLog b/doc/ChangeLog
index 4d178867..7ea0c491 100644
--- a/doc/ChangeLog
+++ b/doc/ChangeLog
@@ -6,6 +6,46 @@
* texinfo.tex: Update to latest from automake 1.11.4.
+2012-04-11 John Haque <j.eh@mchsi.com>
+
+ * gawk.texi: Change RNDMODE to ROUNDMODE.
+ * gawk.1, awkcard.in: Ditto.
+
+2012-04-11 Arnold D. Robbins <arnold@skeeve.com>
+
+ * gawk.texi: Change --arbitrary-precision to --bignum.
+ * gawk.1: Ditto.
+ * awkcard.in: Add --bignum, RNDMODE, PREC.
+
+2012-04-08 Arnold D. Robbins <arnold@skeeve.com>
+
+ * gawk.texi: Editing on new chapter on arbitrary precision numbers.
+
+2012-03-31 John Haque <j.eh@mchsi.com>
+
+ * gawk.texi, gawk.1: Add text on support for arbitrary precision
+ numbers.
+
+2012-02-06 Arnold D. Robbins <arnold@skeeve.com>
+
+ * gawk.texi, gawk.1: And some minor edits thereunto.
+
+2012-02-03 John Haque <j.eh@mchsi.com>
+
+ * gawk.texi, gawk.1: Add text on read timeout.
+
+2011-12-28 Arnold D. Robbins <arnold@skeeve.com>
+
+ * awkcard.in, gawk.1: Minor edits after merge of executables.
+
+2011-12-21 John Haque <j.eh@mchsi.com>
+
+ * gawk.texi: Updated sections on profiling and debugging
+ after merging the exes. Document new options --debug and
+ --load, and add a sub-section on loading extension library.
+ * gawk.1: Same.
+ * awkcard.in: Same.
+
2012-03-28 Arnold D. Robbins <arnold@skeeve.com>
* 4.0.1: Release tar ball made.
@@ -39,6 +79,10 @@
Jeroen Schot <schot@A-Eskwadraat.nl>.
* gawk.texi: Some minor fixes.
+2011-08-31 John Haque <j.eh@mchsi.com>
+
+ * gawk.texi: Updated gawk dynamic extension doc.
+
2011-07-28 Arnold D. Robbins <arnold@skeeve.com>
* gawk.texi (Gory Details): Restore text on historical behavior
diff --git a/doc/Makefile.in b/doc/Makefile.in
index beaad1f1..70c6abe3 100644
--- a/doc/Makefile.in
+++ b/doc/Makefile.in
@@ -84,11 +84,11 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/arch.m4 \
$(top_srcdir)/m4/isc-posix.m4 $(top_srcdir)/m4/lcmessage.m4 \
$(top_srcdir)/m4/lib-ld.m4 $(top_srcdir)/m4/lib-link.m4 \
$(top_srcdir)/m4/lib-prefix.m4 $(top_srcdir)/m4/libsigsegv.m4 \
- $(top_srcdir)/m4/longlong.m4 $(top_srcdir)/m4/nls.m4 \
- $(top_srcdir)/m4/noreturn.m4 $(top_srcdir)/m4/po.m4 \
- $(top_srcdir)/m4/progtest.m4 $(top_srcdir)/m4/readline.m4 \
- $(top_srcdir)/m4/socket.m4 $(top_srcdir)/m4/ulonglong.m4 \
- $(top_srcdir)/configure.ac
+ $(top_srcdir)/m4/longlong.m4 $(top_srcdir)/m4/mpfr.m4 \
+ $(top_srcdir)/m4/nls.m4 $(top_srcdir)/m4/noreturn.m4 \
+ $(top_srcdir)/m4/po.m4 $(top_srcdir)/m4/progtest.m4 \
+ $(top_srcdir)/m4/readline.m4 $(top_srcdir)/m4/socket.m4 \
+ $(top_srcdir)/m4/ulonglong.m4 $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
@@ -180,6 +180,7 @@ INTL_MACOSX_LIBS = @INTL_MACOSX_LIBS@
LDFLAGS = @LDFLAGS@
LIBICONV = @LIBICONV@
LIBINTL = @LIBINTL@
+LIBMPFR = @LIBMPFR@
LIBOBJS = @LIBOBJS@
LIBREADLINE = @LIBREADLINE@
LIBS = @LIBS@
diff --git a/doc/awkcard.in b/doc/awkcard.in
index 22b4716f..b7d87691 100644
--- a/doc/awkcard.in
+++ b/doc/awkcard.in
@@ -26,7 +26,6 @@
.\" Strings to save typing
.ds AK \*(FCawk\*(FR
.ds GK \*(FCgawk\*(FR
-.ds PK \*(FCpgawk\*(FR
.ds NK Bell Labs \*(FCawk\*(FR
.ds MK \*(FCmawk\*(FR
.\"
@@ -77,7 +76,7 @@ Pattern Elements 8
Printf Formats 14
Records 10
Regular Expressions 11
-Signals (\*(PK) 4
+Signals (\*(GK \*(FC\-\^\-profile\*(FR) 4
Special Filenames 12
String Functions 16
Time Functions (\*(GK) 17
@@ -254,6 +253,9 @@ their types and final values to
If no \*(FIfile\*(FR
is provided, \*(FCgawk\*(FR
uses \*(FCawkvars.out\*(FR.
+.TI "\*(FC\-D\*(FR[\*(FC\*(FIfile\*(FR], \*(FC\-\^\-debug\*(FR[\*(FC=\*(FIfile\*(FR]
+Enable debugging of program. Optionally read stored commands
+from \*(FIfile\*(FR.
.TI "\*(FC-e '\*(FItext\*(FC'\*(FR, \*(FC\-\^\-source '\*(FItext\*(FC'\*(FR
Use \*(FItext\*(FR as AWK program source code.
.TI "\*(FC\-E \*(FIfile\*(FR, \*(FC\-\^\-exec \*(FIfile\*(FR
@@ -269,6 +271,8 @@ for localization.
.TI "\*(FC\-h\*(FR, \*(FC\-\^\-help\*(FR
Print a short summary of the available
options on \*(FCstdout\*(FR, then exit zero.
+.TI "\*(FC\-l \*(FIlib\*(FR, \*(FC\-\^\-load \*(FIlib\*(FR
+Load dynamic extension \*(FIlib\fP.
.TI "\*(FC\-L \*(FR[\*(FC\*(FIvalue\*(FR], \*(FC\-\^\-lint\*(FR[\*(FC=\*(FIvalue\*(FR]
Warn about dubious or non-portable constructs.
If \*(FIvalue\*(FR is
@@ -278,36 +282,31 @@ If \*(FIvalue\*(FR is
\*(FCinvalid\*(FR,
only issue warnings about things that are
actually invalid (not fully implemented yet).
+.TI "\*(FC\-M\*(FR, \*(FC\-\^\-bignum\*(FR
+Enable arbitrary-precision arithmetic.
.TI "\*(FC\-n\*(FR, \*(FC\-\^\-non\-decimal\-data\*(FR
Recognize octal and hexadecimal values in input data.
\*(FIUse this option with great caution!\*(FR
.TI "\*(FC\-N\*(FR, \*(FC\-\^\-use\-lc\-numeric\*(FR
Force use of the locale's decimal point character when parsing input data.
+.TI "\*(FC\-o\*(FR[\*(FC\*(FIfile\*(FR], \*(FC\-\^\-pretty-print\*(FR[\*(FC=\*(FIfile\*(FR]
+Output a pretty printed version of the program to \*(FIfile\*(FR
+(default: \*(FCawkprof.out\*(FR).
.TI "\*(FC\-O\*(FR, \*(FC\-\^\-optimize\*(FR
Enable some internal optimizations.
.TI "\*(FC\-p\*(FR[\*(FC\*(FIfile\*(FR], \*(FC\-\^\-profile\*(FR[\*(FC=\*(FIfile\*(FR]
Send profiling data to \*(FIfile\*(FR
(default: \*(FCawkprof.out\*(FR).
-With \*(GK,
-the profile is just a ``pretty printed'' version of the program.
-With \*(PK,
-the profile contains execution counts in the left margin
+The profile contains execution counts in the left margin
of each statement in the program.
.TI "\*(FC\-P\*(FR, \*(FC\-\^\-posix\*(FR
Disable common and GNU extensions.
-.TI "\*(FC\-R \*(FIfile\*(FR, \*(FC\-\^\-command \*(FIfile\*(FR"
-\*(FCdgawk\*(FR only.
-Read stored debugger commands from \*(FIfile\*(FR.
.TI "\*(FC\-r\*(FR, \*(FC\-\^\-re\-interval\*(FR
-Enable \*(FIinterval expressions\*(FR in regular
-expression matching (see \fHRegular
-Expressions\fP below). Useful if
-\*(FC\-\^\-traditional\*(FR is specified.
-.TI "\*(FC\-S\*(FR, \*(FC\-\^\-sandbox\*(FR
-Disable the \*(FCsystem()\*(FR function,
-input redirection with \*(FCgetline\*(FR,
-output redirection with \*(FCprint\*(FR and \*(FCprintf\*(FR,
-and dynamic extensions loading.\*(CB
+Enable \*(FIinterval expressions\*(FR.\*(CB
+... in regular
+... expression matching (see \fHRegular
+... Expressions\fP below). Useful if
+... \*(FC\-\^\-traditional\*(FR is specified
.in -4n
.EB "\s+2\f(HBCOMMAND LINE ARGUMENTS (\*(GK\f(HB)\*(FR\s0"
@@ -319,6 +318,11 @@ and dynamic extensions loading.\*(CB
.ES
.fi
.in +4n
+.TI "\*(FC\-S\*(FR, \*(FC\-\^\-sandbox\*(FR
+Disable the \*(FCsystem()\*(FR function,
+input redirection with \*(FCgetline\*(FR,
+output redirection with \*(FCprint\*(FR and \*(FCprintf\*(FR,
+and dynamic extensions loading.
.TI "\*(FC-t\*(FR, \*(FC\-\^\-lint\-old\*(FR
Warn about constructs that are not
portable to the original version of
@@ -383,14 +387,14 @@ The options may be abbreviated using just the first letter, e.g.,
and so on.\*(CB
.EB "\s+2\f(HBCOMMAND LINE ARGUMENTS (\*(MK\f(HB)\*(FR\s0"
.sp .7
-.\" --- Signals (pgawk)
+.\" --- Signals (gawk --profile)
.ES
.fi
-\*(CD\*(PK accepts two signals.
+\*(CD\*(GK accepts two signals while profiling.
\*(FCSIGUSR1\fP dumps a profile and function call stack to the
profile file. It then continues to run.
\*(FCSIGHUP\fP is similar, but exits.\*(CB
-.EB "\s+2\f(HBSIGNALS (\*(PK\f(HB)\*(FR\s0"
+.EB "\s+2\f(HBSIGNALS (\*(GK \f(HB\-\^\-profile)\*(FR\s0"
.\" --- Lines And Statements
.ES
@@ -609,7 +613,11 @@ T}
\*(FCORS\fP T{
Output record separator, a newline by default.
T}
-\*(CB\*(FCPROCINFO\fP T{
+\*(CB\*(FCPREC\fP T{
+The working precision of arbitrary precision floating-point
+numbers, 53 by default.
+T}
+\*(FCPROCINFO\fP T{
Elements of this array provide access to information
about the running AWK program. See
\*(AM for details.\*(CD
@@ -618,6 +626,10 @@ T}
Length of the string matched by \*(FCmatch()\*(FR;
\-1 if no match.
T}
+\*(CB\*(FCROUNDMODE\fP T{
+The rounding mode to use for arbitrary precision arithmetic,
+by default \*(FC"N"\fP.\*(CD
+T}
\*(FCRS\fP T{
Input record separator, a newline by default
(see \fHRecords\fP above).
diff --git a/doc/gawk.1 b/doc/gawk.1
index e26f9a2e..f01ffbfe 100644
--- a/doc/gawk.1
+++ b/doc/gawk.1
@@ -33,30 +33,6 @@ gawk \- pattern scanning and processing language
]
.I program-text
file .\|.\|.
-.sp
-.B pgawk
-[ \*(PX or \*(GN style options ]
-.B \-f
-.I program-file
-[
-.B \-\^\-
-] file .\|.\|.
-.br
-.B pgawk
-[ \*(PX or \*(GN style options ]
-[
-.B \-\^\-
-]
-.I program-text
-file .\|.\|.
-.sp
-.B dgawk
-[ \*(PX or \*(GN style options ]
-.B \-f
-.I program-file
-[
-.B \-\^\-
-] file .\|.\|.
.SH DESCRIPTION
.I Gawk
is the \*(GN Project's implementation of the \*(AK programming language.
@@ -84,27 +60,31 @@ and
.B ARGV
pre-defined \*(AK variables.
.PP
-.I Pgawk
-is the profiling version of
-.IR gawk .
-It is identical in every way to
-.IR gawk ,
-except that programs run more slowly,
-and it automatically produces an execution profile in the file
+When
+.I gawk
+is invoked with the
+.B \-\^\-profile
+option, it starts gathering profiling statistics
+from the execution of the program.
+.I Gawk
+runs more slowly in this mode, and automatically produces an execution
+profile in the file
.B awkprof.out
when done.
See the
.B \-\^\-profile
option, below.
.PP
-.I Dgawk
-is an
-.I awk
-debugger. Instead of running the program directly, it loads the
+.I Gawk
+also has an integrated debugger. An interactive debugging session can
+be started by supplying the
+.B \-\^\-debug
+option to the command line. In this mode of execution,
+.I gawk
+loads the
AWK source code and then prompts for debugging commands.
-Unlike
-.IR gawk " and " pgawk ", " dgawk
-only processes AWK program source provided with the
+.I Gawk
+can only debug AWK program source provided with the
.B \-f
option.
The debugger is documented in \*(EP.
@@ -117,8 +97,8 @@ while long options start with \*(lq\-\^\-\*(rq.
Long options are provided for both \*(GN-specific features and
for \*(PX-mandated features.
.PP
-.IR Gawk -
-specific options are typically used in long-option form.
+.IR Gawk -specific
+options are typically used in long-option form.
Arguments to long options are either joined with the option
by an
.B =
@@ -273,6 +253,18 @@ names like
and so on.)
.TP
.PD 0
+\fB\-D\fR[\fIfile\fR]
+.TP
+.PD
+\fB\-\^\-debug\fR[\fB=\fIfile\fR]
+Enable debugging of \*(AK programs.
+By default, the debugger reads commands interactively from the terminal.
+The optional
+.IR file
+argument can be used to specify a file with a list
+of commands for the debugger to execute non-interactively.
+.TP
+.PD 0
.BI "\-e " program-text
.TP
.PD
@@ -331,6 +323,21 @@ the standard output.
these options cause an immediate, successful exit.)
.TP
.PD 0
+.BI "\-l " lib
+.TP
+.PD
+.BI \-\^\-load " lib"
+Load a shared library
+.IR lib .
+This searches for the library using the
+.B AWKPATH
+environment variable. The suffix
+.I .so
+in the library name is optional, and
+the library initialization routine is expected to be named
+.BR dlload() .
+.TP
+.PD 0
.BR "\-L " [ \fIvalue\fR ]
.TP
.PD
@@ -348,6 +355,16 @@ only warnings about things that are
actually invalid are issued. (This is not fully implemented yet.)
.TP
.PD 0
+.B \-M
+.TP
+.PD
+.B \-\^\-bignum
+Force arbitrary precision arithmetic on numbers. This option has
+no effect if
+.I gawk
+is not compiled to use the GNU MPFR and MP libraries.
+.TP
+.PD 0
.B \-n
.TP
.PD
@@ -387,12 +404,28 @@ users.
..
.TP
.PD 0
+\fB\-o\fR[\fIfile\fR]
+.TP
+.PD
+\fB\-\^\-pretty-print\fR[\fB=\fIfile\fR]
+Output a pretty printed version of the program to
+.IR file .
+If no
+.I file
+is provided,
+.I gawk
+uses a file named
+.B awkprof.out
+in the current directory.
+.TP
+.PD 0
.B \-O
.TP
.PD
.B \-\^\-optimize
Enable optimizations upon the internal representation of the program.
-Currently, this includes just simple constant-folding. The
+Currently, this includes simple constant-folding, and tail call
+elimination for recursive functions. The
.I gawk
maintainer hopes to add additional optimizations over time.
.TP
@@ -401,16 +434,11 @@ maintainer hopes to add additional optimizations over time.
.TP
.PD
\fB\-\^\-profile\fR[\fB=\fIprof_file\fR]
-Send profiling data to
+Start a profiling session, and send the profiling data to
.IR prof_file .
The default is
.BR awkprof.out .
-When run with
-.IR gawk ,
-the profile is just a \*(lqpretty printed\*(rq version of the program.
-When run with
-.IR pgawk ,
-the profile contains execution counts of each statement in the program
+The profile contains execution counts of each statement in the program
in the left margin and function call counts for each user-defined function.
.TP
.PD 0
@@ -482,15 +510,6 @@ They are enabled by default, but this option remains for use with
.BR \-\^-traditional .
.TP
.PD 0
-.B \-R
-.TP
-.PD
-.BI \-\^\-command " file"
-.I Dgawk
-only. Read stored debugger commands from
-.IR file .
-.TP
-.PD 0
.BI \-S
.TP
.PD
@@ -1022,6 +1041,10 @@ The output field separator, a space by default.
.B ORS
The output record separator, by default a newline.
.TP
+.B PREC
+The working precision of arbitrary precision floating-point
+numbers, 53 by default.
+.TP
.B PROCINFO
The elements of this array provide access to information about the
running \*(AK program.
@@ -1120,11 +1143,48 @@ corresponding values of the two elements being compared.
It should return a number less than, equal to, or greater than 0,
depending on how the elements of the array are to be ordered.
.TP
+\fBPROCINFO["input", "READ_TIMEOUT"]\fP
+specifies the timeout in milliseconds for reading data from
+.IR input ,
+where
+.I input
+is a redirection string or a filename. A value of zero or
+less than zero means no timeout.
+.TP
+\fBPROCINFO["mpfr_version"]\fP
+the version of the GNU MPFR library used for arbitrary precision
+number support in
+.IR gawk .
+.TP
+\fBPROCINFO["gmp_version"]\fP
+the version of the GNU MP library used for arbitrary precision
+number support in
+.IR gawk .
+.TP
+\fBPROCINFO["prec_max"]\fP
+the maximum precision supported by the GNU MPFR library for
+arbitrary precision floating-point numbers.
+.TP
+\fBPROCINFO["prec_min"]\fP
+the minimum precision allowed by the GNU MPFR library for
+arbitrary precision floating-point numbers.
+.TP
\fBPROCINFO["version"]\fP
the version of
.IR gawk .
.RE
.TP
+.B ROUNDMODE
+The rounding mode to use for arbitrary precision arithmetic on
+numbers, by default \fB"N"\fR (IEEE-754 roundTiesToEven mode).
+The accepted values are
+\fB"N"\fR or \fB"n"\fR for roundTiesToEven,
+\fB"U"\fR or \fB"u"\fR for roundTowardPositive,
+\fB"D"\fR or \fB"d"\fR for roundTowardNegative,
+\fB"Z"\fR or \fB"z"\fR for roundTowardZero,
+and if your version of GNU MPFR library supports it,
+\fB"A"\fR or \fB"a"\fR for roundTiesToAway.
+.TP
.B RS
The input record separator, by default a newline.
.TP
@@ -3122,8 +3182,9 @@ Using this feature at the C level is not pretty, but
it is unlikely to go away. Additional mechanisms may
be added at some point.
.SH SIGNALS
-.I pgawk
-accepts two signals.
+The
+.I gawk
+profiler accepts two signals.
.B SIGUSR1
causes it to dump a profile and function call stack to the
profile file, which is either
@@ -3133,7 +3194,7 @@ or whatever file was named with the
option. It then continues to run.
.B SIGHUP
causes
-.I pgawk
+.I gawk
to dump the profile and function call stack and then exit.
.SH INTERNATIONALIZATION
.PP
@@ -3577,6 +3638,12 @@ and
.B \-\^\-file
options.
.PP
+The
+.B GAWK_READ_TIMEOUT
+environment variable can be used to specify a timeout
+in milliseconds for reading input from a terminal, pipe
+or two-way communication including sockets.
+.PP
For socket communication, two special environment variables can be used to control the number of retries
.RB ( GAWK_SOCK_RETRIES ),
and the interval between retries
diff --git a/doc/gawk.info b/doc/gawk.info
index a33027cd..bf279828 100644
--- a/doc/gawk.info
+++ b/doc/gawk.info
@@ -89,12 +89,14 @@ texts being (a) (see below), and with the Back-Cover Texts being (b)
* Functions:: Built-in and user-defined functions.
* Internationalization:: Getting `gawk' to speak your
language.
+* Arbitrary Precision Arithmetic:: Arbitrary precision arithmetic with
+ `gawk'.
* Advanced Features:: Stuff for advanced users, specific to
`gawk'.
* Library Functions:: A Library of `awk' Functions.
* Sample Programs:: Many `awk' programs with complete
explanations.
-* Debugger:: The `dgawk' debugger.
+* Debugger:: The `gawk' debugger.
* Language History:: The evolution of the `awk'
language.
* Installation:: Installing `gawk' under various
@@ -196,6 +198,7 @@ texts being (a) (see below), and with the Back-Cover Texts being (b)
* Getline Notes:: Important things to know about
`getline'.
* Getline Summary:: Summary of `getline' Variants.
+* Read Timeout:: Reading input with a timeout.
* Command line directories:: What happens if you put a directory on the
command line.
* Print:: The `print' statement.
@@ -353,6 +356,21 @@ texts being (a) (see below), and with the Back-Cover Texts being (b)
* I18N Portability:: `awk'-level portability issues.
* I18N Example:: A simple i18n example.
* Gawk I18N:: `gawk' is also internationalized.
+* Floating-point Programming:: Effective floating-point programming.
+* Floating-point Representation:: Binary floating-point representation.
+* Floating-point Context:: Floating-point context.
+* Rounding Mode:: Floating-point rounding mode.
+* Arbitrary Precision Floats:: Arbitrary precision floating-point
+ arithmetic with `gawk'.
+* Setting Precision:: Setting the working precision.
+* Setting Rounding Mode:: Setting the rounding mode.
+* Floating-point Constants:: Representing floating-point constants.
+* Changing Precision:: Changing the precision of a number.
+* Exact Arithmetic:: Exact arithmetic with floating-point numbers.
+* Integer Programming:: Effective integer programming.
+* Arbitrary Precision Integers:: Arbitrary precision integer
+ arithmetic with `gawk'.
+* MPFR and GMP Libraries:: Information about the MPFR and GMP libraries.
* Nondecimal Data:: Allowing nondecimal input data.
* Array Sorting:: Facilities for controlling array traversal
and sorting arrays.
@@ -417,23 +435,23 @@ texts being (a) (see below), and with the Back-Cover Texts being (b)
* Anagram Program:: Finding anagrams from a dictionary.
* Signature Program:: People do amazing things with too much time
on their hands.
-* Debugging:: Introduction to `dgawk'.
-* Debugging Concepts:: Debugging In General.
+* Debugging:: Introduction to `gawk' Debugger.
+* Debugging Concepts:: Debugging in General.
* Debugging Terms:: Additional Debugging Concepts.
* Awk Debugging:: Awk Debugging.
-* Sample dgawk session:: Sample `dgawk' session.
-* dgawk invocation:: `dgawk' Invocation.
-* Finding The Bug:: Finding The Bug.
-* List of Debugger Commands:: Main `dgawk' Commands.
-* Breakpoint Control:: Control of breakpoints.
-* Dgawk Execution Control:: Control of execution.
-* Viewing And Changing Data:: Viewing and changing data.
-* Dgawk Stack:: Dealing with the stack.
-* Dgawk Info:: Obtaining information about the program and
- the debugger state.
-* Miscellaneous Dgawk Commands:: Miscellaneous Commands.
+* Sample Debugging Session:: Sample Debugging Session.
+* Debugger Invocation:: How to Start the Debugger.
+* Finding The Bug:: Finding the Bug.
+* List of Debugger Commands:: Main Commands.
+* Breakpoint Control:: Control of Breakpoints.
+* Debugger Execution Control:: Control of Execution.
+* Viewing And Changing Data:: Viewing and Changing Data.
+* Execution Stack:: Dealing with the Stack.
+* Debugger Info:: Obtaining Information about the Program and
+ the Debugger State.
+* Miscellaneous Debugger Commands:: Miscellaneous Commands.
* Readline Support:: Readline Support.
-* Dgawk Limitations:: Limitations and future plans.
+* Limitations:: Limitations and Future Plans.
* V7/SVR3.1:: The major changes between V7 and System V
Release 3.1.
* SVR4:: Minor changes between System V Releases 3.1
@@ -489,6 +507,7 @@ texts being (a) (see below), and with the Back-Cover Texts being (b)
* Internals:: A brief look at some `gawk'
internals.
* Plugin License:: A note about licensing.
+* Loading Extensions:: How to load dynamic extensions.
* Sample Library:: A example of new functions.
* Internal File Description:: What the new functions will do.
* Internal File Ops:: The code for internal file operations.
@@ -849,7 +868,7 @@ and profile your `awk' programs.
sample `awk' programs. Reading them allows you to see `awk' solving
real problems.
- *note Debugger::, describes the `awk' debugger, `dgawk'.
+ *note Debugger::, describes the `awk' debugger.
*note Language History::, describes how the `awk' language has
evolved since its first release to present. It also describes how
@@ -1100,10 +1119,12 @@ it is today. It has been and continues to be a pleasure working with
this team of fine people.
John Haque contributed the modifications to convert `gawk' into a
-byte-code interpreter, including the debugger. Stephen Davies
-contributed to the effort to bring the byte-code changes into the
-mainstream code base. Efraim Yawitz contributed the initial text of
-*note Debugger::.
+byte-code interpreter, including the debugger, and the additional
+modifications for support of arbitrary precision arithmetic. Stephen
+Davies contributed to the effort to bring the byte-code changes into
+the mainstream code base. Efraim Yawitz contributed the initial text
+of *note Debugger::. John Haque contributed the initial text of *note
+Arbitrary Precision Arithmetic::.
I would like to thank Brian Kernighan for invaluable assistance
during the testing and debugging of `gawk', and for ongoing help and
@@ -2216,6 +2237,15 @@ The following list describes options mandated by the POSIX standard:
particularly easy mistake to make with simple variable names like
`i', `j', etc.)
+`-D[FILE]'
+`--debug=[FILE]'
+ Enable debugging of `awk' programs (*note Debugging::). By
+ default, the debugger reads commands interactively from the
+ terminal. The optional FILE argument allows you to specify a file
+ with a list of commands for the debugger to execute
+ non-interactively. No space is allowed between the `-D' and FILE,
+ if FILE is supplied.
+
`-e PROGRAM-TEXT'
`--source PROGRAM-TEXT'
Provide program source code in the PROGRAM-TEXT. This option
@@ -2258,6 +2288,13 @@ The following list describes options mandated by the POSIX standard:
Print a "usage" message summarizing the short and long style
options that `gawk' accepts and then exit.
+`-l LIB'
+`--load LIB'
+ Load a shared library LIB. This searches for the library using the
+ `AWKPATH' environment variable. The suffix `.so' in the library
+ name is optional. The library initialization routine should be
+ named `dlload()'.
+
`-L [value]'
`--lint[=value]'
Warn about constructs that are dubious or nonportable to other
@@ -2277,6 +2314,12 @@ The following list describes options mandated by the POSIX standard:
inappropriate construct. As `awk' programs are usually short,
doing so is not burdensome.
+`-M'
+`--bignum'
+ Force arbitrary precision arithmetic on numbers. This option has
+ no effect if `gawk' is not compiled to use the GNU MPFR and MP
+ libraries (*note Arbitrary Precision Arithmetic::).
+
`-n'
`--non-decimal-data'
Enable automatic interpretation of octal and hexadecimal values in
@@ -2290,6 +2333,14 @@ The following list describes options mandated by the POSIX standard:
Force the use of the locale's decimal point character when parsing
numeric input data (*note Locales::).
+`-o[FILE]'
+`--pretty-print[=FILE]'
+ Enable pretty-printing of `awk' programs. By default, output
+ program is created in a file named `awkprof.out'. The optional
+ FILE argument allows you to specify a different file name for the
+ output. No space is allowed between the `-o' and FILE, if FILE is
+ supplied.
+
`-O'
`--optimize'
Enable some optimizations on the internal representation of the
@@ -2305,10 +2356,9 @@ The following list describes options mandated by the POSIX standard:
for the profile file. No space is allowed between the `-p' and
FILE, if FILE is supplied.
- When run with `gawk', the profile is just a "pretty printed"
- version of the program. When run with `pgawk', the profile
- contains execution counts for each statement in the program in the
- left margin, and function call counts for each function.
+ The profile contains execution counts for each statement in the
+ program in the left margin, and function call counts for each
+ function.
`-P'
`--posix'
@@ -2342,11 +2392,6 @@ The following list describes options mandated by the POSIX standard:
remains both for backward compatibility, and for use in
combination with the `--traditional' option.
-`-R FILE'
-`--command=FILE'
- `dgawk' only. Read `dgawk' debugger options and commands from
- FILE. *Note Dgawk Info::, for more information.
-
`-S'
`--sandbox'
Disable the `system()' function, input redirections with `getline',
@@ -2611,6 +2656,10 @@ used by regular users.
milliseconds. On systems that do not support the `usleep()' system
call, the value is rounded up to an integral number of seconds.
+`GAWK_READ_TIMEOUT'
+ Specifies the time, in milliseconds, for `gawk' to wait for input
+ before returning with an error. *Note Read Timeout::.
+
The environment variables in the following list are meant for use by
the `gawk' developers for testing and tuning. They are subject to
change. The variables are:
@@ -3612,6 +3661,8 @@ have to be named on the `awk' command line (*note Getline::).
* Multiple Line:: Reading multi-line records.
* Getline:: Reading files under explicit program control
using the `getline' function.
+* Read Timeout:: Reading input with a timeout.
+
* Command line directories:: What happens if you put a directory on the
command line.
@@ -4799,7 +4850,7 @@ feature of `RS' does not apply. It does apply to the default field
separator of a single space: `FS = " "'.

-File: gawk.info, Node: Getline, Next: Command line directories, Prev: Multiple Line, Up: Reading Files
+File: gawk.info, Node: Getline, Next: Read Timeout, Prev: Multiple Line, Up: Reading Files
4.9 Explicit Input with `getline'
=================================
@@ -5224,9 +5275,101 @@ VAR
Table 4.1: getline Variants and What They Set

-File: gawk.info, Node: Command line directories, Prev: Getline, Up: Reading Files
+File: gawk.info, Node: Read Timeout, Next: Command line directories, Prev: Getline, Up: Reading Files
+
+4.10 Reading Input With A Timeout
+=================================
+
+You may specify a timeout in milliseconds for reading input from a
+terminal, pipe or two-way communication including, TCP/IP sockets. This
+can be done on a per input, command or connection basis, by setting a
+special element in the `PROCINFO' array:
+
+ PROCINFO["input_name", "READ_TIMEOUT"] = TIMEOUT IN MILLISECONDS
+
+ When set, this will cause `gawk' to time out and return failure if
+no data is available to read within the specified timeout period. For
+example, a TCP client can decide to give up on receiving any response
+from the server after a certain amount of time:
+
+ Service = "/inet/tcp/0/localhost/daytime"
+ PROCINFO[Service, "READ_TIMEOUT"] = 100
+ if ((Service |& getline) > 0)
+ print $0
+ else if (ERRNO != "")
+ print ERRNO
+
+ Here is how to read interactively from the terminal(1) without
+waiting for more than five seconds:
+
+ PROCINFO["/dev/stdin", "READ_TIMEOUT"] = 5000
+ while ((getline < "/dev/stdin") > 0)
+ print $0
+
+ `gawk' will terminate the read operation if input does not arrive
+after waiting for the timeout period, return failure and set the
+`ERRNO' variable to an appropriate string value. A negative or zero
+value for the timeout is the same as specifying no timeout at all.
+
+ A timeout can also be set for reading from the terminal in the
+implicit loop that reads input records and matches them against
+patterns, like so:
+
+ $ gawk 'BEGIN { PROCINFO["-", "READ_TIMEOUT"] = 5000 }
+ > { print "You entered: " $0 }'
+ gawk
+ -| You entered: gawk
+
+ In this case, failure to respond within five seconds results in the
+following error message:
+
+ error--> gawk: cmd. line:2: (FILENAME=- FNR=1) fatal: error reading input file `-': Connection timed out
+
+ The timeout can be set or changed at any time, and will take effect
+on the next attempt to read from the input device. In the following
+example, we start with a timeout value of one second, and progressively
+reduce it by one-tenth of a second until we wait indefinitely for the
+input to arrive:
+
+ PROCINFO[Service, "READ_TIMEOUT"] = 1000
+ while ((Service |& getline) > 0) {
+ print $0
+ PROCINFO[S, "READ_TIMEOUT"] -= 100
+ }
+
+ NOTE: You should not assume that the read operation will block
+ exactly after the tenth record has been printed. It is possible
+ that `gawk' will read and buffer more than one record's worth of
+ data the first time. Because of this, changing the value of
+ timeout like in the above example is not very useful.
+
+ If the `PROCINFO' element is not present and the environment
+variable `GAWK_READ_TIMEOUT' exists, `gawk' uses its value to
+initialize the timeout value. The exclusive use of the environment
+variable to specify timeout has the disadvantage of not being able to
+control it on a per command or connection basis.
+
+ `gawk' considers a timeout event to be an error even though the
+attempt to read from the underlying device may succeed in a later
+attempt. This is a limitation, and it also means that you cannot use
+this to multiplex input from two or more sources.
+
+ Assigning a timeout value prevents read operations from blocking
+indefinitely. But bear in mind that there are other ways `gawk' can
+stall waiting for an input device to be ready. A network client can
+sometimes take a long time to establish a connection before it can
+start reading any data, or the attempt to open a FIFO special file for
+reading can block indefinitely until some other process opens it for
+writing.
+
+ ---------- Footnotes ----------
-4.10 Directories On The Command Line
+ (1) This assumes that standard input is the keyboard
+
+
+File: gawk.info, Node: Command line directories, Prev: Read Timeout, Up: Reading Files
+
+4.11 Directories On The Command Line
====================================
According to the POSIX standard, files named on the `awk' command line
@@ -9185,6 +9328,15 @@ specific to `gawk' are marked with a pound sign (`#').
every `print' statement. Its default value is `"\n"', the newline
character. (*Note Output Separators::.)
+`PREC #'
+ The working precision of arbitrary precision floating-point
+ numbers, 53 by default (*note Setting Precision::).
+
+`ROUNDMODE #'
+ The rounding mode to use for arbitrary precision arithmetic on
+ numbers, by default `"N"' (`roundTiesToEven' in the IEEE-754
+ standard) (*note Setting Rounding Mode::).
+
`RS'
This is `awk''s input record separator. Its default value is a
string containing a single newline character, which means that an
@@ -9390,6 +9542,23 @@ with a pound sign (`#').
`PROCINFO["version"]'
The version of `gawk'.
+ The following additional elements in the array are available to
+ provide information about the MPFR and GMP libraries if your
+ version of `gawk' supports arbitrary precision numbers (*note
+ Arbitrary Precision Arithmetic::):
+
+ `PROCINFO["mpfr_version"]'
+ The version of the GNU MPFR library.
+
+ `PROCINFO["gmp_version"]'
+ The version of the GNU MP library.
+
+ `PROCINFO["prec_max"]'
+ The maximum precision supported by MPFR.
+
+ `PROCINFO["prec_min"]'
+ The minimum precision required by MPFR.
+
On some systems, there may be elements in the array, `"group1"'
through `"groupN"' for some N. N is the number of supplementary
groups that the process has. Use the `in' operator to test for
@@ -12903,7 +13072,7 @@ example, in the following case:
`gawk' will look up the actual function to call only once.

-File: gawk.info, Node: Internationalization, Next: Advanced Features, Prev: Functions, Up: Top
+File: gawk.info, Node: Internationalization, Next: Arbitrary Precision Arithmetic, Prev: Functions, Up: Top
10 Internationalization with `gawk'
***********************************
@@ -13483,9 +13652,745 @@ writing, the latest version of GNU `gettext' is version 0.18.1
usage messages, warnings, and fatal errors in the local language.

-File: gawk.info, Node: Advanced Features, Next: Library Functions, Prev: Internationalization, Up: Top
+File: gawk.info, Node: Arbitrary Precision Arithmetic, Next: Advanced Features, Prev: Internationalization, Up: Top
+
+11 Arbitrary Precision Arithmetic with `gawk'
+*********************************************
+
+ There's a credibility gap: We don't know how much of the
+ computer's answers to believe. Novice computer users solve this
+ problem by implicitly trusting in the computer as an infallible
+ authority; they tend to believe that all digits of a printed
+ answer are significant. Disillusioned computer users have just the
+ opposite approach; they are constantly afraid that their answers
+ are almost meaningless.
+
+ Donald Knuth(1)
+
+ This minor node decsribes how to use the arbitrary precision (also
+known as "multiple precision" or "infinite precision") numeric
+capabilites in `gawk' to produce maximally accurate results when you
+need it. But first you should check if your version of `gawk' supports
+arbitrary precision arithmetic. The easiest way to find out is to look
+at the output of the following command:
+
+ $ gawk --version
+ -| GNU Awk 4.1.0 (GNU MPFR 3.1.0, GNU MP 5.0.3)
+ -| Copyright (C) 1989, 1991-2012 Free Software Foundation.
+ ...
+
+ `gawk' uses the GNU MPFR (http://www.mpfr.org) and GNU MP
+(http://gmplib.org) (GMP) libraries for arbitrary precision arithmetic
+on numbers. So if you do not see the names of these libraries in the
+output, then your version of `gawk' does not support arbitrary
+precision arithmetic.
+
+ Even if you aren't interested in arbitrary precision arithmetic, you
+may still benifit from knowing about how `gawk' handles numbers in
+general, and the limitations of doing arithmetic with ordinary `gawk'
+numbers.
+
+* Menu:
+
+* Floating-point Programming:: Effective Floating-point Programming.
+* Floating-point Representation:: Binary Floating-point Representation.
+* Floating-point Context:: Floating-point Context.
+* Rounding Mode:: Floating-point Rounding Mode.
+* Arbitrary Precision Floats:: Arbitrary Precision Floating-point
+ Arithmetic with `gawk'.
+* Setting Precision:: Setting the Working Precision.
+* Setting Rounding Mode:: Setting the Rounding Mode.
+* Floating-point Constants:: Representing Floating-point Constants.
+* Changing Precision:: Changing the Precision of a Number.
+* Exact Arithmetic:: Exact Arithmetic with Floating-point Numbers.
+* Integer Programming:: Effective Integer Programming.
+* Arbitrary Precision Integers:: Arbitrary Precision Integer
+ Arithmetic with `gawk'.
+* MPFR and GMP Libraries:: Information About the MPFR and GMP Libraries.
+
+ ---------- Footnotes ----------
+
+ (1) Donald E. Knuth. `The Art of Computer Programming'. Volume 2,
+`Seminumerical Algorithms', third edition, 1998, ISBN 0-201-89683-4, p.
+229.
+
+
+File: gawk.info, Node: Floating-point Programming, Next: Floating-point Representation, Up: Arbitrary Precision Arithmetic
+
+11.1 Effective Floating-point Programming
+=========================================
+
+Numerical programming is an extensive area; if you need to develop
+sophisticated numerical algorithms then `gawk' may not be the ideal
+tool, and this documentation may not be sufficient. It might require a
+book or two to communicate how to compute with ideal accuracy and
+precision and the result often depends on the particular application.
+
+ NOTE: A floating-point calculation's "accuracy" is how close it
+ comes to the real value. This is as opposed to the "precision",
+ which usually refers to the number of bits used to represent the
+ number (see the Wikipedia article
+ (http://en.wikipedia.org/wiki/Accuracy_and_precision) for more
+ information).
+
+ Binary floating-point representations and arithmetic are inexact.
+Simple values like 0.1 cannot be precisely represented using binary
+floating-point numbers, and the limited precision of floating-point
+numbers means that slight changes in the order of operations or the
+precision of intermediate storage can change the result. To make
+matters worse with arbitrary precision floating-point, you can set the
+precision before starting a computation, but then you cannot be sure of
+the number of significant decimal places in the final result.
+
+ Sometimes you need to think more about what you really want and
+what's really happening. Consider the two numbers in the following
+example:
+
+ x = 0.875 # 1/2 + 1/4 + 1/8
+ y = 0.425
+
+ Unlike the number in `y', the number stored in `x' is exactly
+representable in binary since it can be written as a finite sum of one
+or more fractions whose denominators are all powers of two. When
+`gawk' reads a floating-point number from program source, it
+automatically rounds that number to whatever precision your machine
+supports. If you try to print the numeric content of a variable using
+an output format string of `"%.17g"', it may not produce the same
+number as you assigned to it:
+
+ $ gawk 'BEGIN { x = 0.875; y = 0.425
+ > printf("%0.17g, %0.17g\n", x, y) }'
+ -| 0.875, 0.42499999999999999
+
+ Often the error is so small you do not even notice it, and if you do,
+you can always specify how much precision you would like in your output.
+Usually this is a format string like `"%.15g"', which when used in the
+previous example, produces an output identical to the input.
+
+ Because the underlying representation can be little bit off from the
+exact value, comparing floats to see if they are equal is generally not
+a good idea. Here is an example where it does not work like you expect:
+
+ $ gawk 'BEGIN { print (0.1 + 12.2 == 12.3) }'
+ -| 0
+
+ The loss of accuracy during a single computation with floating-point
+numbers usually isn't enough to worry about. However, if you compute a
+value which is the result of a sequence of floating point operations,
+the error can accumulate and greatly affect the computation itself.
+Here is an attempt to compute the value of the constant pi using one of
+its many series representations:
+
+ BEGIN {
+ x = 1.0 / sqrt(3.0)
+ n = 6
+ for (i = 1; i < 30; i++) {
+ n = n * 2.0
+ x = (sqrt(x * x + 1) - 1) / x
+ printf("%.15f\n", n * x)
+ }
+ }
+
+ When run, the early errors propagating through later computations
+cause the loop to terminate prematurely after an attempt to divide by
+zero.
+
+ $ gawk -f pi.awk
+ -| 3.215390309173475
+ -| 3.159659942097510
+ -| 3.146086215131467
+ -| 3.142714599645573
+ ...
+ -| 3.224515243534819
+ -| 2.791117213058638
+ -| 0.000000000000000
+ error--> gawk: pi.awk:6: fatal: division by zero attempted
+
+ Here is one more example where the inaccuracies in internal
+representations yield an unexpected result:
+
+ $ gawk 'BEGIN {
+ > for (d = 1.1; d <= 1.5; d += 0.1)
+ > i++
+ > print i
+ > }'
+ -| 4
+
+ Can computation using aribitrary precision help with the previous
+examples? If you are impatient to know, see *note Exact Arithmetic::.
+
+ Instead of aribitrary precision floating-point arithmetic, often all
+you need is an adjustment of your logic or a different order for the
+operations in your calculation. The stability and the accuracy of the
+computation of the constant pi in the previous example can be enhanced
+by using the following simple algebraic transformation:
+
+ (sqrt(x * x + 1) - 1) / x = x / (sqrt(x * x + 1) + x)
+
+ There is no need to be unduly suspicious about the results from
+floating-point arithmetic. The lesson to remember is that
+floating-point math is always more complex than the math using pencil
+and paper. In order to take advantage of the power of computer
+floating-point, you need to know its limitations and work within them.
+For most casual use of floating-point arithmetic, you will often get
+the expected result in the end if you simply round the display of your
+final results to the correct number of significant decimal digits.
+Avoid presenting numerical data in a manner that implies better
+precision than is actually the case.
+
+
+File: gawk.info, Node: Floating-point Representation, Next: Floating-point Context, Prev: Floating-point Programming, Up: Arbitrary Precision Arithmetic
+
+11.2 Binary Floating-point Representation
+=========================================
+
+Although floating-point representations vary from machine to machine,
+the most commonly encountered representation is that defined by the
+IEEE 754 Standard. An IEEE-754 format value has three components:
+
+ * a sign bit telling whether the number is positive or negative,
+
+ * an "exponent" giving its order of magnitude, E,
+
+ * and a "significand", S, specifying the actual digits of the number.
+
+ The value of the number is then S * 2^E. The first bit of a
+non-zero binary significand is always one, so the significand in an
+IEEE-754 format only includes the fractional part, leaving the leading
+one implicit.
+
+ Three of the standard IEEE-754 types are 32-bit single precision,
+64-bit double precision and 128-bit quadruple precision. The standard
+also specifies extended precision formats to allow greater precisions
+and larger exponent ranges.
+
+
+File: gawk.info, Node: Floating-point Context, Next: Rounding Mode, Prev: Floating-point Representation, Up: Arbitrary Precision Arithmetic
+
+11.3 Floating-point Context
+===========================
+
+A floating-point context defines the environment for arithmetic
+operations. It governs precision, sets rules for rounding and limits
+range for exponents. The context has the following primary components:
+
+`precision'
+ Precision of the floating-point format in bits.
+
+`emax'
+ Maximum exponent allowed for this format.
+
+`emin'
+ Minimum exponent allowed for this format.
+
+`underflow behavior'
+ The format may or may not support gradual underflow.
+
+`rounding'
+ The rounding mode of this context.
+
+ *note table-ieee-formats:: lists the precision and exponent field
+values for the basic IEEE-754 binary formats:
+
+Name Total bits Precision emin emax
+---------------------------------------------------------------------------
+Single 32 24 -126 +127
+Double 64 53 -1022 +1023
+Quadruple 128 113 -16382 +16383
+
+Table 11.1: Basic IEEE Formats
+
+ NOTE: The precision numbers include the implied leading one that
+ gives them one extra bit of significand.
+
+ A floating-point context can also determine which signals are treated
+as exceptions, and can set rules for arithmetic with special values.
+Please consult the IEEE-754 standard or other resources for details.
+
+ `gawk' ordinarily uses the hardware double precision representation
+for numbers. On most systems, this is IEEE-754 floating-point format,
+corresponding to 64-bit binary with 53 bits of precision.
+
+ NOTE: In case an underflow occurs, the standard allows, but does
+ not require, the result from an arithmetic operation to be a
+ number smaller than the smallest nonzero normalized number. Such
+ numbers do not have as many significant digits as normal numbers,
+ and are called "denormals" or "subnormals". The alternative,
+ simply returning a zero, is called "flush to zero". The basic
+ IEEE-754 binary formats support subnormal numbers.
+
+
+File: gawk.info, Node: Rounding Mode, Next: Arbitrary Precision Floats, Prev: Floating-point Context, Up: Arbitrary Precision Arithmetic
+
+11.4 Floating-point Rounding Mode
+=================================
+
+The "rounding mode" specifies the behavior for the results of numerical
+operations when discarding extra precision. Each rounding mode indicates
+how the least significant returned digit of a rounded result is to be
+calculated. The `ROUNDMODE' variable (*note Setting Rounding Mode::)
+provides program level control over the rounding mode. *note
+table-rounding-modes:: lists the IEEE-754 defined rounding modes:
+
+Rounding Mode IEEE Name `ROUNDMODE'
+---------------------------------------------------------------------------
+Round to nearest, ties to even `roundTiesToEven' `"N"' or `"n"'
+Round toward plus Infinity `roundTowardPositive' `"U"' or `"u"'
+Round toward negative Infinity `roundTowardNegative' `"D"' or `"d"'
+Round toward zero `roundTowardZero' `"Z"' or `"z"'
+Round to nearest, ties away `roundTiesToAway' `"A"' or `"a"'
+from zero
+
+Table 11.2: Rounding Modes
+
+ The default mode `roundTiesToEven' is the most preferred, but the
+least intuitive. This method does the obvious thing for most values, by
+rounding them up or down to the nearest digit. For example, rounding
+1.132 to two digits yields 1.13, and rounding 1.157 yields 1.16.
+
+ However, when it comes to rounding a value that is exactly halfway
+between, things do not work the way you probably learned in school. In
+this case, the number is rounded to the nearest even digit. So
+rounding 0.125 to two digits rounds down to 0.12, but rounding 0.6875
+to three digits rounds up to 0.688. You probably have already
+encountered this rounding mode when using the `printf' routine to
+format floating-point numbers. For example:
-11 Advanced Features of `gawk'
+ BEGIN {
+ x = -4.5
+ for (i = 1; i < 10; i++) {
+ x += 1.0
+ printf("%4.1f => %2.0f\n", x, x)
+ }
+ }
+
+produces the following output when run(1):
+
+ -3.5 => -4
+ -2.5 => -2
+ -1.5 => -2
+ -0.5 => 0
+ 0.5 => 0
+ 1.5 => 2
+ 2.5 => 2
+ 3.5 => 4
+ 4.5 => 4
+
+ The theory behind the rounding mode `roundTiesToEven' is that it
+more or less evenly distributes upward and downward rounds of exact
+halves, which might cause the round-off error to cancel itself out.
+This is the default rounding mode used in IEEE-754 computing functions
+and operators.
+
+ The other rounding modes are rarely used. Round toward positive
+infinity (`roundTowardPositive') and round toward negative infinity
+(`roundTowardNegative') are often used to implement interval arithmetic,
+where you adjust the rounding mode to calculate upper and lower bounds
+for the range of output. The `roundTowardZero' mode can be used for
+converting floating-point numbers to integers. The rounding mode
+`roundTiesToAway' rounds the result to the nearest number and selects
+the number with the larger magnitude if a tie occurs.
+
+ Some numerical analysts will tell you that your choice of rounding
+style has tremendous impact on the final outcome, and advise you to
+wait until final output for any rounding. Instead, you can often
+achieve this goal by setting the precision initially to some value
+sufficiently larger than the final desired precision, so that the
+accumulation of round-off error does not influence the outcome. If you
+suspect that results from your computation are sensitive to
+accumulation of round-off error, one way to be sure is to look for a
+significant difference in output when you change the rounding mode.
+
+ ---------- Footnotes ----------
+
+ (1) It is possible for the output to be completely different if the
+C library in your system does not use the IEEE-754 even-rounding rule
+to round halfway cases for `printf()'.
+
+
+File: gawk.info, Node: Arbitrary Precision Floats, Next: Setting Precision, Prev: Rounding Mode, Up: Arbitrary Precision Arithmetic
+
+11.5 Arbitrary Precision Floating-point Arithmetic with `gawk'
+==============================================================
+
+`gawk' uses the GNU MPFR library for arbitrary precision floating-point
+arithmetic. The MPFR library provides precise control over precisions
+and rounding modes, and gives correctly rounded reproducible
+platform-independent results. With the command-line option `--bignum'
+or `-M', all floating-point arithmetic operators and numeric functions
+can yield results to any desired precision level supported by MPFR.
+Two built-in variables `PREC' (*note Setting Precision::) and
+`ROUNDMODE' (*note Setting Rounding Mode::) provide control over the
+working precision and the rounding mode. The precision and the
+rounding mode are set globally for every operation to follow.
+
+ The default working precision for arbitrary precision floats is 53,
+and the default value for `ROUNDMODE' is `"N"', which selects the
+IEEE-754 `roundTiesToEven' (*note Rounding Mode::) rounding mode.(1)
+`gawk' uses the default exponent range in MPFR (EMAX = 2^30 - 1, EMIN =
+-EMAX) for all floating-point contexts. There is no explicit mechanism
+to adjust the exponent range. MPFR does not implement subnormal
+numbers by default, and this behavior cannot be changed in `gawk'.
+
+ NOTE: When emulating an IEEE-754 format (*note Setting
+ Precision::), `gawk' internally adjusts the exponent range to the
+ value defined for the format and also performs computations needed
+ for gradual underflow (subnormal numbers).
+
+ NOTE: MPFR numbers are variable-size entities, consuming only as
+ much space as needed to store the significant digits. Since the
+ performance using MPFR numbers pales in comparison to doing math
+ using the underlying machine types, you should consider using only
+ as much precision as needed by your program.
+
+ ---------- Footnotes ----------
+
+ (1) The default precision is 53, since according to the MPFR
+documentation, the library should be able to exactly reproduce all
+computations with double-precision machine floating-point numbers
+(`double' type in C), except the default exponent range is much wider
+and subnormal numbers are not implemented.
+
+
+File: gawk.info, Node: Setting Precision, Next: Setting Rounding Mode, Prev: Arbitrary Precision Floats, Up: Arbitrary Precision Arithmetic
+
+11.6 Setting the Working Precision
+==================================
+
+`gawk' uses a global working precision; it does not keep track of the
+precision or accuracy of individual numbers. Performing an arithmetic
+operation or calling a built-in function rounds the result to the
+current working precision. The default working precision is 53 which
+can be modified using the built-in variable `PREC'. You can also set the
+value to one of the following pre-defined case-insensitive strings to
+emulate an IEEE-754 binary format:
+
+`PREC' IEEE-754 Binary Format
+---------------------------------------------------
+`"half"' 16-bit half-precision.
+`"single"' Basic 32-bit single precision.
+`"double"' Basic 64-bit double precision.
+`"quad"' Basic 128-bit quadruple precision.
+`"oct"' 256-bit octuple precision.
+
+ The following example illustrates the effects of changing precision
+on arithmetic operations:
+
+ $ gawk -M -vPREC=100 'BEGIN { x = 1.0e-400; print x + 0; \
+ > PREC = "double"; print x + 0 }'
+ -| 1e-400
+ -| 0
+
+ Binary and decimal precisions are related approximately according to
+the formula:
+
+ PREC = 3.322 * DPS
+
+Here, PREC denotes the binary precision (measured in bits) and DPS
+(short for decimal places) is the decimal digits. We can easily
+calculate how many decimal digits the 53-bit significand of an IEEE
+double is equivalent to: 53 / 3.332 which is equal to about 15.95. But
+what does 15.95 digits actually mean? It depends whether you are
+concerned about how many digits you can rely on, or how many digits you
+need.
+
+ It is important to know how many bits it takes to uniquely identify
+a double-precision value (the C type `double'). If you want to convert
+from `double' to decimal and back to `double' (e.g., saving a `double'
+representing an intermediate result to a file, and later reading it
+back to restart the computation), then a few more decimal digits are
+required. 17 digits is generally enough for a `double'.
+
+ It can also be important to know what decimal numbers can be uniquely
+represented with a `double'. If you want to convert from decimal to
+`double' and back again, 15 digits is the most that you can get. Stated
+differently, you should not present the numbers from your
+floating-point computations with more than 15 significant digits in
+them.
+
+ Conversely, it takes a precision of 332 bits to hold an approximation
+of constant pi that is accurate to 100 decimal places. You should
+always add some extra bits in order to avoid the confusing round-off
+issues that occur because numbers are stored internally in binary.
+
+
+File: gawk.info, Node: Setting Rounding Mode, Next: Floating-point Constants, Prev: Setting Precision, Up: Arbitrary Precision Arithmetic
+
+11.7 Setting the Rounding Mode
+==============================
+
+The built-in variable `ROUNDMODE' has the default value `"N"', which
+selects the IEEE-754 rounding mode `roundTiesToEven'. The other
+possible values for `ROUNDMODE' are `"U"' for rounding mode
+`roundTowardPositive', `"D"' for `roundTowardNegative', and `"Z"' for
+`roundTowardZero'. `gawk' also accepts `"A"' to select the IEEE-754
+mode `roundTiesToAway' if your version of the MPFR library supports it;
+otherwise setting `ROUNDMODE' to this value has no effect. *Note
+Rounding Mode::, for the meanings of the various rounding modes.
+
+ Here is an example of how to change the default rounding behavior of
+`printf''s output:
+
+ $ gawk -M -vROUNDMODE="Z" 'BEGIN { printf("%.2f\n", 1.378) }'
+ -| 1.37
+
+
+File: gawk.info, Node: Floating-point Constants, Next: Changing Precision, Prev: Setting Rounding Mode, Up: Arbitrary Precision Arithmetic
+
+11.8 Representing Floating-point Constants
+==========================================
+
+Be wary of floating-point constants! When reading a floating-point
+constant from program source code, `gawk' uses the default precision,
+unless overridden by an assignment to the special variable `PREC' on
+the command line, to store it internally as a MPFR number. Changing
+the precision using `PREC' in the program text does not change the
+precision of a constant. If you need to represent a floating-point
+constant at a higher precision than the default and cannot use a
+command line assignment to `PREC', you should either specify the
+constant as a string, or a rational number whenever possible. The
+following example illustrates the differences among various ways to
+print a floating-point constant:
+
+ $ gawk -M 'BEGIN { PREC = 113; printf("%0.25f\n", 0.1) }'
+ -| 0.1000000000000000055511151
+ $ gawk -M -vPREC = 113 'BEGIN { printf("%0.25f\n", 0.1) }'
+ -| 0.1000000000000000000000000
+ $ gawk -M 'BEGIN { PREC = 113; printf("%0.25f\n", "0.1") }'
+ -| 0.1000000000000000000000000
+ $ gawk -M 'BEGIN { PREC = 113; printf("%0.25f\n", 1/10) }'
+ -| 0.1000000000000000000000000
+
+ In the first case, the number is stored with the default precision
+of 53.
+
+
+File: gawk.info, Node: Changing Precision, Next: Exact Arithmetic, Prev: Floating-point Constants, Up: Arbitrary Precision Arithmetic
+
+11.9 Changing the Precision of a Number
+=======================================
+
+ The point is that in any variable-precision package, a decision is
+ made on how to treat numbers given as data, or arising in
+ intermediate results, which are represented in floating-point
+ format to a precision lower than working precision. Do we promote
+ them to full membership of the high-precision club, or do we treat
+ them and all their associates as second-class citizens? Sometimes
+ the first course is proper, sometimes the second, and it takes
+ careful analysis to tell which.
+
+ Dirk Laurie(1)
+
+ `gawk' does not implicitly modify the precision of any previously
+computed results when the working precision is changed with an
+assignment to `PREC'. The precision of a number is always the one that
+was used at the time of its creation, and there is no way for the user
+to explicitly change it afterwards. However, since the result of a
+floating-point arithmetic operation is always an arbitrary precision
+floating-point value--with a precision set by the value of `PREC'--one
+of the following workarounds effectively accomplishes the desired
+behavior:
+
+ x = x + 0.0
+
+or:
+
+ x += 0.0
+
+ ---------- Footnotes ----------
+
+ (1) Dirk Laurie. `Variable-precision Arithmetic Considered Perilous
+- A Detective Story'. Electronic Transactions on Numerical Analysis.
+Volume 28, pp. 168-173, 2008.
+
+
+File: gawk.info, Node: Exact Arithmetic, Next: Integer Programming, Prev: Changing Precision, Up: Arbitrary Precision Arithmetic
+
+11.10 Exact Arithmetic with Floating-point Numbers
+==================================================
+
+ CAUTION: Never depend on the exactness of floating-point
+ arithmetic, even for apparently simple expressions!
+
+ Can arbitrary precision arithmetic give exact results? There are no
+easy answers. The standard rules of algebra often do not apply when
+using floating-point arithmetic. Among other things, the distributive
+and associative laws do not hold completely, and order of operation may
+be important for your computation. Rounding error, cumulative precision
+loss and underflow are often troublesome.
+
+ When `gawk' tests the expressions `0.1 + 12.2' and `12.3' for
+equality using the machine double precision arithmetic, it decides that
+they are not equal! (*Note Floating-point Programming::.) You can get
+the result you want by increasing the precision; 56 in this case will
+get the job done:
+
+ $ gawk -M -vPREC=56 'BEGIN { print (0.1 + 12.2 == 12.3) }'
+ -| 1
+
+ If adding more bits is good, perhaps adding even more bits of
+precision is better? Here is what happens if we use an even larger
+value of `PREC':
+
+ $ gawk -M -vPREC=201 'BEGIN { print (0.1 + 12.2 == 12.3) }'
+ -| 0
+
+ This is not a bug in `gawk' or in the MPFR library. It is easy to
+forget that the finite number of bits used to store the value is often
+just an approximation after proper rounding. The test for equality
+succeeds if and only if _all_ bits in the two operands are exactly the
+same. Since this is not necessarily true after floating-point
+computations with a particular precision and effective rounding rule, a
+straight test for equality may not work.
+
+ So, don't assume that floating-point values can be compared for
+equality. You should also exercise caution when using other forms of
+comparisons. The standard way to compare between floating-point
+numbers is to determine how much error (or "tolerance") you will allow
+in a comparison and check to see if one value is within this error
+range of the other.
+
+ In applications where 15 or fewer decimal places suffice, hardware
+double precision arithmetic can be adequate, and is usually much faster.
+But you do need to keep in mind that every floating-point operation can
+suffer a new rounding error with catastrophic consequences as
+illustrated by our attempt to compute the value of the constant pi,
+(*note Floating-point Programming::). Extra precision can greatly
+enhance the stability and the accuracy of your computation in such
+cases.
+
+ Repeated addition is not necessarily equivalent to multiplication in
+floating-point arithmetic. In the last example (*note Floating-point
+Programming::), you may or may not succeed in getting the correct
+result by choosing an arbitrarily large value for `PREC'. Reformulation
+of the problem at hand is often the correct approach in such situations.
+
+
+File: gawk.info, Node: Integer Programming, Next: Arbitrary Precision Integers, Prev: Exact Arithmetic, Up: Arbitrary Precision Arithmetic
+
+11.11 Effective Integer Programming
+===================================
+
+As has been mentioned already, `gawk' ordinarily uses hardware double
+precision with 64-bit IEEE binary floating-point representation for
+numbers on most systems. A large integer like 9007199254740997 has a
+binary representation that, although finite, is more than 53 bits long;
+it must also be rounded to 53 bits. The biggest integer that can be
+stored in a C `double' is usually the same as the largest possible
+value of a `double'. If your system `double' is an IEEE 64-bit
+`double', this largest possible value is an integer and can be
+represented precisely. What more should one know about integers?
+
+ If you want to know what is the largest integer, such that it and
+all smaller integers can be stored in 64-bit doubles without losing
+precision, then the answer is 2^53. The next representable number is
+the even number 2^53 + 2, meaning it is unlikely that you will be able
+to make `gawk' print 2^53 + 1 in integer format. The range of integers
+exactly representable by a 64-bit double is [-2^53, 2^53]. If you ever
+see an integer outside this range in `gawk' using 64-bit doubles, you
+have reason to be very suspicious about the accuracy of the output.
+Here is a simple program with erroneous output:
+
+ $ gawk 'BEGIN { i = 2^53 - 1; for (j = 0; j < 4; j++) print i + j }'
+ -| 9007199254740991
+ -| 9007199254740992
+ -| 9007199254740992
+ -| 9007199254740994
+
+ The lesson is to not assume that any large integer printed by `gawk'
+represents an exact result from your computation, especially if it wraps
+around on your screen.
+
+
+File: gawk.info, Node: Arbitrary Precision Integers, Next: MPFR and GMP Libraries, Prev: Integer Programming, Up: Arbitrary Precision Arithmetic
+
+11.12 Arbitrary Precision Integer Arithmetic with `gawk'
+========================================================
+
+If the option `--bignum' or `-M' is specified, `gawk' performs all
+integer arithmetic using GMP arbitrary precision integers. Any number
+that looks like an integer in a program source or data file is stored
+as an arbitrary precision integer. The size of the integer is limited
+only by your computer's memory. The current floating-point context has
+no effect on operations involving integers. For example, the following
+computes 5^4^3^2, the result of which is beyond the limits of ordinary
+`gawk' numbers:
+
+ $ gawk -M 'BEGIN {
+ > x = 5^4^3^2
+ > print "# of digits =", length(x)
+ > print substr(x, 1, 20), "...", substr(x, length(x) - 19, 20)
+ > }'
+ -| # of digits = 183231
+ -| 62060698786608744707 ... 92256259918212890625
+
+ If you were to compute the same value using arbitrary precision
+floating-point values instead, the precision needed for correct output
+(using the formula `prec = 3.322 * dps'), would be 3.322 x 183231, or
+608693.
+
+ The result from an arithmetic operation with an integer and a
+floating-point value is a floating-point value with a precision equal
+to the working precision. The following program calculates the eighth
+term in Sylvester's sequence(1) using a recurrence:
+
+ $ gawk -M 'BEGIN {
+ > s = 2.0
+ > for (i = 1; i <= 7; i++)
+ > s = s * (s - 1) + 1
+ > print s
+ > }'
+ -| 113423713055421845118910464
+
+ The output differs from the acutal number,
+113423713055421844361000443, because the default precision of 53 is not
+enough to represent the floating-point results exactly. You can either
+increase the precision (100 is enough in this case), or replace the
+floating-point constant `2.0' with an integer, to perform all
+computations using integer arithmetic to get the correct output.
+
+ It will sometimes be necessary for `gawk' to implicitly convert an
+arbitrary precision integer into an arbitrary precision floating-point
+value. This is primarily because the MPFR library does not always
+provide the relevant interface to process arbitrary precision integers
+or mixed-mode numbers as needed by an operation or function. In such a
+case, the precision is set to the minimum value necessary for exact
+conversion, and the working precision is not used for this purpose. If
+this is not what you need or want, you can employ a subterfuge like
+this:
+
+ gawk -M 'BEGIN { n = 13; print (n + 0.0) % 2.0 }'
+
+ You can avoid this issue altogether by specifying the number as a
+float to begin with:
+
+ gawk -M 'BEGIN { n = 13.0; print n % 2.0 }'
+
+ Note that for the particular example above, there is unlikely to be a
+reason for simply not using the following:
+
+ gawk -M 'BEGIN { n = 13; print n % 2 }'
+
+ ---------- Footnotes ----------
+
+ (1) Weisstein, Eric W. `Sylvester's Sequence'. From MathWorld-A
+Wolfram Web Resource.
+`http://mathworld.wolfram.com/SylvestersSequence.html'
+
+
+File: gawk.info, Node: MPFR and GMP Libraries, Prev: Arbitrary Precision Integers, Up: Arbitrary Precision Arithmetic
+
+11.13 Information About the MPFR and GMP Libraries
+==================================================
+
+There are a few elements available in the `PROCINFO' array to provide
+information about the MPFR and GMP libraries. *Note Auto-set::, for
+more information.
+
+
+File: gawk.info, Node: Advanced Features, Next: Library Functions, Prev: Arbitrary Precision Arithmetic, Up: Top
+
+12 Advanced Features of `gawk'
******************************
Write documentation as if whoever reads it is a violent psychopath
@@ -13518,7 +14423,7 @@ and likely to change, its description is relegated to an appendix.

File: gawk.info, Node: Nondecimal Data, Next: Array Sorting, Up: Advanced Features
-11.1 Allowing Nondecimal Input Data
+12.1 Allowing Nondecimal Input Data
===================================
If you run `gawk' with the `--non-decimal-data' option, you can have
@@ -13560,7 +14465,7 @@ request it.

File: gawk.info, Node: Array Sorting, Next: Two-way I/O, Prev: Nondecimal Data, Up: Advanced Features
-11.2 Controlling Array Traversal and Array Sorting
+12.2 Controlling Array Traversal and Array Sorting
==================================================
`gawk' lets you control the order in which a `for (i in array)' loop
@@ -13579,7 +14484,7 @@ to order the elements during sorting.

File: gawk.info, Node: Controlling Array Traversal, Next: Array Sorting Functions, Up: Array Sorting
-11.2.1 Controlling Array Traversal
+12.2.1 Controlling Array Traversal
----------------------------------
By default, the order in which a `for (i in array)' loop scans an array
@@ -13810,7 +14715,7 @@ the default.

File: gawk.info, Node: Array Sorting Functions, Prev: Controlling Array Traversal, Up: Array Sorting
-11.2.2 Sorting Array Values and Indices with `gawk'
+12.2.2 Sorting Array Values and Indices with `gawk'
---------------------------------------------------
In most `awk' implementations, sorting an array requires writing a
@@ -13905,7 +14810,7 @@ extensions, they are not available in that case.

File: gawk.info, Node: Two-way I/O, Next: TCP/IP Networking, Prev: Array Sorting, Up: Advanced Features
-11.3 Two-Way Communications with Another Process
+12.3 Two-Way Communications with Another Process
================================================
From: brennan@whidbey.com (Mike Brennan)
@@ -14040,7 +14945,7 @@ regular pipes.

File: gawk.info, Node: TCP/IP Networking, Next: Profiling, Prev: Two-way I/O, Up: Advanced Features
-11.4 Using `gawk' for Network Programming
+12.4 Using `gawk' for Network Programming
=========================================
`EMISTERED':
@@ -14117,29 +15022,26 @@ examples.

File: gawk.info, Node: Profiling, Prev: TCP/IP Networking, Up: Advanced Features
-11.5 Profiling Your `awk' Programs
+12.5 Profiling Your `awk' Programs
==================================
You may produce execution traces of your `awk' programs. This is done
-with a specially compiled version of `gawk', called `pgawk' ("profiling
-`gawk'").
-
- `pgawk' is identical in every way to `gawk', except that when it has
-finished running, it creates a profile of your program in a file named
-`awkprof.out'. Because it is profiling, it also executes up to 45%
+by passing the option `--profile' to `gawk'. When `gawk' has finished
+running, it creates a profile of your program in a file named
+`awkprof.out'. Because it is profiling, it also executes up to 45%
slower than `gawk' normally does.
As shown in the following example, the `--profile' option can be
-used to change the name of the file where `pgawk' will write the
-profile:
+used to change the name of the file where `gawk' will write the profile:
- pgawk --profile=myprog.prof -f myprog.awk data1 data2
+ gawk --profile=myprog.prof -f myprog.awk data1 data2
-In the above example, `pgawk' places the profile in `myprog.prof'
+In the above example, `gawk' places the profile in `myprog.prof'
instead of in `awkprof.out'.
Here is a sample session showing a simple `awk' program, its input
-data, and the results from running `pgawk'. First, the `awk' program:
+data, and the results from running `gawk' with the `--profile' option.
+First, the `awk' program:
BEGIN { print "First BEGIN rule" }
@@ -14175,9 +15077,9 @@ data, and the results from running `pgawk'. First, the `awk' program:
foo
junk
- Here is the `awkprof.out' that results from running `pgawk' on this
-program and data (this example also illustrates that `awk' programmers
-sometimes have to work late):
+ Here is the `awkprof.out' that results from running the `gawk'
+profiler on this program and data (this example also illustrates that
+`awk' programmers sometimes have to work late):
# gawk profile, created Sun Aug 13 00:00:15 2000
@@ -14266,14 +15168,14 @@ output. They are as follows:
redirection. Similarly, if the target of a redirection isn't a
scalar, it gets parenthesized.
- * `pgawk' supplies leading comments in front of the `BEGIN' and
- `END' rules, the pattern/action rules, and the functions.
+ * `gawk' supplies leading comments in front of the `BEGIN' and `END'
+ rules, the pattern/action rules, and the functions.
The profiled version of your program may not look exactly like what
-you typed when you wrote it. This is because `pgawk' creates the
+you typed when you wrote it. This is because `gawk' creates the
profiled version by "pretty printing" its internal representation of
-the program. The advantage to this is that `pgawk' can produce a
+the program. The advantage to this is that `gawk' can produce a
standard representation. The disadvantage is that all source-code
comments are lost, as are the distinctions among multiple `BEGIN',
`END', `BEGINFILE', and `ENDFILE' rules. Also, things such as:
@@ -14288,21 +15190,23 @@ come out as:
which is correct, but possibly surprising.
- Besides creating profiles when a program has completed, `pgawk' can
+ Besides creating profiles when a program has completed, `gawk' can
produce a profile while it is running. This is useful if your `awk'
program goes into an infinite loop and you want to see what has been
-executed. To use this feature, run `pgawk' in the background:
+executed. To use this feature, run `gawk' with the `--profile' option
+in the background:
- $ pgawk -f myprog &
+ $ gawk --profile -f myprog &
[1] 13992
The shell prints a job number and process ID number; in this case,
-13992. Use the `kill' command to send the `USR1' signal to `pgawk':
+13992. Use the `kill' command to send the `USR1' signal to `gawk':
$ kill -USR1 13992
As usual, the profiled version of the program is written to
-`awkprof.out', or to a different file if you use the `--profile' option.
+`awkprof.out', or to a different file if one specified with the
+`--profile' option.
Along with the regular profile, as shown earlier, the profile
includes a trace of any active functions:
@@ -14314,29 +15218,29 @@ includes a trace of any active functions:
# 1. foo
# -- main --
- You may send `pgawk' the `USR1' signal as many times as you like.
+ You may send `gawk' the `USR1' signal as many times as you like.
Each time, the profile and function call trace are appended to the
output profile file.
- If you use the `HUP' signal instead of the `USR1' signal, `pgawk'
+ If you use the `HUP' signal instead of the `USR1' signal, `gawk'
produces the profile and the function call trace and then exits.
- When `pgawk' runs on MS-Windows systems, it uses the `INT' and
-`QUIT' signals for producing the profile and, in the case of the `INT'
-signal, `pgawk' exits. This is because these systems don't support the
-`kill' command, so the only signals you can deliver to a program are
-those generated by the keyboard. The `INT' signal is generated by the
+ When `gawk' runs on MS-Windows systems, it uses the `INT' and `QUIT'
+signals for producing the profile and, in the case of the `INT' signal,
+`gawk' exits. This is because these systems don't support the `kill'
+command, so the only signals you can deliver to a program are those
+generated by the keyboard. The `INT' signal is generated by the
`Ctrl-<C>' or `Ctrl-<BREAK>' key, while the `QUIT' signal is generated
by the `Ctrl-<\>' key.
- Finally, regular `gawk' also accepts the `--profile' option. When
+ Finally, `gawk' also accepts another option `--pretty-print'. When
called this way, `gawk' "pretty prints" the program into `awkprof.out',
without any execution counts.

File: gawk.info, Node: Library Functions, Next: Sample Programs, Prev: Advanced Features, Up: Top
-12 A Library of `awk' Functions
+13 A Library of `awk' Functions
*******************************
*note User-defined::, describes how to write your own `awk' functions.
@@ -14408,7 +15312,7 @@ contents of the input record.

File: gawk.info, Node: Library Names, Next: General Functions, Up: Library Functions
-12.1 Naming Library Function Global Variables
+13.1 Naming Library Function Global Variables
=============================================
Due to the way the `awk' language evolved, variables are either
@@ -14488,7 +15392,7 @@ verifying this.

File: gawk.info, Node: General Functions, Next: Data File Management, Prev: Library Names, Up: Library Functions
-12.2 General Programming
+13.2 General Programming
========================
This minor node presents a number of functions that are of general
@@ -14511,7 +15415,7 @@ programming use.

File: gawk.info, Node: Strtonum Function, Next: Assert Function, Up: General Functions
-12.2.1 Converting Strings To Numbers
+13.2.1 Converting Strings To Numbers
------------------------------------
The `strtonum()' function (*note String Functions::) is a `gawk'
@@ -14595,7 +15499,7 @@ be tested with `gawk' and the results compared to the built-in

File: gawk.info, Node: Assert Function, Next: Round Function, Prev: Strtonum Function, Up: General Functions
-12.2.2 Assertions
+13.2.2 Assertions
-----------------
When writing large programs, it is often useful to know that a
@@ -14681,7 +15585,7 @@ rule always ends with an `exit' statement.

File: gawk.info, Node: Round Function, Next: Cliff Random Function, Prev: Assert Function, Up: General Functions
-12.2.3 Rounding Numbers
+13.2.3 Rounding Numbers
-----------------------
The way `printf' and `sprintf()' (*note Printf::) perform rounding
@@ -14727,7 +15631,7 @@ might be useful if your `awk''s `printf' does unbiased rounding:

File: gawk.info, Node: Cliff Random Function, Next: Ordinal Functions, Prev: Round Function, Up: General Functions
-12.2.4 The Cliff Random Number Generator
+13.2.4 The Cliff Random Number Generator
----------------------------------------
The Cliff random number generator
@@ -14756,7 +15660,7 @@ might try using this function instead.

File: gawk.info, Node: Ordinal Functions, Next: Join Function, Prev: Cliff Random Function, Up: General Functions
-12.2.5 Translating Between Characters and Numbers
+13.2.5 Translating Between Characters and Numbers
-------------------------------------------------
One commercial implementation of `awk' supplies a built-in function,
@@ -14854,7 +15758,7 @@ extensions, you can simplify `_ord_init' to loop from 0 to 255.

File: gawk.info, Node: Join Function, Next: Gettimeofday Function, Prev: Ordinal Functions, Up: General Functions
-12.2.6 Merging an Array into a String
+13.2.6 Merging an Array into a String
-------------------------------------
When doing string processing, it is often useful to be able to join all
@@ -14901,7 +15805,7 @@ makes string operations more difficult than they really need to be.

File: gawk.info, Node: Gettimeofday Function, Prev: Join Function, Up: General Functions
-12.2.7 Managing the Time of Day
+13.2.7 Managing the Time of Day
-------------------------------
The `systime()' and `strftime()' functions described in *note Time
@@ -14983,7 +15887,7 @@ optional timestamp value to use instead of the current time.

File: gawk.info, Node: Data File Management, Next: Getopt Function, Prev: General Functions, Up: Library Functions
-12.3 Data File Management
+13.3 Data File Management
=========================
This minor node presents functions that are useful for managing
@@ -15000,7 +15904,7 @@ command-line data files.

File: gawk.info, Node: Filetrans Function, Next: Rewind Function, Up: Data File Management
-12.3.1 Noting Data File Boundaries
+13.3.1 Noting Data File Boundaries
----------------------------------
The `BEGIN' and `END' rules are each executed exactly once at the
@@ -15098,7 +16002,7 @@ it provides an easy way to do per-file cleanup processing.

File: gawk.info, Node: Rewind Function, Next: File Checking, Prev: Filetrans Function, Up: Data File Management
-12.3.2 Rereading the Current File
+13.3.2 Rereading the Current File
---------------------------------
Another request for a new built-in function was for a `rewind()'
@@ -15140,7 +16044,7 @@ Nextfile Statement::).

File: gawk.info, Node: File Checking, Next: Empty Files, Prev: Rewind Function, Up: Data File Management
-12.3.3 Checking for Readable Data Files
+13.3.3 Checking for Readable Data Files
---------------------------------------
Normally, if you give `awk' a data file that isn't readable, it stops
@@ -15169,7 +16073,7 @@ in the list). See also *note ARGC and ARGV::.

File: gawk.info, Node: Empty Files, Next: Ignoring Assigns, Prev: File Checking, Up: Data File Management
-12.3.4 Checking For Zero-length Files
+13.3.4 Checking For Zero-length Files
-------------------------------------
All known `awk' implementations silently skip over zero-length files.
@@ -15226,7 +16130,7 @@ intervening value in `ARGV' is a variable assignment.

File: gawk.info, Node: Ignoring Assigns, Prev: Empty Files, Up: Data File Management
-12.3.5 Treating Assignments as File Names
+13.3.5 Treating Assignments as File Names
-----------------------------------------
Occasionally, you might not want `awk' to process command-line variable
@@ -15269,7 +16173,7 @@ arguments are left alone.

File: gawk.info, Node: Getopt Function, Next: Passwd Functions, Prev: Data File Management, Up: Library Functions
-12.4 Processing Command-Line Options
+13.4 Processing Command-Line Options
====================================
Most utilities on POSIX compatible systems take options on the command
@@ -15562,7 +16466,7 @@ have left it alone, since using `substr()' is more portable.

File: gawk.info, Node: Passwd Functions, Next: Group Functions, Prev: Getopt Function, Up: Library Functions
-12.5 Reading the User Database
+13.5 Reading the User Database
==============================
The `PROCINFO' array (*note Built-in Variables::) provides access to
@@ -15805,7 +16709,7 @@ network database.

File: gawk.info, Node: Group Functions, Next: Walking Arrays, Prev: Passwd Functions, Up: Library Functions
-12.6 Reading the Group Database
+13.6 Reading the Group Database
===============================
Much of the discussion presented in *note Passwd Functions::, applies
@@ -16039,7 +16943,7 @@ very simple, relying on `awk''s associative arrays to do work.

File: gawk.info, Node: Walking Arrays, Prev: Group Functions, Up: Library Functions
-12.7 Traversing Arrays of Arrays
+13.7 Traversing Arrays of Arrays
================================
*note Arrays of Arrays::, described how `gawk' provides arrays of
@@ -16090,7 +16994,7 @@ value. Here is a main program to demonstrate:

File: gawk.info, Node: Sample Programs, Next: Debugger, Prev: Library Functions, Up: Top
-13 Practical `awk' Programs
+14 Practical `awk' Programs
***************************
*note Library Functions::, presents the idea that reading programs in a
@@ -16110,7 +17014,7 @@ Library Functions::.

File: gawk.info, Node: Running Examples, Next: Clones, Up: Sample Programs
-13.1 Running the Example Programs
+14.1 Running the Example Programs
=================================
To run a given program, you would typically do something like this:
@@ -16133,7 +17037,7 @@ OPTIONS are any command-line options for the program that start with a

File: gawk.info, Node: Clones, Next: Miscellaneous Programs, Prev: Running Examples, Up: Sample Programs
-13.2 Reinventing Wheels for Fun and Profit
+14.2 Reinventing Wheels for Fun and Profit
==========================================
This minor node presents a number of POSIX utilities implemented in
@@ -16163,7 +17067,7 @@ programming for "real world" tasks.

File: gawk.info, Node: Cut Program, Next: Egrep Program, Up: Clones
-13.2.1 Cutting out Fields and Columns
+14.2.1 Cutting out Fields and Columns
-------------------------------------
The `cut' utility selects, or "cuts," characters or fields from its
@@ -16422,7 +17326,7 @@ solution to the problem of picking the input line apart by characters.

File: gawk.info, Node: Egrep Program, Next: Id Program, Prev: Cut Program, Up: Clones
-13.2.2 Searching for Regular Expressions in Files
+14.2.2 Searching for Regular Expressions in Files
-------------------------------------------------
The `egrep' utility searches files for patterns. It uses regular
@@ -16654,7 +17558,7 @@ the translated line, not the original.

File: gawk.info, Node: Id Program, Next: Split Program, Prev: Egrep Program, Up: Clones
-13.2.3 Printing out User Information
+14.2.3 Printing out User Information
------------------------------------
The `id' utility lists a user's real and effective user ID numbers,
@@ -16761,7 +17665,7 @@ body never executes.

File: gawk.info, Node: Split Program, Next: Tee Program, Prev: Id Program, Up: Clones
-13.2.4 Splitting a Large File into Pieces
+14.2.4 Splitting a Large File into Pieces
-----------------------------------------
The `split' program splits large text files into smaller pieces. Usage
@@ -16869,7 +17773,7 @@ not relevant for what the program aims to demonstrate.

File: gawk.info, Node: Tee Program, Next: Uniq Program, Prev: Split Program, Up: Clones
-13.2.5 Duplicating Output into Multiple Files
+14.2.5 Duplicating Output into Multiple Files
---------------------------------------------
The `tee' program is known as a "pipe fitting." `tee' copies its
@@ -16957,7 +17861,7 @@ N input records and M output files, the first method only executes N

File: gawk.info, Node: Uniq Program, Next: Wc Program, Prev: Tee Program, Up: Clones
-13.2.6 Printing Nonduplicated Lines of Text
+14.2.6 Printing Nonduplicated Lines of Text
-------------------------------------------
The `uniq' utility reads sorted lines of data on its standard input,
@@ -17176,7 +18080,7 @@ line of input data:

File: gawk.info, Node: Wc Program, Prev: Uniq Program, Up: Clones
-13.2.7 Counting Things
+14.2.7 Counting Things
----------------------
The `wc' (word count) utility counts lines, words, and characters in
@@ -17321,7 +18225,7 @@ characters, not bytes.

File: gawk.info, Node: Miscellaneous Programs, Prev: Clones, Up: Sample Programs
-13.3 A Grab Bag of `awk' Programs
+14.3 A Grab Bag of `awk' Programs
=================================
This minor node is a large "grab bag" of miscellaneous programs. We
@@ -17348,7 +18252,7 @@ hope you find them both interesting and enjoyable.

File: gawk.info, Node: Dupword Program, Next: Alarm Program, Up: Miscellaneous Programs
-13.3.1 Finding Duplicated Words in a Document
+14.3.1 Finding Duplicated Words in a Document
---------------------------------------------
A common error when writing large amounts of prose is to accidentally
@@ -17396,7 +18300,7 @@ word, comparing it to the previous one:

File: gawk.info, Node: Alarm Program, Next: Translate Program, Prev: Dupword Program, Up: Miscellaneous Programs
-13.3.2 An Alarm Clock Program
+14.3.2 An Alarm Clock Program
-----------------------------
Nothing cures insomnia like a ringing alarm clock.
@@ -17529,7 +18433,7 @@ necessary:

File: gawk.info, Node: Translate Program, Next: Labels Program, Prev: Alarm Program, Up: Miscellaneous Programs
-13.3.3 Transliterating Characters
+14.3.3 Transliterating Characters
---------------------------------
The system `tr' utility transliterates characters. For example, it is
@@ -17655,7 +18559,7 @@ split each character in a string into separate array elements.

File: gawk.info, Node: Labels Program, Next: Word Sorting, Prev: Translate Program, Up: Miscellaneous Programs
-13.3.4 Printing Mailing Labels
+14.3.4 Printing Mailing Labels
------------------------------
Here is a "real world"(1) program. This script reads lists of names and
@@ -17762,7 +18666,7 @@ something done."

File: gawk.info, Node: Word Sorting, Next: History Sorting, Prev: Labels Program, Up: Miscellaneous Programs
-13.3.5 Generating Word-Usage Counts
+14.3.5 Generating Word-Usage Counts
-----------------------------------
When working with large amounts of text, it can be interesting to know
@@ -17866,7 +18770,7 @@ operating system documentation for more information on how to use the

File: gawk.info, Node: History Sorting, Next: Extract Program, Prev: Word Sorting, Up: Miscellaneous Programs
-13.3.6 Removing Duplicates from Unsorted Text
+14.3.6 Removing Duplicates from Unsorted Text
---------------------------------------------
The `uniq' program (*note Uniq Program::), removes duplicate lines from
@@ -17913,7 +18817,7 @@ seen.

File: gawk.info, Node: Extract Program, Next: Simple Sed, Prev: History Sorting, Up: Miscellaneous Programs
-13.3.7 Extracting Programs from Texinfo Source Files
+14.3.7 Extracting Programs from Texinfo Source Files
----------------------------------------------------
The nodes *note Library Functions::, and *note Sample Programs::, are
@@ -18113,7 +19017,7 @@ function. Consider how you might use it to simplify the code.

File: gawk.info, Node: Simple Sed, Next: Igawk Program, Prev: Extract Program, Up: Miscellaneous Programs
-13.3.8 A Simple Stream Editor
+14.3.8 A Simple Stream Editor
-----------------------------
The `sed' utility is a stream editor, a program that reads a stream of
@@ -18194,7 +19098,7 @@ the single rule handles the printing scheme outlined above, using

File: gawk.info, Node: Igawk Program, Next: Anagram Program, Prev: Simple Sed, Up: Miscellaneous Programs
-13.3.9 An Easy Way to Use Library Functions
+14.3.9 An Easy Way to Use Library Functions
-------------------------------------------
In *note Include Files::, we saw how `gawk' provides a built-in
@@ -18591,7 +19495,7 @@ can loop forever if the file exists but is empty. Caveat emptor.

File: gawk.info, Node: Anagram Program, Next: Signature Program, Prev: Igawk Program, Up: Miscellaneous Programs
-13.3.10 Finding Anagrams From A Dictionary
+14.3.10 Finding Anagrams From A Dictionary
------------------------------------------
An interesting programming challenge is to search for "anagrams" in a
@@ -18681,7 +19585,7 @@ otherwise the anagrams would appear in arbitrary order:

File: gawk.info, Node: Signature Program, Prev: Anagram Program, Up: Miscellaneous Programs
-13.3.11 And Now For Something Completely Different
+14.3.11 And Now For Something Completely Different
--------------------------------------------------
The following program was written by Davide Brini and is published on
@@ -18708,45 +19612,46 @@ supplies the following copyright terms:

File: gawk.info, Node: Debugger, Next: Language History, Prev: Sample Programs, Up: Top
-14 `dgawk': The `awk' Debugger
-******************************
+15 Debugging `awk' Programs
+***************************
It would be nice if computer programs worked perfectly the first time
they were run, but in real life, this rarely happens for programs of
any complexity. Thus, most programming languages have facilities
available for "debugging" programs, and now `awk' is no exception.
- The `dgawk' debugger is purposely modeled after the GNU Debugger
+ The `gawk' debugger is purposely modeled after the GNU Debugger
(GDB) (http://www.gnu.org/software/gdb/) command-line debugger. If you
-are familiar with GDB, learning `dgawk' is easy.
+are familiar with GDB, learning how to use `gawk' for debugging your
+program is easy.
* Menu:
-* Debugging:: Introduction to `dgawk'.
-* Sample dgawk session:: Sample `dgawk' session.
-* List of Debugger Commands:: Main `dgawk' Commands.
-* Readline Support:: Readline Support.
-* Dgawk Limitations:: Limitations and future plans.
+* Debugging:: Introduction to `gawk' debugger.
+* Sample Debugging Session:: Sample debugging session.
+* List of Debugger Commands:: Main debugger commands.
+* Readline Support:: Readline support.
+* Limitations:: Limitations and future plans.

-File: gawk.info, Node: Debugging, Next: Sample dgawk session, Up: Debugger
+File: gawk.info, Node: Debugging, Next: Sample Debugging Session, Up: Debugger
-14.1 Introduction to `dgawk'
-============================
+15.1 Introduction to `gawk' Debugger
+====================================
This minor node introduces debugging in general and begins the
discussion of debugging in `gawk'.
* Menu:
-* Debugging Concepts:: Debugging In General.
+* Debugging Concepts:: Debugging in General.
* Debugging Terms:: Additional Debugging Concepts.
* Awk Debugging:: Awk Debugging.

File: gawk.info, Node: Debugging Concepts, Next: Debugging Terms, Up: Debugging
-14.1.1 Debugging In General
+15.1.1 Debugging in General
---------------------------
(If you have used debuggers in other languages, you may want to skip
@@ -18786,13 +19691,12 @@ functional program that you or someone else wrote).

File: gawk.info, Node: Debugging Terms, Next: Awk Debugging, Prev: Debugging Concepts, Up: Debugging
-14.1.2 Additional Debugging Concepts
+15.1.2 Additional Debugging Concepts
------------------------------------
Before diving in to the details, we need to introduce several important
-concepts that apply to just about all debuggers, including `dgawk'.
-The following list defines terms used throughout the rest of this
-major node.
+concepts that apply to just about all debuggers. The following list
+defines terms used throughout the rest of this major node.
"Stack Frame"
Programs generally call functions during the course of their
@@ -18810,11 +19714,11 @@ major node.
needed to manage the call stack. This data area is termed a
"stack frame".
- `gawk' also follows this model, and `dgawk' gives you access to
- the call stack and to each stack frame. You can see the call
- stack, as well as from where each function on the stack was
- invoked. Commands that print the call stack print information about
- each stack frame (as detailed later on).
+ `gawk' also follows this model, and gives you access to the call
+ stack and to each stack frame. You can see the call stack, as well
+ as from where each function on the stack was invoked. Commands
+ that print the call stack print information about each stack frame
+ (as detailed later on).
"Breakpoint"
During debugging, you often wish to let the program run until it
@@ -18839,7 +19743,7 @@ major node.

File: gawk.info, Node: Awk Debugging, Prev: Debugging Terms, Up: Debugging
-14.1.3 Awk Debugging
+15.1.3 Awk Debugging
--------------------
Debugging an `awk' program has some specific aspects that are not
@@ -18859,54 +19763,57 @@ individual primitive instructions carried out by the higher-level `awk'
commands.

-File: gawk.info, Node: Sample dgawk session, Next: List of Debugger Commands, Prev: Debugging, Up: Debugger
+File: gawk.info, Node: Sample Debugging Session, Next: List of Debugger Commands, Prev: Debugging, Up: Debugger
-14.2 Sample `dgawk' session
-===========================
+15.2 Sample Debugging Session
+=============================
-In order to illustrate the use of `dgawk', let's look at a sample
-debugging session. We will use the `awk' implementation of the POSIX
-`uniq' command described earlier (*note Uniq Program::) as our example.
+In order to illustrate the use of `gawk' as a debugger, let's look at a
+sample debugging session. We will use the `awk' implementation of the
+POSIX `uniq' command described earlier (*note Uniq Program::) as our
+example.
* Menu:
-* dgawk invocation:: `dgawk' Invocation.
-* Finding The Bug:: Finding The Bug.
+* Debugger Invocation:: How to Start the Debugger.
+* Finding The Bug:: Finding the Bug.

-File: gawk.info, Node: dgawk invocation, Next: Finding The Bug, Up: Sample dgawk session
+File: gawk.info, Node: Debugger Invocation, Next: Finding The Bug, Up: Sample Debugging Session
-14.2.1 `dgawk' Invocation
--------------------------
+15.2.1 How to Start the Debugger
+--------------------------------
-Starting `dgawk' is exactly like running `awk'. The file(s) containing
-the program and any supporting code are given on the command line as
-arguments to one or more `-f' options. (`dgawk' is not designed to
-debug command-line programs, only programs contained in files.) In our
-case, we call `dgawk' like this:
+Starting the debugger is almost exactly like running `awk', except you
+have to pass an additional option `--debug' or the corresponding short
+option `-D'. The file(s) containing the program and any supporting
+code are given on the command line as arguments to one or more `-f'
+options. (`gawk' is not designed to debug command-line programs, only
+programs contained in files.) In our case, we invoke the debugger like
+this:
- $ dgawk -f getopt.awk -f join.awk -f uniq.awk inputfile
+ $ gawk -D -f getopt.awk -f join.awk -f uniq.awk inputfile
where both `getopt.awk' and `uniq.awk' are in `$AWKPATH'. (Experienced
users of GDB or similar debuggers should note that this syntax is
-slightly different from what they are used to. With `dgawk', the
-arguments for running the program are given in the command line to the
-debugger rather than as part of the `run' command at the debugger
+slightly different from what they are used to. With `gawk' debugger,
+the arguments for running the program are given in the command line to
+the debugger rather than as part of the `run' command at the debugger
prompt.)
Instead of immediately running the program on `inputfile', as `gawk'
-would ordinarily do, `dgawk' merely loads all the program source files,
-compiles them internally, and then gives us a prompt:
+would ordinarily do, the debugger merely loads all the program source
+files, compiles them internally, and then gives us a prompt:
- dgawk>
+ gawk>
from which we can issue commands to the debugger. At this point, no
code has been executed.

-File: gawk.info, Node: Finding The Bug, Prev: dgawk invocation, Up: Sample dgawk session
+File: gawk.info, Node: Finding The Bug, Prev: Debugger Invocation, Up: Sample Debugging Session
-14.2.2 Finding The Bug
+15.2.2 Finding the Bug
----------------------
Let's say that we are having a problem using (a faulty version of)
@@ -18936,27 +19843,27 @@ for a breakpoint in `uniq.awk' is at the beginning of the function
`are_equal()', which compares the current line with the previous one.
To set the breakpoint, use the `b' (breakpoint) command:
- dgawk> b are_equal
+ gawk> b are_equal
-| Breakpoint 1 set at file `awklib/eg/prog/uniq.awk', line 64
The debugger tells us the file and line number where the breakpoint
is. Now type `r' or `run' and the program runs until it hits the
breakpoint for the first time:
- dgawk> r
+ gawk> r
-| Starting program:
-| Stopping in Rule ...
-| Breakpoint 1, are_equal(n, m, clast, cline, alast, aline)
at `awklib/eg/prog/uniq.awk':64
-| 64 if (fcount == 0 && charcount == 0)
- dgawk>
+ gawk>
Now we can look at what's going on inside our program. First of all,
let's see how we got to where we are. At the prompt, we type `bt'
-(short for "backtrace"), and `dgawk' responds with a listing of the
-current stack frames:
+(short for "backtrace"), and the debugger responds with a listing of
+the current stack frames:
- dgawk> bt
+ gawk> bt
-| #0 are_equal(n, m, clast, cline, alast, aline)
at `awklib/eg/prog/uniq.awk':69
-| #1 in main() at `awklib/eg/prog/uniq.awk':89
@@ -18970,9 +19877,9 @@ the key to finding the source of the problem.)
Now that we're in `are_equal()', we can start looking at the values
of some variables. Let's say we type `p n' (`p' is short for "print").
We would expect to see the value of `n', a parameter to `are_equal()'.
-Actually, `dgawk' gives us:
+Actually, the debugger gives us:
- dgawk> p n
+ gawk> p n
-| n = untyped variable
In this case, `n' is an uninitialized local variable, since the
@@ -18980,13 +19887,13 @@ function was called without arguments (*note Function Calls::).
A more useful variable to display might be the current record:
- dgawk> p $0
+ gawk> p $0
-| $0 = string ("gawk is a wonderful program!")
This might be a bit puzzling at first since this is the second line of
our test input above. Let's look at `NR':
- dgawk> p NR
+ gawk> p NR
-| NR = number (2)
So we can see that `are_equal()' was only called for the second record
@@ -19000,7 +19907,7 @@ for `NR == 1':
OK, let's just check that that rule worked correctly:
- dgawk> p last
+ gawk> p last
-| last = string ("awk is a wonderful program!")
Everything we have done so far has verified that the program has
@@ -19009,7 +19916,7 @@ the problem must be inside this function. To investigate further, we
must begin "stepping through" the lines of `are_equal()'. We start by
typing `n' (for "next"):
- dgawk> n
+ gawk> n
-| 67 if (fcount > 0) {
This tells us that `gawk' is now ready to execute line 67, which
@@ -19025,15 +19932,15 @@ was false.)
Continuing to step, we now get to the splitting of the current and
last records:
- dgawk> n
+ gawk> n
-| 68 n = split(last, alast)
- dgawk> n
+ gawk> n
-| 69 m = split($0, aline)
At this point, we should be curious to see what our records were
split into, so we try to look:
- dgawk> p n m alast aline
+ gawk> p n m alast aline
-| n = number (5)
-| m = number (5)
-| alast = array, 5 elements
@@ -19049,19 +19956,19 @@ want to see inside the array?
The first choice would be to use subscripts:
- dgawk> p alast[0]
+ gawk> p alast[0]
-| "0" not in array `alast'
Oops!
- dgawk> p alast[1]
+ gawk> p alast[1]
-| alast["1"] = string ("awk")
- This would be kind of slow for a 100-member array, though, so
-`dgawk' provides a shortcut (reminiscent of another language not to be
+ This would be kind of slow for a 100-member array, though, so `gawk'
+provides a shortcut (reminiscent of another language not to be
mentioned):
- dgawk> p @alast
+ gawk> p @alast
-| alast["1"] = string ("awk")
-| alast["2"] = string ("is")
-| alast["3"] = string ("a")
@@ -19070,9 +19977,9 @@ mentioned):
It looks like we got this far OK. Let's take another step or two:
- dgawk> n
+ gawk> n
-| 70 clast = join(alast, fcount, n)
- dgawk> n
+ gawk> n
-| 71 cline = join(aline, fcount, m)
Well, here we are at our error (sorry to spoil the suspense). What
@@ -19080,7 +19987,7 @@ we had in mind was to join the fields starting from the second one to
make the virtual record to compare, and if the first field was numbered
zero, this would work. Let's look at what we've got:
- dgawk> p cline clast
+ gawk> p cline clast
-| cline = string ("gawk is a wonderful program!")
-| clast = string ("awk is a wonderful program!")
@@ -19088,9 +19995,9 @@ zero, this would work. Let's look at what we've got:
unaltered, input records. A little thinking (the human brain is still
the best debugging tool), and we realize that we were off by one!
- We get out of `dgawk':
+ We get out of the debugger:
- dgawk> q
+ gawk> q
-| The program is running. Exit anyway (y/n)? y
Then we get into an editor:
@@ -19101,12 +20008,13 @@ Then we get into an editor:
and problem solved!

-File: gawk.info, Node: List of Debugger Commands, Next: Readline Support, Prev: Sample dgawk session, Up: Debugger
+File: gawk.info, Node: List of Debugger Commands, Next: Readline Support, Prev: Sample Debugging Session, Up: Debugger
-14.3 Main `dgawk' Commands
-==========================
+15.3 Main Debugger Commands
+===========================
-The `dgawk' command set can be divided into the following categories:
+The `gawk' debugger command set can be divided into the following
+categories:
* Breakpoint control
@@ -19122,26 +20030,26 @@ The `dgawk' command set can be divided into the following categories:
Each of these are discussed in the following subsections. In the
following descriptions, commands which may be abbreviated show the
-abbreviation on a second description line. A `dgawk' command name may
-also be truncated if that partial name is unambiguous. `dgawk' has the
-built-in capability to automatically repeat the previous command when
-just hitting <Enter>. This works for the commands `list', `next',
+abbreviation on a second description line. A debugger command name may
+also be truncated if that partial name is unambiguous. The debugger has
+the built-in capability to automatically repeat the previous command
+when just hitting <Enter>. This works for the commands `list', `next',
`nexti', `step', `stepi' and `continue' executed without any argument.
* Menu:
-* Breakpoint Control:: Control of breakpoints.
-* Dgawk Execution Control:: Control of execution.
-* Viewing And Changing Data:: Viewing and changing data.
-* Dgawk Stack:: Dealing with the stack.
-* Dgawk Info:: Obtaining information about the program and
- the debugger state.
-* Miscellaneous Dgawk Commands:: Miscellaneous Commands.
+* Breakpoint Control:: Control of Breakpoints.
+* Debugger Execution Control:: Control of Execution.
+* Viewing And Changing Data:: Viewing and Changing Data.
+* Execution Stack:: Dealing with the Stack.
+* Debugger Info:: Obtaining Information about the Program and
+ the Debugger State.
+* Miscellaneous Debugger Commands:: Miscellaneous Commands.

-File: gawk.info, Node: Breakpoint Control, Next: Dgawk Execution Control, Up: List of Debugger Commands
+File: gawk.info, Node: Breakpoint Control, Next: Debugger Execution Control, Up: List of Debugger Commands
-14.3.1 Control Of Breakpoints
+15.3.1 Control of Breakpoints
-----------------------------
As we saw above, the first thing you probably want to do in a debugging
@@ -19169,10 +20077,10 @@ controlling breakpoints are:
it from the breakpoint list using the `delete' command.
With a breakpoint, you may also supply a condition. This is an
- `awk' expression (enclosed in double quotes) that `dgawk'
+ `awk' expression (enclosed in double quotes) that the debugger
evaluates whenever the breakpoint is reached. If the condition is
- true, then `dgawk' stops execution and prompts for a command.
- Otherwise, `dgawk' continues executing the program.
+ true, then the debugger stops execution and prompts for a command.
+ Otherwise, it continues executing the program.
`clear' [[FILENAME`:']N | FUNCTION]
Without any argument, delete any breakpoint at the next instruction
@@ -19194,12 +20102,13 @@ controlling breakpoints are:
`condition' N `"EXPRESSION"'
Add a condition to existing breakpoint or watchpoint N. The
- condition is an `awk' expression that `dgawk' evaluates whenever
- the breakpoint or watchpoint is reached. If the condition is true,
- then `dgawk' stops execution and prompts for a command. Otherwise,
- `dgawk' continues executing the program. If the condition
- expression is not specified, any existing condition is removed;
- i.e., the breakpoint or watchpoint is made unconditional.
+ condition is an `awk' expression that the debugger evaluates
+ whenever the breakpoint or watchpoint is reached. If the condition
+ is true, then the debugger stops execution and prompts for a
+ command. Otherwise, the debugger continues executing the program.
+ If the condition expression is not specified, any existing
+ condition is removed; i.e., the breakpoint or watchpoint is made
+ unconditional.
`delete' [N1 N2 ...] [N-M]
`d' [N1 N2 ...] [N-M]
@@ -19233,9 +20142,9 @@ controlling breakpoints are:
arguments are the same as for `break'.

-File: gawk.info, Node: Dgawk Execution Control, Next: Viewing And Changing Data, Prev: Breakpoint Control, Up: List of Debugger Commands
+File: gawk.info, Node: Debugger Execution Control, Next: Viewing And Changing Data, Prev: Breakpoint Control, Up: List of Debugger Commands
-14.3.2 Control of Execution
+15.3.2 Control of Execution
---------------------------
Now that your breakpoints are ready, you can start running the program
@@ -19256,14 +20165,14 @@ execution of the program than we saw in our earlier example:
`continue') terminates the list (an implicit `end'), and
subsequent commands are ignored. For example:
- dgawk> commands
+ gawk> commands
> silent
> printf "A silent breakpoint; i = %d\n", i
> info locals
> set i = 10
> continue
> end
- dgawk>
+ gawk>
`continue' [COUNT]
`c' [COUNT]
@@ -19296,9 +20205,9 @@ execution of the program than we saw in our earlier example:
`run'
`r'
- Start/restart execution of the program. When restarting, `dgawk'
- retains the current breakpoints, watchpoints, command history,
- automatic display variables, and debugger options.
+ Start/restart execution of the program. When restarting, the
+ debugger retains the current breakpoints, watchpoints, command
+ history, automatic display variables, and debugger options.
`step' [COUNT]
`s' [COUNT]
@@ -19313,7 +20222,7 @@ execution of the program than we saw in our earlier example:
Execute one (or COUNT) instruction(s), stepping inside function
calls. (For illustration of what is meant by an "instruction" in
`gawk', see the output shown under `dump' in *note Miscellaneous
- Dgawk Commands::.)
+ Debugger Commands::.)
`until' [[FILENAME`:']N | FUNCTION]
`u' [[FILENAME`:']N | FUNCTION]
@@ -19323,9 +20232,9 @@ execution of the program than we saw in our earlier example:
current stack frame returns.

-File: gawk.info, Node: Viewing And Changing Data, Next: Dgawk Stack, Prev: Dgawk Execution Control, Up: List of Debugger Commands
+File: gawk.info, Node: Viewing And Changing Data, Next: Execution Stack, Prev: Debugger Execution Control, Up: List of Debugger Commands
-14.3.3 Viewing and Changing Data
+15.3.3 Viewing and Changing Data
--------------------------------
The commands for viewing and changing variables inside of `gawk' are:
@@ -19335,7 +20244,7 @@ The commands for viewing and changing variables inside of `gawk' are:
of the variable or field is displayed each time the program stops.
Each variable added to the list is identified by a unique number:
- dgawk> display x
+ gawk> display x
-| 10: x = 1
displays the assigned item number, the variable name and its
@@ -19363,7 +20272,7 @@ AWK STATEMENTS
Print the value of a `gawk' variable or field. Fields must be
referenced by constants:
- dgawk> print $3
+ gawk> print $3
This prints the third field in the input record (if the specified
field does not exist, it prints `Null field'). A variable can be
@@ -19391,16 +20300,16 @@ AWK STATEMENTS
`watch' VAR | `$'N [`"EXPRESSION"']
`w' VAR | `$'N [`"EXPRESSION"']
- Add variable VAR (or field `$N') to the watch list. `dgawk' then
- stops whenever the value of the variable or field changes. Each
- watched item is assigned a number which can be used to delete it
- from the watch list using the `unwatch' command.
+ Add variable VAR (or field `$N') to the watch list. The debugger
+ then stops whenever the value of the variable or field changes.
+ Each watched item is assigned a number which can be used to delete
+ it from the watch list using the `unwatch' command.
With a watchpoint, you may also supply a condition. This is an
- `awk' expression (enclosed in double quotes) that `dgawk'
+ `awk' expression (enclosed in double quotes) that the debugger
evaluates whenever the watchpoint is reached. If the condition is
- true, then `dgawk' stops execution and prompts for a command.
- Otherwise, `dgawk' continues executing the program.
+ true, then the debugger stops execution and prompts for a command.
+ Otherwise, `gawk' continues executing the program.
`undisplay' [N]
Remove item number N (or all items, if no argument) from the
@@ -19412,9 +20321,9 @@ AWK STATEMENTS

-File: gawk.info, Node: Dgawk Stack, Next: Dgawk Info, Prev: Viewing And Changing Data, Up: List of Debugger Commands
+File: gawk.info, Node: Execution Stack, Next: Debugger Info, Prev: Viewing And Changing Data, Up: List of Debugger Commands
-14.3.4 Dealing With The Stack
+15.3.4 Dealing with the Stack
-----------------------------
Whenever you run a program which contains any function calls, `gawk'
@@ -19449,16 +20358,17 @@ are:
frame. Then select and print the frame.

-File: gawk.info, Node: Dgawk Info, Next: Miscellaneous Dgawk Commands, Prev: Dgawk Stack, Up: List of Debugger Commands
+File: gawk.info, Node: Debugger Info, Next: Miscellaneous Debugger Commands, Prev: Execution Stack, Up: List of Debugger Commands
-14.3.5 Obtaining Information About The Program and The Debugger State
+15.3.5 Obtaining Information about the Program and the Debugger State
---------------------------------------------------------------------
Besides looking at the values of variables, there is often a need to get
other sorts of information about the state of your program and of the
-debugging environment itself. `dgawk' has one command which provides
-this information, appropriately called `info'. `info' is used with one
-of a number of arguments that tell it exactly what you want to know:
+debugging environment itself. The `gawk' debugger has one command which
+provides this information, appropriately called `info'. `info' is used
+with one of a number of arguments that tell it exactly what you want to
+know:
`info' WHAT
`i' WHAT
@@ -19486,10 +20396,10 @@ of a number of arguments that tell it exactly what you want to know:
`source'
The name of the current source file. Each time the program
stops, the current source file is the file containing the
- current instruction. When `dgawk' first starts, the current
- source file is the first file included via the `-f' option.
- The `list FILENAME:LINENO' command can be used at any time to
- change the current source.
+ current instruction. When the debugger first starts, the
+ current source file is the first file included via the `-f'
+ option. The `list FILENAME:LINENO' command can be used at any
+ time to change the current source.
`sources'
List all program sources.
@@ -19513,7 +20423,7 @@ from a file. The commands are:
`history_size'
The maximum number of lines to keep in the history file
- `./.dgawk_history'. The default is 100.
+ `./.gawk_history'. The default is 100.
`listsize'
The number of lines that `list' prints. The default is 15.
@@ -19524,14 +20434,14 @@ from a file. The commands are:
standard output.
`prompt'
- The debugger prompt. The default is `dgawk> '.
+ The debugger prompt. The default is `gawk> '.
`save_history [on | off]'
- Save command history to file `./.dgawk_history'. The default
+ Save command history to file `./.gawk_history'. The default
is `on'.
`save_options [on | off]'
- Save current options to file `./.dgawkrc' upon exit. The
+ Save current options to file `./.gawkrc' upon exit. The
default is `on'. Options are read back in to the next
session upon startup.
@@ -19549,17 +20459,17 @@ from a file. The commands are:
ignored; they do _not_ repeat the last command. You can't restart
the program by having more than one `run' command in the file.
Also, the list of commands may include additional `source'
- commands; however, `dgawk' will not source the same file more than
- once in order to avoid infinite recursion.
+ commands; however, the `gawk' debugger will not source the same
+ file more than once in order to avoid infinite recursion.
In addition to, or instead of the `source' command, you can use
- the `-R FILE' or `--command=FILE' command-line options to execute
+ the `-D FILE' or `--debug=FILE' command-line options to execute
commands from a file non-interactively (*note Options::.

-File: gawk.info, Node: Miscellaneous Dgawk Commands, Prev: Dgawk Info, Up: List of Debugger Commands
+File: gawk.info, Node: Miscellaneous Debugger Commands, Prev: Debugger Info, Up: List of Debugger Commands
-14.3.6 Miscellaneous Commands
+15.3.6 Miscellaneous Commands
-----------------------------
There are a few more commands which do not fit into the previous
@@ -19573,7 +20483,7 @@ categories, as follows:
partial dump of Davide Brini's obfuscated code (*note Signature
Program::) demonstrates:
- dgawk> dump
+ gawk> dump
-| # BEGIN
-|
-| [ 2:0x89faef4] Op_rule : [in_rule = BEGIN] [source_file = brini.awk]
@@ -19622,13 +20532,13 @@ categories, as follows:
-| [ :0x89fa3b0] Op_after_beginfile :
-| [ :0x89fa388] Op_no_op :
-| [ :0x89fa3c4] Op_after_endfile :
- dgawk>
+ gawk>
`help'
`h'
- Print a list of all of the `dgawk' commands with a short summary
- of their usage. `help COMMAND' prints the information about the
- command COMMAND.
+ Print a list of all of the `gawk' debugger commands with a short
+ summary of their usage. `help COMMAND' prints the information
+ about the command COMMAND.
`list' [`-' | `+' | N | FILENAME`:'N | N-M | FUNCTION]
`l' [`-' | `+' | N | FILENAME`:'N | N-M | FUNCTION]
@@ -19662,7 +20572,7 @@ categories, as follows:
Exit the debugger. Debugging is great fun, but sometimes we all
have to tend to other obligations in life, and sometimes we find
the bug, and are free to go on to the next one! As we saw above,
- if you are running a program, `dgawk' warns you if you
+ if you are running a program, the debugger warns you if you
accidentally type `q' or `quit', to make sure you really want to
quit.
@@ -19677,12 +20587,12 @@ categories, as follows:

-File: gawk.info, Node: Readline Support, Next: Dgawk Limitations, Prev: List of Debugger Commands, Up: Debugger
+File: gawk.info, Node: Readline Support, Next: Limitations, Prev: List of Debugger Commands, Up: Debugger
-14.4 Readline Support
+15.4 Readline Support
=====================
-If `dgawk' is compiled with the `readline' library, you can take
+If `gawk' is compiled with the `readline' library, you can take
advantage of that library's command completion and history expansion
features. The following types of completion are available:
@@ -19704,27 +20614,27 @@ Variable name completion

-File: gawk.info, Node: Dgawk Limitations, Prev: Readline Support, Up: Debugger
+File: gawk.info, Node: Limitations, Prev: Readline Support, Up: Debugger
-14.5 Limitations and Future Plans
+15.5 Limitations and Future Plans
=================================
-We hope you find `dgawk' useful and enjoyable to work with, but as with
-any program, especially in its early releases, it still has some
-limitations. A few which are worth being aware of are:
+We hope you find the `gawk' debugger useful and enjoyable to work with,
+but as with any program, especially in its early releases, it still has
+some limitations. A few which are worth being aware of are:
- * At this point, `dgawk' does not give a detailed explanation of
+ * At this point, the debugger does not give a detailed explanation of
what you did wrong when you type in something it doesn't like.
Rather, it just responds `syntax error'. When you do figure out
what your mistake was, though, you'll feel like a real guru.
- * If you perused the dump of opcodes in *note Miscellaneous Dgawk
+ * If you perused the dump of opcodes in *note Miscellaneous Debugger
Commands::, (or if you are already familiar with `gawk' internals),
you will realize that much of the internal manipulation of data in
`gawk', as in many interpreters, is done on a stack. `Op_push',
`Op_pop', etc., are the "bread and butter" of most `gawk' code.
- Unfortunately, as of now, `dgawk' does not allow you to examine
- the stack's contents.
+ Unfortunately, as of now, the `gawk' debugger does not allow you
+ to examine the stack's contents.
That is, the intermediate results of expression evaluation are on
the stack, but cannot be printed. Rather, only variables which
@@ -19737,13 +20647,15 @@ limitations. A few which are worth being aware of are:
expressions to see if you got it right. As an `awk' programmer,
you are expected to know what `/[^[:alnum:][:blank:]]/' means.
- * `dgawk' is designed to be used by running a program (with all its
- parameters) on the command line, as described in *note dgawk
- invocation::. There is no way (as of now) to attach or "break in"
- to a running program. This seems reasonable for a language which
- is used mainly for quickly executing, short programs.
+ * The `gawk' debugger is designed to be used by running a program
+ (with all its parameters) on the command line, as described in
+ *note Debugger Invocation::. There is no way (as of now) to
+ attach or "break in" to a running program. This seems reasonable
+ for a language which is used mainly for quickly executing, short
+ programs.
- * `dgawk' only accepts source supplied with the `-f' option.
+ * The `gawk' debugger only accepts source supplied with the `-f'
+ option.
Look forward to a future release when these and other missing
features may be added, and of course feel free to try to add them
@@ -20319,7 +21231,7 @@ Info file, in approximate chronological order:
Windows32 environments. (This is no longer supported)
* John Haque reworked the `gawk' internals to use a byte-code engine,
- providing the `dgawk' debugger for `awk' programs.
+ providing the `gawk' debugger for `awk' programs.
* Efraim Yawitz contributed the original text for *note Debugger::.
@@ -21336,9 +22248,10 @@ Unix `awk'
`pawk'
Nelson H.F. Beebe at the University of Utah has modified Brian
Kernighan's `awk' to provide timing and profiling information. It
- is different from `pgawk' (*note Profiling::), in that it uses
- CPU-based profiling, not line-count profiling. You may find it at
- either `ftp://ftp.math.utah.edu/pub/pawk/pawk-20030606.tar.gz' or
+ is different from `gawk' with the `--profile' option. (*note
+ Profiling::), in that it uses CPU-based profiling, not line-count
+ profiling. You may find it at either
+ `ftp://ftp.math.utah.edu/pub/pawk/pawk-20030606.tar.gz' or
`http://www.math.utah.edu/pub/pawk/pawk-20030606.tar.gz'.
Busybox Awk
@@ -21735,6 +22648,7 @@ is necessary when reading this minor node.
* Internals:: A brief look at some `gawk' internals.
* Plugin License:: A note about licensing.
+* Loading Extensions:: How to load dynamic extensions.
* Sample Library:: A example of new functions.

@@ -21779,16 +22693,9 @@ when writing extensions. The next minor node shows how they are used:
is current. It may end up calling an internal `gawk' function.
It also guarantees that the wide string is zero-terminated.
-`size_t get_curfunc_arg_count(void)'
- This function returns the actual number of parameters passed to
- the current function. Inside the code of an extension this can be
- used to determine the maximum index which is safe to use with
- `get_actual_argument'. If this value is greater than `nargs', the
- function was called incorrectly from the `awk' program.
-
`nargs'
- Inside an extension function, this is the maximum number of
- expected parameters, as set by the `make_builtin()' function.
+ Inside an extension function, this is the actual number of
+ parameters passed to the current function.
`n->stptr'
`n->stlen'
@@ -21816,12 +22723,10 @@ when writing extensions. The next minor node shows how they are used:
Clears the associative array pointed to by `n'. Make sure that
`n->type == Node_var_array' first.
-`NODE **assoc_lookup(NODE *symbol, NODE *subs, int reference)'
+`NODE **assoc_lookup(NODE *symbol, NODE *subs)'
Finds, and installs if necessary, array elements. `symbol' is the
array, `subs' is the subscript. This is usually a value created
- with `make_string()' (see below). `reference' should be `TRUE' if
- it is an error to use the value before it is created. Typically,
- `FALSE' is the correct value to use from extension functions.
+ with `make_string()' (see below).
`NODE *make_string(char *s, size_t len)'
Take a C string and turn it into a pointer to a `NODE' that can be
@@ -21943,7 +22848,7 @@ function parameter.
just blindly copy this code.

-File: gawk.info, Node: Plugin License, Next: Sample Library, Prev: Internals, Up: Dynamic Extensions
+File: gawk.info, Node: Plugin License, Next: Loading Extensions, Prev: Internals, Up: Dynamic Extensions
C.3.2 Extension Licensing
-------------------------
@@ -21960,9 +22865,54 @@ the symbol exists in the global scope. Something like this is enough:
int plugin_is_GPL_compatible;

-File: gawk.info, Node: Sample Library, Prev: Plugin License, Up: Dynamic Extensions
+File: gawk.info, Node: Loading Extensions, Next: Sample Library, Prev: Plugin License, Up: Dynamic Extensions
+
+C.3.3 Loading a Dynamic Extension
+---------------------------------
+
+There are two ways to load a dynamically linked library. The first is
+to use the builtin `extension()':
+
+ extension(libname, init_func)
+
+ where `libname' is the library to load, and `init_func' is the name
+of the initialization or bootstrap routine to run once loaded.
+
+ The second method for dynamic loading of a library is to use the
+command line option `-l':
+
+ $ gawk -l libname -f myprog
+
+ This will work only if the initialization routine is named
+`dlload()'.
+
+ If you use `extension()', the library will be loaded at run time.
+This means that the functions are available only to the rest of your
+script. If you use the command line option `-l' instead, the library
+will be loaded before `gawk' starts compiling the actual program. The
+net effect is that you can use those functions anywhere in the program.
+
+ `gawk' has a list of directories where it searches for libraries.
+By default, the list includes directories that depend upon how gawk was
+built and installed (*note AWKPATH Variable::). If you want `gawk' to
+look for libraries in your private directory, you have to tell it. The
+way to do it is to set the `AWKPATH' environment variable (*note
+AWKPATH Variable::). `gawk' supplies the default suffix `.so' if it is
+not present in the name of the library. If the name of your library is
+`mylib.so', you can simply type
+
+ $ gawk -l mylib -f myprog
+
+ and `gawk' will do everything necessary to load in your library, and
+then call your `dlload()' routine.
+
+ You can always specify the library using an absolute pathname, in
+which case `gawk' will not use `AWKPATH' to search for it.
-C.3.3 Example: Directory and File Operation Built-ins
+
+File: gawk.info, Node: Sample Library, Prev: Loading Extensions, Up: Dynamic Extensions
+
+C.3.4 Example: Directory and File Operation Built-ins
-----------------------------------------------------
Two useful functions that are not in `awk' are `chdir()' (so that an
@@ -21979,7 +22929,7 @@ implements these functions for `gawk' in an external extension library.

File: gawk.info, Node: Internal File Description, Next: Internal File Ops, Up: Sample Library
-C.3.3.1 Using `chdir()' and `stat()'
+C.3.4.1 Using `chdir()' and `stat()'
....................................
This minor node shows how to use the new functions at the `awk' level
@@ -22102,7 +23052,7 @@ Elements::):

File: gawk.info, Node: Internal File Ops, Next: Using Internal File Ops, Prev: Internal File Description, Up: Sample Library
-C.3.3.2 C Code for `chdir()' and `stat()'
+C.3.4.2 C Code for `chdir()' and `stat()'
.........................................
Here is the C code for these extensions. They were written for
@@ -22123,7 +23073,7 @@ other POSIX-compliant systems:(1)
NODE *newdir;
int ret = -1;
- if (do_lint && get_curfunc_arg_count() != 1)
+ if (do_lint && nargs != 1)
lintwarn("chdir: called with incorrect number of arguments");
newdir = get_scalar_argument(0, FALSE);
@@ -22180,7 +23130,7 @@ declarations and argument checking:
char *pmode; /* printable mode */
char *type = "unknown";
- if (do_lint && get_curfunc_arg_count() > 2)
+ if (do_lint && nargs > 2)
lintwarn("stat: called with too many arguments");
Then comes the actual work. First, the function gets the arguments.
@@ -22207,15 +23157,15 @@ link. If there's an error, it sets `ERRNO' and returns:
calls are shown here, since they all follow the same pattern:
/* fill in the array */
- aptr = assoc_lookup(array, tmp = make_string("name", 4), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("name", 4));
*aptr = dupnode(file);
unref(tmp);
- aptr = assoc_lookup(array, tmp = make_string("mode", 4), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("mode", 4));
*aptr = make_number((AWKNUM) sbuf.st_mode);
unref(tmp);
- aptr = assoc_lookup(array, tmp = make_string("pmode", 5), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("pmode", 5));
pmode = format_mode(sbuf.st_mode);
*aptr = make_string(pmode, strlen(pmode));
unref(tmp);
@@ -22252,7 +23202,7 @@ version.

File: gawk.info, Node: Using Internal File Ops, Prev: Internal File Ops, Up: Sample Library
-C.3.3.3 Integrating the Extensions
+C.3.4.3 Integrating the Extensions
..................................
Now that the code is written, it must be possible to add it at runtime
@@ -24690,8 +25640,8 @@ Index
* ' (single quote): One-shot. (line 15)
* ' (single quote), vs. apostrophe: Comments. (line 27)
* ' (single quote), with double quotes: Quoting. (line 53)
+* () (parentheses) <1>: Profiling. (line 138)
* () (parentheses): Regexp Operators. (line 79)
-* () (parentheses), pgawk program: Profiling. (line 141)
* * (asterisk), * operator, as multiplication operator: Precedence.
(line 55)
* * (asterisk), * operator, as regexp operator: Regexp Operators.
@@ -24721,73 +25671,78 @@ Index
* - (hyphen), filenames beginning with: Options. (line 59)
* - (hyphen), in bracket expressions: Bracket Expressions. (line 17)
* --assign option: Options. (line 32)
+* --bignum option: Options. (line 182)
* --c option: Options. (line 78)
* --characters-as-bytes option: Options. (line 68)
-* --command option: Options. (line 231)
* --copyright option: Options. (line 85)
+* --debug option: Options. (line 105)
* --disable-lint configuration option: Additional Configuration Options.
(line 9)
* --disable-nls configuration option: Additional Configuration Options.
(line 24)
* --dump-variables option <1>: Library Names. (line 45)
* --dump-variables option: Options. (line 90)
-* --exec option: Options. (line 113)
+* --exec option: Options. (line 122)
* --field-separator option: Options. (line 21)
* --file option: Options. (line 25)
* --gen-pot option <1>: String Extraction. (line 6)
-* --gen-pot option: Options. (line 135)
-* --help option: Options. (line 142)
-* --L option: Options. (line 245)
-* --lint option <1>: Options. (line 147)
+* --gen-pot option: Options. (line 144)
+* --help option: Options. (line 151)
+* --L option: Options. (line 269)
+* --lint option <1>: Options. (line 163)
* --lint option: Command Line. (line 20)
-* --lint-old option: Options. (line 245)
+* --lint-old option: Options. (line 269)
+* --load option: Options. (line 156)
* --non-decimal-data option <1>: Nondecimal Data. (line 6)
-* --non-decimal-data option: Options. (line 166)
+* --non-decimal-data option: Options. (line 188)
* --non-decimal-data option, strtonum() function and: Nondecimal Data.
(line 36)
-* --optimize option: Options. (line 179)
-* --posix option: Options. (line 199)
-* --posix option, --traditional option and: Options. (line 218)
-* --profile option <1>: Profiling. (line 15)
-* --profile option: Options. (line 186)
-* --re-interval option: Options. (line 224)
-* --sandbox option: Options. (line 236)
+* --optimize option: Options. (line 209)
+* --posix option: Options. (line 228)
+* --posix option, --traditional option and: Options. (line 247)
+* --pretty-print option: Options. (line 201)
+* --profile option <1>: Profiling. (line 12)
+* --profile option: Options. (line 216)
+* --re-interval option: Options. (line 253)
+* --sandbox option: Options. (line 260)
* --sandbox option, disabling system() function: I/O Functions.
(line 85)
* --sandbox option, input redirection with getline: Getline. (line 19)
* --sandbox option, output redirection with print, printf: Redirection.
(line 6)
-* --source option: Options. (line 105)
+* --source option: Options. (line 114)
* --traditional option: Options. (line 78)
-* --traditional option, --posix option and: Options. (line 218)
-* --use-lc-numeric option: Options. (line 174)
-* --version option: Options. (line 250)
+* --traditional option, --posix option and: Options. (line 247)
+* --use-lc-numeric option: Options. (line 196)
+* --version option: Options. (line 274)
* --with-whiny-user-strftime configuration option: Additional Configuration Options.
(line 29)
* -b option: Options. (line 68)
* -C option: Options. (line 85)
+* -D option: Options. (line 105)
* -d option: Options. (line 90)
-* -E option: Options. (line 113)
-* -e option: Options. (line 105)
+* -E option: Options. (line 122)
+* -e option: Options. (line 114)
* -F option: Command Line Field Separator.
(line 6)
* -f option: Options. (line 25)
* -F option: Options. (line 21)
* -f option: Long. (line 12)
-* -F option, -Ft sets FS to TAB: Options. (line 258)
-* -f option, on command line: Options. (line 263)
-* -g option: Options. (line 135)
-* -h option: Options. (line 142)
-* -l option: Options. (line 147)
-* -N option: Options. (line 174)
-* -n option: Options. (line 166)
-* -O option: Options. (line 179)
-* -P option: Options. (line 199)
-* -p option: Options. (line 186)
-* -R option: Options. (line 231)
-* -r option: Options. (line 224)
-* -S option: Options. (line 236)
-* -V option: Options. (line 250)
+* -F option, -Ft sets FS to TAB: Options. (line 282)
+* -f option, on command line: Options. (line 287)
+* -g option: Options. (line 144)
+* -h option: Options. (line 151)
+* -l option: Options. (line 156)
+* -M option: Options. (line 182)
+* -N option: Options. (line 196)
+* -n option: Options. (line 188)
+* -O option: Options. (line 209)
+* -o option: Options. (line 201)
+* -P option: Options. (line 228)
+* -p option: Options. (line 216)
+* -r option: Options. (line 253)
+* -S option: Options. (line 260)
+* -V option: Options. (line 274)
* -v option: Options. (line 32)
* -v option, variables, assigning: Assignment Options. (line 12)
* -W option: Options. (line 46)
@@ -24927,7 +25882,7 @@ Index
(line 67)
* advanced features, data files as single record: Records. (line 175)
* advanced features, fixed-width data: Constant Size. (line 9)
-* advanced features, FNR/NR variables: Auto-set. (line 207)
+* advanced features, FNR/NR variables: Auto-set. (line 224)
* advanced features, gawk: Advanced Features. (line 6)
* advanced features, gawk, network programming: TCP/IP Networking.
(line 6)
@@ -24962,6 +25917,8 @@ Index
* and Boolean-logic operator: Boolean Ops. (line 6)
* and() function (gawk): Bitwise Functions. (line 39)
* ANSI: Glossary. (line 35)
+* arbitrary precision: Arbitrary Precision Arithmetic.
+ (line 6)
* archeologists: Bugs. (line 6)
* ARGC/ARGV variables <1>: ARGC and ARGV. (line 6)
* ARGC/ARGV variables: Auto-set. (line 11)
@@ -24976,18 +25933,18 @@ Index
* arguments, command-line, invoking awk: Command Line. (line 6)
* arguments, in function calls: Function Calls. (line 16)
* arguments, processing: Getopt Function. (line 6)
-* arguments, retrieving: Internals. (line 120)
+* arguments, retrieving: Internals. (line 111)
* arithmetic operators: Arithmetic Ops. (line 6)
* arrays: Arrays. (line 6)
* arrays, as parameters to functions: Pass By Value/Reference.
(line 47)
* arrays, associative: Array Intro. (line 50)
-* arrays, associative, clearing: Internals. (line 75)
+* arrays, associative, clearing: Internals. (line 68)
* arrays, associative, library functions and: Library Names. (line 57)
* arrays, deleting entire contents: Delete. (line 39)
* arrays, elements, assigning: Assigning Elements. (line 6)
* arrays, elements, deleting: Delete. (line 6)
-* arrays, elements, installing: Internals. (line 79)
+* arrays, elements, installing: Internals. (line 72)
* arrays, elements, order of: Scanning an Array. (line 48)
* arrays, elements, referencing: Reference to Elements.
(line 6)
@@ -25026,8 +25983,8 @@ Index
* assignment operators, evaluation order: Assignment Ops. (line 111)
* assignment operators, lvalues/rvalues: Assignment Ops. (line 32)
* assignments as filenames: Ignoring Assigns. (line 6)
-* assoc_clear() internal function: Internals. (line 75)
-* assoc_lookup() internal function: Internals. (line 79)
+* assoc_clear() internal function: Internals. (line 68)
+* assoc_lookup() internal function: Internals. (line 72)
* associative arrays: Array Intro. (line 50)
* asterisk (*), * operator, as multiplication operator: Precedence.
(line 55)
@@ -25043,7 +26000,10 @@ Index
* asterisk (*), *= operator: Assignment Ops. (line 129)
* atan2() function: Numeric Functions. (line 11)
* awf (amazingly workable formatter) program: Glossary. (line 25)
+* awk debugging, enabling: Options. (line 105)
+* awk enabling: Options. (line 201)
* awk language, POSIX version: Assignment Ops. (line 136)
+* awk profiling, enabling: Options. (line 216)
* awk programs <1>: Two Rules. (line 6)
* awk programs <2>: Executable Scripts. (line 6)
* awk programs: Getting Started. (line 12)
@@ -25059,7 +26019,6 @@ Index
* awk programs, location of: Options. (line 25)
* awk programs, one-line examples: Very Simple. (line 45)
* awk programs, profiling: Profiling. (line 6)
-* awk programs, profiling, enabling: Options. (line 186)
* awk programs, running <1>: Long. (line 6)
* awk programs, running: Running gawk. (line 6)
* awk programs, running, from shell scripts: One-shot. (line 22)
@@ -25099,7 +26058,7 @@ Index
* AWKNUM internal type: Internals. (line 19)
* AWKPATH environment variable <1>: PC Using. (line 11)
* AWKPATH environment variable: AWKPATH Variable. (line 6)
-* awkprof.out file: Profiling. (line 10)
+* awkprof.out file: Profiling. (line 6)
* awksed.awk program: Simple Sed. (line 25)
* awkvars.out file: Options. (line 90)
* b debugger command (alias for break): Breakpoint Control. (line 11)
@@ -25153,12 +26112,13 @@ Index
* backslash (\), in escape sequences, POSIX and: Escape Sequences.
(line 113)
* backslash (\), regexp constants: Computed Regexps. (line 28)
-* backtrace debugger command: Dgawk Stack. (line 13)
+* backtrace debugger command: Execution Stack. (line 13)
* BBS-list file: Sample Data Files. (line 6)
* Beebe, Nelson <1>: Other Versions. (line 69)
* Beebe, Nelson: Acknowledgments. (line 60)
-* BEGIN pattern <1>: BEGIN/END. (line 6)
-* BEGIN pattern <2>: Field Separators. (line 44)
+* BEGIN pattern <1>: Profiling. (line 62)
+* BEGIN pattern <2>: BEGIN/END. (line 6)
+* BEGIN pattern <3>: Field Separators. (line 44)
* BEGIN pattern: Records. (line 29)
* BEGIN pattern, assert() user-defined function and: Assert Function.
(line 83)
@@ -25173,7 +26133,6 @@ Index
* BEGIN pattern, OFS/ORS variables, assigning values to: Output Separators.
(line 20)
* BEGIN pattern, operators and: Using BEGIN/END. (line 17)
-* BEGIN pattern, pgawk program: Profiling. (line 65)
* BEGIN pattern, print statement and: I/O And BEGIN/END. (line 16)
* BEGIN pattern, pwcat program: Passwd Functions. (line 143)
* BEGIN pattern, running awk programs and: Cut Program. (line 68)
@@ -25202,8 +26161,8 @@ Index
* Boolean expressions, as patterns: Expression Patterns. (line 41)
* Boolean operators, See Boolean expressions: Boolean Ops. (line 6)
* Bourne shell, quoting rules for: Quoting. (line 18)
+* braces ({}): Profiling. (line 134)
* braces ({}), actions and: Action Overview. (line 19)
-* braces ({}), pgawk program: Profiling. (line 137)
* braces ({}), statements, grouping: Statements. (line 10)
* bracket expressions <1>: Bracket Expressions. (line 6)
* bracket expressions: Regexp Operators. (line 55)
@@ -25230,7 +26189,7 @@ Index
* Broder, Alan J.: Contributors. (line 88)
* Brown, Martin: Contributors. (line 82)
* BSD-based operating systems: Glossary. (line 611)
-* bt debugger command (alias for backtrace): Dgawk Stack. (line 13)
+* bt debugger command (alias for backtrace): Execution Stack. (line 13)
* Buening, Andreas <1>: Bugs. (line 71)
* Buening, Andreas <2>: Contributors. (line 92)
* Buening, Andreas: Acknowledgments. (line 60)
@@ -25248,7 +26207,7 @@ Index
* built-in variables, -v option, setting with: Options. (line 40)
* built-in variables, conveying information: Auto-set. (line 6)
* built-in variables, user-modifiable: User-modified. (line 6)
-* Busybox Awk: Other Versions. (line 78)
+* Busybox Awk: Other Versions. (line 79)
* call by reference: Pass By Value/Reference.
(line 47)
* call by value: Pass By Value/Reference.
@@ -25268,7 +26227,7 @@ Index
* case sensitivity, regexps and <1>: User-modified. (line 82)
* case sensitivity, regexps and: Case-sensitivity. (line 6)
* case sensitivity, string comparisons and: User-modified. (line 82)
-* CGI, awk scripts for: Options. (line 113)
+* CGI, awk scripts for: Options. (line 122)
* character lists, See bracket expressions: Regexp Operators. (line 55)
* character sets (machine character encodings) <1>: Glossary. (line 141)
* character sets (machine character encodings): Ordinal Functions.
@@ -25298,7 +26257,7 @@ Index
* close() function, two-way pipes and: Two-way I/O. (line 77)
* Close, Diane <1>: Contributors. (line 21)
* Close, Diane: Manual History. (line 41)
-* close_func() input method: Internals. (line 160)
+* close_func() input method: Internals. (line 151)
* collating elements: Bracket Expressions. (line 69)
* collating symbols: Bracket Expressions. (line 76)
* Colombo, Antonio: Acknowledgments. (line 60)
@@ -25322,7 +26281,7 @@ Index
* command line, variables, assigning on: Assignment Options. (line 6)
* command-line options, processing: Getopt Function. (line 6)
* command-line options, string extraction: String Extraction. (line 6)
-* commands debugger command: Dgawk Execution Control.
+* commands debugger command: Debugger Execution Control.
(line 10)
* commenting: Comments. (line 6)
* commenting, backslash continuation and: Statements/Lines. (line 76)
@@ -25375,8 +26334,12 @@ Index
(line 29)
* configuration options, gawk: Additional Configuration Options.
(line 6)
+* constants, floating-point: Floating-point Constants.
+ (line 6)
* constants, nondecimal: Nondecimal Data. (line 6)
* constants, types of: Constants. (line 6)
+* context, floating-point: Floating-point Context.
+ (line 6)
* continue statement: Continue Statement. (line 6)
* control statements: Statements. (line 6)
* converting, case: String Functions. (line 522)
@@ -25399,7 +26362,7 @@ Index
* cos() function: Numeric Functions. (line 15)
* counting: Wc Program. (line 6)
* csh utility: Statements/Lines. (line 44)
-* csh utility, POSIXLY_CORRECT environment variable: Options. (line 305)
+* csh utility, POSIXLY_CORRECT environment variable: Options. (line 329)
* csh utility, |& operator, comparison with: Two-way I/O. (line 44)
* ctime() user-defined function: Function Example. (line 72)
* currency symbols, localization: Explaining gettext. (line 103)
@@ -25407,7 +26370,7 @@ Index
(line 30)
* cut utility: Cut Program. (line 6)
* cut.awk program: Cut Program. (line 45)
-* d debugger command (alias for delete): Breakpoint Control. (line 63)
+* d debugger command (alias for delete): Breakpoint Control. (line 64)
* d.c., See dark corner: Conventions. (line 38)
* dark corner <1>: Glossary. (line 193)
* dark corner <2>: Truth Values. (line 24)
@@ -25431,7 +26394,7 @@ Index
(line 47)
* dark corner, FILENAME variable <1>: Auto-set. (line 92)
* dark corner, FILENAME variable: Getline Notes. (line 19)
-* dark corner, FNR/NR variables: Auto-set. (line 207)
+* dark corner, FNR/NR variables: Auto-set. (line 224)
* dark corner, format-control characters: Control Letters. (line 18)
* dark corner, FS as null string: Single Character Fields.
(line 20)
@@ -25471,113 +26434,113 @@ Index
(line 33)
* deadlocks: Two-way I/O. (line 70)
* debugger commands, b (break): Breakpoint Control. (line 11)
-* debugger commands, backtrace: Dgawk Stack. (line 13)
+* debugger commands, backtrace: Execution Stack. (line 13)
* debugger commands, break: Breakpoint Control. (line 11)
-* debugger commands, bt (backtrace): Dgawk Stack. (line 13)
-* debugger commands, c (continue): Dgawk Execution Control.
+* debugger commands, bt (backtrace): Execution Stack. (line 13)
+* debugger commands, c (continue): Debugger Execution Control.
(line 33)
* debugger commands, clear: Breakpoint Control. (line 36)
-* debugger commands, commands: Dgawk Execution Control.
+* debugger commands, commands: Debugger Execution Control.
(line 10)
* debugger commands, condition: Breakpoint Control. (line 54)
-* debugger commands, continue: Dgawk Execution Control.
+* debugger commands, continue: Debugger Execution Control.
(line 33)
-* debugger commands, d (delete): Breakpoint Control. (line 63)
-* debugger commands, delete: Breakpoint Control. (line 63)
-* debugger commands, disable: Breakpoint Control. (line 68)
+* debugger commands, d (delete): Breakpoint Control. (line 64)
+* debugger commands, delete: Breakpoint Control. (line 64)
+* debugger commands, disable: Breakpoint Control. (line 69)
* debugger commands, display: Viewing And Changing Data.
(line 8)
-* debugger commands, down: Dgawk Stack. (line 21)
-* debugger commands, dump: Miscellaneous Dgawk Commands.
+* debugger commands, down: Execution Stack. (line 21)
+* debugger commands, dump: Miscellaneous Debugger Commands.
(line 9)
-* debugger commands, e (enable): Breakpoint Control. (line 72)
-* debugger commands, enable: Breakpoint Control. (line 72)
-* debugger commands, end: Dgawk Execution Control.
+* debugger commands, e (enable): Breakpoint Control. (line 73)
+* debugger commands, enable: Breakpoint Control. (line 73)
+* debugger commands, end: Debugger Execution Control.
(line 10)
* debugger commands, eval: Viewing And Changing Data.
(line 23)
-* debugger commands, f (frame): Dgawk Stack. (line 25)
-* debugger commands, finish: Dgawk Execution Control.
+* debugger commands, f (frame): Execution Stack. (line 25)
+* debugger commands, finish: Debugger Execution Control.
(line 39)
-* debugger commands, frame: Dgawk Stack. (line 25)
-* debugger commands, h (help): Miscellaneous Dgawk Commands.
+* debugger commands, frame: Execution Stack. (line 25)
+* debugger commands, h (help): Miscellaneous Debugger Commands.
(line 68)
-* debugger commands, help: Miscellaneous Dgawk Commands.
+* debugger commands, help: Miscellaneous Debugger Commands.
(line 68)
-* debugger commands, i (info): Dgawk Info. (line 12)
-* debugger commands, ignore: Breakpoint Control. (line 86)
-* debugger commands, info: Dgawk Info. (line 12)
-* debugger commands, l (list): Miscellaneous Dgawk Commands.
+* debugger commands, i (info): Debugger Info. (line 13)
+* debugger commands, ignore: Breakpoint Control. (line 87)
+* debugger commands, info: Debugger Info. (line 13)
+* debugger commands, l (list): Miscellaneous Debugger Commands.
(line 74)
-* debugger commands, list: Miscellaneous Dgawk Commands.
+* debugger commands, list: Miscellaneous Debugger Commands.
(line 74)
-* debugger commands, n (next): Dgawk Execution Control.
+* debugger commands, n (next): Debugger Execution Control.
(line 43)
-* debugger commands, next: Dgawk Execution Control.
+* debugger commands, next: Debugger Execution Control.
(line 43)
-* debugger commands, nexti: Dgawk Execution Control.
+* debugger commands, nexti: Debugger Execution Control.
(line 49)
-* debugger commands, ni (nexti): Dgawk Execution Control.
+* debugger commands, ni (nexti): Debugger Execution Control.
(line 49)
-* debugger commands, o (option): Dgawk Info. (line 56)
-* debugger commands, option: Dgawk Info. (line 56)
+* debugger commands, o (option): Debugger Info. (line 57)
+* debugger commands, option: Debugger Info. (line 57)
* debugger commands, p (print): Viewing And Changing Data.
(line 36)
* debugger commands, print: Viewing And Changing Data.
(line 36)
* debugger commands, printf: Viewing And Changing Data.
(line 54)
-* debugger commands, q (quit): Miscellaneous Dgawk Commands.
+* debugger commands, q (quit): Miscellaneous Debugger Commands.
(line 101)
-* debugger commands, quit: Miscellaneous Dgawk Commands.
+* debugger commands, quit: Miscellaneous Debugger Commands.
(line 101)
-* debugger commands, r (run): Dgawk Execution Control.
+* debugger commands, r (run): Debugger Execution Control.
(line 62)
-* debugger commands, return: Dgawk Execution Control.
+* debugger commands, return: Debugger Execution Control.
(line 54)
-* debugger commands, run: Dgawk Execution Control.
+* debugger commands, run: Debugger Execution Control.
(line 62)
-* debugger commands, s (step): Dgawk Execution Control.
+* debugger commands, s (step): Debugger Execution Control.
(line 68)
* debugger commands, set: Viewing And Changing Data.
(line 59)
-* debugger commands, si (stepi): Dgawk Execution Control.
+* debugger commands, si (stepi): Debugger Execution Control.
(line 76)
-* debugger commands, silent: Dgawk Execution Control.
+* debugger commands, silent: Debugger Execution Control.
(line 10)
-* debugger commands, step: Dgawk Execution Control.
+* debugger commands, step: Debugger Execution Control.
(line 68)
-* debugger commands, stepi: Dgawk Execution Control.
+* debugger commands, stepi: Debugger Execution Control.
(line 76)
-* debugger commands, t (tbreak): Breakpoint Control. (line 89)
-* debugger commands, tbreak: Breakpoint Control. (line 89)
-* debugger commands, trace: Miscellaneous Dgawk Commands.
+* debugger commands, t (tbreak): Breakpoint Control. (line 90)
+* debugger commands, tbreak: Breakpoint Control. (line 90)
+* debugger commands, trace: Miscellaneous Debugger Commands.
(line 110)
-* debugger commands, u (until): Dgawk Execution Control.
+* debugger commands, u (until): Debugger Execution Control.
(line 83)
* debugger commands, undisplay: Viewing And Changing Data.
(line 80)
-* debugger commands, until: Dgawk Execution Control.
+* debugger commands, until: Debugger Execution Control.
(line 83)
* debugger commands, unwatch: Viewing And Changing Data.
(line 84)
-* debugger commands, up: Dgawk Stack. (line 33)
+* debugger commands, up: Execution Stack. (line 33)
* debugger commands, w (watch): Viewing And Changing Data.
(line 67)
* debugger commands, watch: Viewing And Changing Data.
(line 67)
+* debugging awk programs: Debugger. (line 6)
* debugging gawk, bug reports: Bugs. (line 9)
-* decimal point character, locale specific: Options. (line 215)
+* decimal point character, locale specific: Options. (line 244)
* decrement operators: Increment Ops. (line 35)
* default keyword: Switch Statement. (line 6)
* Deifik, Scott <1>: Bugs. (line 70)
* Deifik, Scott <2>: Contributors. (line 54)
* Deifik, Scott: Acknowledgments. (line 60)
-* delete debugger command: Breakpoint Control. (line 63)
+* delete debugger command: Breakpoint Control. (line 64)
* delete statement: Delete. (line 6)
* deleting elements in arrays: Delete. (line 6)
* deleting entire arrays: Delete. (line 39)
-* dgawk: Debugger. (line 6)
* differences between gawk and awk: String Functions. (line 196)
* differences in awk and gawk, ARGC/ARGV variables: ARGC and ARGV.
(line 88)
@@ -25630,7 +26593,7 @@ Index
* differences in awk and gawk, regular expressions: Case-sensitivity.
(line 26)
* differences in awk and gawk, RS/RT variables: Records. (line 167)
-* differences in awk and gawk, RT variable: Auto-set. (line 196)
+* differences in awk and gawk, RT variable: Auto-set. (line 213)
* differences in awk and gawk, single-character fields: Single Character Fields.
(line 6)
* differences in awk and gawk, split() function: String Functions.
@@ -25640,7 +26603,7 @@ Index
* differences in awk and gawk, strtonum() function (gawk): String Functions.
(line 404)
* differences in awk and gawk, TEXTDOMAIN variable: User-modified.
- (line 153)
+ (line 162)
* differences in awk and gawk, trunc-mod operation: Arithmetic Ops.
(line 66)
* directories, changing: Sample Library. (line 6)
@@ -25648,7 +26611,7 @@ Index
(line 6)
* directories, searching <1>: Igawk Program. (line 368)
* directories, searching: AWKPATH Variable. (line 6)
-* disable debugger command: Breakpoint Control. (line 68)
+* disable debugger command: Breakpoint Control. (line 69)
* display debugger command: Viewing And Changing Data.
(line 8)
* division: Arithmetic Ops. (line 44)
@@ -25666,14 +26629,14 @@ Index
* double quote (") <1>: Quoting. (line 37)
* double quote ("): Read Terminal. (line 25)
* double quote ("), regexp constants: Computed Regexps. (line 28)
-* down debugger command: Dgawk Stack. (line 21)
+* down debugger command: Execution Stack. (line 21)
* Drepper, Ulrich: Acknowledgments. (line 52)
* DuBois, John: Acknowledgments. (line 60)
-* dump debugger command: Miscellaneous Dgawk Commands.
+* dump debugger command: Miscellaneous Debugger Commands.
(line 9)
-* dupnode() internal function: Internals. (line 96)
+* dupnode() internal function: Internals. (line 87)
* dupword.awk program: Dupword Program. (line 31)
-* e debugger command (alias for enable): Breakpoint Control. (line 72)
+* e debugger command (alias for enable): Breakpoint Control. (line 73)
* EBCDIC: Ordinal Functions. (line 45)
* egrep utility <1>: Egrep Program. (line 6)
* egrep utility: Bracket Expressions. (line 24)
@@ -25689,9 +26652,10 @@ Index
* empty pattern: Empty. (line 6)
* empty strings, See null strings: Regexp Field Splitting.
(line 43)
-* enable debugger command: Breakpoint Control. (line 72)
-* end debugger command: Dgawk Execution Control.
+* enable debugger command: Breakpoint Control. (line 73)
+* end debugger command: Debugger Execution Control.
(line 10)
+* END pattern <1>: Profiling. (line 62)
* END pattern: BEGIN/END. (line 6)
* END pattern, assert() user-defined function and: Assert Function.
(line 75)
@@ -25703,7 +26667,6 @@ Index
* END pattern, next/nextfile statements and: I/O And BEGIN/END.
(line 37)
* END pattern, operators and: Using BEGIN/END. (line 17)
-* END pattern, pgawk program: Profiling. (line 65)
* END pattern, print statement and: I/O And BEGIN/END. (line 16)
* ENDFILE pattern: BEGINFILE/ENDFILE. (line 6)
* ENDFILE pattern, Boolean patterns and: Expression Patterns. (line 73)
@@ -25712,7 +26675,7 @@ Index
* endgrent() user-defined function: Group Functions. (line 218)
* endpwent() function (C library): Passwd Functions. (line 210)
* endpwent() user-defined function: Passwd Functions. (line 213)
-* ENVIRON array <1>: Internals. (line 149)
+* ENVIRON array <1>: Internals. (line 140)
* ENVIRON array: Auto-set. (line 60)
* environment variables: Auto-set. (line 60)
* epoch, definition of: Glossary. (line 239)
@@ -25721,7 +26684,7 @@ Index
* equals sign (=), == operator: Comparison Operators.
(line 11)
* EREs (Extended Regular Expressions): Bracket Expressions. (line 24)
-* ERRNO variable <1>: Internals. (line 139)
+* ERRNO variable <1>: Internals. (line 130)
* ERRNO variable <2>: TCP/IP Networking. (line 54)
* ERRNO variable <3>: Auto-set. (line 72)
* ERRNO variable <4>: BEGINFILE/ENDFILE. (line 26)
@@ -25770,7 +26733,7 @@ Index
(line 9)
* expressions, selecting: Conditional Exp. (line 6)
* Extended Regular Expressions (EREs): Bracket Expressions. (line 24)
-* eXtensible Markup Language (XML): Internals. (line 160)
+* eXtensible Markup Language (XML): Internals. (line 151)
* extension() function (gawk): Using Internal File Ops.
(line 15)
* extensions, Brian Kernighan's awk <1>: Other Versions. (line 13)
@@ -25795,7 +26758,7 @@ Index
* extract.awk program: Extract Program. (line 78)
* extraction, of marked strings (internationalization): String Extraction.
(line 6)
-* f debugger command (alias for frame): Dgawk Stack. (line 25)
+* f debugger command (alias for frame): Execution Stack. (line 25)
* false, logical: Truth Values. (line 6)
* FDL (Free Documentation License): GNU Free Documentation License.
(line 6)
@@ -25862,7 +26825,7 @@ Index
* files, /inet6/... (gawk): TCP/IP Networking. (line 6)
* files, as single records: Records. (line 196)
* files, awk programs in: Long. (line 6)
-* files, awkprof.out: Profiling. (line 10)
+* files, awkprof.out: Profiling. (line 6)
* files, awkvars.out: Options. (line 90)
* files, closing: I/O Functions. (line 10)
* files, descriptors, See file descriptors: Special FD. (line 6)
@@ -25891,7 +26854,7 @@ Index
* files, portable object template: Explaining gettext. (line 30)
* files, portable object, converting to message object files: I18N Example.
(line 62)
-* files, portable object, generating: Options. (line 135)
+* files, portable object, generating: Options. (line 144)
* files, processing, ARGIND variable and: Auto-set. (line 47)
* files, reading: Rewind Function. (line 6)
* files, reading, multiline records: Multiple Line. (line 6)
@@ -25900,18 +26863,20 @@ Index
* files, source, search path for: Igawk Program. (line 368)
* files, splitting: Split Program. (line 6)
* files, Texinfo, extracting programs from: Extract Program. (line 6)
-* finish debugger command: Dgawk Execution Control.
+* finish debugger command: Debugger Execution Control.
(line 39)
* Fish, Fred: Contributors. (line 51)
* fixed-width data: Constant Size. (line 9)
* flag variables <1>: Tee Program. (line 20)
* flag variables: Boolean Ops. (line 67)
+* floating-point numbers, arbitrary precision: Arbitrary Precision Arithmetic.
+ (line 6)
* floating-point, numbers <1>: Unexpected Results. (line 6)
* floating-point, numbers: Basic Data Typing. (line 21)
* floating-point, numbers, AWKNUM internal type: Internals. (line 19)
* FNR variable <1>: Auto-set. (line 102)
* FNR variable: Records. (line 6)
-* FNR variable, changing: Auto-set. (line 207)
+* FNR variable, changing: Auto-set. (line 224)
* for statement: For Statement. (line 6)
* for statement, in arrays: Scanning an Array. (line 20)
* force_number() internal function: Internals. (line 27)
@@ -25935,7 +26900,7 @@ Index
* FPAT variable <1>: User-modified. (line 45)
* FPAT variable: Splitting By Content.
(line 26)
-* frame debugger command: Dgawk Stack. (line 25)
+* frame debugger command: Execution Stack. (line 25)
* Free Documentation License (FDL): GNU Free Documentation License.
(line 6)
* Free Software Foundation (FSF) <1>: Glossary. (line 301)
@@ -25947,7 +26912,7 @@ Index
* FS variable, --field-separator option and: Options. (line 21)
* FS variable, as null string: Single Character Fields.
(line 20)
-* FS variable, as TAB character: Options. (line 211)
+* FS variable, as TAB character: Options. (line 240)
* FS variable, changing value of: Field Separators. (line 34)
* FS variable, running awk programs and: Cut Program. (line 68)
* FS variable, setting from command line: Command Line Field Separator.
@@ -25992,20 +26957,21 @@ Index
* functions, names of <1>: Definition Syntax. (line 20)
* functions, names of: Arrays. (line 18)
* functions, recursive: Definition Syntax. (line 73)
-* functions, return values, setting: Internals. (line 139)
+* functions, return values, setting: Internals. (line 130)
* functions, string-translation: I18N Functions. (line 6)
* functions, undefined: Pass By Value/Reference.
(line 71)
* functions, user-defined: User-defined. (line 6)
* functions, user-defined, calling: Calling A Function. (line 6)
-* functions, user-defined, counts: Profiling. (line 132)
+* functions, user-defined, counts: Profiling. (line 129)
* functions, user-defined, library of: Library Functions. (line 6)
* functions, user-defined, next/nextfile statements and <1>: Nextfile Statement.
(line 44)
* functions, user-defined, next/nextfile statements and: Next Statement.
(line 45)
-* G-d: Acknowledgments. (line 81)
+* G-d: Acknowledgments. (line 83)
* Garfinkle, Scott: Contributors. (line 35)
+* gawk program, dynamic profiling: Profiling. (line 171)
* gawk, ARGIND variable in: Other Arguments. (line 12)
* gawk, awk and <1>: This Manual. (line 14)
* gawk, awk and: Preface. (line 23)
@@ -26032,7 +26998,7 @@ Index
(line 139)
* gawk, ERRNO variable in: Getline. (line 19)
* gawk, escape sequences: Escape Sequences. (line 125)
-* gawk, extensions, disabling: Options. (line 199)
+* gawk, extensions, disabling: Options. (line 228)
* gawk, features, adding: Adding Code. (line 6)
* gawk, features, advanced: Advanced Features. (line 6)
* gawk, fflush() function in: I/O Functions. (line 44)
@@ -26046,6 +27012,7 @@ Index
(line 26)
* gawk, function arguments and: Calling Built-in. (line 16)
* gawk, functions, adding: Dynamic Extensions. (line 10)
+* gawk, functions, loading: Loading Extensions. (line 6)
* gawk, hexadecimal numbers and: Nondecimal-numbers. (line 42)
* gawk, IGNORECASE variable in <1>: Array Sorting Functions.
(line 81)
@@ -26084,7 +27051,7 @@ Index
* gawk, regular expressions, operators: GNU Regexp Operators.
(line 6)
* gawk, regular expressions, precedence: Regexp Operators. (line 161)
-* gawk, RT variable in <1>: Auto-set. (line 196)
+* gawk, RT variable in <1>: Auto-set. (line 213)
* gawk, RT variable in <2>: Getline/Variable/File.
(line 10)
* gawk, RT variable in <3>: Multiple Line. (line 129)
@@ -26093,10 +27060,10 @@ Index
* gawk, source code, obtaining: Getting. (line 6)
* gawk, splitting fields and: Constant Size. (line 87)
* gawk, string-translation functions: I18N Functions. (line 6)
-* gawk, TEXTDOMAIN variable in: User-modified. (line 153)
+* gawk, TEXTDOMAIN variable in: User-modified. (line 162)
* gawk, timestamps: Time Functions. (line 6)
* gawk, uses for: Preface. (line 36)
-* gawk, versions of, information about, printing: Options. (line 250)
+* gawk, versions of, information about, printing: Options. (line 274)
* gawk, VMS version of: VMS Installation. (line 6)
* gawk, word-boundary operator: GNU Regexp Operators.
(line 63)
@@ -26106,12 +27073,11 @@ Index
* gensub() function (gawk): Using Constant Regexps.
(line 43)
* gensub() function (gawk), escape processing: Gory Details. (line 6)
-* get_actual_argument() internal function: Internals. (line 125)
-* get_argument() internal function: Internals. (line 120)
-* get_array_argument() internal macro: Internals. (line 136)
-* get_curfunc_arg_count() internal function: Internals. (line 42)
-* get_record() input method: Internals. (line 160)
-* get_scalar_argument() internal macro: Internals. (line 133)
+* get_actual_argument() internal function: Internals. (line 116)
+* get_argument() internal function: Internals. (line 111)
+* get_array_argument() internal macro: Internals. (line 127)
+* get_record() input method: Internals. (line 151)
+* get_scalar_argument() internal macro: Internals. (line 124)
* getaddrinfo() function (C library): TCP/IP Networking. (line 38)
* getgrent() function (C library): Group Functions. (line 6)
* getgrent() user-defined function: Group Functions. (line 6)
@@ -26149,6 +27115,8 @@ Index
* gettext() function (C library): Explaining gettext. (line 62)
* gettimeofday() user-defined function: Gettimeofday Function.
(line 16)
+* GMP: Arbitrary Precision Arithmetic.
+ (line 6)
* GNITS mailing list: Acknowledgments. (line 52)
* GNU awk, See gawk: Preface. (line 49)
* GNU Free Documentation License: GNU Free Documentation License.
@@ -26157,7 +27125,7 @@ Index
* GNU Lesser General Public License: Glossary. (line 397)
* GNU long options <1>: Options. (line 6)
* GNU long options: Command Line. (line 13)
-* GNU long options, printing list of: Options. (line 142)
+* GNU long options, printing list of: Options. (line 151)
* GNU Project <1>: Glossary. (line 319)
* GNU Project: Manual History. (line 11)
* GNU/Linux <1>: Glossary. (line 611)
@@ -26176,7 +27144,7 @@ Index
(line 43)
* gsub() function, arguments of: String Functions. (line 462)
* gsub() function, escape processing: Gory Details. (line 6)
-* h debugger command (alias for help): Miscellaneous Dgawk Commands.
+* h debugger command (alias for help): Miscellaneous Debugger Commands.
(line 68)
* Hankerson, Darrel <1>: Contributors. (line 61)
* Hankerson, Darrel: Acknowledgments. (line 60)
@@ -26185,13 +27153,13 @@ Index
* Hartholz, Elaine: Acknowledgments. (line 38)
* Hartholz, Marshall: Acknowledgments. (line 38)
* Hasegawa, Isamu: Contributors. (line 94)
-* help debugger command: Miscellaneous Dgawk Commands.
+* help debugger command: Miscellaneous Debugger Commands.
(line 68)
* hexadecimal numbers: Nondecimal-numbers. (line 6)
-* hexadecimal values, enabling interpretation of: Options. (line 166)
+* hexadecimal values, enabling interpretation of: Options. (line 188)
* histsort.awk program: History Sorting. (line 25)
* Hughes, Phil: Acknowledgments. (line 43)
-* HUP signal: Profiling. (line 204)
+* HUP signal: Profiling. (line 203)
* hyphen (-), - operator: Precedence. (line 52)
* hyphen (-), -- (decrement/increment) operators: Precedence. (line 46)
* hyphen (-), -- operator: Increment Ops. (line 48)
@@ -26199,14 +27167,16 @@ Index
* hyphen (-), -= operator: Assignment Ops. (line 129)
* hyphen (-), filenames beginning with: Options. (line 59)
* hyphen (-), in bracket expressions: Bracket Expressions. (line 17)
-* i debugger command (alias for info): Dgawk Info. (line 12)
+* i debugger command (alias for info): Debugger Info. (line 13)
* id utility: Id Program. (line 6)
* id.awk program: Id Program. (line 30)
+* IEEE-754 format: Floating-point Representation.
+ (line 6)
* if statement <1>: If Statement. (line 6)
* if statement: Regexp Usage. (line 19)
* if statement, actions, changing: Ranges. (line 25)
* igawk.sh program: Igawk Program. (line 124)
-* ignore debugger command: Breakpoint Control. (line 86)
+* ignore debugger command: Breakpoint Control. (line 87)
* IGNORECASE variable <1>: Array Sorting Functions.
(line 81)
* IGNORECASE variable <2>: String Functions. (line 29)
@@ -26234,7 +27204,9 @@ Index
* index() function: String Functions. (line 155)
* indexing arrays: Array Intro. (line 50)
* indirect function calls: Indirect Calls. (line 6)
-* info debugger command: Dgawk Info. (line 12)
+* infinite precision: Arbitrary Precision Arithmetic.
+ (line 6)
+* info debugger command: Debugger Info. (line 13)
* initialization, automatic: More Complex. (line 38)
* input files: Reading Files. (line 6)
* input files, closing: Close Files And Pipes.
@@ -26259,47 +27231,48 @@ Index
* insomnia, cure for: Alarm Program. (line 6)
* installation, VMS: VMS Installation. (line 6)
* installing gawk: Installation. (line 6)
-* INT signal (MS-Windows): Profiling. (line 207)
+* INT signal (MS-Windows): Profiling. (line 206)
* int() function: Numeric Functions. (line 23)
+* integer, arbitrary precision: Arbitrary Precision Integers.
+ (line 6)
* integers: Basic Data Typing. (line 21)
* integers, unsigned: Basic Data Typing. (line 30)
* interacting with other programs: I/O Functions. (line 63)
-* internal constant, INVALID_HANDLE: Internals. (line 160)
-* internal function, assoc_clear(): Internals. (line 75)
-* internal function, assoc_lookup(): Internals. (line 79)
-* internal function, dupnode(): Internals. (line 96)
+* internal constant, INVALID_HANDLE: Internals. (line 151)
+* internal function, assoc_clear(): Internals. (line 68)
+* internal function, assoc_lookup(): Internals. (line 72)
+* internal function, dupnode(): Internals. (line 87)
* internal function, force_number(): Internals. (line 27)
* internal function, force_string(): Internals. (line 32)
* internal function, force_wstring(): Internals. (line 37)
-* internal function, get_actual_argument(): Internals. (line 125)
-* internal function, get_argument(): Internals. (line 120)
-* internal function, get_curfunc_arg_count(): Internals. (line 42)
-* internal function, iop_alloc(): Internals. (line 160)
-* internal function, make_builtin(): Internals. (line 106)
-* internal function, make_number(): Internals. (line 91)
-* internal function, make_string(): Internals. (line 86)
-* internal function, register_deferred_variable(): Internals. (line 149)
-* internal function, register_open_hook(): Internals. (line 160)
-* internal function, unref(): Internals. (line 101)
-* internal function, update_ERRNO(): Internals. (line 139)
-* internal function, update_ERRNO_saved(): Internals. (line 144)
-* internal macro, get_array_argument(): Internals. (line 136)
-* internal macro, get_scalar_argument(): Internals. (line 133)
-* internal structure, IOBUF: Internals. (line 160)
+* internal function, get_actual_argument(): Internals. (line 116)
+* internal function, get_argument(): Internals. (line 111)
+* internal function, iop_alloc(): Internals. (line 151)
+* internal function, make_builtin(): Internals. (line 97)
+* internal function, make_number(): Internals. (line 82)
+* internal function, make_string(): Internals. (line 77)
+* internal function, register_deferred_variable(): Internals. (line 140)
+* internal function, register_open_hook(): Internals. (line 151)
+* internal function, unref(): Internals. (line 92)
+* internal function, update_ERRNO(): Internals. (line 130)
+* internal function, update_ERRNO_saved(): Internals. (line 135)
+* internal macro, get_array_argument(): Internals. (line 127)
+* internal macro, get_scalar_argument(): Internals. (line 124)
+* internal structure, IOBUF: Internals. (line 151)
* internal type, AWKNUM: Internals. (line 19)
* internal type, NODE: Internals. (line 23)
-* internal variable, nargs: Internals. (line 49)
-* internal variable, stlen: Internals. (line 53)
-* internal variable, stptr: Internals. (line 53)
-* internal variable, type: Internals. (line 66)
-* internal variable, vname: Internals. (line 71)
-* internal variable, wstlen: Internals. (line 61)
-* internal variable, wstptr: Internals. (line 61)
+* internal variable, nargs: Internals. (line 42)
+* internal variable, stlen: Internals. (line 46)
+* internal variable, stptr: Internals. (line 46)
+* internal variable, type: Internals. (line 59)
+* internal variable, vname: Internals. (line 64)
+* internal variable, wstlen: Internals. (line 54)
+* internal variable, wstptr: Internals. (line 54)
* internationalization <1>: I18N and L10N. (line 6)
* internationalization: I18N Functions. (line 6)
* internationalization, localization <1>: Internationalization.
(line 13)
-* internationalization, localization: User-modified. (line 153)
+* internationalization, localization: User-modified. (line 162)
* internationalization, localization, character classes: Bracket Expressions.
(line 90)
* internationalization, localization, gawk and: Internationalization.
@@ -26314,10 +27287,10 @@ Index
* interpreted programs <1>: Glossary. (line 361)
* interpreted programs: Basic High Level. (line 14)
* interval expressions: Regexp Operators. (line 116)
-* INVALID_HANDLE internal constant: Internals. (line 160)
+* INVALID_HANDLE internal constant: Internals. (line 151)
* inventory-shipped file: Sample Data Files. (line 32)
-* IOBUF internal structure: Internals. (line 160)
-* iop_alloc() internal function: Internals. (line 160)
+* IOBUF internal structure: Internals. (line 151)
+* iop_alloc() internal function: Internals. (line 151)
* isarray() function (gawk): Type Functions. (line 11)
* ISO: Glossary. (line 372)
* ISO 8859-1: Glossary. (line 141)
@@ -26325,9 +27298,9 @@ Index
* Jacobs, Andrew: Passwd Functions. (line 90)
* Jaegermann, Michal <1>: Contributors. (line 46)
* Jaegermann, Michal: Acknowledgments. (line 60)
-* Java implementation of awk: Other Versions. (line 96)
+* Java implementation of awk: Other Versions. (line 97)
* Java programming language: Glossary. (line 380)
-* jawk: Other Versions. (line 96)
+* jawk: Other Versions. (line 97)
* Jedi knights: Undocumented. (line 6)
* join() user-defined function: Join Function. (line 18)
* Kahrs, Ju"rgen <1>: Contributors. (line 70)
@@ -26339,16 +27312,19 @@ Index
* Kernighan, Brian <3>: Contributors. (line 12)
* Kernighan, Brian <4>: BTL. (line 6)
* Kernighan, Brian <5>: Concatenation. (line 6)
-* Kernighan, Brian <6>: Acknowledgments. (line 75)
+* Kernighan, Brian <6>: Acknowledgments. (line 77)
* Kernighan, Brian <7>: Conventions. (line 34)
* Kernighan, Brian: History. (line 17)
-* kill command, dynamic profiling: Profiling. (line 182)
+* kill command, dynamic profiling: Profiling. (line 180)
* Knights, jedi: Undocumented. (line 6)
+* Knuth, Donald: Arbitrary Precision Arithmetic.
+ (line 6)
* Kwok, Conrad: Contributors. (line 35)
-* l debugger command (alias for list): Miscellaneous Dgawk Commands.
+* l debugger command (alias for list): Miscellaneous Debugger Commands.
(line 74)
* labels.awk program: Labels Program. (line 51)
* languages, data-driven: Basic High Level. (line 83)
+* Laurie, Dirk: Changing Precision. (line 6)
* LC_ALL locale category: Explaining gettext. (line 120)
* LC_COLLATE locale category: Explaining gettext. (line 93)
* LC_CTYPE locale category: Explaining gettext. (line 97)
@@ -26371,7 +27347,7 @@ Index
* length() function: String Functions. (line 166)
* Lesser General Public License (LGPL): Glossary. (line 397)
* LGPL (Lesser General Public License): Glossary. (line 397)
-* libmawk: Other Versions. (line 104)
+* libmawk: Other Versions. (line 105)
* libraries of awk functions: Library Functions. (line 6)
* libraries of awk functions, assertions: Assert Function. (line 6)
* libraries of awk functions, associative arrays and: Library Names.
@@ -26409,20 +27385,22 @@ Index
* lint checking, array subscripts: Uninitialized Subscripts.
(line 43)
* lint checking, empty programs: Command Line. (line 16)
-* lint checking, issuing warnings: Options. (line 147)
+* lint checking, issuing warnings: Options. (line 163)
* lint checking, POSIXLY_CORRECT environment variable: Options.
- (line 289)
+ (line 313)
* lint checking, undefined functions: Pass By Value/Reference.
(line 88)
* LINT variable: User-modified. (line 98)
* Linux <1>: Glossary. (line 611)
* Linux <2>: I18N Example. (line 55)
* Linux: Manual History. (line 28)
-* list debugger command: Miscellaneous Dgawk Commands.
+* list debugger command: Miscellaneous Debugger Commands.
(line 74)
+* loading extension: Loading Extensions. (line 6)
+* loading, library: Options. (line 156)
* local variables: Variable Scope. (line 6)
* locale categories: Explaining gettext. (line 80)
-* locale decimal point character: Options. (line 215)
+* locale decimal point character: Options. (line 244)
* locale, definition of: Locales. (line 6)
* localization: I18N and L10N. (line 6)
* localization, See internationalization, localization: I18N and L10N.
@@ -26435,7 +27413,7 @@ Index
* long options: Command Line. (line 13)
* loops: While Statement. (line 6)
* loops, continue statements and: For Statement. (line 64)
-* loops, count for header: Profiling. (line 126)
+* loops, count for header: Profiling. (line 123)
* loops, exiting: Break Statement. (line 6)
* loops, See Also while statement: While Statement. (line 6)
* Lost In Space: Dynamic Extensions. (line 6)
@@ -26444,9 +27422,9 @@ Index
* lvalues/rvalues: Assignment Ops. (line 32)
* mailing labels, printing: Labels Program. (line 6)
* mailing list, GNITS: Acknowledgments. (line 52)
-* make_builtin() internal function: Internals. (line 106)
-* make_number() internal function: Internals. (line 91)
-* make_string() internal function: Internals. (line 86)
+* make_builtin() internal function: Internals. (line 97)
+* make_number() internal function: Internals. (line 82)
+* make_string() internal function: Internals. (line 77)
* mark parity: Ordinal Functions. (line 45)
* marked string extraction (internationalization): String Extraction.
(line 6)
@@ -26461,7 +27439,7 @@ Index
* matching, null strings: Gory Details. (line 164)
* mawk program: Other Versions. (line 35)
* McPhee, Patrick: Contributors. (line 100)
-* memory, releasing: Internals. (line 101)
+* memory, releasing: Internals. (line 92)
* message object files: Explaining gettext. (line 41)
* message object files, converting from portable object files: I18N Example.
(line 62)
@@ -26473,8 +27451,12 @@ Index
* mktime() function (gawk): Time Functions. (line 24)
* modifiers, in format specifiers: Format Modifiers. (line 6)
* monetary information, localization: Explaining gettext. (line 103)
+* MPFR: Arbitrary Precision Arithmetic.
+ (line 6)
* msgfmt utility: I18N Example. (line 62)
-* n debugger command (alias for next): Dgawk Execution Control.
+* multiple precision: Arbitrary Precision Arithmetic.
+ (line 6)
+* n debugger command (alias for next): Debugger Execution Control.
(line 43)
* names, arrays/variables <1>: Library Names. (line 6)
* names, arrays/variables: Arrays. (line 18)
@@ -26483,14 +27465,14 @@ Index
* namespace issues <1>: Library Names. (line 6)
* namespace issues: Arrays. (line 18)
* namespace issues, functions: Definition Syntax. (line 20)
-* nargs internal variable: Internals. (line 49)
+* nargs internal variable: Internals. (line 42)
* nawk utility: Names. (line 17)
* negative zero: Unexpected Results. (line 28)
* NetBSD: Glossary. (line 611)
* networks, programming: TCP/IP Networking. (line 6)
* networks, support for: Special Network. (line 6)
* newlines <1>: Boolean Ops. (line 67)
-* newlines <2>: Options. (line 205)
+* newlines <2>: Options. (line 234)
* newlines: Statements/Lines. (line 6)
* newlines, as field separators: Default Field Splitting.
(line 6)
@@ -26501,7 +27483,7 @@ Index
* newlines, separating statements in actions <1>: Statements. (line 10)
* newlines, separating statements in actions: Action Overview.
(line 19)
-* next debugger command: Dgawk Execution Control.
+* next debugger command: Debugger Execution Control.
(line 43)
* next statement <1>: Next Statement. (line 6)
* next statement: Boolean Ops. (line 85)
@@ -26516,20 +27498,20 @@ Index
(line 26)
* nextfile statement, user-defined functions and: Nextfile Statement.
(line 44)
-* nexti debugger command: Dgawk Execution Control.
+* nexti debugger command: Debugger Execution Control.
(line 49)
* NF variable <1>: Auto-set. (line 107)
* NF variable: Fields. (line 33)
* NF variable, decrementing: Changing Fields. (line 107)
-* ni debugger command (alias for nexti): Dgawk Execution Control.
+* ni debugger command (alias for nexti): Debugger Execution Control.
(line 49)
* noassign.awk program: Ignoring Assigns. (line 15)
* NODE internal type: Internals. (line 23)
-* nodes, duplicating: Internals. (line 96)
+* nodes, duplicating: Internals. (line 87)
* not Boolean-logic operator: Boolean Ops. (line 6)
* NR variable <1>: Auto-set. (line 118)
* NR variable: Records. (line 6)
-* NR variable, changing: Auto-set. (line 207)
+* NR variable, changing: Auto-set. (line 224)
* null strings <1>: Basic Data Typing. (line 50)
* null strings <2>: Truth Values. (line 6)
* null strings <3>: Regexp Field Splitting.
@@ -26546,7 +27528,7 @@ Index
* number sign (#), #! (executable scripts), portability issues with: Executable Scripts.
(line 6)
* number sign (#), commenting: Comments. (line 6)
-* numbers: Internals. (line 91)
+* numbers: Internals. (line 82)
* numbers, as array subscripts: Numeric Array Subscripts.
(line 6)
* numbers, as values of characters: Ordinal Functions. (line 6)
@@ -26566,11 +27548,11 @@ Index
* numeric, output format: OFMT. (line 6)
* numeric, strings: Variable Typing. (line 6)
* numeric, values: Internals. (line 27)
-* o debugger command (alias for option): Dgawk Info. (line 56)
+* o debugger command (alias for option): Debugger Info. (line 57)
* oawk utility: Names. (line 17)
* obsolete features: Obsolete. (line 6)
* octal numbers: Nondecimal-numbers. (line 6)
-* octal values, enabling interpretation of: Options. (line 166)
+* octal values, enabling interpretation of: Options. (line 188)
* OFMT variable <1>: User-modified. (line 115)
* OFMT variable <2>: Conversion. (line 55)
* OFMT variable: OFMT. (line 15)
@@ -26579,7 +27561,7 @@ Index
* OFS variable <2>: Output Separators. (line 6)
* OFS variable: Changing Fields. (line 64)
* OpenBSD: Glossary. (line 611)
-* OpenSolaris: Other Versions. (line 86)
+* OpenSolaris: Other Versions. (line 87)
* operating systems, BSD-based: Manual History. (line 28)
* operating systems, PC, gawk on: PC Using. (line 6)
* operating systems, PC, gawk on, installing: PC Installation.
@@ -26612,7 +27594,7 @@ Index
(line 48)
* operators, word-boundary (gawk): GNU Regexp Operators.
(line 63)
-* option debugger command: Dgawk Info. (line 56)
+* option debugger command: Debugger Info. (line 57)
* options, command-line <1>: Command Line Field Separator.
(line 6)
* options, command-line <2>: Options. (line 6)
@@ -26623,7 +27605,7 @@ Index
* options, deprecated: Obsolete. (line 6)
* options, long <1>: Options. (line 6)
* options, long: Command Line. (line 13)
-* options, printing list of: Options. (line 142)
+* options, printing list of: Options. (line 151)
* OR bitwise operation: Bitwise Functions. (line 6)
* or Boolean-logic operator: Boolean Ops. (line 6)
* or() function (gawk): Bitwise Functions. (line 48)
@@ -26649,15 +27631,15 @@ Index
(line 36)
* P1003.1 POSIX standard: Glossary. (line 454)
* P1003.2 POSIX standard: Glossary. (line 454)
-* parameters, number of: Internals. (line 49)
+* parameters, number of: Internals. (line 42)
+* parentheses () <1>: Profiling. (line 138)
* parentheses (): Regexp Operators. (line 79)
-* parentheses (), pgawk program: Profiling. (line 141)
* password file: Passwd Functions. (line 16)
* patsplit() function: String Functions. (line 293)
* patterns: Patterns and Actions.
(line 6)
* patterns, comparison expressions as: Expression Patterns. (line 14)
-* patterns, counts: Profiling. (line 113)
+* patterns, counts: Profiling. (line 110)
* patterns, default: Very Simple. (line 34)
* patterns, empty: Empty. (line 6)
* patterns, expressions as: Regexp Patterns. (line 6)
@@ -26675,9 +27657,6 @@ Index
* Perl: Future Extensions. (line 6)
* Peters, Arno: Contributors. (line 85)
* Peterson, Hal: Contributors. (line 40)
-* pgawk program: Profiling. (line 6)
-* pgawk program, awkprof.out file: Profiling. (line 10)
-* pgawk program, dynamic profiling: Profiling. (line 174)
* pipes, closing: Close Files And Pipes.
(line 6)
* pipes, input: Getline/Pipe. (line 6)
@@ -26718,13 +27697,13 @@ Index
* portability, NF variable, decrementing: Changing Fields. (line 115)
* portability, operators: Increment Ops. (line 61)
* portability, operators, not in POSIX awk: Precedence. (line 98)
-* portability, POSIXLY_CORRECT environment variable: Options. (line 310)
+* portability, POSIXLY_CORRECT environment variable: Options. (line 334)
* portability, substr() function: String Functions. (line 512)
* portable object files <1>: Translator i18n. (line 6)
* portable object files: Explaining gettext. (line 36)
* portable object files, converting to message object files: I18N Example.
(line 62)
-* portable object files, generating: Options. (line 135)
+* portable object files, generating: Options. (line 144)
* portable object template files: Explaining gettext. (line 30)
* porting gawk: New Ports. (line 6)
* positional specifiers, printf statement <1>: Printf Ordering.
@@ -26768,11 +27747,13 @@ Index
* POSIX awk, regular expressions and: Regexp Operators. (line 161)
* POSIX awk, timestamps and: Time Functions. (line 6)
* POSIX awk, | I/O operator and: Getline/Pipe. (line 52)
-* POSIX mode: Options. (line 199)
+* POSIX mode: Options. (line 228)
* POSIX, awk and: Preface. (line 23)
* POSIX, gawk extensions not included in: POSIX/GNU. (line 6)
* POSIX, programs, implementing in awk: Clones. (line 6)
-* POSIXLY_CORRECT environment variable: Options. (line 289)
+* POSIXLY_CORRECT environment variable: Options. (line 313)
+* PREC variable <1>: Setting Precision. (line 6)
+* PREC variable: User-modified. (line 134)
* precedence <1>: Precedence. (line 6)
* precedence: Increment Ops. (line 61)
* precedence, regexp operators: Regexp Operators. (line 156)
@@ -26806,14 +27787,14 @@ Index
* printf statement, sprintf() function and: Round Function. (line 6)
* printf statement, syntax of: Basic Printf. (line 6)
* printing: Printing. (line 6)
-* printing, list of options: Options. (line 142)
+* printing, list of options: Options. (line 151)
* printing, mailing labels: Labels Program. (line 6)
* printing, unduplicated lines of text: Uniq Program. (line 6)
* printing, user information: Id Program. (line 6)
* private variables: Library Names. (line 11)
* processes, two-way communications with: Two-way I/O. (line 23)
* processing data: Basic High Level. (line 6)
-* PROCINFO array <1>: Internals. (line 149)
+* PROCINFO array <1>: Internals. (line 140)
* PROCINFO array <2>: Id Program. (line 15)
* PROCINFO array <3>: Group Functions. (line 6)
* PROCINFO array <4>: Passwd Functions. (line 6)
@@ -26822,8 +27803,8 @@ Index
* PROCINFO array <7>: Auto-set. (line 123)
* PROCINFO array: Obsolete. (line 11)
* profiling awk programs: Profiling. (line 6)
-* profiling awk programs, dynamically: Profiling. (line 174)
-* profiling gawk, See pgawk program: Profiling. (line 6)
+* profiling awk programs, dynamically: Profiling. (line 171)
+* profiling gawk: Profiling. (line 6)
* program, definition of: Getting Started. (line 21)
* programmers, attractiveness of: Two-way I/O. (line 6)
* programming conventions, --non-decimal-data option: Nondecimal Data.
@@ -26847,23 +27828,23 @@ Index
* programming, basic steps: Basic High Level. (line 19)
* programming, concepts: Basic Concepts. (line 6)
* pwcat program: Passwd Functions. (line 23)
-* q debugger command (alias for quit): Miscellaneous Dgawk Commands.
+* q debugger command (alias for quit): Miscellaneous Debugger Commands.
(line 101)
-* QSE Awk: Other Versions. (line 108)
+* QSE Awk: Other Versions. (line 109)
* question mark (?) regexp operator <1>: GNU Regexp Operators.
(line 59)
* question mark (?) regexp operator: Regexp Operators. (line 111)
* question mark (?), ?: operator: Precedence. (line 92)
-* QuikTrim Awk: Other Versions. (line 112)
-* quit debugger command: Miscellaneous Dgawk Commands.
+* QuikTrim Awk: Other Versions. (line 113)
+* quit debugger command: Miscellaneous Debugger Commands.
(line 101)
-* QUIT signal (MS-Windows): Profiling. (line 207)
+* QUIT signal (MS-Windows): Profiling. (line 206)
* quoting <1>: Comments. (line 27)
* quoting <2>: Long. (line 26)
* quoting: Read Terminal. (line 25)
* quoting, rules for: Quoting. (line 6)
* quoting, tricks for: Quoting. (line 71)
-* r debugger command (alias for run): Dgawk Execution Control.
+* r debugger command (alias for run): Debugger Execution Control.
(line 62)
* Rakitzis, Byron: History Sorting. (line 25)
* rand() function: Numeric Functions. (line 34)
@@ -26881,7 +27862,7 @@ Index
* readable data files, checking: File Checking. (line 6)
* readable.awk program: File Checking. (line 11)
* recipe for a programming language: History. (line 6)
-* record separators <1>: User-modified. (line 134)
+* record separators <1>: User-modified. (line 143)
* record separators: Records. (line 14)
* record separators, changing: Records. (line 81)
* record separators, regular expressions as: Records. (line 112)
@@ -26909,8 +27890,8 @@ Index
* regexp constants, slashes vs. quotes: Computed Regexps. (line 28)
* regexp constants, vs. string constants: Computed Regexps. (line 38)
* regexp, See regular expressions: Regexp. (line 6)
-* register_deferred_variable() internal function: Internals. (line 149)
-* register_open_hook() internal function: Internals. (line 160)
+* register_deferred_variable() internal function: Internals. (line 140)
+* register_open_hook() internal function: Internals. (line 151)
* regular expressions: Regexp. (line 6)
* regular expressions as field separators: Field Separators. (line 50)
* regular expressions, anchors in: Regexp Operators. (line 22)
@@ -26929,7 +27910,7 @@ Index
(line 59)
* regular expressions, gawk, command-line options: GNU Regexp Operators.
(line 70)
-* regular expressions, interval expressions and: Options. (line 224)
+* regular expressions, interval expressions and: Options. (line 253)
* regular expressions, leftmost longest match: Leftmost Longest.
(line 6)
* regular expressions, operators <1>: Regexp Operators. (line 6)
@@ -26945,7 +27926,7 @@ Index
* regular expressions, searching for: Egrep Program. (line 6)
* relational operators, See comparison operators: Typing and Comparison.
(line 9)
-* return debugger command: Dgawk Execution Control.
+* return debugger command: Debugger Execution Control.
(line 54)
* return statement, user-defined functions: Return Statement. (line 6)
* return values, close() function: Close Files And Pipes.
@@ -26963,7 +27944,7 @@ Index
* right angle bracket (>), >> operator (I/O): Redirection. (line 50)
* right shift, bitwise: Bitwise Functions. (line 32)
* Ritchie, Dennis: Basic Data Typing. (line 74)
-* RLENGTH variable: Auto-set. (line 183)
+* RLENGTH variable: Auto-set. (line 200)
* RLENGTH variable, match() function and: String Functions. (line 223)
* Robbins, Arnold <1>: Future Extensions. (line 6)
* Robbins, Arnold <2>: Bugs. (line 32)
@@ -26974,23 +27955,27 @@ Index
* Robbins, Arnold: Command Line Field Separator.
(line 80)
* Robbins, Bill: Getline/Pipe. (line 36)
-* Robbins, Harry: Acknowledgments. (line 81)
-* Robbins, Jean: Acknowledgments. (line 81)
+* Robbins, Harry: Acknowledgments. (line 83)
+* Robbins, Jean: Acknowledgments. (line 83)
* Robbins, Miriam <1>: Passwd Functions. (line 90)
* Robbins, Miriam <2>: Getline/Pipe. (line 36)
-* Robbins, Miriam: Acknowledgments. (line 81)
+* Robbins, Miriam: Acknowledgments. (line 83)
* Robinson, Will: Dynamic Extensions. (line 6)
* robot, the: Dynamic Extensions. (line 6)
* Rommel, Kai Uwe: Contributors. (line 43)
* round() user-defined function: Round Function. (line 16)
+* rounding mode, floating-point: Rounding Mode. (line 6)
* rounding numbers: Round Function. (line 6)
-* RS variable <1>: User-modified. (line 134)
+* ROUNDMODE variable <1>: Setting Rounding Mode.
+ (line 6)
+* ROUNDMODE variable: User-modified. (line 138)
+* RS variable <1>: User-modified. (line 143)
* RS variable: Records. (line 20)
* RS variable, multiline records and: Multiple Line. (line 17)
* rshift() function (gawk): Bitwise Functions. (line 51)
-* RSTART variable: Auto-set. (line 189)
+* RSTART variable: Auto-set. (line 206)
* RSTART variable, match() function and: String Functions. (line 223)
-* RT variable <1>: Auto-set. (line 196)
+* RT variable <1>: Auto-set. (line 213)
* RT variable <2>: Getline/Variable/File.
(line 10)
* RT variable <3>: Multiple Line. (line 129)
@@ -26998,12 +27983,12 @@ Index
* Rubin, Paul <1>: Contributors. (line 16)
* Rubin, Paul: History. (line 30)
* rule, definition of: Getting Started. (line 21)
-* run debugger command: Dgawk Execution Control.
+* run debugger command: Debugger Execution Control.
(line 62)
* rvalues/lvalues: Assignment Ops. (line 32)
-* s debugger command (alias for step): Dgawk Execution Control.
+* s debugger command (alias for step): Debugger Execution Control.
(line 68)
-* sandbox mode: Options. (line 236)
+* sandbox mode: Options. (line 260)
* scalar values: Basic Data Typing. (line 13)
* Schorr, Andrew: Acknowledgments. (line 60)
* Schreiber, Bert: Acknowledgments. (line 38)
@@ -27033,11 +28018,11 @@ Index
* separators, field, FIELDWIDTHS variable and: User-modified. (line 35)
* separators, field, FPAT variable and: User-modified. (line 45)
* separators, field, POSIX and: Fields. (line 6)
-* separators, for records <1>: User-modified. (line 134)
+* separators, for records <1>: User-modified. (line 143)
* separators, for records: Records. (line 14)
* separators, for records, regular expressions as: Records. (line 112)
* separators, for statements in actions: Action Overview. (line 19)
-* separators, subscript: User-modified. (line 147)
+* separators, subscript: User-modified. (line 156)
* set debugger command: Viewing And Changing Data.
(line 59)
* shells, piping commands into: Redirection. (line 143)
@@ -27049,7 +28034,7 @@ Index
(line 6)
* shift, bitwise: Bitwise Functions. (line 32)
* short-circuit operators: Boolean Ops. (line 57)
-* si debugger command (alias for stepi): Dgawk Execution Control.
+* si debugger command (alias for stepi): Debugger Execution Control.
(line 76)
* side effects <1>: Increment Ops. (line 11)
* side effects: Concatenation. (line 42)
@@ -27064,15 +28049,15 @@ Index
* side effects, FILENAME variable: Getline Notes. (line 19)
* side effects, function calls: Function Calls. (line 54)
* side effects, statements: Action Overview. (line 32)
-* SIGHUP signal: Profiling. (line 204)
-* SIGINT signal (MS-Windows): Profiling. (line 207)
-* signals, HUP/SIGHUP: Profiling. (line 204)
-* signals, INT/SIGINT (MS-Windows): Profiling. (line 207)
-* signals, QUIT/SIGQUIT (MS-Windows): Profiling. (line 207)
-* signals, USR1/SIGUSR1: Profiling. (line 182)
-* SIGQUIT signal (MS-Windows): Profiling. (line 207)
-* SIGUSR1 signal: Profiling. (line 182)
-* silent debugger command: Dgawk Execution Control.
+* SIGHUP signal: Profiling. (line 203)
+* SIGINT signal (MS-Windows): Profiling. (line 206)
+* signals, HUP/SIGHUP: Profiling. (line 203)
+* signals, INT/SIGINT (MS-Windows): Profiling. (line 206)
+* signals, QUIT/SIGQUIT (MS-Windows): Profiling. (line 206)
+* signals, USR1/SIGUSR1: Profiling. (line 180)
+* SIGQUIT signal (MS-Windows): Profiling. (line 206)
+* SIGUSR1 signal: Profiling. (line 180)
+* silent debugger command: Debugger Execution Control.
(line 10)
* sin() function: Numeric Functions. (line 75)
* single precision floating-point: Basic Data Typing. (line 36)
@@ -27085,7 +28070,7 @@ Index
(line 6)
* Skywalker, Luke: Undocumented. (line 6)
* sleep utility: Alarm Program. (line 109)
-* Solaris, POSIX-compliant awk: Other Versions. (line 86)
+* Solaris, POSIX-compliant awk: Other Versions. (line 87)
* sort function, arrays, sorting: Array Sorting Functions.
(line 6)
* sort utility: Word Sorting. (line 50)
@@ -27094,17 +28079,17 @@ Index
(line 93)
* source code, awka: Other Versions. (line 55)
* source code, Brian Kernighan's awk: Other Versions. (line 13)
-* source code, Busybox Awk: Other Versions. (line 78)
+* source code, Busybox Awk: Other Versions. (line 79)
* source code, gawk: Gawk Distribution. (line 6)
-* source code, jawk: Other Versions. (line 96)
-* source code, libmawk: Other Versions. (line 104)
+* source code, jawk: Other Versions. (line 97)
+* source code, libmawk: Other Versions. (line 105)
* source code, mawk: Other Versions. (line 35)
-* source code, mixing: Options. (line 105)
+* source code, mixing: Options. (line 114)
* source code, pawk: Other Versions. (line 69)
-* source code, QSE Awk: Other Versions. (line 108)
-* source code, QuikTrim Awk: Other Versions. (line 112)
-* source code, Solaris awk: Other Versions. (line 86)
-* source code, xgawk: Other Versions. (line 119)
+* source code, QSE Awk: Other Versions. (line 109)
+* source code, QuikTrim Awk: Other Versions. (line 113)
+* source code, Solaris awk: Other Versions. (line 87)
+* source code, xgawk: Other Versions. (line 120)
* source files, search path for: Igawk Program. (line 368)
* sparse arrays: Array Intro. (line 71)
* Spencer, Henry: Glossary. (line 12)
@@ -27132,12 +28117,12 @@ Index
* statements, compound, control statements and: Statements. (line 10)
* statements, control, in actions: Statements. (line 6)
* statements, multiple: Statements/Lines. (line 91)
-* step debugger command: Dgawk Execution Control.
+* step debugger command: Debugger Execution Control.
(line 68)
-* stepi debugger command: Dgawk Execution Control.
+* stepi debugger command: Debugger Execution Control.
(line 76)
-* stlen internal variable: Internals. (line 53)
-* stptr internal variable: Internals. (line 53)
+* stlen internal variable: Internals. (line 46)
+* stptr internal variable: Internals. (line 46)
* stream editors <1>: Simple Sed. (line 6)
* stream editors: Field Splitting Summary.
(line 47)
@@ -27148,7 +28133,7 @@ Index
(line 6)
* string operators: Concatenation. (line 9)
* string-matching operators: Regexp Usage. (line 19)
-* strings: Internals. (line 86)
+* strings: Internals. (line 77)
* strings, converting <1>: Bitwise Functions. (line 107)
* strings, converting: Conversion. (line 6)
* strings, converting, numbers to: User-modified. (line 28)
@@ -27170,7 +28155,7 @@ Index
(line 43)
* sub() function, arguments of: String Functions. (line 462)
* sub() function, escape processing: Gory Details. (line 6)
-* subscript separators: User-modified. (line 147)
+* subscript separators: User-modified. (line 156)
* subscripts in arrays, multidimensional: Multi-dimensional. (line 10)
* subscripts in arrays, multidimensional, scanning: Multi-scanning.
(line 11)
@@ -27178,7 +28163,7 @@ Index
(line 6)
* subscripts in arrays, uninitialized variables as: Uninitialized Subscripts.
(line 6)
-* SUBSEP variable: User-modified. (line 147)
+* SUBSEP variable: User-modified. (line 156)
* SUBSEP variable, multidimensional arrays: Multi-dimensional.
(line 16)
* substr() function: String Functions. (line 481)
@@ -27188,8 +28173,8 @@ Index
(line 148)
* system() function: I/O Functions. (line 63)
* systime() function (gawk): Time Functions. (line 64)
-* t debugger command (alias for tbreak): Breakpoint Control. (line 89)
-* tbreak debugger command: Breakpoint Control. (line 89)
+* t debugger command (alias for tbreak): Breakpoint Control. (line 90)
+* tbreak debugger command: Breakpoint Control. (line 90)
* Tcl: Library Names. (line 57)
* TCP/IP: TCP/IP Networking. (line 6)
* TCP/IP, support for: Special Network. (line 6)
@@ -27211,7 +28196,7 @@ Index
* text, printing: Print. (line 22)
* text, printing, unduplicated lines of: Uniq Program. (line 6)
* TEXTDOMAIN variable <1>: Programmer i18n. (line 9)
-* TEXTDOMAIN variable: User-modified. (line 153)
+* TEXTDOMAIN variable: User-modified. (line 162)
* TEXTDOMAIN variable, BEGIN pattern and: Programmer i18n. (line 60)
* TEXTDOMAIN variable, portability and: I18N Portability. (line 20)
* textdomain() function (C library): Explaining gettext. (line 27)
@@ -27228,6 +28213,7 @@ Index
* time, managing: Gettimeofday Function.
(line 6)
* time, retrieving: Time Functions. (line 17)
+* timeout, reading input: Read Timeout. (line 6)
* timestamps: Time Functions. (line 6)
* timestamps, converting dates to: Time Functions. (line 74)
* timestamps, formatted: Gettimeofday Function.
@@ -27235,10 +28221,10 @@ Index
* tolower() function: String Functions. (line 523)
* toupper() function: String Functions. (line 529)
* tr utility: Translate Program. (line 6)
-* trace debugger command: Miscellaneous Dgawk Commands.
+* trace debugger command: Miscellaneous Debugger Commands.
(line 110)
* translate.awk program: Translate Program. (line 55)
-* troubleshooting, --non-decimal-data option: Options. (line 166)
+* troubleshooting, --non-decimal-data option: Options. (line 188)
* troubleshooting, == operator: Comparison Operators.
(line 37)
* troubleshooting, awk uses FS not IFS: Field Separators. (line 29)
@@ -27278,8 +28264,8 @@ Index
* trunc-mod operation: Arithmetic Ops. (line 66)
* truth values: Truth Values. (line 6)
* type conversion: Conversion. (line 21)
-* type internal variable: Internals. (line 66)
-* u debugger command (alias for until): Dgawk Execution Control.
+* type internal variable: Internals. (line 59)
+* u debugger command (alias for until): Debugger Execution Control.
(line 83)
* undefined functions: Pass By Value/Reference.
(line 71)
@@ -27304,23 +28290,23 @@ Index
(line 72)
* Unix, awk scripts and: Executable Scripts. (line 6)
* UNIXROOT variable, on OS/2 systems: PC Using. (line 17)
-* unref() internal function: Internals. (line 101)
+* unref() internal function: Internals. (line 92)
* unsigned integers: Basic Data Typing. (line 30)
-* until debugger command: Dgawk Execution Control.
+* until debugger command: Debugger Execution Control.
(line 83)
* unwatch debugger command: Viewing And Changing Data.
(line 84)
-* up debugger command: Dgawk Stack. (line 33)
-* update_ERRNO() internal function: Internals. (line 139)
-* update_ERRNO_saved() internal function: Internals. (line 144)
+* up debugger command: Execution Stack. (line 33)
+* update_ERRNO() internal function: Internals. (line 130)
+* update_ERRNO_saved() internal function: Internals. (line 135)
* user database, reading: Passwd Functions. (line 6)
* user-defined, functions: User-defined. (line 6)
-* user-defined, functions, counts: Profiling. (line 132)
+* user-defined, functions, counts: Profiling. (line 129)
* user-defined, variables: Variables. (line 6)
* user-modifiable variables: User-modified. (line 6)
* users, information about, printing: Id Program. (line 6)
* users, information about, retrieving: Passwd Functions. (line 16)
-* USR1 signal: Profiling. (line 182)
+* USR1 signal: Profiling. (line 180)
* values, numeric: Basic Data Typing. (line 13)
* values, string: Basic Data Typing. (line 13)
* variable typing: Typing and Comparison.
@@ -27363,7 +28349,7 @@ Index
* vertical bar (|), || operator <1>: Precedence. (line 89)
* vertical bar (|), || operator: Boolean Ops. (line 57)
* Vinschen, Corinna: Acknowledgments. (line 60)
-* vname internal variable: Internals. (line 71)
+* vname internal variable: Internals. (line 64)
* w debugger command (alias for watch): Viewing And Changing Data.
(line 67)
* w utility: Constant Size. (line 22)
@@ -27371,7 +28357,7 @@ Index
* Wall, Larry <1>: Future Extensions. (line 6)
* Wall, Larry: Array Intro. (line 6)
* Wallin, Anders: Acknowledgments. (line 60)
-* warnings, issuing: Options. (line 147)
+* warnings, issuing: Options. (line 163)
* watch debugger command: Viewing And Changing Data.
(line 67)
* wc utility: Wc Program. (line 6)
@@ -27383,7 +28369,7 @@ Index
* whitespace, as field separators: Default Field Splitting.
(line 6)
* whitespace, functions, calling: Calling Built-in. (line 10)
-* whitespace, newlines as: Options. (line 205)
+* whitespace, newlines as: Options. (line 234)
* Williams, Kent: Contributors. (line 35)
* Woehlke, Matthew: Contributors. (line 79)
* Woods, John: Contributors. (line 28)
@@ -27397,11 +28383,11 @@ Index
* words, counting: Wc Program. (line 6)
* words, duplicate, searching for: Dupword Program. (line 6)
* words, usage counts, generating: Word Sorting. (line 6)
-* wstlen internal variable: Internals. (line 61)
-* wstptr internal variable: Internals. (line 61)
-* xgawk: Other Versions. (line 119)
+* wstlen internal variable: Internals. (line 54)
+* wstptr internal variable: Internals. (line 54)
+* xgawk: Other Versions. (line 120)
* xgettext utility: String Extraction. (line 13)
-* XML (eXtensible Markup Language): Internals. (line 160)
+* XML (eXtensible Markup Language): Internals. (line 151)
* XOR bitwise operation: Bitwise Functions. (line 6)
* xor() function (gawk): Bitwise Functions. (line 54)
* Yawitz, Efraim: Contributors. (line 106)
@@ -27411,8 +28397,8 @@ Index
* zero, negative vs. positive: Unexpected Results. (line 28)
* zerofile.awk program: Empty Files. (line 21)
* Zoulas, Christos: Contributors. (line 67)
+* {} (braces): Profiling. (line 134)
* {} (braces), actions and: Action Overview. (line 19)
-* {} (braces), pgawk program: Profiling. (line 137)
* {} (braces), statements, grouping: Statements. (line 10)
* | (vertical bar): Regexp Operators. (line 69)
* | (vertical bar), | operator (I/O) <1>: Precedence. (line 65)
@@ -27439,416 +28425,440 @@ Index

Tag Table:
Node: Top1352
-Node: Foreword30282
-Node: Preface34627
-Ref: Preface-Footnote-137680
-Ref: Preface-Footnote-237786
-Node: History38018
-Node: Names40409
-Ref: Names-Footnote-141886
-Node: This Manual41958
-Ref: This Manual-Footnote-146905
-Node: Conventions47005
-Node: Manual History49139
-Ref: Manual History-Footnote-152409
-Ref: Manual History-Footnote-252450
-Node: How To Contribute52524
-Node: Acknowledgments53668
-Node: Getting Started57999
-Node: Running gawk60378
-Node: One-shot61564
-Node: Read Terminal62789
-Ref: Read Terminal-Footnote-164439
-Ref: Read Terminal-Footnote-264715
-Node: Long64886
-Node: Executable Scripts66262
-Ref: Executable Scripts-Footnote-168131
-Ref: Executable Scripts-Footnote-268233
-Node: Comments68780
-Node: Quoting71247
-Node: DOS Quoting75870
-Node: Sample Data Files76545
-Node: Very Simple79577
-Node: Two Rules84176
-Node: More Complex86323
-Ref: More Complex-Footnote-189253
-Node: Statements/Lines89338
-Ref: Statements/Lines-Footnote-193800
-Node: Other Features94065
-Node: When94993
-Node: Invoking Gawk97140
-Node: Command Line98525
-Node: Options99308
-Ref: Options-Footnote-1112745
-Node: Other Arguments112770
-Node: Naming Standard Input115428
-Node: Environment Variables116522
-Node: AWKPATH Variable116966
-Ref: AWKPATH Variable-Footnote-1119563
-Node: Other Environment Variables119823
-Node: Exit Status122163
-Node: Include Files122838
-Node: Obsolete126323
-Node: Undocumented127009
-Node: Regexp127250
-Node: Regexp Usage128639
-Node: Escape Sequences130665
-Node: Regexp Operators136428
-Ref: Regexp Operators-Footnote-1143808
-Ref: Regexp Operators-Footnote-2143955
-Node: Bracket Expressions144053
-Ref: table-char-classes145943
-Node: GNU Regexp Operators148466
-Node: Case-sensitivity152189
-Ref: Case-sensitivity-Footnote-1155157
-Ref: Case-sensitivity-Footnote-2155392
-Node: Leftmost Longest155500
-Node: Computed Regexps156701
-Node: Reading Files160111
-Node: Records162052
-Ref: Records-Footnote-1170726
-Node: Fields170763
-Ref: Fields-Footnote-1173796
-Node: Nonconstant Fields173882
-Node: Changing Fields176084
-Node: Field Separators182065
-Node: Default Field Splitting184694
-Node: Regexp Field Splitting185811
-Node: Single Character Fields189153
-Node: Command Line Field Separator190212
-Node: Field Splitting Summary193653
-Ref: Field Splitting Summary-Footnote-1196845
-Node: Constant Size196946
-Node: Splitting By Content201530
-Ref: Splitting By Content-Footnote-1205256
-Node: Multiple Line205296
-Ref: Multiple Line-Footnote-1211143
-Node: Getline211322
-Node: Plain Getline213550
-Node: Getline/Variable215639
-Node: Getline/File216780
-Node: Getline/Variable/File218102
-Ref: Getline/Variable/File-Footnote-1219701
-Node: Getline/Pipe219788
-Node: Getline/Variable/Pipe222348
-Node: Getline/Coprocess223455
-Node: Getline/Variable/Coprocess224698
-Node: Getline Notes225412
-Node: Getline Summary227354
-Ref: table-getline-variants227697
-Node: Command line directories228553
-Node: Printing229178
-Node: Print230809
-Node: Print Examples232146
-Node: Output Separators234930
-Node: OFMT236690
-Node: Printf238048
-Node: Basic Printf238954
-Node: Control Letters240493
-Node: Format Modifiers244305
-Node: Printf Examples250314
-Node: Redirection253029
-Node: Special Files260013
-Node: Special FD260546
-Ref: Special FD-Footnote-1264171
-Node: Special Network264245
-Node: Special Caveats265095
-Node: Close Files And Pipes265891
-Ref: Close Files And Pipes-Footnote-1272914
-Ref: Close Files And Pipes-Footnote-2273062
-Node: Expressions273212
-Node: Values274344
-Node: Constants275020
-Node: Scalar Constants275700
-Ref: Scalar Constants-Footnote-1276559
-Node: Nondecimal-numbers276741
-Node: Regexp Constants279800
-Node: Using Constant Regexps280275
-Node: Variables283330
-Node: Using Variables283985
-Node: Assignment Options285709
-Node: Conversion287581
-Ref: table-locale-affects292957
-Ref: Conversion-Footnote-1293581
-Node: All Operators293690
-Node: Arithmetic Ops294320
-Node: Concatenation296825
-Ref: Concatenation-Footnote-1299618
-Node: Assignment Ops299738
-Ref: table-assign-ops304726
-Node: Increment Ops306134
-Node: Truth Values and Conditions309604
-Node: Truth Values310687
-Node: Typing and Comparison311736
-Node: Variable Typing312525
-Ref: Variable Typing-Footnote-1316422
-Node: Comparison Operators316544
-Ref: table-relational-ops316954
-Node: POSIX String Comparison320503
-Ref: POSIX String Comparison-Footnote-1321459
-Node: Boolean Ops321597
-Ref: Boolean Ops-Footnote-1325675
-Node: Conditional Exp325766
-Node: Function Calls327498
-Node: Precedence331092
-Node: Locales334761
-Node: Patterns and Actions335850
-Node: Pattern Overview336904
-Node: Regexp Patterns338573
-Node: Expression Patterns339116
-Node: Ranges342801
-Node: BEGIN/END345767
-Node: Using BEGIN/END346529
-Ref: Using BEGIN/END-Footnote-1349260
-Node: I/O And BEGIN/END349366
-Node: BEGINFILE/ENDFILE351648
-Node: Empty354541
-Node: Using Shell Variables354857
-Node: Action Overview357142
-Node: Statements359499
-Node: If Statement361353
-Node: While Statement362852
-Node: Do Statement364896
-Node: For Statement366052
-Node: Switch Statement369204
-Node: Break Statement371301
-Node: Continue Statement373291
-Node: Next Statement375084
-Node: Nextfile Statement377474
-Node: Exit Statement380019
-Node: Built-in Variables382435
-Node: User-modified383530
-Ref: User-modified-Footnote-1391556
-Node: Auto-set391618
-Ref: Auto-set-Footnote-1400909
-Node: ARGC and ARGV401114
-Node: Arrays404965
-Node: Array Basics406470
-Node: Array Intro407296
-Node: Reference to Elements411614
-Node: Assigning Elements413884
-Node: Array Example414375
-Node: Scanning an Array416107
-Node: Controlling Scanning418421
-Ref: Controlling Scanning-Footnote-1423354
-Node: Delete423670
-Ref: Delete-Footnote-1426105
-Node: Numeric Array Subscripts426162
-Node: Uninitialized Subscripts428345
-Node: Multi-dimensional429973
-Node: Multi-scanning433067
-Node: Arrays of Arrays434658
-Node: Functions439303
-Node: Built-in440125
-Node: Calling Built-in441203
-Node: Numeric Functions443191
-Ref: Numeric Functions-Footnote-1447023
-Ref: Numeric Functions-Footnote-2447380
-Ref: Numeric Functions-Footnote-3447428
-Node: String Functions447697
-Ref: String Functions-Footnote-1471194
-Ref: String Functions-Footnote-2471323
-Ref: String Functions-Footnote-3471571
-Node: Gory Details471658
-Ref: table-sub-escapes473337
-Ref: table-sub-posix-92474691
-Ref: table-sub-proposed476034
-Ref: table-posix-sub477384
-Ref: table-gensub-escapes478930
-Ref: Gory Details-Footnote-1480137
-Ref: Gory Details-Footnote-2480188
-Node: I/O Functions480339
-Ref: I/O Functions-Footnote-1486994
-Node: Time Functions487141
-Ref: Time Functions-Footnote-1498033
-Ref: Time Functions-Footnote-2498101
-Ref: Time Functions-Footnote-3498259
-Ref: Time Functions-Footnote-4498370
-Ref: Time Functions-Footnote-5498482
-Ref: Time Functions-Footnote-6498709
-Node: Bitwise Functions498975
-Ref: table-bitwise-ops499533
-Ref: Bitwise Functions-Footnote-1503693
-Node: Type Functions503877
-Node: I18N Functions504347
-Node: User-defined505974
-Node: Definition Syntax506778
-Ref: Definition Syntax-Footnote-1511688
-Node: Function Example511757
-Node: Function Caveats514351
-Node: Calling A Function514772
-Node: Variable Scope515887
-Node: Pass By Value/Reference517862
-Node: Return Statement521302
-Node: Dynamic Typing524283
-Node: Indirect Calls525018
-Node: Internationalization534703
-Node: I18N and L10N536129
-Node: Explaining gettext536815
-Ref: Explaining gettext-Footnote-1541881
-Ref: Explaining gettext-Footnote-2542065
-Node: Programmer i18n542230
-Node: Translator i18n546430
-Node: String Extraction547223
-Ref: String Extraction-Footnote-1548184
-Node: Printf Ordering548270
-Ref: Printf Ordering-Footnote-1551054
-Node: I18N Portability551118
-Ref: I18N Portability-Footnote-1553567
-Node: I18N Example553630
-Ref: I18N Example-Footnote-1556265
-Node: Gawk I18N556337
-Node: Advanced Features556954
-Node: Nondecimal Data558467
-Node: Array Sorting560050
-Node: Controlling Array Traversal560747
-Node: Array Sorting Functions568984
-Ref: Array Sorting Functions-Footnote-1572658
-Ref: Array Sorting Functions-Footnote-2572751
-Node: Two-way I/O572945
-Ref: Two-way I/O-Footnote-1578377
-Node: TCP/IP Networking578447
-Node: Profiling581291
-Node: Library Functions588765
-Ref: Library Functions-Footnote-1591772
-Node: Library Names591943
-Ref: Library Names-Footnote-1595414
-Ref: Library Names-Footnote-2595634
-Node: General Functions595720
-Node: Strtonum Function596673
-Node: Assert Function599603
-Node: Round Function602929
-Node: Cliff Random Function604472
-Node: Ordinal Functions605488
-Ref: Ordinal Functions-Footnote-1608558
-Ref: Ordinal Functions-Footnote-2608810
-Node: Join Function609019
-Ref: Join Function-Footnote-1610790
-Node: Gettimeofday Function610990
-Node: Data File Management614705
-Node: Filetrans Function615337
-Node: Rewind Function619476
-Node: File Checking620863
-Node: Empty Files621957
-Node: Ignoring Assigns624187
-Node: Getopt Function625740
-Ref: Getopt Function-Footnote-1637044
-Node: Passwd Functions637247
-Ref: Passwd Functions-Footnote-1646222
-Node: Group Functions646310
-Node: Walking Arrays654394
-Node: Sample Programs655963
-Node: Running Examples656628
-Node: Clones657356
-Node: Cut Program658580
-Node: Egrep Program668425
-Ref: Egrep Program-Footnote-1676198
-Node: Id Program676308
-Node: Split Program679924
-Ref: Split Program-Footnote-1683443
-Node: Tee Program683571
-Node: Uniq Program686374
-Node: Wc Program693803
-Ref: Wc Program-Footnote-1698069
-Ref: Wc Program-Footnote-2698269
-Node: Miscellaneous Programs698361
-Node: Dupword Program699549
-Node: Alarm Program701580
-Node: Translate Program706329
-Ref: Translate Program-Footnote-1710716
-Ref: Translate Program-Footnote-2710944
-Node: Labels Program711078
-Ref: Labels Program-Footnote-1714449
-Node: Word Sorting714533
-Node: History Sorting718417
-Node: Extract Program720256
-Ref: Extract Program-Footnote-1727739
-Node: Simple Sed727867
-Node: Igawk Program730929
-Ref: Igawk Program-Footnote-1746086
-Ref: Igawk Program-Footnote-2746287
-Node: Anagram Program746425
-Node: Signature Program749493
-Node: Debugger750593
-Node: Debugging751504
-Node: Debugging Concepts751917
-Node: Debugging Terms753773
-Node: Awk Debugging756396
-Node: Sample dgawk session757288
-Node: dgawk invocation757780
-Node: Finding The Bug758962
-Node: List of Debugger Commands765448
-Node: Breakpoint Control766759
-Node: Dgawk Execution Control770395
-Node: Viewing And Changing Data773746
-Node: Dgawk Stack777083
-Node: Dgawk Info778543
-Node: Miscellaneous Dgawk Commands782491
-Node: Readline Support787919
-Node: Dgawk Limitations788757
-Node: Language History790946
-Node: V7/SVR3.1792458
-Node: SVR4794779
-Node: POSIX796221
-Node: BTL797229
-Node: POSIX/GNU797963
-Node: Common Extensions803114
-Node: Ranges and Locales804221
-Ref: Ranges and Locales-Footnote-1808825
-Node: Contributors809046
-Node: Installation813308
-Node: Gawk Distribution814202
-Node: Getting814686
-Node: Extracting815512
-Node: Distribution contents817204
-Node: Unix Installation822426
-Node: Quick Installation823043
-Node: Additional Configuration Options825005
-Node: Configuration Philosophy826482
-Node: Non-Unix Installation828824
-Node: PC Installation829282
-Node: PC Binary Installation830581
-Node: PC Compiling832429
-Node: PC Testing835373
-Node: PC Using836549
-Node: Cygwin840734
-Node: MSYS841734
-Node: VMS Installation842248
-Node: VMS Compilation842851
-Ref: VMS Compilation-Footnote-1843858
-Node: VMS Installation Details843916
-Node: VMS Running845551
-Node: VMS Old Gawk847158
-Node: Bugs847632
-Node: Other Versions851484
-Node: Notes856765
-Node: Compatibility Mode857457
-Node: Additions858240
-Node: Accessing The Source859052
-Node: Adding Code860477
-Node: New Ports866444
-Node: Dynamic Extensions870557
-Node: Internals871933
-Node: Plugin License881036
-Node: Sample Library881670
-Node: Internal File Description882356
-Node: Internal File Ops886071
-Ref: Internal File Ops-Footnote-1890852
-Node: Using Internal File Ops890992
-Node: Future Extensions893369
-Node: Basic Concepts895873
-Node: Basic High Level896630
-Ref: Basic High Level-Footnote-1900665
-Node: Basic Data Typing900850
-Node: Floating Point Issues905375
-Node: String Conversion Precision906458
-Ref: String Conversion Precision-Footnote-1908158
-Node: Unexpected Results908267
-Node: POSIX Floating Point Problems910093
-Ref: POSIX Floating Point Problems-Footnote-1913798
-Node: Glossary913836
-Node: Copying938812
-Node: GNU Free Documentation License976369
-Node: Index1001506
+Node: Foreword31559
+Node: Preface35904
+Ref: Preface-Footnote-138957
+Ref: Preface-Footnote-239063
+Node: History39295
+Node: Names41686
+Ref: Names-Footnote-143163
+Node: This Manual43235
+Ref: This Manual-Footnote-148173
+Node: Conventions48273
+Node: Manual History50407
+Ref: Manual History-Footnote-153677
+Ref: Manual History-Footnote-253718
+Node: How To Contribute53792
+Node: Acknowledgments54936
+Node: Getting Started59432
+Node: Running gawk61811
+Node: One-shot62997
+Node: Read Terminal64222
+Ref: Read Terminal-Footnote-165872
+Ref: Read Terminal-Footnote-266148
+Node: Long66319
+Node: Executable Scripts67695
+Ref: Executable Scripts-Footnote-169564
+Ref: Executable Scripts-Footnote-269666
+Node: Comments70213
+Node: Quoting72680
+Node: DOS Quoting77303
+Node: Sample Data Files77978
+Node: Very Simple81010
+Node: Two Rules85609
+Node: More Complex87756
+Ref: More Complex-Footnote-190686
+Node: Statements/Lines90771
+Ref: Statements/Lines-Footnote-195233
+Node: Other Features95498
+Node: When96426
+Node: Invoking Gawk98573
+Node: Command Line99958
+Node: Options100741
+Ref: Options-Footnote-1115098
+Node: Other Arguments115123
+Node: Naming Standard Input117781
+Node: Environment Variables118875
+Node: AWKPATH Variable119319
+Ref: AWKPATH Variable-Footnote-1121916
+Node: Other Environment Variables122176
+Node: Exit Status124668
+Node: Include Files125343
+Node: Obsolete128828
+Node: Undocumented129514
+Node: Regexp129755
+Node: Regexp Usage131144
+Node: Escape Sequences133170
+Node: Regexp Operators138933
+Ref: Regexp Operators-Footnote-1146313
+Ref: Regexp Operators-Footnote-2146460
+Node: Bracket Expressions146558
+Ref: table-char-classes148448
+Node: GNU Regexp Operators150971
+Node: Case-sensitivity154694
+Ref: Case-sensitivity-Footnote-1157662
+Ref: Case-sensitivity-Footnote-2157897
+Node: Leftmost Longest158005
+Node: Computed Regexps159206
+Node: Reading Files162616
+Node: Records164620
+Ref: Records-Footnote-1173294
+Node: Fields173331
+Ref: Fields-Footnote-1176364
+Node: Nonconstant Fields176450
+Node: Changing Fields178652
+Node: Field Separators184633
+Node: Default Field Splitting187262
+Node: Regexp Field Splitting188379
+Node: Single Character Fields191721
+Node: Command Line Field Separator192780
+Node: Field Splitting Summary196221
+Ref: Field Splitting Summary-Footnote-1199413
+Node: Constant Size199514
+Node: Splitting By Content204098
+Ref: Splitting By Content-Footnote-1207824
+Node: Multiple Line207864
+Ref: Multiple Line-Footnote-1213711
+Node: Getline213890
+Node: Plain Getline216106
+Node: Getline/Variable218195
+Node: Getline/File219336
+Node: Getline/Variable/File220658
+Ref: Getline/Variable/File-Footnote-1222257
+Node: Getline/Pipe222344
+Node: Getline/Variable/Pipe224904
+Node: Getline/Coprocess226011
+Node: Getline/Variable/Coprocess227254
+Node: Getline Notes227968
+Node: Getline Summary229910
+Ref: table-getline-variants230253
+Node: Read Timeout231109
+Ref: Read Timeout-Footnote-1234854
+Node: Command line directories234911
+Node: Printing235541
+Node: Print237172
+Node: Print Examples238509
+Node: Output Separators241293
+Node: OFMT243053
+Node: Printf244411
+Node: Basic Printf245317
+Node: Control Letters246856
+Node: Format Modifiers250668
+Node: Printf Examples256677
+Node: Redirection259392
+Node: Special Files266376
+Node: Special FD266909
+Ref: Special FD-Footnote-1270534
+Node: Special Network270608
+Node: Special Caveats271458
+Node: Close Files And Pipes272254
+Ref: Close Files And Pipes-Footnote-1279277
+Ref: Close Files And Pipes-Footnote-2279425
+Node: Expressions279575
+Node: Values280707
+Node: Constants281383
+Node: Scalar Constants282063
+Ref: Scalar Constants-Footnote-1282922
+Node: Nondecimal-numbers283104
+Node: Regexp Constants286163
+Node: Using Constant Regexps286638
+Node: Variables289693
+Node: Using Variables290348
+Node: Assignment Options292072
+Node: Conversion293944
+Ref: table-locale-affects299320
+Ref: Conversion-Footnote-1299944
+Node: All Operators300053
+Node: Arithmetic Ops300683
+Node: Concatenation303188
+Ref: Concatenation-Footnote-1305981
+Node: Assignment Ops306101
+Ref: table-assign-ops311089
+Node: Increment Ops312497
+Node: Truth Values and Conditions315967
+Node: Truth Values317050
+Node: Typing and Comparison318099
+Node: Variable Typing318888
+Ref: Variable Typing-Footnote-1322785
+Node: Comparison Operators322907
+Ref: table-relational-ops323317
+Node: POSIX String Comparison326866
+Ref: POSIX String Comparison-Footnote-1327822
+Node: Boolean Ops327960
+Ref: Boolean Ops-Footnote-1332038
+Node: Conditional Exp332129
+Node: Function Calls333861
+Node: Precedence337455
+Node: Locales341124
+Node: Patterns and Actions342213
+Node: Pattern Overview343267
+Node: Regexp Patterns344936
+Node: Expression Patterns345479
+Node: Ranges349164
+Node: BEGIN/END352130
+Node: Using BEGIN/END352892
+Ref: Using BEGIN/END-Footnote-1355623
+Node: I/O And BEGIN/END355729
+Node: BEGINFILE/ENDFILE358011
+Node: Empty360904
+Node: Using Shell Variables361220
+Node: Action Overview363505
+Node: Statements365862
+Node: If Statement367716
+Node: While Statement369215
+Node: Do Statement371259
+Node: For Statement372415
+Node: Switch Statement375567
+Node: Break Statement377664
+Node: Continue Statement379654
+Node: Next Statement381447
+Node: Nextfile Statement383837
+Node: Exit Statement386382
+Node: Built-in Variables388798
+Node: User-modified389893
+Ref: User-modified-Footnote-1398248
+Node: Auto-set398310
+Ref: Auto-set-Footnote-1408156
+Node: ARGC and ARGV408361
+Node: Arrays412212
+Node: Array Basics413717
+Node: Array Intro414543
+Node: Reference to Elements418861
+Node: Assigning Elements421131
+Node: Array Example421622
+Node: Scanning an Array423354
+Node: Controlling Scanning425668
+Ref: Controlling Scanning-Footnote-1430601
+Node: Delete430917
+Ref: Delete-Footnote-1433352
+Node: Numeric Array Subscripts433409
+Node: Uninitialized Subscripts435592
+Node: Multi-dimensional437220
+Node: Multi-scanning440314
+Node: Arrays of Arrays441905
+Node: Functions446550
+Node: Built-in447372
+Node: Calling Built-in448450
+Node: Numeric Functions450438
+Ref: Numeric Functions-Footnote-1454270
+Ref: Numeric Functions-Footnote-2454627
+Ref: Numeric Functions-Footnote-3454675
+Node: String Functions454944
+Ref: String Functions-Footnote-1478441
+Ref: String Functions-Footnote-2478570
+Ref: String Functions-Footnote-3478818
+Node: Gory Details478905
+Ref: table-sub-escapes480584
+Ref: table-sub-posix-92481938
+Ref: table-sub-proposed483281
+Ref: table-posix-sub484631
+Ref: table-gensub-escapes486177
+Ref: Gory Details-Footnote-1487384
+Ref: Gory Details-Footnote-2487435
+Node: I/O Functions487586
+Ref: I/O Functions-Footnote-1494241
+Node: Time Functions494388
+Ref: Time Functions-Footnote-1505280
+Ref: Time Functions-Footnote-2505348
+Ref: Time Functions-Footnote-3505506
+Ref: Time Functions-Footnote-4505617
+Ref: Time Functions-Footnote-5505729
+Ref: Time Functions-Footnote-6505956
+Node: Bitwise Functions506222
+Ref: table-bitwise-ops506780
+Ref: Bitwise Functions-Footnote-1510940
+Node: Type Functions511124
+Node: I18N Functions511594
+Node: User-defined513221
+Node: Definition Syntax514025
+Ref: Definition Syntax-Footnote-1518935
+Node: Function Example519004
+Node: Function Caveats521598
+Node: Calling A Function522019
+Node: Variable Scope523134
+Node: Pass By Value/Reference525109
+Node: Return Statement528549
+Node: Dynamic Typing531530
+Node: Indirect Calls532265
+Node: Internationalization541950
+Node: I18N and L10N543389
+Node: Explaining gettext544075
+Ref: Explaining gettext-Footnote-1549141
+Ref: Explaining gettext-Footnote-2549325
+Node: Programmer i18n549490
+Node: Translator i18n553690
+Node: String Extraction554483
+Ref: String Extraction-Footnote-1555444
+Node: Printf Ordering555530
+Ref: Printf Ordering-Footnote-1558314
+Node: I18N Portability558378
+Ref: I18N Portability-Footnote-1560827
+Node: I18N Example560890
+Ref: I18N Example-Footnote-1563525
+Node: Gawk I18N563597
+Node: Arbitrary Precision Arithmetic564214
+Ref: Arbitrary Precision Arithmetic-Footnote-1567089
+Node: Floating-point Programming567237
+Node: Floating-point Representation572507
+Node: Floating-point Context573611
+Ref: table-ieee-formats574446
+Node: Rounding Mode575816
+Ref: table-rounding-modes576443
+Ref: Rounding Mode-Footnote-1579566
+Node: Arbitrary Precision Floats579747
+Ref: Arbitrary Precision Floats-Footnote-1581788
+Node: Setting Precision582099
+Node: Setting Rounding Mode584857
+Node: Floating-point Constants585774
+Node: Changing Precision587193
+Ref: Changing Precision-Footnote-1588593
+Node: Exact Arithmetic588766
+Node: Integer Programming591779
+Node: Arbitrary Precision Integers593559
+Ref: Arbitrary Precision Integers-Footnote-1596583
+Node: MPFR and GMP Libraries596729
+Node: Advanced Features597114
+Node: Nondecimal Data598637
+Node: Array Sorting600220
+Node: Controlling Array Traversal600917
+Node: Array Sorting Functions609154
+Ref: Array Sorting Functions-Footnote-1612828
+Ref: Array Sorting Functions-Footnote-2612921
+Node: Two-way I/O613115
+Ref: Two-way I/O-Footnote-1618547
+Node: TCP/IP Networking618617
+Node: Profiling621461
+Node: Library Functions628915
+Ref: Library Functions-Footnote-1631922
+Node: Library Names632093
+Ref: Library Names-Footnote-1635564
+Ref: Library Names-Footnote-2635784
+Node: General Functions635870
+Node: Strtonum Function636823
+Node: Assert Function639753
+Node: Round Function643079
+Node: Cliff Random Function644622
+Node: Ordinal Functions645638
+Ref: Ordinal Functions-Footnote-1648708
+Ref: Ordinal Functions-Footnote-2648960
+Node: Join Function649169
+Ref: Join Function-Footnote-1650940
+Node: Gettimeofday Function651140
+Node: Data File Management654855
+Node: Filetrans Function655487
+Node: Rewind Function659626
+Node: File Checking661013
+Node: Empty Files662107
+Node: Ignoring Assigns664337
+Node: Getopt Function665890
+Ref: Getopt Function-Footnote-1677194
+Node: Passwd Functions677397
+Ref: Passwd Functions-Footnote-1686372
+Node: Group Functions686460
+Node: Walking Arrays694544
+Node: Sample Programs696113
+Node: Running Examples696778
+Node: Clones697506
+Node: Cut Program698730
+Node: Egrep Program708575
+Ref: Egrep Program-Footnote-1716348
+Node: Id Program716458
+Node: Split Program720074
+Ref: Split Program-Footnote-1723593
+Node: Tee Program723721
+Node: Uniq Program726524
+Node: Wc Program733953
+Ref: Wc Program-Footnote-1738219
+Ref: Wc Program-Footnote-2738419
+Node: Miscellaneous Programs738511
+Node: Dupword Program739699
+Node: Alarm Program741730
+Node: Translate Program746479
+Ref: Translate Program-Footnote-1750866
+Ref: Translate Program-Footnote-2751094
+Node: Labels Program751228
+Ref: Labels Program-Footnote-1754599
+Node: Word Sorting754683
+Node: History Sorting758567
+Node: Extract Program760406
+Ref: Extract Program-Footnote-1767889
+Node: Simple Sed768017
+Node: Igawk Program771079
+Ref: Igawk Program-Footnote-1786236
+Ref: Igawk Program-Footnote-2786437
+Node: Anagram Program786575
+Node: Signature Program789643
+Node: Debugger790743
+Node: Debugging791695
+Node: Debugging Concepts792128
+Node: Debugging Terms793984
+Node: Awk Debugging796581
+Node: Sample Debugging Session797473
+Node: Debugger Invocation797993
+Node: Finding The Bug799322
+Node: List of Debugger Commands805810
+Node: Breakpoint Control807144
+Node: Debugger Execution Control810808
+Node: Viewing And Changing Data814168
+Node: Execution Stack817524
+Node: Debugger Info818991
+Node: Miscellaneous Debugger Commands822972
+Node: Readline Support828417
+Node: Limitations829248
+Node: Language History831500
+Node: V7/SVR3.1833012
+Node: SVR4835333
+Node: POSIX836775
+Node: BTL837783
+Node: POSIX/GNU838517
+Node: Common Extensions843668
+Node: Ranges and Locales844775
+Ref: Ranges and Locales-Footnote-1849379
+Node: Contributors849600
+Node: Installation853861
+Node: Gawk Distribution854755
+Node: Getting855239
+Node: Extracting856065
+Node: Distribution contents857757
+Node: Unix Installation862979
+Node: Quick Installation863596
+Node: Additional Configuration Options865558
+Node: Configuration Philosophy867035
+Node: Non-Unix Installation869377
+Node: PC Installation869835
+Node: PC Binary Installation871134
+Node: PC Compiling872982
+Node: PC Testing875926
+Node: PC Using877102
+Node: Cygwin881287
+Node: MSYS882287
+Node: VMS Installation882801
+Node: VMS Compilation883404
+Ref: VMS Compilation-Footnote-1884411
+Node: VMS Installation Details884469
+Node: VMS Running886104
+Node: VMS Old Gawk887711
+Node: Bugs888185
+Node: Other Versions892037
+Node: Notes897352
+Node: Compatibility Mode898044
+Node: Additions898827
+Node: Accessing The Source899639
+Node: Adding Code901064
+Node: New Ports907031
+Node: Dynamic Extensions911144
+Node: Internals912584
+Node: Plugin License921103
+Node: Loading Extensions921741
+Node: Sample Library923551
+Node: Internal File Description924241
+Node: Internal File Ops927956
+Ref: Internal File Ops-Footnote-1932680
+Node: Using Internal File Ops932820
+Node: Future Extensions935197
+Node: Basic Concepts937701
+Node: Basic High Level938458
+Ref: Basic High Level-Footnote-1942493
+Node: Basic Data Typing942678
+Node: Floating Point Issues947203
+Node: String Conversion Precision948286
+Ref: String Conversion Precision-Footnote-1949986
+Node: Unexpected Results950095
+Node: POSIX Floating Point Problems951921
+Ref: POSIX Floating Point Problems-Footnote-1955626
+Node: Glossary955664
+Node: Copying980640
+Node: GNU Free Documentation License1018197
+Node: Index1043334

End Tag Table
diff --git a/doc/gawk.texi b/doc/gawk.texi
index 83bd3b5d..8cd7e38e 100644
--- a/doc/gawk.texi
+++ b/doc/gawk.texi
@@ -79,9 +79,11 @@
@c some special symbols
@iftex
@set LEQ @math{@leq}
+@set PI @math{@pi}
@end iftex
@ifnottex
@set LEQ <=
+@set PI @i{pi}
@end ifnottex
@ifnottex
@@ -285,12 +287,14 @@ particular records in a file and perform operations upon them.
* Functions:: Built-in and user-defined functions.
* Internationalization:: Getting @command{gawk} to speak your
language.
+* Arbitrary Precision Arithmetic:: Arbitrary precision arithmetic with
+ @command{gawk}.
* Advanced Features:: Stuff for advanced users, specific to
@command{gawk}.
* Library Functions:: A Library of @command{awk} Functions.
* Sample Programs:: Many @command{awk} programs with complete
explanations.
-* Debugger:: The @code{dgawk} debugger.
+* Debugger:: The @code{gawk} debugger.
* Language History:: The evolution of the @command{awk}
language.
* Installation:: Installing @command{gawk} under various
@@ -393,6 +397,7 @@ particular records in a file and perform operations upon them.
* Getline Notes:: Important things to know about
@code{getline}.
* Getline Summary:: Summary of @code{getline} Variants.
+* Read Timeout:: Reading input with a timeout.
* Command line directories:: What happens if you put a directory on the
command line.
* Print:: The @code{print} statement.
@@ -550,6 +555,21 @@ particular records in a file and perform operations upon them.
* I18N Portability:: @command{awk}-level portability issues.
* I18N Example:: A simple i18n example.
* Gawk I18N:: @command{gawk} is also internationalized.
+* Floating-point Programming:: Effective floating-point programming.
+* Floating-point Representation:: Binary floating-point representation.
+* Floating-point Context:: Floating-point context.
+* Rounding Mode:: Floating-point rounding mode.
+* Arbitrary Precision Floats:: Arbitrary precision floating-point
+ arithmetic with @command{gawk}.
+* Setting Precision:: Setting the working precision.
+* Setting Rounding Mode:: Setting the rounding mode.
+* Floating-point Constants:: Representing floating-point constants.
+* Changing Precision:: Changing the precision of a number.
+* Exact Arithmetic:: Exact arithmetic with floating-point numbers.
+* Integer Programming:: Effective integer programming.
+* Arbitrary Precision Integers:: Arbitrary precision integer
+ arithmetic with @command{gawk}.
+* MPFR and GMP Libraries:: Information about the MPFR and GMP libraries.
* Nondecimal Data:: Allowing nondecimal input data.
* Array Sorting:: Facilities for controlling array traversal
and sorting arrays.
@@ -614,23 +634,23 @@ particular records in a file and perform operations upon them.
* Anagram Program:: Finding anagrams from a dictionary.
* Signature Program:: People do amazing things with too much time
on their hands.
-* Debugging:: Introduction to @command{dgawk}.
-* Debugging Concepts:: Debugging In General.
+* Debugging:: Introduction to @command{gawk} Debugger.
+* Debugging Concepts:: Debugging in General.
* Debugging Terms:: Additional Debugging Concepts.
* Awk Debugging:: Awk Debugging.
-* Sample dgawk session:: Sample @command{dgawk} session.
-* dgawk invocation:: @command{dgawk} Invocation.
-* Finding The Bug:: Finding The Bug.
-* List of Debugger Commands:: Main @command{dgawk} Commands.
-* Breakpoint Control:: Control of breakpoints.
-* Dgawk Execution Control:: Control of execution.
-* Viewing And Changing Data:: Viewing and changing data.
-* Dgawk Stack:: Dealing with the stack.
-* Dgawk Info:: Obtaining information about the program and
- the debugger state.
-* Miscellaneous Dgawk Commands:: Miscellaneous Commands.
+* Sample Debugging Session:: Sample Debugging Session.
+* Debugger Invocation:: How to Start the Debugger.
+* Finding The Bug:: Finding the Bug.
+* List of Debugger Commands:: Main Commands.
+* Breakpoint Control:: Control of Breakpoints.
+* Debugger Execution Control:: Control of Execution.
+* Viewing And Changing Data:: Viewing and Changing Data.
+* Execution Stack:: Dealing with the Stack.
+* Debugger Info:: Obtaining Information about the Program and
+ the Debugger State.
+* Miscellaneous Debugger Commands:: Miscellaneous Commands.
* Readline Support:: Readline Support.
-* Dgawk Limitations:: Limitations and future plans.
+* Limitations:: Limitations and Future Plans.
* V7/SVR3.1:: The major changes between V7 and System V
Release 3.1.
* SVR4:: Minor changes between System V Releases 3.1
@@ -686,6 +706,7 @@ particular records in a file and perform operations upon them.
* Internals:: A brief look at some @command{gawk}
internals.
* Plugin License:: A note about licensing.
+* Loading Extensions:: How to load dynamic extensions.
* Sample Library:: A example of new functions.
* Internal File Description:: What the new functions will do.
* Internal File Ops:: The code for internal file operations.
@@ -1164,8 +1185,7 @@ provide many sample @command{awk} programs.
Reading them allows you to see @command{awk}
solving real problems.
-@ref{Debugger}, describes the @command{awk} debugger,
-@command{dgawk}.
+@ref{Debugger}, describes the @command{awk} debugger.
@ref{Language History},
describes how the @command{awk} language has evolved since
@@ -1594,10 +1614,13 @@ has been and continues to be a pleasure working with this team of fine
people.
John Haque contributed the modifications to convert @command{gawk}
-into a byte-code interpreter, including the debugger. Stephen Davies
+into a byte-code interpreter, including the debugger, and the
+additional modifications for support of arbitrary precision arithmetic.
+Stephen Davies
contributed to the effort to bring the byte-code changes into the mainstream
code base.
Efraim Yawitz contributed the initial text of @ref{Debugger}.
+John Haque contributed the initial text of @ref{Arbitrary Precision Arithmetic}.
@cindex Kernighan, Brian
I would like to thank Brian Kernighan for invaluable assistance during the
@@ -3103,6 +3126,19 @@ inadvertently use global variables that you meant to be local.
(This is a particularly easy mistake to make with simple variable
names like @code{i}, @code{j}, etc.)
+@item -D@r{[}@var{file}@r{]}
+@itemx --debug=@r{[}@var{file}@r{]}
+@cindex @code{-D} option
+@cindex @code{--debug} option
+@cindex @command{awk} debugging, enabling
+Enable debugging of @command{awk} programs
+(@pxref{Debugging}).
+By default, the debugger reads commands interactively from the terminal.
+The optional @var{file} argument allows you to specify a file with a list
+of commands for the debugger to execute non-interactively.
+No space is allowed between the @option{-D} and @var{file}, if
+@var{file} is supplied.
+
@item -e @var{program-text}
@itemx --source @var{program-text}
@cindex @code{-e} option
@@ -3168,6 +3204,15 @@ for information about this option.
Print a ``usage'' message summarizing the short and long style options
that @command{gawk} accepts and then exit.
+@item -l @var{lib}
+@itemx --load @var{lib}
+@cindex @code{-l} option
+@cindex @code{--load} option
+@cindex loading, library
+Load a shared library @var{lib}. This searches for the library using the @env{AWKPATH}
+environment variable. The suffix @samp{.so} in the library name is optional.
+The library initialization routine should be named @code{dlload()}.
+
@item -L @r{[}value@r{]}
@itemx --lint@r{[}=value@r{]}
@cindex @code{-l} option
@@ -3191,6 +3236,14 @@ when eliminating problems pointed out by @option{--lint}, you should take
care to search for all occurrences of each inappropriate construct. As
@command{awk} programs are usually short, doing so is not burdensome.
+@item -M
+@itemx --bignum
+@cindex @code{-M} option
+@cindex @code{--bignum} option
+Force arbitrary precision arithmetic on numbers. This option has no effect
+if @command{gawk} is not compiled to use the GNU MPFR and MP libraries
+(@pxref{Arbitrary Precision Arithmetic}).
+
@item -n
@itemx --non-decimal-data
@cindex @code{-n} option
@@ -3214,6 +3267,18 @@ Use with care.
Force the use of the locale's decimal point character
when parsing numeric input data (@pxref{Locales}).
+@item -o@r{[}@var{file}@r{]}
+@itemx --pretty-print@r{[}=@var{file}@r{]}
+@cindex @code{-o} option
+@cindex @code{--pretty-print} option
+@cindex @command{awk} enabling
+Enable pretty-printing of @command{awk} programs.
+By default, output program is created in a file named @file{awkprof.out}.
+The optional @var{file} argument allows you to specify a different
+@value{FN} for the output.
+No space is allowed between the @option{-o} and @var{file}, if
+@var{file} is supplied.
+
@item -O
@itemx --optimize
@cindex @code{--optimize} option
@@ -3226,7 +3291,7 @@ maintainer hopes to add more optimizations over time.
@itemx --profile@r{[}=@var{file}@r{]}
@cindex @code{-p} option
@cindex @code{--profile} option
-@cindex @command{awk} programs, profiling, enabling
+@cindex @command{awk} profiling, enabling
Enable profiling of @command{awk} programs
(@pxref{Profiling}).
By default, profiles are created in a file named @file{awkprof.out}.
@@ -3235,10 +3300,8 @@ The optional @var{file} argument allows you to specify a different
No space is allowed between the @option{-p} and @var{file}, if
@var{file} is supplied.
-When run with @command{gawk}, the profile is just a ``pretty printed'' version
-of the program. When run with @command{pgawk}, the profile contains execution
-counts for each statement in the program in the left margin, and function
-call counts for each function.
+The profile contains execution counts for each statement in the program
+in the left margin, and function call counts for each function.
@item -P
@itemx --posix
@@ -3302,14 +3365,6 @@ This is now @command{gawk}'s default behavior.
Nevertheless, this option remains both for backward compatibility,
and for use in combination with the @option{--traditional} option.
-@item -R @var{file}
-@itemx --command=@var{file}
-@cindex @code{-R} option
-@cindex @code{--command} option
-@command{dgawk} only.
-Read @command{dgawk} debugger options and commands from @var{file}.
-@xref{Dgawk Info}, for more information.
-
@item -S
@itemx --sandbox
@cindex @code{-S} option
@@ -3633,6 +3688,11 @@ Specifies the interval between connection retries,
in milliseconds. On systems that do not support
the @code{usleep()} system call,
the value is rounded up to an integral number of seconds.
+
+@item GAWK_READ_TIMEOUT
+Specifies the time, in milliseconds, for @command{gawk} to
+wait for input before returning with an error.
+@xref{Read Timeout}.
@end table
The environment variables in the following list are meant
@@ -3706,7 +3766,7 @@ into smaller, more manageable pieces, and also lets you reuse common @command{aw
code from various @command{awk} scripts. In other words, you can group
together @command{awk} functions, used to carry out specific tasks,
into external files. These files can be used just like function libraries,
-using the @samp{@@include} keyword in conjunction with the @code{AWKPATH}
+using the @samp{@@include} keyword in conjunction with the @env{AWKPATH}
environment variable.
Let's see an example.
@@ -5119,6 +5179,8 @@ used with it do not have to be named on the @command{awk} command line
* Multiple Line:: Reading multi-line records.
* Getline:: Reading files under explicit program control
using the @code{getline} function.
+* Read Timeout:: Reading input with a timeout.
+
* Command line directories:: What happens if you put a directory on the
command line.
@end menu
@@ -7197,6 +7259,110 @@ and whether the variant is standard or a @command{gawk} extension.
@c ENDOFRANGE inex
@c ENDOFRANGE infir
+@node Read Timeout
+@section Reading Input With A Timeout
+@cindex timeout, reading input
+
+You may specify a timeout in milliseconds for reading input from a terminal,
+pipe or two-way communication including, TCP/IP sockets. This can be done
+on a per input, command or connection basis, by setting a special element
+in the @code{PROCINFO} array:
+
+@example
+PROCINFO["input_name", "READ_TIMEOUT"] = @var{timeout in milliseconds}
+@end example
+
+When set, this will cause @command{gawk} to time out and return failure
+if no data is available to read within the specified timeout period.
+For example, a TCP client can decide to give up on receiving
+any response from the server after a certain amount of time:
+
+@example
+Service = "/inet/tcp/0/localhost/daytime"
+PROCINFO[Service, "READ_TIMEOUT"] = 100
+if ((Service |& getline) > 0)
+ print $0
+else if (ERRNO != "")
+ print ERRNO
+@end example
+
+Here is how to read interactively from the terminal@footnote{This assumes
+that standard input is the keyboard} without waiting
+for more than five seconds:
+
+@example
+PROCINFO["/dev/stdin", "READ_TIMEOUT"] = 5000
+while ((getline < "/dev/stdin") > 0)
+ print $0
+@end example
+
+@command{gawk} will terminate the read operation if input does not
+arrive after waiting for the timeout period, return failure
+and set the @code{ERRNO} variable to an appropriate string value.
+A negative or zero value for the timeout is the same as specifying
+no timeout at all.
+
+A timeout can also be set for reading from the terminal in the implicit
+loop that reads input records and matches them against patterns,
+like so:
+
+@example
+$ @kbd{ gawk 'BEGIN @{ PROCINFO["-", "READ_TIMEOUT"] = 5000 @}}
+> @kbd{@{ print "You entered: " $0 @}'}
+@kbd{gawk}
+@print{} You entered: gawk
+@end example
+
+In this case, failure to respond within five seconds results in the following
+error message:
+
+@example
+@error{} gawk: cmd. line:2: (FILENAME=- FNR=1) fatal: error reading input file `-': Connection timed out
+@end example
+
+The timeout can be set or changed at any time, and will take effect on the
+next attempt to read from the input device. In the following example,
+we start with a timeout value of one second, and progressively
+reduce it by one-tenth of a second until we wait indefinitely
+for the input to arrive:
+
+@example
+PROCINFO[Service, "READ_TIMEOUT"] = 1000
+while ((Service |& getline) > 0) @{
+ print $0
+ PROCINFO[S, "READ_TIMEOUT"] -= 100
+@}
+@end example
+
+@quotation NOTE
+You should not assume that the read operation will block
+exactly after the tenth record has been printed. It is possible that
+@command{gawk} will read and buffer more than one record's
+worth of data the first time. Because of this, changing the value
+of timeout like in the above example is not very useful.
+@end quotation
+
+If the @code{PROCINFO} element is not present and the environment
+variable @env{GAWK_READ_TIMEOUT} exists,
+@command{gawk} uses its value to initialize the timeout value.
+The exclusive use of the environment variable to specify timeout
+has the disadvantage of not being able to control it
+on a per command or connection basis.
+
+@command{gawk} considers a timeout event to be an error even though
+the attempt to read from the underlying device may
+succeed in a later attempt. This is a limitation, and it also
+means that you cannot use this to multiplex input from
+two or more sources.
+
+Assigning a timeout value prevents read operations from
+blocking indefinitely. But bear in mind that there are other ways
+@command{gawk} can stall waiting for an input device to be ready.
+A network client can sometimes take a long time to establish
+a connection before it can start reading any data,
+or the attempt to open a FIFO special file for reading can block
+indefinitely until some other process opens it for writing.
+
@node Command line directories
@section Directories On The Command Line
@cindex directories, command line
@@ -12470,6 +12636,18 @@ This is the output record separator. It is output at the end of every
@code{print} statement. Its default value is @code{"\n"}, the newline
character. (@xref{Output Separators}.)
+@cindex @code{PREC} variable
+@item PREC #
+The working precision of arbitrary precision floating-point numbers,
+53 by default (@pxref{Setting Precision}).
+
+@cindex @code{ROUNDMODE} variable
+@item ROUNDMODE #
+The rounding mode to use for arbitrary precision arithmetic on
+numbers, by default @code{"N"} (@samp{roundTiesToEven} in
+the IEEE-754 standard)
+(@pxref{Setting Rounding Mode}).
+
@cindex @code{RS} variable
@cindex separators, for records
@cindex record separators
@@ -12753,6 +12931,25 @@ The value of the @code{getuid()} system call.
The version of @command{gawk}.
@end table
+The following additional elements in the array
+are available to provide information about the MPFR and GMP libraries
+if your version of @command{gawk} supports arbitrary precision numbers
+(@pxref{Arbitrary Precision Arithmetic}):
+
+@table @code
+@item PROCINFO["mpfr_version"]
+The version of the GNU MPFR library.
+
+@item PROCINFO["gmp_version"]
+The version of the GNU MP library.
+
+@item PROCINFO["prec_max"]
+The maximum precision supported by MPFR.
+
+@item PROCINFO["prec_min"]
+The minimum precision required by MPFR.
+@end table
+
On some systems, there may be elements in the array, @code{"group1"}
through @code{"group@var{N}"} for some @var{N}. @var{N} is the number of
supplementary groups that the process has. Use the @code{in} operator
@@ -18171,6 +18368,863 @@ then @command{gawk} produces usage messages, warnings,
and fatal errors in the local language.
@c ENDOFRANGE inloc
+@node Arbitrary Precision Arithmetic
+@chapter Arbitrary Precision Arithmetic with @command{gawk}
+@cindex arbitrary precision
+@cindex multiple precision
+@cindex infinite precision
+@cindex floating-point numbers, arbitrary precision
+@cindex MPFR
+@cindex GMP
+
+@cindex Knuth, Donald
+@quotation
+@i{There's a credibility gap: We don't know how much of the computer's answers
+to believe. Novice computer users solve this problem by implicitly trusting
+in the computer as an infallible authority; they tend to believe that all
+digits of a printed answer are significant. Disillusioned computer users have
+just the opposite approach; they are constantly afraid that their answers
+are almost meaningless.}
+
+Donald Knuth@footnote{Donald E.@: Knuth.
+@cite{The Art of Computer Programming}. Volume 2,
+@cite{Seminumerical Algorithms}, third edition,
+1998, ISBN 0-201-89683-4, p.@: 229.}
+@end quotation
+
+This @value{SECTION} decsribes how to use the arbitrary precision
+(also known as @dfn{multiple precision} or @dfn{infinite precision}) numeric
+capabilites in @command{gawk} to produce maximally accurate results
+when you need it. But first you should check if your version of
+@command{gawk} supports arbitrary precision arithmetic.
+The easiest way to find out is to look at the output of
+the following command:
+
+@example
+$ @kbd{gawk --version}
+@print{} GNU Awk 4.1.0 (GNU MPFR 3.1.0, GNU MP 5.0.3)
+@print{} Copyright (C) 1989, 1991-2012 Free Software Foundation.
+@dots{}
+@end example
+
+@command{gawk} uses the
+@uref{http://www.mpfr.org, GNU MPFR}
+and
+@uref{http://gmplib.org, GNU MP} (GMP)
+libraries for arbitrary precision
+arithmetic on numbers. So if you do not see the names of these libraries
+in the output, then your version of @command{gawk} does not support
+arbitrary precision arithmetic.
+
+Even if you aren't interested in arbitrary precision arithmetic, you
+may still benifit from knowing about how @command{gawk} handles numbers
+in general, and the limitations of doing arithmetic with ordinary
+@command{gawk} numbers.
+
+@menu
+* Floating-point Programming:: Effective Floating-point Programming.
+* Floating-point Representation:: Binary Floating-point Representation.
+* Floating-point Context:: Floating-point Context.
+* Rounding Mode:: Floating-point Rounding Mode.
+* Arbitrary Precision Floats:: Arbitrary Precision Floating-point
+ Arithmetic with @command{gawk}.
+* Setting Precision:: Setting the Working Precision.
+* Setting Rounding Mode:: Setting the Rounding Mode.
+* Floating-point Constants:: Representing Floating-point Constants.
+* Changing Precision:: Changing the Precision of a Number.
+* Exact Arithmetic:: Exact Arithmetic with Floating-point Numbers.
+* Integer Programming:: Effective Integer Programming.
+* Arbitrary Precision Integers:: Arbitrary Precision Integer
+ Arithmetic with @command{gawk}.
+* MPFR and GMP Libraries:: Information About the MPFR and GMP Libraries.
+@end menu
+
+@node Floating-point Programming
+@section Effective Floating-point Programming
+
+Numerical programming is an extensive area; if you need to develop
+sophisticated numerical algorithms then @command{gawk} may not be
+the ideal tool, and this documentation may not be sufficient.
+@c FIXME: JOHN: Do you want to cite some actual books?
+It might require a book or two to communicate how to compute
+with ideal accuracy and precision
+and the result often depends on the particular application.
+
+@quotation NOTE
+A floating-point calculation's @dfn{accuracy} is how close it comes
+to the real value. This is as opposed to the @dfn{precision}, which
+usually refers to the number of bits used to represent the number
+(see @uref{http://en.wikipedia.org/wiki/Accuracy_and_precision,
+the Wikipedia article} for more information).
+@end quotation
+
+Binary floating-point representations and arithmetic are inexact.
+Simple values like 0.1 cannot be precisely represented using
+binary floating-point numbers, and the limited precision of
+floating-point numbers means that slight changes in
+the order of operations or the precision of intermediate storage
+can change the result. To make matters worse with arbitrary precision
+floating-point, you can set the precision before starting a computation,
+but then you cannot be sure of the number of significant decimal places
+in the final result.
+
+Sometimes you need to think more about what you really want
+and what's really happening. Consider the two numbers
+in the following example:
+
+@example
+x = 0.875 # 1/2 + 1/4 + 1/8
+y = 0.425
+@end example
+
+Unlike the number in @code{y}, the number stored in @code{x}
+is exactly representable
+in binary since it can be written as a finite sum of one or
+more fractions whose denominators are all powers of two.
+When @command{gawk} reads a floating-point number from
+program source, it automatically rounds that number to whatever
+precision your machine supports. If you try to print the numeric
+content of a variable using an output format string of @code{"%.17g"},
+it may not produce the same number as you assigned to it:
+
+@example
+$ @kbd{gawk 'BEGIN @{ x = 0.875; y = 0.425}
+> @kbd{ printf("%0.17g, %0.17g\n", x, y) @}'}
+@print{} 0.875, 0.42499999999999999
+@end example
+
+Often the error is so small you do not even notice it, and if you do,
+you can always specify how much precision you would like in your output.
+Usually this is a format string like @code{"%.15g"}, which when
+used in the previous example, produces an output identical to the input.
+
+Because the underlying representation can be little bit off from the exact value,
+comparing floats to see if they are equal is generally not a good idea.
+Here is an example where it does not work like you expect:
+
+@example
+$ @kbd{gawk 'BEGIN @{ print (0.1 + 12.2 == 12.3) @}'}
+@print{} 0
+@end example
+
+The loss of accuracy during a single computation with floating-point numbers
+usually isn't enough to worry about. However, if you compute a value
+which is the result of a sequence of floating point operations,
+the error can accumulate and greatly affect the computation itself.
+Here is an attempt to compute the value of the constant
+@value{PI} using one of its many series representations:
+
+@example
+BEGIN @{
+ x = 1.0 / sqrt(3.0)
+ n = 6
+ for (i = 1; i < 30; i++) @{
+ n = n * 2.0
+ x = (sqrt(x * x + 1) - 1) / x
+ printf("%.15f\n", n * x)
+ @}
+@}
+@end example
+
+When run, the early errors propagating through later computations
+cause the loop to terminate prematurely after an attempt to divide by zero.
+
+@example
+$ @kbd{gawk -f pi.awk}
+@print{} 3.215390309173475
+@print{} 3.159659942097510
+@print{} 3.146086215131467
+@print{} 3.142714599645573
+@dots{}
+@print{} 3.224515243534819
+@print{} 2.791117213058638
+@print{} 0.000000000000000
+@error{} gawk: pi.awk:6: fatal: division by zero attempted
+@end example
+
+Here is one more example where the inaccuracies in internal representations
+yield an unexpected result:
+
+@example
+$ @kbd{gawk 'BEGIN @{}
+> @kbd{for (d = 1.1; d <= 1.5; d += 0.1)}
+> @kbd{i++}
+> @kbd{print i}
+> @kbd{@}'}
+@print{} 4
+@end example
+
+Can computation using aribitrary precision help with the previous examples?
+If you are impatient to know, see
+@ref{Exact Arithmetic}.
+
+Instead of aribitrary precision floating-point arithmetic,
+often all you need is an adjustment of your logic
+or a different order for the operations in your calculation.
+The stability and the accuracy of the computation of the constant @value{PI}
+in the previous example can be enhanced by using the following
+simple algebraic transformation:
+
+@example
+(sqrt(x * x + 1) - 1) / x = x / (sqrt(x * x + 1) + x)
+@end example
+
+There is no need to be unduly suspicious about the results from
+floating-point arithmetic. The lesson to remember is that
+floating-point math is always more complex than the math using
+pencil and paper. In order to take advantage of the power
+of computer floating-point, you need to know its limitations
+and work within them. For most casual use of floating-point arithmetic,
+you will often get the expected result in the end if you simply round
+the display of your final results to the correct number of significant
+decimal digits. Avoid presenting numerical data in a manner that
+implies better precision than is actually the case.
+
+@node Floating-point Representation
+@section Binary Floating-point Representation
+@cindex IEEE-754 format
+
+Although floating-point representations vary from machine to machine,
+the most commonly encountered representation is that defined by the
+IEEE 754 Standard. An IEEE-754 format value has three components:
+
+@itemize @bullet
+@item
+a sign bit telling whether the number is positive or negative,
+
+@item
+an @dfn{exponent} giving its order of magnitude, @var{e},
+
+@item
+and a @dfn{significand}, @var{s},
+specifying the actual digits of the number.
+@end itemize
+
+The value of the
+number is then
+@iftex
+@math{s @cdot 2^e}.
+@end iftex
+@ifnottex
+@var{s * 2^e}.
+@end ifnottex
+The first bit of a non-zero binary significand
+is always one, so the significand in an IEEE-754 format only includes the
+fractional part, leaving the leading one implicit.
+
+Three of the standard IEEE-754 types are 32-bit single precision,
+64-bit double precision and 128-bit quadruple precision.
+The standard also specifies extended precision formats
+to allow greater precisions and larger exponent ranges.
+
+@node Floating-point Context
+@section Floating-point Context
+@cindex context, floating-point
+
+A floating-point context defines the environment for arithmetic operations.
+It governs precision, sets rules for rounding and limits range for exponents.
+The context has the following primary components:
+
+@table @code
+@item precision
+Precision of the floating-point format in bits.
+@item emax
+Maximum exponent allowed for this format.
+@item emin
+Minimum exponent allowed for this format.
+@item underflow behavior
+The format may or may not support gradual underflow.
+@item rounding
+The rounding mode of this context.
+@end table
+
+@ref{table-ieee-formats} lists the precision and exponent
+field values for the basic IEEE-754 binary formats:
+
+@float Table,table-ieee-formats
+@caption{Basic IEEE Formats}
+@multitable @columnfractions .20 .20 .20 .20 .20
+@headitem Name @tab Total bits @tab Precision @tab emin @tab emax
+@item Single @tab 32 @tab 24 @tab @minus{}126 @tab +127
+@item Double @tab 64 @tab 53 @tab @minus{}1022 @tab +1023
+@item Quadruple @tab 128 @tab 113 @tab @minus{}16382 @tab +16383
+@end multitable
+@end float
+
+@quotation NOTE
+The precision numbers include the implied leading one that gives them
+one extra bit of significand.
+@end quotation
+
+A floating-point context can also determine which signals are treated
+as exceptions, and can set rules for arithmetic with special values.
+Please consult the IEEE-754 standard or other resources for details.
+
+@command{gawk} ordinarily uses the hardware double precision
+representation for numbers. On most systems, this is IEEE-754
+floating-point format, corresponding to 64-bit binary with 53 bits
+of precision.
+
+@quotation NOTE
+In case an underflow occurs, the standard allows, but does not require,
+the result from an arithmetic operation to be a number smaller than
+the smallest nonzero normalized number. Such numbers do
+not have as many significant digits as normal numbers, and are called
+@dfn{denormals} or @dfn{subnormals}. The alternative, simply returning a zero,
+is called @dfn{flush to zero}. The basic IEEE-754 binary formats
+support subnormal numbers.
+@end quotation
+
+@node Rounding Mode
+@section Floating-point Rounding Mode
+@cindex rounding mode, floating-point
+
+The @dfn{rounding mode} specifies the behavior for the results of numerical
+operations when discarding extra precision. Each rounding mode indicates
+how the least significant returned digit of a rounded result is to
+be calculated.
+The @code{ROUNDMODE} variable (@pxref{Setting Rounding Mode}) provides
+program level control over the rounding mode.
+@ref{table-rounding-modes} lists the IEEE-754 defined
+rounding modes:
+
+@float Table,table-rounding-modes
+@caption{Rounding Modes}
+@multitable @columnfractions .45 .30 .25
+@headitem Rounding Mode @tab IEEE Name @tab @code{ROUNDMODE}
+@item Round to nearest, ties to even @tab @code{roundTiesToEven} @tab @code{"N"} or @code{"n"}
+@item Round toward plus Infinity @tab @code{roundTowardPositive} @tab @code{"U"} or @code{"u"}
+@item Round toward negative Infinity @tab @code{roundTowardNegative} @tab @code{"D"} or @code{"d"}
+@item Round toward zero @tab @code{roundTowardZero} @tab @code{"Z"} or @code{"z"}
+@item Round to nearest, ties away from zero @tab @code{roundTiesToAway} @tab @code{"A"} or @code{"a"}
+@end multitable
+@end float
+
+The default mode @samp{roundTiesToEven} is the most preferred,
+but the least intuitive. This method does the obvious thing for most values,
+by rounding them up or down to the nearest digit.
+For example, rounding 1.132 to two digits yields 1.13,
+and rounding 1.157 yields 1.16.
+
+However, when it comes to rounding a value that is exactly halfway between,
+things do not work the way you probably learned in school.
+In this case, the number is rounded to the nearest even digit.
+So rounding 0.125 to two digits rounds down to 0.12,
+but rounding 0.6875 to three digits rounds up to 0.688.
+You probably have already encountered this rounding mode when
+using the @code{printf} routine to format floating-point numbers.
+For example:
+
+@example
+BEGIN @{
+ x = -4.5
+ for (i = 1; i < 10; i++) @{
+ x += 1.0
+ printf("%4.1f => %2.0f\n", x, x)
+ @}
+@}
+@end example
+
+@noindent
+produces the following output when run@footnote{It
+is possible for the output to be completely different if the
+C library in your system does not use the IEEE-754 even-rounding
+rule to round halfway cases for @code{printf()}.}:
+
+@example
+-3.5 => -4
+-2.5 => -2
+-1.5 => -2
+-0.5 => 0
+ 0.5 => 0
+ 1.5 => 2
+ 2.5 => 2
+ 3.5 => 4
+ 4.5 => 4
+@end example
+
+The theory behind the rounding mode @samp{roundTiesToEven} is that
+it more or less evenly distributes upward and downward rounds
+of exact halves, which might cause the round-off error
+to cancel itself out. This is the default rounding mode used
+in IEEE-754 computing functions and operators.
+
+The other rounding modes are rarely used.
+Round toward positive infinity (@samp{roundTowardPositive})
+and round toward negative infinity (@samp{roundTowardNegative})
+are often used to implement interval arithmetic,
+where you adjust the rounding mode to calculate upper and lower bounds
+for the range of output. The @samp{roundTowardZero}
+mode can be used for converting floating-point numbers to integers.
+The rounding mode @samp{roundTiesToAway} rounds the result to the
+nearest number and selects the number with the larger magnitude
+if a tie occurs.
+
+Some numerical analysts will tell you that your choice of rounding style
+has tremendous impact on the final outcome, and advise you to wait until
+final output for any rounding. Instead, you can often achieve this goal by
+setting the precision initially to some value sufficiently larger than
+the final desired precision, so that the accumulation of round-off error
+does not influence the outcome.
+If you suspect that results from your computation are
+sensitive to accumulation of round-off error,
+one way to be sure is to look for a significant difference in output
+when you change the rounding mode.
+
+@node Arbitrary Precision Floats
+@section Arbitrary Precision Floating-point Arithmetic with @command{gawk}
+
+@command{gawk} uses the GNU MPFR library
+for arbitrary precision floating-point arithmetic. The MPFR library
+provides precise control over precisions and rounding modes, and gives
+correctly rounded reproducible platform-independent results. With the
+command-line option @option{--bignum} or @option{-M},
+all floating-point arithmetic operators and numeric functions can yield
+results to any desired precision level supported by MPFR.
+Two built-in
+variables @code{PREC}
+(@pxref{Setting Precision})
+and @code{ROUNDMODE}
+(@pxref{Setting Rounding Mode})
+provide control over the working precision and the rounding mode.
+The precision and the rounding mode are set globally for every operation
+to follow.
+
+The default working precision for arbitrary precision floats is 53,
+and the default value for @code{ROUNDMODE} is @code{"N"},
+which selects the IEEE-754
+@samp{roundTiesToEven} (@pxref{Rounding Mode}) rounding mode.@footnote{The
+default precision is 53, since according to the MPFR documentation,
+the library should be able to exactly reproduce all computations with
+double-precision machine floating-point numbers (@code{double} type
+in C), except the default exponent range is much wider and subnormal
+numbers are not implemented.}
+@command{gawk} uses the default exponent range in MPFR
+@iftex
+(@math{emax = 2^{30} - 1, emin = -emax})
+@end iftex
+@ifnottex
+(@var{emax} = 2^30 @minus{} 1, @var{emin} = @minus{}@var{emax})
+@end ifnottex
+for all floating-point contexts.
+There is no explicit mechanism to adjust the exponent range.
+MPFR does not implement subnormal numbers by default,
+and this behavior cannot be changed in @command{gawk}.
+
+@quotation NOTE
+When emulating an IEEE-754 format (@pxref{Setting Precision}),
+@command{gawk} internally adjusts the exponent range
+to the value defined for the format and also performs computations needed for
+gradual underflow (subnormal numbers).
+@end quotation
+
+@quotation NOTE
+MPFR numbers are variable-size entities, consuming only as much space as
+needed to store the significant digits. Since the performance using MPFR
+numbers pales in comparison to doing math using the underlying machine
+types, you should consider using only as much precision as needed by
+your program.
+@end quotation
+
+@node Setting Precision
+@section Setting the Working Precision
+@cindex @code{PREC} variable
+
+@command{gawk} uses a global working precision; it does not keep track of
+the precision or accuracy of individual numbers. Performing an arithmetic
+operation or calling a built-in function rounds the result to the current
+working precision. The default working precision is 53 which can be
+modified using the built-in variable @code{PREC}. You can also set the
+value to one of the following pre-defined case-insensitive strings
+to emulate an IEEE-754 binary format:
+
+@multitable {@code{"double"}} {12345678901234567890123456789012345}
+@headitem @code{PREC} @tab IEEE-754 Binary Format
+@item @code{"half"} @tab 16-bit half-precision.
+@item @code{"single"} @tab Basic 32-bit single precision.
+@item @code{"double"} @tab Basic 64-bit double precision.
+@item @code{"quad"} @tab Basic 128-bit quadruple precision.
+@item @code{"oct"} @tab 256-bit octuple precision.
+@end multitable
+
+The following example illustrates the effects of changing precision
+on arithmetic operations:
+
+@example
+$ @kbd{gawk -M -vPREC=100 'BEGIN @{ x = 1.0e-400; print x + 0; \}
+> @kbd{PREC = "double"; print x + 0 @}'}
+@print{} 1e-400
+@print{} 0
+@end example
+
+Binary and decimal precisions are related approximately according to the
+formula:
+
+@iftex
+@math{prec = 3.322 @cdot dps}
+@end iftex
+@ifnottex
+@var{prec} = 3.322 * @var{dps}
+@end ifnottex
+
+@noindent
+Here, @var{prec} denotes the binary precision
+(measured in bits) and @var{dps} (short for decimal places)
+is the decimal digits. We can easily calculate how many decimal
+digits the 53-bit significand of an IEEE double is equivalent to:
+53 / 3.332 which is equal to about 15.95.
+But what does 15.95 digits actually mean? It depends whether you are
+concerned about how many digits you can rely on, or how many digits
+you need.
+
+It is important to know how many bits it takes to uniquely identify
+a double-precision value (the C type @code{double}). If you want to
+convert from @code{double} to decimal and back to @code{double} (e.g.,
+saving a @code{double} representing an intermediate result to a file, and
+later reading it back to restart the computation), then a few more decimal
+digits are required. 17 digits is generally enough for a @code{double}.
+
+It can also be important to know what decimal numbers can be uniquely
+represented with a @code{double}. If you want to convert
+from decimal to @code{double} and back again, 15 digits is the most that
+you can get. Stated differently, you should not present
+the numbers from your floating-point computations with more than 15
+significant digits in them.
+
+Conversely, it takes a precision of 332 bits to hold an approximation
+of constant @value{PI} that is accurate to 100 decimal places.
+You should always add some extra bits in order to avoid the confusing round-off
+issues that occur because numbers are stored internally in binary.
+
+@node Setting Rounding Mode
+@section Setting the Rounding Mode
+@cindex @code{ROUNDMODE} variable
+
+The built-in variable @code{ROUNDMODE} has the default value @code{"N"},
+which selects the IEEE-754 rounding mode @samp{roundTiesToEven}.
+The other possible values for @code{ROUNDMODE} are @code{"U"} for rounding mode
+@samp{roundTowardPositive}, @code{"D"} for @samp{roundTowardNegative},
+and @code{"Z"} for @samp{roundTowardZero}.
+@command{gawk} also accepts @code{"A"} to select the IEEE-754 mode
+@samp{roundTiesToAway}
+if your version of the MPFR library supports it; otherwise setting
+@code{ROUNDMODE} to this value has no effect. @xref{Rounding Mode},
+for the meanings of the various rounding modes.
+
+Here is an example of how to change the default rounding behavior of
+@code{printf}'s output:
+
+@example
+$ @kbd{gawk -M -vROUNDMODE="Z" 'BEGIN @{ printf("%.2f\n", 1.378) @}'}
+@print{} 1.37
+@end example
+
+@node Floating-point Constants
+@section Representing Floating-point Constants
+@cindex constants, floating-point
+
+Be wary of floating-point constants! When reading a floating-point constant
+from program source code, @command{gawk} uses the default precision,
+unless overridden
+by an assignment to the special variable @code{PREC} on the command
+line, to store it internally as a MPFR number.
+Changing the precision using @code{PREC} in the program text does
+not change the precision of a constant. If you need to
+represent a floating-point constant at a higher precision than the
+default and cannot use a command line assignment to @code{PREC},
+you should either specify the constant as a string, or
+a rational number whenever possible. The following example
+illustrates the differences among various ways to
+print a floating-point constant:
+
+@example
+$ @kbd{gawk -M 'BEGIN @{ PREC = 113; printf("%0.25f\n", 0.1) @}'}
+@print{} 0.1000000000000000055511151
+$ @kbd{gawk -M -vPREC = 113 'BEGIN @{ printf("%0.25f\n", 0.1) @}'}
+@print{} 0.1000000000000000000000000
+$ @kbd{gawk -M 'BEGIN @{ PREC = 113; printf("%0.25f\n", "0.1") @}'}
+@print{} 0.1000000000000000000000000
+$ @kbd{gawk -M 'BEGIN @{ PREC = 113; printf("%0.25f\n", 1/10) @}'}
+@print{} 0.1000000000000000000000000
+@end example
+
+In the first case, the number is stored with the default precision of 53.
+
+@node Changing Precision
+@section Changing the Precision of a Number
+
+@cindex Laurie, Dirk
+@quotation
+@i{The point is that in any variable-precision package,
+a decision is made on how to treat numbers given as data,
+or arising in intermediate results, which are represented in
+floating-point format to a precision lower than working precision.
+Do we promote them to full membership of the high-precision club,
+or do we treat them and all their associates as second-class citizens?
+Sometimes the first course is proper, sometimes the second, and it takes
+careful analysis to tell which.}
+
+Dirk Laurie@footnote{Dirk Laurie.
+@cite{Variable-precision Arithmetic Considered Perilous -- A Detective Story}.
+Electronic Transactions on Numerical Analysis. Volume 28, pp. 168-173, 2008.}
+@end quotation
+
+@command{gawk} does not implicitly modify the precision of any previously
+computed results when the working precision is changed with an assignment
+to @code{PREC}. The precision of a number is always the one that was
+used at the time of its creation, and there is no way for the user
+to explicitly change it afterwards. However, since the result of a
+floating-point arithmetic operation is always an arbitrary precision
+floating-point value---with a precision set by the value of @code{PREC}---one of the
+following workarounds effectively accomplishes the desired behavior:
+
+@example
+x = x + 0.0
+@end example
+
+@noindent
+or:
+
+@example
+x += 0.0
+@end example
+
+@node Exact Arithmetic
+@section Exact Arithmetic with Floating-point Numbers
+
+@quotation CAUTION
+Never depend on the exactness of floating-point arithmetic,
+even for apparently simple expressions!
+@end quotation
+
+Can arbitrary precision arithmetic give exact results? There are
+no easy answers. The standard rules of algebra often do not apply
+when using floating-point arithmetic.
+Among other things, the distributive and associative laws
+do not hold completely, and order of operation may be important
+for your computation. Rounding error, cumulative precision loss
+and underflow are often troublesome.
+
+When @command{gawk} tests the expressions @samp{0.1 + 12.2} and @samp{12.3}
+for equality
+using the machine double precision arithmetic, it decides that they
+are not equal!
+(@xref{Floating-point Programming}.)
+You can get the result you want by increasing the precision;
+56 in this case will get the job done:
+
+@example
+$ @kbd{gawk -M -vPREC=56 'BEGIN @{ print (0.1 + 12.2 == 12.3) @}'}
+@print{} 1
+@end example
+
+If adding more bits is good, perhaps adding even more bits of
+precision is better?
+Here is what happens if we use an even larger value of @code{PREC}:
+
+@example
+$ @kbd{gawk -M -vPREC=201 'BEGIN @{ print (0.1 + 12.2 == 12.3) @}'}
+@print{} 0
+@end example
+
+This is not a bug in @command{gawk} or in the MPFR library.
+It is easy to forget that the finite number of bits used to store the value
+is often just an approximation after proper rounding.
+The test for equality succeeds if and only if @emph{all} bits in the two operands
+are exactly the same. Since this is not necessarily true after floating-point
+computations with a particular precision and effective rounding rule,
+a straight test for equality may not work.
+
+So, don't assume that floating-point values can be compared for equality.
+You should also exercise caution when using other forms of comparisons.
+The standard way to compare between floating-point numbers is to determine
+how much error (or @dfn{tolerance}) you will allow in a comparison and
+check to see if one value is within this error range of the other.
+
+In applications where 15 or fewer decimal places suffice,
+hardware double precision arithmetic can be adequate, and is usually much faster.
+But you do need to keep in mind that every floating-point operation
+can suffer a new rounding error with catastrophic consequences as illustrated
+by our attempt to compute the value of the constant @value{PI},
+(@pxref{Floating-point Programming}).
+Extra precision can greatly enhance the stability and the accuracy
+of your computation in such cases.
+
+Repeated addition is not necessarily equivalent to multiplication
+in floating-point arithmetic. In the last example
+(@pxref{Floating-point Programming}),
+you may or may not succeed in getting the correct result by choosing
+an arbitrarily large value for @code{PREC}. Reformulation of
+the problem at hand is often the correct approach in such situations.
+
+
+@node Integer Programming
+@section Effective Integer Programming
+
+As has been mentioned already, @command{gawk} ordinarily uses hardware double
+precision with 64-bit IEEE binary floating-point representation
+for numbers on most systems. A large integer like 9007199254740997
+has a binary representation that, although finite, is more than 53 bits long;
+it must also be rounded to 53 bits.
+The biggest integer that can be stored in a C @code{double} is usually the same
+as the largest possible value of a @code{double}. If your system @code{double}
+is an IEEE 64-bit @code{double}, this largest possible value is an integer and
+can be represented precisely. What more should one know about integers?
+
+If you want to know what is the largest integer, such that it and
+all smaller integers can be stored in 64-bit doubles without losing precision,
+then the answer is
+@iftex
+@math{2^{53}}.
+@end iftex
+@ifnottex
+2^53.
+@end ifnottex
+The next representable number is the even number
+@iftex
+@math{2^{53} + 2},
+@end iftex
+@ifnottex
+2^53 + 2,
+@end ifnottex
+meaning it is unlikely that you will be able to make
+@command{gawk} print
+@iftex
+@math{2^{53} + 1}
+@end iftex
+@ifnottex
+2^53 + 1
+@end ifnottex
+in integer format.
+The range of integers exactly representable by a 64-bit double
+is
+@iftex
+@math{[-2^{53}, 2^{53}]}.
+@end iftex
+@ifnottex
+[@minus{}2^53, 2^53].
+@end ifnottex
+If you ever see an integer outside this range in @command{gawk}
+using 64-bit doubles, you have reason to be very suspicious about
+the accuracy of the output. Here is a simple program with erroneous output:
+
+@example
+$ @kbd{gawk 'BEGIN @{ i = 2^53 - 1; for (j = 0; j < 4; j++) print i + j @}'}
+@print{} 9007199254740991
+@print{} 9007199254740992
+@print{} 9007199254740992
+@print{} 9007199254740994
+@end example
+
+The lesson is to not assume that any large integer printed by @command{gawk}
+represents an exact result from your computation, especially if it wraps
+around on your screen.
+
+@node Arbitrary Precision Integers
+@section Arbitrary Precision Integer Arithmetic with @command{gawk}
+@cindex integer, arbitrary precision
+
+If the option @option{--bignum} or @option{-M} is specified,
+@command{gawk} performs all
+integer arithmetic using GMP arbitrary precision integers.
+Any number that looks like an integer in a program source or data file
+is stored as an arbitrary precision integer.
+The size of the integer is limited only by your computer's memory.
+The current floating-point context has no effect on operations involving integers.
+For example, the following computes
+@iftex
+@math{5^{4^{3^{2}}}},
+@end iftex
+@ifnottex
+5^4^3^2,
+@end ifnottex
+the result of which is beyond the
+limits of ordinary @command{gawk} numbers:
+
+@example
+$ @kbd{gawk -M 'BEGIN @{}
+> @kbd{x = 5^4^3^2}
+> @kbd{print "# of digits =", length(x)}
+> @kbd{print substr(x, 1, 20), "...", substr(x, length(x) - 19, 20)}
+> @kbd{@}'}
+@print{} # of digits = 183231
+@print{} 62060698786608744707 ... 92256259918212890625
+@end example
+
+If you were to compute the same value using arbitrary precision
+floating-point values instead, the precision needed for correct output
+(using the formula
+@iftex
+@math{prec = 3.322 @cdot dps}),
+would be @math{3.322 @cdot 183231},
+@end iftex
+@ifnottex
+@samp{prec = 3.322 * dps}),
+would be 3.322 x 183231,
+@end ifnottex
+or 608693.
+
+The result from an arithmetic operation with an integer and a floating-point value
+is a floating-point value with a precision equal to the working precision.
+The following program calculates the eighth term in
+Sylvester's sequence@footnote{Weisstein, Eric W.
+@cite{Sylvester's Sequence}. From MathWorld--A Wolfram Web Resource.
+@url{http://mathworld.wolfram.com/SylvestersSequence.html}}
+using a recurrence:
+
+@example
+$ @kbd{gawk -M 'BEGIN @{}
+> @kbd{s = 2.0}
+> @kbd{for (i = 1; i <= 7; i++)}
+> @kbd{s = s * (s - 1) + 1}
+> @kbd{print s}
+> @kbd{@}'}
+@print{} 113423713055421845118910464
+@end example
+
+The output differs from the acutal number, 113423713055421844361000443,
+because the default precision of 53 is not enough to represent the
+floating-point results exactly. You can either increase the precision
+(100 is enough in this case), or replace the floating-point constant
+@code{2.0} with an integer, to perform all computations using integer
+arithmetic to get the correct output.
+
+It will sometimes be necessary for @command{gawk} to implicitly convert an
+arbitrary precision integer into an arbitrary precision floating-point value.
+This is primarily because the MPFR library does not always provide the
+relevant interface to process arbitrary precision integers or mixed-mode
+numbers as needed by an operation or function.
+In such a case, the precision is set to the minimum value necessary
+for exact conversion, and the working precision is not used for this purpose.
+If this is not what you need or want, you can employ a subterfuge
+like this:
+
+@example
+gawk -M 'BEGIN @{ n = 13; print (n + 0.0) % 2.0 @}'
+@end example
+
+You can avoid this issue altogether by specifying the number as a float
+to begin with:
+
+@example
+gawk -M 'BEGIN @{ n = 13.0; print n % 2.0 @}'
+@end example
+
+Note that for the particular example above, there is unlikely to be a
+reason for simply not using the following:
+
+@example
+gawk -M 'BEGIN @{ n = 13; print n % 2 @}'
+@end example
+
+
+@node MPFR and GMP Libraries
+@section Information About the MPFR and GMP Libraries
+
+There are a few elements available in the @code{PROCINFO} array
+to provide information about the MPFR and GMP libraries.
+@xref{Auto-set}, for more information.
+
@node Advanced Features
@chapter Advanced Features of @command{gawk}
@cindex advanced features, network connections, See Also networks, connections
@@ -18967,40 +20021,32 @@ extensive examples.
@cindex @command{awk} programs, profiling
@c STARTOFRANGE proawk
@cindex profiling @command{awk} programs
-@c STARTOFRANGE pgawk
-@cindex @command{pgawk} program
-@cindex profiling @command{gawk}, See @command{pgawk} program
-
-You may produce execution
-traces of your @command{awk} programs.
-This is done with a specially compiled version of @command{gawk},
-called @command{pgawk} (``profiling @command{gawk}'').
-
+@cindex profiling @command{gawk}
@cindex @code{awkprof.out} file
@cindex files, @code{awkprof.out}
-@cindex @command{pgawk} program, @code{awkprof.out} file
-@command{pgawk} is identical in every way to @command{gawk}, except that when
-it has finished running, it creates a profile of your program in a file
-named @file{awkprof.out}.
-Because it is profiling, it also executes up to 45% slower than
+
+You may produce execution traces of your @command{awk} programs.
+This is done by passing the option @option{--profile} to @command{gawk}.
+When @command{gawk} has finished running, it creates a profile of your program in a file
+named @file{awkprof.out}. Because it is profiling, it also executes up to 45% slower than
@command{gawk} normally does.
@cindex @code{--profile} option
As shown in the following example,
the @option{--profile} option can be used to change the name of the file
-where @command{pgawk} will write the profile:
+where @command{gawk} will write the profile:
@example
-pgawk --profile=myprog.prof -f myprog.awk data1 data2
+gawk --profile=myprog.prof -f myprog.awk data1 data2
@end example
@noindent
-In the above example, @command{pgawk} places the profile in
+In the above example, @command{gawk} places the profile in
@file{myprog.prof} instead of in @file{awkprof.out}.
-Here is a sample
-session showing a simple @command{awk} program, its input data, and the
-results from running @command{pgawk}. First, the @command{awk} program:
+Here is a sample session showing a simple @command{awk} program, its input data, and the
+results from running @command{gawk} with the @option{--profile} option.
+First, the @command{awk} program:
@example
BEGIN @{ print "First BEGIN rule" @}
@@ -19040,12 +20086,12 @@ foo
junk
@end example
-Here is the @file{awkprof.out} that results from running @command{pgawk}
-on this program and data (this example also illustrates that @command{awk}
+Here is the @file{awkprof.out} that results from running the @command{gawk}
+profiler on this program and data (this example also illustrates that @command{awk}
programmers sometimes have to work late):
-@cindex @code{BEGIN} pattern, @command{pgawk} program
-@cindex @code{END} pattern, @command{pgawk} program
+@cindex @code{BEGIN} pattern
+@cindex @code{END} pattern
@example
# gawk profile, created Sun Aug 13 00:00:15 2000
@@ -19137,15 +20183,15 @@ keyword indicates how many times the function was called.
The counts next to the statements in the body show how many times
those statements were executed.
-@cindex @code{@{@}} (braces), @command{pgawk} program
-@cindex braces (@code{@{@}}), @command{pgawk} program
+@cindex @code{@{@}} (braces)
+@cindex braces (@code{@{@}})
@item
The layout uses ``K&R'' style with TABs.
Braces are used everywhere, even when
the body of an @code{if}, @code{else}, or loop is only a single statement.
-@cindex @code{()} (parentheses), @command{pgawk} program
-@cindex parentheses @code{()}, @command{pgawk} program
+@cindex @code{()} (parentheses)
+@cindex parentheses @code{()}
@item
Parentheses are used only where needed, as indicated by the structure
of the program and the precedence rules.
@@ -19168,16 +20214,16 @@ Similarly, if
the target of a redirection isn't a scalar, it gets parenthesized.
@item
-@command{pgawk} supplies leading comments in
+@command{gawk} supplies leading comments in
front of the @code{BEGIN} and @code{END} rules,
the pattern/action rules, and the functions.
@end itemize
The profiled version of your program may not look exactly like what you
-typed when you wrote it. This is because @command{pgawk} creates the
+typed when you wrote it. This is because @command{gawk} creates the
profiled version by ``pretty printing'' its internal representation of
-the program. The advantage to this is that @command{pgawk} can produce
+the program. The advantage to this is that @command{gawk} can produce
a standard representation. The disadvantage is that all source-code
comments are lost, as are the distinctions among multiple @code{BEGIN},
@code{END}, @code{BEGINFILE}, and @code{ENDFILE} rules. Also, things such as:
@@ -19199,15 +20245,16 @@ come out as:
which is correct, but possibly surprising.
@cindex profiling @command{awk} programs, dynamically
-@cindex @command{pgawk} program, dynamic profiling
+@cindex @command{gawk} program, dynamic profiling
Besides creating profiles when a program has completed,
-@command{pgawk} can produce a profile while it is running.
+@command{gawk} can produce a profile while it is running.
This is useful if your @command{awk} program goes into an
infinite loop and you want to see what has been executed.
-To use this feature, run @command{pgawk} in the background:
+To use this feature, run @command{gawk} with the @option{--profile}
+option in the background:
@example
-$ @kbd{pgawk -f myprog &}
+$ @kbd{gawk --profile -f myprog &}
[1] 13992
@end example
@@ -19218,7 +20265,7 @@ $ @kbd{pgawk -f myprog &}
@noindent
The shell prints a job number and process ID number; in this case, 13992.
Use the @command{kill} command to send the @code{USR1} signal
-to @command{pgawk}:
+to @command{gawk}:
@example
$ @kbd{kill -USR1 13992}
@@ -19226,8 +20273,8 @@ $ @kbd{kill -USR1 13992}
@noindent
As usual, the profiled version of the program is written to
-@file{awkprof.out}, or to a different file if you use the @option{--profile}
-option.
+@file{awkprof.out}, or to a different file if one specified with
+the @option{--profile} option.
Along with the regular profile, as shown earlier, the profile
includes a trace of any active functions:
@@ -19241,7 +20288,7 @@ includes a trace of any active functions:
# -- main --
@end example
-You may send @command{pgawk} the @code{USR1} signal as many times as you like.
+You may send @command{gawk} the @code{USR1} signal as many times as you like.
Each time, the profile and function call trace are appended to the output
profile file.
@@ -19249,7 +20296,7 @@ profile file.
@cindex @code{SIGHUP} signal
@cindex signals, @code{HUP}/@code{SIGHUP}
If you use the @code{HUP} signal instead of the @code{USR1} signal,
-@command{pgawk} produces the profile and the function call trace and then exits.
+@command{gawk} produces the profile and the function call trace and then exits.
@cindex @code{INT} signal (MS-Windows)
@cindex @code{SIGINT} signal (MS-Windows)
@@ -19257,21 +20304,20 @@ If you use the @code{HUP} signal instead of the @code{USR1} signal,
@cindex @code{QUIT} signal (MS-Windows)
@cindex @code{SIGQUIT} signal (MS-Windows)
@cindex signals, @code{QUIT}/@code{SIGQUIT} (MS-Windows)
-When @command{pgawk} runs on MS-Windows systems, it uses the
+When @command{gawk} runs on MS-Windows systems, it uses the
@code{INT} and @code{QUIT} signals for producing the profile and, in
-the case of the @code{INT} signal, @command{pgawk} exits. This is
+the case of the @code{INT} signal, @command{gawk} exits. This is
because these systems don't support the @command{kill} command, so the
only signals you can deliver to a program are those generated by the
keyboard. The @code{INT} signal is generated by the
@kbd{@value{CTL}-@key{C}} or @kbd{@value{CTL}-@key{BREAK}} key, while the
@code{QUIT} signal is generated by the @kbd{@value{CTL}-@key{\}} key.
-Finally, regular @command{gawk} also accepts the @option{--profile} option.
+Finally, @command{gawk} also accepts another option @option{--pretty-print}.
When called this way, @command{gawk} ``pretty prints'' the program into
@file{awkprof.out}, without any execution counts.
@c ENDOFRANGE advgaw
@c ENDOFRANGE gawadv
-@c ENDOFRANGE pgawk
@c ENDOFRANGE awkp
@c ENDOFRANGE proawk
@@ -25153,41 +26199,41 @@ BEGIN {
@c FIXME: Add more indexing.
@node Debugger
-@chapter @command{dgawk}: The @command{awk} Debugger
-@cindex @command{dgawk}
+@chapter Debugging @command{awk} Programs
+@cindex debugging @command{awk} programs
It would be nice if computer programs worked perfectly the first time they
were run, but in real life, this rarely happens for programs of
any complexity. Thus, most programming languages have facilities available
for ``debugging'' programs, and now @command{awk} is no exception.
-The @command{dgawk} debugger is purposely modeled after
+The @command{gawk} debugger is purposely modeled after
@uref{http://www.gnu.org/software/gdb/, the GNU Debugger (GDB)}
command-line debugger. If you are familiar with GDB, learning
-@command{dgawk} is easy.
+how to use @command{gawk} for debugging your program is easy.
@menu
-* Debugging:: Introduction to @command{dgawk}.
-* Sample dgawk session:: Sample @command{dgawk} session.
-* List of Debugger Commands:: Main @command{dgawk} Commands.
-* Readline Support:: Readline Support.
-* Dgawk Limitations:: Limitations and future plans.
+* Debugging:: Introduction to @command{gawk} debugger.
+* Sample Debugging Session:: Sample debugging session.
+* List of Debugger Commands:: Main debugger commands.
+* Readline Support:: Readline support.
+* Limitations:: Limitations and future plans.
@end menu
@node Debugging
-@section Introduction to @command{dgawk}
+@section Introduction to @command{gawk} Debugger
This @value{SECTION} introduces debugging in general and begins
the discussion of debugging in @command{gawk}.
@menu
-* Debugging Concepts:: Debugging In General.
+* Debugging Concepts:: Debugging in General.
* Debugging Terms:: Additional Debugging Concepts.
* Awk Debugging:: Awk Debugging.
@end menu
@node Debugging Concepts
-@subsection Debugging In General
+@subsection Debugging in General
(If you have used debuggers in other languages, you may want to skip
ahead to the next section on the specific features of the @command{awk}
@@ -25233,8 +26279,7 @@ functional program that you or someone else wrote).
@subsection Additional Debugging Concepts
Before diving in to the details, we need to introduce several
-important concepts that apply to just about all debuggers, including
-@command{dgawk}.
+important concepts that apply to just about all debuggers.
The following list defines terms used throughout the rest of
this @value{CHAPTER}.
@@ -25253,7 +26298,7 @@ that contains the function's parameters, local variables, and return value,
as well as any other ``bookkeeping'' information needed to manage the
call stack. This data area is termed a @dfn{stack frame}.
-@command{gawk} also follows this model, and @command{dgawk} gives you
+@command{gawk} also follows this model, and gives you
access to the call stack and to each stack frame. You can see the
call stack, as well as from where each function on the stack was
invoked. Commands that print the call stack print information about
@@ -25298,48 +26343,48 @@ each line of @command{awk} code. The debugger provides the opportunity
to look at the individual primitive instructions carried out
by the higher-level @command{awk} commands.
-@node Sample dgawk session
-@section Sample @command{dgawk} session
+@node Sample Debugging Session
+@section Sample Debugging Session
-In order to illustrate the use of @command{dgawk}, let's look at a sample
+In order to illustrate the use of @command{gawk} as a debugger, let's look at a sample
debugging session. We will use the @command{awk} implementation of the
POSIX @command{uniq} command described earlier (@pxref{Uniq Program})
as our example.
@menu
-* dgawk invocation:: @command{dgawk} Invocation.
-* Finding The Bug:: Finding The Bug.
+* Debugger Invocation:: How to Start the Debugger.
+* Finding The Bug:: Finding the Bug.
@end menu
-@node dgawk invocation
-@subsection @command{dgawk} Invocation
+@node Debugger Invocation
+@subsection How to Start the Debugger
-Starting @command{dgawk} is exactly like running @command{awk}. The
-file(s) containing the program and any supporting code are given on the
-command line as arguments to one or more @option{-f} options.
-(@command{dgawk} is not designed to debug command-line
-programs, only programs contained in files.) In our case,
-we call @command{dgawk} like this:
+Starting the debugger is almost exactly like running @command{awk}, except you have to
+pass an additional option @option{--debug} or the corresponding short option @option{-D}.
+The file(s) containing the program and any supporting code are given on the command
+line as arguments to one or more @option{-f} options. (@command{gawk} is not designed
+to debug command-line programs, only programs contained in files.) In our case,
+we invoke the debugger like this:
@example
-$ @kbd{dgawk -f getopt.awk -f join.awk -f uniq.awk inputfile}
+$ @kbd{gawk -D -f getopt.awk -f join.awk -f uniq.awk inputfile}
@end example
@noindent
where both @file{getopt.awk} and @file{uniq.awk} are in @env{$AWKPATH}.
(Experienced users of GDB or similar debuggers should note that
this syntax is slightly different from what they are used to.
-With @command{dgawk}, the arguments for running the program are given
+With @command{gawk} debugger, the arguments for running the program are given
in the command line to the debugger rather than as part of the @code{run}
command at the debugger prompt.)
Instead of immediately running the program on @file{inputfile}, as
-@command{gawk} would ordinarily do, @command{dgawk} merely loads all
+@command{gawk} would ordinarily do, the debugger merely loads all
the program source files, compiles them internally, and then gives
us a prompt:
@example
-dgawk>
+gawk>
@end example
@noindent
@@ -25347,7 +26392,7 @@ from which we can issue commands to the debugger. At this point, no
code has been executed.
@node Finding The Bug
-@subsection Finding The Bug
+@subsection Finding the Bug
Let's say that we are having a problem using (a faulty version of)
@file{uniq.awk} in the ``field-skipping'' mode, and it doesn't seem to be
@@ -25383,7 +26428,7 @@ a breakpoint in @file{uniq.awk} is at the beginning of the function
the breakpoint, use the @code{b} (breakpoint) command:
@example
-dgawk> @kbd{b are_equal}
+gawk> @kbd{b are_equal}
@print{} Breakpoint 1 set at file `awklib/eg/prog/uniq.awk', line 64
@end example
@@ -25392,22 +26437,22 @@ Now type @samp{r} or @samp{run} and the program runs until it hits
the breakpoint for the first time:
@example
-dgawk> @kbd{r}
+gawk> @kbd{r}
@print{} Starting program:
@print{} Stopping in Rule ...
@print{} Breakpoint 1, are_equal(n, m, clast, cline, alast, aline)
at `awklib/eg/prog/uniq.awk':64
@print{} 64 if (fcount == 0 && charcount == 0)
-dgawk>
+gawk>
@end example
Now we can look at what's going on inside our program. First of all,
let's see how we got to where we are. At the prompt, we type @samp{bt}
-(short for ``backtrace''), and @command{dgawk} responds with a
+(short for ``backtrace''), and the debugger responds with a
listing of the current stack frames:
@example
-dgawk> @kbd{bt}
+gawk> @kbd{bt}
@print{} #0 are_equal(n, m, clast, cline, alast, aline)
at `awklib/eg/prog/uniq.awk':69
@print{} #1 in main() at `awklib/eg/prog/uniq.awk':89
@@ -25422,11 +26467,11 @@ the key to finding the source of the problem.)
Now that we're in @code{are_equal()}, we can start looking at the values
of some variables. Let's say we type @samp{p n}
(@code{p} is short for ``print''). We would expect to see the value of
-@code{n}, a parameter to @code{are_equal()}. Actually, @command{dgawk}
+@code{n}, a parameter to @code{are_equal()}. Actually, the debugger
gives us:
@example
-dgawk> @kbd{p n}
+gawk> @kbd{p n}
@print{} n = untyped variable
@end example
@@ -25437,7 +26482,7 @@ function was called without arguments (@pxref{Function Calls}).
A more useful variable to display might be the current record:
@example
-dgawk> @kbd{p $0}
+gawk> @kbd{p $0}
@print{} $0 = string ("gawk is a wonderful program!")
@end example
@@ -25446,7 +26491,7 @@ This might be a bit puzzling at first since this is the second line of
our test input above. Let's look at @code{NR}:
@example
-dgawk> @kbd{p NR}
+gawk> @kbd{p NR}
@print{} NR = number (2)
@end example
@@ -25465,7 +26510,7 @@ NR == 1 @{
OK, let's just check that that rule worked correctly:
@example
-dgawk> @kbd{p last}
+gawk> @kbd{p last}
@print{} last = string ("awk is a wonderful program!")
@end example
@@ -25476,7 +26521,7 @@ be inside this function. To investigate further, we must begin
@samp{n} (for ``next''):
@example
-dgawk> @kbd{n}
+gawk> @kbd{n}
@print{} 67 if (fcount > 0) @{
@end example
@@ -25496,9 +26541,9 @@ Continuing to step, we now get to the splitting of the current and
last records:
@example
-dgawk> @kbd{n}
+gawk> @kbd{n}
@print{} 68 n = split(last, alast)
-dgawk> @kbd{n}
+gawk> @kbd{n}
@print{} 69 m = split($0, aline)
@end example
@@ -25506,7 +26551,7 @@ At this point, we should be curious to see what our records were split
into, so we try to look:
@example
-dgawk> @kbd{p n m alast aline}
+gawk> @kbd{p n m alast aline}
@print{} n = number (5)
@print{} m = number (5)
@print{} alast = array, 5 elements
@@ -25525,7 +26570,7 @@ inside the array?
The first choice would be to use subscripts:
@example
-dgawk> @kbd{p alast[0]}
+gawk> @kbd{p alast[0]}
@print{} "0" not in array `alast'
@end example
@@ -25533,16 +26578,16 @@ dgawk> @kbd{p alast[0]}
Oops!
@example
-dgawk> @kbd{p alast[1]}
+gawk> @kbd{p alast[1]}
@print{} alast["1"] = string ("awk")
@end example
This would be kind of slow for a 100-member array, though, so
-@command{dgawk} provides a shortcut (reminiscent of another language
+@command{gawk} provides a shortcut (reminiscent of another language
not to be mentioned):
@example
-dgawk> @kbd{p @@alast}
+gawk> @kbd{p @@alast}
@print{} alast["1"] = string ("awk")
@print{} alast["2"] = string ("is")
@print{} alast["3"] = string ("a")
@@ -25554,9 +26599,9 @@ It looks like we got this far OK. Let's take another step
or two:
@example
-dgawk> @kbd{n}
+gawk> @kbd{n}
@print{} 70 clast = join(alast, fcount, n)
-dgawk> @kbd{n}
+gawk> @kbd{n}
@print{} 71 cline = join(aline, fcount, m)
@end example
@@ -25566,7 +26611,7 @@ the virtual record to compare, and if the first field was numbered zero,
this would work. Let's look at what we've got:
@example
-dgawk> @kbd{p cline clast}
+gawk> @kbd{p cline clast}
@print{} cline = string ("gawk is a wonderful program!")
@print{} clast = string ("awk is a wonderful program!")
@end example
@@ -25575,10 +26620,10 @@ Hey, those look pretty familiar! They're just our original, unaltered,
input records. A little thinking (the human brain is still the best
debugging tool), and we realize that we were off by one!
-We get out of @command{dgawk}:
+We get out of the debugger:
@example
-dgawk> @kbd{q}
+gawk> @kbd{q}
@print{} The program is running. Exit anyway (y/n)? @kbd{y}
@end example
@@ -25594,9 +26639,9 @@ cline = join(aline, fcount+1, m)
and problem solved!
@node List of Debugger Commands
-@section Main @command{dgawk} Commands
+@section Main Debugger Commands
-The @command{dgawk} command set can be divided into the
+The @command{gawk} debugger command set can be divided into the
following categories:
@itemize @bullet{}
@@ -25623,24 +26668,24 @@ Miscellaneous
Each of these are discussed in the following subsections.
In the following descriptions, commands which may be abbreviated
show the abbreviation on a second description line.
-A @command{dgawk} command name may also be truncated if that partial
-name is unambiguous. @command{dgawk} has the built-in capability to
+A debugger command name may also be truncated if that partial
+name is unambiguous. The debugger has the built-in capability to
automatically repeat the previous command when just hitting @key{Enter}.
This works for the commands @code{list}, @code{next}, @code{nexti}, @code{step}, @code{stepi}
and @code{continue} executed without any argument.
@menu
-* Breakpoint Control:: Control of breakpoints.
-* Dgawk Execution Control:: Control of execution.
-* Viewing And Changing Data:: Viewing and changing data.
-* Dgawk Stack:: Dealing with the stack.
-* Dgawk Info:: Obtaining information about the program and
- the debugger state.
-* Miscellaneous Dgawk Commands:: Miscellaneous Commands.
+* Breakpoint Control:: Control of Breakpoints.
+* Debugger Execution Control:: Control of Execution.
+* Viewing And Changing Data:: Viewing and Changing Data.
+* Execution Stack:: Dealing with the Stack.
+* Debugger Info:: Obtaining Information about the Program and
+ the Debugger State.
+* Miscellaneous Debugger Commands:: Miscellaneous Commands.
@end menu
@node Breakpoint Control
-@subsection Control Of Breakpoints
+@subsection Control of Breakpoints
As we saw above, the first thing you probably want to do in a debugging
session is to get your breakpoints set up, since otherwise your program
@@ -25675,10 +26720,10 @@ Each breakpoint is assigned a number which can be used to delete it from
the breakpoint list using the @code{delete} command.
With a breakpoint, you may also supply a condition. This is an
-@command{awk} expression (enclosed in double quotes) that @command{dgawk}
+@command{awk} expression (enclosed in double quotes) that the debugger
evaluates whenever the breakpoint is reached. If the condition is true,
-then @command{dgawk} stops execution and prompts for a command. Otherwise,
-@command{dgawk} continues executing the program.
+then the debugger stops execution and prompts for a command. Otherwise,
+it continues executing the program.
@cindex debugger commands, @code{clear}
@cindex @code{clear} debugger command
@@ -25704,10 +26749,10 @@ Delete breakpoint(s) set at entry to function @var{function}.
@cindex @code{condition} debugger command
@item @code{condition} @var{n} @code{"@var{expression}"}
Add a condition to existing breakpoint or watchpoint @var{n}. The
-condition is an @command{awk} expression that @command{dgawk} evaluates
+condition is an @command{awk} expression that the debugger evaluates
whenever the breakpoint or watchpoint is reached. If the condition is true, then
-@command{dgawk} stops execution and prompts for a command. Otherwise,
-@command{dgawk} continues executing the program. If the condition expression is
+the debugger stops execution and prompts for a command. Otherwise,
+the debugger continues executing the program. If the condition expression is
not specified, any existing condition is removed; i.e., the breakpoint or
watchpoint is made unconditional.
@@ -25763,7 +26808,7 @@ Set a temporary breakpoint (enabled for only one stop).
The arguments are the same as for @code{break}.
@end table
-@node Dgawk Execution Control
+@node Debugger Execution Control
@subsection Control of Execution
Now that your breakpoints are ready, you can start running the program
@@ -25792,14 +26837,14 @@ in the list that resumes execution (e.g., @code{continue}) terminates the list
For example:
@example
-dgawk> @kbd{commands}
+gawk> @kbd{commands}
> @kbd{silent}
> @kbd{printf "A silent breakpoint; i = %d\n", i}
> @kbd{info locals}
> @kbd{set i = 10}
> @kbd{continue}
> @kbd{end}
-dgawk>
+gawk>
@end example
@cindex debugger commands, @code{c} (@code{continue})
@@ -25849,7 +26894,7 @@ and the caller of that frame becomes the innermost frame.
@cindex @code{r} debugger command (alias for @code{run})
@item @code{run}
@itemx @code{r}
-Start/restart execution of the program. When restarting, @command{dgawk}
+Start/restart execution of the program. When restarting, the debugger
retains the current breakpoints, watchpoints, command history,
automatic display variables, and debugger options.
@@ -25872,7 +26917,7 @@ stopping, unless it encounters a breakpoint or watchpoint.
@itemx @code{si} [@var{count}]
Execute one (or @var{count}) instruction(s), stepping inside function calls.
(For illustration of what is meant by an ``instruction'' in @command{gawk},
-see the output shown under @code{dump} in @ref{Miscellaneous Dgawk Commands}.)
+see the output shown under @code{dump} in @ref{Miscellaneous Debugger Commands}.)
@cindex debugger commands, @code{u} (@code{until})
@cindex debugger commands, @code{until}
@@ -25900,7 +26945,7 @@ The value of the variable or field is displayed each time the program stops.
Each variable added to the list is identified by a unique number:
@example
-dgawk> @kbd{display x}
+gawk> @kbd{display x}
@print{} 10: x = 1
@end example
@@ -25937,7 +26982,7 @@ Print the value of a @command{gawk} variable or field.
Fields must be referenced by constants:
@example
-dgawk> @kbd{print $3}
+gawk> @kbd{print $3}
@end example
@noindent
@@ -25979,16 +27024,16 @@ You can also set special @command{awk} variables, such as @code{FS},
@item @code{watch} @var{var} | @code{$}@var{n} [@code{"@var{expression}"}]
@itemx @code{w} @var{var} | @code{$}@var{n} [@code{"@var{expression}"}]
Add variable @var{var} (or field @code{$@var{n}}) to the watch list.
-@command{dgawk} then stops whenever
+The debugger then stops whenever
the value of the variable or field changes. Each watched item is assigned a
number which can be used to delete it from the watch list using the
@code{unwatch} command.
With a watchpoint, you may also supply a condition. This is an
-@command{awk} expression (enclosed in double quotes) that @command{dgawk}
+@command{awk} expression (enclosed in double quotes) that the debugger
evaluates whenever the watchpoint is reached. If the condition is true,
-then @command{dgawk} stops execution and prompts for a command. Otherwise,
-@command{dgawk} continues executing the program.
+then the debugger stops execution and prompts for a command. Otherwise,
+@command{gawk} continues executing the program.
@cindex debugger commands, @code{undisplay}
@cindex @code{undisplay} debugger command
@@ -26004,8 +27049,8 @@ watch list.
@end table
-@node Dgawk Stack
-@subsection Dealing With The Stack
+@node Execution Stack
+@subsection Dealing with the Stack
Whenever you run a program which contains any function calls,
@command{gawk} maintains a stack of all of the function calls leading up
@@ -26049,12 +27094,12 @@ Move @var{count} (default 1) frames up the stack toward the outermost frame.
Then select and print the frame.
@end table
-@node Dgawk Info
-@subsection Obtaining Information About The Program and The Debugger State
+@node Debugger Info
+@subsection Obtaining Information about the Program and the Debugger State
Besides looking at the values of variables, there is often a need to get
other sorts of information about the state of your program and of the
-debugging environment itself. @command{dgawk} has one command which
+debugging environment itself. The @command{gawk} debugger has one command which
provides this information, appropriately called @code{info}. @code{info}
is used with one of a number of arguments that tell it exactly what
you want to know:
@@ -26092,7 +27137,7 @@ Local variables of the selected frame.
@item source
The name of the current source file. Each time the program stops, the
current source file is the file containing the current instruction.
-When @command{dgawk} first starts, the current source file is the first file
+When the debugger first starts, the current source file is the first file
included via the @option{-f} option. The
@samp{list @var{filename}:@var{lineno}} command can
be used at any time to change the current source.
@@ -26128,7 +27173,7 @@ The available options are:
@c nested table
@table @code
@item history_size
-The maximum number of lines to keep in the history file @file{./.dgawk_history}.
+The maximum number of lines to keep in the history file @file{./.gawk_history}.
The default is 100.
@item listsize
@@ -26140,14 +27185,14 @@ to standard output. An empty string (@code{""}) resets output to
standard output.
@item prompt
-The debugger prompt. The default is @samp{@w{dgawk> }}.
+The debugger prompt. The default is @samp{@w{gawk> }}.
@item save_history @r{[}on @r{|} off@r{]}
-Save command history to file @file{./.dgawk_history}.
+Save command history to file @file{./.gawk_history}.
The default is @code{on}.
@item save_options @r{[}on @r{|} off@r{]}
-Save current options to file @file{./.dgawkrc} upon exit.
+Save current options to file @file{./.gawkrc} upon exit.
The default is @code{on}.
Options are read back in to the next session upon startup.
@@ -26167,16 +27212,16 @@ Empty lines are ignored; they do @emph{not}
repeat the last command.
You can't restart the program by having more than one @code{run}
command in the file. Also, the list of commands may include additional
-@code{source} commands; however, @command{dgawk} will not source the
+@code{source} commands; however, the @command{gawk} debugger will not source the
same file more than once in order to avoid infinite recursion.
In addition to, or instead of the @code{source} command, you can use
-the @option{-R @var{file}} or @option{--command=@var{file}} command-line
+the @option{-D @var{file}} or @option{--debug=@var{file}} command-line
options to execute commands from a file non-interactively
(@pxref{Options}.
@end table
-@node Miscellaneous Dgawk Commands
+@node Miscellaneous Debugger Commands
@subsection Miscellaneous Commands
There are a few more commands which do not fit into the
@@ -26194,7 +27239,7 @@ partial dump of Davide Brini's obfuscated code
(@pxref{Signature Program}) demonstrates:
@smallexample
-dgawk> @kbd{dump}
+gawk> @kbd{dump}
@print{} # BEGIN
@print{}
@print{} [ 2:0x89faef4] Op_rule : [in_rule = BEGIN] [source_file = brini.awk]
@@ -26243,7 +27288,7 @@ dgawk> @kbd{dump}
@print{} [ :0x89fa3b0] Op_after_beginfile :
@print{} [ :0x89fa388] Op_no_op :
@print{} [ :0x89fa3c4] Op_after_endfile :
-dgawk>
+gawk>
@end smallexample
@cindex debugger commands, @code{h} (@code{help})
@@ -26252,7 +27297,7 @@ dgawk>
@cindex @code{h} debugger command (alias for @code{help})
@item @code{help}
@itemx @code{h}
-Print a list of all of the @command{dgawk} commands with a short
+Print a list of all of the @command{gawk} debugger commands with a short
summary of their usage. @samp{help @var{command}} prints the information
about the command @var{command}.
@@ -26299,7 +27344,7 @@ function @var{function}. This command may change the current source file.
Exit the debugger. Debugging is great fun, but sometimes we all have
to tend to other obligations in life, and sometimes we find the bug,
and are free to go on to the next one! As we saw above, if you are
-running a program, @command{dgawk} warns you if you accidentally type
+running a program, the debugger warns you if you accidentally type
@samp{q} or @samp{quit}, to make sure you really want to quit.
@cindex debugger commands, @code{trace}
@@ -26318,7 +27363,7 @@ fairly self-explanatory, and using @code{stepi} and @code{nexti} while
@node Readline Support
@section Readline Support
-If @command{dgawk} is compiled with the @code{readline} library, you
+If @command{gawk} is compiled with the @code{readline} library, you
can take advantage of that library's command completion and history expansion
features. The following types of completion are available:
@@ -26350,28 +27395,28 @@ and
@end table
-@node Dgawk Limitations
+@node Limitations
@section Limitations and Future Plans
-We hope you find @command{dgawk} useful and enjoyable to work with,
+We hope you find the @command{gawk} debugger useful and enjoyable to work with,
but as with any program, especially in its early releases, it still has
some limitations. A few which are worth being aware of are:
@itemize @bullet{}
@item
-At this point, @command{dgawk} does not give a detailed explanation of
+At this point, the debugger does not give a detailed explanation of
what you did wrong when you type in something it doesn't like. Rather, it just
responds @samp{syntax error}. When you do figure out what your mistake was,
though, you'll feel like a real guru.
@item
-If you perused the dump of opcodes in @ref{Miscellaneous Dgawk Commands},
+If you perused the dump of opcodes in @ref{Miscellaneous Debugger Commands},
(or if you are already familiar with @command{gawk} internals),
you will realize that much of the internal manipulation of data
in @command{gawk}, as in many interpreters, is done on a stack.
@code{Op_push}, @code{Op_pop}, etc., are the ``bread and butter'' of
-most @command{gawk} code. Unfortunately, as of now, @command{dgawk}
-does not allow you to examine the stack's contents.
+most @command{gawk} code. Unfortunately, as of now, the @command{gawk}
+debugger does not allow you to examine the stack's contents.
That is, the intermediate results of expression evaluation are on the
stack, but cannot be printed. Rather, only variables which are defined
@@ -26386,14 +27431,14 @@ programmer, you are expected to know what @code{/[^[:alnum:][:blank:]]/}
means.
@item
-@command{dgawk} is designed to be used by running a program (with all its
-parameters) on the command line, as described in @ref{dgawk invocation}.
+The @command{gawk} debugger is designed to be used by running a program (with all its
+parameters) on the command line, as described in @ref{Debugger Invocation}.
There is no way (as of now) to attach or ``break in'' to a running program.
This seems reasonable for a language which is used mainly for quickly
executing, short programs.
@item
-@command{dgawk} only accepts source supplied with the @option{-f} option.
+The @command{gawk} debugger only accepts source supplied with the @option{-f} option.
@end itemize
Look forward to a future release when these and other missing features may
@@ -27302,7 +28347,7 @@ environments.
@cindex Haque, John
John Haque
reworked the @command{gawk} internals to use a byte-code engine,
-providing the @command{dgawk} debugger for @command{awk} programs.
+providing the @command{gawk} debugger for @command{awk} programs.
@item
@cindex Yawitz, Efraim
@@ -28572,7 +29617,7 @@ since approximately 2003.
@item @command{pawk}
Nelson H.F.@: Beebe at the University of Utah has modified
Brian Kernighan's @command{awk} to provide timing and profiling information.
-It is different from @command{pgawk}
+It is different from @command{gawk} with the @option{--profile} option.
(@pxref{Profiling}),
in that it uses CPU-based profiling, not line-count
profiling. You may find it at either
@@ -29077,6 +30122,7 @@ When @option{--sandbox} is specified, extensions are disabled
@menu
* Internals:: A brief look at some @command{gawk} internals.
* Plugin License:: A note about licensing.
+* Loading Extensions:: How to load dynamic extensions.
* Sample Library:: A example of new functions.
@end menu
@@ -29141,22 +30187,12 @@ macro guarantees that a @code{NODE}'s wide-string value is current.
It may end up calling an internal @command{gawk} function.
It also guarantees that the wide string is zero-terminated.
-@cindex @code{get_curfunc_arg_count()} internal function
-@cindex internal function, @code{get_curfunc_arg_count()}
-@item size_t get_curfunc_arg_count(void)
-This function returns the actual number of parameters passed
-to the current function. Inside the code of an extension
-this can be used to determine the maximum index which is
-safe to use with @code{get_actual_argument}. If this value is
-greater than @code{nargs}, the function was
-called incorrectly from the @command{awk} program.
-
@cindex parameters@comma{} number of
@cindex @code{nargs} internal variable
@cindex internal variable, @code{nargs}
@item nargs
-Inside an extension function, this is the maximum number of
-expected parameters, as set by the @code{make_builtin()} function.
+Inside an extension function, this is the actual number of
+parameters passed to the current function.
@cindex @code{stptr} internal variable
@cindex internal variable, @code{stptr}
@@ -29202,13 +30238,10 @@ Make sure that @samp{n->type == Node_var_array} first.
@cindex arrays, elements, installing
@cindex @code{assoc_lookup()} internal function
@cindex internal function, @code{assoc_lookup()}
-@item NODE **assoc_lookup(NODE *symbol, NODE *subs, int reference)
+@item NODE **assoc_lookup(NODE *symbol, NODE *subs)
Finds, and installs if necessary, array elements.
@code{symbol} is the array, @code{subs} is the subscript.
This is usually a value created with @code{make_string()} (see below).
-@code{reference} should be @code{TRUE} if it is an error to use the
-value before it is created. Typically, @code{FALSE} is the
-correct value to use from extension functions.
@cindex strings
@cindex @code{make_string()} internal function
@@ -29400,6 +30433,56 @@ the symbol exists in the global scope. Something like this is enough:
int plugin_is_GPL_compatible;
@end example
+@node Loading Extensions
+@appendixsubsec Loading a Dynamic Extension
+@cindex loading extension
+@cindex @command{gawk}, functions, loading
+There are two ways to load a dynamically linked library. The first is to use the
+builtin @code{extension()}:
+
+@example
+extension(libname, init_func)
+@end example
+
+where @file{libname} is the library to load, and @samp{init_func} is the
+name of the initialization or bootstrap routine to run once loaded.
+
+The second method for dynamic loading of a library is to use the
+command line option @option{-l}:
+
+@example
+$ @kbd{gawk -l libname -f myprog}
+@end example
+
+This will work only if the initialization routine is named @code{dlload()}.
+
+If you use @code{extension()}, the library will be loaded
+at run time. This means that the functions are available only to the rest of
+your script. If you use the command line option @option{-l} instead,
+the library will be loaded before @command{gawk} starts compiling the
+actual program. The net effect is that you can use those functions
+anywhere in the program.
+
+@command{gawk} has a list of directories where it searches for libraries.
+By default, the list includes directories that depend upon how gawk was built
+and installed (@pxref{AWKPATH Variable}). If you want @command{gawk}
+to look for libraries in your private directory, you have to tell it.
+The way to do it is to set the @env{AWKPATH} environment variable
+(@pxref{AWKPATH Variable}).
+@command{gawk} supplies the default suffix @samp{.so} if it is not
+present in the name of the library.
+If the name of your library is @file{mylib.so}, you can simply type
+
+@example
+$ @kbd{gawk -l mylib -f myprog}
+@end example
+
+and @command{gawk} will do everything necessary to load in your library,
+and then call your @code{dlload()} routine.
+
+You can always specify the library using an absolute pathname, in which
+case @command{gawk} will not use @env{AWKPATH} to search for it.
+
@node Sample Library
@appendixsubsec Example: Directory and File Operation Built-ins
@c STARTOFRANGE chdirg
@@ -29592,7 +30675,7 @@ do_chdir(int nargs)
NODE *newdir;
int ret = -1;
- if (do_lint && get_curfunc_arg_count() != 1)
+ if (do_lint && nargs != 1)
lintwarn("chdir: called with incorrect number of arguments");
newdir = get_scalar_argument(0, FALSE);
@@ -29665,7 +30748,7 @@ do_stat(int nargs)
char *pmode; /* printable mode */
char *type = "unknown";
- if (do_lint && get_curfunc_arg_count() > 2)
+ if (do_lint && nargs > 2)
lintwarn("stat: called with too many arguments");
@end example
@@ -29699,15 +30782,15 @@ calls are shown here, since they all follow the same pattern:
@example
/* fill in the array */
- aptr = assoc_lookup(array, tmp = make_string("name", 4), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("name", 4));
*aptr = dupnode(file);
unref(tmp);
- aptr = assoc_lookup(array, tmp = make_string("mode", 4), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("mode", 4));
*aptr = make_number((AWKNUM) sbuf.st_mode);
unref(tmp);
- aptr = assoc_lookup(array, tmp = make_string("pmode", 5), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("pmode", 5));
pmode = format_mode(sbuf.st_mode);
*aptr = make_string(pmode, strlen(pmode));
unref(tmp);
diff --git a/eval.c b/eval.c
index 2421aea1..2305bbb3 100644
--- a/eval.c
+++ b/eval.c
@@ -29,34 +29,19 @@ extern void after_beginfile(IOBUF **curfile);
extern double pow(double x, double y);
extern double modf(double x, double *yp);
extern double fmod(double x, double y);
-NODE **fcall_list;
+NODE **fcall_list = NULL;
long fcall_count = 0;
int currule = 0;
IOBUF *curfile = NULL; /* current data file */
int exiting = FALSE;
-#ifdef DEBUGGING
-extern int pre_execute(INSTRUCTION **);
-extern void post_execute(INSTRUCTION *);
-#else
-#define r_interpret interpret
-#endif
+int (*interpret)(INSTRUCTION *);
+#define MAX_EXEC_HOOKS 10
+static int num_exec_hook = 0;
+static Func_pre_exec pre_execute[MAX_EXEC_HOOKS];
+static Func_post_exec post_execute = NULL;
-/*
- * Flag which executable this is; done here because eval.c is compiled
- * differently for each of them.
- */
-enum exe_mode which_gawk =
-#ifdef PROFILING
- exe_profiling /* pgawk */
-#else
-# ifdef DEBUGGING
- exe_debugging /* dgawk */
-# else
- exe_normal /* normal gawk */
-# endif
-#endif
- ; /* which_gawk */
+extern void frame_popped();
#if __GNUC__ < 2
NODE *_t; /* used as a temporary in macros */
@@ -66,12 +51,7 @@ int ORSlen;
int OFMTidx;
int CONVFMTidx;
-/* Profiling stuff */
-#ifdef PROFILING
-#define INCREMENT(n) n++
-#else
-#define INCREMENT(n) /* nothing */
-#endif
+static NODE *node_Boolean[2];
/* This rather ugly macro is for VMS C */
#ifdef C
@@ -262,9 +242,12 @@ static const char *const nodetypes[] = {
"Node_var_new",
"Node_param_list",
"Node_func",
+ "Node_ext_func",
"Node_hashnode",
- "Node_ahash",
"Node_array_ref",
+ "Node_array_tree",
+ "Node_array_leaf",
+ "Node_dump_array",
"Node_arrayfor",
"Node_frame",
"Node_instruction",
@@ -349,6 +332,7 @@ static struct optypetab {
{ "Op_K_nextfile", "nextfile" },
{ "Op_builtin", NULL },
{ "Op_sub_builtin", NULL },
+ { "Op_ext_builtin", NULL },
{ "Op_in_array", " in " },
{ "Op_func_call", NULL },
{ "Op_indirect_func_call", NULL },
@@ -376,7 +360,6 @@ static struct optypetab {
{ "Op_field_assign", NULL },
{ "Op_after_beginfile", NULL },
{ "Op_after_endfile", NULL },
- { "Op_ext_func", NULL },
{ "Op_func", NULL },
{ "Op_exec_count", NULL },
{ "Op_breakpoint", NULL },
@@ -446,20 +429,21 @@ flags2str(int flagval)
{
static const struct flagtab values[] = {
{ MALLOC, "MALLOC" },
- { PERM, "PERM" },
{ STRING, "STRING" },
{ STRCUR, "STRCUR" },
{ NUMCUR, "NUMCUR" },
{ NUMBER, "NUMBER" },
{ MAYBE_NUM, "MAYBE_NUM" },
- { ARRAYMAXED, "ARRAYMAXED" },
- { FUNC, "FUNC" },
{ FIELD, "FIELD" },
{ INTLSTR, "INTLSTR" },
- { NUMIND, "NUMIND" },
-#ifdef WSTRCUR
+ { NUMINT, "NUMINT" },
+ { INTIND, "INTIND" },
{ WSTRCUR, "WSTRCUR" },
-#endif
+ { MPFN, "MPFN" },
+ { MPZN, "MPZN" },
+ { ARRAYMAXED, "ARRAYMAXED" },
+ { HALFHAT, "HALFHAT" },
+ { XARRAY, "XARRAY" },
{ 0, NULL },
};
@@ -484,7 +468,7 @@ genflags2str(int flagval, const struct flagtab *tab)
* the '|' character.
*/
space_needed = (strlen(tab[i].name) + (sp != buffer));
- if (space_left < space_needed)
+ if (space_left <= space_needed)
fatal(_("buffer overflow in genflags2str"));
if (sp != buffer) {
@@ -498,6 +482,7 @@ genflags2str(int flagval, const struct flagtab *tab)
}
}
+ *sp = '\0';
return buffer;
}
@@ -599,16 +584,13 @@ cmp_nodes(NODE *t1, NODE *t2)
(void) force_number(t1);
if (t2->flags & MAYBE_NUM)
(void) force_number(t2);
- if ((t1->flags & NUMBER) && (t2->flags & NUMBER)) {
- if (t1->numbr == t2->numbr)
- ret = 0;
- /* don't subtract, in case one or both are infinite */
- else if (t1->numbr < t2->numbr)
- ret = -1;
- else
- ret = 1;
- return ret;
- }
+ if (t1->flags & INTIND)
+ t1 = force_string(t1);
+ if (t2->flags & INTIND)
+ t2 = force_string(t2);
+
+ if ((t1->flags & NUMBER) && (t2->flags & NUMBER))
+ return cmp_numbers(t1, t2);
(void) force_string(t1);
(void) force_string(t2);
@@ -637,11 +619,13 @@ cmp_nodes(NODE *t1, NODE *t2)
ret = casetable[*cp1] - casetable[*cp2];
} else
ret = memcmp(t1->stptr, t2->stptr, l);
- return (ret == 0 ? ldiff : ret);
+
+ ret = ret == 0 ? ldiff : ret;
+ return ret;
}
+/* push_frame --- push a frame NODE onto stack */
-#if defined(PROFILING) || defined(DEBUGGING)
static void
push_frame(NODE *f)
{
@@ -663,35 +647,28 @@ push_frame(NODE *f)
fcall_list[1] = f;
}
+
+/* pop_frame --- pop off a frame NODE*/
+
static void
pop_frame()
{
-#ifdef DEBUGGING
- extern void frame_popped();
-#endif
if (fcall_count > 1)
memmove(fcall_list + 1, fcall_list + 2, (fcall_count - 1) * sizeof(NODE *));
fcall_count--;
assert(fcall_count >= 0);
-#ifdef DEBUGGING
- frame_popped();
-#endif
+ if (do_debug)
+ frame_popped();
}
-#else /* not PROFILING or DEBUGGING */
-#define push_frame(p) /* nothing */
-#define pop_frame() /* nothing */
-#endif
-#ifdef PROFILING
-
/* dump_fcall_stack --- print a backtrace of the awk function calls */
void
dump_fcall_stack(FILE *fp)
{
NODE *f, *func;
- long i = 0;
+ long i = 0, j, k = 0;
if (fcall_count == 0)
return;
@@ -699,19 +676,20 @@ dump_fcall_stack(FILE *fp)
/* current frame */
func = frame_ptr->func_node;
- fprintf(fp, "\t# %3ld. %s\n", i, func->lnode->param);
+ for (j = 0; j <= frame_ptr->num_tail_calls; j++)
+ fprintf(fp, "\t# %3ld. %s\n", k++, func->vname);
/* outer frames except main */
for (i = 1; i < fcall_count; i++) {
f = fcall_list[i];
func = f->func_node;
- fprintf(fp, "\t# %3ld. %s\n", i, func->lnode->param);
+ for (j = 0; j <= f->num_tail_calls; j++)
+ fprintf(fp, "\t# %3ld. %s\n", k++, func->vname);
}
- fprintf(fp, "\t# %3ld. -- main --\n", fcall_count);
+ fprintf(fp, "\t# %3ld. -- main --\n", k);
}
-#endif /* PROFILING */
/* set_IGNORECASE --- update IGNORECASE as appropriate */
@@ -719,6 +697,7 @@ void
set_IGNORECASE()
{
static short warned = FALSE;
+ NODE *n = IGNORECASE_node->var_value;
if ((do_lint || do_traditional) && ! warned) {
warned = TRUE;
@@ -727,16 +706,19 @@ set_IGNORECASE()
load_casetable();
if (do_traditional)
IGNORECASE = FALSE;
- else if ((IGNORECASE_node->var_value->flags & (STRING|STRCUR)) != 0) {
- if ((IGNORECASE_node->var_value->flags & MAYBE_NUM) == 0)
- IGNORECASE = (force_string(IGNORECASE_node->var_value)->stlen > 0);
- else
- IGNORECASE = (force_number(IGNORECASE_node->var_value) != 0.0);
- } else if ((IGNORECASE_node->var_value->flags & (NUMCUR|NUMBER)) != 0)
- IGNORECASE = (force_number(IGNORECASE_node->var_value) != 0.0);
+ else if ((n->flags & (STRING|STRCUR)) != 0) {
+ if ((n->flags & MAYBE_NUM) == 0) {
+ (void) force_string(n);
+ IGNORECASE = (n->stlen > 0);
+ } else {
+ (void) force_number(n);
+ IGNORECASE = ! iszero(n);
+ }
+ } else if ((n->flags & (NUMCUR|NUMBER)) != 0)
+ IGNORECASE = ! iszero(n);
else
IGNORECASE = FALSE; /* shouldn't happen */
-
+
set_RS(); /* set_RS() calls set_FS() if need be, for us */
}
@@ -747,7 +729,7 @@ set_BINMODE()
{
static short warned = FALSE;
char *p;
- NODE *v;
+ NODE *v = BINMODE_node->var_value;
if ((do_lint || do_traditional) && ! warned) {
warned = TRUE;
@@ -755,16 +737,15 @@ set_BINMODE()
}
if (do_traditional)
BINMODE = 0;
- else if ((BINMODE_node->var_value->flags & NUMBER) != 0) {
- BINMODE = (int) force_number(BINMODE_node->var_value);
+ else if ((v->flags & NUMBER) != 0) {
+ (void) force_number(v);
+ BINMODE = get_number_si(v);
/* Make sure the value is rational. */
if (BINMODE < 0)
BINMODE = 0;
else if (BINMODE > 3)
BINMODE = 3;
- }
- else if ((BINMODE_node->var_value->flags & STRING) != 0) {
- v = BINMODE_node->var_value;
+ } else if ((v->flags & STRING) != 0) {
p = v->stptr;
/*
@@ -813,8 +794,7 @@ set_BINMODE()
break;
}
}
- }
- else
+ } else
BINMODE = 3; /* shouldn't happen */
}
@@ -823,7 +803,8 @@ set_BINMODE()
void
set_OFS()
{
- OFS = force_string(OFS_node->var_value)->stptr;
+ OFS_node->var_value = force_string(OFS_node->var_value);
+ OFS = OFS_node->var_value->stptr;
OFSlen = OFS_node->var_value->stlen;
OFS[OFSlen] = '\0';
}
@@ -833,7 +814,8 @@ set_OFS()
void
set_ORS()
{
- ORS = force_string(ORS_node->var_value)->stptr;
+ ORS_node->var_value = force_string(ORS_node->var_value);
+ ORS = ORS_node->var_value->stptr;
ORSlen = ORS_node->var_value->stlen;
ORS[ORSlen] = '\0';
}
@@ -849,6 +831,7 @@ fmt_ok(NODE *n)
{
NODE *tmp = force_string(n);
const char *p = tmp->stptr;
+
#if ! defined(PRINTF_HAS_F_FORMAT) || PRINTF_HAS_F_FORMAT != 1
static const char float_formats[] = "efgEG";
#else
@@ -890,7 +873,7 @@ fmt_index(NODE *n)
if (fmt_list == NULL)
emalloc(fmt_list, NODE **, fmt_num*sizeof(*fmt_list), "fmt_index");
- (void) force_string(n);
+ n = force_string(n);
while (ix < fmt_hiwater) {
if (cmp_nodes(fmt_list[ix], n) == 0)
return ix;
@@ -937,46 +920,52 @@ set_LINT()
{
#ifndef NO_LINT
int old_lint = do_lint;
+ NODE *n = LINT_node->var_value;
- if ((LINT_node->var_value->flags & (STRING|STRCUR)) != 0) {
- if ((LINT_node->var_value->flags & MAYBE_NUM) == 0) {
+ if ((n->flags & (STRING|STRCUR)) != 0) {
+ if ((n->flags & MAYBE_NUM) == 0) {
const char *lintval;
size_t lintlen;
- do_lint = (force_string(LINT_node->var_value)->stlen > 0);
- lintval = LINT_node->var_value->stptr;
- lintlen = LINT_node->var_value->stlen;
- if (do_lint) {
- do_lint = LINT_ALL;
+ n = force_string(LINT_node->var_value);
+ lintval = n->stptr;
+ lintlen = n->stlen;
+ if (lintlen > 0) {
+ do_flags |= DO_LINT_ALL;
if (lintlen == 5 && strncmp(lintval, "fatal", 5) == 0)
lintfunc = r_fatal;
- else if (lintlen == 7 && strncmp(lintval, "invalid", 7) == 0)
- do_lint = LINT_INVALID;
- else
+ else if (lintlen == 7 && strncmp(lintval, "invalid", 7) == 0) {
+ do_flags &= ~ DO_LINT_ALL;
+ do_flags |= DO_LINT_INVALID;
+ } else
lintfunc = warning;
- } else
+ } else {
+ do_flags &= ~(DO_LINT_ALL|DO_LINT_INVALID);
lintfunc = warning;
+ }
} else {
- if (force_number(LINT_node->var_value) != 0.0)
- do_lint = LINT_ALL;
+ (void) force_number(n);
+ if (! iszero(n))
+ do_flags |= DO_LINT_ALL;
else
- do_lint = FALSE;
+ do_flags &= ~(DO_LINT_ALL|DO_LINT_INVALID);
lintfunc = warning;
}
- } else if ((LINT_node->var_value->flags & (NUMCUR|NUMBER)) != 0) {
- if (force_number(LINT_node->var_value) != 0.0)
- do_lint = LINT_ALL;
+ } else if ((n->flags & (NUMCUR|NUMBER)) != 0) {
+ (void) force_number(n);
+ if (! iszero(n))
+ do_flags |= DO_LINT_ALL;
else
- do_lint = FALSE;
+ do_flags &= ~(DO_LINT_ALL|DO_LINT_INVALID);
lintfunc = warning;
} else
- do_lint = FALSE; /* shouldn't happen */
+ do_flags &= ~(DO_LINT_ALL|DO_LINT_INVALID); /* shouldn't happen */
if (! do_lint)
lintfunc = warning;
/* explicitly use warning() here, in case lintfunc == r_fatal */
- if (old_lint != do_lint && old_lint && do_lint == FALSE)
+ if (old_lint != do_lint && old_lint && ! do_lint)
warning(_("turning off `--lint' due to assignment to `LINT'"));
#endif /* ! NO_LINT */
}
@@ -987,9 +976,11 @@ void
set_TEXTDOMAIN()
{
int len;
+ NODE *tmp;
- TEXTDOMAIN = force_string(TEXTDOMAIN_node->var_value)->stptr;
- len = TEXTDOMAIN_node->var_value->stlen;
+ tmp = TEXTDOMAIN_node->var_value = force_string(TEXTDOMAIN_node->var_value);
+ TEXTDOMAIN = tmp->stptr;
+ len = tmp->stlen;
TEXTDOMAIN[len] = '\0';
/*
* Note: don't call textdomain(); this value is for
@@ -1026,9 +1017,14 @@ update_ERRNO()
void
update_NR()
{
+#ifdef HAVE_MPFR
+ if (is_mpg_number(NR_node->var_value))
+ (void) mpg_update_var(NR_node);
+ else
+#endif
if (NR_node->var_value->numbr != NR) {
unref(NR_node->var_value);
- NR_node->var_value = make_number((AWKNUM) NR);
+ NR_node->var_value = make_number(NR);
}
}
@@ -1037,11 +1033,14 @@ update_NR()
void
update_NF()
{
- if (NF == -1 || NF_node->var_value->numbr != NF) {
+ long l;
+
+ l = get_number_si(NF_node->var_value);
+ if (NF == -1 || l != NF) {
if (NF == -1)
(void) get_field(UNLIMITED - 1, NULL); /* parse record */
unref(NF_node->var_value);
- NF_node->var_value = make_number((AWKNUM) NF);
+ NF_node->var_value = make_number(NF);
}
}
@@ -1050,14 +1049,18 @@ update_NF()
void
update_FNR()
{
+#ifdef HAVE_MPFR
+ if (is_mpg_number(FNR_node->var_value))
+ (void) mpg_update_var(FNR_node);
+ else
+#endif
if (FNR_node->var_value->numbr != FNR) {
unref(FNR_node->var_value);
- FNR_node->var_value = make_number((AWKNUM) FNR);
+ FNR_node->var_value = make_number(FNR);
}
}
-
NODE *frame_ptr; /* current frame */
STACK_ITEM *stack_ptr = NULL;
STACK_ITEM *stack_bottom;
@@ -1078,32 +1081,6 @@ NODE **args_array = NULL;
STACK_ITEM *
grow_stack()
{
- if (stack_ptr == NULL) {
- char *val;
-
- if ((val = getenv("GAWK_STACKSIZE")) != NULL) {
- if (isdigit((unsigned char) *val)) {
- unsigned long n = 0;
- for (; *val && isdigit((unsigned char) *val); val++)
- n = (n * 10) + *val - '0';
- if (n >= 1)
- STACK_SIZE = n;
- }
- }
-
- emalloc(stack_bottom, STACK_ITEM *, STACK_SIZE * sizeof(STACK_ITEM), "grow_stack");
- stack_ptr = stack_bottom - 1;
- stack_top = stack_bottom + STACK_SIZE - 1;
-
- /* initialize frame pointer */
- getnode(frame_ptr);
- frame_ptr->type = Node_frame;
- frame_ptr->stack = NULL;
- frame_ptr->func_node = NULL; /* in main */
- frame_ptr->vname = NULL;
- return stack_ptr;
- }
-
STACK_SIZE *= 2;
erealloc(stack_bottom, STACK_ITEM *, STACK_SIZE * sizeof(STACK_ITEM), "grow_stack");
stack_top = stack_bottom + STACK_SIZE - 1;
@@ -1123,9 +1100,6 @@ r_get_lhs(NODE *n, int reference)
int isparam = FALSE;
if (n->type == Node_param_list) {
- if ((n->flags & FUNC) != 0)
- fatal(_("can't use function name `%s' as variable or array"),
- n->vname);
isparam = TRUE;
n = GET_PARAM(n->param_cnt);
}
@@ -1139,11 +1113,11 @@ r_get_lhs(NODE *n, int reference)
fatal(_("attempt to use array `%s' in a scalar context"),
array_vname(n));
n->orig_array->type = Node_var;
- n->orig_array->var_value = Nnull_string;
+ n->orig_array->var_value = dupnode(Nnull_string);
/* fall through */
case Node_var_new:
n->type = Node_var;
- n->var_value = Nnull_string;
+ n->var_value = dupnode(Nnull_string);
break;
case Node_var:
@@ -1158,7 +1132,7 @@ r_get_lhs(NODE *n, int reference)
_("reference to uninitialized argument `%s'") :
_("reference to uninitialized variable `%s'")),
n->vname);
- return &n->var_value;
+ return & n->var_value;
}
@@ -1180,7 +1154,9 @@ r_get_field(NODE *n, Func_ptr *assign, int reference)
}
}
- field_num = (long) force_number(n);
+ (void) force_number(n);
+ field_num = get_number_si(n);
+
if (field_num < 0)
fatal(_("attempt to access field %ld"), field_num);
@@ -1239,17 +1215,42 @@ static INSTRUCTION *
setup_frame(INSTRUCTION *pc)
{
NODE *r = NULL;
- NODE *m;
- NODE *f;
+ NODE *m, *f, *fp;
NODE **sp = NULL;
- char **varnames;
- int pcount, arg_count, i;
+ int pcount, arg_count, i, j;
+ int tail_optimize = FALSE;
f = pc->func_body;
- pcount = f->lnode->param_cnt;
- varnames = f->parmlist;
+ pcount = f->param_cnt;
+ fp = f->fparms;
arg_count = (pc + 1)->expr_count;
+ /* tail recursion optimization */
+ tail_optimize = ((pc + 1)->tail_call && do_optimize > 1
+ && ! do_debug && ! do_profile);
+
+ if (tail_optimize) {
+ /* free local vars of calling frame */
+
+ NODE *func;
+ int n;
+
+ func = frame_ptr->func_node;
+ for (n = func->param_cnt, sp = frame_ptr->stack; n > 0; n--) {
+ r = *sp++;
+ if (r->type == Node_var) /* local variable */
+ DEREF(r->var_value);
+ else if (r->type == Node_var_array) /* local array */
+ assoc_clear(r);
+ }
+ sp = frame_ptr->stack;
+
+ } else if (pcount > 0) {
+ emalloc(sp, NODE **, pcount * sizeof(NODE *), "setup_frame");
+ memset(sp, 0, pcount * sizeof(NODE *));
+ }
+
+
/* check for extra args */
if (arg_count > pcount) {
warning(
@@ -1262,23 +1263,23 @@ setup_frame(INSTRUCTION *pc)
} while (--arg_count > pcount);
}
- if (pcount > 0) {
- emalloc(sp, NODE **, pcount * sizeof(NODE *), "setup_frame");
- memset(sp, 0, pcount * sizeof(NODE *));
- }
+ for (i = 0, j = arg_count - 1; i < pcount; i++, j--) {
+ if (tail_optimize)
+ r = sp[i];
+ else {
+ getnode(r);
+ memset(r, 0, sizeof(NODE));
+ sp[i] = r;
+ }
- for (i = 0; i < pcount; i++) {
- getnode(r);
- memset(r, 0, sizeof(NODE));
- sp[i] = r;
if (i >= arg_count) {
/* local variable */
r->type = Node_var_new;
- r->vname = varnames[i];
+ r->vname = fp[i].param;
continue;
}
- m = PEEK(arg_count - i - 1); /* arguments in reverse order on runtime stack */
+ m = PEEK(j); /* arguments in reverse order on runtime stack */
if (m->type == Node_param_list)
m = GET_PARAM(m->param_cnt);
@@ -1302,7 +1303,7 @@ setup_frame(INSTRUCTION *pc)
* subsequent param.
*/
r->type = Node_var;
- r->var_value = Nnull_string;
+ r->var_value = dupnode(Nnull_string);
break;
case Node_val:
@@ -1313,10 +1314,16 @@ setup_frame(INSTRUCTION *pc)
default:
cant_happen();
}
- r->vname = varnames[i];
+ r->vname = fp[i].param;
}
+
stack_adj(-arg_count); /* adjust stack pointer */
+ if (tail_optimize) {
+ frame_ptr->num_tail_calls++;
+ return f->code_ptr;
+ }
+
if (pc->opcode == Op_indirect_func_call) {
r = POP(); /* indirect var */
DEREF(r);
@@ -1324,7 +1331,8 @@ setup_frame(INSTRUCTION *pc)
frame_ptr->vname = source; /* save current source */
- push_frame(frame_ptr);
+ if (do_profile || do_debug)
+ push_frame(frame_ptr);
/* save current frame in stack */
PUSH(frame_ptr);
@@ -1335,6 +1343,7 @@ setup_frame(INSTRUCTION *pc)
frame_ptr->stack = sp;
frame_ptr->prev_frame_size = (stack_ptr - stack_bottom); /* size of the previous stack frame */
frame_ptr->func_node = f;
+ frame_ptr->num_tail_calls = 0;
frame_ptr->vname = NULL;
frame_ptr->reti = pc; /* on return execute pc->nexti */
@@ -1354,7 +1363,7 @@ restore_frame(NODE *fp)
INSTRUCTION *ri;
func = frame_ptr->func_node;
- n = func->lnode->param_cnt;
+ n = func->param_cnt;
sp = frame_ptr->stack;
for (; n > 0; n--) {
@@ -1365,13 +1374,15 @@ restore_frame(NODE *fp)
assoc_clear(r);
freenode(r);
}
+
if (frame_ptr->stack != NULL)
efree(frame_ptr->stack);
ri = frame_ptr->reti; /* execution in calling frame
* resumes from ri->nexti.
*/
freenode(frame_ptr);
- pop_frame();
+ if (do_profile || do_debug)
+ pop_frame();
/* restore frame */
frame_ptr = fp;
@@ -1388,18 +1399,22 @@ restore_frame(NODE *fp)
static inline void
free_arrayfor(NODE *r)
{
- if (r->var_array != NULL) {
- size_t num_elems = r->table_size;
- NODE **list = r->var_array;
- while (num_elems > 0)
- unref(list[--num_elems]);
+ if (r->for_list != NULL) {
+ NODE *n;
+ size_t num_elems = r->for_list_size;
+ NODE **list = r->for_list;
+ while (num_elems > 0) {
+ n = list[--num_elems];
+ unref(n);
+ }
efree(list);
}
freenode(r);
}
-/* unwind_stack --- pop items off the run-time stack;
+/*
+ * unwind_stack --- pop items off the run-time stack;
* 'n' is the # of items left in the stack.
*/
@@ -1460,30 +1475,28 @@ unwind_stack(long n)
#define pop_stack() (void) unwind_stack(0)
-/*
- * This generated compiler warnings from GCC 4.4. Who knows why.
- *
-#define eval_condition(t) (((t)->flags & MAYBE_NUM) && force_number(t), \
- ((t)->flags & NUMBER) ? ((t)->numbr != 0.0) : ((t)->stlen != 0))
-*/
-
-
static inline int
eval_condition(NODE *t)
{
+ if (t == node_Boolean[FALSE])
+ return FALSE;
+
+ if (t == node_Boolean[TRUE])
+ return TRUE;
+
if ((t->flags & MAYBE_NUM) != 0)
force_number(t);
if ((t->flags & NUMBER) != 0)
- return (t->numbr != 0.0);
+ return ! iszero(t);
return (t->stlen != 0);
}
-/* cmp_scalar -- compare two nodes on the stack */
+/* cmp_scalars -- compare two nodes on the stack */
static inline int
-cmp_scalar()
+cmp_scalars()
{
NODE *t1, *t2;
int di;
@@ -1506,32 +1519,33 @@ static void
op_assign(OPCODE op)
{
NODE **lhs;
- NODE *r = NULL;
- AWKNUM x1, x2;
-#ifndef HAVE_FMOD
- AWKNUM x;
-#endif
+ NODE *t1, *t2;
+ AWKNUM x = 0.0, x1, x2;
lhs = POP_ADDRESS();
- x1 = force_number(*lhs);
- TOP_NUMBER(x2);
- unref(*lhs);
+ t1 = *lhs;
+ x1 = force_number(t1)->numbr;
+
+ t2 = TOP_SCALAR();
+ x2 = force_number(t2)->numbr;
+ DEREF(t2);
+
switch (op) {
case Op_assign_plus:
- r = *lhs = make_number(x1 + x2);
+ x = x1 + x2;
break;
case Op_assign_minus:
- r = *lhs = make_number(x1 - x2);
+ x = x1 - x2;
break;
case Op_assign_times:
- r = *lhs = make_number(x1 * x2);
+ x = x1 * x2;
break;
case Op_assign_quotient:
if (x2 == (AWKNUM) 0) {
decr_sp();
fatal(_("division by zero attempted in `/='"));
}
- r = *lhs = make_number(x1 / x2);
+ x = x1 / x2;
break;
case Op_assign_mod:
if (x2 == (AWKNUM) 0) {
@@ -1539,24 +1553,30 @@ op_assign(OPCODE op)
fatal(_("division by zero attempted in `%%='"));
}
#ifdef HAVE_FMOD
- r = *lhs = make_number(fmod(x1, x2));
+ x = fmod(x1, x2);
#else /* ! HAVE_FMOD */
(void) modf(x1 / x2, &x);
x = x1 - x2 * x;
- r = *lhs = make_number(x);
#endif /* ! HAVE_FMOD */
break;
case Op_assign_exp:
- r = *lhs = make_number((AWKNUM) calc_exp((double) x1, (double) x2));
+ x = calc_exp((double) x1, (double) x2);
break;
default:
break;
}
- UPREF(r);
- REPLACE(r);
-}
+ if (t1->valref == 1 && t1->flags == (MALLOC|NUMCUR|NUMBER)) {
+ /* optimization */
+ t1->numbr = x;
+ } else {
+ unref(t1);
+ t1 = *lhs = make_number(x);
+ }
+ UPREF(t1);
+ REPLACE(t1);
+}
/* PUSH_CODE --- push a code onto the runtime stack */
@@ -1584,7 +1604,8 @@ POP_CODE()
}
-/* Implementation of BEGINFILE and ENDFILE requires saving an execution
+/*
+ * Implementation of BEGINFILE and ENDFILE requires saving an execution
* state and the ability to return to that state. The state is
* defined by the instruction triggering the BEGINFILE/ENDFILE rule, the
* run-time stack, the rule and the source file. The source line is available in
@@ -1653,1126 +1674,92 @@ pop_exec_state(int *rule, char **src, long *sz)
}
-/*
- * r_interpret:
- * code is a list of instructions to run. returns the exit value
- * from the awk code.
- */
-
- /* N.B.:
- * 1) reference counting done for both number and string values.
- * 2) TEMP flag no longer needed (consequence of the above; valref = 0
- * is the replacement).
- * 3) Stack operations:
- * Use REPLACE[_XX] if last stack operation was TOP[_XX],
- * PUSH[_XX] if last operation was POP[_XX] instead.
- * 4) UPREF and DREF -- see awk.h
- */
-
+/* register_exec_hook --- add exec hooks in the interpreter. */
int
-r_interpret(INSTRUCTION *code)
+register_exec_hook(Func_pre_exec preh, Func_post_exec posth)
{
- INSTRUCTION *pc; /* current instruction */
- NODE *r = NULL;
- NODE *m;
- INSTRUCTION *ni;
- NODE *t1, *t2;
- NODE *f; /* function definition */
- NODE **lhs;
- AWKNUM x, x1, x2;
- int di, pre = FALSE;
- Regexp *rp;
-#if defined(GAWKDEBUG) || defined(ARRAYDEBUG)
- int last_was_stopme = FALSE; /* builtin stopme() called ? */
-#endif
- int stdio_problem = FALSE;
+ int pos = 0;
+ /*
+ * multiple post-exec hooks aren't supported. post-exec hook is mainly
+ * for use by the debugger.
+ */
- if (args_array == NULL)
- emalloc(args_array, NODE **, (max_args + 2)*sizeof(NODE *), "r_interpret");
- else
- erealloc(args_array, NODE **, (max_args + 2)*sizeof(NODE *), "r_interpret");
+ if (! preh || (post_execute && posth))
+ return FALSE;
-/* array subscript */
-#define mk_sub(n) (n == 1 ? POP_STRING() : concat_exp(n, TRUE))
+ if (num_exec_hook == MAX_EXEC_HOOKS)
+ return FALSE;
-#ifdef DEBUGGING
-#define JUMPTO(x) do { post_execute(pc); pc = (x); goto top; } while(FALSE)
-#else
-#define JUMPTO(x) do { pc = (x); goto top; } while(FALSE)
-#endif
-
- pc = code;
-
- /* N.B.: always use JUMPTO for next instruction, otherwise bad things
- * may happen. DO NOT add a real loop (for/while) below to
- * replace ' forever {'; this catches failure to use JUMPTO to execute
- * next instruction (e.g. continue statement).
+ /*
+ * Add to the beginning of the array but do not displace the
+ * debugger hook if it exists.
*/
+ if (num_exec_hook > 0) {
+ pos = !! do_debug;
+ if (num_exec_hook > pos)
+ memmove(pre_execute + pos + 1, pre_execute + pos,
+ (num_exec_hook - pos) * sizeof (preh));
+ }
+ pre_execute[pos] = preh;
+ num_exec_hook++;
- /* loop until hit Op_stop instruction */
-
- /* forever { */
-top:
- if (pc->source_line > 0)
- sourceline = pc->source_line;
-
-#ifdef DEBUGGING
- if (! pre_execute(&pc))
- goto top;
-#endif
-
- switch (pc->opcode) {
- case Op_rule:
- currule = pc->in_rule; /* for sole use in Op_K_next, Op_K_nextfile, Op_K_getline* */
- /* fall through */
- case Op_func:
- case Op_ext_func:
- source = pc->source_file;
- break;
-
- case Op_atexit:
- /* avoid false source indications */
- source = NULL;
- sourceline = 0;
- (void) nextfile(&curfile, TRUE); /* close input data file */
- /*
- * This used to be:
- *
- * if (close_io() != 0 && ! exiting && exit_val == 0)
- * exit_val = 1;
- *
- * Other awks don't care about problems closing open files
- * and pipes, in that it doesn't affect their exit status.
- * So we no longer do either.
- */
- (void) close_io(& stdio_problem);
- /*
- * However, we do want to exit non-zero if there was a problem
- * with stdout/stderr, so we reinstate a slightly different
- * version of the above:
- */
- if (stdio_problem && ! exiting && exit_val == 0)
- exit_val = 1;
- break;
-
- case Op_stop:
- return 0;
-
- case Op_push_i:
- m = pc->memory;
- PUSH((m->flags & INTLSTR) != 0 ? format_val(CONVFMT, CONVFMTidx, m): m);
- break;
-
- case Op_push:
- case Op_push_arg:
- {
- NODE *save_symbol;
- int isparam = FALSE;
-
- save_symbol = m = pc->memory;
- if (m->type == Node_param_list) {
- if ((m->flags & FUNC) != 0)
- fatal(_("can't use function name `%s' as variable or array"),
- m->vname);
- isparam = TRUE;
- save_symbol = m = GET_PARAM(m->param_cnt);
- if (m->type == Node_array_ref)
- m = m->orig_array;
- }
-
- switch (m->type) {
- case Node_var:
- if (do_lint && var_uninitialized(m))
- lintwarn(isparam ?
- _("reference to uninitialized argument `%s'") :
- _("reference to uninitialized variable `%s'"),
- save_symbol->vname);
- m = m->var_value;
- UPREF(m);
- PUSH(m);
- break;
-
- case Node_var_new:
- m->type = Node_var;
- m->var_value = Nnull_string;
- if (do_lint)
- lintwarn(isparam ?
- _("reference to uninitialized argument `%s'") :
- _("reference to uninitialized variable `%s'"),
- save_symbol->vname);
- PUSH(Nnull_string);
- break;
-
- case Node_var_array:
- if (pc->opcode == Op_push_arg)
- PUSH(m);
- else
- fatal(_("attempt to use array `%s' in a scalar context"),
- array_vname(save_symbol));
- break;
-
- default:
- cant_happen();
- }
- }
- break;
-
- case Op_push_param: /* function argument */
- m = pc->memory;
- if (m->type == Node_param_list)
- m = GET_PARAM(m->param_cnt);
- if (m->type == Node_var) {
- m = m->var_value;
- UPREF(m);
- PUSH(m);
- break;
- }
- /* else
- fall through */
- case Op_push_array:
- PUSH(pc->memory);
- break;
-
- case Op_push_lhs:
- lhs = get_lhs(pc->memory, pc->do_reference);
- PUSH_ADDRESS(lhs);
- break;
-
- case Op_subscript:
- t2 = mk_sub(pc->sub_count);
- t1 = POP_ARRAY();
- r = *assoc_lookup(t1, t2, TRUE);
- DEREF(t2);
- if (r->type == Node_val)
- UPREF(r);
- PUSH(r);
- break;
-
- case Op_sub_array:
- t2 = mk_sub(pc->sub_count);
- t1 = POP_ARRAY();
- r = in_array(t1, t2);
- if (r == NULL) {
- getnode(r);
- r->type = Node_var_array;
- r->var_array = NULL;
- r->vname = estrdup(t2->stptr, t2->stlen); /* the subscript in parent array */
- r->parent_array = t1;
- *assoc_lookup(t1, t2, FALSE) = r;
- } else if (r->type != Node_var_array)
- fatal(_("attempt to use scalar `%s[\"%.*s\"]' as an array"),
- array_vname(t1), (int) t2->stlen, t2->stptr);
- DEREF(t2);
- PUSH(r);
- break;
-
- case Op_subscript_lhs:
- t2 = mk_sub(pc->sub_count);
- t1 = POP_ARRAY();
- lhs = assoc_lookup(t1, t2, pc->do_reference);
- if ((*lhs)->type == Node_var_array)
- fatal(_("attempt to use array `%s[\"%.*s\"]' in a scalar context"),
- array_vname(t1), (int) t2->stlen, t2->stptr);
- DEREF(t2);
- PUSH_ADDRESS(lhs);
- break;
-
- case Op_field_spec:
- t1 = TOP_SCALAR();
- lhs = r_get_field(t1, (Func_ptr *) 0, TRUE);
- decr_sp();
- DEREF(t1);
- /* This used to look like this:
- PUSH(dupnode(*lhs));
- but was changed to bypass an apparent bug in the z/OS C compiler.
- Please do not remerge. */
- r = dupnode(*lhs); /* can't use UPREF here */
- PUSH(r);
- break;
-
- case Op_field_spec_lhs:
- t1 = TOP_SCALAR();
- lhs = r_get_field(t1, &pc->target_assign->field_assign, pc->do_reference);
- decr_sp();
- DEREF(t1);
- PUSH_ADDRESS(lhs);
- break;
-
- case Op_lint:
- if (do_lint) {
- switch (pc->lint_type) {
- case LINT_assign_in_cond:
- lintwarn(_("assignment used in conditional context"));
- break;
-
- case LINT_no_effect:
- lintwarn(_("statement has no effect"));
- break;
-
- default:
- cant_happen();
- }
- }
- break;
-
- case Op_K_break:
- case Op_K_continue:
- case Op_jmp:
- JUMPTO(pc->target_jmp);
-
- case Op_jmp_false:
- r = POP_SCALAR();
- di = eval_condition(r);
- DEREF(r);
- if (! di)
- JUMPTO(pc->target_jmp);
- break;
-
- case Op_jmp_true:
- r = POP_SCALAR();
- di = eval_condition(r);
- DEREF(r);
- if (di)
- JUMPTO(pc->target_jmp);
- break;
-
- case Op_and:
- case Op_or:
- t1 = POP_SCALAR();
- di = eval_condition(t1);
- DEREF(t1);
- if ((pc->opcode == Op_and && di)
- || (pc->opcode == Op_or && ! di))
- break;
- r = make_number((AWKNUM) di);
- PUSH(r);
- ni = pc->target_jmp;
- JUMPTO(ni->nexti);
-
- case Op_and_final:
- case Op_or_final:
- t1 = TOP_SCALAR();
- r = make_number((AWKNUM) eval_condition(t1));
- DEREF(t1);
- REPLACE(r);
- break;
-
- case Op_not:
- t1 = TOP_SCALAR();
- r = make_number((AWKNUM) ! eval_condition(t1));
- DEREF(t1);
- REPLACE(r);
- break;
-
- case Op_equal:
- r = make_number((AWKNUM) (cmp_scalar() == 0));
- REPLACE(r);
- break;
-
- case Op_notequal:
- r = make_number((AWKNUM) (cmp_scalar() != 0));
- REPLACE(r);
- break;
-
- case Op_less:
- r = make_number((AWKNUM) (cmp_scalar() < 0));
- REPLACE(r);
- break;
-
- case Op_greater:
- r = make_number((AWKNUM) (cmp_scalar() > 0));
- REPLACE(r);
- break;
-
- case Op_leq:
- r = make_number((AWKNUM) (cmp_scalar() <= 0));
- REPLACE(r);
- break;
-
- case Op_geq:
- r = make_number((AWKNUM) (cmp_scalar() >= 0));
- REPLACE(r);
- break;
-
- case Op_plus_i:
- x2 = force_number(pc->memory);
- goto plus;
-
- case Op_plus:
- POP_NUMBER(x2);
-plus:
- TOP_NUMBER(x1);
- r = make_number(x1 + x2);
- REPLACE(r);
- break;
-
- case Op_minus_i:
- x2 = force_number(pc->memory);
- goto minus;
-
- case Op_minus:
- POP_NUMBER(x2);
-minus:
- TOP_NUMBER(x1);
- r = make_number(x1 - x2);
- REPLACE(r);
- break;
-
- case Op_times_i:
- x2 = force_number(pc->memory);
- goto times;
-
- case Op_times:
- POP_NUMBER(x2);
-times:
- TOP_NUMBER(x1);
- r = make_number(x1 * x2);
- REPLACE(r);
- break;
-
- case Op_exp_i:
- x2 = force_number(pc->memory);
- goto exponent;
-
- case Op_exp:
- POP_NUMBER(x2);
-exponent:
- TOP_NUMBER(x1);
- x = calc_exp(x1, x2);
- r = make_number(x);
- REPLACE(r);
- break;
-
- case Op_quotient_i:
- x2 = force_number(pc->memory);
- goto quotient;
-
- case Op_quotient:
- POP_NUMBER(x2);
-quotient:
- if (x2 == 0)
- fatal(_("division by zero attempted"));
-
- TOP_NUMBER(x1);
- x = x1 / x2;
- r = make_number(x);
- REPLACE(r);
- break;
-
- case Op_mod_i:
- x2 = force_number(pc->memory);
- goto mod;
-
- case Op_mod:
- POP_NUMBER(x2);
-mod:
- if (x2 == 0)
- fatal(_("division by zero attempted in `%%'"));
-
- TOP_NUMBER(x1);
-#ifdef HAVE_FMOD
- x = fmod(x1, x2);
-#else /* ! HAVE_FMOD */
- (void) modf(x1 / x2, &x);
- x = x1 - x * x2;
-#endif /* ! HAVE_FMOD */
- r = make_number(x);
- REPLACE(r);
- break;
-
- case Op_preincrement:
- pre = TRUE;
- case Op_postincrement:
- x2 = 1.0;
-post:
- lhs = TOP_ADDRESS();
- x1 = force_number(*lhs);
- unref(*lhs);
- r = *lhs = make_number(x1 + x2);
- if (pre)
- UPREF(r);
- else
- r = make_number(x1);
- REPLACE(r);
- pre = FALSE;
- break;
-
- case Op_predecrement:
- pre = TRUE;
- case Op_postdecrement:
- x2 = -1.0;
- goto post;
-
- case Op_unary_minus:
- TOP_NUMBER(x1);
- r = make_number(-x1);
- REPLACE(r);
- break;
-
- case Op_store_sub:
- /* array[sub] assignment optimization,
- * see awkgram.y (optimize_assignment)
- */
- t1 = get_array(pc->memory, TRUE); /* array */
- t2 = mk_sub(pc->expr_count); /* subscript */
- lhs = assoc_lookup(t1, t2, FALSE);
- if ((*lhs)->type == Node_var_array)
- fatal(_("attempt to use array `%s[\"%.*s\"]' in a scalar context"),
- array_vname(t1), (int) t2->stlen, t2->stptr);
- DEREF(t2);
- unref(*lhs);
- *lhs = POP_SCALAR();
- break;
-
- case Op_store_var:
- /* simple variable assignment optimization,
- * see awkgram.y (optimize_assignment)
- */
-
- lhs = get_lhs(pc->memory, FALSE);
- unref(*lhs);
- *lhs = POP_SCALAR();
- break;
-
- case Op_store_field:
- {
- /* field assignment optimization,
- * see awkgram.y (optimize_assignment)
- */
-
- Func_ptr assign;
- t1 = TOP_SCALAR();
- lhs = r_get_field(t1, &assign, FALSE);
- decr_sp();
- DEREF(t1);
- unref(*lhs);
- *lhs = POP_SCALAR();
- assert(assign != NULL);
- assign();
- }
- break;
-
- case Op_assign_concat:
- /* x = x ... string concatenation optimization */
- lhs = get_lhs(pc->memory, FALSE);
- t1 = force_string(*lhs);
- t2 = POP_STRING();
-
- free_wstr(*lhs);
-
- if (t1 != t2 && t1->valref == 1 && (t1->flags & PERM) == 0) {
- size_t nlen = t1->stlen + t2->stlen;
- erealloc(t1->stptr, char *, nlen + 2, "r_interpret");
- memcpy(t1->stptr + t1->stlen, t2->stptr, t2->stlen);
- t1->stlen = nlen;
- t1->stptr[nlen] = '\0';
- } else {
- size_t nlen = t1->stlen + t2->stlen;
- char *p;
-
- emalloc(p, char *, nlen + 2, "r_interpret");
- memcpy(p, t1->stptr, t1->stlen);
- memcpy(p + t1->stlen, t2->stptr, t2->stlen);
- unref(*lhs);
- t1 = *lhs = make_str_node(p, nlen, ALREADY_MALLOCED);
- }
- t1->flags &= ~(NUMCUR|NUMBER);
- DEREF(t2);
- break;
-
- case Op_assign:
- lhs = POP_ADDRESS();
- r = TOP_SCALAR();
- unref(*lhs);
- *lhs = r;
- UPREF(r);
- REPLACE(r);
- break;
-
- /* numeric assignments */
- case Op_assign_plus:
- case Op_assign_minus:
- case Op_assign_times:
- case Op_assign_quotient:
- case Op_assign_mod:
- case Op_assign_exp:
- op_assign(pc->opcode);
- break;
-
- case Op_var_update: /* update value of NR, FNR or NF */
- pc->update_var();
- break;
-
- case Op_var_assign:
- case Op_field_assign:
- if (pc->assign_ctxt == Op_sub_builtin
- && TOP()->numbr == 0.0 /* top of stack has a number == 0 */
- ) {
- /* There wasn't any substitutions. If the target is a FIELD,
- * this means no field re-splitting or $0 reconstruction.
- * Skip the set_FOO routine if the target is a special variable.
- */
-
- break;
- } else if ((pc->assign_ctxt == Op_K_getline
- || pc->assign_ctxt == Op_K_getline_redir)
- && TOP()->numbr <= 0.0 /* top of stack has a number <= 0 */
- ) {
- /* getline returned EOF or error */
-
- break;
- }
-
- if (pc->opcode == Op_var_assign)
- pc->assign_var();
- else
- pc->field_assign();
- break;
-
- case Op_concat:
- r = concat_exp(pc->expr_count, pc->concat_flag & CSUBSEP);
- PUSH(r);
- break;
-
- case Op_K_case:
- if ((pc + 1)->match_exp) {
- /* match a constant regex against switch expression instead of $0. */
- m = POP(); /* regex */
- t2 = TOP_SCALAR(); /* switch expression */
- (void) force_string(t2);
- rp = re_update(m);
- di = (research(rp, t2->stptr, 0, t2->stlen,
- avoid_dfa(m, t2->stptr, t2->stlen)) >= 0);
- } else {
- t1 = POP_SCALAR(); /* case value */
- t2 = TOP_SCALAR(); /* switch expression */
- di = (cmp_nodes(t2, t1) == 0);
- DEREF(t1);
- }
-
- if (di) { /* match found */
- decr_sp();
- DEREF(t2);
- JUMPTO(pc->target_jmp);
- }
- break;
-
- case Op_K_delete:
- t1 = POP_ARRAY();
- do_delete(t1, pc->expr_count);
- stack_adj(-pc->expr_count);
- break;
-
- case Op_K_delete_loop:
- t1 = POP_ARRAY();
- lhs = POP_ADDRESS(); /* item */
- do_delete_loop(t1, lhs);
- break;
-
- case Op_in_array:
- t1 = POP_ARRAY();
- t2 = mk_sub(pc->expr_count);
- di = (in_array(t1, t2) != NULL);
- DEREF(t2);
- PUSH(make_number((AWKNUM) di));
- break;
-
- case Op_arrayfor_init:
- {
- NODE **list = NULL;
- NODE *array, *sort_str;
- size_t num_elems = 0;
- static NODE *sorted_in = NULL;
- const char *how_to_sort = "@unsorted";
-
- /* get the array */
- array = POP_ARRAY();
-
- /* sanity: check if empty */
- if (array->var_array == NULL || array->table_size == 0)
- goto arrayfor;
-
- num_elems = array->table_size;
-
- if (sorted_in == NULL) /* do this once */
- sorted_in = make_string("sorted_in", 9);
-
- sort_str = NULL;
- /*
- * If posix, or if there's no PROCINFO[],
- * there's no ["sorted_in"], so no sorting
- */
- if (! do_posix && PROCINFO_node != NULL)
- sort_str = in_array(PROCINFO_node, sorted_in);
-
- if (sort_str != NULL) {
- sort_str = force_string(sort_str);
- if (sort_str->stlen > 0)
- how_to_sort = sort_str->stptr;
- }
-
- list = assoc_list(array, how_to_sort, SORTED_IN);
-
- /*
- * Actual array for use in lint warning
- * in Op_arrayfor_incr
- */
- list[num_elems] = array;
-
-arrayfor:
- getnode(r);
- r->type = Node_arrayfor;
- r->var_array = list;
- r->table_size = num_elems; /* # of elements in list */
- r->array_size = -1; /* current index */
- PUSH(r);
-
- if (num_elems == 0)
- JUMPTO(pc->target_jmp); /* Op_arrayfor_final */
- }
- break;
-
- case Op_arrayfor_incr:
- r = TOP(); /* Node_arrayfor */
- if (++r->array_size == r->table_size) {
- NODE *array;
- array = r->var_array[r->table_size]; /* actual array */
- if (do_lint && array->table_size != r->table_size)
- lintwarn(_("for loop: array `%s' changed size from %ld to %ld during loop execution"),
- array_vname(array), (long) r->table_size, (long) array->table_size);
- JUMPTO(pc->target_jmp); /* Op_arrayfor_final */
- }
-
- t1 = r->var_array[r->array_size];
- lhs = get_lhs(pc->array_var, FALSE);
- unref(*lhs);
- *lhs = make_string(t1->ahname_str, t1->ahname_len);
- break;
-
- case Op_arrayfor_final:
- r = POP();
- assert(r->type == Node_arrayfor);
- free_arrayfor(r);
- break;
-
- case Op_builtin:
- r = pc->builtin(pc->expr_count);
-#if defined(GAWKDEBUG) || defined(ARRAYDEBUG)
- if (! r)
- last_was_stopme = TRUE;
- else
-#endif
- PUSH(r);
- break;
-
- case Op_sub_builtin: /* sub, gsub and gensub */
- r = do_sub(pc->expr_count, pc->sub_flags);
- PUSH(r);
- break;
-
- case Op_K_print:
- do_print(pc->expr_count, pc->redir_type);
- break;
-
- case Op_K_printf:
- do_printf(pc->expr_count, pc->redir_type);
- break;
-
- case Op_K_print_rec:
- do_print_rec(pc->expr_count, pc->redir_type);
- break;
-
- case Op_push_re:
- m = pc->memory;
- if (m->type == Node_dynregex) {
- r = POP_STRING();
- unref(m->re_exp);
- m->re_exp = r;
- }
- PUSH(m);
- break;
-
- case Op_match_rec:
- m = pc->memory;
- t1 = *get_field(0, (Func_ptr *) 0);
-match_re:
- rp = re_update(m);
- /*
- * Any place where research() is called with a last parameter of
- * zero, we need to use the avoid_dfa test. This appears here and
- * in the code for Op_K_case.
- *
- * A new or improved dfa that distinguishes beginning/end of
- * string from beginning/end of line will allow us to get rid of
- * this hack.
- *
- * The avoid_dfa() function is in re.c; it is not very smart.
- */
-
- di = research(rp, t1->stptr, 0, t1->stlen,
- avoid_dfa(m, t1->stptr, t1->stlen));
- di = (di == -1) ^ (pc->opcode != Op_nomatch);
- if(pc->opcode != Op_match_rec) {
- decr_sp();
- DEREF(t1);
- }
- r = make_number((AWKNUM) di);
- PUSH(r);
- break;
-
- case Op_nomatch:
- /* fall through */
- case Op_match:
- m = pc->memory;
- t1 = TOP_STRING();
- if (m->type == Node_dynregex) {
- unref(m->re_exp);
- m->re_exp = t1;
- decr_sp();
- t1 = TOP_STRING();
- }
- goto match_re;
- break;
-
- case Op_indirect_func_call:
- {
- int arg_count;
-
- f = NULL;
- arg_count = (pc + 1)->expr_count;
- t1 = PEEK(arg_count); /* indirect var */
- assert(t1->type == Node_val); /* @a[1](p) not allowed in grammar */
- (void) force_string(t1);
- if (t1->stlen > 0) {
- /* retrieve function definition node */
- f = pc->func_body;
- if (f != NULL && strcmp(f->vname, t1->stptr) == 0)
- /* indirect var hasn't been reassigned */
- goto func_call;
- f = lookup(t1->stptr);
- }
-
- if (f == NULL || f->type != Node_func)
- fatal(_("function called indirectly through `%s' does not exist"), pc->func_name);
- pc->func_body = f; /* save for next call */
-
- goto func_call;
- }
-
- case Op_func_call:
- /* retrieve function definition node */
- f = pc->func_body;
- if (f == NULL) {
- f = lookup(pc->func_name);
- if (f == NULL || f->type != Node_func)
- fatal(_("function `%s' not defined"), pc->func_name);
- pc->func_body = f; /* save for next call */
- }
-
- /* save current frame along with source */
-
-func_call:
- ni = setup_frame(pc);
-
- if (ni->opcode == Op_ext_func) {
- /* dynamically set source and line numbers for an extension builtin. */
- ni->source_file = source;
- ni->source_line = sourceline;
- ni->nexti->source_line = sourceline; /* Op_builtin */
- ni->nexti->nexti->source_line = sourceline; /* Op_K_return */
- }
-
- /* run the function instructions */
- JUMPTO(ni); /* Op_func or Op_ext_func */
-
- case Op_K_return:
- m = POP_SCALAR(); /* return value */
-
- ni = pop_fcall();
-
- /* put the return value back on stack */
- PUSH(m);
-
- JUMPTO(ni);
-
- case Op_K_getline_redir:
- if ((currule == BEGINFILE || currule == ENDFILE)
- && pc->into_var == FALSE
- && pc->redir_type == redirect_input)
- fatal(_("`getline' invalid inside `%s' rule"), ruletab[currule]);
- r = do_getline_redir(pc->into_var, pc->redir_type);
- PUSH(r);
- break;
-
- case Op_K_getline: /* no redirection */
- if (! currule || currule == BEGINFILE || currule == ENDFILE)
- fatal(_("non-redirected `getline' invalid inside `%s' rule"),
- ruletab[currule]);
-
- do {
- int ret;
- ret = nextfile(& curfile, FALSE);
- if (ret <= 0)
- r = do_getline(pc->into_var, curfile);
- else {
-
- /* Save execution state so that we can return to it
- * from Op_after_beginfile or Op_after_endfile.
- */
-
- push_exec_state(pc, currule, source, stack_ptr);
-
- if (curfile == NULL)
- JUMPTO((pc + 1)->target_endfile);
- else
- JUMPTO((pc + 1)->target_beginfile);
- }
- } while (r == NULL); /* EOF */
-
- PUSH(r);
- break;
-
- case Op_after_endfile:
- /* Find the execution state to return to */
- ni = pop_exec_state(& currule, & source, NULL);
-
- assert(ni->opcode == Op_newfile || ni->opcode == Op_K_getline);
- JUMPTO(ni);
-
- case Op_after_beginfile:
- after_beginfile(& curfile);
-
- /* Find the execution state to return to */
- ni = pop_exec_state(& currule, & source, NULL);
-
- assert(ni->opcode == Op_newfile || ni->opcode == Op_K_getline);
- if (ni->opcode == Op_K_getline
- || curfile == NULL /* skipping directory argument */
- )
- JUMPTO(ni);
-
- break; /* read a record, Op_get_record */
-
- case Op_newfile:
- {
- int ret;
-
- ret = nextfile(& curfile, FALSE);
-
- if (ret < 0) /* end of input */
- JUMPTO(pc->target_jmp); /* end block or Op_atexit */
-
- if (ret == 0) /* read a record */
- JUMPTO((pc + 1)->target_get_record);
-
- /* ret > 0 */
- /* Save execution state for use in Op_after_beginfile or Op_after_endfile. */
-
- push_exec_state(pc, currule, source, stack_ptr);
-
- if (curfile == NULL) /* EOF */
- JUMPTO(pc->target_endfile);
- /* else
- execute beginfile block */
- }
- break;
-
- case Op_get_record:
- {
- int errcode = 0;
-
- ni = pc->target_newfile;
- if (curfile == NULL) {
- /* from non-redirected getline, e.g.:
- * {
- * while (getline > 0) ;
- * }
- */
-
- ni = ni->target_jmp; /* end_block or Op_atexit */
- JUMPTO(ni);
- }
-
- if (inrec(curfile, & errcode) != 0) {
- if (errcode > 0 && (do_traditional || ! pc->has_endfile))
- fatal(_("error reading input file `%s': %s"),
- curfile->name, strerror(errcode));
-
- JUMPTO(ni);
- } /* else
- prog (rule) block */
- }
- break;
-
- case Op_K_nextfile:
- {
- int ret;
-
- if (currule != Rule && currule != BEGINFILE)
- fatal(_("`nextfile' cannot be called from a `%s' rule"),
- ruletab[currule]);
-
- ret = nextfile(& curfile, TRUE); /* skip current file */
-
- if (currule == BEGINFILE) {
- long stack_size;
-
- ni = pop_exec_state(& currule, & source, & stack_size);
-
- assert(ni->opcode == Op_K_getline || ni->opcode == Op_newfile);
-
- /* pop stack returning to the state of Op_K_getline or Op_newfile. */
- unwind_stack(stack_size);
-
- if (ret == 0) {
- /* There was an error opening the file;
- * don't run ENDFILE block(s).
- */
-
- JUMPTO(ni);
- } else {
- /* do run ENDFILE block(s) first. */
-
- /* Execution state to return to in Op_after_endfile. */
- push_exec_state(ni, currule, source, stack_ptr);
-
- JUMPTO(pc->target_endfile);
- }
- } /* else
- Start over with the first rule. */
-
- /* empty the run-time stack to avoid memory leak */
- pop_stack();
-
- /* Push an execution state for Op_after_endfile to return to */
- push_exec_state(pc->target_newfile, currule, source, stack_ptr);
-
- JUMPTO(pc->target_endfile);
- }
- break;
-
- case Op_K_exit:
- /* exit not allowed in user-defined comparison functions for "sorted_in";
- * This is done so that END blocks aren't executed more than once.
- */
- if (! currule)
- fatal(_("`exit' cannot be called in the current context"));
-
- exiting = TRUE;
- POP_NUMBER(x1);
- exit_val = (int) x1;
-#ifdef VMS
- if (exit_val == 0)
- exit_val = EXIT_SUCCESS;
- else if (exit_val == 1)
- exit_val = EXIT_FAILURE;
- /* else
- just pass anything else on through */
-#endif
-
- if (currule == BEGINFILE || currule == ENDFILE) {
-
- /* Find the rule of the saved execution state (Op_K_getline/Op_newfile).
- * This is needed to prevent multiple execution of any END rules:
- * gawk 'BEGINFILE { exit(1) } \
- * END { while (getline > 0); }' in1 in2
- */
-
- (void) pop_exec_state(& currule, & source, NULL);
- }
-
- pop_stack(); /* empty stack, don't leak memory */
-
- /* Jump to either the first END block instruction
- * or to Op_atexit.
- */
-
- if (currule == END)
- ni = pc->target_atexit;
- else
- ni = pc->target_end;
- JUMPTO(ni);
-
- case Op_K_next:
- if (currule != Rule)
- fatal(_("`next' cannot be called from a `%s' rule"), ruletab[currule]);
-
- pop_stack();
- JUMPTO(pc->target_jmp); /* Op_get_record, read next record */
-
- case Op_pop:
-#if defined(GAWKDEBUG) || defined(ARRAYDEBUG)
- if (last_was_stopme)
- last_was_stopme = FALSE;
- else
-#endif
- {
- r = POP_SCALAR();
- DEREF(r);
- }
- break;
-
- case Op_line_range:
- if (pc->triggered) /* evaluate right expression */
- JUMPTO(pc->target_jmp);
- /* else
- evaluate left expression */
- break;
+ if (posth)
+ post_execute = posth;
- case Op_cond_pair:
- {
- int result;
- INSTRUCTION *ip;
+ return TRUE;
+}
- t1 = TOP_SCALAR(); /* from right hand side expression */
- di = (eval_condition(t1) != 0);
- DEREF(t1);
- ip = pc->line_range; /* Op_line_range */
+/* interpreter routine when not debugging */
+#include "interpret.h"
- if (! ip->triggered && di) {
- /* not already triggered and left expression is TRUE */
- decr_sp();
- ip->triggered = TRUE;
- JUMPTO(ip->target_jmp); /* evaluate right expression */
- }
+/* interpreter routine with exec hook(s). Used when debugging and/or with MPFR. */
+#define r_interpret h_interpret
+#define EXEC_HOOK 1
+#include "interpret.h"
+#undef EXEC_HOOK
+#undef r_interpret
- result = ip->triggered || di;
- ip->triggered ^= di; /* update triggered flag */
- r = make_number((AWKNUM) result); /* final value of condition pair */
- REPLACE(r);
- JUMPTO(pc->target_jmp);
- }
- case Op_exec_count:
- INCREMENT(pc->exec_count);
- break;
+void
+init_interpret()
+{
+ long newval;
- case Op_no_op:
- case Op_K_do:
- case Op_K_while:
- case Op_K_for:
- case Op_K_arrayfor:
- case Op_K_switch:
- case Op_K_default:
- case Op_K_if:
- case Op_K_else:
- case Op_cond_exp:
- break;
+ if ((newval = getenv_long("GAWK_STACKSIZE")) > 0)
+ STACK_SIZE = newval;
- default:
- fatal(_("Sorry, don't know how to interpret `%s'"), opcode2str(pc->opcode));
- }
+ emalloc(stack_bottom, STACK_ITEM *, STACK_SIZE * sizeof(STACK_ITEM), "grow_stack");
+ stack_ptr = stack_bottom - 1;
+ stack_top = stack_bottom + STACK_SIZE - 1;
- JUMPTO(pc->nexti);
+ /* initialize frame pointer */
+ getnode(frame_ptr);
+ frame_ptr->type = Node_frame;
+ frame_ptr->stack = NULL;
+ frame_ptr->func_node = NULL; /* in main */
+ frame_ptr->num_tail_calls = 0;
+ frame_ptr->vname = NULL;
-/* } forever */
+ /* initialize TRUE and FALSE nodes */
+ node_Boolean[FALSE] = make_number(0.0);
+ node_Boolean[TRUE] = make_number(1.0);
+ if (! is_mpg_number(node_Boolean[FALSE])) {
+ node_Boolean[FALSE]->flags |= NUMINT;
+ node_Boolean[TRUE]->flags |= NUMINT;
+ }
- /* not reached */
- return 0;
+ /*
+ * Select the interpreter routine. The version without
+ * any exec hook support (r_interpret) is faster by about
+ * 5%, or more depending on the opcodes.
+ */
-#undef mk_sub
-#undef JUMPTO
+ if (num_exec_hook > 0)
+ interpret = h_interpret;
+ else
+ interpret = r_interpret;
}
+
diff --git a/eval_d.c b/eval_d.c
deleted file mode 100644
index 64a8e55a..00000000
--- a/eval_d.c
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * eval_p.c - compile eval.c with debugging turned on.
- */
-
-/*
- * Copyright (C) 2001 the Free Software Foundation, Inc.
- *
- * This file is part of GAWK, the GNU implementation of the
- * AWK Programming Language.
- *
- * GAWK is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * GAWK is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
- */
-
-#define DEBUGGING 1
-#include "eval.c"
diff --git a/eval_p.c b/eval_p.c
deleted file mode 100644
index c8afe666..00000000
--- a/eval_p.c
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * eval_p.c - compile eval.c with profiling turned on.
- */
-
-/*
- * Copyright (C) 2001 the Free Software Foundation, Inc.
- *
- * This file is part of GAWK, the GNU implementation of the
- * AWK Programming Language.
- *
- * GAWK is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 3 of the License, or
- * (at your option) any later version.
- *
- * GAWK is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
- */
-
-#define PROFILING 1
-#include "eval.c"
diff --git a/ext.c b/ext.c
index f3e783da..0f56849d 100644
--- a/ext.c
+++ b/ext.c
@@ -33,77 +33,72 @@
#include <dlfcn.h>
-/* do_ext --- load an extension */
+/* do_ext --- load an extension at run-time: interface to load_ext */
NODE *
do_ext(int nargs)
{
- NODE *obj;
- NODE *fun;
+ NODE *obj, *fun, *ret = NULL;
+ SRCFILE *s;
+ extern SRCFILE *srcfiles;
+
+ fun = POP_STRING();
+ obj = POP_STRING();
+
+ s = add_srcfile(SRC_EXTLIB, obj->stptr, srcfiles, NULL, NULL);
+ if (s != NULL)
+ ret = load_ext(s->fullpath, fun->stptr, obj);
+ DEREF(obj);
+ DEREF(fun);
+ if (ret == NULL)
+ ret = dupnode(Nnull_string);
+ return ret;
+}
+
+/* load_ext --- load an external library */
+
+NODE *
+load_ext(const char *lib_name, const char *init_func, NODE *obj)
+{
NODE *tmp = NULL;
NODE *(*func)(NODE *, void *);
void *dl;
int flags = RTLD_LAZY;
- int fatal_error = FALSE;
int *gpl_compat;
-#if 0
- static short warned = FALSE;
-#endif
if (do_sandbox)
fatal(_("extensions are not allowed in sandbox mode"));
-#if 0
- /* already done in parser */
- if (do_lint && ! warned) {
- warned = TRUE;
- lintwarn(_("`extension' is a gawk extension"));
- }
-#endif
-
if (do_traditional || do_posix)
- error(_("`extension' is a gawk extension"));
-
- fun = POP_STRING();
- obj = POP_STRING();
+ fatal(_("`extension' is a gawk extension"));
#ifdef RTLD_GLOBAL
flags |= RTLD_GLOBAL;
#endif
- if ((dl = dlopen(obj->stptr, flags)) == NULL) {
- /* fatal needs `obj', and we need to deallocate it! */
- msg(_("fatal: extension: cannot open `%s' (%s)\n"), obj->stptr,
+
+ if ((dl = dlopen(lib_name, flags)) == NULL)
+ fatal(_("extension: cannot open library `%s' (%s)\n"), lib_name,
dlerror());
- fatal_error = TRUE;
- goto done;
- }
/* Per the GNU Coding standards */
gpl_compat = (int *) dlsym(dl, "plugin_is_GPL_compatible");
- if (gpl_compat == NULL) {
- msg(_("fatal: extension: library `%s': does not define `plugin_is_GPL_compatible' (%s)\n"),
- obj->stptr, dlerror());
- fatal_error = TRUE;
- goto done;
- }
-
-
- func = (NODE *(*)(NODE *, void *)) dlsym(dl, fun->stptr);
- if (func == NULL) {
- msg(_("fatal: extension: library `%s': cannot call function `%s' (%s)\n"),
- obj->stptr, fun->stptr, dlerror());
- fatal_error = TRUE;
- goto done;
+ if (gpl_compat == NULL)
+ fatal(_("extension: library `%s': does not define `plugin_is_GPL_compatible' (%s)\n"),
+ lib_name, dlerror());
+ func = (NODE *(*)(NODE *, void *)) dlsym(dl, init_func);
+ if (func == NULL)
+ fatal(_("extension: library `%s': cannot call function `%s' (%s)\n"),
+ lib_name, init_func, dlerror());
+
+ if (obj == NULL) {
+ obj = make_string(lib_name, strlen(lib_name));
+ tmp = (*func)(obj, dl);
+ unref(tmp);
+ unref(obj);
+ return NULL;
}
tmp = (*func)(obj, dl);
- if (tmp == NULL)
- tmp = Nnull_string;
-done:
- DEREF(obj);
- DEREF(fun);
- if (fatal_error)
- gawk_exit(EXIT_FATAL);
return tmp;
}
@@ -113,14 +108,10 @@ done:
void
make_builtin(const char *name, NODE *(*func)(int), int count)
{
- NODE *p, *symbol, *f;
- INSTRUCTION *b, *r;
+ NODE *symbol, *f;
+ INSTRUCTION *b;
const char *sp;
- char *pname;
- char **vnames = NULL;
- char c, buf[200];
- size_t space_needed;
- int i;
+ char c;
sp = name;
if (sp == NULL || *sp == '\0')
@@ -136,126 +127,82 @@ make_builtin(const char *name, NODE *(*func)(int), int count)
if (f != NULL) {
if (f->type == Node_func) {
- INSTRUCTION *pc = f->code_ptr;
- if (pc->opcode != Op_ext_func) /* user-defined function */
- fatal(_("extension: can't redefine function `%s'"), name);
- else {
- /* multiple extension() calls etc. */
- if (do_lint)
- lintwarn(_("extension: function `%s' already defined"), name);
- return;
- }
+ /* user-defined function */
+ fatal(_("extension: can't redefine function `%s'"), name);
+ } else if (f->type == Node_ext_func) {
+ /* multiple extension() calls etc. */
+ if (do_lint)
+ lintwarn(_("extension: function `%s' already defined"), name);
+ return;
} else
/* variable name etc. */
fatal(_("extension: function name `%s' previously defined"), name);
} else if (check_special(name) >= 0)
fatal(_("extension: can't use gawk built-in `%s' as function name"), name);
- /* count parameters, create artificial list of param names */
if (count < 0)
fatal(_("make_builtin: negative argument count for function `%s'"),
- name);
-
- if (count > 0) {
- sprintf(buf, "p%d", count);
- space_needed = strlen(buf) + 1;
- emalloc(vnames, char **, count * sizeof(char *), "make_builtin");
- for (i = 0; i < count; i++) {
- emalloc(pname, char *, space_needed, "make_builtin");
- sprintf(pname, "p%d", i);
- vnames[i] = pname;
- }
- }
-
-
- getnode(p);
- p->type = Node_param_list;
- p->flags |= FUNC;
- /* get our own copy for name */
- p->param = estrdup(name, strlen(name));
- p->param_cnt = count;
+ name);
- /* actual source and line numbers set at runtime for these instructions */
- b = bcalloc(Op_builtin, 1, __LINE__);
+ b = bcalloc(Op_symbol, 1, 0);
b->builtin = func;
b->expr_count = count;
- b->nexti = bcalloc(Op_K_return, 1, __LINE__);
- r = bcalloc(Op_ext_func, 1, __LINE__);
- r->source_file = __FILE__;
- r->nexti = b;
/* NB: extension sub must return something */
- symbol = mk_symbol(Node_func, p);
- symbol->parmlist = vnames;
- symbol->code_ptr = r;
- r->func_body = symbol;
- (void) install_symbol(p->param, symbol);
+ symbol = install_symbol(estrdup(name, strlen(name)), Node_ext_func);
+ symbol->code_ptr = b;
}
-/* get_curfunc_arg_count --- return number actual parameters */
-
-size_t
-get_curfunc_arg_count()
-{
- size_t argc;
- INSTRUCTION *pc;
-
- pc = (INSTRUCTION *) frame_ptr->reti; /* Op_func_call instruction */
- argc = (pc + 1)->expr_count; /* # of arguments supplied */
- return argc;
-}
-
-
-/* get_argument --- get the n'th argument of a dynamically linked function */
+/* get_argument --- get the i'th argument of a dynamically linked function */
NODE *
get_argument(int i)
{
- int pcount;
- NODE *t, *f;
- int actual_args;
+ NODE *t;
+ int arg_count, pcount;
INSTRUCTION *pc;
- f = frame_ptr->func_node;
- pcount = f->lnode->param_cnt;
+ pc = TOP()->code_ptr; /* Op_ext_builtin instruction */
+ pcount = (pc + 1)->expr_count; /* max # of arguments */
+ arg_count = pc->expr_count; /* # of arguments supplied */
- pc = (INSTRUCTION *) frame_ptr->reti; /* Op_func_call instruction */
- actual_args = (pc + 1)->expr_count; /* # of arguments supplied */
-
- if (i < 0 || i >= pcount || i >= actual_args)
+ if (i < 0 || i >= pcount || i >= arg_count)
return NULL;
- t = GET_PARAM(i);
+ t = PEEK(arg_count - i);
+ if (t->type == Node_param_list)
+ t = GET_PARAM(t->param_cnt);
if (t->type == Node_array_ref)
- return t->orig_array; /* Node_var_new or Node_var_array */
- if (t->type == Node_var_new || t->type == Node_var_array)
- return t;
- return t->var_value;
+ t = t->orig_array;
+ if (t->type == Node_var) /* See Case Node_var in setup_frame(), eval.c */
+ return Nnull_string;
+ /* Node_var_new, Node_var_array or Node_val */
+ return t;
}
-/* get_actual_argument --- get a scalar or array, allowed to be optional */
+/* get_actual_argument --- get the i'th scalar or array argument of a
+ dynamically linked function, allowed to be optional.
+*/
NODE *
get_actual_argument(int i, int optional, int want_array)
{
- /* optional : if TRUE and i th argument not present return NULL, else fatal. */
-
- NODE *t, *f;
- int pcount;
+ NODE *t;
char *fname;
-
+ int pcount;
+ INSTRUCTION *pc;
+
+ pc = TOP()->code_ptr; /* Op_ext_builtin instruction */
+ fname = (pc + 1)->func_name;
+ pcount = (pc + 1)->expr_count;
+
t = get_argument(i);
-
- f = frame_ptr->func_node;
- pcount = f->lnode->param_cnt;
- fname = f->lnode->param;
-
if (t == NULL) {
- if (i >= pcount) /* must be fatal */
+ if (i >= pcount) /* must be fatal */
fatal(_("function `%s' defined to take no more than %d argument(s)"),
fname, pcount);
if (! optional)
@@ -269,8 +216,8 @@ get_actual_argument(int i, int optional, int want_array)
return get_array(t, FALSE);
else {
t->type = Node_var;
- t->var_value = Nnull_string;
- return Nnull_string;
+ t->var_value = dupnode(Nnull_string);
+ return t->var_value;
}
}
@@ -283,6 +230,7 @@ get_actual_argument(int i, int optional, int want_array)
fatal(_("function `%s': argument #%d: attempt to use array as a scalar"),
fname, i + 1);
}
+ assert(t->type == Node_var_array || t->type == Node_val);
return t;
}
@@ -299,4 +247,13 @@ do_ext(int nargs)
ERRNO_node->var_value = make_string(emsg, strlen(emsg));
return make_number((AWKNUM) -1);
}
+
+/* load_ext --- dummy version if extensions not available */
+
+NODE *
+load_ext(const char *lib_name, const char *init_func, NODE *obj)
+{
+ fatal(_("dynamic loading of library not supported"));
+ return NULL;
+}
#endif
diff --git a/extension/ChangeLog b/extension/ChangeLog
index d684afe9..0b3053ed 100644
--- a/extension/ChangeLog
+++ b/extension/ChangeLog
@@ -1,3 +1,8 @@
+2011-08-31 John Haque <j.eh@mchsi.com>
+
+ * arrayparm.c, filefuncs.c, fork.c, ordchr.c, readfile.c,
+ rwarray.c, testarg.c: Updated.
+
2012-03-28 Arnold D. Robbins <arnold@skeeve.com>
* 4.0.1: Release tar ball made.
diff --git a/extension/arrayparm.c b/extension/arrayparm.c
index 8a550ace..b0aee33d 100644
--- a/extension/arrayparm.c
+++ b/extension/arrayparm.c
@@ -43,13 +43,13 @@ int plugin_is_GPL_compatible;
*/
static NODE *
-do_mkarray(int args)
+do_mkarray(int nargs)
{
int ret = -1;
NODE *var, *sub, *val;
NODE **elemval;
- if (do_lint && get_curfunc_arg_count() > 3)
+ if (do_lint && nargs > 3)
lintwarn("mkarray: called with too many arguments");
var = get_array_argument(0, FALSE);
@@ -60,9 +60,9 @@ do_mkarray(int args)
printf("sub->type = %s\n", nodetype2str(sub->type));
printf("val->type = %s\n", nodetype2str(val->type));
- assoc_clear(var);
+ assoc_clear(var, NULL);
- elemval = assoc_lookup(var, sub, 0);
+ elemval = assoc_lookup(var, sub);
*elemval = dupnode(val);
ret = 0;
diff --git a/extension/filefuncs.c b/extension/filefuncs.c
index ad7828f3..1a0a86ef 100644
--- a/extension/filefuncs.c
+++ b/extension/filefuncs.c
@@ -41,7 +41,7 @@ do_chdir(int nargs)
NODE *newdir;
int ret = -1;
- if (do_lint && get_curfunc_arg_count() != 1)
+ if (do_lint && nargs != 1)
lintwarn("chdir: called with incorrect number of arguments");
newdir = get_scalar_argument(0, FALSE);
@@ -169,7 +169,7 @@ do_stat(int nargs)
char *pmode; /* printable mode */
char *type = "unknown";
- if (do_lint && get_curfunc_arg_count() > 2)
+ if (do_lint && nargs > 2)
lintwarn("stat: called with too many arguments");
/* file is first arg, array to hold results is second */
@@ -177,7 +177,7 @@ do_stat(int nargs)
array = get_array_argument(1, FALSE);
/* empty out the array */
- assoc_clear(array);
+ assoc_clear(array, NULL);
/* lstat the file, if error, set ERRNO and return */
(void) force_string(file);
@@ -188,76 +188,76 @@ do_stat(int nargs)
}
/* fill in the array */
- aptr = assoc_lookup(array, tmp = make_string("name", 4), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("name", 4));
*aptr = dupnode(file);
unref(tmp);
- aptr = assoc_lookup(array, tmp = make_string("dev", 3), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("dev", 3));
*aptr = make_number((AWKNUM) sbuf.st_dev);
unref(tmp);
- aptr = assoc_lookup(array, tmp = make_string("ino", 3), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("ino", 3));
*aptr = make_number((AWKNUM) sbuf.st_ino);
unref(tmp);
- aptr = assoc_lookup(array, tmp = make_string("mode", 4), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("mode", 4));
*aptr = make_number((AWKNUM) sbuf.st_mode);
unref(tmp);
- aptr = assoc_lookup(array, tmp = make_string("nlink", 5), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("nlink", 5));
*aptr = make_number((AWKNUM) sbuf.st_nlink);
unref(tmp);
- aptr = assoc_lookup(array, tmp = make_string("uid", 3), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("uid", 3));
*aptr = make_number((AWKNUM) sbuf.st_uid);
unref(tmp);
- aptr = assoc_lookup(array, tmp = make_string("gid", 3), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("gid", 3));
*aptr = make_number((AWKNUM) sbuf.st_gid);
unref(tmp);
- aptr = assoc_lookup(array, tmp = make_string("size", 4), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("size", 4));
*aptr = make_number((AWKNUM) sbuf.st_size);
unref(tmp);
- aptr = assoc_lookup(array, tmp = make_string("blocks", 6), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("blocks", 6));
*aptr = make_number((AWKNUM) sbuf.st_blocks);
unref(tmp);
- aptr = assoc_lookup(array, tmp = make_string("atime", 5), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("atime", 5));
*aptr = make_number((AWKNUM) sbuf.st_atime);
unref(tmp);
- aptr = assoc_lookup(array, tmp = make_string("mtime", 5), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("mtime", 5));
*aptr = make_number((AWKNUM) sbuf.st_mtime);
unref(tmp);
- aptr = assoc_lookup(array, tmp = make_string("ctime", 5), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("ctime", 5));
*aptr = make_number((AWKNUM) sbuf.st_ctime);
unref(tmp);
/* for block and character devices, add rdev, major and minor numbers */
if (S_ISBLK(sbuf.st_mode) || S_ISCHR(sbuf.st_mode)) {
- aptr = assoc_lookup(array, tmp = make_string("rdev", 4), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("rdev", 4));
*aptr = make_number((AWKNUM) sbuf.st_rdev);
unref(tmp);
- aptr = assoc_lookup(array, tmp = make_string("major", 5), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("major", 5));
*aptr = make_number((AWKNUM) major(sbuf.st_rdev));
unref(tmp);
- aptr = assoc_lookup(array, tmp = make_string("minor", 5), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("minor", 5));
*aptr = make_number((AWKNUM) minor(sbuf.st_rdev));
unref(tmp);
}
#ifdef HAVE_ST_BLKSIZE
- aptr = assoc_lookup(array, tmp = make_string("blksize", 7), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("blksize", 7));
*aptr = make_number((AWKNUM) sbuf.st_blksize);
unref(tmp);
#endif /* HAVE_ST_BLKSIZE */
- aptr = assoc_lookup(array, tmp = make_string("pmode", 5), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("pmode", 5));
pmode = format_mode(sbuf.st_mode);
*aptr = make_string(pmode, strlen(pmode));
unref(tmp);
@@ -277,7 +277,7 @@ do_stat(int nargs)
*/
buf[linksize] = '\0';
- aptr = assoc_lookup(array, tmp = make_string("linkval", 7), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("linkval", 7));
*aptr = make_str_node(buf, linksize, ALREADY_MALLOCED);
unref(tmp);
}
@@ -319,7 +319,7 @@ do_stat(int nargs)
#endif
}
- aptr = assoc_lookup(array, tmp = make_string("type", 4), FALSE);
+ aptr = assoc_lookup(array, tmp = make_string("type", 4));
*aptr = make_string(type, strlen(type));
unref(tmp);
diff --git a/extension/fork.c b/extension/fork.c
index aff9b568..88353879 100644
--- a/extension/fork.c
+++ b/extension/fork.c
@@ -38,7 +38,7 @@ do_fork(int nargs)
NODE **aptr;
NODE *tmp;
- if (do_lint && get_curfunc_arg_count() > 0)
+ if (do_lint && nargs > 0)
lintwarn("fork: called with too many arguments");
ret = fork();
@@ -48,11 +48,11 @@ do_fork(int nargs)
else if (ret == 0) {
/* update PROCINFO in the child */
- aptr = assoc_lookup(PROCINFO_node, tmp = make_string("pid", 3), FALSE);
+ aptr = assoc_lookup(PROCINFO_node, tmp = make_string("pid", 3));
(*aptr)->numbr = (AWKNUM) getpid();
unref(tmp);
- aptr = assoc_lookup(PROCINFO_node, tmp = make_string("ppid", 4), FALSE);
+ aptr = assoc_lookup(PROCINFO_node, tmp = make_string("ppid", 4));
(*aptr)->numbr = (AWKNUM) getppid();
unref(tmp);
}
@@ -73,7 +73,7 @@ do_waitpid(int nargs)
pid_t pid;
int options = 0;
- if (do_lint && get_curfunc_arg_count() > 1)
+ if (do_lint && nargs > 1)
lintwarn("waitpid: called with too many arguments");
pidnode = get_scalar_argument(0, FALSE);
diff --git a/extension/ordchr.c b/extension/ordchr.c
index efbc6d56..8926a949 100644
--- a/extension/ordchr.c
+++ b/extension/ordchr.c
@@ -40,7 +40,7 @@ do_ord(int nargs)
NODE *str;
int ret = -1;
- if (do_lint && get_curfunc_arg_count() > 1)
+ if (do_lint && nargs > 1)
lintwarn("ord: called with too many arguments");
str = get_scalar_argument(0, FALSE);
@@ -67,7 +67,7 @@ do_chr(int nargs)
str[0] = str[1] = '\0';
- if (do_lint && get_curfunc_arg_count() > 1)
+ if (do_lint && nargs > 1)
lintwarn("chr: called with too many arguments");
num = get_scalar_argument(0, FALSE);
diff --git a/extension/readfile.c b/extension/readfile.c
index e6ee0f22..c9b1efc3 100644
--- a/extension/readfile.c
+++ b/extension/readfile.c
@@ -50,7 +50,7 @@ do_readfile(int nargs)
char *text;
int fd;
- if (do_lint && get_curfunc_arg_count() > 1)
+ if (do_lint && nargs > 1)
lintwarn("readfile: called with too many arguments");
filename = get_scalar_argument(0, FALSE);
diff --git a/extension/rwarray.c b/extension/rwarray.c
index 3c629579..8175c7c0 100644
--- a/extension/rwarray.c
+++ b/extension/rwarray.c
@@ -82,7 +82,7 @@ do_writea(int nargs)
uint32_t major = MAJOR;
uint32_t minor = MINOR;
- if (do_lint && get_curfunc_arg_count() > 2)
+ if (do_lint && nargs > 2)
lintwarn("writea: called with too many arguments");
/* directory is first arg, array to dump is second */
@@ -250,7 +250,7 @@ do_reada(int nargs)
uint32_t minor;
char magic_buf[30];
- if (do_lint && get_curfunc_arg_count() > 2)
+ if (do_lint && nargs > 2)
lintwarn("reada: called with too many arguments");
/* directory is first arg, array to dump is second */
@@ -289,7 +289,7 @@ do_reada(int nargs)
goto done1;
}
- assoc_clear(array);
+ assoc_clear(array, NULL);
ret = read_array(fd, array);
if (ret == 0)
diff --git a/extension/testarg.c b/extension/testarg.c
index ba4d56ff..4d012db5 100644
--- a/extension/testarg.c
+++ b/extension/testarg.c
@@ -5,17 +5,15 @@ int plugin_is_GPL_compatible;
static NODE *
do_check_arg(int nargs)
{
- int ret = 0, argc;
+ int ret = 0;
NODE *arg1, *arg2, *arg3;
- argc = get_curfunc_arg_count();
- printf("arg count: defined = %d, supplied = %d\n",
- nargs, argc);
+ printf("arg count: defined = 3, supplied = %d\n", nargs);
arg1 = get_scalar_argument(0, FALSE);
arg2 = get_array_argument(1, FALSE);
arg3 = get_scalar_argument(2, TRUE); /* optional */
- if (argc > 3) {
+ if (nargs > 3) {
/* try to use an extra arg */
NODE *arg4;
arg4 = get_array_argument(3, TRUE);
diff --git a/field.c b/field.c
index 2e7c1505..68bd699d 100644
--- a/field.c
+++ b/field.c
@@ -85,13 +85,13 @@ void
init_fields()
{
emalloc(fields_arr, NODE **, sizeof(NODE *), "init_fields");
- fields_arr[0] = Nnull_string;
+ fields_arr[0] = dupnode(Nnull_string);
parse_extent = fields_arr[0]->stptr;
save_FS = dupnode(FS_node->var_value);
getnode(Null_field);
*Null_field = *Nnull_string;
- Null_field->flags |= FIELD;
- Null_field->flags &= ~(NUMCUR|NUMBER|MAYBE_NUM|PERM|MALLOC);
+ Null_field->valref = 1;
+ Null_field->flags = (FIELD|STRCUR|STRING);
field0_valid = TRUE;
}
@@ -194,24 +194,34 @@ rebuild_record()
* so that unrefing a field doesn't try to unref into the old $0.
*/
for (cops = ops, i = 1; i <= NF; i++) {
- if (fields_arr[i]->stlen > 0) {
+ NODE *r = fields_arr[i];
+ if (r->stlen > 0) {
NODE *n;
getnode(n);
- if ((fields_arr[i]->flags & FIELD) == 0) {
+ if ((r->flags & FIELD) == 0) {
*n = *Null_field;
- n->stlen = fields_arr[i]->stlen;
- if ((fields_arr[i]->flags & (NUMCUR|NUMBER)) != 0) {
- n->flags |= (fields_arr[i]->flags & (NUMCUR|NUMBER));
- n->numbr = fields_arr[i]->numbr;
+ n->stlen = r->stlen;
+ if ((r->flags & (NUMCUR|NUMBER)) != 0) {
+ n->flags |= (r->flags & (MPFN|MPZN|NUMCUR|NUMBER));
+#ifdef HAVE_MPFR
+ if (is_mpg_float(r)) {
+ mpfr_init(n->mpg_numbr);
+ mpfr_set(n->mpg_numbr, r->mpg_numbr, ROUND_MODE);
+ } else if (is_mpg_integer(r)) {
+ mpz_init(n->mpg_i);
+ mpz_set(n->mpg_i, r->mpg_i);
+ } else
+#endif
+ n->numbr = r->numbr;
}
} else {
- *n = *(fields_arr[i]);
- n->flags &= ~(MALLOC|PERM|STRING);
+ *n = *r;
+ n->flags &= ~(MALLOC|STRING);
}
n->stptr = cops;
- unref(fields_arr[i]);
+ unref(r);
fields_arr[i] = n;
assert((n->flags & WSTRCUR) == 0);
}
@@ -289,7 +299,7 @@ reset_record()
int i;
NODE *n;
- (void) force_string(fields_arr[0]);
+ fields_arr[0] = force_string(fields_arr[0]);
NF = -1;
for (i = 1; i <= parse_high_water; i++) {
@@ -323,7 +333,8 @@ set_NF()
assert(NF != -1);
- nf = (long) force_number(NF_node->var_value);
+ (void) force_number(NF_node->var_value);
+ nf = get_number_si(NF_node->var_value);
if (nf < 0)
fatal(_("NF set to negative value"));
NF = nf;
@@ -927,7 +938,7 @@ set_element(long num, char *s, long len, NODE *n)
it = make_string(s, len);
it->flags |= MAYBE_NUM;
sub = make_number((AWKNUM) (num));
- lhs = assoc_lookup(n, sub, FALSE);
+ lhs = assoc_lookup(n, sub);
unref(sub);
unref(*lhs);
*lhs = it;
@@ -988,8 +999,8 @@ do_split(int nargs)
/*
* Skip the work if first arg is the null string.
*/
- decr_sp();
- DEREF(src);
+ tmp = POP_SCALAR();
+ DEREF(tmp);
return make_number((AWKNUM) 0);
}
@@ -1027,7 +1038,7 @@ do_split(int nargs)
tmp = make_number((AWKNUM) (*parseit)(UNLIMITED, &s, (int) src->stlen,
fs, rp, set_element, arr, sep_arr, FALSE));
- decr_sp();
+ src = POP_SCALAR(); /* really pop off stack */
DEREF(src);
return tmp;
}
@@ -1088,7 +1099,7 @@ do_patsplit(int nargs)
set_element, arr, sep_arr, FALSE));
}
- decr_sp(); /* 1st argument not POP-ed */
+ src = POP_SCALAR(); /* really pop off stack */
DEREF(src);
return tmp;
}
@@ -1104,6 +1115,7 @@ set_FIELDWIDTHS()
static int fw_alloc = 4;
static short warned = FALSE;
int fatal_error = FALSE;
+ NODE *tmp;
if (do_lint && ! warned) {
warned = TRUE;
@@ -1120,7 +1132,8 @@ set_FIELDWIDTHS()
(void) get_field(UNLIMITED - 1, 0);
parse_field = fw_parse_field;
- scan = force_string(FIELDWIDTHS_node->var_value)->stptr;
+ tmp = force_string(FIELDWIDTHS_node->var_value);
+ scan = tmp->stptr;
if (FIELDWIDTHS == NULL)
emalloc(FIELDWIDTHS, int *, fw_alloc * sizeof(int), "set_FIELDWIDTHS");
@@ -1331,7 +1344,7 @@ update_PROCINFO_str(const char *subscript, const char *str)
if (PROCINFO_node == NULL)
return;
tmp = make_string(subscript, strlen(subscript));
- aptr = assoc_lookup(PROCINFO_node, tmp, FALSE);
+ aptr = assoc_lookup(PROCINFO_node, tmp);
unref(tmp);
unref(*aptr);
*aptr = make_string(str, strlen(str));
@@ -1348,7 +1361,7 @@ update_PROCINFO_num(const char *subscript, AWKNUM val)
if (PROCINFO_node == NULL)
return;
tmp = make_string(subscript, strlen(subscript));
- aptr = assoc_lookup(PROCINFO_node, tmp, FALSE);
+ aptr = assoc_lookup(PROCINFO_node, tmp);
unref(tmp);
unref(*aptr);
*aptr = make_number(val);
diff --git a/int_array.c b/int_array.c
new file mode 100644
index 00000000..0fa37642
--- /dev/null
+++ b/int_array.c
@@ -0,0 +1,799 @@
+/*
+ * int_array.c - routines for arrays of integer indices.
+ */
+
+/*
+ * Copyright (C) 1986, 1988, 1989, 1991-2011 the Free Software Foundation, Inc.
+ *
+ * This file is part of GAWK, the GNU implementation of the
+ * AWK Programming Language.
+ *
+ * GAWK is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * GAWK is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
+ */
+
+#include "awk.h"
+
+extern FILE *output_fp;
+extern void indent(int indent_level);
+extern NODE **is_integer(NODE *symbol, NODE *subs);
+
+static size_t INT_CHAIN_MAX = 2;
+
+static NODE **int_array_init(NODE *symbol, NODE *subs);
+static NODE **int_lookup(NODE *symbol, NODE *subs);
+static NODE **int_exists(NODE *symbol, NODE *subs);
+static NODE **int_clear(NODE *symbol, NODE *subs);
+static NODE **int_remove(NODE *symbol, NODE *subs);
+static NODE **int_list(NODE *symbol, NODE *t);
+static NODE **int_copy(NODE *symbol, NODE *newsymb);
+static NODE **int_dump(NODE *symbol, NODE *ndump);
+
+static uint32_t int_hash(uint32_t k, uint32_t hsize);
+static inline NODE **int_find(NODE *symbol, long k, uint32_t hash1);
+static NODE **int_insert(NODE *symbol, long k, uint32_t hash1);
+static void grow_int_table(NODE *symbol);
+
+array_ptr int_array_func[] = {
+ int_array_init,
+ is_integer,
+ int_lookup,
+ int_exists,
+ int_clear,
+ int_remove,
+ int_list,
+ int_copy,
+ int_dump,
+};
+
+
+/* int_array_init --- check relevant environment variables */
+
+static NODE **
+int_array_init(NODE *symbol ATTRIBUTE_UNUSED, NODE *subs ATTRIBUTE_UNUSED)
+{
+ long newval;
+
+ if ((newval = getenv_long("INT_CHAIN_MAX")) > 0)
+ INT_CHAIN_MAX = newval;
+ return (NODE **) ! NULL;
+}
+
+
+/* is_integer --- check if subscript is an integer */
+
+NODE **
+is_integer(NODE *symbol, NODE *subs)
+{
+ long l;
+ AWKNUM d;
+
+ if (subs == Nnull_string || do_mpfr)
+ return NULL;
+
+ if ((subs->flags & NUMINT) != 0)
+ return (NODE **) ! NULL;
+
+ if ((subs->flags & NUMBER) != 0) {
+ d = subs->numbr;
+ if (d <= INT32_MAX && d >= INT32_MIN && d == (int32_t) d) {
+ subs->flags |= NUMINT;
+ return (NODE **) ! NULL;
+ }
+ return NULL;
+ }
+
+ /* a[3]=1; print "3" in a -- TRUE
+ * a[3]=1; print "+3" in a -- FALSE
+ * a[3]=1; print "03" in a -- FALSE
+ * a[-3]=1; print "-3" in a -- TRUE
+ */
+
+ if ((subs->flags & (STRING|STRCUR)) != 0) {
+ char *cp = subs->stptr, *cpend, *ptr;
+ char save;
+ size_t len = subs->stlen;
+
+ if (len == 0 || (! isdigit((unsigned char) *cp) && *cp != '-'))
+ return NULL;
+ if (len > 1 &&
+ ((*cp == '0') /* "00", "011" .. */
+ || (*cp == '-' && *(cp + 1) == '0') /* "-0", "-011" .. */
+ )
+ )
+ return NULL;
+ if (len == 1 && *cp != '-') { /* single digit */
+ subs->numbr = (long) (*cp - '0');
+ if ((subs->flags & MAYBE_NUM) != 0) {
+ subs->flags &= ~MAYBE_NUM;
+ subs->flags |= NUMBER;
+ }
+ subs->flags |= (NUMCUR|NUMINT);
+ return (NODE **) ! NULL;
+ }
+
+ cpend = cp + len;
+ save = *cpend;
+ *cpend = '\0';
+
+ errno = 0;
+ l = strtol(cp, & ptr, 10);
+ *cpend = save;
+ if (errno != 0 || ptr != cpend)
+ return NULL;
+ subs->numbr = l;
+ if ((subs->flags & MAYBE_NUM) != 0) {
+ subs->flags &= ~MAYBE_NUM;
+ subs->flags |= NUMBER;
+ }
+ subs->flags |= NUMCUR;
+ if (l <= INT32_MAX && l >= INT32_MIN) {
+ subs->flags |= NUMINT;
+ return (NODE **) ! NULL;
+ }
+ }
+ return NULL;
+}
+
+
+/* int_lookup --- Find SYMBOL[SUBS] in the assoc array. Install it with value ""
+ * if it isn't there. Returns a pointer ala get_lhs to where its value is stored.
+ */
+
+static NODE **
+int_lookup(NODE *symbol, NODE *subs)
+{
+ uint32_t hash1;
+ long k;
+ unsigned long size;
+ NODE **lhs;
+ NODE *xn;
+
+ /* N.B: symbol->table_size is the total # of non-integers (symbol->xarray)
+ * and integer elements. Also, symbol->xarray must have at least one
+ * item in it, and can not exist if there are no integer elements.
+ * In that case, symbol->xarray is promoted to 'symbol' (See int_remove).
+ */
+
+
+ if (! is_integer(symbol, subs)) {
+ xn = symbol->xarray;
+ if (xn == NULL) {
+ xn = symbol->xarray = make_array();
+ xn->vname = symbol->vname; /* shallow copy */
+ xn->flags |= XARRAY;
+ } else if ((lhs = xn->aexists(xn, subs)) != NULL)
+ return lhs;
+ symbol->table_size++;
+ return assoc_lookup(xn, subs);
+ }
+
+ k = subs->numbr;
+ if (symbol->buckets == NULL)
+ grow_int_table(symbol);
+
+ hash1 = int_hash(k, symbol->array_size);
+ if ((lhs = int_find(symbol, k, hash1)) != NULL)
+ return lhs;
+
+ /* It's not there, install it */
+
+ symbol->table_size++;
+
+ /* first see if we would need to grow the array, before installing */
+ size = symbol->table_size;
+ if ((xn = symbol->xarray) != NULL)
+ size -= xn->table_size;
+
+ if ((symbol->flags & ARRAYMAXED) == 0
+ && (size / symbol->array_size) > INT_CHAIN_MAX) {
+ grow_int_table(symbol);
+ /* have to recompute hash value for new size */
+ hash1 = int_hash(k, symbol->array_size);
+ }
+
+ return int_insert(symbol, k, hash1);
+}
+
+
+/* int_exists --- test whether the array element symbol[subs] exists or not,
+ * return pointer to value if it does.
+ */
+
+static NODE **
+int_exists(NODE *symbol, NODE *subs)
+{
+ long k;
+ uint32_t hash1;
+
+ if (! is_integer(symbol, subs)) {
+ NODE *xn = symbol->xarray;
+ if (xn == NULL)
+ return NULL;
+ return xn->aexists(xn, subs);
+ }
+ if (symbol->buckets == NULL)
+ return NULL;
+
+ k = subs->numbr;
+ hash1 = int_hash(k, symbol->array_size);
+ return int_find(symbol, k, hash1);
+}
+
+/* int_clear --- flush all the values in symbol[] */
+
+static NODE **
+int_clear(NODE *symbol, NODE *subs ATTRIBUTE_UNUSED)
+{
+ unsigned long i;
+ int j;
+ BUCKET *b, *next;
+ NODE *r;
+
+ if (symbol->xarray != NULL) {
+ NODE *xn = symbol->xarray;
+ assoc_clear(xn);
+ freenode(xn);
+ symbol->xarray = NULL;
+ }
+
+ for (i = 0; i < symbol->array_size; i++) {
+ for (b = symbol->buckets[i]; b != NULL; b = next) {
+ next = b->ainext;
+ for (j = 0; j < b->aicount; j++) {
+ r = b->aivalue[j];
+ if (r->type == Node_var_array) {
+ assoc_clear(r); /* recursively clear all sub-arrays */
+ efree(r->vname);
+ freenode(r);
+ } else
+ unref(r);
+ }
+ freebucket(b);
+ }
+ symbol->buckets[i] = NULL;
+ }
+ if (symbol->buckets != NULL)
+ efree(symbol->buckets);
+ init_array(symbol); /* re-initialize symbol */
+ symbol->flags &= ~ARRAYMAXED;
+ return NULL;
+}
+
+
+/* int_remove --- If SUBS is already in the table, remove it. */
+
+static NODE **
+int_remove(NODE *symbol, NODE *subs)
+{
+ uint32_t hash1;
+ BUCKET *b, *prev = NULL;
+ long k;
+ int i;
+ NODE *xn = symbol->xarray;
+
+ if (symbol->table_size == 0 || symbol->buckets == NULL)
+ return NULL;
+
+ if (! is_integer(symbol, subs)) {
+ if (xn == NULL || xn->aremove(xn, subs) == NULL)
+ return NULL;
+ if (xn->table_size == 0) {
+ freenode(xn);
+ symbol->xarray = NULL;
+ }
+ symbol->table_size--;
+ assert(symbol->table_size > 0);
+ return (NODE **) ! NULL;
+ }
+
+ k = subs->numbr;
+ hash1 = int_hash(k, symbol->array_size);
+
+ for (b = symbol->buckets[hash1]; b != NULL; prev = b, b = b->ainext) {
+ for (i = 0; i < b->aicount; i++) {
+ if (k != b->ainum[i])
+ continue;
+
+ /* item found */
+ if (i == 0 && b->aicount == 2) {
+ /* removing the 1st item; move 2nd item from position 1 to 0 */
+
+ b->ainum[0] = b->ainum[1];
+ b->aivalue[0] = b->aivalue[1];
+ } /* else
+ removing the only item or the 2nd item */
+
+ goto removed;
+ }
+ }
+
+ if (b == NULL) /* item not in array */
+ return NULL;
+
+removed:
+ b->aicount--;
+
+ if (b->aicount == 0) {
+ /* detach bucket */
+ if (prev != NULL)
+ prev->ainext = b->ainext;
+ else
+ symbol->buckets[hash1] = b->ainext;
+
+ /* delete bucket */
+ freebucket(b);
+ } else if (b != symbol->buckets[hash1]) {
+ BUCKET *head = symbol->buckets[hash1];
+
+ assert(b->aicount == 1);
+ /* move the last element from head
+ * to bucket to make it full.
+ */
+ i = --head->aicount; /* head has one less element */
+ b->ainum[1] = head->ainum[i];
+ b->aivalue[1] = head->aivalue[i];
+ b->aicount++; /* bucket has one more element */
+ if (i == 0) {
+ /* head is now empty; delete head */
+ symbol->buckets[hash1] = head->ainext;
+ freebucket(head);
+ }
+ } /* else
+ do nothing */
+
+ symbol->table_size--;
+ if (xn == NULL && symbol->table_size == 0) {
+ efree(symbol->buckets);
+ init_array(symbol); /* re-initialize array 'symbol' */
+ symbol->flags &= ~ARRAYMAXED;
+ } else if (xn != NULL && symbol->table_size == xn->table_size) {
+ /* promote xn (str_array) to symbol */
+ xn->flags &= ~XARRAY;
+ xn->parent_array = symbol->parent_array;
+ efree(symbol->buckets);
+ *symbol = *xn;
+ freenode(xn);
+ }
+
+ return (NODE **) ! NULL; /* return success */
+}
+
+
+/* int_copy --- duplicate input array "symbol" */
+
+static NODE **
+int_copy(NODE *symbol, NODE *newsymb)
+{
+ BUCKET **old, **new, **pnew;
+ BUCKET *chain, *newchain;
+ int j;
+ unsigned long i, cursize;
+
+ assert(symbol->buckets != NULL);
+
+ /* find the current hash size */
+ cursize = symbol->array_size;
+
+ /* allocate new table */
+ emalloc(new, BUCKET **, cursize * sizeof(BUCKET *), "int_copy");
+ memset(new, '\0', cursize * sizeof(BUCKET *));
+
+ old = symbol->buckets;
+
+ for (i = 0; i < cursize; i++) {
+ for (chain = old[i], pnew = & new[i]; chain != NULL;
+ chain = chain->ainext
+ ) {
+ getbucket(newchain);
+ newchain->aicount = chain->aicount;
+ for (j = 0; j < chain->aicount; j++) {
+ NODE *oldval;
+
+ /*
+ * copy the corresponding key and
+ * value from the original input list
+ */
+ newchain->ainum[j] = chain->ainum[j];
+
+ oldval = chain->aivalue[j];
+ if (oldval->type == Node_val)
+ newchain->aivalue[j] = dupnode(oldval);
+ else {
+ NODE *r;
+ r = make_array();
+ r->vname = estrdup(oldval->vname, strlen(oldval->vname));
+ r->parent_array = newsymb;
+ newchain->aivalue[j] = assoc_copy(oldval, r);
+ }
+ }
+
+ *pnew = newchain;
+ pnew = & newchain->ainext;
+ }
+ }
+
+ if (symbol->xarray != NULL) {
+ NODE *xn, *n;
+ xn = symbol->xarray;
+ n = make_array();
+ n->vname = newsymb->vname; /* shallow copy */
+ (void) xn->acopy(xn, n);
+ newsymb->xarray = n;
+ } else
+ newsymb->xarray = NULL;
+
+ newsymb->table_size = symbol->table_size;
+ newsymb->buckets = new;
+ newsymb->array_size = cursize;
+ newsymb->flags = symbol->flags;
+
+ return NULL;
+}
+
+
+/* int_list --- return a list of array items */
+
+static NODE**
+int_list(NODE *symbol, NODE *t)
+{
+ NODE **list = NULL;
+ unsigned long num_elems, list_size, i, k = 0;
+ BUCKET *b;
+ NODE *r, *subs, *xn;
+ int j, elem_size = 1;
+ long num;
+ static char buf[100];
+
+ if (symbol->table_size == 0)
+ return NULL;
+
+ num_elems = symbol->table_size;
+ if ((t->flags & (AINDEX|AVALUE|ADELETE)) == (AINDEX|ADELETE))
+ num_elems = 1;
+
+ if ((t->flags & (AINDEX|AVALUE)) == (AINDEX|AVALUE))
+ elem_size = 2;
+ list_size = elem_size * num_elems;
+
+ if (symbol->xarray != NULL) {
+ xn = symbol->xarray;
+ list = xn->alist(xn, t);
+ assert(list != NULL);
+ if (num_elems == 1 || num_elems == xn->table_size)
+ return list;
+ erealloc(list, NODE **, list_size * sizeof(NODE *), "int_list");
+ k = elem_size * xn->table_size;
+ } else
+ emalloc(list, NODE **, list_size * sizeof(NODE *), "int_list");
+
+ /* populate it */
+
+ for (i = 0; i < symbol->array_size; i++) {
+ for (b = symbol->buckets[i]; b != NULL; b = b->ainext) {
+ for (j = 0; j < b->aicount; j++) {
+ /* index */
+ num = b->ainum[j];
+ if (t->flags & AISTR) {
+ sprintf(buf, "%ld", num);
+ subs = make_string(buf, strlen(buf));
+ subs->numbr = num;
+ subs->flags |= (NUMCUR|NUMINT);
+ } else {
+ subs = make_number((AWKNUM) num);
+ subs->flags |= (INTIND|NUMINT);
+ }
+ list[k++] = subs;
+
+ /* value */
+ if (t->flags & AVALUE) {
+ r = b->aivalue[j];
+ if (r->type == Node_val) {
+ if ((t->flags & AVNUM) != 0)
+ (void) force_number(r);
+ else if ((t->flags & AVSTR) != 0)
+ r = force_string(r);
+ }
+ list[k++] = r;
+ }
+
+ if (k >= list_size)
+ return list;
+ }
+ }
+ }
+ return list;
+}
+
+
+/* int_kilobytes --- calculate memory consumption of the assoc array */
+
+AWKNUM
+int_kilobytes(NODE *symbol)
+{
+ unsigned long i, bucket_cnt = 0;
+ BUCKET *b;
+ AWKNUM kb;
+ extern AWKNUM str_kilobytes(NODE *symbol);
+
+ for (i = 0; i < symbol->array_size; i++) {
+ for (b = symbol->buckets[i]; b != NULL; b = b->ainext)
+ bucket_cnt++;
+ }
+ kb = (((AWKNUM) bucket_cnt) * sizeof (BUCKET) +
+ ((AWKNUM) symbol->array_size) * sizeof (BUCKET *)) / 1024.0;
+
+ if (symbol->xarray != NULL)
+ kb += str_kilobytes(symbol->xarray);
+
+ return kb;
+}
+
+
+/* int_dump --- dump array info */
+
+static NODE **
+int_dump(NODE *symbol, NODE *ndump)
+{
+#define HCNT 31
+
+ int indent_level;
+ BUCKET *b;
+ NODE *xn = NULL;
+ unsigned long str_size = 0, int_size = 0;
+ unsigned long i;
+ size_t j, bucket_cnt;
+ static size_t hash_dist[HCNT + 1];
+
+ indent_level = ndump->alevel;
+
+ if (symbol->xarray != NULL) {
+ xn = symbol->xarray;
+ str_size = xn->table_size;
+ }
+ int_size = symbol->table_size - str_size;
+
+ if ((symbol->flags & XARRAY) == 0)
+ fprintf(output_fp, "%s `%s'\n",
+ (symbol->parent_array == NULL) ? "array" : "sub-array",
+ array_vname(symbol));
+
+ indent_level++;
+ indent(indent_level);
+ fprintf(output_fp, "array_func: int_array_func\n");
+ if (symbol->flags != 0) {
+ indent(indent_level);
+ fprintf(output_fp, "flags: %s\n", flags2str(symbol->flags));
+ }
+ indent(indent_level);
+ fprintf(output_fp, "INT_CHAIN_MAX: %lu\n", (unsigned long) INT_CHAIN_MAX);
+ indent(indent_level);
+ fprintf(output_fp, "array_size: %lu (int)\n", (unsigned long) symbol->array_size);
+ indent(indent_level);
+ fprintf(output_fp, "table_size: %lu (total), %lu (int), %lu (str)\n",
+ (unsigned long) symbol->table_size, int_size, str_size);
+ indent(indent_level);
+ fprintf(output_fp, "Avg # of items per chain (int): %.2g\n",
+ ((AWKNUM) int_size) / symbol->array_size);
+
+ indent(indent_level);
+ fprintf(output_fp, "memory: %.2g kB (total)\n", int_kilobytes(symbol));
+
+ /* hash value distribution */
+
+ memset(hash_dist, '\0', (HCNT + 1) * sizeof(size_t));
+ for (i = 0; i < symbol->array_size; i++) {
+ bucket_cnt = 0;
+ for (b = symbol->buckets[i]; b != NULL; b = b->ainext)
+ bucket_cnt += b->aicount;
+ if (bucket_cnt >= HCNT)
+ bucket_cnt = HCNT;
+ hash_dist[bucket_cnt]++;
+ }
+
+ indent(indent_level);
+ fprintf(output_fp, "Hash distribution:\n");
+ indent_level++;
+ for (j = 0; j <= HCNT; j++) {
+ if (hash_dist[j] > 0) {
+ indent(indent_level);
+ if (j == HCNT)
+ fprintf(output_fp, "[>=%lu]:%lu\n",
+ (unsigned long) HCNT, (unsigned long) hash_dist[j]);
+ else
+ fprintf(output_fp, "[%lu]:%lu\n",
+ (unsigned long) j, (unsigned long) hash_dist[j]);
+ }
+ }
+ indent_level--;
+
+ /* dump elements */
+
+ if (ndump->adepth >= 0) {
+ NODE *subs;
+ const char *aname;
+
+ fprintf(output_fp, "\n");
+
+ aname = make_aname(symbol);
+ subs = make_number((AWKNUM) 0);
+ subs->flags |= (INTIND|NUMINT);
+
+ for (i = 0; i < symbol->array_size; i++) {
+ for (b = symbol->buckets[i]; b != NULL; b = b->ainext) {
+ for (j = 0; j < b->aicount; j++) {
+ subs->numbr = b->ainum[j];
+ assoc_info(subs, b->aivalue[j], ndump, aname);
+ }
+ }
+ }
+ unref(subs);
+ }
+
+ if (xn != NULL) {
+ fprintf(output_fp, "\n");
+ xn->adump(xn, ndump);
+ }
+
+ return NULL;
+
+#undef HCNT
+}
+
+
+/* int_hash --- calculate the hash function of the integer subs */
+
+static uint32_t
+int_hash(uint32_t k, uint32_t hsize)
+{
+
+/* Code snippet copied from:
+ * Hash functions (http://www.azillionmonkeys.com/qed/hash.html).
+ * Copyright 2004-2008 by Paul Hsieh. Licenced under LGPL 2.1.
+ */
+
+ /* This is the final mixing function used by Paul Hsieh
+ * in SuperFastHash.
+ */
+
+ k ^= k << 3;
+ k += k >> 5;
+ k ^= k << 4;
+ k += k >> 17;
+ k ^= k << 25;
+ k += k >> 6;
+
+ if (k >= hsize)
+ k %= hsize;
+ return k;
+}
+
+/* int_find --- locate symbol[subs] */
+
+static inline NODE **
+int_find(NODE *symbol, long k, uint32_t hash1)
+{
+ BUCKET *b;
+ int i;
+
+ assert(symbol->buckets != NULL);
+ for (b = symbol->buckets[hash1]; b != NULL; b = b->ainext) {
+ for (i = 0; i < b->aicount; i++) {
+ if (b->ainum[i] == k)
+ return (b->aivalue + i);
+ }
+ }
+ return NULL;
+}
+
+
+/* int_insert --- install subs in the assoc array */
+
+static NODE **
+int_insert(NODE *symbol, long k, uint32_t hash1)
+{
+ BUCKET *b;
+ int i;
+
+ b = symbol->buckets[hash1];
+
+ /* Only the first bucket in the chain can be partially full,
+ * but is never empty.
+ */
+
+ if (b == NULL || (i = b->aicount) == 2) {
+ getbucket(b);
+ b->aicount = 0;
+ b->ainext = symbol->buckets[hash1];
+ symbol->buckets[hash1] = b;
+ i = 0;
+ }
+
+ b->ainum[i] = k;
+ b->aivalue[i] = dupnode(Nnull_string);
+ b->aicount++;
+ return & b->aivalue[i];
+}
+
+
+/* grow_int_table --- grow the hash table */
+
+static void
+grow_int_table(NODE *symbol)
+{
+ BUCKET **old, **new;
+ BUCKET *chain, *next;
+ int i, j;
+ unsigned long oldsize, newsize, k;
+
+ /*
+ * This is an array of primes. We grow the table by an order of
+ * magnitude each time (not just doubling) so that growing is a
+ * rare operation. We expect, on average, that it won't happen
+ * more than twice. The final size is also chosen to be small
+ * enough so that MS-DOG mallocs can handle it. When things are
+ * very large (> 8K), we just double more or less, instead of
+ * just jumping from 8K to 64K.
+ */
+
+ static const unsigned long sizes[] = {
+ 13, 127, 1021, 8191, 16381, 32749, 65497,
+ 131101, 262147, 524309, 1048583, 2097169,
+ 4194319, 8388617, 16777259, 33554467,
+ 67108879, 134217757, 268435459, 536870923,
+ 1073741827
+ };
+
+ /* find next biggest hash size */
+ newsize = oldsize = symbol->array_size;
+
+ for (i = 0, j = sizeof(sizes)/sizeof(sizes[0]); i < j; i++) {
+ if (oldsize < sizes[i]) {
+ newsize = sizes[i];
+ break;
+ }
+ }
+ if (newsize == oldsize) { /* table already at max (!) */
+ symbol->flags |= ARRAYMAXED;
+ return;
+ }
+
+ /* allocate new table */
+ emalloc(new, BUCKET **, newsize * sizeof(BUCKET *), "grow_int_table");
+ memset(new, '\0', newsize * sizeof(BUCKET *));
+
+ old = symbol->buckets;
+ symbol->buckets = new;
+ symbol->array_size = newsize;
+
+ /* brand new hash table */
+ if (old == NULL)
+ return; /* DO NOT initialize symbol->table_size */
+
+ /* old hash table there, move stuff to new, free old */
+ /* note that symbol->table_size does not change if an old array. */
+
+ for (k = 0; k < oldsize; k++) {
+ long num;
+ for (chain = old[k]; chain != NULL; chain = next) {
+ for (i = 0; i < chain->aicount; i++) {
+ num = chain->ainum[i];
+ *int_insert(symbol, num, int_hash(num, newsize)) = chain->aivalue[i];
+ }
+ next = chain->ainext;
+ freebucket(chain);
+ }
+ }
+ efree(old);
+}
diff --git a/interpret.h b/interpret.h
new file mode 100644
index 00000000..009e6e10
--- /dev/null
+++ b/interpret.h
@@ -0,0 +1,1218 @@
+/*
+ * interpret.h --- run a list of instructions.
+ */
+
+/*
+ * Copyright (C) 1986, 1988, 1989, 1991-2012 the Free Software Foundation, Inc.
+ *
+ * This file is part of GAWK, the GNU implementation of the
+ * AWK Programming Language.
+ *
+ * GAWK is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * GAWK is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
+ */
+
+
+int
+r_interpret(INSTRUCTION *code)
+{
+ INSTRUCTION *pc; /* current instruction */
+ OPCODE op; /* current opcode */
+ NODE *r = NULL;
+ NODE *m;
+ INSTRUCTION *ni;
+ NODE *t1, *t2;
+ NODE **lhs;
+ AWKNUM x, x2;
+ int di;
+ Regexp *rp;
+
+/* array subscript */
+#define mk_sub(n) (n == 1 ? POP_SCALAR() : concat_exp(n, TRUE))
+
+#ifdef EXEC_HOOK
+#define JUMPTO(x) do { if (post_execute) post_execute(pc); pc = (x); goto top; } while (FALSE)
+#else
+#define JUMPTO(x) do { pc = (x); goto top; } while (FALSE)
+#endif
+
+ pc = code;
+
+ /* N.B.: always use JUMPTO for next instruction, otherwise bad things
+ * may happen. DO NOT add a real loop (for/while) below to
+ * replace ' forever {'; this catches failure to use JUMPTO to execute
+ * next instruction (e.g. continue statement).
+ */
+
+ /* loop until hit Op_stop instruction */
+
+ /* forever { */
+top:
+ if (pc->source_line > 0)
+ sourceline = pc->source_line;
+
+#ifdef EXEC_HOOK
+ for (di = 0; di < num_exec_hook; di++) {
+ if (! pre_execute[di](& pc))
+ goto top;
+ }
+#endif
+
+ switch ((op = pc->opcode)) {
+ case Op_rule:
+ currule = pc->in_rule; /* for sole use in Op_K_next, Op_K_nextfile, Op_K_getline */
+ /* fall through */
+ case Op_func:
+ source = pc->source_file;
+ break;
+
+ case Op_atexit:
+ {
+ int stdio_problem = FALSE;
+
+ /* avoid false source indications */
+ source = NULL;
+ sourceline = 0;
+ (void) nextfile(& curfile, TRUE); /* close input data file */
+ /*
+ * This used to be:
+ *
+ * if (close_io() != 0 && ! exiting && exit_val == 0)
+ * exit_val = 1;
+ *
+ * Other awks don't care about problems closing open files
+ * and pipes, in that it doesn't affect their exit status.
+ * So we no longer do either.
+ */
+ (void) close_io(& stdio_problem);
+ /*
+ * However, we do want to exit non-zero if there was a problem
+ * with stdout/stderr, so we reinstate a slightly different
+ * version of the above:
+ */
+ if (stdio_problem && ! exiting && exit_val == 0)
+ exit_val = 1;
+ }
+ break;
+
+ case Op_stop:
+ return 0;
+
+ case Op_push_i:
+ m = pc->memory;
+ if (! do_traditional && (m->flags & INTLSTR) != 0) {
+ char *orig, *trans, save;
+
+ save = m->stptr[m->stlen];
+ m->stptr[m->stlen] = '\0';
+ orig = m->stptr;
+ trans = dgettext(TEXTDOMAIN, orig);
+ m->stptr[m->stlen] = save;
+ m = make_string(trans, strlen(trans));
+ } else
+ UPREF(m);
+ PUSH(m);
+ break;
+
+ case Op_push:
+ case Op_push_arg:
+ {
+ NODE *save_symbol;
+ int isparam = FALSE;
+
+ save_symbol = m = pc->memory;
+ if (m->type == Node_param_list) {
+ isparam = TRUE;
+ save_symbol = m = GET_PARAM(m->param_cnt);
+ if (m->type == Node_array_ref)
+ m = m->orig_array;
+ }
+
+ switch (m->type) {
+ case Node_var:
+ if (do_lint && var_uninitialized(m))
+ lintwarn(isparam ?
+ _("reference to uninitialized argument `%s'") :
+ _("reference to uninitialized variable `%s'"),
+ save_symbol->vname);
+ m = m->var_value;
+ UPREF(m);
+ PUSH(m);
+ break;
+
+ case Node_var_new:
+ m->type = Node_var;
+ m->var_value = dupnode(Nnull_string);
+ if (do_lint)
+ lintwarn(isparam ?
+ _("reference to uninitialized argument `%s'") :
+ _("reference to uninitialized variable `%s'"),
+ save_symbol->vname);
+ m = dupnode(Nnull_string);
+ PUSH(m);
+ break;
+
+ case Node_var_array:
+ if (op == Op_push_arg)
+ PUSH(m);
+ else
+ fatal(_("attempt to use array `%s' in a scalar context"),
+ array_vname(save_symbol));
+ break;
+
+ default:
+ cant_happen();
+ }
+ }
+ break;
+
+ case Op_push_param: /* function argument */
+ m = pc->memory;
+ if (m->type == Node_param_list)
+ m = GET_PARAM(m->param_cnt);
+ if (m->type == Node_var) {
+ m = m->var_value;
+ UPREF(m);
+ PUSH(m);
+ break;
+ }
+ /* else
+ fall through */
+ case Op_push_array:
+ PUSH(pc->memory);
+ break;
+
+ case Op_push_lhs:
+ lhs = get_lhs(pc->memory, pc->do_reference);
+ PUSH_ADDRESS(lhs);
+ break;
+
+ case Op_subscript:
+ t2 = mk_sub(pc->sub_count);
+ t1 = POP_ARRAY();
+
+ if (do_lint && in_array(t1, t2) == NULL) {
+ t2 = force_string(t2);
+ lintwarn(_("reference to uninitialized element `%s[\"%.*s\"]'"),
+ array_vname(t1), (int) t2->stlen, t2->stptr);
+ if (t2->stlen == 0)
+ lintwarn(_("subscript of array `%s' is null string"), array_vname(t1));
+ }
+
+ r = *assoc_lookup(t1, t2);
+ DEREF(t2);
+ if (r->type == Node_val)
+ UPREF(r);
+ PUSH(r);
+ break;
+
+ case Op_sub_array:
+ t2 = mk_sub(pc->sub_count);
+ t1 = POP_ARRAY();
+ r = in_array(t1, t2);
+ if (r == NULL) {
+ r = make_array();
+ r->parent_array = t1;
+ *assoc_lookup(t1, t2) = r;
+ t2 = force_string(t2);
+ r->vname = estrdup(t2->stptr, t2->stlen); /* the subscript in parent array */
+ } else if (r->type != Node_var_array) {
+ t2 = force_string(t2);
+ fatal(_("attempt to use scalar `%s[\"%.*s\"]' as an array"),
+ array_vname(t1), (int) t2->stlen, t2->stptr);
+ }
+
+ DEREF(t2);
+ PUSH(r);
+ break;
+
+ case Op_subscript_lhs:
+ t2 = mk_sub(pc->sub_count);
+ t1 = POP_ARRAY();
+ if (do_lint && in_array(t1, t2) == NULL) {
+ t2 = force_string(t2);
+ if (pc->do_reference)
+ lintwarn(_("reference to uninitialized element `%s[\"%.*s\"]'"),
+ array_vname(t1), (int) t2->stlen, t2->stptr);
+ if (t2->stlen == 0)
+ lintwarn(_("subscript of array `%s' is null string"), array_vname(t1));
+ }
+
+ lhs = assoc_lookup(t1, t2);
+ if ((*lhs)->type == Node_var_array) {
+ t2 = force_string(t2);
+ fatal(_("attempt to use array `%s[\"%.*s\"]' in a scalar context"),
+ array_vname(t1), (int) t2->stlen, t2->stptr);
+ }
+
+ DEREF(t2);
+ PUSH_ADDRESS(lhs);
+ break;
+
+ case Op_field_spec:
+ t1 = TOP_SCALAR();
+ lhs = r_get_field(t1, (Func_ptr *) 0, TRUE);
+ decr_sp();
+ DEREF(t1);
+ r = dupnode(*lhs); /* can't use UPREF here */
+ PUSH(r);
+ break;
+
+ case Op_field_spec_lhs:
+ t1 = TOP_SCALAR();
+ lhs = r_get_field(t1, &pc->target_assign->field_assign, pc->do_reference);
+ decr_sp();
+ DEREF(t1);
+ PUSH_ADDRESS(lhs);
+ break;
+
+ case Op_lint:
+ if (do_lint) {
+ switch (pc->lint_type) {
+ case LINT_assign_in_cond:
+ lintwarn(_("assignment used in conditional context"));
+ break;
+
+ case LINT_no_effect:
+ lintwarn(_("statement has no effect"));
+ break;
+
+ default:
+ cant_happen();
+ }
+ }
+ break;
+
+ case Op_K_break:
+ case Op_K_continue:
+ case Op_jmp:
+ JUMPTO(pc->target_jmp);
+
+ case Op_jmp_false:
+ r = POP_SCALAR();
+ di = eval_condition(r);
+ DEREF(r);
+ if (! di)
+ JUMPTO(pc->target_jmp);
+ break;
+
+ case Op_jmp_true:
+ r = POP_SCALAR();
+ di = eval_condition(r);
+ DEREF(r);
+ if (di)
+ JUMPTO(pc->target_jmp);
+ break;
+
+ case Op_and:
+ case Op_or:
+ t1 = POP_SCALAR();
+ di = eval_condition(t1);
+ DEREF(t1);
+ if ((op == Op_and && di) || (op == Op_or && ! di))
+ break;
+ r = node_Boolean[di];
+ UPREF(r);
+ PUSH(r);
+ ni = pc->target_jmp;
+ JUMPTO(ni->nexti);
+
+ case Op_and_final:
+ case Op_or_final:
+ t1 = TOP_SCALAR();
+ r = node_Boolean[eval_condition(t1)];
+ DEREF(t1);
+ UPREF(r);
+ REPLACE(r);
+ break;
+
+ case Op_not:
+ t1 = TOP_SCALAR();
+ r = node_Boolean[! eval_condition(t1)];
+ DEREF(t1);
+ UPREF(r);
+ REPLACE(r);
+ break;
+
+ case Op_equal:
+ r = node_Boolean[cmp_scalars() == 0];
+ UPREF(r);
+ REPLACE(r);
+ break;
+
+ case Op_notequal:
+ r = node_Boolean[cmp_scalars() != 0];
+ UPREF(r);
+ REPLACE(r);
+ break;
+
+ case Op_less:
+ r = node_Boolean[cmp_scalars() < 0];
+ UPREF(r);
+ REPLACE(r);
+ break;
+
+ case Op_greater:
+ r = node_Boolean[cmp_scalars() > 0];
+ UPREF(r);
+ REPLACE(r);
+ break;
+
+ case Op_leq:
+ r = node_Boolean[cmp_scalars() <= 0];
+ UPREF(r);
+ REPLACE(r);
+ break;
+
+ case Op_geq:
+ r = node_Boolean[cmp_scalars() >= 0];
+ UPREF(r);
+ REPLACE(r);
+ break;
+
+ case Op_plus_i:
+ x2 = force_number(pc->memory)->numbr;
+ goto plus;
+ case Op_plus:
+ t2 = POP_NUMBER();
+ x2 = t2->numbr;
+ DEREF(t2);
+plus:
+ t1 = TOP_NUMBER();
+ r = make_number(t1->numbr + x2);
+ DEREF(t1);
+ REPLACE(r);
+ break;
+
+ case Op_minus_i:
+ x2 = force_number(pc->memory)->numbr;
+ goto minus;
+ case Op_minus:
+ t2 = POP_NUMBER();
+ x2 = t2->numbr;
+ DEREF(t2);
+minus:
+ t1 = TOP_NUMBER();
+ r = make_number(t1->numbr - x2);
+ DEREF(t1);
+ REPLACE(r);
+ break;
+
+ case Op_times_i:
+ x2 = force_number(pc->memory)->numbr;
+ goto times;
+ case Op_times:
+ t2 = POP_NUMBER();
+ x2 = t2->numbr;
+ DEREF(t2);
+times:
+ t1 = TOP_NUMBER();
+ r = make_number(t1->numbr * x2);
+ DEREF(t1);
+ REPLACE(r);
+ break;
+
+ case Op_exp_i:
+ x2 = force_number(pc->memory)->numbr;
+ goto exp;
+ case Op_exp:
+ t2 = POP_NUMBER();
+ x2 = t2->numbr;
+ DEREF(t2);
+exp:
+ t1 = TOP_NUMBER();
+ r = make_number(calc_exp(t1->numbr, x2));
+ DEREF(t1);
+ REPLACE(r);
+ break;
+
+ case Op_quotient_i:
+ x2 = force_number(pc->memory)->numbr;
+ goto quotient;
+ case Op_quotient:
+ t2 = POP_NUMBER();
+ x2 = t2->numbr;
+ DEREF(t2);
+quotient:
+ t1 = TOP_NUMBER();
+ if (x2 == 0)
+ fatal(_("division by zero attempted"));
+ r = make_number(t1->numbr / x2);
+ DEREF(t1);
+ REPLACE(r);
+ break;
+
+ case Op_mod_i:
+ x2 = force_number(pc->memory)->numbr;
+ goto mod;
+ case Op_mod:
+ t2 = POP_NUMBER();
+ x2 = t2->numbr;
+ DEREF(t2);
+mod:
+ t1 = TOP_NUMBER();
+ if (x2 == 0)
+ fatal(_("division by zero attempted in `%%'"));
+#ifdef HAVE_FMOD
+ x = fmod(t1->numbr, x2);
+#else /* ! HAVE_FMOD */
+ (void) modf(t1->numbr / x2, &x);
+ x = t1->numbr - x * x2;
+#endif /* ! HAVE_FMOD */
+ r = make_number(x);
+
+ DEREF(t1);
+ REPLACE(r);
+ break;
+
+ case Op_preincrement:
+ case Op_predecrement:
+ x = op == Op_preincrement ? 1.0 : -1.0;
+ lhs = TOP_ADDRESS();
+ t1 = *lhs;
+ force_number(t1);
+ if (t1->valref == 1 && t1->flags == (MALLOC|NUMCUR|NUMBER)) {
+ /* optimization */
+ t1->numbr += x;
+ r = t1;
+ } else {
+ r = *lhs = make_number(t1->numbr + x);
+ unref(t1);
+ }
+ UPREF(r);
+ REPLACE(r);
+ break;
+
+ case Op_postincrement:
+ case Op_postdecrement:
+ x = op == Op_postincrement ? 1.0 : -1.0;
+ lhs = TOP_ADDRESS();
+ t1 = *lhs;
+ force_number(t1);
+ r = make_number(t1->numbr);
+ if (t1->valref == 1 && t1->flags == (MALLOC|NUMCUR|NUMBER)) {
+ /* optimization */
+ t1->numbr += x;
+ } else {
+ *lhs = make_number(t1->numbr + x);
+ unref(t1);
+ }
+ REPLACE(r);
+ break;
+
+ case Op_unary_minus:
+ t1 = TOP_NUMBER();
+ r = make_number(-t1->numbr);
+ DEREF(t1);
+ REPLACE(r);
+ break;
+
+ case Op_store_sub:
+ /* array[sub] assignment optimization,
+ * see awkgram.y (optimize_assignment)
+ */
+ t1 = get_array(pc->memory, TRUE); /* array */
+ t2 = mk_sub(pc->expr_count); /* subscript */
+ lhs = assoc_lookup(t1, t2);
+ if ((*lhs)->type == Node_var_array) {
+ t2 = force_string(t2);
+ fatal(_("attempt to use array `%s[\"%.*s\"]' in a scalar context"),
+ array_vname(t1), (int) t2->stlen, t2->stptr);
+ }
+ DEREF(t2);
+ unref(*lhs);
+ *lhs = POP_SCALAR();
+ break;
+
+ case Op_store_var:
+ /* simple variable assignment optimization,
+ * see awkgram.y (optimize_assignment)
+ */
+
+ lhs = get_lhs(pc->memory, FALSE);
+ unref(*lhs);
+ r = pc->initval; /* constant initializer */
+ if (r == NULL)
+ *lhs = POP_SCALAR();
+ else {
+ UPREF(r);
+ *lhs = r;
+ }
+ break;
+
+ case Op_store_field:
+ {
+ /* field assignment optimization,
+ * see awkgram.y (optimize_assignment)
+ */
+
+ Func_ptr assign;
+ t1 = TOP_SCALAR();
+ lhs = r_get_field(t1, & assign, FALSE);
+ decr_sp();
+ DEREF(t1);
+ unref(*lhs);
+ *lhs = POP_SCALAR();
+ assert(assign != NULL);
+ assign();
+ }
+ break;
+
+ case Op_assign_concat:
+ /* x = x ... string concatenation optimization */
+ lhs = get_lhs(pc->memory, FALSE);
+ t1 = force_string(*lhs);
+ t2 = POP_STRING();
+
+ free_wstr(*lhs);
+
+ if (t1 != *lhs) {
+ unref(*lhs);
+ *lhs = dupnode(t1);
+ }
+
+ if (t1 != t2 && t1->valref == 1 && (t1->flags & MPFN) == 0) {
+ size_t nlen = t1->stlen + t2->stlen;
+
+ erealloc(t1->stptr, char *, nlen + 2, "r_interpret");
+ memcpy(t1->stptr + t1->stlen, t2->stptr, t2->stlen);
+ t1->stlen = nlen;
+ t1->stptr[nlen] = '\0';
+ t1->flags &= ~(NUMCUR|NUMBER|NUMINT);
+ } else {
+ size_t nlen = t1->stlen + t2->stlen;
+ char *p;
+
+ emalloc(p, char *, nlen + 2, "r_interpret");
+ memcpy(p, t1->stptr, t1->stlen);
+ memcpy(p + t1->stlen, t2->stptr, t2->stlen);
+ unref(*lhs);
+ t1 = *lhs = make_str_node(p, nlen, ALREADY_MALLOCED);
+ }
+ DEREF(t2);
+ break;
+
+ case Op_assign:
+ lhs = POP_ADDRESS();
+ r = TOP_SCALAR();
+ unref(*lhs);
+ *lhs = r;
+ UPREF(r);
+ REPLACE(r);
+ break;
+
+ /* numeric assignments */
+ case Op_assign_plus:
+ case Op_assign_minus:
+ case Op_assign_times:
+ case Op_assign_quotient:
+ case Op_assign_mod:
+ case Op_assign_exp:
+ op_assign(op);
+ break;
+
+ case Op_var_update: /* update value of NR, FNR or NF */
+ pc->update_var();
+ break;
+
+ case Op_var_assign:
+ case Op_field_assign:
+ r = TOP();
+ if (pc->assign_ctxt == Op_sub_builtin
+ && get_number_si(r) == 0 /* top of stack has a number == 0 */
+ ) {
+ /* There wasn't any substitutions. If the target is a FIELD,
+ * this means no field re-splitting or $0 reconstruction.
+ * Skip the set_FOO routine if the target is a special variable.
+ */
+
+ break;
+ } else if ((pc->assign_ctxt == Op_K_getline
+ || pc->assign_ctxt == Op_K_getline_redir)
+ && get_number_si(r) <= 0 /* top of stack has a number <= 0 */
+ ) {
+ /* getline returned EOF or error */
+
+ break;
+ }
+
+ if (op == Op_var_assign)
+ pc->assign_var();
+ else
+ pc->field_assign();
+ break;
+
+ case Op_concat:
+ r = concat_exp(pc->expr_count, pc->concat_flag & CSUBSEP);
+ PUSH(r);
+ break;
+
+ case Op_K_case:
+ if ((pc + 1)->match_exp) {
+ /* match a constant regex against switch expression instead of $0. */
+
+ m = POP(); /* regex */
+ t2 = TOP_SCALAR(); /* switch expression */
+ t2 = force_string(t2);
+ rp = re_update(m);
+ di = (research(rp, t2->stptr, 0, t2->stlen,
+ avoid_dfa(m, t2->stptr, t2->stlen)) >= 0);
+ } else {
+ t1 = POP_SCALAR(); /* case value */
+ t2 = TOP_SCALAR(); /* switch expression */
+ di = (cmp_nodes(t2, t1) == 0);
+ DEREF(t1);
+ }
+
+ if (di) {
+ /* match found */
+ t2 = POP_SCALAR();
+ DEREF(t2);
+ JUMPTO(pc->target_jmp);
+ }
+ break;
+
+ case Op_K_delete:
+ t1 = POP_ARRAY();
+ do_delete(t1, pc->expr_count);
+ stack_adj(-pc->expr_count);
+ break;
+
+ case Op_K_delete_loop:
+ t1 = POP_ARRAY();
+ lhs = POP_ADDRESS(); /* item */
+ do_delete_loop(t1, lhs);
+ break;
+
+ case Op_in_array:
+ t1 = POP_ARRAY();
+ t2 = mk_sub(pc->expr_count);
+ r = node_Boolean[(in_array(t1, t2) != NULL)];
+ DEREF(t2);
+ UPREF(r);
+ PUSH(r);
+ break;
+
+ case Op_arrayfor_init:
+ {
+ NODE **list = NULL;
+ NODE *array, *sort_str;
+ size_t num_elems = 0;
+ static NODE *sorted_in = NULL;
+ const char *how_to_sort = "@unsorted";
+
+ /* get the array */
+ array = POP_ARRAY();
+
+ /* sanity: check if empty */
+ if (array_empty(array))
+ goto arrayfor;
+
+ num_elems = array->table_size;
+
+ if (sorted_in == NULL) /* do this once */
+ sorted_in = make_string("sorted_in", 9);
+
+ sort_str = NULL;
+ /*
+ * If posix, or if there's no PROCINFO[],
+ * there's no ["sorted_in"], so no sorting
+ */
+ if (! do_posix && PROCINFO_node != NULL)
+ sort_str = in_array(PROCINFO_node, sorted_in);
+
+ if (sort_str != NULL) {
+ sort_str = force_string(sort_str);
+ if (sort_str->stlen > 0)
+ how_to_sort = sort_str->stptr;
+ }
+
+ list = assoc_list(array, how_to_sort, SORTED_IN);
+
+arrayfor:
+ getnode(r);
+ r->type = Node_arrayfor;
+ r->for_list = list;
+ r->for_list_size = num_elems; /* # of elements in list */
+ r->cur_idx = -1; /* current index */
+ r->for_array = array; /* array */
+ PUSH(r);
+
+ if (num_elems == 0)
+ JUMPTO(pc->target_jmp); /* Op_arrayfor_final */
+ }
+ break;
+
+ case Op_arrayfor_incr:
+ r = TOP(); /* Node_arrayfor */
+ if (++r->cur_idx == r->for_list_size) {
+ NODE *array;
+ array = r->for_array; /* actual array */
+ if (do_lint && array->table_size != r->for_list_size)
+ lintwarn(_("for loop: array `%s' changed size from %ld to %ld during loop execution"),
+ array_vname(array), (long) r->for_list_size, (long) array->table_size);
+ JUMPTO(pc->target_jmp); /* Op_arrayfor_final */
+ }
+
+ t1 = r->for_list[r->cur_idx];
+ lhs = get_lhs(pc->array_var, FALSE);
+ unref(*lhs);
+ *lhs = dupnode(t1);
+ break;
+
+ case Op_arrayfor_final:
+ r = POP();
+ assert(r->type == Node_arrayfor);
+ free_arrayfor(r);
+ break;
+
+ case Op_builtin:
+ r = pc->builtin(pc->expr_count);
+ PUSH(r);
+ break;
+
+ case Op_ext_builtin:
+ {
+ int arg_count = pc->expr_count;
+
+ PUSH_CODE(pc);
+ r = pc->builtin(arg_count);
+ (void) POP_CODE();
+ while (arg_count-- > 0) {
+ t1 = POP();
+ if (t1->type == Node_val)
+ DEREF(t1);
+ }
+ PUSH(r);
+ }
+ break;
+
+ case Op_sub_builtin: /* sub, gsub and gensub */
+ r = do_sub(pc->expr_count, pc->sub_flags);
+ PUSH(r);
+ break;
+
+ case Op_K_print:
+ do_print(pc->expr_count, pc->redir_type);
+ break;
+
+ case Op_K_printf:
+ do_printf(pc->expr_count, pc->redir_type);
+ break;
+
+ case Op_K_print_rec:
+ do_print_rec(pc->expr_count, pc->redir_type);
+ break;
+
+ case Op_push_re:
+ m = pc->memory;
+ if (m->type == Node_dynregex) {
+ r = POP_STRING();
+ unref(m->re_exp);
+ m->re_exp = r;
+ }
+ PUSH(m);
+ break;
+
+ case Op_match_rec:
+ m = pc->memory;
+ t1 = *get_field(0, (Func_ptr *) 0);
+match_re:
+ rp = re_update(m);
+ /*
+ * Any place where research() is called with a last parameter of
+ * zero, we need to use the avoid_dfa test. This appears here and
+ * in the code for Op_K_case.
+ *
+ * A new or improved dfa that distinguishes beginning/end of
+ * string from beginning/end of line will allow us to get rid of
+ * this hack.
+ *
+ * The avoid_dfa() function is in re.c; it is not very smart.
+ */
+
+ di = research(rp, t1->stptr, 0, t1->stlen,
+ avoid_dfa(m, t1->stptr, t1->stlen));
+ di = (di == -1) ^ (op != Op_nomatch);
+ if (op != Op_match_rec) {
+ decr_sp();
+ DEREF(t1);
+ }
+ r = node_Boolean[di];
+ UPREF(r);
+ PUSH(r);
+ break;
+
+ case Op_nomatch:
+ /* fall through */
+ case Op_match:
+ m = pc->memory;
+ t1 = TOP_STRING();
+ if (m->type == Node_dynregex) {
+ unref(m->re_exp);
+ m->re_exp = t1;
+ decr_sp();
+ t1 = TOP_STRING();
+ }
+ goto match_re;
+ break;
+
+ case Op_indirect_func_call:
+ {
+ NODE *f = NULL;
+ int arg_count;
+
+ arg_count = (pc + 1)->expr_count;
+ t1 = PEEK(arg_count); /* indirect var */
+ assert(t1->type == Node_val); /* @a[1](p) not allowed in grammar */
+ t1 = force_string(t1);
+ if (t1->stlen > 0) {
+ /* retrieve function definition node */
+ f = pc->func_body;
+ if (f != NULL && strcmp(f->vname, t1->stptr) == 0) {
+ /* indirect var hasn't been reassigned */
+
+ ni = setup_frame(pc);
+ JUMPTO(ni); /* Op_func */
+ }
+ f = lookup(t1->stptr);
+ }
+
+ if (f == NULL || f->type != Node_func)
+ fatal(_("function called indirectly through `%s' does not exist"),
+ pc->func_name);
+ pc->func_body = f; /* save for next call */
+
+ ni = setup_frame(pc);
+ JUMPTO(ni); /* Op_func */
+ }
+
+ case Op_func_call:
+ {
+ NODE *f;
+
+ /* retrieve function definition node */
+ f = pc->func_body;
+ if (f == NULL) {
+ f = lookup(pc->func_name);
+ if (f == NULL || (f->type != Node_func && f->type != Node_ext_func))
+ fatal(_("function `%s' not defined"), pc->func_name);
+ pc->func_body = f; /* save for next call */
+ }
+
+ if (f->type == Node_ext_func) {
+ INSTRUCTION *bc;
+ char *fname = pc->func_name;
+ int arg_count = (pc + 1)->expr_count;
+
+ bc = f->code_ptr;
+ assert(bc->opcode == Op_symbol);
+ pc->opcode = Op_ext_builtin; /* self modifying code */
+ pc->builtin = bc->builtin;
+ pc->expr_count = arg_count; /* actual argument count */
+ (pc + 1)->func_name = fname; /* name of the builtin */
+ (pc + 1)->expr_count = bc->expr_count; /* defined max # of arguments */
+ ni = pc;
+ JUMPTO(ni);
+ }
+
+ ni = setup_frame(pc);
+ JUMPTO(ni); /* Op_func */
+ }
+
+ case Op_K_return:
+ m = POP_SCALAR(); /* return value */
+
+ ni = pop_fcall();
+
+ /* put the return value back on stack */
+ PUSH(m);
+
+ JUMPTO(ni);
+
+ case Op_K_getline_redir:
+ if ((currule == BEGINFILE || currule == ENDFILE)
+ && pc->into_var == FALSE
+ && pc->redir_type == redirect_input)
+ fatal(_("`getline' invalid inside `%s' rule"), ruletab[currule]);
+ r = do_getline_redir(pc->into_var, pc->redir_type);
+ PUSH(r);
+ break;
+
+ case Op_K_getline: /* no redirection */
+ if (! currule || currule == BEGINFILE || currule == ENDFILE)
+ fatal(_("non-redirected `getline' invalid inside `%s' rule"),
+ ruletab[currule]);
+
+ do {
+ int ret;
+ ret = nextfile(& curfile, FALSE);
+ if (ret <= 0)
+ r = do_getline(pc->into_var, curfile);
+ else {
+
+ /* Save execution state so that we can return to it
+ * from Op_after_beginfile or Op_after_endfile.
+ */
+
+ push_exec_state(pc, currule, source, stack_ptr);
+
+ if (curfile == NULL)
+ JUMPTO((pc + 1)->target_endfile);
+ else
+ JUMPTO((pc + 1)->target_beginfile);
+ }
+ } while (r == NULL); /* EOF */
+
+ PUSH(r);
+ break;
+
+ case Op_after_endfile:
+ /* Find the execution state to return to */
+ ni = pop_exec_state(& currule, & source, NULL);
+
+ assert(ni->opcode == Op_newfile || ni->opcode == Op_K_getline);
+ JUMPTO(ni);
+
+ case Op_after_beginfile:
+ after_beginfile(& curfile);
+
+ /* Find the execution state to return to */
+ ni = pop_exec_state(& currule, & source, NULL);
+
+ assert(ni->opcode == Op_newfile || ni->opcode == Op_K_getline);
+ if (ni->opcode == Op_K_getline
+ || curfile == NULL /* skipping directory argument */
+ )
+ JUMPTO(ni);
+
+ break; /* read a record, Op_get_record */
+
+ case Op_newfile:
+ {
+ int ret;
+
+ ret = nextfile(& curfile, FALSE);
+
+ if (ret < 0) /* end of input */
+ JUMPTO(pc->target_jmp); /* end block or Op_atexit */
+
+ if (ret == 0) /* read a record */
+ JUMPTO((pc + 1)->target_get_record);
+
+ /* ret > 0 */
+ /* Save execution state for use in Op_after_beginfile or Op_after_endfile. */
+
+ push_exec_state(pc, currule, source, stack_ptr);
+
+ if (curfile == NULL) /* EOF */
+ JUMPTO(pc->target_endfile);
+ /* else
+ execute beginfile block */
+ }
+ break;
+
+ case Op_get_record:
+ {
+ int errcode = 0;
+
+ ni = pc->target_newfile;
+ if (curfile == NULL) {
+ /* from non-redirected getline, e.g.:
+ * {
+ * while (getline > 0) ;
+ * }
+ */
+
+ ni = ni->target_jmp; /* end_block or Op_atexit */
+ JUMPTO(ni);
+ }
+
+ if (inrec(curfile, & errcode) != 0) {
+ if (errcode > 0 && (do_traditional || ! pc->has_endfile))
+ fatal(_("error reading input file `%s': %s"),
+ curfile->name, strerror(errcode));
+
+ JUMPTO(ni);
+ } /* else
+ prog (rule) block */
+ }
+ break;
+
+ case Op_K_nextfile:
+ {
+ int ret;
+
+ if (currule != Rule && currule != BEGINFILE)
+ fatal(_("`nextfile' cannot be called from a `%s' rule"),
+ ruletab[currule]);
+
+ ret = nextfile(& curfile, TRUE); /* skip current file */
+
+ if (currule == BEGINFILE) {
+ long stack_size;
+
+ ni = pop_exec_state(& currule, & source, & stack_size);
+
+ assert(ni->opcode == Op_K_getline || ni->opcode == Op_newfile);
+
+ /* pop stack returning to the state of Op_K_getline or Op_newfile. */
+ unwind_stack(stack_size);
+
+ if (ret == 0) {
+ /* There was an error opening the file;
+ * don't run ENDFILE block(s).
+ */
+
+ JUMPTO(ni);
+ } else {
+ /* do run ENDFILE block(s) first. */
+
+ /* Execution state to return to in Op_after_endfile. */
+ push_exec_state(ni, currule, source, stack_ptr);
+
+ JUMPTO(pc->target_endfile);
+ }
+ } /* else
+ Start over with the first rule. */
+
+ /* empty the run-time stack to avoid memory leak */
+ pop_stack();
+
+ /* Push an execution state for Op_after_endfile to return to */
+ push_exec_state(pc->target_newfile, currule, source, stack_ptr);
+
+ JUMPTO(pc->target_endfile);
+ }
+ break;
+
+ case Op_K_exit:
+ /* exit not allowed in user-defined comparison functions for "sorted_in";
+ * This is done so that END blocks aren't executed more than once.
+ */
+ if (! currule)
+ fatal(_("`exit' cannot be called in the current context"));
+
+ exiting = TRUE;
+ t1 = POP_NUMBER();
+ exit_val = (int) get_number_si(t1);
+ DEREF(t1);
+#ifdef VMS
+ if (exit_val == 0)
+ exit_val = EXIT_SUCCESS;
+ else if (exit_val == 1)
+ exit_val = EXIT_FAILURE;
+ /* else
+ just pass anything else on through */
+#endif
+
+ if (currule == BEGINFILE || currule == ENDFILE) {
+
+ /* Find the rule of the saved execution state (Op_K_getline/Op_newfile).
+ * This is needed to prevent multiple execution of any END rules:
+ * gawk 'BEGINFILE { exit(1) } \
+ * END { while (getline > 0); }' in1 in2
+ */
+
+ (void) pop_exec_state(& currule, & source, NULL);
+ }
+
+ pop_stack(); /* empty stack, don't leak memory */
+
+ /* Jump to either the first END block instruction
+ * or to Op_atexit.
+ */
+
+ if (currule == END)
+ ni = pc->target_atexit;
+ else
+ ni = pc->target_end;
+ JUMPTO(ni);
+
+ case Op_K_next:
+ if (currule != Rule)
+ fatal(_("`next' cannot be called from a `%s' rule"), ruletab[currule]);
+
+ pop_stack();
+ JUMPTO(pc->target_jmp); /* Op_get_record, read next record */
+
+ case Op_pop:
+ r = POP_SCALAR();
+ DEREF(r);
+ break;
+
+ case Op_line_range:
+ if (pc->triggered) /* evaluate right expression */
+ JUMPTO(pc->target_jmp);
+ /* else
+ evaluate left expression */
+ break;
+
+ case Op_cond_pair:
+ {
+ int result;
+ INSTRUCTION *ip;
+
+ t1 = TOP_SCALAR(); /* from right hand side expression */
+ di = (eval_condition(t1) != 0);
+ DEREF(t1);
+
+ ip = pc->line_range; /* Op_line_range */
+
+ if (! ip->triggered && di) {
+ /* not already triggered and left expression is TRUE */
+ decr_sp();
+ ip->triggered = TRUE;
+ JUMPTO(ip->target_jmp); /* evaluate right expression */
+ }
+
+ result = ip->triggered || di;
+ ip->triggered ^= di; /* update triggered flag */
+ r = node_Boolean[result]; /* final value of condition pair */
+ UPREF(r);
+ REPLACE(r);
+ JUMPTO(pc->target_jmp);
+ }
+
+ case Op_exec_count:
+ if (do_profile)
+ pc->exec_count++;
+ break;
+
+ case Op_no_op:
+ case Op_K_do:
+ case Op_K_while:
+ case Op_K_for:
+ case Op_K_arrayfor:
+ case Op_K_switch:
+ case Op_K_default:
+ case Op_K_if:
+ case Op_K_else:
+ case Op_cond_exp:
+ break;
+
+ default:
+ fatal(_("Sorry, don't know how to interpret `%s'"), opcode2str(op));
+ }
+
+ JUMPTO(pc->nexti);
+
+/* } forever */
+
+ /* not reached */
+ return 0;
+
+#undef mk_sub
+#undef JUMPTO
+}
diff --git a/io.c b/io.c
index c57aef2a..7e46cd9a 100644
--- a/io.c
+++ b/io.c
@@ -72,11 +72,15 @@
#include <netdb.h>
#endif /* HAVE_NETDB_H */
+#if defined(HAVE_POPEN_H)
+#include "popen.h"
+#endif
+
#ifndef HAVE_GETADDRINFO
#include "missing_d/getaddrinfo.h"
#endif
-#ifndef AI_ADDRCONFIG /* This is a recent symbol, not everyone has it */
+#ifndef AI_ADDRCONFIG /* not everyone has this symbol */
#define AI_ADDRCONFIG 0
#endif /* AI_ADDRCONFIG */
@@ -132,46 +136,57 @@
#define PIPES_SIMULATED
#endif
+#ifdef HAVE_MPFR
+/* increment NR or FNR */
+#define INCREMENT_REC(X) (do_mpfr && X == (LONG_MAX - 1)) ? \
+ (mpz_add_ui(M##X, M##X, 1), X = 0) : X++
+#else
+#define INCREMENT_REC(X) X++
+#endif
+
typedef enum { CLOSE_ALL, CLOSE_TO, CLOSE_FROM } two_way_close_type;
-/* Several macros make the code a bit clearer: */
-/* */
-/* */
-/* <defines and enums>= */
+/* Several macros to make the code a bit clearer. */
#define at_eof(iop) (((iop)->flag & IOP_AT_EOF) != 0)
#define has_no_data(iop) ((iop)->dataend == NULL)
#define no_data_left(iop) ((iop)->off >= (iop)->dataend)
-/* The key point to the design is to split out the code that searches through */
-/* a buffer looking for the record and the terminator into separate routines, */
-/* with a higher-level routine doing the reading of data and buffer management. */
-/* This makes the code easier to manage; the buffering code is the same independent */
-/* of how we find a record. Communication is via the return value: */
-/* */
-/* */
-/* <defines and enums>= */
+
+/*
+ * The key point to the design is to split out the code that searches through
+ * a buffer looking for the record and the terminator into separate routines,
+ * with a higher-level routine doing the reading of data and buffer management.
+ * This makes the code easier to manage; the buffering code is the same
+ * independent of how we find a record. Communication is via the return
+ * value:
+ */
+
typedef enum recvalues {
REC_OK, /* record and terminator found, recmatch struct filled in */
NOTERM, /* no terminator found, give me more input data */
TERMATEND, /* found terminator at end of buffer */
- TERMNEAREND /* found terminator close to end of buffer, for RE might be bigger */
+ TERMNEAREND /* found terminator close to end of buffer, for when
+ the RE might be match more data further in
+ the file. */
} RECVALUE;
-/* Between calls to a scanning routine, the state is stored in */
-/* an [[enum scanstate]] variable. Not all states apply to all */
-/* variants, but the higher code doesn't really care. */
-/* */
-/* */
-/* <defines and enums>= */
+
+/*
+ * Between calls to a scanning routine, the state is stored in
+ * an enum scanstate variable. Not all states apply to all
+ * variants, but the higher code doesn't really care.
+ */
+
typedef enum scanstate {
NOSTATE, /* scanning not started yet (all) */
INLEADER, /* skipping leading data (RS = "") */
INDATA, /* in body of record (all) */
INTERM /* scanning terminator (RS = "", RS = regexp) */
} SCANSTATE;
-/* When a record is seen ([[REC_OK]] or [[TERMATEND]]), the following */
-/* structure is filled in. */
-/* */
-/* */
-/* <recmatch>= */
+
+/*
+ * When a record is seen (REC_OK or TERMATEND), the following
+ * structure is filled in.
+ */
+
struct recmatch {
char *start; /* record start */
size_t len; /* length of record */
@@ -206,24 +221,53 @@ static int get_a_record(char **out, IOBUF *iop, int *errcode);
static void free_rp(struct redirect *rp);
static int inetfile(const char *str, int *length, int *family);
-#if defined(HAVE_POPEN_H)
-#include "popen.h"
-#endif
+static NODE *in_PROCINFO(const char *pidx1, const char *pidx2, NODE **full_idx);
+static long get_read_timeout(IOBUF *iop);
+static ssize_t read_with_timeout(int fd, char *buf, size_t size);
+
+static int read_can_timeout = FALSE;
+static long read_timeout;
+static long read_default_timeout;
static struct redirect *red_head = NULL;
-static NODE *RS;
-static Regexp *RS_re_yes_case;
-static Regexp *RS_re_no_case;
+static NODE *RS = NULL;
+static Regexp *RS_re_yes_case; /* regexp for RS when ignoring case */
+static Regexp *RS_re_no_case; /* regexp for RS when not ignoring case */
static Regexp *RS_regexp;
int RS_is_null;
-extern int output_is_tty;
extern NODE *ARGC_node;
extern NODE *ARGV_node;
extern NODE *ARGIND_node;
-extern NODE *ERRNO_node;
-extern NODE **fields_arr;
+
+/* init_io --- set up timeout related variables */
+
+void
+init_io()
+{
+ long tmout;
+
+ /*
+ * N.B.: all these hacks are to minimize the effect
+ * on programs that do not care about timeout.
+ */
+
+ /* Parse the env. variable only once */
+ tmout = getenv_long("GAWK_READ_TIMEOUT");
+ if (tmout > 0) {
+ read_default_timeout = tmout;
+ read_can_timeout = TRUE;
+ }
+
+ /*
+ * PROCINFO entries for timeout are dynamic;
+ * We can't be any more specific than this.
+ */
+ if (PROCINFO_node != NULL)
+ read_can_timeout = TRUE;
+}
+
#if defined(__DJGPP__) || defined(__MINGW32__) || defined(__EMX__) || defined(__CYGWIN__)
/* binmode --- convert BINMODE to string for fopen */
@@ -257,6 +301,8 @@ static int vmsrtl_fileno(fp) FILE *fp; { return fileno(fp); }
#define fileno(FP) (((FP) && *(FP)) ? vmsrtl_fileno(FP) : -1)
#endif /* VMS */
+/* after_beginfile --- reset necessary state after BEGINFILE has run */
+
void
after_beginfile(IOBUF **curfile)
{
@@ -303,13 +349,14 @@ nextfile(IOBUF **curfile, int skipping)
static IOBUF mybuf;
const char *fname;
int fd = INVALID_HANDLE;
- int errcode;
+ int errcode = 0;
IOBUF *iop = *curfile;
+ long argc;
if (skipping) { /* for 'nextfile' call */
errcode = 0;
if (iop != NULL) {
- errcode = iop->errcode;
+ errcode = iop->errcode;
(void) iop_close(iop);
}
*curfile = NULL;
@@ -326,7 +373,9 @@ nextfile(IOBUF **curfile, int skipping)
return 0;
}
- for (; i < (long) (ARGC_node->lnode->numbr); i++) {
+ argc = get_number_si(ARGC_node->var_value);
+
+ for (; i < argc; i++) {
tmp = make_number((AWKNUM) i);
(void) force_string(tmp);
arg = in_array(ARGV_node, tmp);
@@ -349,11 +398,14 @@ nextfile(IOBUF **curfile, int skipping)
if (! do_traditional)
update_ERRNO();
- /* This is a kludge. */
unref(FILENAME_node->var_value);
FILENAME_node->var_value = dupnode(arg);
+#ifdef HAVE_MPFR
+ if (is_mpg_number(FNR_node->var_value))
+ mpz_set_ui(MFNR, 0);
+#endif
FNR = 0;
- iop = *curfile = iop_alloc(fd, fname, &mybuf, FALSE);
+ iop = *curfile = iop_alloc(fd, fname, & mybuf, FALSE);
if (fd == INVALID_HANDLE)
iop->errcode = errcode;
else
@@ -374,8 +426,9 @@ nextfile(IOBUF **curfile, int skipping)
FILENAME_node->var_value = make_string("-", 1);
FILENAME_node->var_value->flags |= MAYBE_NUM; /* be pedantic */
fname = "-";
- iop = *curfile = iop_alloc(fileno(stdin), fname, &mybuf, FALSE);
+ iop = *curfile = iop_alloc(fileno(stdin), fname, & mybuf, FALSE);
iop->flag |= IOP_NOFREE_OBJ;
+
if (iop->fd == INVALID_HANDLE) {
errcode = errno;
errno = 0;
@@ -396,7 +449,14 @@ nextfile(IOBUF **curfile, int skipping)
void
set_FNR()
{
- FNR = (long) FNR_node->var_value->numbr;
+ NODE *n = FNR_node->var_value;
+ (void) force_number(n);
+#ifdef HAVE_MPFR
+ if (is_mpg_number(n))
+ FNR = mpg_set_var(FNR_node);
+ else
+#endif
+ FNR = get_number_si(n);
}
/* set_NR --- update internal NR from awk variable */
@@ -404,7 +464,14 @@ set_FNR()
void
set_NR()
{
- NR = (long) NR_node->var_value->numbr;
+ NODE *n = NR_node->var_value;
+ (void) force_number(n);
+#ifdef HAVE_MPFR
+ if (is_mpg_number(n))
+ NR = mpg_set_var(NR_node);
+ else
+#endif
+ NR = get_number_si(n);
}
/* inrec --- This reads in a record from the input file */
@@ -421,15 +488,15 @@ inrec(IOBUF *iop, int *errcode)
else if ((iop->flag & IOP_CLOSED) != 0)
cnt = EOF;
else
- cnt = get_a_record(&begin, iop, errcode);
+ cnt = get_a_record(& begin, iop, errcode);
if (cnt == EOF) {
retval = 1;
if (*errcode > 0)
update_ERRNO_saved(*errcode);
} else {
- NR += 1;
- FNR += 1;
+ INCREMENT_REC(NR);
+ INCREMENT_REC(FNR);
set_record(begin, cnt);
}
@@ -445,14 +512,14 @@ remap_std_file(int oldfd)
int ret = -1;
/*
- * Give OS-specific routines in gawkmisc.c chance to interpret
+ * Give OS-specific routines in gawkmisc.c a chance to interpret
* "/dev/null" as appropriate for their platforms.
*/
newfd = os_devopen("/dev/null", O_RDWR);
if (newfd == INVALID_HANDLE)
newfd = open("/dev/null", O_RDWR);
if (newfd >= 0) {
- /* dup2() will close oldfd for us first. */
+ /* if oldfd is open, dup2() will close oldfd for us first. */
ret = dup2(newfd, oldfd);
if (ret == 0)
close(newfd);
@@ -495,7 +562,7 @@ iop_close(IOBUF *iop)
ret = close(iop->fd);
if (iop->close_func != NULL)
- (*iop->close_func)(iop);
+ iop->close_func(iop);
if (ret == -1)
warning(_("close of fd %d (`%s') failed (%s)"), iop->fd,
@@ -515,7 +582,7 @@ iop_close(IOBUF *iop)
unref(fields_arr[0]);
fields_arr[0] = t;
/*
- * 1/27/2003: This used to be here:
+ * This used to be here:
*
* reset_record();
*
@@ -611,7 +678,7 @@ redirect(NODE *redir_exp, int redirtype, int *errflg)
if (do_lint && (redir_exp->flags & STRCUR) == 0)
lintwarn(_("expression in `%s' redirection only has numeric value"),
what);
- redir_exp = force_string(redir_exp);
+ redir_exp= force_string(redir_exp);
str = redir_exp->stptr;
if (str == NULL || *str == '\0')
@@ -623,11 +690,11 @@ redirect(NODE *redir_exp, int redirtype, int *errflg)
lintwarn(_("filename `%s' for `%s' redirection may be result of logical expression"),
str, what);
+#ifdef HAVE_SOCKETS
/*
- * XXX: Use /inet4 and /inet6 with plain /inet being whatever
- * we get back from the system.
+ * Use /inet4 to force IPv4, /inet6 to force IPv6, and plain
+ * /inet will be whatever we get back from the system.
*/
-#ifdef HAVE_SOCKETS
if (inetfile(str, & len, NULL)) {
tflag |= RED_SOCKET;
if (strncmp(str + len, "tcp/", 4) == 0)
@@ -643,7 +710,7 @@ redirect(NODE *redir_exp, int redirtype, int *errflg)
* if at all possible. Messing with signal() for
* SIGCLD leads to lots of headaches. However, if
* we've gotten EOF from a child input pipeline, it's
- * good bet that the child has died. So recover it.
+ * a good bet that the child has died. So recover it.
*/
if ((rp->flag & RED_EOF) && redirtype == redirect_pipein) {
if (rp->pid != -1)
@@ -693,7 +760,7 @@ redirect(NODE *redir_exp, int redirtype, int *errflg)
while (rp->fp == NULL && rp->iop == NULL) {
if (! new_rp && rp->flag & RED_EOF) {
/*
- * encountered EOF on file or pipe -- must be cleared
+ * Encountered EOF on file or pipe -- must be cleared
* by explicit close() before reading more
*/
save_rp = NULL;
@@ -803,7 +870,7 @@ redirect(NODE *redir_exp, int redirtype, int *errflg)
/* too many files open -- close one and try again */
if (errno == EMFILE || errno == ENFILE)
close_one();
-#if defined __MINGW32__ || defined __sun
+#if defined __MINGW32__
else if (errno == 0) /* HACK! */
close_one();
#endif
@@ -826,9 +893,8 @@ redirect(NODE *redir_exp, int redirtype, int *errflg)
*/
if (errflg != NULL)
*errflg = errno;
- if (redirtype == redirect_output
- || redirtype == redirect_append
- ) {
+ if ( redirtype == redirect_output
+ || redirtype == redirect_append) {
/* multiple messages make life easier for translators */
if (*direction == 'f')
fatal(_("can't redirect from `%s' (%s)"),
@@ -900,7 +966,7 @@ close_one()
if ((rp->flag & (RED_FILE|RED_WRITE)) == (RED_FILE|RED_WRITE)) {
rp->flag |= RED_USED;
errno = 0;
- if (/* do_lint && */ fclose(rp->fp) != 0)
+ if (fclose(rp->fp) != 0)
warning(_("close of `%s' failed (%s)."),
rp->value, strerror(errno));
rp->fp = NULL;
@@ -973,7 +1039,7 @@ do_close(int nargs)
*/
if (do_posix) {
unref(tmp);
- return make_number((AWKNUM) 0);
+ tmp = make_number((AWKNUM) 0);
}
return tmp;
}
@@ -1015,7 +1081,8 @@ close_rp(struct redirect *rp, two_way_close_type how)
rp->iop = NULL;
}
- } else if ((rp->flag & (RED_PIPE|RED_WRITE)) == (RED_PIPE|RED_WRITE)) { /* write to pipe */
+ } else if ((rp->flag & (RED_PIPE|RED_WRITE)) == (RED_PIPE|RED_WRITE)) {
+ /* write to pipe */
status = pclose(rp->fp);
if ((BINMODE & 1) != 0)
os_setbinmode(fileno(stdin), O_BINARY);
@@ -1055,14 +1122,15 @@ close_redir(struct redirect *rp, int exitwarn, two_way_close_type how)
status = close_rp(rp, how);
- /* SVR4 awk checks and warns about status of close */
if (status != 0) {
int save_errno = errno;
char *s = strerror(save_errno);
/*
- * Too many people have complained about this.
- * As of 2.15.6, it is now under lint control.
+ * BWK's awk, as far back as SVR4 (1989) would check
+ * and warn about the status of close. However, when
+ * we did this we got too many complaints, so we moved
+ * it to be under lint control.
*/
if (do_lint) {
if ((rp->flag & RED_PIPE) != 0)
@@ -1167,7 +1235,7 @@ close_io(int *stdio_problem)
for (rp = red_head; rp != NULL; rp = next) {
next = rp->next;
/*
- * close_redir() will print a message if needed
+ * close_redir() will print a message if needed.
* if do_lint, warn about lack of explicit close
*/
if (close_redir(rp, do_lint, CLOSE_ALL))
@@ -1175,7 +1243,7 @@ close_io(int *stdio_problem)
rp = NULL;
}
/*
- * Some of the non-Unix os's have problems doing an fclose
+ * Some of the non-Unix os's have problems doing an fclose()
* on stdout and stderr. Since we don't really need to close
* them, we just flush them, and do that across the board.
*/
@@ -1245,34 +1313,34 @@ socketopen(int family, int type, const char *localpname,
struct addrinfo *rres, *rres0;
struct addrinfo rhints;
- int lerror;
- int rerror;
+ int lerror, rerror;
int socket_fd = INVALID_HANDLE;
int any_remote_host = (strcmp(remotehostname, "0") == 0);
- memset (&lhints, '\0', sizeof (lhints));
+ memset(& lhints, '\0', sizeof (lhints));
lhints.ai_flags = AI_PASSIVE | AI_ADDRCONFIG;
lhints.ai_socktype = type;
lhints.ai_family = family;
- lerror = getaddrinfo (NULL, localpname, &lhints, &lres);
+ lerror = getaddrinfo(NULL, localpname, & lhints, & lres);
if (lerror) {
if (strcmp(localpname, "0") != 0)
fatal(_("local port %s invalid in `/inet'"), localpname);
lres0 = NULL;
- lres = &lhints;
+ lres = & lhints;
} else
lres0 = lres;
while (lres != NULL) {
- memset (&rhints, '\0', sizeof (rhints));
+ memset (& rhints, '\0', sizeof (rhints));
rhints.ai_flags = lhints.ai_flags;
rhints.ai_socktype = lhints.ai_socktype;
rhints.ai_family = lhints.ai_family;
rhints.ai_protocol = lhints.ai_protocol;
- rerror = getaddrinfo (any_remote_host ? NULL : remotehostname, remotepname, &rhints, &rres);
+ rerror = getaddrinfo(any_remote_host ? NULL : remotehostname,
+ remotepname, & rhints, & rres);
if (rerror) {
if (lres0 != NULL)
freeaddrinfo(lres0);
@@ -1296,7 +1364,8 @@ socketopen(int family, int type, const char *localpname,
(char *) & on, sizeof(on));
#ifdef SO_LINGER
linger.l_onoff = 1;
- linger.l_linger = 30; /* linger for 30/100 second */
+ /* linger for 30/100 second */
+ linger.l_linger = 30;
setsockopt(socket_fd, SOL_SOCKET, SO_LINGER,
(char *) & linger, sizeof(linger));
#endif
@@ -1312,12 +1381,12 @@ socketopen(int family, int type, const char *localpname,
int clientsocket_fd = INVALID_HANDLE;
struct sockaddr_storage remote_addr;
- socklen_t namelen = sizeof (remote_addr);
+ socklen_t namelen = sizeof(remote_addr);
if (listen(socket_fd, 1) >= 0
&& (clientsocket_fd = accept(socket_fd,
- (struct sockaddr *) &remote_addr,
- &namelen)) >= 0) {
+ (struct sockaddr *) & remote_addr,
+ & namelen)) >= 0) {
close(socket_fd);
socket_fd = clientsocket_fd;
break;
@@ -1326,15 +1395,15 @@ socketopen(int family, int type, const char *localpname,
#ifdef MSG_PEEK
char buf[10];
struct sockaddr_storage remote_addr;
- socklen_t readle;
+ socklen_t read_len;
if (recvfrom(socket_fd, buf, 1, MSG_PEEK,
(struct sockaddr *) & remote_addr,
- & readle) >= 0
- && readle
+ & read_len) >= 0
+ && read_len
&& connect(socket_fd,
- (struct sockaddr *)& remote_addr,
- readle) == 0)
+ (struct sockaddr *) & remote_addr,
+ read_len) == 0)
break;
#endif
}
@@ -1375,11 +1444,10 @@ devopen(const char *name, const char *mode)
int len;
int family;
- flag = str2mode(mode);
-
if (strcmp(name, "-") == 0)
return fileno(stdin);
+ flag = str2mode(mode);
openfd = INVALID_HANDLE;
if (do_traditional)
@@ -1403,9 +1471,9 @@ devopen(const char *name, const char *mode)
struct stat sbuf;
cp += 3;
- openfd = (int) strtoul(cp, &ptr, 10);
+ openfd = (int) strtoul(cp, & ptr, 10);
if (openfd <= INVALID_HANDLE || ptr == cp
- || fstat(openfd, &sbuf) < 0)
+ || fstat(openfd, & sbuf) < 0)
openfd = INVALID_HANDLE;
}
/* do not set close-on-exec for inherited fd's */
@@ -1468,7 +1536,7 @@ devopen(const char *name, const char *mode)
cp++;
/*
* The remote port ends the special file name.
- * This means there already is a 0 at the end of the string.
+ * This means there already is a '\0' at the end of the string.
* Therefore no need to patch any string ending.
*
* Here too, require a port, let them explicitly put 0 if
@@ -1482,48 +1550,48 @@ devopen(const char *name, const char *mode)
{
#define DEFAULT_RETRIES 20
- static unsigned long def_retries = DEFAULT_RETRIES;
- static int first_time = TRUE;
- unsigned long retries = 0;
- static long msleep = 1000;
-
- if (first_time) {
- char *cp, *end;
- unsigned long count = 0;
- char *ms2;
-
- first_time = FALSE;
- if ((cp = getenv("GAWK_SOCK_RETRIES")) != NULL) {
- count = strtoul(cp, &end, 10);
- if (end != cp && count > 0)
- def_retries = count;
- }
-
- /*
- * Env var is in milliseconds, paramter to usleep()
- * is microseconds, make the conversion. Default is
- * 1 millisecond.
- */
- if ((ms2 = getenv("GAWK_MSEC_SLEEP")) != NULL) {
- msleep = strtol(ms2, &end, 10);
- if (end == ms2 || msleep < 0)
- msleep = 1000;
- else
- msleep *= 1000;
- }
+ static unsigned long def_retries = DEFAULT_RETRIES;
+ static int first_time = TRUE;
+ unsigned long retries = 0;
+ static long msleep = 1000;
+
+ if (first_time) {
+ char *cp, *end;
+ unsigned long count = 0;
+ char *ms2;
+
+ first_time = FALSE;
+ if ((cp = getenv("GAWK_SOCK_RETRIES")) != NULL) {
+ count = strtoul(cp, & end, 10);
+ if (end != cp && count > 0)
+ def_retries = count;
}
- retries = def_retries;
- do {
- openfd = socketopen(family, protocol, localpname, cp, hostname);
- retries--;
- } while (openfd == INVALID_HANDLE && retries > 0 && usleep(msleep) == 0);
+ /*
+ * Env var is in milliseconds, paramter to usleep()
+ * is microseconds, make the conversion. Default is
+ * 1 millisecond.
+ */
+ if ((ms2 = getenv("GAWK_MSEC_SLEEP")) != NULL) {
+ msleep = strtol(ms2, & end, 10);
+ if (end == ms2 || msleep < 0)
+ msleep = 1000;
+ else
+ msleep *= 1000;
+ }
}
+ retries = def_retries;
- *localpnamelastcharp = '/';
- *hostnameslastcharp = '/';
+ do {
+ openfd = socketopen(family, protocol, localpname, cp, hostname);
+ retries--;
+ } while (openfd == INVALID_HANDLE && retries > 0 && usleep(msleep) == 0);
+ }
+
+ *localpnamelastcharp = '/';
+ *hostnameslastcharp = '/';
#else /* ! HAVE_SOCKETS */
- fatal(_("TCP/IP communications are not supported"));
+ fatal(_("TCP/IP communications are not supported"));
#endif /* HAVE_SOCKETS */
}
@@ -1535,8 +1603,8 @@ strictopen:
/* on OS/2 directory access via open() is not permitted */
struct stat buf;
- if (stat(name, &buf) == 0 && S_ISDIR(buf.st_mode))
- errno = EISDIR;
+ if (stat(name, & buf) == 0 && S_ISDIR(buf.st_mode))
+ errno = EISDIR;
}
#endif
if (openfd != INVALID_HANDLE) {
@@ -1582,9 +1650,11 @@ two_way_open(const char *str, struct redirect *rp)
fclose(rp->fp);
return FALSE;
}
+ os_close_on_exec(fd, str, "socket", "to/from");
os_close_on_exec(newfd, str, "socket", "to/from");
rp->iop = iop_alloc(newfd, str, NULL, TRUE);
if (rp->iop == NULL) {
+ close(newfd);
fclose(rp->fp);
return FALSE;
}
@@ -1609,20 +1679,20 @@ two_way_open(const char *str, struct redirect *rp)
pid_t pid;
struct stat statb;
struct termios st;
- /* Use array of chars to avoid ascii / ebcdic issues */
+ /* Use array of chars to avoid ASCII / EBCDIC issues */
static char pty_chars[] = "pqrstuvwxyzabcdefghijklmno";
int i;
if (! initialized) {
initialized = TRUE;
#ifdef HAVE_GRANTPT
- have_dev_ptmx = (stat("/dev/ptmx", &statb) >= 0);
+ have_dev_ptmx = (stat("/dev/ptmx", & statb) >= 0);
#endif
i = 0;
do {
c = pty_chars[i++];
sprintf(slavenam, "/dev/pty%c0", c);
- if (stat(slavenam, &statb) >= 0) {
+ if (stat(slavenam, & statb) >= 0) {
first_pty_letter = c;
break;
}
@@ -1650,8 +1720,9 @@ two_way_open(const char *str, struct redirect *rp)
if (first_pty_letter) {
/*
* Assume /dev/ptyXNN and /dev/ttyXN naming system.
- * The FIRST_PTY_LETTER gives the first X to try. We try in the
- * sequence FIRST_PTY_LETTER, .., 'z', 'a', .., FIRST_PTY_LETTER.
+ * The FIRST_PTY_LETTER gives the first X to try.
+ * We try in the sequence FIRST_PTY_LETTER, ..,
+ * 'z', 'a', .., FIRST_PTY_LETTER.
* Is this worthwhile, or just over-zealous?
*/
c = first_pty_letter;
@@ -1661,7 +1732,7 @@ two_way_open(const char *str, struct redirect *rp)
for (i = 0; i < 16; i++) {
sprintf(slavenam, "/dev/pty%c%x", c, i);
- if (stat(slavenam, &statb) < 0) {
+ if (stat(slavenam, & statb) < 0) {
no_ptys = TRUE; /* bypass all this next time */
goto use_pipes;
}
@@ -1703,7 +1774,7 @@ two_way_open(const char *str, struct redirect *rp)
ioctl(slave, I_PUSH, "ldterm");
#endif
- tcgetattr(slave, &st);
+ tcgetattr(slave, & st);
st.c_iflag &= ~(ISTRIP | IGNCR | INLCR | IXOFF);
st.c_iflag |= (ICRNL | IGNPAR | BRKINT | IXON);
st.c_oflag &= ~OPOST;
@@ -1711,10 +1782,6 @@ two_way_open(const char *str, struct redirect *rp)
st.c_cflag |= CREAD | CS8 | CLOCAL;
st.c_lflag &= ~(ECHO | ECHOE | ECHOK | NOFLSH | TOSTOP);
st.c_lflag |= ISIG;
-#if 0
- st.c_cc[VMIN] = 1;
- st.c_cc[VTIME] = 0;
-#endif
/* Set some control codes to default values */
#ifdef VINTR
@@ -1732,9 +1799,9 @@ two_way_open(const char *str, struct redirect *rp)
#ifdef VEOF
st.c_cc[VEOF] = '\004'; /* ^d */
#endif
- tcsetattr(slave, TCSANOW, &st);
+ tcsetattr(slave, TCSANOW, & st);
- switch (pid = fork ()) {
+ switch (pid = fork()) {
case 0:
/* Child process */
setsid();
@@ -1774,9 +1841,9 @@ two_way_open(const char *str, struct redirect *rp)
}
/* parent */
- if (close(slave)) {
+ if (close(slave) != 0) {
close(master);
- (void) kill(pid, SIGKILL); /* overkill? (pardon pun) */
+ (void) kill(pid, SIGKILL);
fatal(_("close of slave pty failed (%s)"), strerror(errno));
}
@@ -1784,7 +1851,7 @@ two_way_open(const char *str, struct redirect *rp)
rp->iop = iop_alloc(master, str, NULL, TRUE);
if (rp->iop == NULL) {
(void) close(master);
- (void) kill(pid, SIGKILL); /* overkill? (pardon pun) */
+ (void) kill(pid, SIGKILL);
return FALSE;
}
@@ -1797,7 +1864,7 @@ two_way_open(const char *str, struct redirect *rp)
iop_close(rp->iop);
rp->iop = NULL;
(void) close(master);
- (void) kill(pid, SIGKILL); /* overkill? (pardon pun) */
+ (void) kill(pid, SIGKILL);
if (dup_master > 0)
(void) close(dup_master);
return FALSE;
@@ -1837,7 +1904,7 @@ use_pipes:
save_stdout = dup(1); /* duplicate stdout */
if (save_stdout == -1 || save_stdin == -1) {
- /* if an error occurrs close all open file handles */
+ /* if an error occurs close all open file handles */
save_errno = errno;
if (save_stdin != -1)
close(save_stdin);
@@ -1940,7 +2007,7 @@ use_pipes:
(void) close(ctop[1]);
(void) close(ptoc[0]);
(void) close(ptoc[1]);
- (void) kill(pid, SIGKILL); /* overkill? (pardon pun) */
+ (void) kill(pid, SIGKILL);
return FALSE;
}
@@ -1952,7 +2019,7 @@ use_pipes:
(void) close(ctop[1]);
(void) close(ptoc[0]);
(void) close(ptoc[1]);
- (void) kill(pid, SIGKILL); /* overkill? (pardon pun) */
+ (void) kill(pid, SIGKILL);
return FALSE;
}
@@ -1994,9 +2061,9 @@ wait_any(int interesting) /* pid of interest, if any */
qstat = signal(SIGQUIT, SIG_IGN);
for (;;) {
#ifdef HAVE_SYS_WAIT_H /* POSIX compatible sys/wait.h */
- pid = wait(&status);
+ pid = wait(& status);
#else
- pid = wait((union wait *)&status);
+ pid = wait((union wait *) & status);
#endif
if (interesting && pid == interesting) {
break;
@@ -2029,27 +2096,31 @@ gawk_popen(const char *cmd, struct redirect *rp)
#endif
/*
- * used to wait for any children to synchronize input and output,
+ * We used to wait for any children to synchronize input and output,
* but this could cause gawk to hang when it is started in a pipeline
- * and thus has a child process feeding it input (shell dependent)
+ * and thus has a child process feeding it input (shell dependent).
+ *
+ * (void) wait_any(0); // wait for outstanding processes
*/
- /*(void) wait_any(0);*/ /* wait for outstanding processes */
if (pipe(p) < 0)
fatal(_("cannot open pipe `%s' (%s)"), cmd, strerror(errno));
#ifdef __EMX__
- save_stdout = dup(1); /* save stdout */
rp->iop = NULL;
+ save_stdout = dup(1); /* save stdout */
if (save_stdout == -1) {
- close(p[0]); close(p[1]);
- return rp->iop; /* failed */
+ close(p[0]);
+ close(p[1]);
+ return NULL; /* failed */
}
close(1); /* close stdout */
if (dup(p[1]) != 1) {
- close(p[0]); close(p[1]);
- fatal(_("moving pipe to stdout in child failed (dup: %s)"), strerror(errno));
+ close(p[0]);
+ close(p[1]);
+ fatal(_("moving pipe to stdout in child failed (dup: %s)"),
+ strerror(errno));
}
/* none of these handles must be inherited by the child process */
@@ -2170,7 +2241,7 @@ gawk_pclose(struct redirect *rp)
/* do_getline --- read in a line, into var and with redirection */
NODE *
-do_getline_redir(int intovar, int redirtype)
+do_getline_redir(int into_variable, enum redirval redirtype)
{
struct redirect *rp = NULL;
IOBUF *iop;
@@ -2181,12 +2252,12 @@ do_getline_redir(int intovar, int redirtype)
NODE **lhs = NULL;
int redir_error = 0;
- if (intovar)
+ if (into_variable)
lhs = POP_ADDRESS();
- assert(redirtype != 0);
+ assert(redirtype != redirect_none);
redir_exp = TOP();
- rp = redirect(redir_exp, redirtype, &redir_error);
+ rp = redirect(redir_exp, redirtype, & redir_error);
DEREF(redir_exp);
decr_sp();
if (rp == NULL) {
@@ -2201,9 +2272,9 @@ do_getline_redir(int intovar, int redirtype)
return make_number((AWKNUM) 0.0);
errcode = 0;
- cnt = get_a_record(&s, iop, &errcode);
+ cnt = get_a_record(& s, iop, & errcode);
if (errcode != 0) {
- if (! do_traditional && (errcode != -1))
+ if (! do_traditional && errcode != -1)
update_ERRNO_saved(errcode);
return make_number((AWKNUM) -1.0);
}
@@ -2236,34 +2307,34 @@ do_getline_redir(int intovar, int redirtype)
/* do_getline --- read in a line, into var and without redirection */
NODE *
-do_getline(int intovar, IOBUF *iop)
+do_getline(int into_variable, IOBUF *iop)
{
int cnt = EOF;
char *s = NULL;
int errcode;
if (iop == NULL) { /* end of input */
- if (intovar)
+ if (into_variable)
(void) POP_ADDRESS();
return make_number((AWKNUM) 0.0);
}
errcode = 0;
- cnt = get_a_record(&s, iop, &errcode);
+ cnt = get_a_record(& s, iop, & errcode);
if (errcode != 0) {
- if (! do_traditional && (errcode != -1))
+ if (! do_traditional && errcode != -1)
update_ERRNO_saved(errcode);
- if (intovar)
+ if (into_variable)
(void) POP_ADDRESS();
return make_number((AWKNUM) -1.0);
}
if (cnt == EOF)
return NULL; /* try next file */
- NR++;
- FNR++;
+ INCREMENT_REC(NR);
+ INCREMENT_REC(FNR);
- if (! intovar) /* no optional var. */
+ if (! into_variable) /* no optional var. */
set_record(s, cnt);
else { /* assignment to variable */
NODE **lhs;
@@ -2316,7 +2387,7 @@ init_awkpath(char *path)
memcpy(p, start, len);
/* add directory punctuation if necessary */
- if (! isdirpunct(*(end - 1)))
+ if (! isdirpunct(end[-1]))
p[len++] = '/';
p[len] = '\0';
@@ -2340,6 +2411,30 @@ init_awkpath(char *path)
#undef INC_PATH
}
+/* get_cwd -- get current working directory */
+
+static char *
+get_cwd ()
+{
+#define BSIZE 100
+ char *buf;
+ size_t bsize = BSIZE;
+
+ emalloc(buf, char *, bsize * sizeof(char), "get_cwd");
+ while (TRUE) {
+ if (getcwd(buf, bsize) == buf)
+ return buf;
+ if (errno != ERANGE) {
+ efree(buf);
+ return NULL;
+ }
+ bsize *= 2;
+ erealloc(buf, char *, bsize * sizeof(char), "get_cwd");
+ }
+#undef BSIZE
+}
+
+
/* do_find_source --- search $AWKPATH for file, return NULL if not found */
static char *
@@ -2361,10 +2456,16 @@ do_find_source(const char *src, struct stat *stb, int *errcode)
return NULL;
}
- /* try current directory before path search */
+ /* try current directory before $AWKPATH search */
if (stat(src, stb) == 0) {
- emalloc(path, char *, strlen(src) + 1, "do_find_source");
- strcpy(path, src);
+ path = get_cwd();
+ if (path == NULL) {
+ *errcode = errno;
+ return NULL;
+ }
+ erealloc(path, char *, strlen(path) + strlen(src) + 2, "do_find_source");
+ strcat(path, "/");
+ strcat(path, src);
return path;
}
@@ -2374,6 +2475,7 @@ do_find_source(const char *src, struct stat *stb, int *errcode)
emalloc(path, char *, max_pathlen + strlen(src) + 1, "do_find_source");
for (i = 0; awkpath[i] != NULL; i++) {
if (strcmp(awkpath[i], "./") == 0 || strcmp(awkpath[i], ".") == 0) {
+ /* FIXME: already tried CWD above; Why do it again ? */
*path = '\0';
} else
strcpy(path, awkpath[i]);
@@ -2391,7 +2493,7 @@ do_find_source(const char *src, struct stat *stb, int *errcode)
/* find_source --- find source file with default file extension handling */
char *
-find_source(const char *src, struct stat *stb, int *errcode)
+find_source(const char *src, struct stat *stb, int *errcode, int is_extlib)
{
char *path;
@@ -2400,10 +2502,36 @@ find_source(const char *src, struct stat *stb, int *errcode)
return NULL;
path = do_find_source(src, stb, errcode);
+ if (path == NULL && is_extlib) {
+ char *file_ext;
+ int save_errno;
+ size_t src_len;
+ size_t suffix_len;
+
+#define EXTLIB_SUFFIX ".so"
+ src_len = strlen(src);
+ suffix_len = strlen(EXTLIB_SUFFIX);
+
+ /* check if already has the SUFFIX */
+ if (src_len >= suffix_len && strcmp(& src[src_len - suffix_len], EXTLIB_SUFFIX) == 0)
+ return NULL;
+
+ /* append EXTLIB_SUFFIX and try again */
+ save_errno = errno;
+ emalloc(file_ext, char *, src_len + suffix_len + 1, "find_source");
+ sprintf(file_ext, "%s%s", src, EXTLIB_SUFFIX);
+ path = do_find_source(file_ext, stb, errcode);
+ efree(file_ext);
+ if (path == NULL)
+ errno = save_errno;
+ return path;
+#undef EXTLIB_SUFFIX
+ }
+
#ifdef DEFAULT_FILETYPE
if (! do_traditional && path == NULL) {
char *file_awk;
- int save = errno;
+ int save_errno = errno;
#ifdef VMS
int vms_save = vaxc$errno;
#endif
@@ -2415,7 +2543,7 @@ find_source(const char *src, struct stat *stb, int *errcode)
path = do_find_source(file_awk, stb, errcode);
efree(file_awk);
if (path == NULL) {
- errno = save;
+ errno = save_errno;
#ifdef VMS
vaxc$errno = vms_save;
#endif
@@ -2426,29 +2554,19 @@ find_source(const char *src, struct stat *stb, int *errcode)
return path;
}
+
/* srcopen --- open source file */
int
srcopen(SRCFILE *s)
{
if (s->stype == SRC_STDIN)
- return (0);
+ return fileno(stdin);
if (s->stype == SRC_FILE || s->stype == SRC_INC)
return devopen(s->fullpath, "r");
return INVALID_HANDLE;
}
-#ifdef TEST
-int bufsize = 8192;
-
-void
-fatal(const char *s)
-{
- printf("%s\n", s);
- exit(EXIT_FAILURE);
-}
-#endif
-
/* open hooks, mainly for use by extension functions */
static struct open_hook {
@@ -2496,22 +2614,21 @@ iop_alloc(int fd, const char *name, IOBUF *iop, int do_openhooks)
iop_malloced = TRUE;
}
memset(iop, '\0', sizeof(IOBUF));
- iop->flag = 0;
iop->fd = fd;
iop->name = name;
+ iop->read_func = ( ssize_t(*)() ) read;
- if (do_openhooks)
+ if (do_openhooks) {
find_open_hook(iop);
- else if (iop->fd == INVALID_HANDLE)
+ /* tried to find open hook and could not */
+ if (iop->fd == INVALID_HANDLE) {
+ if (iop_malloced)
+ efree(iop);
+ return NULL;
+ }
+ } else if (iop->fd == INVALID_HANDLE)
return iop;
- /* test reached if tried to find open hook and could not */
- if (iop->fd == INVALID_HANDLE) {
- if (iop_malloced)
- efree(iop);
- return NULL;
- }
-
if (os_isatty(iop->fd))
iop->flag |= IOP_IS_TTY;
iop->readsize = iop->size = optimal_bufsize(iop->fd, & sbuf);
@@ -2530,18 +2647,18 @@ iop_alloc(int fd, const char *name, IOBUF *iop, int do_openhooks)
#define set_RT_to_null() \
(void)(! do_traditional && (unref(RT_node->var_value), \
- RT_node->var_value = Nnull_string))
+ RT_node->var_value = dupnode(Nnull_string)))
#define set_RT(str, len) \
(void)(! do_traditional && (unref(RT_node->var_value), \
RT_node->var_value = make_string(str, len)))
-/* grow must increase size of buffer, set end, make sure off and dataend point at */
-/* right spot. */
-/* */
-/* */
-/* <growbuffer>= */
-/* grow_iop_buffer --- grow the buffer */
+/*
+ * grow_iop_buffer:
+ *
+ * grow must increase size of buffer, set end, make sure off and dataend
+ * point at the right spot.
+ */
static void
grow_iop_buffer(IOBUF *iop)
@@ -2575,10 +2692,8 @@ grow_iop_buffer(IOBUF *iop)
iop->end = iop->buf + iop->size;
}
-/* Here are the routines. */
-/* */
-/* */
-/* <rs1scan>= */
+/* Here are the routines. */
+
/* rs1scan --- scan for a single character record terminator */
static RECVALUE
@@ -2659,19 +2774,19 @@ rs1scan(IOBUF *iop, struct recmatch *recm, SCANSTATE *state)
int len = iop->dataend - bp;
int found = 0;
- memset(&mbs, 0, sizeof(mbstate_t));
+ memset(& mbs, 0, sizeof(mbstate_t));
do {
if (*bp == rs)
found = 1;
if (is_valid_character(*bp))
mbclen = 1;
else
- mbclen = mbrlen(bp, len, &mbs);
- if ( (mbclen == 1)
- || (mbclen == (size_t) -1)
- || (mbclen == (size_t) -2)
- || (mbclen == 0)) {
- /* We treat it as a singlebyte character. */
+ mbclen = mbrlen(bp, len, & mbs);
+ if ( mbclen == 1
+ || mbclen == (size_t) -1
+ || mbclen == (size_t) -2
+ || mbclen == 0) {
+ /* We treat it as a single-byte character. */
mbclen = 1;
}
len -= mbclen;
@@ -2681,8 +2796,8 @@ rs1scan(IOBUF *iop, struct recmatch *recm, SCANSTATE *state)
/* Check that newline found isn't the sentinel. */
if (found && (bp - mbclen) < iop->dataend) {
/*
- * set len to what we have so far, in case this is
- * all there is
+ * Set len to what we have so far, in case this is
+ * all there is.
*/
recm->len = bp - recm->start - mbclen;
recm->rt_start = bp - mbclen;
@@ -2716,7 +2831,6 @@ rs1scan(IOBUF *iop, struct recmatch *recm, SCANSTATE *state)
}
}
-/* <rsrescan>= */
/* rsrescan --- search for a regex match in the buffer */
static RECVALUE
@@ -2806,21 +2920,15 @@ again:
* This matches the "xyz" and ends up putting the
* "abc" into the front of the next record. Ooops.
*
- * The remaybelong() function looks to see if the
+ * The re->maybe_long member is true if the
* regex contains one of: + * ? |. This is a very
* simple heuristic, but in combination with the
* "end of match within a few bytes of end of buffer"
* check, should keep things reasonable.
*/
- /*
- * XXX: The reisstring and remaybelong tests should
- * really be done once when RS is assigned to and
- * then tested as flags here. Maybe one day.
- */
-
/* succession of tests is easier to trace in GDB. */
- if (remaybelong(RS->stptr, RS->stlen)) {
+ if (RSre->maybe_long) {
char *matchend = iop->off + reend;
if (iop->dataend - matchend < RS->stlen)
@@ -2830,7 +2938,6 @@ again:
return REC_OK;
}
-/* <rsnullscan>= */
/* rsnullscan --- handle RS = "" */
static RECVALUE
@@ -2907,7 +3014,6 @@ find_longest_terminator:
return REC_OK;
}
-/* <getarecord>= */
/* get_a_record --- read a record from IOP into out, return length of EOF, set RT */
static int
@@ -2925,12 +3031,15 @@ get_a_record(char **out, /* pointer to pointer to data */
if (at_eof(iop) && no_data_left(iop))
return EOF;
+ if (read_can_timeout)
+ read_timeout = get_read_timeout(iop);
+
if (iop->get_record != NULL)
- return (*iop->get_record)(out, iop, errcode);
+ return iop->get_record(out, iop, errcode);
- /* <fill initial buffer>= */
+ /* fill initial buffer */
if (has_no_data(iop) || no_data_left(iop)) {
- iop->count = read(iop->fd, iop->buf, iop->readsize);
+ iop->count = iop->read_func(iop->fd, iop->buf, iop->readsize);
if (iop->count == 0) {
iop->flag |= IOP_AT_EOF;
return EOF;
@@ -2945,10 +3054,12 @@ get_a_record(char **out, /* pointer to pointer to data */
}
}
- /* <loop through file to find a record>= */
+ /* loop through file to find a record */
state = NOSTATE;
for (;;) {
size_t dataend_off;
+ size_t room_left;
+ size_t amt_to_read;
ret = (*matchrec)(iop, & recm, & state);
iop->flag &= ~IOP_AT_START;
@@ -2956,64 +3067,62 @@ get_a_record(char **out, /* pointer to pointer to data */
break;
/* need to add more data to buffer */
- /* <shift data down in buffer>= */
+ /* shift data down in buffer */
dataend_off = iop->dataend - iop->off;
memmove(iop->buf, iop->off, dataend_off);
iop->off = iop->buf;
iop->dataend = iop->buf + dataend_off;
- /* <adjust recm contents>= */
+ /* adjust recm contents */
recm.start = iop->off;
if (recm.rt_start != NULL)
recm.rt_start = iop->off + recm.len;
- /* <read more data, break if EOF>= */
- {
+ /* read more data, break if EOF */
#define min(x, y) (x < y ? x : y)
- /* subtract one in read count to leave room for sentinel */
- size_t room_left = iop->end - iop->dataend - 1;
- size_t amt_to_read = min(iop->readsize, room_left);
-
- if (amt_to_read < iop->readsize) {
- grow_iop_buffer(iop);
- /* <adjust recm contents>= */
- recm.start = iop->off;
- if (recm.rt_start != NULL)
- recm.rt_start = iop->off + recm.len;
-
- /* recalculate amt_to_read */
- room_left = iop->end - iop->dataend - 1;
- amt_to_read = min(iop->readsize, room_left);
- }
- while (amt_to_read + iop->readsize < room_left)
- amt_to_read += iop->readsize;
+ /* subtract one in read count to leave room for sentinel */
+ room_left = iop->end - iop->dataend - 1;
+ amt_to_read = min(iop->readsize, room_left);
+
+ if (amt_to_read < iop->readsize) {
+ grow_iop_buffer(iop);
+ /* adjust recm contents */
+ recm.start = iop->off;
+ if (recm.rt_start != NULL)
+ recm.rt_start = iop->off + recm.len;
+
+ /* recalculate amt_to_read */
+ room_left = iop->end - iop->dataend - 1;
+ amt_to_read = min(iop->readsize, room_left);
+ }
+ while (amt_to_read + iop->readsize < room_left)
+ amt_to_read += iop->readsize;
#ifdef SSIZE_MAX
- /*
- * POSIX limits read to SSIZE_MAX. There are (bizarre)
- * systems where this amount is small.
- */
- amt_to_read = min(amt_to_read, SSIZE_MAX);
+ /*
+ * POSIX limits read to SSIZE_MAX. There are (bizarre)
+ * systems where this amount is small.
+ */
+ amt_to_read = min(amt_to_read, SSIZE_MAX);
#endif
- iop->count = read(iop->fd, iop->dataend, amt_to_read);
- if (iop->count == -1) {
- *errcode = errno;
- iop->flag |= IOP_AT_EOF;
- break;
- } else if (iop->count == 0) {
- /*
- * hit EOF before matching RS, so end
- * the record and set RT to ""
- */
- iop->flag |= IOP_AT_EOF;
- break;
- } else
- iop->dataend += iop->count;
- }
+ iop->count = iop->read_func(iop->fd, iop->dataend, amt_to_read);
+ if (iop->count == -1) {
+ *errcode = errno;
+ iop->flag |= IOP_AT_EOF;
+ break;
+ } else if (iop->count == 0) {
+ /*
+ * hit EOF before matching RS, so end
+ * the record and set RT to ""
+ */
+ iop->flag |= IOP_AT_EOF;
+ break;
+ } else
+ iop->dataend += iop->count;
}
- /* <set record, RT, return right value>= */
+ /* set record, RT, return right value */
/*
* rtval is not a static pointer to avoid dangling pointer problems
@@ -3134,6 +3243,7 @@ set_FS:
set_FS();
}
+
/* pty_vs_pipe --- return true if should use pty instead of pipes for `|&' */
/*
@@ -3144,32 +3254,16 @@ static int
pty_vs_pipe(const char *command)
{
#ifdef HAVE_TERMIOS_H
- char *full_index;
- size_t full_len;
NODE *val;
- NODE *sub;
if (PROCINFO_node == NULL)
return FALSE;
-
- full_len = strlen(command)
- + SUBSEP_node->var_value->stlen
- + 3 /* strlen("pty") */
- + 1; /* string terminator */
- emalloc(full_index, char *, full_len, "pty_vs_pipe");
- sprintf(full_index, "%s%.*spty", command,
- (int) SUBSEP_node->var_value->stlen, SUBSEP_node->var_value->stptr);
-
- sub = make_string(full_index, strlen(full_index));
- val = in_array(PROCINFO_node, sub);
- unref(sub);
- efree(full_index);
-
+ val = in_PROCINFO(command, "pty", NULL);
if (val) {
if (val->flags & MAYBE_NUM)
(void) force_number(val);
if (val->flags & NUMBER)
- return (val->numbr != 0.0);
+ return ! iszero(val);
else
return (val->stlen != 0);
}
@@ -3235,3 +3329,121 @@ inetfile(const char *str, int *length, int *family)
return ret;
}
+
+/*
+ * in_PROCINFO --- return value for a PROCINFO element with
+ * SUBSEP seperated indices.
+ */
+
+static NODE *
+in_PROCINFO(const char *pidx1, const char *pidx2, NODE **full_idx)
+{
+ char *str;
+ size_t str_len;
+ NODE *r, *sub = NULL;
+ NODE *subsep = SUBSEP_node->var_value;
+
+ /* full_idx is in+out parameter */
+
+ if (full_idx)
+ sub = *full_idx;
+
+ str_len = strlen(pidx1) + subsep->stlen + strlen(pidx2);
+ if (sub == NULL) {
+ emalloc(str, char *, str_len + 1, "in_PROCINFO");
+ sub = make_str_node(str, str_len, ALREADY_MALLOCED);
+ if (full_idx)
+ *full_idx = sub;
+ } else if (str_len != sub->stlen) {
+ /* *full_idx != NULL */
+
+ assert(sub->valref == 1);
+ erealloc(sub->stptr, char *, str_len + 1, "in_PROCINFO");
+ sub->stlen = str_len;
+ }
+
+ sprintf(sub->stptr, "%s%.*s%s", pidx1, (int)subsep->stlen,
+ subsep->stptr, pidx2);
+ r = in_array(PROCINFO_node, sub);
+ if (! full_idx)
+ unref(sub);
+ return r;
+}
+
+
+/* get_read_timeout --- get timeout in milliseconds for reading */
+
+static long
+get_read_timeout(IOBUF *iop)
+{
+ long tmout = 0;
+
+ if (PROCINFO_node != NULL) {
+ const char *name = iop->name;
+ NODE *val = NULL;
+ static NODE *full_idx = NULL;
+ static const char *last_name = NULL;
+
+ /*
+ * Do not re-construct the full index when last redirection
+ * string is the same as the current; "efficiency_hack++".
+ */
+ if (full_idx == NULL || strcmp(name, last_name) != 0) {
+ val = in_PROCINFO(name, "READ_TIMEOUT", & full_idx);
+ if (last_name != NULL)
+ efree((void *) last_name);
+ last_name = estrdup(name, strlen(name));
+ } else /* use cached full index */
+ val = in_array(PROCINFO_node, full_idx);
+
+ if (val != NULL) {
+ (void) force_number(val);
+ tmout = get_number_si(val);
+ }
+ } else
+ tmout = read_default_timeout; /* initialized from env. variable in init_io() */
+
+ iop->read_func = tmout > 0 ? read_with_timeout : ( ssize_t(*)() ) read;
+ return tmout;
+}
+
+/*
+ * read_with_timeout --- read with a timeout, return failure
+ * if no data is available within the timeout period.
+ */
+
+static ssize_t
+read_with_timeout(int fd, char *buf, size_t size)
+{
+#ifndef __MINGW32__
+ fd_set readfds;
+ struct timeval tv;
+
+ tv.tv_sec = read_timeout / 1000;
+ tv.tv_usec = 1000 * (read_timeout - 1000 * tv.tv_sec);
+
+ FD_ZERO(& readfds);
+ FD_SET(fd, & readfds);
+
+ errno = 0;
+ if (select(fd + 1, & readfds, NULL, NULL, & tv) < 0)
+ return -1;
+
+ if (FD_ISSET(fd, & readfds))
+ return read(fd, buf, size);
+ /* else
+ timed out */
+
+ /* Set a meaningful errno */
+#ifdef ETIMEDOUT
+ errno = ETIMEDOUT;
+#else
+ errno = EAGAIN;
+#endif
+ return -1;
+#else /* __MINGW32__ */
+ return read(fd, buf, size);
+#endif /* __MINGW32__ */
+}
+
+
diff --git a/m4/ChangeLog b/m4/ChangeLog
index f099c857..4e4e7c84 100644
--- a/m4/ChangeLog
+++ b/m4/ChangeLog
@@ -1,3 +1,8 @@
+<<<<<<< HEAD
+2012-04-01 John Haque <j.eh@mchsi.com>
+
+ * mpfr.m4: New file.
+=======
2012-04-27 Arnold D. Robbins <arnold@skeeve.com>
Update to autoconf 2.69, automake 1.12.
@@ -6,6 +11,7 @@
intlmacosx.m4, intmax.m4, inttypes-pri.m4, inttypes_h.m4, lcmessage.m4,
lock.m4, longlong.m4, printf-posix.m4, size_max.m4, stdint_h.m4,
uintmax_t.m4, visibility.m4, wchar_t.m4, wint_t.m4, xsize.m4: Updated.
+>>>>>>> gawk-4.0-stable
2012-03-30 Arnold D. Robbins <arnold@skeeve.com>
diff --git a/m4/mpfr.m4 b/m4/mpfr.m4
new file mode 100644
index 00000000..7d9e678b
--- /dev/null
+++ b/m4/mpfr.m4
@@ -0,0 +1,62 @@
+dnl Check for MPFR and dependencies
+dnl Copyright (C) 2004, 2005 Free Software Foundation, Inc.
+dnl
+dnl This file is free software, distributed under the terms of the GNU
+dnl General Public License. As a special exception to the GNU General
+dnl Public License, this file may be distributed as part of a program
+dnl that contains a configuration script generated by Autoconf, under
+dnl the same distribution terms as the rest of that program.
+dnl
+dnl Defines HAVE_MPFR to 1 if a working MPFR/GMP setup is
+dnl found, and sets @LIBMPFR@ to the necessary libraries.
+
+AC_DEFUN([GNUPG_CHECK_MPFR],
+[
+ AC_ARG_WITH([mpfr],
+ AC_HELP_STRING([--with-mpfr=DIR],
+ [look for the mpfr and gmp libraries in DIR]),
+ [_do_mpfr=$withval],[_do_mpfr=yes])
+
+ if test "$_do_mpfr" != "no" ; then
+ if test -d "$withval" ; then
+ CPPFLAGS="${CPPFLAGS} -I$withval/include"
+ LDFLAGS="${LDFLAGS} -L$withval/lib"
+ fi
+
+ _mpfr_save_libs=$LIBS
+ _combo="-lmpfr -lgmp"
+ LIBS="$LIBS $_combo"
+
+ AC_MSG_CHECKING([whether mpfr via \"$_combo\" is present and usable])
+
+ AC_LINK_IFELSE([
+ AC_LANG_PROGRAM([
+#include <stdio.h>
+#include <mpfr.h>
+#include <gmp.h>
+],[
+mpfr_t p;
+mpz_t z;
+mpfr_init(p);
+mpz_init(z);
+mpfr_printf("%Rf%Zd", p, z);
+mpfr_clear(p);
+mpz_clear(z);
+])],_found_mpfr=yes,_found_mpfr=no)
+
+ AC_MSG_RESULT([$_found_mpfr])
+
+ LIBS=$_mpfr_save_libs
+
+ if test $_found_mpfr = yes ; then
+ AC_DEFINE(HAVE_MPFR,1,
+ [Define to 1 if you have fully functional mpfr and gmp libraries.])
+ AC_SUBST(LIBMPFR,$_combo)
+ break
+ fi
+
+ unset _mpfr_save_libs
+ unset _combo
+ unset _found_mpfr
+ fi
+])dnl
diff --git a/main.c b/main.c
index 3680e3f4..8a38a760 100644
--- a/main.c
+++ b/main.c
@@ -35,6 +35,8 @@
#define DEFAULT_PROFILE "awkprof.out" /* where to put profile */
#define DEFAULT_VARFILE "awkvars.out" /* where to put vars */
+#define DEFAULT_PREC 53
+#define DEFAULT_ROUNDMODE "N" /* round to nearest */
static const char *varfile = DEFAULT_VARFILE;
const char *command_file = NULL; /* debugger commands */
@@ -55,15 +57,18 @@ static void nostalgia(void) ATTRIBUTE_NORETURN;
static void version(void) ATTRIBUTE_NORETURN;
static void init_fds(void);
static void init_groupset(void);
-
static void save_argv(int, char **);
+extern int debug_prog(INSTRUCTION *pc); /* debug.c */
+extern int init_debug(); /* debug.c */
+
/* These nodes store all the special variables AWK uses */
NODE *ARGC_node, *ARGIND_node, *ARGV_node, *BINMODE_node, *CONVFMT_node;
NODE *ENVIRON_node, *ERRNO_node, *FIELDWIDTHS_node, *FILENAME_node;
NODE *FNR_node, *FPAT_node, *FS_node, *IGNORECASE_node, *LINT_node;
NODE *NF_node, *NR_node, *OFMT_node, *OFS_node, *ORS_node, *PROCINFO_node;
NODE *RLENGTH_node, *RSTART_node, *RS_node, *RT_node, *SUBSEP_node;
+NODE *PREC_node, *ROUNDMODE_node;
NODE *TEXTDOMAIN_node;
NODE *_r; /* used as temporary in stack macros */
@@ -129,30 +134,18 @@ static int disallow_var_assigns = FALSE; /* true for --exec */
static void add_preassign(enum assign_type type, char *val);
-#undef do_lint
-#undef do_lint_old
-
-int do_traditional = FALSE; /* no gnu extensions, add traditional weirdnesses */
-int do_posix = FALSE; /* turn off gnu and unix extensions */
-int do_lint = FALSE; /* provide warnings about questionable stuff */
-int do_lint_old = FALSE; /* warn about stuff not in V7 awk */
-int do_intl = FALSE; /* dump locale-izable strings to stdout */
-int do_non_decimal_data = FALSE; /* allow octal/hex C style DATA. Use with caution! */
-int do_nostalgia = FALSE; /* provide a blast from the past */
-int do_intervals = FALSE; /* allow {...,...} in regexps, see resetup() */
-int do_profiling = FALSE; /* profile and pretty print the program */
-int do_dump_vars = FALSE; /* dump all global variables at end */
-int do_tidy_mem = FALSE; /* release vars when done */
-int do_optimize = TRUE; /* apply default optimizations */
-int do_binary = FALSE; /* hands off my data! */
-int do_sandbox = FALSE; /* sandbox mode - disable 'system' function & redirections */
+int do_flags = FALSE;
+int do_optimize = TRUE; /* apply default optimizations */
+static int do_nostalgia = FALSE; /* provide a blast from the past */
+static int do_binary = FALSE; /* hands off my data! */
+
int use_lc_numeric = FALSE; /* obey locale for decimal point */
#if MBS_SUPPORT
int gawk_mb_cur_max; /* MB_CUR_MAX value, see comment in main() */
#endif
-FILE *output_fp; /* default output for debugger */
+FILE *output_fp; /* default gawk output, can be redirected in the debugger */
int output_is_tty = FALSE; /* control flushing of output */
/* default format for strftime(), available via PROCINFO */
@@ -167,44 +160,39 @@ int ngroups; /* size of said set */
void (*lintfunc)(const char *mesg, ...) = warning;
-/*
- * Note: reserve -D for future use, to merge dgawk into gawk.
- * Note: reserve -l for future use, for xgawk's -l option.
- */
static const struct option optab[] = {
- { "traditional", no_argument, & do_traditional, 1 },
- { "lint", optional_argument, NULL, 'L' },
- { "lint-old", no_argument, & do_lint_old, 1 },
- { "optimize", no_argument, & do_optimize, 'O' },
- { "posix", no_argument, & do_posix, 1 },
- { "command", required_argument, NULL, 'R' },
+ { "traditional", no_argument, NULL, 'c' },
+ { "lint", optional_argument, NULL, 'L' },
+ { "lint-old", no_argument, NULL, 't' },
+ { "optimize", no_argument, NULL, 'O' },
+ { "posix", no_argument, NULL, 'P' },
{ "nostalgia", no_argument, & do_nostalgia, 1 },
- { "gen-pot", no_argument, & do_intl, 1 },
- { "non-decimal-data", no_argument, & do_non_decimal_data, 1 },
- { "profile", optional_argument, NULL, 'p' },
- { "copyright", no_argument, NULL, 'C' },
- { "field-separator", required_argument, NULL, 'F' },
- { "file", required_argument, NULL, 'f' },
- { "re-interval", no_argument, & do_intervals, 1 },
- { "source", required_argument, NULL, 'e' },
- { "dump-variables", optional_argument, NULL, 'd' },
- { "assign", required_argument, NULL, 'v' },
- { "version", no_argument, NULL, 'V' },
- { "help", no_argument, NULL, 'h' },
- { "exec", required_argument, NULL, 'E' },
+ { "gen-pot", no_argument, NULL, 'g' },
+ { "non-decimal-data", no_argument, NULL, 'n' },
+ { "pretty-print", optional_argument, NULL, 'o' },
+ { "profile", optional_argument, NULL, 'p' },
+ { "debug", optional_argument, NULL, 'D' },
+ { "copyright", no_argument, NULL, 'C' },
+ { "field-separator", required_argument, NULL, 'F' },
+ { "file", required_argument, NULL, 'f' },
+ { "re-interval", no_argument, NULL, 'r' },
+ { "source", required_argument, NULL, 'e' },
+ { "load", required_argument, NULL, 'l' },
+ { "dump-variables", optional_argument, NULL, 'd' },
+ { "assign", required_argument, NULL, 'v' },
+ { "version", no_argument, NULL, 'V' },
+ { "help", no_argument, NULL, 'h' },
+ { "exec", required_argument, NULL, 'E' },
{ "use-lc-numeric", no_argument, & use_lc_numeric, 1 },
{ "characters-as-bytes", no_argument, & do_binary, 'b' },
- { "sandbox", no_argument, & do_sandbox, 1 },
+ { "sandbox", no_argument, NULL, 'S' },
+ { "bignum", no_argument, NULL, 'M' },
#if defined(YYDEBUG) || defined(GAWKDEBUG)
{ "parsedebug", no_argument, NULL, 'Y' },
#endif
{ NULL, 0, NULL, '\0' }
};
-#ifdef NO_LINT
-#define do_lint 0
-#define do_lint_old 0
-#endif
/* main --- process args, parse program, run it, clean up */
@@ -213,19 +201,20 @@ main(int argc, char **argv)
{
/*
* The + on the front tells GNU getopt not to rearrange argv.
- * Note: reserve -D for future use, to merge dgawk into gawk.
- * Note: reserve -l for future use, for xgawk's -l option.
*/
- const char *optlist = "+F:f:v:W;m:bcCd::e:E:gh:L:nNOp::PrR:StVY";
+ const char *optlist = "+F:f:v:W;m:bcCd::D::e:E:gh:l:L:nNo::Op::MPrStVY";
int stopped_early = FALSE;
int old_optind;
int i;
int c;
char *scan, *src;
char *extra_stack;
+ int have_srcfile = FALSE;
+ SRCFILE *s;
/* do these checks early */
- do_tidy_mem = (getenv("TIDYMEM") != NULL);
+ if (getenv("TIDYMEM") != NULL)
+ do_flags |= DO_TIDY_MEM;
#ifdef HAVE_MCHECK_H
#ifdef HAVE_MTRACE
@@ -373,7 +362,7 @@ main(int argc, char **argv)
break;
case 'c':
- do_traditional = TRUE;
+ do_flags |= DO_TRADITIONAL;
break;
case 'C':
@@ -381,11 +370,17 @@ main(int argc, char **argv)
break;
case 'd':
- do_dump_vars = TRUE;
+ do_flags |= DO_DUMP_VARS;
if (optarg != NULL && optarg[0] != '\0')
varfile = optarg;
break;
+ case 'D':
+ do_flags |= DO_DEBUG;
+ if (optarg != NULL && optarg[0] != '\0')
+ command_file = optarg;
+ break;
+
case 'e':
if (optarg[0] == '\0')
warning(_("empty argument to `-e/--source' ignored"));
@@ -394,7 +389,7 @@ main(int argc, char **argv)
break;
case 'g':
- do_intl = TRUE;
+ do_flags |= DO_INTL;
break;
case 'h':
@@ -402,19 +397,25 @@ main(int argc, char **argv)
usage(EXIT_SUCCESS, stdout);
break;
-#ifndef NO_LINT
+ case 'l':
+ (void) add_srcfile(SRC_EXTLIB, optarg, srcfiles, NULL, NULL);
+ break;
+
case 'L':
- do_lint = LINT_ALL;
+#ifndef NO_LINT
+ do_flags |= DO_LINT_ALL;
if (optarg != NULL) {
if (strcmp(optarg, "fatal") == 0)
lintfunc = r_fatal;
- else if (strcmp(optarg, "invalid") == 0)
- do_lint = LINT_INVALID;
+ else if (strcmp(optarg, "invalid") == 0) {
+ do_flags &= ~DO_LINT_ALL;
+ do_flags |= DO_LINT_INVALID;
+ }
}
break;
case 't':
- do_lint_old = TRUE;
+ do_flags |= DO_LINT_OLD;
break;
#else
case 'L':
@@ -423,7 +424,7 @@ main(int argc, char **argv)
#endif
case 'n':
- do_non_decimal_data = TRUE;
+ do_flags |= DO_NON_DEC_DATA;
break;
case 'N':
@@ -435,23 +436,32 @@ main(int argc, char **argv)
break;
case 'p':
- do_profiling = TRUE;
+ do_flags |= DO_PROFILE;
+ /* fall through */
+ case 'o':
+ do_flags |= DO_PRETTY_PRINT;
if (optarg != NULL)
set_prof_file(optarg);
else
set_prof_file(DEFAULT_PROFILE);
break;
+ case 'M':
+#ifdef HAVE_MPFR
+ do_flags |= DO_MPFR;
+#endif
+ break;
+
case 'P':
- do_posix = TRUE;
+ do_flags |= DO_POSIX;
break;
case 'r':
- do_intervals = TRUE;
+ do_flags |= DO_INTERVALS;
break;
case 'S':
- do_sandbox = TRUE;
+ do_flags |= DO_SANDBOX;
break;
case 'V':
@@ -472,20 +482,13 @@ main(int argc, char **argv)
break;
case 'Y':
- case 'R':
#if defined(YYDEBUG) || defined(GAWKDEBUG)
if (c == 'Y') {
yydebug = 2;
break;
}
#endif
- if (c == 'R' && which_gawk == exe_debugging) {
- if (optarg[0] != '\0')
- command_file = optarg;
- break;
- }
- /* if not debugging or dgawk, fall through */
-
+ /* if not debugging, fall through */
case '?':
default:
/*
@@ -530,7 +533,7 @@ out:
/* check for POSIXLY_CORRECT environment variable */
if (! do_posix && getenv("POSIXLY_CORRECT") != NULL) {
- do_posix = TRUE;
+ do_flags |= DO_POSIX;
if (do_lint)
lintwarn(
_("environment variable `POSIXLY_CORRECT' set: turning on `--posix'"));
@@ -541,7 +544,7 @@ out:
if (do_traditional) /* both on command line */
warning(_("`--posix' overrides `--traditional'"));
else
- do_traditional = TRUE;
+ do_flags |= DO_TRADITIONAL;
/*
* POSIX compliance also implies
* no GNU extensions either.
@@ -549,7 +552,7 @@ out:
}
if (do_traditional && do_non_decimal_data) {
- do_non_decimal_data = FALSE;
+ do_flags &= ~DO_NON_DEC_DATA;
warning(_("`--posix'/`--traditional' overrides `--non-decimal-data'"));
}
@@ -565,21 +568,30 @@ out:
}
#endif
- /*
- * Force profiling if this is pgawk.
- * Don't bother if the command line already set profiling up.
- */
- if (! do_profiling)
- init_profiling(& do_profiling, DEFAULT_PROFILE);
+ if (do_debug) /* Need to register the debugger pre-exec hook before any other */
+ init_debug();
+
+#ifdef HAVE_MPFR
+ /* Set up MPFR defaults, and register pre-exec hook to process arithmetic opcodes */
+ if (do_mpfr)
+ init_mpfr(DEFAULT_PREC, DEFAULT_ROUNDMODE);
+#endif
/* load group set */
init_groupset();
/* initialize the null string */
Nnull_string = make_string("", 0);
- Nnull_string->numbr = 0.0;
- Nnull_string->type = Node_val;
- Nnull_string->flags = (PERM|STRCUR|STRING|NUMCUR|NUMBER);
+#ifdef HAVE_MPFR
+ if (do_mpfr) {
+ mpz_init(Nnull_string->mpg_i);
+ Nnull_string->flags = (MALLOC|STRCUR|STRING|MPZN|NUMCUR|NUMBER);
+ } else
+#endif
+ {
+ Nnull_string->numbr = 0.0;
+ Nnull_string->flags = (MALLOC|STRCUR|STRING|NUMCUR|NUMBER);
+ }
/*
* Tell the regex routines how they should work.
@@ -588,8 +600,6 @@ out:
*/
resetup();
- (void) grow_stack();
-
/* Set up the special variables */
init_vars();
@@ -623,14 +633,26 @@ out:
#endif
if (os_isatty(fileno(stdout)))
output_is_tty = TRUE;
+
+ /* load extension libs */
+ for (s = srcfiles->next; s != srcfiles; s = s->next) {
+ if (s->stype == SRC_EXTLIB)
+ (void) load_ext(s->fullpath, "dlload", NULL);
+ else
+ have_srcfile++;
+ }
+
/* No -f or --source options, use next arg */
- if (srcfiles->next == srcfiles) {
+ if (! have_srcfile) {
if (optind > argc - 1 || stopped_early) /* no args left or no program */
usage(EXIT_FAILURE, stderr);
(void) add_srcfile(SRC_CMDLINE, argv[optind], srcfiles, NULL, NULL);
optind++;
}
+ /* Select the interpreter routine */
+ init_interpret();
+
init_args(optind, argc,
do_posix ? argv[0] : myname,
argv);
@@ -644,7 +666,7 @@ out:
setlocale(LC_NUMERIC, "C");
#endif
/* Read in the program */
- if (parse_program(&code_block) != 0)
+ if (parse_program(& code_block) != 0)
exit(EXIT_FAILURE);
if (do_intl)
@@ -656,7 +678,8 @@ out:
if (do_lint && code_block->nexti->opcode == Op_atexit)
lintwarn(_("no program text at all!"));
- init_profiling_signals();
+ if (do_profile)
+ init_profiling_signals();
#if defined(LC_NUMERIC)
/*
@@ -677,10 +700,16 @@ out:
if (use_lc_numeric)
setlocale(LC_NUMERIC, "");
#endif
+
+ init_io();
+ output_fp = stdout;
- interpret(code_block);
+ if (do_debug)
+ debug_prog(code_block);
+ else
+ interpret(code_block);
- if (do_profiling) {
+ if (do_pretty_print) {
dump_prog(code_block);
dump_funcs();
}
@@ -734,7 +763,7 @@ usage(int exitval, FILE *fp)
fprintf(fp, _("Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n"),
myname);
fprintf(fp, _("Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n"),
- myname, quote, quote);
+ myname, quote, quote);
/* GNU long options info. This is too many options. */
@@ -747,19 +776,21 @@ usage(int exitval, FILE *fp)
fputs(_("\t-c\t\t\t--traditional\n"), fp);
fputs(_("\t-C\t\t\t--copyright\n"), fp);
fputs(_("\t-d[file]\t\t--dump-variables[=file]\n"), fp);
+ fputs(_("\t-D[file]\t\t--debug[=file]\n"), fp);
fputs(_("\t-e 'program-text'\t--source='program-text'\n"), fp);
fputs(_("\t-E file\t\t\t--exec=file\n"), fp);
fputs(_("\t-g\t\t\t--gen-pot\n"), fp);
fputs(_("\t-h\t\t\t--help\n"), fp);
+ fputs(_("\t-l library\t\t--load=library\n"), fp);
fputs(_("\t-L [fatal]\t\t--lint[=fatal]\n"), fp);
fputs(_("\t-n\t\t\t--non-decimal-data\n"), fp);
+ fputs(_("\t-M\t\t\t--bignum\n"), fp);
fputs(_("\t-N\t\t\t--use-lc-numeric\n"), fp);
+ fputs(_("\t-o[file]\t\t--pretty-print[=file]\n"), fp);
fputs(_("\t-O\t\t\t--optimize\n"), fp);
fputs(_("\t-p[file]\t\t--profile[=file]\n"), fp);
fputs(_("\t-P\t\t\t--posix\n"), fp);
fputs(_("\t-r\t\t\t--re-interval\n"), fp);
- if (which_gawk == exe_debugging)
- fputs(_("\t-R file\t\t\t--command=file\n"), fp);
fputs(_("\t-S\t\t\t--sandbox\n"), fp);
fputs(_("\t-t\t\t\t--lint-old\n"), fp);
fputs(_("\t-V\t\t\t--version\n"), fp);
@@ -857,6 +888,7 @@ cmdline_fs(char *str)
if (do_traditional && ! do_posix)
str[0] = '\t';
}
+
*tmp = make_str_node(str, strlen(str), SCAN); /* do process escapes */
set_FS();
}
@@ -870,26 +902,27 @@ init_args(int argc0, int argc, const char *argv0, char **argv)
NODE **aptr;
NODE *tmp;
- ARGV_node = install_symbol(estrdup("ARGV", 4), mk_symbol(Node_var_array, (NODE *) NULL));
+ ARGV_node = install_symbol(estrdup("ARGV", 4), Node_var_array);
tmp = make_number(0.0);
- aptr = assoc_lookup(ARGV_node, tmp, FALSE);
+ aptr = assoc_lookup(ARGV_node, tmp);
unref(tmp);
unref(*aptr);
*aptr = make_string(argv0, strlen(argv0));
(*aptr)->flags |= MAYBE_NUM;
for (i = argc0, j = 1; i < argc; i++, j++) {
tmp = make_number((AWKNUM) j);
- aptr = assoc_lookup(ARGV_node, tmp, FALSE);
+ aptr = assoc_lookup(ARGV_node, tmp);
unref(tmp);
unref(*aptr);
*aptr = make_string(argv[i], strlen(argv[i]));
(*aptr)->flags |= MAYBE_NUM;
}
- ARGC_node = install_symbol(estrdup("ARGC", 4),
- mk_symbol(Node_var, make_number((AWKNUM) j)));
+ ARGC_node = install_symbol(estrdup("ARGC", 4), Node_var);
+ ARGC_node->var_value = make_number((AWKNUM) j);
}
+
/*
* Set all the special variables to their initial values.
* Note that some of the variables that have set_FOO routines should
@@ -926,6 +959,7 @@ static const struct varinit varinit[] = {
{&FPAT_node, "FPAT", "[^[:space:]]+", 0, NULL, set_FPAT, FALSE, NON_STANDARD },
{&IGNORECASE_node, "IGNORECASE", NULL, 0, NULL, set_IGNORECASE, FALSE, NON_STANDARD },
{&LINT_node, "LINT", NULL, 0, NULL, set_LINT, FALSE, NON_STANDARD },
+{&PREC_node, "PREC", NULL, DEFAULT_PREC, NULL, set_PREC, FALSE, NON_STANDARD},
{&NF_node, "NF", NULL, -1, update_NF, set_NF, FALSE, 0 },
{&NR_node, "NR", NULL, 0, update_NR, set_NR, TRUE, 0 },
{&OFMT_node, "OFMT", "%.6g", 0, NULL, set_OFMT, TRUE, 0 },
@@ -933,6 +967,7 @@ static const struct varinit varinit[] = {
{&ORS_node, "ORS", "\n", 0, NULL, set_ORS, TRUE, 0 },
{NULL, "PROCINFO", NULL, 0, NULL, NULL, FALSE, NO_INSTALL | NON_STANDARD },
{&RLENGTH_node, "RLENGTH", NULL, 0, NULL, NULL, FALSE, 0 },
+{&ROUNDMODE_node, "ROUNDMODE", DEFAULT_ROUNDMODE, 0, NULL, set_ROUNDMODE, FALSE, NON_STANDARD },
{&RS_node, "RS", "\n", 0, NULL, set_RS, TRUE, 0 },
{&RSTART_node, "RSTART", NULL, 0, NULL, NULL, FALSE, 0 },
{&RT_node, "RT", "", 0, NULL, NULL, FALSE, NON_STANDARD },
@@ -952,13 +987,13 @@ init_vars()
for (vp = varinit; vp->name != NULL; vp++) {
if ((vp->flags & NO_INSTALL) != 0)
continue;
- n = mk_symbol(Node_var, vp->strval == NULL
- ? make_number(vp->numval)
- : make_string(vp->strval, strlen(vp->strval)));
+ n = *(vp->spec) = install_symbol(estrdup(vp->name, strlen(vp->name)), Node_var);
+ if (vp->strval != NULL)
+ n->var_value = make_string(vp->strval, strlen(vp->strval));
+ else
+ n->var_value = make_number(vp->numval);
n->var_assign = (Func_ptr) vp->assign;
n->var_update = (Func_ptr) vp->update;
-
- *(vp->spec) = install_symbol(estrdup(vp->name, strlen(vp->name)), n);
if (vp->do_assign)
(*(vp->assign))();
}
@@ -982,9 +1017,7 @@ load_environ()
int i;
NODE *tmp;
- ENVIRON_node = install_symbol(estrdup("ENVIRON", 7),
- mk_symbol(Node_var_array, (NODE *) NULL));
-
+ ENVIRON_node = install_symbol(estrdup("ENVIRON", 7), Node_var_array);
for (i = 0; environ[i] != NULL; i++) {
static char nullstr[] = "";
@@ -995,7 +1028,7 @@ load_environ()
else
val = nullstr;
tmp = make_string(var, strlen(var));
- aptr = assoc_lookup(ENVIRON_node, tmp, FALSE);
+ aptr = assoc_lookup(ENVIRON_node, tmp);
unref(tmp);
unref(*aptr);
*aptr = make_string(val, strlen(val));
@@ -1018,7 +1051,7 @@ load_environ()
val = getenv("AWKPATH");
if (val == NULL)
val = defpath;
- aptr = assoc_lookup(ENVIRON_node, tmp, FALSE);
+ aptr = assoc_lookup(ENVIRON_node, tmp);
unref(*aptr);
*aptr = make_string(val, strlen(val));
}
@@ -1033,16 +1066,26 @@ load_procinfo()
{
#if defined (HAVE_GETGROUPS) && defined(NGROUPS_MAX) && NGROUPS_MAX > 0
int i;
+#endif
+#if (defined (HAVE_GETGROUPS) && defined(NGROUPS_MAX) && NGROUPS_MAX > 0) || defined(HAVE_MPFR)
char name[100];
#endif
AWKNUM value;
- PROCINFO_node = install_symbol(estrdup("PROCINFO", 8),
- mk_symbol(Node_var_array, (NODE *) NULL));
+ PROCINFO_node = install_symbol(estrdup("PROCINFO", 8), Node_var_array);
update_PROCINFO_str("version", VERSION);
update_PROCINFO_str("strftime", def_strftime_format);
+#ifdef HAVE_MPFR
+ sprintf(name, "GNU MPFR %s", mpfr_get_version());
+ update_PROCINFO_str("mpfr_version", name);
+ sprintf(name, "GNU MP %s", gmp_version);
+ update_PROCINFO_str("gmp_version", name);
+ update_PROCINFO_num("prec_max", MPFR_PREC_MAX);
+ update_PROCINFO_num("prec_min", MPFR_PREC_MIN);
+#endif
+
#ifdef GETPGRP_VOID
#define getpgrp_arg() /* nothing */
#else
@@ -1234,7 +1277,7 @@ arg_assign(char *arg, int initing)
cp2 = estrdup(arg, cp - arg); /* var name */
- var = variable(cp2, Node_var);
+ var = variable(0, cp2, Node_var);
if (var == NULL) /* error */
exit(EXIT_FATAL);
if (var->type == Node_var && var->var_update)
@@ -1319,7 +1362,11 @@ nostalgia()
static void
version()
{
- printf("%s\n", version_string);
+ printf("%s", version_string);
+#ifdef HAVE_MPFR
+ printf(" (GNU MPFR %s, GNU MP %s)", mpfr_get_version(), gmp_version);
+#endif
+ printf("\n");
/*
* Per GNU coding standards, print copyright info,
* then exit successfully, do nothing else.
@@ -1461,3 +1508,18 @@ update_global_values()
vp->update();
}
}
+
+/* getenv_long --- read a long value (>= 0) from an environment var. */
+
+long
+getenv_long(const char *name)
+{
+ const char *val;
+ long newval;
+ if ((val = getenv(name)) != NULL && isdigit((unsigned char) *val)) {
+ for (newval = 0; *val && isdigit((unsigned char) *val); val++)
+ newval = (newval * 10) + *val - '0';
+ return newval;
+ }
+ return -1;
+}
diff --git a/mpfr.c b/mpfr.c
new file mode 100644
index 00000000..b28c7206
--- /dev/null
+++ b/mpfr.c
@@ -0,0 +1,1620 @@
+/*
+ * mpfr.c - routines for arbitrary-precision number support in gawk.
+ */
+
+/*
+ * Copyright (C) 2012 the Free Software Foundation, Inc.
+ *
+ * This file is part of GAWK, the GNU implementation of the
+ * AWK Programming Language.
+ *
+ * GAWK is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * GAWK is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
+ */
+
+#include "awk.h"
+
+#ifdef HAVE_MPFR
+
+#if !defined(MPFR_VERSION_MAJOR) || MPFR_VERSION_MAJOR < 3
+typedef mp_exp_t mpfr_exp_t;
+#endif
+
+extern NODE **fmt_list; /* declared in eval.c */
+
+mpz_t mpzval; /* GMP integer type, used as temporary in few places */
+mpz_t MNR;
+mpz_t MFNR;
+int do_ieee_fmt; /* IEEE-754 floating-point emulation */
+mpfr_rnd_t ROUND_MODE;
+
+static mpfr_rnd_t get_rnd_mode(const char rmode);
+static NODE *mpg_force_number(NODE *n);
+static NODE *mpg_make_number(double);
+static NODE *mpg_format_val(const char *format, int index, NODE *s);
+static int mpg_interpret(INSTRUCTION **cp);
+
+static mpfr_exp_t min_exp = MPFR_EMIN_DEFAULT;
+static mpfr_exp_t max_exp = MPFR_EMAX_DEFAULT;
+
+/* temporaries used in bit ops */
+static NODE *_tz1;
+static NODE *_tz2;
+static mpz_t _mpz1;
+static mpz_t _mpz2;
+static mpz_ptr mpz1;
+static mpz_ptr mpz2;
+
+static NODE *get_bit_ops(const char *op);
+#define free_bit_ops() (DEREF(_tz1), DEREF(_tz2))
+
+/* temporary MPFR floats used to hold converted GMP integer operands */
+static mpfr_t _mpf_t1;
+static mpfr_t _mpf_t2;
+
+/*
+ * PRECISION_MIN is the precision used to initialize _mpf_t1 and _mpf_t2.
+ * 64 bits should be enough for exact conversion of most integers to floats.
+ */
+
+#define PRECISION_MIN 64
+
+/* mf = { _mpf_t1, _mpf_t2 } */
+static inline mpfr_ptr mpg_tofloat(mpfr_ptr mf, mpz_ptr mz);
+/* T = {t1, t2} */
+#define MP_FLOAT(T) is_mpg_integer(T) ? mpg_tofloat(_mpf_##T, (T)->mpg_i) : (T)->mpg_numbr
+
+
+/* init_mpfr --- set up MPFR related variables */
+
+void
+init_mpfr(mpfr_prec_t prec, const char *rmode)
+{
+ mpfr_set_default_prec(prec);
+ ROUND_MODE = get_rnd_mode(rmode[0]);
+ mpfr_set_default_rounding_mode(ROUND_MODE);
+ make_number = mpg_make_number;
+ str2number = mpg_force_number;
+ format_val = mpg_format_val;
+ cmp_numbers = mpg_cmp;
+
+ mpz_init(MNR);
+ mpz_init(MFNR);
+ do_ieee_fmt = FALSE;
+
+ mpz_init(_mpz1);
+ mpz_init(_mpz2);
+ mpfr_init2(_mpf_t1, PRECISION_MIN);
+ mpfr_init2(_mpf_t2, PRECISION_MIN);
+ mpz_init(mpzval);
+
+ register_exec_hook(mpg_interpret, 0);
+}
+
+/* mpg_node --- allocate a node to store MPFR float or GMP integer */
+
+NODE *
+mpg_node(unsigned int tp)
+{
+ NODE *r;
+ getnode(r);
+ r->type = Node_val;
+
+ if (tp == MPFN) {
+ /* Initialize, set precision to the default precision, and value to NaN */
+ mpfr_init(r->mpg_numbr);
+ r->flags = MPFN;
+ } else {
+ /* Initialize and set value to 0 */
+ mpz_init(r->mpg_i);
+ r->flags = MPZN;
+ }
+
+ r->valref = 1;
+ r->flags |= MALLOC|NUMBER|NUMCUR;
+ r->stptr = NULL;
+ r->stlen = 0;
+#if MBS_SUPPORT
+ r->wstptr = NULL;
+ r->wstlen = 0;
+#endif /* defined MBS_SUPPORT */
+ return r;
+}
+
+/*
+ * mpg_make_number --- make a arbitrary-precision number node
+ * and initialize with a C double
+ */
+
+static NODE *
+mpg_make_number(double x)
+{
+ NODE *r;
+ double ival;
+
+ if ((ival = double_to_int(x)) != x) {
+ int tval;
+ r = mpg_float();
+ tval = mpfr_set_d(r->mpg_numbr, x, ROUND_MODE);
+ IEEE_FMT(r->mpg_numbr, tval);
+ } else {
+ r = mpg_integer();
+ mpz_set_d(r->mpg_i, ival);
+ }
+ return r;
+}
+
+/* mpg_strtoui --- assign arbitrary-precision integral value from a string */
+
+int
+mpg_strtoui(mpz_ptr zi, char *str, size_t len, char **end, int base)
+{
+ char *s = str;
+ char *start;
+ int ret = -1;
+
+ /*
+ * mpz_set_str does not like leading 0x or 0X for hex (or 0 for octal)
+ * with a non-zero base argument.
+ */
+ if (base == 16 && len >= 2 && *s == '0' && (s[1] == 'x' || s[1] == 'X')) {
+ s += 2; len -= 2;
+ } else if (base == 8 && len >= 1 && *s == '0') {
+ s++; len--;
+ }
+ start = s;
+
+ while (len > 0) {
+ switch (*s) {
+ case '0':
+ case '1':
+ case '2':
+ case '3':
+ case '4':
+ case '5':
+ case '6':
+ case '7':
+ break;
+ case '8':
+ case '9':
+ if (base == 8)
+ goto done;
+ break;
+ case 'a':
+ case 'b':
+ case 'c':
+ case 'd':
+ case 'e':
+ case 'f':
+ case 'A':
+ case 'B':
+ case 'C':
+ case 'D':
+ case 'E':
+ case 'F':
+ if (base == 16)
+ break;
+ default:
+ goto done;
+ }
+ s++; len--;
+ }
+done:
+ if (s > start) {
+ char save = *s;
+ *s = '\0';
+ ret = mpz_set_str(zi, start, base);
+ *s = save;
+ }
+ if (end != NULL)
+ *end = s;
+ return ret;
+}
+
+
+/* mpg_maybe_float --- test if a string may contain arbitrary-precision float */
+
+static int
+mpg_maybe_float(const char *str, int use_locale)
+{
+ int dec_point = '.';
+ const char *s = str;
+
+#if defined(HAVE_LOCALE_H)
+ /*
+ * loc.decimal_point may not have been initialized yet,
+ * so double check it before using it.
+ */
+ if (use_locale && loc.decimal_point != NULL && loc.decimal_point[0] != '\0')
+ dec_point = loc.decimal_point[0]; /* XXX --- assumes one char */
+#endif
+
+ if (strlen(s) >= 3
+ && ( ( (s[0] == 'i' || s[0] == 'I')
+ && (s[1] == 'n' || s[1] == 'N')
+ && (s[2] == 'f' || s[2] == 'F'))
+ || ( (s[0] == 'n' || s[0] == 'N')
+ && (s[1] == 'a' || s[1] == 'A')
+ && (s[2] == 'n' || s[2] == 'N'))))
+ return TRUE;
+
+ for (; *s != '\0'; s++) {
+ if (*s == dec_point || *s == 'e' || *s == 'E')
+ return TRUE;
+ }
+
+ return FALSE;
+}
+
+
+/* mpg_zero --- initialize with arbitrary-precision integer(GMP) and set value to zero */
+
+static inline void
+mpg_zero(NODE *n)
+{
+ if (is_mpg_float(n)) {
+ mpfr_clear(n->mpg_numbr);
+ n->flags &= ~MPFN;
+ }
+ if (! is_mpg_integer(n)) {
+ mpz_init(n->mpg_i); /* this also sets its value to 0 */
+ n->flags |= MPZN;
+ } else
+ mpz_set_si(n->mpg_i, 0);
+}
+
+
+/* force_mpnum --- force a value to be a GMP integer or MPFR float */
+
+static int
+force_mpnum(NODE *n, int do_nondec, int use_locale)
+{
+ char *cp, *cpend, *ptr, *cp1;
+ char save;
+ int tval, base = 10;
+
+ if (n->stlen == 0) {
+ mpg_zero(n);
+ return FALSE;
+ }
+
+ cp = n->stptr;
+ cpend = n->stptr + n->stlen;
+ while (cp < cpend && isspace((unsigned char) *cp))
+ cp++;
+ if (cp == cpend) { /* only spaces */
+ mpg_zero(n);
+ return FALSE;
+ }
+
+ save = *cpend;
+ *cpend = '\0';
+
+ if (*cp == '+' || *cp == '-')
+ cp1 = cp + 1;
+ else
+ cp1 = cp;
+
+ if (do_nondec)
+ base = get_numbase(cp1, use_locale);
+
+ if (! mpg_maybe_float(cp1, use_locale)) {
+ mpg_zero(n);
+ errno = 0;
+ mpg_strtoui(n->mpg_i, cp1, cpend - cp1, & ptr, base);
+ if (*cp == '-')
+ mpz_neg(n->mpg_i, n->mpg_i);
+ goto done;
+ }
+
+ if (is_mpg_integer(n)) {
+ mpz_clear(n->mpg_i);
+ n->flags &= ~MPZN;
+ }
+
+ if (! is_mpg_float(n)) {
+ mpfr_init(n->mpg_numbr);
+ n->flags |= MPFN;
+ }
+
+ errno = 0;
+ tval = mpfr_strtofr(n->mpg_numbr, cp, & ptr, base, ROUND_MODE);
+ IEEE_FMT(n->mpg_numbr, tval);
+done:
+ /* trailing space is OK for NUMBER */
+ while (isspace((unsigned char) *ptr))
+ ptr++;
+ *cpend = save;
+ if (errno == 0 && ptr == cpend)
+ return TRUE;
+ errno = 0;
+ return FALSE;
+}
+
+/* mpg_force_number --- force a value to be a multiple-precision number */
+
+static NODE *
+mpg_force_number(NODE *n)
+{
+ unsigned int newflags = 0;
+
+ if (is_mpg_number(n) && (n->flags & NUMCUR))
+ return n;
+
+ if (n->flags & MAYBE_NUM) {
+ n->flags &= ~MAYBE_NUM;
+ newflags = NUMBER;
+ }
+
+ if (force_mpnum(n, (do_non_decimal_data && ! do_traditional), TRUE)) {
+ n->flags |= newflags;
+ n->flags |= NUMCUR;
+ }
+ return n;
+}
+
+/* mpg_format_val --- format a numeric value based on format */
+
+static NODE *
+mpg_format_val(const char *format, int index, NODE *s)
+{
+ NODE *dummy[2], *r;
+ unsigned int oflags;
+
+ /* create dummy node for a sole use of format_tree */
+ dummy[1] = s;
+ oflags = s->flags;
+
+ if (is_mpg_integer(s) || mpfr_integer_p(s->mpg_numbr)) {
+ /* integral value, use %d */
+ r = format_tree("%d", 2, dummy, 2);
+ s->stfmt = -1;
+ } else {
+ r = format_tree(format, fmt_list[index]->stlen, dummy, 2);
+ assert(r != NULL);
+ s->stfmt = (char) index;
+ }
+ s->flags = oflags;
+ s->stlen = r->stlen;
+ if ((s->flags & STRCUR) != 0)
+ efree(s->stptr);
+ s->stptr = r->stptr;
+ freenode(r); /* Do not unref(r)! We want to keep s->stptr == r->stpr. */
+
+ s->flags |= STRCUR;
+ free_wstr(s);
+ return s;
+}
+
+/* mpg_cmp --- compare two numbers */
+
+int
+mpg_cmp(const NODE *t1, const NODE *t2)
+{
+ /*
+ * For the purposes of sorting, NaN is considered greater than
+ * any other value, and all NaN values are considered equivalent and equal.
+ */
+
+ if (is_mpg_float(t1)) {
+ if (is_mpg_float(t2)) {
+ if (mpfr_nan_p(t1->mpg_numbr))
+ return ! mpfr_nan_p(t2->mpg_numbr);
+ if (mpfr_nan_p(t2->mpg_numbr))
+ return -1;
+ return mpfr_cmp(t1->mpg_numbr, t2->mpg_numbr);
+ }
+ if (mpfr_nan_p(t1->mpg_numbr))
+ return 1;
+ return mpfr_cmp_z(t1->mpg_numbr, t2->mpg_i);
+ } else if (is_mpg_float(t2)) {
+ int ret;
+ if (mpfr_nan_p(t2->mpg_numbr))
+ return -1;
+ ret = mpfr_cmp_z(t2->mpg_numbr, t1->mpg_i);
+ return ret > 0 ? -1 : (ret < 0);
+ } else if (is_mpg_integer(t1)) {
+ return mpz_cmp(t1->mpg_i, t2->mpg_i);
+ }
+
+ /* t1 and t2 are AWKNUMs */
+ return cmp_awknums(t1, t2);
+}
+
+
+/*
+ * mpg_update_var --- update NR or FNR.
+ * NR_node->var_value(mpz_t) = MNR(mpz_t) * LONG_MAX + NR(long)
+ */
+
+NODE *
+mpg_update_var(NODE *n)
+{
+ NODE *val = n->var_value;
+ long nr = 0;
+ mpz_ptr nq = 0;
+
+ if (n == NR_node) {
+ nr = NR;
+ nq = MNR;
+ } else if (n == FNR_node) {
+ nr = FNR;
+ nq = MFNR;
+ } else
+ cant_happen();
+
+ if (mpz_sgn(nq) == 0) {
+ /* Efficiency hack similar to that for AWKNUM */
+ if (is_mpg_float(val) || mpz_get_si(val->mpg_i) != nr) {
+ unref(n->var_value);
+ val = n->var_value = mpg_integer();
+ mpz_set_si(val->mpg_i, nr);
+ }
+ } else {
+ unref(n->var_value);
+ val = n->var_value = mpg_integer();
+ mpz_set_si(val->mpg_i, nr);
+ mpz_addmul_ui(val->mpg_i, nq, LONG_MAX); /* val->mpg_i += nq * LONG_MAX */
+ }
+ return val;
+}
+
+/* mpg_set_var --- set NR or FNR */
+
+long
+mpg_set_var(NODE *n)
+{
+ long nr = 0;
+ mpz_ptr nq = 0, r;
+ NODE *val = n->var_value;
+
+ if (n == NR_node)
+ nq = MNR;
+ else if (n == FNR_node)
+ nq = MFNR;
+ else
+ cant_happen();
+
+ if (is_mpg_integer(val))
+ r = val->mpg_i;
+ else {
+ /* convert float to integer */
+ mpfr_get_z(mpzval, val->mpg_numbr, MPFR_RNDZ);
+ r = mpzval;
+ }
+ nr = mpz_fdiv_q_ui(nq, r, LONG_MAX); /* nq (MNR or MFNR) is quotient */
+ return nr; /* remainder (NR or FNR) */
+}
+
+/* set_PREC --- update MPFR PRECISION related variables when PREC assigned to */
+
+void
+set_PREC()
+{
+ long prec = 0;
+ NODE *val;
+ static const struct ieee_fmt {
+ const char *name;
+ mpfr_prec_t precision;
+ mpfr_exp_t emax;
+ mpfr_exp_t emin;
+ } ieee_fmts[] = {
+{ "half", 11, 16, -23 }, /* binary16 */
+{ "single", 24, 128, -148 }, /* binary32 */
+{ "double", 53, 1024, -1073 }, /* binary64 */
+{ "quad", 113, 16384, -16493 }, /* binary128 */
+{ "oct", 237, 262144, -262377 }, /* binary256, not in the IEEE 754-2008 standard */
+
+ /*
+ * For any bitwidth = 32 * k ( k >= 4),
+ * precision = 13 + bitwidth - int(4 * log2(bitwidth))
+ * emax = 1 << bitwidth - precision - 1
+ * emin = 4 - emax - precision
+ */
+ };
+
+ if (! do_mpfr)
+ return;
+
+ val = PREC_node->var_value;
+ if (val->flags & MAYBE_NUM)
+ force_number(val);
+
+ if ((val->flags & (STRING|NUMBER)) == STRING) {
+ int i, j;
+
+ /* emulate IEEE-754 binary format */
+
+ for (i = 0, j = sizeof(ieee_fmts)/sizeof(ieee_fmts[0]); i < j; i++) {
+ if (strcasecmp(ieee_fmts[i].name, val->stptr) == 0)
+ break;
+ }
+
+ if (i < j) {
+ prec = ieee_fmts[i].precision;
+
+ /*
+ * We *DO NOT* change the MPFR exponent range using
+ * mpfr_set_{emin, emax} here. See format_ieee() for details.
+ */
+ max_exp = ieee_fmts[i].emax;
+ min_exp = ieee_fmts[i].emin;
+
+ do_ieee_fmt = TRUE;
+ }
+ }
+
+ if (prec <= 0) {
+ force_number(val);
+ prec = get_number_si(val);
+ if (prec < MPFR_PREC_MIN || prec > MPFR_PREC_MAX) {
+ force_string(val);
+ warning(_("PREC value `%.*s' is invalid"), (int) val->stlen, val->stptr);
+ prec = 0;
+ } else
+ do_ieee_fmt = FALSE;
+ }
+
+ if (prec > 0)
+ mpfr_set_default_prec(prec);
+}
+
+
+/* get_rnd_mode --- convert string to MPFR rounding mode */
+
+static mpfr_rnd_t
+get_rnd_mode(const char rmode)
+{
+ switch (rmode) {
+ case 'N':
+ case 'n':
+ return MPFR_RNDN; /* round to nearest (IEEE-754 roundTiesToEven) */
+ case 'Z':
+ case 'z':
+ return MPFR_RNDZ; /* round toward zero (IEEE-754 roundTowardZero) */
+ case 'U':
+ case 'u':
+ return MPFR_RNDU; /* round toward plus infinity (IEEE-754 roundTowardPositive) */
+ case 'D':
+ case 'd':
+ return MPFR_RNDD; /* round toward minus infinity (IEEE-754 roundTowardNegative) */
+#if defined(MPFR_VERSION_MAJOR) && MPFR_VERSION_MAJOR > 2
+ case 'A':
+ case 'a':
+ return MPFR_RNDA; /* round away from zero (IEEE-754 roundTiesToAway) */
+#endif
+ default:
+ break;
+ }
+ return -1;
+}
+
+/*
+ * set_ROUNDMODE --- update MPFR rounding mode related variables
+ * when ROUNDMODE assigned to
+ */
+
+void
+set_ROUNDMODE()
+{
+ if (do_mpfr) {
+ mpfr_rnd_t rndm = -1;
+ NODE *n;
+ n = force_string(ROUNDMODE_node->var_value);
+ if (n->stlen == 1)
+ rndm = get_rnd_mode(n->stptr[0]);
+ if (rndm != -1) {
+ mpfr_set_default_rounding_mode(rndm);
+ ROUND_MODE = rndm;
+ } else
+ warning(_("RNDMODE value `%.*s' is invalid"), (int) n->stlen, n->stptr);
+ }
+}
+
+
+/* format_ieee --- make sure a number follows IEEE-754 floating-point standard */
+
+int
+format_ieee(mpfr_ptr x, int tval)
+{
+ /*
+ * The MPFR doc says that it's our responsibility to make sure all numbers
+ * including those previously created are in range after we've changed the
+ * exponent range. Most MPFR operations and functions require
+ * the input arguments to have exponents within the current exponent range.
+ * Any argument outside the range results in a MPFR assertion failure
+ * like this:
+ *
+ * $ gawk -M 'BEGIN { x=1.0e-10000; print x+0; PREC="double"; print x+0}'
+ * 1e-10000
+ * init2.c:52: MPFR assertion failed ....
+ *
+ * A "naive" approach would be to keep track of the ternary state and
+ * the rounding mode for each number, and make sure it is in the current
+ * exponent range (using mpfr_check_range) before using it in an
+ * operation or function. Instead, we adopt the following strategy.
+ *
+ * When gawk starts, the exponent range is the MPFR default
+ * [MPFR_EMIN_DEFAULT, MPFR_EMAX_DEFAULT]. Any number that gawk
+ * creates must have exponent in this range (excluding infinities, NaNs and zeros).
+ * Each MPFR operation or function is performed with this default exponent
+ * range.
+ *
+ * When emulating IEEE-754 format, the exponents are *temporarily* changed,
+ * mpfr_check_range is called to make sure the number is in the new range,
+ * and mpfr_subnormalize is used to round following the rules of subnormal
+ * arithmetic. The exponent range is then *restored* to the original value
+ * [MPFR_EMIN_DEFAULT, MPFR_EMAX_DEFAULT].
+ */
+
+ (void) mpfr_set_emin(min_exp);
+ (void) mpfr_set_emax(max_exp);
+ tval = mpfr_check_range(x, tval, ROUND_MODE);
+ tval = mpfr_subnormalize(x, tval, ROUND_MODE);
+ (void) mpfr_set_emin(MPFR_EMIN_DEFAULT);
+ (void) mpfr_set_emax(MPFR_EMAX_DEFAULT);
+ return tval;
+}
+
+
+/* do_mpfr_atan2 --- do the atan2 function */
+
+NODE *
+do_mpfr_atan2(int nargs)
+{
+ NODE *t1, *t2, *res;
+ mpfr_ptr p1, p2;
+ int tval;
+
+ t2 = POP_SCALAR();
+ t1 = POP_SCALAR();
+
+ if (do_lint) {
+ if ((t1->flags & (NUMCUR|NUMBER)) == 0)
+ lintwarn(_("atan2: received non-numeric first argument"));
+ if ((t2->flags & (NUMCUR|NUMBER)) == 0)
+ lintwarn(_("atan2: received non-numeric second argument"));
+ }
+ force_number(t1);
+ force_number(t2);
+
+ p1 = MP_FLOAT(t1);
+ p2 = MP_FLOAT(t2);
+ res = mpg_float();
+ /* See MPFR documentation for handling of special values like +inf as an argument */
+ tval = mpfr_atan2(res->mpg_numbr, p1, p2, ROUND_MODE);
+ IEEE_FMT(res->mpg_numbr, tval);
+
+ DEREF(t1);
+ DEREF(t2);
+ return res;
+}
+
+
+#define SPEC_MATH(X) \
+NODE *t1, *res; \
+mpfr_ptr p1; \
+int tval; \
+t1 = POP_SCALAR(); \
+if (do_lint && (t1->flags & (NUMCUR|NUMBER)) == 0) \
+ lintwarn(_("%s: received non-numeric argument"), #X); \
+force_number(t1); \
+p1 = MP_FLOAT(t1); \
+res = mpg_float(); \
+tval = mpfr_##X(res->mpg_numbr, p1, ROUND_MODE); \
+IEEE_FMT(res->mpg_numbr, tval); \
+DEREF(t1); \
+return res
+
+
+/* do_mpfr_sin --- do the sin function */
+
+NODE *
+do_mpfr_sin(int nargs)
+{
+ SPEC_MATH(sin);
+}
+
+/* do_mpfr_cos --- do the cos function */
+
+NODE *
+do_mpfr_cos(int nargs)
+{
+ SPEC_MATH(cos);
+}
+
+/* do_mpfr_exp --- exponential function */
+
+NODE *
+do_mpfr_exp(int nargs)
+{
+ SPEC_MATH(exp);
+}
+
+/* do_mpfr_log --- the log function */
+
+NODE *
+do_mpfr_log(int nargs)
+{
+ SPEC_MATH(log);
+}
+
+/* do_mpfr_sqrt --- do the sqrt function */
+
+NODE *
+do_mpfr_sqrt(int nargs)
+{
+ SPEC_MATH(sqrt);
+}
+
+/* do_mpfr_int --- convert double to int for awk */
+
+NODE *
+do_mpfr_int(int nargs)
+{
+ NODE *tmp, *r;
+
+ tmp = POP_SCALAR();
+ if (do_lint && (tmp->flags & (NUMCUR|NUMBER)) == 0)
+ lintwarn(_("int: received non-numeric argument"));
+ force_number(tmp);
+
+ if (is_mpg_integer(tmp)) {
+ r = mpg_integer();
+ mpz_set(r->mpg_i, tmp->mpg_i);
+ } else {
+ if (! mpfr_number_p(tmp->mpg_numbr)) {
+ /* [+-]inf or NaN */
+ return tmp;
+ }
+
+ r = mpg_integer();
+ mpfr_get_z(r->mpg_i, tmp->mpg_numbr, MPFR_RNDZ);
+ }
+
+ DEREF(tmp);
+ return r;
+}
+
+/* do_mpfr_compl --- perform a ~ operation */
+
+NODE *
+do_mpfr_compl(int nargs)
+{
+ NODE *tmp, *r;
+ mpz_ptr zptr;
+
+ tmp = POP_SCALAR();
+ if (do_lint && (tmp->flags & (NUMCUR|NUMBER)) == 0)
+ lintwarn(_("compl: received non-numeric argument"));
+
+ force_number(tmp);
+ if (is_mpg_float(tmp)) {
+ mpfr_ptr p = tmp->mpg_numbr;
+
+ if (! mpfr_number_p(p)) {
+ /* [+-]inf or NaN */
+ return tmp;
+ }
+ if (do_lint) {
+ if (mpfr_sgn(p) < 0)
+ lintwarn("%s",
+ mpg_fmt(_("compl(%Rg): negative value will give strange results"), p)
+ );
+ if (! mpfr_integer_p(p))
+ lintwarn("%s",
+ mpg_fmt(_("comp(%Rg): fractional value will be truncated"), p)
+ );
+ }
+
+ mpfr_get_z(mpzval, p, MPFR_RNDZ); /* float to integer conversion */
+ zptr = mpzval;
+ } else {
+ /* (tmp->flags & MPZN) != 0 */
+ zptr = tmp->mpg_i;
+ if (do_lint) {
+ if (mpz_sgn(zptr) < 0)
+ lintwarn("%s",
+ mpg_fmt(_("cmpl(%Zd): negative values will give strange results"), zptr)
+ );
+ }
+ }
+
+ r = mpg_integer();
+ mpz_com(r->mpg_i, zptr);
+ DEREF(tmp);
+ return r;
+}
+
+
+/*
+ * get_bit_ops --- get the numeric operands of a binary function.
+ * Returns a copy of the operand if either is inf or nan. Otherwise
+ * each operand is converted to an integer if necessary, and
+ * the results are placed in the variables mpz1 and mpz2.
+ */
+
+static NODE *
+get_bit_ops(const char *op)
+{
+ _tz2 = POP_SCALAR();
+ _tz1 = POP_SCALAR();
+
+ if (do_lint) {
+ if ((_tz1->flags & (NUMCUR|NUMBER)) == 0)
+ lintwarn(_("%s: received non-numeric first argument"), op);
+ if ((_tz2->flags & (NUMCUR|NUMBER)) == 0)
+ lintwarn(_("%s: received non-numeric second argument"), op);
+ }
+
+ force_number(_tz1);
+ force_number(_tz2);
+
+ if (is_mpg_float(_tz1)) {
+ mpfr_ptr left = _tz1->mpg_numbr;
+ if (! mpfr_number_p(left)) {
+ /* inf or NaN */
+ NODE *res;
+ res = mpg_float();
+ mpfr_set(res->mpg_numbr, _tz1->mpg_numbr, ROUND_MODE);
+ return res;
+ }
+
+ if (do_lint) {
+ if (mpfr_sgn(left) < 0)
+ lintwarn("%s",
+ mpg_fmt(_("%s(%Rg, ..): negative values will give strange results"),
+ op, left)
+ );
+ if (! mpfr_integer_p(left))
+ lintwarn("%s",
+ mpg_fmt(_("%s(%Rg, ..): fractional values will be truncated"),
+ op, left)
+ );
+ }
+
+ mpfr_get_z(_mpz1, left, MPFR_RNDZ); /* float to integer conversion */
+ mpz1 = _mpz1;
+ } else {
+ /* (_tz1->flags & MPZN) != 0 */
+ mpz1 = _tz1->mpg_i;
+ if (do_lint) {
+ if (mpz_sgn(mpz1) < 0)
+ lintwarn("%s",
+ mpg_fmt(_("%s(%Zd, ..): negative values will give strange results"),
+ op, mpz1)
+ );
+ }
+ }
+
+ if (is_mpg_float(_tz2)) {
+ mpfr_ptr right = _tz2->mpg_numbr;
+ if (! mpfr_number_p(right)) {
+ /* inf or NaN */
+ NODE *res;
+ res = mpg_float();
+ mpfr_set(res->mpg_numbr, _tz2->mpg_numbr, ROUND_MODE);
+ return res;
+ }
+
+ if (do_lint) {
+ if (mpfr_sgn(right) < 0)
+ lintwarn("%s",
+ mpg_fmt(_("%s(.., %Rg): negative values will give strange results"),
+ op, right)
+ );
+ if (! mpfr_integer_p(right))
+ lintwarn("%s",
+ mpg_fmt(_("%s(.., %Rg): fractional values will be truncated"),
+ op, right)
+ );
+ }
+
+ mpfr_get_z(_mpz2, right, MPFR_RNDZ); /* float to integer conversion */
+ mpz2 = _mpz2;
+ } else {
+ /* (_tz2->flags & MPZN) != 0 */
+ mpz2 = _tz2->mpg_i;
+ if (do_lint) {
+ if (mpz_sgn(mpz2) < 0)
+ lintwarn("%s",
+ mpg_fmt(_("%s(.., %Zd): negative values will give strange results"),
+ op, mpz2)
+ );
+ }
+ }
+
+ return NULL;
+}
+
+/* do_mpfr_lshift --- perform a << operation */
+
+NODE *
+do_mpfr_lshift(int nargs)
+{
+ NODE *res;
+ unsigned long shift;
+
+ if ((res = get_bit_ops("lshift")) == NULL) {
+
+ /*
+ * mpz_get_ui: If op is too big to fit an unsigned long then just
+ * the least significant bits that do fit are returned.
+ * The sign of op is ignored, only the absolute value is used.
+ */
+
+ shift = mpz_get_ui(mpz2); /* GMP integer => unsigned long conversion */
+ res = mpg_integer();
+ mpz_mul_2exp(res->mpg_i, mpz1, shift); /* res = mpz1 * 2^shift */
+ }
+ free_bit_ops();
+ return res;
+}
+
+/* do_mpfr_rshift --- perform a >> operation */
+
+NODE *
+do_mpfr_rhift(int nargs)
+{
+ NODE *res;
+ unsigned long shift;
+
+ if ((res = get_bit_ops("rshift")) == NULL) {
+ /*
+ * mpz_get_ui: If op is too big to fit an unsigned long then just
+ * the least significant bits that do fit are returned.
+ * The sign of op is ignored, only the absolute value is used.
+ */
+
+ shift = mpz_get_ui(mpz2); /* GMP integer => unsigned long conversion */
+ res = mpg_integer();
+ mpz_fdiv_q_2exp(res->mpg_i, mpz1, shift); /* res = mpz1 / 2^shift, round towards −inf */
+ }
+ free_bit_ops();
+ return res;
+}
+
+/* do_mpfr_and --- perform an & operation */
+
+NODE *
+do_mpfr_and(int nargs)
+{
+ NODE *res;
+
+ if ((res = get_bit_ops("and")) == NULL) {
+ res = mpg_integer();
+ mpz_and(res->mpg_i, mpz1, mpz2);
+ }
+ free_bit_ops();
+ return res;
+}
+
+/* do_mpfr_or --- perform an | operation */
+
+NODE *
+do_mpfr_or(int nargs)
+{
+ NODE *res;
+
+ if ((res = get_bit_ops("or")) == NULL) {
+ res = mpg_integer();
+ mpz_ior(res->mpg_i, mpz1, mpz2);
+ }
+ free_bit_ops();
+ return res;
+}
+
+/* do_mpfr_strtonum --- the strtonum function */
+
+NODE *
+do_mpfr_strtonum(int nargs)
+{
+ NODE *tmp, *r;
+
+ tmp = POP_SCALAR();
+ if ((tmp->flags & (NUMBER|NUMCUR)) == 0) {
+ r = mpg_integer(); /* will be changed to MPFR float if necessary in force_mpnum() */
+ r->stptr = tmp->stptr;
+ r->stlen = tmp->stlen;
+ force_mpnum(r, TRUE, use_lc_numeric);
+ r->stptr = NULL;
+ r->stlen = 0;
+ } else {
+ (void) force_number(tmp);
+ if (is_mpg_float(tmp)) {
+ int tval;
+ r = mpg_float();
+ tval = mpfr_set(r->mpg_numbr, tmp->mpg_numbr, ROUND_MODE);
+ IEEE_FMT(r->mpg_numbr, tval);
+ } else {
+ r = mpg_integer();
+ mpz_set(r->mpg_i, tmp->mpg_i);
+ }
+ }
+
+ DEREF(tmp);
+ return r;
+}
+
+/* do_mpfr_xor --- perform an ^ operation */
+
+NODE *
+do_mpfr_xor(int nargs)
+{
+ NODE *res;
+
+ if ((res = get_bit_ops("xor")) == NULL) {
+ res = mpg_integer();
+ mpz_xor(res->mpg_i, mpz1, mpz2);
+ }
+ free_bit_ops();
+ return res;
+}
+
+
+static int firstrand = TRUE;
+static gmp_randstate_t state;
+static mpz_t seed; /* current seed */
+
+/* do_mpfr_rand --- do the rand function */
+
+NODE *
+do_mpfr_rand(int nargs ATTRIBUTE_UNUSED)
+{
+ NODE *res;
+ int tval;
+
+ if (firstrand) {
+#if 0
+ /* Choose the default algorithm */
+ gmp_randinit_default(state);
+#endif
+ /*
+ * Choose a specific (Mersenne Twister) algorithm in case the default
+ * changes in the future.
+ */
+
+ gmp_randinit_mt(state);
+
+ mpz_init(seed);
+ mpz_set_ui(seed, 1);
+ /* seed state */
+ gmp_randseed(state, seed);
+ firstrand = FALSE;
+ }
+ res = mpg_float();
+ tval = mpfr_urandomb(res->mpg_numbr, state);
+ IEEE_FMT(res->mpg_numbr, tval);
+ return res;
+}
+
+
+/* do_mpfr_srand --- seed the random number generator */
+
+NODE *
+do_mpfr_srand(int nargs)
+{
+ NODE *res;
+
+ if (firstrand) {
+#if 0
+ /* Choose the default algorithm */
+ gmp_randinit_default(state);
+#endif
+ /*
+ * Choose a specific algorithm (Mersenne Twister) in case default
+ * changes in the future.
+ */
+
+ gmp_randinit_mt(state);
+
+ mpz_init(seed);
+ mpz_set_ui(seed, 1);
+ /* No need to seed state, will change it below */
+ firstrand = FALSE;
+ }
+
+ res = mpg_integer();
+ mpz_set(res->mpg_i, seed); /* previous seed */
+
+ if (nargs == 0)
+ mpz_set_ui(seed, (unsigned long) time((time_t *) 0));
+ else {
+ NODE *tmp;
+ tmp = POP_SCALAR();
+ if (do_lint && (tmp->flags & (NUMCUR|NUMBER)) == 0)
+ lintwarn(_("srand: received non-numeric argument"));
+ force_number(tmp);
+ if (is_mpg_float(tmp))
+ mpfr_get_z(seed, tmp->mpg_numbr, MPFR_RNDZ);
+ else /* MP integer */
+ mpz_set(seed, tmp->mpg_i);
+ DEREF(tmp);
+ }
+
+ gmp_randseed(state, seed);
+ return res;
+}
+
+/*
+ * mpg_tofloat --- convert an arbitrary-precision integer operand to
+ * a float without loss of precision. It is assumed that the
+ * MPFR variable has already been initialized.
+ */
+
+static inline mpfr_ptr
+mpg_tofloat(mpfr_ptr mf, mpz_ptr mz)
+{
+ size_t prec;
+
+ /*
+ * When implicitely converting a GMP integer operand to a MPFR float, use
+ * a precision sufficiently large to hold the converted value exactly.
+ *
+ * $ ./gawk -M 'BEGIN { print 13 % 2 }'
+ * 1
+ * If the user-specified precision is used to convert the integer 13 to a
+ * float, one will get:
+ * $ ./gawk -M 'BEGIN { PREC=2; print 13 % 2.0 }'
+ * 0
+ */
+
+ prec = mpz_sizeinbase(mz, 2); /* most significant 1 bit position starting at 1 */
+ if (prec > PRECISION_MIN) {
+ prec -= (size_t) mpz_scan1(mz, 0); /* least significant 1 bit index starting at 0 */
+ if (prec > MPFR_PREC_MAX)
+ prec = MPFR_PREC_MAX;
+ if (prec > PRECISION_MIN)
+ mpfr_set_prec(mf, prec);
+ }
+
+ mpfr_set_z(mf, mz, ROUND_MODE);
+ return mf;
+}
+
+
+/* mpg_add --- add arbitrary-precision numbers */
+
+static NODE *
+mpg_add(NODE *t1, NODE *t2)
+{
+ NODE *r;
+ int tval;
+
+ if (is_mpg_integer(t1) && is_mpg_integer(t2)) {
+ r = mpg_integer();
+ mpz_add(r->mpg_i, t1->mpg_i, t2->mpg_i);
+ } else {
+ r = mpg_float();
+ if (is_mpg_integer(t2))
+ tval = mpfr_add_z(r->mpg_numbr, t1->mpg_numbr, t2->mpg_i, ROUND_MODE);
+ else if (is_mpg_integer(t1))
+ tval = mpfr_add_z(r->mpg_numbr, t2->mpg_numbr, t1->mpg_i, ROUND_MODE);
+ else
+ tval = mpfr_add(r->mpg_numbr, t1->mpg_numbr, t2->mpg_numbr, ROUND_MODE);
+ IEEE_FMT(r->mpg_numbr, tval);
+ }
+ return r;
+}
+
+/* mpg_sub --- subtract arbitrary-precision numbers */
+
+static NODE *
+mpg_sub(NODE *t1, NODE *t2)
+{
+ NODE *r;
+ int tval;
+
+ if (is_mpg_integer(t1) && is_mpg_integer(t2)) {
+ r = mpg_integer();
+ mpz_sub(r->mpg_i, t1->mpg_i, t2->mpg_i);
+ } else {
+ r = mpg_float();
+ if (is_mpg_integer(t2))
+ tval = mpfr_sub_z(r->mpg_numbr, t1->mpg_numbr, t2->mpg_i, ROUND_MODE);
+ else if (is_mpg_integer(t1)) {
+#if (!defined(MPFR_VERSION) || (MPFR_VERSION < MPFR_VERSION_NUM(3,1,0)))
+ NODE *tmp = t1;
+ t1 = t2;
+ t2 = tmp;
+ tval = mpfr_sub_z(r->mpg_numbr, t1->mpg_numbr, t2->mpg_i, ROUND_MODE);
+ tval = mpfr_neg(r->mpg_numbr, r->mpg_numbr, ROUND_MODE);
+ t2 = t1;
+ t1 = tmp;
+#else
+ tval = mpfr_z_sub(r->mpg_numbr, t1->mpg_i, t2->mpg_numbr, ROUND_MODE);
+#endif
+ } else
+ tval = mpfr_sub(r->mpg_numbr, t1->mpg_numbr, t2->mpg_numbr, ROUND_MODE);
+ IEEE_FMT(r->mpg_numbr, tval);
+ }
+ return r;
+}
+
+/* mpg_mul --- multiply arbitrary-precision numbers */
+
+static NODE *
+mpg_mul(NODE *t1, NODE *t2)
+{
+ NODE *r;
+ int tval;
+
+ if (is_mpg_integer(t1) && is_mpg_integer(t2)) {
+ r = mpg_integer();
+ mpz_mul(r->mpg_i, t1->mpg_i, t2->mpg_i);
+ } else {
+ r = mpg_float();
+ if (is_mpg_integer(t2))
+ tval = mpfr_mul_z(r->mpg_numbr, t1->mpg_numbr, t2->mpg_i, ROUND_MODE);
+ else if (is_mpg_integer(t1))
+ tval = mpfr_mul_z(r->mpg_numbr, t2->mpg_numbr, t1->mpg_i, ROUND_MODE);
+ else
+ tval = mpfr_mul(r->mpg_numbr, t1->mpg_numbr, t2->mpg_numbr, ROUND_MODE);
+ IEEE_FMT(r->mpg_numbr, tval);
+ }
+ return r;
+}
+
+
+/* mpg_pow --- exponentiation involving arbitrary-precision numbers */
+
+static NODE *
+mpg_pow(NODE *t1, NODE *t2)
+{
+ NODE *r;
+ int tval;
+
+ if (is_mpg_integer(t1) && is_mpg_integer(t2)) {
+ if (mpz_sgn(t2->mpg_i) >= 0 && mpz_fits_ulong_p(t2->mpg_i)) {
+ r = mpg_integer();
+ mpz_pow_ui(r->mpg_i, t1->mpg_i, mpz_get_ui(t2->mpg_i));
+ } else {
+ mpfr_ptr p1, p2;
+ p1 = MP_FLOAT(t1);
+ p2 = MP_FLOAT(t2);
+ r = mpg_float();
+ tval = mpfr_pow(r->mpg_numbr, p1, p2, ROUND_MODE);
+ IEEE_FMT(r->mpg_numbr, tval);
+ }
+ } else {
+ r = mpg_float();
+ if (is_mpg_integer(t2))
+ tval = mpfr_pow_z(r->mpg_numbr, t1->mpg_numbr, t2->mpg_i, ROUND_MODE);
+ else {
+ mpfr_ptr p1;
+ p1 = MP_FLOAT(t1);
+ tval = mpfr_pow(r->mpg_numbr, p1, t2->mpg_numbr, ROUND_MODE);
+ }
+ IEEE_FMT(r->mpg_numbr, tval);
+ }
+ return r;
+}
+
+/* mpg_div --- arbitrary-precision division */
+
+static NODE *
+mpg_div(NODE *t1, NODE *t2)
+{
+ NODE *r;
+ int tval;
+
+ if (is_mpg_integer(t1) && is_mpg_integer(t2)
+ && (mpz_sgn(t2->mpg_i) != 0) /* not dividing by 0 */
+ && mpz_divisible_p(t1->mpg_i, t2->mpg_i)
+ ) {
+ r = mpg_integer();
+ mpz_divexact(r->mpg_i, t1->mpg_i, t2->mpg_i);
+ } else {
+ mpfr_ptr p1, p2;
+ p1 = MP_FLOAT(t1);
+ p2 = MP_FLOAT(t2);
+ r = mpg_float();
+ tval = mpfr_div(r->mpg_numbr, p1, p2, ROUND_MODE);
+ IEEE_FMT(r->mpg_numbr, tval);
+ }
+ return r;
+}
+
+/* mpg_mod --- modulus operation with arbitrary-precision numbers */
+
+static NODE *
+mpg_mod(NODE *t1, NODE *t2)
+{
+ NODE *r;
+ int tval;
+
+ if (is_mpg_integer(t1) && is_mpg_integer(t2)) {
+ r = mpg_integer();
+ mpz_mod(r->mpg_i, t1->mpg_i, t2->mpg_i);
+ } else {
+ mpfr_ptr p1, p2;
+ p1 = MP_FLOAT(t1);
+ p2 = MP_FLOAT(t2);
+ r = mpg_float();
+ tval = mpfr_fmod(r->mpg_numbr, p1, p2, ROUND_MODE);
+ IEEE_FMT(r->mpg_numbr, tval);
+ }
+ return r;
+}
+
+/*
+ * mpg_interpret --- pre-exec hook in the interpreter. Handles
+ * arithmetic operations with MPFR/GMP numbers.
+ */
+
+static int
+mpg_interpret(INSTRUCTION **cp)
+{
+ INSTRUCTION *pc = *cp; /* current instruction */
+ OPCODE op; /* current opcode */
+ NODE *r = NULL;
+ NODE *t1, *t2;
+ NODE **lhs;
+ int tval; /* the ternary value returned by a MPFR function */
+
+ switch ((op = pc->opcode)) {
+ case Op_plus_i:
+ t2 = force_number(pc->memory);
+ goto plus;
+ case Op_plus:
+ t2 = POP_NUMBER();
+plus:
+ t1 = TOP_NUMBER();
+ r = mpg_add(t1, t2);
+ DEREF(t1);
+ if (op == Op_plus)
+ DEREF(t2);
+ REPLACE(r);
+ break;
+
+ case Op_minus_i:
+ t2 = force_number(pc->memory);
+ goto minus;
+ case Op_minus:
+ t2 = POP_NUMBER();
+minus:
+ t1 = TOP_NUMBER();
+ r = mpg_sub(t1, t2);
+ DEREF(t1);
+ if (op == Op_minus)
+ DEREF(t2);
+ REPLACE(r);
+ break;
+
+ case Op_times_i:
+ t2 = force_number(pc->memory);
+ goto times;
+ case Op_times:
+ t2 = POP_NUMBER();
+times:
+ t1 = TOP_NUMBER();
+ r = mpg_mul(t1, t2);
+ DEREF(t1);
+ if (op == Op_times)
+ DEREF(t2);
+ REPLACE(r);
+ break;
+
+ case Op_exp_i:
+ t2 = force_number(pc->memory);
+ goto exp;
+ case Op_exp:
+ t2 = POP_NUMBER();
+exp:
+ t1 = TOP_NUMBER();
+ r = mpg_pow(t1, t2);
+ DEREF(t1);
+ if (op == Op_exp)
+ DEREF(t2);
+ REPLACE(r);
+ break;
+
+ case Op_quotient_i:
+ t2 = force_number(pc->memory);
+ goto quotient;
+ case Op_quotient:
+ t2 = POP_NUMBER();
+quotient:
+ t1 = TOP_NUMBER();
+ r = mpg_div(t1, t2);
+ DEREF(t1);
+ if (op == Op_quotient)
+ DEREF(t2);
+ REPLACE(r);
+ break;
+
+ case Op_mod_i:
+ t2 = force_number(pc->memory);
+ goto mod;
+ case Op_mod:
+ t2 = POP_NUMBER();
+mod:
+ t1 = TOP_NUMBER();
+ r = mpg_mod(t1, t2);
+ DEREF(t1);
+ if (op == Op_mod)
+ DEREF(t2);
+ REPLACE(r);
+ break;
+
+ case Op_preincrement:
+ case Op_predecrement:
+ lhs = TOP_ADDRESS();
+ t1 = *lhs;
+ force_number(t1);
+
+ if (is_mpg_integer(t1)) {
+ if (t1->valref == 1 && t1->flags == (MALLOC|MPZN|NUMCUR|NUMBER))
+ /* Efficiency hack. Big speed-up (> 30%) in a tight loop */
+ r = t1;
+ else
+ r = *lhs = mpg_integer();
+ if (op == Op_preincrement)
+ mpz_add_ui(r->mpg_i, t1->mpg_i, 1);
+ else
+ mpz_sub_ui(r->mpg_i, t1->mpg_i, 1);
+ } else {
+
+ /*
+ * An optimization like the one above is not going to work
+ * for a floating-point number. With it,
+ * gawk -M 'BEGIN { PREC=53; i=2^53+0.0; PREC=113; ++i; print i}'
+ * will output 2^53 instead of 2^53+1.
+ */
+
+ r = *lhs = mpg_float();
+ tval = mpfr_add_si(r->mpg_numbr, t1->mpg_numbr,
+ op == Op_preincrement ? 1 : -1,
+ ROUND_MODE);
+ IEEE_FMT(r->mpg_numbr, tval);
+ }
+ if (r != t1)
+ unref(t1);
+ UPREF(r);
+ REPLACE(r);
+ break;
+
+ case Op_postincrement:
+ case Op_postdecrement:
+ lhs = TOP_ADDRESS();
+ t1 = *lhs;
+ force_number(t1);
+
+ if (is_mpg_integer(t1)) {
+ r = mpg_integer();
+ mpz_set(r->mpg_i, t1->mpg_i);
+ if (t1->valref == 1 && t1->flags == (MALLOC|MPZN|NUMCUR|NUMBER))
+ /* Efficiency hack. Big speed-up (> 30%) in a tight loop */
+ t2 = t1;
+ else
+ t2 = *lhs = mpg_integer();
+ if (op == Op_postincrement)
+ mpz_add_ui(t2->mpg_i, t1->mpg_i, 1);
+ else
+ mpz_sub_ui(t2->mpg_i, t1->mpg_i, 1);
+ } else {
+ r = mpg_float();
+ tval = mpfr_set(r->mpg_numbr, t1->mpg_numbr, ROUND_MODE);
+ IEEE_FMT(r->mpg_numbr, tval);
+ t2 = *lhs = mpg_float();
+ tval = mpfr_add_si(t2->mpg_numbr, t1->mpg_numbr,
+ op == Op_postincrement ? 1 : -1,
+ ROUND_MODE);
+ IEEE_FMT(t2->mpg_numbr, tval);
+ }
+ if (t2 != t1)
+ unref(t1);
+ REPLACE(r);
+ break;
+
+ case Op_unary_minus:
+ t1 = TOP_NUMBER();
+ if (is_mpg_float(t1)) {
+ r = mpg_float();
+ tval = mpfr_neg(r->mpg_numbr, t1->mpg_numbr, ROUND_MODE);
+ IEEE_FMT(r->mpg_numbr, tval);
+ } else {
+ r = mpg_integer();
+ mpz_neg(r->mpg_i, t1->mpg_i);
+ }
+ DEREF(t1);
+ REPLACE(r);
+ break;
+
+ case Op_assign_plus:
+ case Op_assign_minus:
+ case Op_assign_times:
+ case Op_assign_quotient:
+ case Op_assign_mod:
+ case Op_assign_exp:
+ lhs = POP_ADDRESS();
+ t1 = *lhs;
+ force_number(t1);
+ t2 = TOP_NUMBER();
+
+ switch (op) {
+ case Op_assign_plus:
+ r = mpg_add(t1, t2);
+ break;
+ case Op_assign_minus:
+ r = mpg_sub(t1, t2);
+ break;
+ case Op_assign_times:
+ r = mpg_mul(t1, t2);
+ break;
+ case Op_assign_quotient:
+ r = mpg_div(t1, t2);
+ break;
+ case Op_assign_mod:
+ r = mpg_mod(t1, t2);
+ break;
+ case Op_assign_exp:
+ r = mpg_pow(t1, t2);
+ break;
+ default:
+ cant_happen();
+ }
+
+ DEREF(t2);
+ unref(*lhs);
+ *lhs = r;
+ UPREF(r);
+ REPLACE(r);
+ break;
+
+ default:
+ return TRUE; /* unhandled */
+ }
+
+ *cp = pc->nexti; /* next instruction to execute */
+ return FALSE;
+}
+
+
+/* mpg_fmt --- output formatted string with special MPFR/GMP conversion specifiers */
+
+const char *
+mpg_fmt(const char *mesg, ...)
+{
+ static char *tmp = NULL;
+ int ret;
+ va_list args;
+
+ if (tmp != NULL) {
+ mpfr_free_str(tmp);
+ tmp = NULL;
+ }
+ va_start(args, mesg);
+ ret = mpfr_vasprintf(& tmp, mesg, args);
+ va_end(args);
+ if (ret >= 0 && tmp != NULL)
+ return tmp;
+ return mesg;
+}
+
+#else
+
+void
+set_PREC()
+{
+ /* dummy function */
+}
+
+void
+set_ROUNDMODE()
+{
+ /* dummy function */
+}
+
+#endif
diff --git a/msg.c b/msg.c
index 3ed02331..78818187 100644
--- a/msg.c
+++ b/msg.c
@@ -46,8 +46,6 @@ err(const char *s, const char *emsg, va_list argp)
(void) fflush(output_fp);
me = myname;
- if (strncmp(me, "dgawk", 5) == 0)
- me = &myname[1];
(void) fprintf(stderr, "%s: ", me);
#ifdef GAWKDEBUG
if (srcfile != NULL) {
@@ -64,6 +62,21 @@ err(const char *s, const char *emsg, va_list argp)
(void) fprintf(stderr, "%d: ", sourceline);
}
+
+#ifdef HAVE_MPFR
+ if (FNR_node && is_mpg_number(FNR_node->var_value)) {
+ NODE *val;
+ val = mpg_update_var(FNR_node);
+ assert((val->flags & MPZN) != 0);
+ if (mpz_sgn(val->mpg_i) > 0) {
+ file = FILENAME_node->var_value->stptr;
+ (void) putc('(', stderr);
+ if (file)
+ (void) fprintf(stderr, "FILENAME=%s ", file);
+ (void) mpfr_fprintf(stderr, "FNR=%Zd) ", val->mpg_i);
+ }
+ } else
+#endif
if (FNR > 0) {
file = FILENAME_node->var_value->stptr;
(void) putc('(', stderr);
@@ -71,6 +84,7 @@ err(const char *s, const char *emsg, va_list argp)
(void) fprintf(stderr, "FILENAME=%s ", file);
(void) fprintf(stderr, "FNR=%ld) ", FNR);
}
+
(void) fprintf(stderr, "%s", s);
vfprintf(stderr, emsg, argp);
(void) fprintf(stderr, "\n");
diff --git a/node.c b/node.c
index 204a91f9..8dbe68a9 100644
--- a/node.c
+++ b/node.c
@@ -26,13 +26,21 @@
#include "awk.h"
#include "math.h"
+#include "floatmagic.h" /* definition of isnan */
static int is_ieee_magic_val(const char *val);
+static NODE *r_make_number(double x);
static AWKNUM get_ieee_magic_val(const char *val);
+extern NODE **fmt_list; /* declared in eval.c */
+
+NODE *(*make_number)(double) = r_make_number;
+NODE *(*str2number)(NODE *) = r_force_number;
+NODE *(*format_val)(const char *, int, NODE *) = r_format_val;
+int (*cmp_numbers)(const NODE *, const NODE *) = cmp_awknums;
/* force_number --- force a value to be numeric */
-AWKNUM
+NODE *
r_force_number(NODE *n)
{
char *cp;
@@ -43,7 +51,7 @@ r_force_number(NODE *n)
extern double strtod();
if (n->flags & NUMCUR)
- return n->numbr;
+ return n;
/* all the conditionals are an attempt to avoid the expensive strtod */
@@ -52,7 +60,7 @@ r_force_number(NODE *n)
n->numbr = 0.0;
if (n->stlen == 0) {
- return 0.0;
+ return n;
}
cp = n->stptr;
@@ -65,14 +73,14 @@ r_force_number(NODE *n)
*/
if (! do_posix) {
if (isalpha((unsigned char) *cp)) {
- return 0.0;
+ return n;
} else if (n->stlen == 4 && is_ieee_magic_val(n->stptr)) {
if (n->flags & MAYBE_NUM)
n->flags &= ~MAYBE_NUM;
n->flags |= NUMBER|NUMCUR;
n->numbr = get_ieee_magic_val(n->stptr);
- return n->numbr;
+ return n;
}
/* else
fall through */
@@ -90,7 +98,7 @@ r_force_number(NODE *n)
/* CANNOT do non-decimal and saw 0x */
|| (! do_non_decimal_data && cp[0] == '0'
&& (cp[1] == 'x' || cp[1] == 'X'))))) {
- return 0.0;
+ return n;
}
if (n->flags & MAYBE_NUM) {
@@ -104,13 +112,15 @@ r_force_number(NODE *n)
n->numbr = (AWKNUM)(*cp - '0');
n->flags |= newflags;
n->flags |= NUMCUR;
+ if (cp == n->stptr) /* no leading spaces */
+ n->flags |= NUMINT;
}
- return n->numbr;
+ return n;
}
if (do_non_decimal_data) { /* main.c assures false if do_posix */
errno = 0;
- if (! do_traditional && isnondecimal(cp, TRUE)) {
+ if (! do_traditional && get_numbase(cp, TRUE) != 10) {
n->numbr = nondec2awknum(cp, cpend - cp);
n->flags |= NUMCUR;
ptr = cpend;
@@ -135,7 +145,7 @@ finish:
errno = 0;
}
- return n->numbr;
+ return n;
}
@@ -158,26 +168,14 @@ static const char *values[] = {
};
#define NVAL (sizeof(values)/sizeof(values[0]))
-/* format_val --- format a numeric value based on format */
+/* r_format_val --- format a numeric value based on format */
NODE *
-format_val(const char *format, int index, NODE *s)
+r_format_val(const char *format, int index, NODE *s)
{
char buf[BUFSIZ];
char *sp = buf;
double val;
- char *orig, *trans, save;
-
- if (! do_traditional && (s->flags & INTLSTR) != 0) {
- save = s->stptr[s->stlen];
- s->stptr[s->stlen] = '\0';
-
- orig = s->stptr;
- trans = dgettext(TEXTDOMAIN, orig);
-
- s->stptr[s->stlen] = save;
- return make_string(trans, strlen(trans));
- }
/*
* 2/2007: Simplify our lives here. Instead of worrying about
@@ -198,7 +196,8 @@ format_val(const char *format, int index, NODE *s)
/* not an integral value, or out of range */
if ((val = double_to_int(s->numbr)) != s->numbr
- || val <= LONG_MIN || val >= LONG_MAX) {
+ || val <= LONG_MIN || val >= LONG_MAX
+ ) {
/*
* Once upon a time, we just blindly did this:
* sprintf(sp, format, s->numbr);
@@ -209,12 +208,12 @@ format_val(const char *format, int index, NODE *s)
*/
NODE *dummy[2], *r;
- unsigned short oflags;
- extern NODE **fmt_list; /* declared in eval.c */
+ unsigned int oflags;
/* create dummy node for a sole use of format_tree */
dummy[1] = s;
oflags = s->flags;
+
if (val == s->numbr) {
/* integral value, but outside range of %ld, use %.0f */
r = format_tree("%.0f", 4, dummy, 2);
@@ -234,8 +233,7 @@ format_val(const char *format, int index, NODE *s)
goto no_malloc;
} else {
/*
- * integral value
- * force conversion to long only once
+ * integral value; force conversion to long only once.
*/
long num = (long) val;
@@ -247,19 +245,25 @@ format_val(const char *format, int index, NODE *s)
s->stlen = strlen(sp);
}
s->stfmt = -1;
+ if (s->flags & INTIND) {
+ s->flags &= ~(INTIND|NUMBER);
+ s->flags |= STRING;
+ }
}
if (s->stptr != NULL)
efree(s->stptr);
emalloc(s->stptr, char *, s->stlen + 2, "format_val");
- memcpy(s->stptr, sp, s->stlen+1);
+ memcpy(s->stptr, sp, s->stlen + 1);
no_malloc:
s->flags |= STRCUR;
free_wstr(s);
return s;
}
-/* force_string --- force a value to be a string */
+/* r_force_string --- force a value to be a string */
+
+#ifdef GAWKDEBUG
NODE *
r_force_string(NODE *s)
{
@@ -269,28 +273,23 @@ r_force_string(NODE *s)
return s;
return format_val(CONVFMT, CONVFMTidx, s);
}
+#endif
-/* dupnode --- duplicate a node */
+/* r_dupnode --- duplicate a node */
NODE *
-dupnode(NODE *n)
+r_dupnode(NODE *n)
{
NODE *r;
- if (n->type == Node_ahash) {
- n->ahname_ref++;
- return n;
- }
-
assert(n->type == Node_val);
- if ((n->flags & PERM) != 0)
- return n;
-
+#ifdef GAWKDEBUG
if ((n->flags & MALLOC) != 0) {
n->valref++;
return n;
}
+#endif
getnode(r);
*r = *n;
@@ -308,13 +307,13 @@ dupnode(NODE *n)
#endif /* MBS_SUPPORT */
if ((n->flags & STRCUR) != 0) {
- emalloc(r->stptr, char *, n->stlen + 2, "dupnode");
+ emalloc(r->stptr, char *, n->stlen + 2, "r_dupnode");
memcpy(r->stptr, n->stptr, n->stlen);
r->stptr[n->stlen] = '\0';
#if MBS_SUPPORT
if ((n->flags & WSTRCUR) != 0) {
r->wstlen = n->wstlen;
- emalloc(r->wstptr, wchar_t *, sizeof(wchar_t) * (n->wstlen + 2), "dupnode");
+ emalloc(r->wstptr, wchar_t *, sizeof(wchar_t) * (n->wstlen + 2), "r_dupnode");
memcpy(r->wstptr, n->wstptr, n->wstlen * sizeof(wchar_t));
r->wstptr[n->wstlen] = L'\0';
r->flags |= WSTRCUR;
@@ -325,35 +324,66 @@ dupnode(NODE *n)
return r;
}
-/* mk_number --- allocate a node with defined number */
+/* r_make_number --- allocate a node with defined number */
-NODE *
-mk_number(AWKNUM x, unsigned int flags)
+static NODE *
+r_make_number(double x)
{
NODE *r;
-
getnode(r);
r->type = Node_val;
r->numbr = x;
+ r->flags = MALLOC|NUMBER|NUMCUR;
r->valref = 1;
- r->flags = flags;
r->stptr = NULL;
r->stlen = 0;
- free_wstr(r);
+#if MBS_SUPPORT
+ r->wstptr = NULL;
+ r->wstlen = 0;
+#endif /* defined MBS_SUPPORT */
return r;
}
-/* make_str_node --- make a string node */
+/* cmp_awknums --- compare two AWKNUMs */
+
+int
+cmp_awknums(const NODE *t1, const NODE *t2)
+{
+ /*
+ * This routine is also used to sort numeric array indices or values.
+ * For the purposes of sorting, NaN is considered greater than
+ * any other value, and all NaN values are considered equivalent and equal.
+ * This isn't in compliance with IEEE standard, but compliance w.r.t. NaN
+ * comparison at the awk level is a different issue, and needs to be dealt
+ * with in the interpreter for each opcode seperately.
+ */
+
+ if (isnan(t1->numbr))
+ return ! isnan(t2->numbr);
+ if (isnan(t2->numbr))
+ return -1;
+ /* don't subtract, in case one or both are infinite */
+ if (t1->numbr == t2->numbr)
+ return 0;
+ if (t1->numbr < t2->numbr)
+ return -1;
+ return 1;
+}
+
+
+/* r_make_str_node --- make a string node */
NODE *
-r_make_str_node(const char *s, unsigned long len, int flags)
+r_make_str_node(const char *s, size_t len, int flags)
{
NODE *r;
-
getnode(r);
r->type = Node_val;
r->numbr = 0;
- r->flags = (STRING|STRCUR|MALLOC);
+ r->flags = (MALLOC|STRING|STRCUR);
+ r->valref = 1;
+ r->stfmt = -1;
+
#if MBS_SUPPORT
r->wstptr = NULL;
r->wstlen = 0;
@@ -362,11 +392,11 @@ r_make_str_node(const char *s, unsigned long len, int flags)
if (flags & ALREADY_MALLOCED)
r->stptr = (char *) s;
else {
- emalloc(r->stptr, char *, len + 2, "make_str_node");
+ emalloc(r->stptr, char *, len + 2, "r_make_str_node");
memcpy(r->stptr, s, len);
}
r->stptr[len] = '\0';
-
+
if ((flags & SCAN) != 0) { /* scan for escape sequences */
const char *pf;
char *ptm;
@@ -411,70 +441,43 @@ r_make_str_node(const char *s, unsigned long len, int flags)
*ptm++ = c;
}
len = ptm - r->stptr;
- erealloc(r->stptr, char *, len + 1, "make_str_node");
+ erealloc(r->stptr, char *, len + 1, "r_make_str_node");
r->stptr[len] = '\0';
- r->flags &= ~MALLOC;
- r->flags |= PERM;
}
r->stlen = len;
- r->valref = 1;
- r->stfmt = -1;
return r;
}
-/* more_nodes --- allocate more nodes */
-
-#define NODECHUNK 100
-
-NODE *nextfree = NULL;
-
-NODE *
-more_nodes()
-{
- NODE *np;
-
- /* get more nodes and initialize list */
- emalloc(nextfree, NODE *, NODECHUNK * sizeof(NODE), "more_nodes");
- memset(nextfree, 0, NODECHUNK * sizeof(NODE));
- for (np = nextfree; np <= &nextfree[NODECHUNK - 1]; np++) {
- np->nextp = np + 1;
- }
- --np;
- np->nextp = NULL;
- np = nextfree;
- nextfree = nextfree->nextp;
- return np;
-}
/* unref --- remove reference to a particular node */
void
-unref(NODE *tmp)
+r_unref(NODE *tmp)
{
+#ifdef GAWKDEBUG
if (tmp == NULL)
return;
- if ((tmp->flags & PERM) != 0)
- return;
-
- if (tmp->type == Node_ahash) {
- if (tmp->ahname_ref > 1)
- tmp->ahname_ref--;
- else {
- efree(tmp->ahname_str);
- freenode(tmp);
- }
- return;
- }
-
if ((tmp->flags & MALLOC) != 0) {
if (tmp->valref > 1) {
- tmp->valref--;
+ tmp->valref--;
return;
- }
+ }
if (tmp->flags & STRCUR)
efree(tmp->stptr);
}
+#else
+ if ((tmp->flags & (MALLOC|STRCUR)) == (MALLOC|STRCUR))
+ efree(tmp->stptr);
+#endif
+
+#ifdef HAVE_MPFR
+ if (is_mpg_float(tmp))
+ mpfr_clear(tmp->mpg_numbr);
+ else if (is_mpg_integer(tmp))
+ mpz_clear(tmp->mpg_i);
+#endif
+
free_wstr(tmp);
freenode(tmp);
}
@@ -615,12 +618,14 @@ parse_escape(const char **string_ptr)
}
}
-/* isnondecimal --- return true if number is not a decimal number */
+/* get_numbase --- return the base to use for the number in 's' */
int
-isnondecimal(const char *str, int use_locale)
+get_numbase(const char *s, int use_locale)
{
int dec_point = '.';
+ const char *str = s;
+
#if defined(HAVE_LOCALE_H)
/*
* loc.decimal_point may not have been initialized yet,
@@ -631,11 +636,11 @@ isnondecimal(const char *str, int use_locale)
#endif
if (str[0] != '0')
- return FALSE;
+ return 10;
/* leading 0x or 0X */
if (str[1] == 'x' || str[1] == 'X')
- return TRUE;
+ return 16;
/*
* Numbers with '.', 'e', or 'E' are decimal.
@@ -645,12 +650,16 @@ isnondecimal(const char *str, int use_locale)
*/
for (; *str != '\0'; str++) {
if (*str == 'e' || *str == 'E' || *str == dec_point)
- return FALSE;
+ return 10;
else if (! isdigit((unsigned char) *str))
break;
}
- return TRUE;
+ if (! isdigit((unsigned char) s[1])
+ || s[1] == '8' || s[1] == '9'
+ )
+ return 10;
+ return 8;
}
#if MBS_SUPPORT
@@ -963,3 +972,41 @@ void init_btowc_cache()
}
}
#endif
+
+#define BLOCKCHUNK 100
+
+BLOCK nextfree[BLOCK_MAX] = {
+ { 0, NULL}, /* invalid */
+ { sizeof(NODE), NULL },
+ { sizeof(BUCKET), NULL },
+};
+
+
+/* more_blocks --- get more blocks of memory and add to the free list;
+ size of a block must be >= sizeof(BLOCK)
+ */
+
+void *
+more_blocks(int id)
+{
+ BLOCK *freep, *np, *next;
+ char *p, *endp;
+ size_t size;
+
+ size = nextfree[id].size;
+
+ emalloc(freep, BLOCK *, BLOCKCHUNK * size, "more_blocks");
+ p = (char *) freep;
+ endp = p + BLOCKCHUNK * size;
+
+ for (np = freep; ; np = next) {
+ next = (BLOCK *) (p += size);
+ if (p >= endp) {
+ np->freep = NULL;
+ break;
+ }
+ np->freep = next;
+ }
+ nextfree[id].freep = freep->freep;
+ return freep;
+}
diff --git a/pc/ChangeLog b/pc/ChangeLog
index 41cc25bd..8d340b45 100644
--- a/pc/ChangeLog
+++ b/pc/ChangeLog
@@ -1,3 +1,37 @@
+2012-04-16 Eli Zaretskii <eliz@gnu.org>
+
+ * Makefile.tst (PGAWK): Redefine as "../gawk.exe -p".
+ (MPFR_TESTS): New variable, a list of MPFR-related tests.
+ (mpfr-tests): A new target.
+ (badargs): Reset GREP_OPTIONS to empty, to avoid gratuitous
+ failures when the user has something like -nH there.
+ (mpfrieee, mpfrexprange, mpfrrnd, mpfrnr, mpfrsort, mpfrbigint):
+ New tests.
+
+ * Makefile (default): Add descriptions of mingw32-mpfr and
+ mingw32-libreadline-mpfr targets.
+ (PRSPFILE, DRSPFILE, PRSP, DRSP, PLDRSP, DLDRSP, DO_PLNK)
+ (DO_PBIND, DO_DLNK, DO_DBIND, PLDJG, DLDJG, PLMINGW32)
+ (DLMINGW32, PAWKOBJS1, PAWKOBJS2, DAWKOBJS2, PGAWKOBJS)
+ (DGAWKOBJS): Remove unused variables.
+ (djgpp, djgpp-debug, mingw32): Don't use them.
+ (mingw32): Add -D__USE_MINGW_ANSI_STDIO to compilation flags.
+ (mingw32-readline, mingw32-mpfr, mingw32-readline-mpfr): New targets.
+ (CFLAGS, AWKOBJS2): Don't reference obsolete DYN_FLAGS and DYN_OBJ
+ variables.
+ (AWKOBJS2): Add symbol$O.
+ (AWKOBJS3): New variable, lists MPFR-related object files.
+ (AWKOBJS): Add $(AWKOBJS3).
+ (all): Remove pgawk.exe and dgawk.exe.
+ (pgawk.exe, dgawk.exe, $(PRSPFILE) $(DRSPFILE), eval_p$O)
+ (profile_p$O): Remove targets.
+ (random$O, debug$O): Don't depend on floatmagic.h
+ (eval$O): Depend on interpret.h.
+ (clean): Prepend '-' to command line, to ignore errors due to
+ non-existent files.
+
+ * config.h: Comment out "#undef HAVE_LIBREADLINE" (again).
+
2012-03-29 Arnold D. Robbins <arnold@skeeve.com>
* config.h: Add definition for _Noreturn.
@@ -56,6 +90,10 @@
* Makefile.tst: Sync with mainline version.
+2011-12-12 Scott Deifik <scottd.mail@sbcglobal.net>
+
+ * Makefile.tst: Sync with mainline version.
+
2011-12-06 Scott Deifik <scottd.mail@sbcglobal.net>
* Makefile.tst: Sync with mainline version.
diff --git a/pc/Makefile b/pc/Makefile
index af3044d3..21fe0bfe 100644
--- a/pc/Makefile
+++ b/pc/Makefile
@@ -16,6 +16,9 @@ default:
@echo " mingw32 . Windows32 exe [Mingw32 GNU C] "
@echo " mingw32-readline . Like mingw32, but with readline "
@echo " [You will need to have GNU readline library installed.] "
+ @echo " mingw32-mpfr . Like mingw32, but with MPFR "
+ @echo " [You will need to have GNU MPFR library installed.] "
+ @echo " mingw32-readline-mpfr . mingw32 with readline and MPFR "
@echo " ----------------------------------------------------- "
@echo " test .... Perform tests (see README_d/README.pc) "
@echo " install . Install gawk under $(prefix)/ "
@@ -39,8 +42,6 @@ default:
#======================= Configuration ==================================
RSPFILE = gawk.rsp
-PRSPFILE = pgawk.rsp
-DRSPFILE = dgawk.rsp
#
# Choose method for passing arguments to the linker.
#
@@ -50,11 +51,7 @@ DRSPFILE = dgawk.rsp
#
# else use brain-dead approach (emxbnd will need 'tr').
RSP = $(RSPFILE)
-PRSP = $(PRSPFILE)
-DRSP = $(DRSPFILE)
LDRSP = @$(RSP)
-PLDRSP = @$(PRSP)
-DLDRSP = @$(DRSP)
LNKRSP = $(LDRSP)
#------------------------------------------------------------------------
# Some makes do not define MAKE (and ndmake does not allow a define).
@@ -80,10 +77,6 @@ install = 1
# that $($X) can be expanded.
DO_LNK = $($(LNK))
DO_BIND= $($(BIND))
-DO_PLNK = $($(PLNK))
-DO_PBIND= $($(PBIND))
-DO_DLNK = $($(DLNK))
-DO_DBIND= $($(DBIND))
#========================================================================
# End of general configuration. Some platform-specific configuration
# notes appear below.
@@ -97,21 +90,19 @@ prefix = $(DJDIR)
pkgdatadir = $(prefix)/share/awk
endif
LDJG = $(CC) $(LF) -o gawk.exe $(LDRSP) $(LF2)
-PLDJG = $(CC) $(LF) -o pgawk.exe $(PLDRSP) $(LF2)
-DLDJG = $(CC) $(LF) -o dgawk.exe $(DLDRSP) $(LF2)
BDJG = stubify -g awk.exe | stubedit awk.exe runfile=gawk
djgpp:
$(MAK) all \
CC=gcc O=.o CF=-O2 \
- LNK=LDJG PLNK=PLDJG DLNK=DLDJG LF=-s LF2=-lm \
- BIND=BDJG PBIND='' DBIND=''
+ LNK=LDJG LF=-s LF2=-lm \
+ BIND=BDJG
djgpp-debug:
$(MAK) all \
CC=gcc O=.o CF='-O2 -g' \
- LNK=LDJG PLNK=PLDJG DLNK=DLDJG LF2=-lm \
- BIND=BDJG PBIND='' DBIND=''
+ LNK=LDJG LF2=-lm \
+ BIND=BDJG
#========================================================================
#========================== EMX =========================================
@@ -158,16 +149,34 @@ emxbnd-debug:
#========================================================================
LMINGW32 = $(CC) $(LF) -o $@ $(GAWKOBJS) $(LF2)
-PLMINGW32 = $(CC) $(LF) -o $@ $(PGAWKOBJS) $(LF2)
-DLMINGW32 = $(CC) $(LF) -o $@ $(DGAWKOBJS) $(LF2)
# The following might work around command-line length limitations:
#LMINGW32 = $(CC) $(LF) -o $@ *.o $(LF2)
mingw32:
$(MAK) all \
- CC=gcc O=.o CF="-O2 -gdwarf-2 -g3" OBJ=popen.o \
- LNK=LMINGW32 PLNK=PLMINGW32 DLNK=DLMINGW32 \
- LF="-gdwarf-2 -g3" LF2=-lmsvcp60 RSP=
+ CC=gcc O=.o CF="-D__USE_MINGW_ANSI_STDIO -O2 -gdwarf-2 -g3" \
+ OBJ=popen.o LNK=LMINGW32 LF="-gdwarf-2 -g3" LF2=-lmsvcp60 RSP=
+
+mingw32-readline:
+ $(MAK) all \
+ CC=gcc O=.o \
+ CF="-D__USE_MINGW_ANSI_STDIO -DHAVE_LIBREADLINE -O2 -gdwarf-2 -g3" \
+ OBJ=popen.o LNK=LMINGW32 LF="-gdwarf-2 -g3" \
+ LF2="-lreadline -lmsvcp60 -Wl,--enable-auto-import" RSP=
+
+mingw32-mpfr:
+ $(MAK) all \
+ CC=gcc O=.o \
+ CF="-D__USE_MINGW_ANSI_STDIO -DHAVE_MPFR -O2 -gdwarf-2 -g3" \
+ OBJ=popen.o LNK=LMINGW32 LF="-gdwarf-2 -g3" \
+ LF2="-lmpfr -lgmp -lmsvcp60 -Wl,--enable-auto-import" RSP=
+
+mingw32-readline-mpfr:
+ $(MAK) all \
+ CC=gcc O=.o \
+ CF="-D__USE_MINGW_ANSI_STDIO -DHAVE_LIBREADLINE -DHAVE_MPFR -O2 -gdwarf-2 -g3" \
+ OBJ=popen.o LNK=LMINGW32 LF="-gdwarf-2 -g3" \
+ LF2="-lmpfr -lgmp -lreadline -lmsvcp60 -Wl,--enable-auto-import" RSP=
mingw32-readline:
$(MAK) all \
@@ -181,18 +190,13 @@ BIND = EMPTY
PBIND = EMPTY
EMPTY=
-# bitwise operations (-DBITOPS) and non-decimal input data (-DNONDECDATA) are
-# undocumented in 3.0.3. They may be enabled in config.h, or added to CFLAGS.
-CFLAGS = $(CF) -DGAWK -I. -DHAVE_CONFIG_H $(DYN_FLAGS)
+CFLAGS = $(CF) -DGAWK -I. -DHAVE_CONFIG_H
# object files
AWKOBJS1 = array$O builtin$O eval$O field$O floatcomp$O gawkmisc$O io$O main$O
-AWKOBJS2 = ext$O msg$O node$O profile$O re$O replace$O version$O $(DYN_OBJ)
-PAWKOBJS1 = array$O builtin$O eval_p$O field$O floatcomp$O gawkmisc$O io$O main$O
-PAWKOBJS2 = ext$O msg$O node$O profile_p$O re$O replace$O version$O $(DYN_OBJ)
-DAWKOBJS1 = array$O builtin$O debug$O eval_d$O field$O floatcomp$O gawkmisc$O io$O main$O
-DAWKOBJS2 = ext$O msg$O node$O profile$O re$O replace$O version$O command$O $(DYN_OBJ)
-AWKOBJS = $(AWKOBJS1) $(AWKOBJS2)
+AWKOBJS2 = ext$O msg$O node$O profile$O re$O replace$O version$O symbol$O
+AWKOBJS3 = debug$O cint_array$O int_array$O mpfr$O str_array$O command$O
+AWKOBJS = $(AWKOBJS1) $(AWKOBJS2) $(AWKOBJS3)
ALLOBJS = $(AWKOBJS) awkgram$O getid$O $(OBJ)
@@ -201,8 +205,6 @@ ALLOBJS = $(AWKOBJS) awkgram$O getid$O $(OBJ)
LIBOBJS= getopt$O getopt1$O dfa$O regex$O random$O
GAWKOBJS = $(ALLOBJS) $(LIBOBJS)
-PGAWKOBJS = $(PAWKOBJS1) $(PAWKOBJS2) $(LIBOBJS) awkgram$O getid$O $(OBJ)
-DGAWKOBJS = $(DAWKOBJS1) $(DAWKOBJS2) $(LIBOBJS) awkgram$O getid$O $(OBJ)
# clear out suffixes list
# .SUFFIXES:
@@ -212,52 +214,34 @@ DGAWKOBJS = $(DAWKOBJS1) $(DAWKOBJS2) $(LIBOBJS) awkgram$O getid$O $(OBJ)
$(CC) -c $(CFLAGS) $<
# rules to build gawk
-all : gawk.exe pgawk.exe dgawk.exe
+all : gawk.exe
gawk.exe:: $(GAWKOBJS) $(RSP)
$(DO_LNK)
$(DO_BIND)
-pgawk.exe:: $(PGAWKOBJS) $(PRSP)
- $(DO_PLNK)
- $(DO_PBIND)
-
-dgawk.exe:: $(DGAWKOBJS) $(DRSP)
- $(DO_DLNK)
- $(DO_DBIND)
-
$(RSPFILE) : $(GAWKOBJS)
echo $(AWKOBJS1)$P > $@
echo $(AWKOBJS2)$P >> $@
echo awkgram$O getid$O $(OBJ) $(LIBOBJS)$P >> $@
-$(PRSPFILE) : $(PGAWKOBJS)
- echo $(PAWKOBJS1)$P > $@
- echo $(PAWKOBJS2)$P >> $@
- echo awkgram$O getid$O $(OBJ) $(LIBOBJS)$P >> $@
-
-$(DRSPFILE) : $(DGAWKOBJS)
- echo $(DAWKOBJS1)$P > $@
- echo $(DAWKOBJS2)$P >> $@
- echo awkgram$O getid$O $(OBJ) $(LIBOBJS)$P >> $@
-
# Notes to dependencies:
# 1. The dependency on getopt.h is because unistd.h includes it,
# and we have -I. on the compiler command line. unistd.h is
# included by awk.h.
# 2. custom.h is not mentioned because pc ports don't use it.
-$(ALLOBJS) $(LIBOBJS) eval_p$O profile_p$O eval_d$O debug$O command$O: \
+$(ALLOBJS) $(LIBOBJS): \
awk.h regex.h config.h gettext.h mbsupport.h protos.h dfa.h getopt.h
builtin$O: floatmagic.h random.h popen.h
-random$O: floatmagic.h random.h
+random$O: random.h
-debug$O: floatmagic.h
+node$O: floatmagic.h
command$O debug$O: cmd.h
-dfa$O: xalloc.h
+dfa$O: xalloc.h
gawkmisc$O: pc/gawkmisc.pc
@@ -267,9 +251,7 @@ io$O: popen.h
regex$O: regcomp.c regexec.c regex_internal.h
-eval_p$O: eval.c
-
-profile_p$O: profile.c
+eval$O: interpret.h
# A bug in ndmake requires the following rule
awkgram$O: awk.h awkgram.c
@@ -300,7 +282,7 @@ install2:
gawk -v prefix=$(prefix) -f install.awk
clean:
- rm -rf gawk pgawk dgawk *.exe gawk.map *.o *.obj core a.out $(RSPFILE) $(PRSPFILE) $(DRSPFILE) $(DYN_EXP)
+ -rm -rf gawk *.exe gawk.map *.o *.obj core a.out $(RSPFILE) $(PRSPFILE) $(DRSPFILE) $(DYN_EXP)
# cd doc && $(MAKE) clean
# cd test && $(MAKE) clean
# cd awklib && $(MAKE) clean
diff --git a/pc/Makefile.tst b/pc/Makefile.tst
index c10430a7..ab566531 100644
--- a/pc/Makefile.tst
+++ b/pc/Makefile.tst
@@ -67,7 +67,7 @@ AWK2 = '..\gawk.exe'
AWKPROG = ../gawk.exe
# Define PGAWK
-PGAWK = ../pgawk.exe
+PGAWK = ../gawk.exe -p
# Set your cmp command here (you can use most versions of diff instead of cmp
# if you don't want to convert the .ok files to the DOS CR/LF format).
@@ -186,6 +186,7 @@ GAWK_EXT_TESTS = \
EXTRA_TESTS = inftest regtest
INET_TESTS = inetdayu inetdayt inetechu inetecht
MACHINE_TESTS = double1 double2 fmtspcl intformat
+MPFR_TESTS = mpfrnr mpfrrnd mpfrieee mpfrexprange mpfrsort mpfrbigint
LOCALE_CHARSET_TESTS = \
asort asorti fmttest fnarydel fnparydl lc_num1 mbfw1 \
mbprintf1 mbprintf2 mbprintf3 rebt8b2 rtlenmb sort1 sprintfc
@@ -233,6 +234,8 @@ inet: inetmesg $(INET_TESTS)
machine-tests: $(MACHINE_TESTS)
+mpfr-tests: $(MPFR_TESTS)
+
msg::
@echo ""
@echo "Any output from $(CMP) is bad news, although some differences"
@@ -360,7 +363,7 @@ argtest::
badargs::
@echo $@
- @-$(AWK) -f 2>&1 | grep -v patchlevel >_$@
+ @-$(AWK) -f 2>&1 | GREP_OPTIONS='' grep -v patchlevel >_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nonl::
@@ -800,6 +803,36 @@ exit:
@-AWK="$(AWKPROG)" $(srcdir)/$@.sh > _$@ 2>&1
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+mpfrieee:
+ @echo mpfrieee
+ @$(AWK) -M -vPREC=double -f $(srcdir)/$@.awk > _$@ 2>&1
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
+mpfrexprange:
+ @echo mpfrexprange
+ @$(AWK) -M -vPREC=53 -f $(srcdir)/$@.awk > _$@ 2>&1
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
+mpfrrnd:
+ @echo mpfrrnd
+ @$(AWK) -M -vPREC=53 -f $(srcdir)/$@.awk > _$@ 2>&1
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
+mpfrnr:
+ @echo mpfrnr
+ @$(AWK) -M -vPREC=113 -f $(srcdir)/$@.awk $(srcdir)/$@.in > _$@
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
+mpfrsort:
+ @echo mpfrsort
+ @$(AWK) -M -vPREC=53 -f $(srcdir)/$@.awk > _$@ 2>&1
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
+mpfrbigint:
+ @echo mpfrbigint
+ @$(AWK) -M -f $(srcdir)/$@.awk > _$@ 2>&1
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
rri1::
@echo $@
@[ -z "$$GAWKLOCALE" ] && GAWKLOCALE=en_US.UTF-8; \
diff --git a/pc/config.h b/pc/config.h
index 6b50eefa..8b39a640 100644
--- a/pc/config.h
+++ b/pc/config.h
@@ -74,7 +74,7 @@
/* Define if you have the iconv() function and it works. */
#undef HAVE_ICONV
-/* Define if you have the 'intmax_t' type in <stdint.h> or <inttypes.h>. */
+/* Define to 1 if the system has the type `intmax_t'. */
#ifdef __MINGW32__
#define HAVE_INTMAX_T 1
#endif
@@ -84,12 +84,6 @@
#define HAVE_INTTYPES_H 1
#endif
-/* Define if <inttypes.h> exists, doesn't clash with <sys/types.h>, and
- declares uintmax_t. */
-#ifdef __MINGW32__
-#define HAVE_INTTYPES_H_WITH_UINTMAX 1
-#endif
-
/* Define to 1 if you have the `isascii' function. */
#ifdef __MINGW32__
#define HAVE_ISASCII 1
@@ -136,11 +130,6 @@
#define HAVE_LOCALE_H 1
#endif
-/* Define if you have the 'long long' type. */
-#ifdef __MINGW32__
-#define HAVE_LONG_LONG 1
-#endif
-
/* Define to 1 if the system has the type `long long int'. */
#undef HAVE_LONG_LONG_INT
@@ -188,6 +177,9 @@
/* we have the mktime function */
#define HAVE_MKTIME 1
+/* Define to 1 if you have fully functional mpfr and gmp libraries. */
+#undef HAVE_MPFR
+
/* Define to 1 if you have the <netdb.h> header file. */
#undef HAVE_NETDB_H
@@ -231,10 +223,6 @@
#define HAVE_STDINT_H 1
#endif
-/* Define if <stdint.h> exists, doesn't clash with <sys/types.h>, and declares
- uintmax_t. */
-#undef HAVE_STDINT_H_WITH_UINTMAX
-
/* Define to 1 if you have the <stdlib.h> header file. */
#ifdef __MINGW32__
#define HAVE_STDLIB_H 1
@@ -350,7 +338,7 @@
/* Define to 1 if you have the `tzset' function. */
#define HAVE_TZSET 1
-/* Define if you have the 'uintmax_t' type in <stdint.h> or <inttypes.h>. */
+/* Define to 1 if the system has the type `uintmax_t'. */
#if defined(DJGPP) || defined(__MINGW32__)
#define HAVE_UINTMAX_T 1
#ifdef DJGPP
@@ -363,9 +351,6 @@
#define HAVE_UNISTD_H 1
#endif
-/* Define if you have the 'unsigned long long' type. */
-#define HAVE_UNSIGNED_LONG_LONG 1
-
/* Define to 1 if the system has the type `unsigned long long int'. */
#undef HAVE_UNSIGNED_LONG_LONG_INT
@@ -425,7 +410,7 @@
#define PACKAGE_NAME "GNU Awk"
/* Define to the full name and version of this package. */
-#define PACKAGE_STRING "GNU Awk 4.0.1"
+#define PACKAGE_STRING "GNU Awk 4.0.70"
/* Define to the one symbol short name of this package. */
#define PACKAGE_TARNAME "gawk"
@@ -434,7 +419,7 @@
#define PACKAGE_URL "http://www.gnu.org/software/gawk/"
/* Define to the version of this package. */
-#define PACKAGE_VERSION "4.0.1"
+#define PACKAGE_VERSION "4.0.70"
/* Define to 1 if *printf supports %F format */
#undef PRINTF_HAS_F_FORMAT
@@ -496,7 +481,12 @@
/* Version number of package */
-#define VERSION "4.0.1"
+#define VERSION "4.0.70"
+
+/* Enable large inode numbers on Mac OS X 10.5. */
+#ifndef _DARWIN_USE_64_BIT_INODE
+# define _DARWIN_USE_64_BIT_INODE 1
+#endif
/* Number of bits in a file offset, on hosts where this is settable. */
#undef _FILE_OFFSET_BITS
@@ -519,6 +509,7 @@
# endif
#endif
+
/* Define to 2 if the system does not provide POSIX.1 features except with
this defined. */
#undef _POSIX_1_SOURCE
@@ -545,7 +536,8 @@
#endif
#endif
-/* Define to long or long long if <inttypes.h> and <stdint.h> don't define. */
+/* Define to the widest signed integer type if <stdint.h> and <inttypes.h> do
+ not define. */
#ifdef DJGPP
#define intmax_t long long
#endif
@@ -581,8 +573,8 @@
/* Define to `int' if <sys/types.h> doesn't define. */
#undef uid_t
-/* Define to unsigned long or unsigned long long if <stdint.h> and
- <inttypes.h> don't define. */
+/* Define to the widest unsigned integer type if <stdint.h> and <inttypes.h>
+ do not define. */
#ifdef DJGPP
#define uintmax_t unsigned long long
#endif
diff --git a/po/.gitignore b/po/.gitignore
new file mode 100644
index 00000000..2a1c0abe
--- /dev/null
+++ b/po/.gitignore
@@ -0,0 +1,4 @@
+# Ignore files that are created by a build.
+Makefile.in
+POTFILES
+
diff --git a/po/ast.gmo b/po/ast.gmo
deleted file mode 100644
index 7c2ac4e2..00000000
--- a/po/ast.gmo
+++ /dev/null
Binary files differ
diff --git a/po/ca.gmo b/po/ca.gmo
deleted file mode 100644
index 426541dc..00000000
--- a/po/ca.gmo
+++ /dev/null
Binary files differ
diff --git a/po/da.gmo b/po/da.gmo
index 29775fa1..7bd32a99 100644
--- a/po/da.gmo
+++ b/po/da.gmo
Binary files differ
diff --git a/po/da.po b/po/da.po
index e7b3da8f..b52fdbcb 100644
--- a/po/da.po
+++ b/po/da.po
@@ -10,7 +10,7 @@ msgid ""
msgstr ""
"Project-Id-Version: gawk 4.0.0h\n"
"Report-Msgid-Bugs-To: arnold@skeeve.com\n"
-"POT-Creation-Date: 2012-03-28 22:03+0200\n"
+"POT-Creation-Date: 2012-04-27 10:06+0300\n"
"PO-Revision-Date: 2012-02-06 10:37+0100\n"
"Last-Translator: Keld Simonsen <keld@keldix.com>\n"
"Language-Team: Danish <dansk@dansk-gruppen.dk>\n"
@@ -21,509 +21,466 @@ msgstr ""
"X-Generator: Lokalize 1.0\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
-#: array.c:140
+#: array.c:266
#, c-format
msgid "from %s"
msgstr "fra %s"
-#: array.c:248
+#: array.c:366
msgid "attempt to use a scalar value as array"
msgstr "forsøg på at bruge en skalar som array"
-#: array.c:251
-#, c-format
-msgid "attempt to use function `%s' as an array"
-msgstr "forsøg på at bruge funktionen '%s' som et array"
-
-#: array.c:254
+#: array.c:368
#, c-format
msgid "attempt to use scalar parameter `%s' as an array"
msgstr "forsøg på at bruge skalarparameteren '%s' som et array"
-#: array.c:257
+#: array.c:371
#, c-format
msgid "attempt to use scalar `%s' as an array"
msgstr "forsøg på at bruge skalar '%s' som et array"
-#: array.c:302 array.c:707 builtin.c:84 builtin.c:1385 builtin.c:1427
-#: builtin.c:1440 builtin.c:1859 builtin.c:1871 eval.c:1135 eval.c:1139
-#: eval.c:1495 eval.c:1812
+#: array.c:418 array.c:584 builtin.c:85 builtin.c:1560 builtin.c:1602
+#: builtin.c:1615 builtin.c:2041 builtin.c:2053 eval.c:1109 eval.c:1113
+#: eval.c:1508
#, c-format
msgid "attempt to use array `%s' in a scalar context"
msgstr "forsøg på at bruge array '%s' i skalarsammenhæng"
-#: array.c:513
-#, c-format
-msgid "reference to uninitialized element `%s[\"%.*s\"]'"
-msgstr "reference til ikke-initieret element '%s[\"%.*s\"]'"
-
-#: array.c:519
-#, c-format
-msgid "subscript of array `%s' is null string"
-msgstr "indeks i array '%s' er en tom streng"
-
-#: array.c:723
+#: array.c:591
#, c-format
msgid "delete: index `%s' not in array `%s'"
msgstr "delete: indeks '%s' findes ikke i array '%s'"
-#: array.c:734 eval.c:1865
+#: array.c:605
#, c-format
msgid "attempt to use scalar `%s[\"%.*s\"]' as an array"
msgstr "forsøg på at bruge skalaren '%s[\"%.*s\"]' som array"
-#: array.c:910
-#, c-format
-msgid "%s: empty (null)\n"
-msgstr "%s: tom (null)\n"
-
-#: array.c:915
-#, c-format
-msgid "%s: empty (zero)\n"
-msgstr "%s: tom (nul)\n"
-
-#: array.c:919
-#, c-format
-msgid "%s: table_size = %d, array_size = %d\n"
-msgstr "%s: tabelstørrelse = %d, arraystørrelse = %d\n"
-
-#: array.c:954
-#, c-format
-msgid "%s: is parameter\n"
-msgstr "%s: er parameter\n"
-
-#: array.c:958
-#, c-format
-msgid "%s: array_ref to %s\n"
-msgstr "%s: arrayreference til %s\n"
-
-#: array.c:963
-msgid "adump: argument not an array"
+#: array.c:784
+#, fuzzy
+msgid "adump: first argument not an array"
msgstr "adump: argument er ikke et array"
-#: array.c:1086
+#: array.c:823
msgid "asort: second argument not an array"
msgstr "asort: andet argument er ikke et array"
-#: array.c:1087
+#: array.c:824
msgid "asorti: second argument not an array"
msgstr "asorti: andet argument er ikke et array"
-#: array.c:1094
+#: array.c:831
msgid "asort: first argument not an array"
msgstr "asort: første argument er ikke et array"
-#: array.c:1095
+#: array.c:832
msgid "asorti: first argument not an array"
msgstr "asorti: første argument er ikke et array"
-#: array.c:1102
+#: array.c:839
msgid "asort: cannot use a subarray of first arg for second arg"
msgstr ""
"asort: kan ikke bruge et underarray af første argument for andet argument"
-#: array.c:1103
+#: array.c:840
msgid "asorti: cannot use a subarray of first arg for second arg"
msgstr ""
"asorti: kan ikke bruge et underarray af første argument for andet argument"
-#: array.c:1108
+#: array.c:845
msgid "asort: cannot use a subarray of second arg for first arg"
msgstr ""
"asort: kan ikke bruge et underarray af andet argument for første argument"
-#: array.c:1109
+#: array.c:846
msgid "asorti: cannot use a subarray of second arg for first arg"
msgstr ""
"asorti: kan ikke bruge et underarray af andet argument for første argument"
-#: array.c:1655
+#: array.c:1314
#, c-format
msgid "`%s' is invalid as a function name"
msgstr "'%s' er ugyldigt som funktionsnavn"
-#: array.c:1659
+#: array.c:1318
#, c-format
msgid "sort comparison function `%s' is not defined"
msgstr "funktionen for sorteringssammenligning '%s' er ikke defineret"
-#: awkgram.y:249
+#: awkgram.y:223
#, c-format
msgid "%s blocks must have an action part"
msgstr "%s-blokke skal have en handlingsdel"
-#: awkgram.y:252
+#: awkgram.y:226
msgid "each rule must have a pattern or an action part"
msgstr "hver regel skal have et mønster eller en handlingsdel"
-#: awkgram.y:323 awkgram.y:334
+#: awkgram.y:295 awkgram.y:306
msgid "old awk does not support multiple `BEGIN' or `END' rules"
msgstr ""
"gamle versioner af awk understøtter ikke flere 'BEGIN'- eller 'END'-regler"
-#: awkgram.y:371
+#: awkgram.y:343
#, c-format
msgid "`%s' is a built-in function, it cannot be redefined"
msgstr "'%s' er en indbygget funktion, den kan ikke omdefineres"
-#: awkgram.y:432
+#: awkgram.y:389
msgid "regexp constant `//' looks like a C++ comment, but is not"
msgstr "regexp-konstanten '//' ser ud som en C++-kommentar, men er det ikke"
-#: awkgram.y:436
+#: awkgram.y:393
#, c-format
msgid "regexp constant `/%s/' looks like a C comment, but is not"
msgstr "regexp-konstanten '/%s/' ser ud som en C-kommentar, men er det ikke"
-#: awkgram.y:528
+#: awkgram.y:485
#, c-format
msgid "duplicate case values in switch body: %s"
msgstr "dublet case-værdier i switch-krop %s"
-#: awkgram.y:549
+#: awkgram.y:506
msgid "duplicate `default' detected in switch body"
msgstr "dublet 'default' opdaget i switch-krop"
-#: awkgram.y:809
+#: awkgram.y:766
msgid "`break' is not allowed outside a loop or switch"
msgstr "'break' uden for en løkke eller switch er ikke tilladt"
-#: awkgram.y:818
+#: awkgram.y:775
msgid "`continue' is not allowed outside a loop"
msgstr "'continue' uden for en løkke er ikke tilladt"
-#: awkgram.y:828
+#: awkgram.y:785
#, c-format
msgid "`next' used in %s action"
msgstr "'next' brugt i %s-handling"
-#: awkgram.y:836
+#: awkgram.y:793
msgid "`nextfile' is a gawk extension"
msgstr "'nextfile' er en gawk-udvidelse"
-#: awkgram.y:841
+#: awkgram.y:798
#, c-format
msgid "`nextfile' used in %s action"
msgstr "'nextfile' brugt i %s-handling"
-#: awkgram.y:865
+#: awkgram.y:822
msgid "`return' used outside function context"
msgstr "'return' brugt uden for funktion"
-#: awkgram.y:925
+#: awkgram.y:896
msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'"
msgstr ""
"alenestående 'print' i BEGIN eller END-regel skulle muligvis være 'print "
"\"\"'"
-#: awkgram.y:995 awkgram.y:999 awkgram.y:1023
+#: awkgram.y:966 awkgram.y:970 awkgram.y:994
msgid "`delete array' is a gawk extension"
msgstr "'delete array' er en gawk-udvidelse"
-#: awkgram.y:1019
+#: awkgram.y:990
msgid "`delete(array)' is a non-portable tawk extension"
msgstr "'delete array' er en ikke-portabel udvidelse fra tawk"
-#: awkgram.y:1135
+#: awkgram.y:1108
msgid "multistage two-way pipelines don't work"
msgstr "flertrins dobbeltrettede datakanaler fungerer ikke"
-#: awkgram.y:1238
+#: awkgram.y:1211
msgid "regular expression on right of assignment"
msgstr "regulært udtryk i højreleddet af en tildeling"
-#: awkgram.y:1249
+#: awkgram.y:1222
msgid "regular expression on left of `~' or `!~' operator"
msgstr "regulært udtryk på venstre side af en '~'- eller '!~'-operator"
-#: awkgram.y:1265 awkgram.y:1419
+#: awkgram.y:1238 awkgram.y:1389
msgid "old awk does not support the keyword `in' except after `for'"
msgstr ""
"gamle versioner af awk understøtter ikke nøgleordet 'in' undtagen efter 'for'"
-#: awkgram.y:1275
+#: awkgram.y:1248
msgid "regular expression on right of comparison"
msgstr "regulært udtryk i højreleddet af en sammenligning"
-#: awkgram.y:1394
+#: awkgram.y:1364
#, c-format
msgid "`getline var' invalid inside `%s' rule"
msgstr "'getline var' ugyldig inden i '%s' regel"
-#: awkgram.y:1397 eval.c:2504
+#: awkgram.y:1367
#, c-format
msgid "`getline' invalid inside `%s' rule"
msgstr "'getline' ugyldig inden i '%s' regel"
-#: awkgram.y:1402
+#: awkgram.y:1372
msgid "non-redirected `getline' undefined inside END action"
msgstr "ikke-omdirigeret 'getline' udefineret inden i END-handling"
-#: awkgram.y:1421
+#: awkgram.y:1391
msgid "old awk does not support multidimensional arrays"
msgstr "gamle versioner af awk understøtter ikke flerdimensionale array"
-#: awkgram.y:1517
+#: awkgram.y:1488
msgid "call of `length' without parentheses is not portable"
msgstr "kald af 'length' uden parenteser er ikke portabelt"
-#: awkgram.y:1580
+#: awkgram.y:1554
msgid "indirect function calls are a gawk extension"
msgstr "indirekte funktionskald er en gawk-udvidelse"
-#: awkgram.y:1593
+#: awkgram.y:1567
#, c-format
msgid "can not use special variable `%s' for indirect function call"
msgstr "kan ikke bruge specialvariabel '%s' til indirekte funktionskald"
-#: awkgram.y:1671
+#: awkgram.y:1645
msgid "invalid subscript expression"
msgstr "ugyldigt indeksudtryk"
-#: awkgram.y:1711
-msgid "use of non-array as array"
-msgstr "brug af ikke-array som array"
-
-#: awkgram.y:1975 awkgram.y:1995 msg.c:98
+#: awkgram.y:1966 awkgram.y:1986 msg.c:112
msgid "warning: "
msgstr "advarsel: "
-#: awkgram.y:1993 msg.c:130
+#: awkgram.y:1984 msg.c:144
msgid "fatal: "
msgstr "fatal: "
-#: awkgram.y:2043
+#: awkgram.y:2034
msgid "unexpected newline or end of string"
msgstr "uventet nylinjetegn eller strengafslutning"
-#: awkgram.y:2300 awkgram.y:2358 awkgram.y:2542
+#: awkgram.y:2299 awkgram.y:2357 awkgram.y:2545
#, c-format
msgid "can't open source file `%s' for reading (%s)"
msgstr "kan ikke åbne kildefilen '%s' for læsning (%s)"
-#: awkgram.y:2301 awkgram.y:2359 builtin.c:122
+#: awkgram.y:2300 awkgram.y:2358 builtin.c:124
msgid "reason unknown"
msgstr "ukendt årsag"
-#: awkgram.y:2317
+#: awkgram.y:2316
#, c-format
msgid "already included source file `%s'"
msgstr "allerede inkluderet kildefil '%s'"
-#: awkgram.y:2343
+#: awkgram.y:2342
msgid "@include is a gawk extension"
msgstr "@include er en gawk-udvidelse"
-#: awkgram.y:2349
+#: awkgram.y:2348
msgid "empty filename after @include"
msgstr "tomt filnavn efter @include"
-#: awkgram.y:2494
+#: awkgram.y:2497
msgid "empty program text on command line"
msgstr "tom programtekst på kommandolinjen"
-#: awkgram.y:2609
+#: awkgram.y:2612
#, c-format
msgid "can't read sourcefile `%s' (%s)"
msgstr "kan ikke læse kildefilen '%s' (%s)"
-#: awkgram.y:2620
+#: awkgram.y:2623
#, c-format
msgid "source file `%s' is empty"
msgstr "kildefilen '%s' er tom"
-#: awkgram.y:2797
+#: awkgram.y:2800
msgid "source file does not end in newline"
msgstr "kildefilen slutter ikke med en ny linje"
-#: awkgram.y:2900
+#: awkgram.y:2905
msgid "unterminated regexp ends with `\\' at end of file"
msgstr "uafsluttet regulært udtryk slutter med '\\' i slutningen af filen"
-#: awkgram.y:2924
+#: awkgram.y:2929
#, c-format
msgid "%s: %d: tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr "%s: %d: regex-ændringstegn '/.../%c' fra tawk virker ikke i gawk"
-#: awkgram.y:2928
+#: awkgram.y:2933
#, c-format
msgid "tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr "regex-ændringstegn '/.../%c' fra tawk virker ikke i gawk"
-#: awkgram.y:2935
+#: awkgram.y:2940
msgid "unterminated regexp"
msgstr "uafsluttet regulært udtryk"
-#: awkgram.y:2939
+#: awkgram.y:2944
msgid "unterminated regexp at end of file"
msgstr "uafsluttet regulært udtryk i slutningen af filen"
-#: awkgram.y:2998
+#: awkgram.y:3003
msgid "use of `\\ #...' line continuation is not portable"
msgstr "brug af '\\ #...' for linjefortsættelse er ikke portabelt"
-#: awkgram.y:3014
+#: awkgram.y:3019
msgid "backslash not last character on line"
msgstr "sidste tegn på linjen er ikke en omvendt skråstreg"
-#: awkgram.y:3075
+#: awkgram.y:3080
msgid "POSIX does not allow operator `**='"
msgstr "POSIX tillader ikke operatoren '**='"
-#: awkgram.y:3077
+#: awkgram.y:3082
msgid "old awk does not support operator `**='"
msgstr "gamle versioner af awk understøtter ikke operatoren '**='"
-#: awkgram.y:3086
+#: awkgram.y:3091
msgid "POSIX does not allow operator `**'"
msgstr "POSIX tillader ikke operatoren '**'"
-#: awkgram.y:3088
+#: awkgram.y:3093
msgid "old awk does not support operator `**'"
msgstr "gamle versioner af awk understøtter ikke operatoren '**'"
-#: awkgram.y:3123
+#: awkgram.y:3128
msgid "operator `^=' is not supported in old awk"
msgstr "operatoren '^=' understøttes ikke i gamle versioner af awk"
-#: awkgram.y:3131
+#: awkgram.y:3136
msgid "operator `^' is not supported in old awk"
msgstr "operatoren '^' understøttes ikke i gamle versioner af awk"
-#: awkgram.y:3224 awkgram.y:3240
+#: awkgram.y:3229 awkgram.y:3245
msgid "unterminated string"
msgstr "uafsluttet streng"
-#: awkgram.y:3436
+#: awkgram.y:3466
#, c-format
msgid "invalid char '%c' in expression"
msgstr "ugyldigt tegn '%c' i udtryk"
-#: awkgram.y:3483
+#: awkgram.y:3513
#, c-format
msgid "`%s' is a gawk extension"
msgstr "'%s' er en gawk-udvidelse"
-#: awkgram.y:3488
+#: awkgram.y:3518
#, c-format
msgid "`%s' is a Bell Labs extension"
msgstr "'%s' er en Bell Labs-udvidelse"
-#: awkgram.y:3493
+#: awkgram.y:3523
#, c-format
msgid "POSIX does not allow `%s'"
msgstr "POSIX tillader ikke '%s'"
-#: awkgram.y:3501
+#: awkgram.y:3531
#, c-format
msgid "`%s' is not supported in old awk"
msgstr "'%s' understøttes ikke i gamle versioner af awk"
-#: awkgram.y:3568
+#: awkgram.y:3598
msgid "`goto' considered harmful!\n"
msgstr "'goto' anses for skadelig!\n"
-#: awkgram.y:3619
+#: awkgram.y:3632
#, c-format
msgid "%d is invalid as number of arguments for %s"
msgstr "%d er et ugyldigt antal argumenter for %s"
-#: awkgram.y:3654
+#: awkgram.y:3667
#, c-format
msgid "%s: string literal as last arg of substitute has no effect"
msgstr ""
"%s: bogstavelig streng som sidste argument til erstatning har ingen effekt"
-#: awkgram.y:3659
+#: awkgram.y:3672
#, c-format
msgid "%s third parameter is not a changeable object"
msgstr "%s: tredje argument er ikke et ændringsbart objekt"
-#: awkgram.y:3732 awkgram.y:3735
+#: awkgram.y:3751 awkgram.y:3754
msgid "match: third argument is a gawk extension"
msgstr "match: tredje argument er en gawk-udvidelse"
-#: awkgram.y:3789 awkgram.y:3792
+#: awkgram.y:3808 awkgram.y:3811
msgid "close: second argument is a gawk extension"
msgstr "close: andet argument er en gawk-udvidelse"
-#: awkgram.y:3804
+#: awkgram.y:3823
msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore"
msgstr ""
"brug af dcgettext(_\"...\") er forkert: fjern det indledende "
"understregningstegn"
-#: awkgram.y:3819
+#: awkgram.y:3838
msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore"
msgstr ""
"brug af dcgettext(_\"...\") er forkert: fjern det indledende "
"understregningstegn"
-#: awkgram.y:3911
-#, c-format
-msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
-msgstr "funktionen '%s': parameter %d, '%s', er samme som parameter %d"
-
-#: awkgram.y:3953
+#: awkgram.y:3904
#, c-format
msgid "function `%s': parameter `%s' shadows global variable"
msgstr "funktionen '%s': parameteren '%s' overskygger en global variabel"
-#: awkgram.y:4111
+#: awkgram.y:3961
#, c-format
msgid "could not open `%s' for writing (%s)"
msgstr "kunne ikke åbne '%s' for skrivning (%s)"
-#: awkgram.y:4112
+#: awkgram.y:3962
msgid "sending variable list to standard error"
msgstr "sender variabelliste til standard fejl"
-#: awkgram.y:4118
+#: awkgram.y:3970
#, c-format
msgid "%s: close failed (%s)"
msgstr "%s: lukning mislykkedes (%s)"
-#: awkgram.y:4170
+#: awkgram.y:3995
msgid "shadow_funcs() called twice!"
msgstr "shadow_funcs() kaldt to gange!"
-#: awkgram.y:4176
+#: awkgram.y:4003
msgid "there were shadowed variables."
msgstr "der var skyggede variable."
-#: awkgram.y:4206
+#: awkgram.y:4074
+#, c-format
+msgid "function name `%s' previously defined"
+msgstr "funktionsnavnet '%s' er allerede defineret"
+
+#: awkgram.y:4120
#, c-format
msgid "function `%s': can't use function name as parameter name"
msgstr "funktionen '%s': kan ikke bruge funktionsnavn som parameternavn"
-#: awkgram.y:4210
+#: awkgram.y:4123
#, c-format
msgid "function `%s': can't use special variable `%s' as a function parameter"
msgstr ""
"funktionen '%s': kan ikke bruge specialvariabel '%s' som en "
"funktionsparameter"
-#: awkgram.y:4226
+#: awkgram.y:4131
#, c-format
-msgid "function name `%s' previously defined"
-msgstr "funktionsnavnet '%s' er allerede defineret"
+msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
+msgstr "funktionen '%s': parameter %d, '%s', er samme som parameter %d"
-#: awkgram.y:4394 awkgram.y:4400
+#: awkgram.y:4210 awkgram.y:4216
#, c-format
msgid "function `%s' called but never defined"
msgstr "funktionen '%s' kaldt, men aldrig defineret"
-#: awkgram.y:4403
+#: awkgram.y:4219
#, c-format
msgid "function `%s' defined but never called directly"
msgstr "funktionen '%s' defineret, men aldrig kaldt direkte"
-#: awkgram.y:4435
+#: awkgram.y:4251
#, c-format
msgid "regexp constant for parameter #%d yields boolean value"
msgstr "konstant regulært udtryk for parameter %d giver en boolesk værdi"
-#: awkgram.y:4544
+#: awkgram.y:4297
#, c-format
msgid ""
"function `%s' called with space between name and `(',\n"
@@ -532,227 +489,227 @@ msgstr ""
"funktionen '%s' kaldt med blanktegn mellem navnet og '(',\n"
"eller brugt som en variabel eller et array"
-#: awkgram.y:4791 eval.c:2056
+#: awkgram.y:4505
msgid "division by zero attempted"
msgstr "forsøgte at dividere med nul"
-#: awkgram.y:4800 eval.c:2072
+#: awkgram.y:4514
#, c-format
msgid "division by zero attempted in `%%'"
msgstr "forsøgte at dividere med nul i '%%'"
-#: builtin.c:120
+#: builtin.c:122
#, c-format
msgid "%s to \"%s\" failed (%s)"
msgstr "%s til '%s' mislykkedes (%s)"
-#: builtin.c:121
+#: builtin.c:123
msgid "standard output"
msgstr "standard ud"
-#: builtin.c:135
+#: builtin.c:137
msgid "exp: received non-numeric argument"
msgstr "exp: fik et ikke-numerisk argument"
-#: builtin.c:141
+#: builtin.c:143
#, c-format
msgid "exp: argument %g is out of range"
msgstr "exp: argumentet %g er uden for det tilladte område"
-#: builtin.c:200
+#: builtin.c:202
#, c-format
msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing"
msgstr ""
"fflush: kan ikke rense: datakanalen '%s' åbnet for læsning, ikke skrivning"
-#: builtin.c:203
+#: builtin.c:205
#, c-format
msgid "fflush: cannot flush: file `%s' opened for reading, not writing"
msgstr "fflush: kan ikke rense: filen '%s' åbnet for læsning, ikke skrivning"
-#: builtin.c:215
+#: builtin.c:217
#, c-format
msgid "fflush: `%s' is not an open file, pipe or co-process"
msgstr "fflush: '%s' er ikke en åben fil, datakanal eller ko-proces"
-#: builtin.c:333
+#: builtin.c:335
msgid "index: received non-string first argument"
msgstr "indeks: første argument er ikke en streng"
-#: builtin.c:335
+#: builtin.c:337
msgid "index: received non-string second argument"
msgstr "indeks: andet argument er ikke en streng"
-#: builtin.c:457
+#: builtin.c:461
msgid "int: received non-numeric argument"
msgstr "int: fik et ikke-numerisk argument"
-#: builtin.c:493
+#: builtin.c:497
msgid "length: received array argument"
msgstr "length: fik et array-argument"
-#: builtin.c:496
+#: builtin.c:500
msgid "`length(array)' is a gawk extension"
msgstr "'length(array)' er en gawk-udvidelse"
-#: builtin.c:504
+#: builtin.c:508
msgid "length: received non-string argument"
msgstr "length: fik et argument som ikke er en streng"
-#: builtin.c:535
+#: builtin.c:539
msgid "log: received non-numeric argument"
msgstr "log: fik et ikke-numerisk argument"
-#: builtin.c:538
+#: builtin.c:542
#, c-format
msgid "log: received negative argument %g"
msgstr "log: fik et negativt argument %g"
-#: builtin.c:694 builtin.c:699
+#: builtin.c:740 builtin.c:745
msgid "fatal: must use `count$' on all formats or none"
msgstr "fatal: skal bruge 'count$' på alle formater eller ikke nogen"
-#: builtin.c:762
+#: builtin.c:815
#, c-format
msgid "field width is ignored for `%%' specifier"
msgstr "feltbredde ignoreret for '%%'-angivelse"
-#: builtin.c:764
+#: builtin.c:817
#, c-format
msgid "precision is ignored for `%%' specifier"
msgstr "præcision ignoreret for '%%'-angivelse"
-#: builtin.c:766
+#: builtin.c:819
#, c-format
msgid "field width and precision are ignored for `%%' specifier"
msgstr "feltbredde og præcision ignoreret for '%%'-angivelse"
-#: builtin.c:817
+#: builtin.c:870
msgid "fatal: `$' is not permitted in awk formats"
msgstr "fatal: '$' tillades ikke i awk-formater"
-#: builtin.c:826
+#: builtin.c:879
msgid "fatal: arg count with `$' must be > 0"
msgstr "fatal: argumentantallet med '$' skal være > 0"
-#: builtin.c:830
+#: builtin.c:883
#, c-format
msgid "fatal: arg count %ld greater than total number of supplied arguments"
msgstr "fatal: argumentantallet %ld er større end antal givne argumenter"
-#: builtin.c:834
+#: builtin.c:887
msgid "fatal: `$' not permitted after period in format"
msgstr "fatal: '$' tillades ikke efter et punktum i formatet"
-#: builtin.c:850
+#: builtin.c:903
msgid "fatal: no `$' supplied for positional field width or precision"
msgstr ""
"fatal: intet '$' angivet for bredde eller præcision af positionsangivet felt"
-#: builtin.c:921
+#: builtin.c:975
msgid "`l' is meaningless in awk formats; ignored"
msgstr "'l' er meningsløst i awk-formater, ignoreret"
-#: builtin.c:925
+#: builtin.c:979
msgid "fatal: `l' is not permitted in POSIX awk formats"
msgstr "fatal: 'l' tillades ikke i POSIX awk-formater"
-#: builtin.c:938
+#: builtin.c:992
msgid "`L' is meaningless in awk formats; ignored"
msgstr "'L' er meningsløst i awk-formater, ignoreret"
-#: builtin.c:942
+#: builtin.c:996
msgid "fatal: `L' is not permitted in POSIX awk formats"
msgstr "fatal: 'L' tillades ikke i POSIX awk-formater"
-#: builtin.c:955
+#: builtin.c:1009
msgid "`h' is meaningless in awk formats; ignored"
msgstr "'h' er meningsløst i awk-formater, ignoreret"
-#: builtin.c:959
+#: builtin.c:1013
msgid "fatal: `h' is not permitted in POSIX awk formats"
msgstr "fatal: 'h' tillades ikke i POSIX awk-formater"
-#: builtin.c:1272
+#: builtin.c:1408
#, c-format
msgid "[s]printf: value %g is out of range for `%%%c' format"
msgstr "[s]printf: værdi %g er uden for område for '%%%c'-format"
-#: builtin.c:1332
+#: builtin.c:1506
#, c-format
msgid "ignoring unknown format specifier character `%c': no argument converted"
msgstr ""
"ignorerer ukendt formatspecificeringstegn '%c': intet argument konverteret"
-#: builtin.c:1337
+#: builtin.c:1511
msgid "fatal: not enough arguments to satisfy format string"
msgstr "fatal: for få argumenter til formatstrengen"
-#: builtin.c:1339
+#: builtin.c:1513
msgid "^ ran out for this one"
msgstr "^ sluttede her"
-#: builtin.c:1346
+#: builtin.c:1520
msgid "[s]printf: format specifier does not have control letter"
msgstr "[s]printf: formatspecifikation har intet kommandobogstav"
-#: builtin.c:1349
+#: builtin.c:1523
msgid "too many arguments supplied for format string"
msgstr "for mange argumenter til formatstrengen"
-#: builtin.c:1423 builtin.c:1434
+#: builtin.c:1598 builtin.c:1609
msgid "printf: no arguments"
msgstr "printf: ingen argumenter"
-#: builtin.c:1475
+#: builtin.c:1650
msgid "sqrt: received non-numeric argument"
msgstr "sqrt: fik ikke-numerisk argument"
-#: builtin.c:1479
+#: builtin.c:1654
#, c-format
msgid "sqrt: called with negative argument %g"
msgstr "sqrt: kaldt med negativt argument %g"
-#: builtin.c:1503
+#: builtin.c:1685
#, c-format
msgid "substr: length %g is not >= 1"
msgstr "substr: længden %g er ikke >= 1"
-#: builtin.c:1505
+#: builtin.c:1687
#, c-format
msgid "substr: length %g is not >= 0"
msgstr "substr: længden %g er ikke >= 0"
-#: builtin.c:1512
+#: builtin.c:1694
#, c-format
msgid "substr: non-integer length %g will be truncated"
msgstr "substr: længden %g som ikke er et heltal vil blive trunkeret"
-#: builtin.c:1517
+#: builtin.c:1699
#, c-format
msgid "substr: length %g too big for string indexing, truncating to %g"
msgstr "substr: længden %g for stor til strengindeksering, trunkerer til %g"
-#: builtin.c:1529
+#: builtin.c:1711
#, c-format
msgid "substr: start index %g is invalid, using 1"
msgstr "substr: startindeks %g er ugyldigt, bruger 1"
-#: builtin.c:1534
+#: builtin.c:1716
#, c-format
msgid "substr: non-integer start index %g will be truncated"
msgstr "substr: startindeks %g som ikke er et heltal vil blive trunkeret"
-#: builtin.c:1559
+#: builtin.c:1741
msgid "substr: source string is zero length"
msgstr "substr: kildestrengen er tom"
-#: builtin.c:1575
+#: builtin.c:1757
#, c-format
msgid "substr: start index %g is past end of string"
msgstr "substr: startindeks %g er forbi slutningen på strengen"
-#: builtin.c:1583
+#: builtin.c:1765
#, c-format
msgid ""
"substr: length %g at start index %g exceeds length of first argument (%lu)"
@@ -760,229 +717,224 @@ msgstr ""
"substr: længden %g ved startindeks %g overskrider længden af første argument "
"(%lu)"
-#: builtin.c:1657
+#: builtin.c:1839
msgid "strftime: format value in PROCINFO[\"strftime\"] has numeric type"
msgstr "strftime: formatværdi i PROCINFO[\"strftime\"] har numerisk type"
-#: builtin.c:1680
+#: builtin.c:1862
msgid "strftime: received non-numeric second argument"
msgstr "strftime: fik et ikke-numerisk andet argument"
-#: builtin.c:1683
+#: builtin.c:1866
msgid "strftime: second argument less than 0 or too big for time_t"
msgstr "strftime: andet argument mindre end 0 eller for stort til time_t"
-#: builtin.c:1690
+#: builtin.c:1873
msgid "strftime: received non-string first argument"
msgstr "strftime: fik et første argument som ikke er en streng"
-#: builtin.c:1696
+#: builtin.c:1880
msgid "strftime: received empty format string"
msgstr "strftime: fik en tom formatstreng"
-#: builtin.c:1762
+#: builtin.c:1946
msgid "mktime: received non-string argument"
msgstr "mktime: fik et argument som ikke er en streng"
-#: builtin.c:1779
+#: builtin.c:1963
msgid "mktime: at least one of the values is out of the default range"
msgstr "mktime: mindst én af værdierne er udenfor standardområdet"
-#: builtin.c:1814
+#: builtin.c:1998
msgid "'system' function not allowed in sandbox mode"
msgstr "'system'-funktion ikke tilladt i sandkasse-tilstand"
-#: builtin.c:1819
+#: builtin.c:2003
msgid "system: received non-string argument"
msgstr "system: fik et argument som ikke er en streng"
-#: builtin.c:1874 eval.c:1159 eval.c:1790 eval.c:1803
-#, c-format
-msgid "reference to uninitialized variable `%s'"
-msgstr "reference til ikke-initieret variabel '%s'"
-
-#: builtin.c:1941
+#: builtin.c:2121
#, c-format
msgid "reference to uninitialized field `$%d'"
msgstr "reference til ikke-initieret felt '$%d'"
-#: builtin.c:2028
+#: builtin.c:2208
msgid "tolower: received non-string argument"
msgstr "tolower: fik et argument som ikke er en streng"
-#: builtin.c:2062
+#: builtin.c:2242
msgid "toupper: received non-string argument"
msgstr "toupper: fik et argument som ikke er en streng"
-#: builtin.c:2098
+#: builtin.c:2278
msgid "atan2: received non-numeric first argument"
msgstr "atan2: fik et ikke-numerisk første argument"
-#: builtin.c:2100
+#: builtin.c:2280
msgid "atan2: received non-numeric second argument"
msgstr "atan2: fik et ikke-numerisk andet argument"
-#: builtin.c:2119
+#: builtin.c:2299
msgid "sin: received non-numeric argument"
msgstr "sin: fik et ikke-numerisk argument"
-#: builtin.c:2135
+#: builtin.c:2315
msgid "cos: received non-numeric argument"
msgstr "cos: fik et ikke-numerisk argument"
-#: builtin.c:2188
+#: builtin.c:2368
msgid "srand: received non-numeric argument"
msgstr "srand: fik et ikke-numerisk argument"
-#: builtin.c:2219
+#: builtin.c:2399
msgid "match: third argument is not an array"
msgstr "match: tredje argument er ikke et array"
-#: builtin.c:2483
+#: builtin.c:2664
msgid "gensub: third argument of 0 treated as 1"
msgstr "gensub: 0 i tredje argument behandlet som 1"
-#: builtin.c:2776
+#: builtin.c:2957
msgid "lshift: received non-numeric first argument"
msgstr "lshift: fik et ikke-numerisk første argument"
-#: builtin.c:2778
+#: builtin.c:2959
msgid "lshift: received non-numeric second argument"
msgstr "lshift: fik et ikke-numerisk andet argument"
-#: builtin.c:2784
+#: builtin.c:2965
#, c-format
msgid "lshift(%lf, %lf): negative values will give strange results"
msgstr "lshift(%lf, %lf): negative værdier vil give mærkelige resultater"
-#: builtin.c:2786
+#: builtin.c:2967
#, c-format
msgid "lshift(%lf, %lf): fractional values will be truncated"
msgstr "lshift(%lf, %lf): kommatalsværdier vil blive trunkeret"
-#: builtin.c:2788
+#: builtin.c:2969
#, c-format
msgid "lshift(%lf, %lf): too large shift value will give strange results"
msgstr ""
"lshift(%lf, %lf): for store skifteværdier vil give mærkelige resultater"
-#: builtin.c:2813
+#: builtin.c:2994
msgid "rshift: received non-numeric first argument"
msgstr "rshift: fik et ikke-numerisk første argument"
-#: builtin.c:2815
+#: builtin.c:2996
msgid "rshift: received non-numeric second argument"
msgstr "rshift: fik et ikke-numerisk andet argument"
-#: builtin.c:2821
+#: builtin.c:3002
#, c-format
msgid "rshift(%lf, %lf): negative values will give strange results"
msgstr "rshift(%lf, %lf): negative værdier vil give mærkelige resultater"
-#: builtin.c:2823
+#: builtin.c:3004
#, c-format
msgid "rshift(%lf, %lf): fractional values will be truncated"
msgstr "rshift(%lf, %lf): kommatalsværdier vil blive trunkeret"
-#: builtin.c:2825
+#: builtin.c:3006
#, c-format
msgid "rshift(%lf, %lf): too large shift value will give strange results"
msgstr ""
"rshift(%lf, %lf): for store skifteværdier vil give mærkelige resultater"
-#: builtin.c:2850
+#: builtin.c:3031
msgid "and: received non-numeric first argument"
msgstr "and: fik et ikke-numerisk første argument"
-#: builtin.c:2852
+#: builtin.c:3033
msgid "and: received non-numeric second argument"
msgstr "and: fik et ikke-numerisk andet argument"
-#: builtin.c:2858
+#: builtin.c:3039
#, c-format
msgid "and(%lf, %lf): negative values will give strange results"
msgstr "and(%lf, %lf): negative værdier vil give mærkelige resultater"
-#: builtin.c:2860
+#: builtin.c:3041
#, c-format
msgid "and(%lf, %lf): fractional values will be truncated"
msgstr "and(%lf, %lf): kommatalsværdier vil blive trunkeret"
-#: builtin.c:2885
+#: builtin.c:3066
msgid "or: received non-numeric first argument"
msgstr "or: fik et ikke-numerisk første argument"
-#: builtin.c:2887
+#: builtin.c:3068
msgid "or: received non-numeric second argument"
msgstr "or: fik et ikke-numerisk andet argument"
-#: builtin.c:2893
+#: builtin.c:3074
#, c-format
msgid "or(%lf, %lf): negative values will give strange results"
msgstr "or(%lf, %lf): negative værdier vil give mærkelige resultater"
-#: builtin.c:2895
+#: builtin.c:3076
#, c-format
msgid "or(%lf, %lf): fractional values will be truncated"
msgstr "or(%lf, %lf): kommatalsværdier vil blive trunkeret"
-#: builtin.c:2923
+#: builtin.c:3102
msgid "xor: received non-numeric first argument"
msgstr "xor: fik et ikke-numerisk første argument"
-#: builtin.c:2925
+#: builtin.c:3104
msgid "xor: received non-numeric second argument"
msgstr "xor: fik et ikke-numerisk andet argument"
-#: builtin.c:2931
+#: builtin.c:3110
#, c-format
msgid "xor(%lf, %lf): negative values will give strange results"
msgstr "xor(%lf, %lf): negative værdier vil give mærkelige resultater"
-#: builtin.c:2933
+#: builtin.c:3112
#, c-format
msgid "xor(%lf, %lf): fractional values will be truncated"
msgstr "xor(%lf, %lf): kommatalsværdier vil blive trunkeret"
-#: builtin.c:2957 builtin.c:2963
+#: builtin.c:3136
msgid "compl: received non-numeric argument"
msgstr "compl: fik et ikke-numerisk argument"
-#: builtin.c:2965
+#: builtin.c:3142
#, c-format
msgid "compl(%lf): negative value will give strange results"
msgstr "compl(%lf): negative værdier vil give mærkelige resultater"
-#: builtin.c:2967
+#: builtin.c:3144
#, c-format
msgid "compl(%lf): fractional value will be truncated"
msgstr "compl(%lf): kommatalsværdier vil blive trunkeret"
-#: builtin.c:3136
+#: builtin.c:3313
#, c-format
msgid "dcgettext: `%s' is not a valid locale category"
msgstr "dcgettext: '%s' er ikke en gyldig lokalitetskategori"
-#: eval.c:412
+#: eval.c:395
#, c-format
msgid "unknown nodetype %d"
msgstr "ukendt nodetype %d"
-#: eval.c:423 eval.c:437
+#: eval.c:406 eval.c:420
#, c-format
msgid "unknown opcode %d"
msgstr "ukendt opkode %d"
-#: eval.c:434
+#: eval.c:417
#, c-format
msgid "opcode %s not an operator or keyword"
msgstr "opkode %s er ikke en operator eller et nøgleord"
-#: eval.c:488
+#: eval.c:472
msgid "buffer overflow in genflags2str"
msgstr "bufferoverløb i genflags2str"
-#: eval.c:698
+#: eval.c:675
#, c-format
msgid ""
"\n"
@@ -993,300 +945,244 @@ msgstr ""
"\t# Funktionskaldsstak:\n"
"\n"
-#: eval.c:725
+#: eval.c:704
msgid "`IGNORECASE' is a gawk extension"
msgstr "'IGNORECASE' er en gawk-udvidelse"
-#: eval.c:754
+#: eval.c:736
msgid "`BINMODE' is a gawk extension"
msgstr "'BINMODE' er en gawk-udvidelse"
-#: eval.c:812
+#: eval.c:793
#, c-format
msgid "BINMODE value `%s' is invalid, treated as 3"
msgstr "BINMODE værdi '%s' er ugyldig, behandles som 3"
-#: eval.c:902
+#: eval.c:885
#, c-format
msgid "bad `%sFMT' specification `%s'"
msgstr "forkert '%sFMT'-specifikation '%s'"
-#: eval.c:980
+#: eval.c:969
msgid "turning off `--lint' due to assignment to `LINT'"
msgstr "deaktiverer '--lint' på grund af en tildeling til 'LINT'"
-#: eval.c:1127 eval.c:1777
-#, c-format
-msgid "can't use function name `%s' as variable or array"
-msgstr "kan ikke bruge funktionsnavnet '%s' som variabel eller array"
-
-#: eval.c:1158 eval.c:1789 eval.c:1802
+#: eval.c:1132
#, c-format
msgid "reference to uninitialized argument `%s'"
msgstr "reference til ikke-initieret argument '%s'"
-#: eval.c:1177
+#: eval.c:1133
+#, c-format
+msgid "reference to uninitialized variable `%s'"
+msgstr "reference til ikke-initieret variabel '%s'"
+
+#: eval.c:1151
msgid "attempt to field reference from non-numeric value"
msgstr "forsøg på at referere til et felt fra ikke-numerisk værdi"
-#: eval.c:1179
+#: eval.c:1153
msgid "attempt to field reference from null string"
msgstr "forsøg på at referere til et felt fra tom streng"
-#: eval.c:1185
+#: eval.c:1161
#, c-format
msgid "attempt to access field %ld"
msgstr "forsøg på at få adgang til felt %ld"
-#: eval.c:1194
+#: eval.c:1170
#, c-format
msgid "reference to uninitialized field `$%ld'"
msgstr "reference til ikke-initieret felt '$%ld'"
-#: eval.c:1256
+#: eval.c:1257
#, c-format
msgid "function `%s' called with more arguments than declared"
msgstr "funktionen '%s' kaldt med flere argumenter end deklareret"
-#: eval.c:1437
+#: eval.c:1452
#, c-format
msgid "unwind_stack: unexpected type `%s'"
msgstr "unwind_stack: uventet type `%s'"
-#: eval.c:1532
+#: eval.c:1546
msgid "division by zero attempted in `/='"
msgstr "forsøgte at dividere med nul i '/='"
-#: eval.c:1539
+#: eval.c:1553
#, c-format
msgid "division by zero attempted in `%%='"
msgstr "forsøgte at dividere med nul i '%%='"
-#: eval.c:1876 eval.c:2122
-#, c-format
-msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
-msgstr "forsøg på at bruge array '%s[\"%.*s\"]' i skalarsammenhæng"
-
-#: eval.c:1907
-msgid "assignment used in conditional context"
-msgstr "tildeling brugt i sammenligningsammenhæng"
-
-#: eval.c:1911
-msgid "statement has no effect"
-msgstr "kommandoen har ingen effekt"
-
-#: eval.c:2343
-#, c-format
-msgid "for loop: array `%s' changed size from %ld to %ld during loop execution"
-msgstr ""
-"for-løkke: array '%s' ændrede størrelse fra %ld til %ld under udførelse af "
-"løkken"
-
-#: eval.c:2458
-#, c-format
-msgid "function called indirectly through `%s' does not exist"
-msgstr "funktion kaldt indirekte via '%s' eksisterer ikke"
-
-#: eval.c:2470
-#, c-format
-msgid "function `%s' not defined"
-msgstr "funktionen '%s' er ikke defineret"
-
-#: eval.c:2511
-#, c-format
-msgid "non-redirected `getline' invalid inside `%s' rule"
-msgstr "ikke-omdirigeret 'getline' ugyldig inden i '%s'-regel"
-
-#: eval.c:2600
-#, c-format
-msgid "error reading input file `%s': %s"
-msgstr "fejl ved læsning af inddatafilen '%s': %s"
-
-#: eval.c:2614
-#, c-format
-msgid "`nextfile' cannot be called from a `%s' rule"
-msgstr "'nextfile' kan ikke kaldes fra en '%s'-regel"
-
-#: eval.c:2661
-msgid "`exit' cannot be called in the current context"
-msgstr "'exit' kan ikke kaldes i den aktuelle kontekst"
-
-#: eval.c:2700
-#, c-format
-msgid "`next' cannot be called from a `%s' rule"
-msgstr "'next' kan ikke kaldes fra en '%s'-regel"
-
-#: eval.c:2766
-#, c-format
-msgid "Sorry, don't know how to interpret `%s'"
-msgstr "Véd desværre ikke hvordan '%s' skal fortolkes"
-
-#: ext.c:54
+#: ext.c:70
msgid "extensions are not allowed in sandbox mode"
msgstr "udvidelser er ikke tilladt i sandkasse-tilstand"
-#: ext.c:60 ext.c:65
+#: ext.c:73
msgid "`extension' is a gawk extension"
msgstr "'extension' er en gawk-udvidelse"
-#: ext.c:75
-#, c-format
-msgid "fatal: extension: cannot open `%s' (%s)\n"
+#: ext.c:80
+#, fuzzy, c-format
+msgid "extension: cannot open library `%s' (%s)\n"
msgstr "atalt: extension: kan ikke åbne '%s' (%s)\n"
-#: ext.c:84
-#, c-format
+#: ext.c:86
+#, fuzzy, c-format
msgid ""
-"fatal: extension: library `%s': does not define "
-"`plugin_is_GPL_compatible' (%s)\n"
+"extension: library `%s': does not define `plugin_is_GPL_compatible' (%s)\n"
msgstr ""
"fatalt: extension: bibliotek '%s': definer ikke "
"'plugin_is_GPL_compatible' (%s)\n"
-#: ext.c:93
-#, c-format
-msgid "fatal: extension: library `%s': cannot call function `%s' (%s)\n"
+#: ext.c:90
+#, fuzzy, c-format
+msgid "extension: library `%s': cannot call function `%s' (%s)\n"
msgstr ""
"fatalt: extension: bibliotek '%s': kan ikke kalde funktionen '%s' (%s)\n"
-#: ext.c:127
+#: ext.c:118
msgid "extension: missing function name"
msgstr "extension: mangler funktionsnavn"
-#: ext.c:132
+#: ext.c:123
#, c-format
msgid "extension: illegal character `%c' in function name `%s'"
msgstr "extension: ugyldigt tegn '%c' i funktionsnavn '%s'"
-#: ext.c:141
+#: ext.c:131
#, c-format
msgid "extension: can't redefine function `%s'"
msgstr "extension: kan ikke omdefinere funktion '%s'"
-#: ext.c:145
+#: ext.c:135
#, c-format
msgid "extension: function `%s' already defined"
msgstr "extension: funktionen '%s' er allerede defineret"
-#: ext.c:150
+#: ext.c:139
#, c-format
msgid "extension: function name `%s' previously defined"
msgstr "extension: funktionsnavnet '%s' er defineret tidligere"
-#: ext.c:152
+#: ext.c:141
#, c-format
msgid "extension: can't use gawk built-in `%s' as function name"
msgstr "extension: kan ikke bruge gawk's indbyggede '%s' som funktionsnavn"
-#: ext.c:156
+#: ext.c:144
#, c-format
msgid "make_builtin: negative argument count for function `%s'"
msgstr "make_builtin: negativt argumentantal for funktion '%s'"
-#: ext.c:259
+#: ext.c:206
#, c-format
msgid "function `%s' defined to take no more than %d argument(s)"
msgstr "funktionen '%s' defineret til at tage ikke mere end %d argumenter"
-#: ext.c:262
+#: ext.c:209
#, c-format
msgid "function `%s': missing argument #%d"
msgstr "funktion '%s': mangler argument nummer %d"
-#: ext.c:279
+#: ext.c:226
#, c-format
msgid "function `%s': argument #%d: attempt to use scalar as an array"
msgstr ""
"funktion '%s': argument nummer %d: forsøg på at bruge skalar som et array"
-#: ext.c:283
+#: ext.c:230
#, c-format
msgid "function `%s': argument #%d: attempt to use array as a scalar"
msgstr ""
"funktion '%s': argument nummer %d: forsøg på at bruge array som en skalar"
-#: ext.c:296
+#: ext.c:244
msgid "Operation Not Supported"
msgstr "Operationen understøttes ikke"
-#: field.c:328
+#: ext.c:256
+msgid "dynamic loading of library not supported"
+msgstr ""
+
+#: field.c:339
msgid "NF set to negative value"
msgstr "NF sat til en negativ værdi"
-#: field.c:951 field.c:958 field.c:962
+#: field.c:962 field.c:969 field.c:973
msgid "split: fourth argument is a gawk extension"
msgstr "split: fjerde argument er en gawk-udvidelse"
-#: field.c:955
+#: field.c:966
msgid "split: fourth argument is not an array"
msgstr "split: fjerde argument er ikke et array"
-#: field.c:969
+#: field.c:980
msgid "split: second argument is not an array"
msgstr "split: andet argument er ikke et array"
-#: field.c:973
+#: field.c:984
msgid "split: cannot use the same array for second and fourth args"
msgstr "split: kan ikke bruge det samme array som andet og fjerde argument"
-#: field.c:978
+#: field.c:989
msgid "split: cannot use a subarray of second arg for fourth arg"
msgstr ""
"split: kan ikke bruge et underarray af andet argument som fjerde argument"
-#: field.c:981
+#: field.c:992
msgid "split: cannot use a subarray of fourth arg for second arg"
msgstr ""
"split: kan ikke bruge et underarray af fjerde argument som andet argument"
-#: field.c:1010
+#: field.c:1021
msgid "split: null string for third arg is a gawk extension"
msgstr "split: tom streng som tredje argument er en gawk-udvidelse"
-#: field.c:1050
+#: field.c:1061
msgid "patsplit: fourth argument is not an array"
msgstr "patsplit: fjerde argument er ikke et array"
-#: field.c:1055
+#: field.c:1066
msgid "patsplit: second argument is not an array"
msgstr "patsplit: andet argument er ikke et array"
-#: field.c:1061
+#: field.c:1072
msgid "patsplit: third argument must be non-null"
msgstr "patmatch: tredje argument er ikke et array"
-#: field.c:1065
+#: field.c:1076
msgid "patsplit: cannot use the same array for second and fourth args"
msgstr "patsplit: kan ikke bruge det samme array som andet og fjerde argument"
-#: field.c:1070
+#: field.c:1081
msgid "patsplit: cannot use a subarray of second arg for fourth arg"
msgstr ""
"patsplit: kan ikke bruge et underarray af andet argument som fjerde argument"
-#: field.c:1073
+#: field.c:1084
msgid "patsplit: cannot use a subarray of fourth arg for second arg"
msgstr ""
"patsplit: kan ikke bruge et underarray af fjerde argument som andet argument"
-#: field.c:1110
+#: field.c:1122
msgid "`FIELDWIDTHS' is a gawk extension"
msgstr "'FIELDWIDTHS' er en gawk-udvidelse"
-#: field.c:1173
+#: field.c:1186
#, c-format
msgid "invalid FIELDWIDTHS value, near `%s'"
msgstr "ugyldig FIELDWIDTHS værdi, nær '%s"
-#: field.c:1246
+#: field.c:1259
msgid "null string for `FS' is a gawk extension"
msgstr "tom streng som 'FS' er en gawk-udvidelse"
-#: field.c:1250
+#: field.c:1263
msgid "old awk does not support regexps as value of `FS'"
msgstr "gamle versioner af awk understøtter ikke regexp'er som værdi for 'FS'"
-#: field.c:1369
+#: field.c:1382
msgid "`FPAT' is a gawk extension"
msgstr "'FPAT' er en gawk-udvidelse"
@@ -1345,459 +1241,474 @@ msgstr "%s: flaget '-W %s' tillader ikke noget argument\n"
msgid "%s: option '-W %s' requires an argument\n"
msgstr "%s: flaget '-W %s' kræver et argument\n"
-#: io.c:280
+#: io.c:326
#, c-format
msgid "command line argument `%s' is a directory: skipped"
msgstr "kommandolinjeargument '%s' er et katalog, oversprunget"
-#: io.c:283 io.c:385
+#: io.c:329 io.c:438
#, c-format
msgid "cannot open file `%s' for reading (%s)"
msgstr "kan ikke åbne filen '%s' for læsning (%s)"
-#: io.c:501
+#: io.c:568
#, c-format
msgid "close of fd %d (`%s') failed (%s)"
msgstr "lukning af fd %d ('%s') mislykkedes (%s)"
-#: io.c:578
+#: io.c:645
msgid "redirection not allowed in sandbox mode"
msgstr "omdirigering ikke tilladt i sandkasse-tilstand"
-#: io.c:612
+#: io.c:679
#, c-format
msgid "expression in `%s' redirection only has numeric value"
msgstr "udtrykket i '%s'-omdirigering har kun numerisk værdi"
-#: io.c:618
+#: io.c:685
#, c-format
msgid "expression for `%s' redirection has null string value"
msgstr "udtrykket for '%s'-omdirigering har en tom streng som værdi"
-#: io.c:623
+#: io.c:690
#, c-format
msgid "filename `%s' for `%s' redirection may be result of logical expression"
msgstr ""
"filnavnet '%s' for '%s'-omdirigering kan være resultatet af et logisk udtryk"
-#: io.c:666
+#: io.c:733
#, c-format
msgid "unnecessary mixing of `>' and `>>' for file `%.*s'"
msgstr "unødig blanding af '>' og '>>' for filen '%.*s'"
-#: io.c:719
+#: io.c:786
#, c-format
msgid "can't open pipe `%s' for output (%s)"
msgstr "kan ikke åbne datakanalen '%s' for udskrivning (%s)"
-#: io.c:729
+#: io.c:796
#, c-format
msgid "can't open pipe `%s' for input (%s)"
msgstr "kan ikke åbne datakanalen '%s' for indtastning (%s)"
-#: io.c:752
+#: io.c:819
#, c-format
msgid "can't open two way pipe `%s' for input/output (%s)"
msgstr "kan ikke åbne tovejsdatakanalen '%s' for ind-/uddata (%s)"
-#: io.c:834
+#: io.c:900
#, c-format
msgid "can't redirect from `%s' (%s)"
msgstr "kan ikke omdirigere fra '%s' (%s)"
-#: io.c:837
+#: io.c:903
#, c-format
msgid "can't redirect to `%s' (%s)"
msgstr "kan ikke omdirigere til '%s' (%s)"
-#: io.c:888
+#: io.c:954
msgid ""
"reached system limit for open files: starting to multiplex file descriptors"
msgstr ""
"nåede systembegrænsningen for åbne filer: begynder at multiplekse "
"fildeskriptorer"
-#: io.c:904
+#: io.c:970
#, c-format
msgid "close of `%s' failed (%s)."
msgstr "lukning af '%s' mislykkedes (%s)."
-#: io.c:912
+#: io.c:978
msgid "too many pipes or input files open"
msgstr "for mange datakanaler eller inddatafiler åbne"
-#: io.c:934
+#: io.c:1000
msgid "close: second argument must be `to' or `from'"
msgstr "close: andet argument skal være 'to' eller 'from'"
-#: io.c:951
+#: io.c:1017
#, c-format
msgid "close: `%.*s' is not an open file, pipe or co-process"
msgstr "close: '%.*s' er ikke en åben fil, datakanal eller ko-proces"
-#: io.c:956
+#: io.c:1022
msgid "close of redirection that was never opened"
msgstr "lukning af omdirigering som aldrig blev åbnet"
-#: io.c:1053
+#: io.c:1120
#, c-format
msgid "close: redirection `%s' not opened with `|&', second argument ignored"
msgstr ""
"close: omdirigeringen '%s' blev ikke åbnet med '|&', andet argument ignoreret"
-#: io.c:1069
+#: io.c:1137
#, c-format
msgid "failure status (%d) on pipe close of `%s' (%s)"
msgstr "fejlstatus (%d) fra lukning af datakanalen '%s' (%s)"
-#: io.c:1072
+#: io.c:1140
#, c-format
msgid "failure status (%d) on file close of `%s' (%s)"
msgstr "fejlstatus (%d) fra fillukning af '%s' (%s)"
-#: io.c:1092
+#: io.c:1160
#, c-format
msgid "no explicit close of socket `%s' provided"
msgstr "ingen eksplicit lukning af soklen '%s' angivet"
-#: io.c:1095
+#: io.c:1163
#, c-format
msgid "no explicit close of co-process `%s' provided"
msgstr "ingen eksplicit lukning af ko-processen '%s' angivet"
-#: io.c:1098
+#: io.c:1166
#, c-format
msgid "no explicit close of pipe `%s' provided"
msgstr "ingen eksplicit lukning af datakanalen '%s' angivet"
-#: io.c:1101
+#: io.c:1169
#, c-format
msgid "no explicit close of file `%s' provided"
msgstr "ingen eksplicit lukning af filen '%s' angivet"
-#: io.c:1129 io.c:1184 main.c:794 main.c:831
+#: io.c:1197 io.c:1252 main.c:825 main.c:862
#, c-format
msgid "error writing standard output (%s)"
msgstr "fejl ved skrivning til standard ud (%s)"
-#: io.c:1133 io.c:1189
+#: io.c:1201 io.c:1257
#, c-format
msgid "error writing standard error (%s)"
msgstr "fejl ved skrivning til standard fejl (%s)"
-#: io.c:1141
+#: io.c:1209
#, c-format
msgid "pipe flush of `%s' failed (%s)."
msgstr "datakanalsrensning af '%s' mislykkedes (%s)."
-#: io.c:1144
+#: io.c:1212
#, c-format
msgid "co-process flush of pipe to `%s' failed (%s)."
msgstr "ko-procesrensning af datakanalen til '%s' mislykkedes (%s)."
-#: io.c:1147
+#: io.c:1215
#, c-format
msgid "file flush of `%s' failed (%s)."
msgstr "filrensning af '%s' mislykkedes (%s)."
-#: io.c:1262
+#: io.c:1329
#, c-format
msgid "local port %s invalid in `/inet'"
msgstr "lokal port %s ugyldig i '/inet'"
-#: io.c:1279
+#: io.c:1347
#, c-format
msgid "remote host and port information (%s, %s) invalid"
msgstr "fjernvært og portinformation (%s, %s) ugyldige"
-#: io.c:1431
+#: io.c:1499
#, c-format
msgid "no (known) protocol supplied in special filename `%s'"
msgstr "ingen (kendt) protokol opgivet i special-filnavn '%s'"
-#: io.c:1445
+#: io.c:1513
#, c-format
msgid "special file name `%s' is incomplete"
msgstr "special-filnavn '%s' er ufuldstændigt"
-#: io.c:1462
+#: io.c:1530
msgid "must supply a remote hostname to `/inet'"
msgstr "fjernmaskinenavn til '/inet' skal angives"
-#: io.c:1480
+#: io.c:1548
msgid "must supply a remote port to `/inet'"
msgstr "fjernport til '/inet' skal angives"
-#: io.c:1526
+#: io.c:1594
msgid "TCP/IP communications are not supported"
msgstr "TCP/IP-kommunikation understøttes ikke"
-#: io.c:1693
+#: io.c:1764
#, c-format
msgid "could not open `%s', mode `%s'"
msgstr "kunne ikke åbne '%s', tilstand '%s'"
-#: io.c:1747
+#: io.c:1814
#, c-format
msgid "close of master pty failed (%s)"
msgstr "lukning af master-pty mislykkedes (%s)"
-#: io.c:1749 io.c:1917 io.c:2074
+#: io.c:1816 io.c:1984 io.c:2145
#, c-format
msgid "close of stdout in child failed (%s)"
msgstr "lukning af standard ud i underproces mislykkedes (%s)"
-#: io.c:1752
+#: io.c:1819
#, c-format
msgid "moving slave pty to stdout in child failed (dup: %s)"
msgstr ""
"flytning af slave-pty til standard ud i underproces mislykkedes (dup: %s)"
-#: io.c:1754 io.c:1922
+#: io.c:1821 io.c:1989
#, c-format
msgid "close of stdin in child failed (%s)"
msgstr "lukning af standard ind i underproces mislykkedes (%s)"
-#: io.c:1757
+#: io.c:1824
#, c-format
msgid "moving slave pty to stdin in child failed (dup: %s)"
msgstr ""
"flytning af slave-pty til standard ind i underproces mislykkedes (dup: %s)"
-#: io.c:1759 io.c:1780
+#: io.c:1826 io.c:1847
#, c-format
msgid "close of slave pty failed (%s)"
msgstr "lukning af slave-pty mislykkedes (%s)"
-#: io.c:1858 io.c:1920 io.c:2052 io.c:2077
+#: io.c:1925 io.c:1987 io.c:2122 io.c:2148
#, c-format
msgid "moving pipe to stdout in child failed (dup: %s)"
msgstr ""
"flytning af datakanal til standard ud i underproces mislykkedes (dup: %s)"
-#: io.c:1865 io.c:1925
+#: io.c:1932 io.c:1992
#, c-format
msgid "moving pipe to stdin in child failed (dup: %s)"
msgstr ""
"flytning af datakanalen til standard ind i underproces mislykkedes (dup: %s)"
-#: io.c:1885 io.c:2067
+#: io.c:1952 io.c:2138
msgid "restoring stdout in parent process failed\n"
msgstr "genskabelse af standard ud i forælderprocessen mislykkedes\n"
-#: io.c:1893
+#: io.c:1960
msgid "restoring stdin in parent process failed\n"
msgstr "genskabelse af standard ind i forælderprocessen mislykkedes\n"
-#: io.c:1928 io.c:2079 io.c:2093
+#: io.c:1995 io.c:2150 io.c:2164
#, c-format
msgid "close of pipe failed (%s)"
msgstr "lukning af datakanalen mislykkedes (%s)"
-#: io.c:1973
+#: io.c:2040
msgid "`|&' not supported"
msgstr "'|&' understøttes ikke"
-#: io.c:2039
+#: io.c:2107
#, c-format
msgid "cannot open pipe `%s' (%s)"
msgstr "kan ikke åbne datakanalen '%s' (%s)"
-#: io.c:2087
+#: io.c:2158
#, c-format
msgid "cannot create child process for `%s' (fork: %s)"
msgstr "kan ikke oprette barneproces for '%s' (fork: %s)"
-#: io.c:2520
+#: io.c:2637
#, c-format
msgid "data file `%s' is empty"
msgstr "datafilen '%s' er tom"
-#: io.c:2561 io.c:2569
+#: io.c:2678 io.c:2686
msgid "could not allocate more input memory"
msgstr "kunne ikke allokere mere hukommelse til inddata"
-#: io.c:3127
+#: io.c:3236
msgid "multicharacter value of `RS' is a gawk extension"
msgstr "'RS' som flertegnsværdi er en gawk-udvidelse"
-#: io.c:3232
+#: io.c:3326
msgid "IPv6 communication is not supported"
msgstr "IPv6-kommunikation understøttes ikke"
-#: main.c:366
+#: main.c:355
msgid "`-m[fr]' option irrelevant in gawk"
msgstr "'-m[fr]'-flaget er irrelevant i gawk"
-#: main.c:368
+#: main.c:357
msgid "-m option usage: `-m[fr] nnn'"
msgstr "brug af flaget -m: '-m[fr] nnn'"
-#: main.c:391
+#: main.c:386
msgid "empty argument to `-e/--source' ignored"
msgstr "tomt argument til '-e/--source' ignoreret"
-#: main.c:462
+#: main.c:472
#, c-format
msgid "%s: option `-W %s' unrecognized, ignored\n"
msgstr "%s: flaget '-W %s' ukendt, ignoreret\n"
-#: main.c:515
+#: main.c:518
#, c-format
msgid "%s: option requires an argument -- %c\n"
msgstr "%s: flaget kræver et argument -- %c\n"
-#: main.c:536
+#: main.c:539
msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'"
msgstr "miljøvariablen 'POSIXLY_CORRECT' sat: aktiverer '--posix'"
-#: main.c:542
+#: main.c:545
msgid "`--posix' overrides `--traditional'"
msgstr "'--posix' tilsidesætter '--traditional'"
-#: main.c:553
+#: main.c:556
msgid "`--posix'/`--traditional' overrides `--non-decimal-data'"
msgstr "'--posix'/'--traditional' tilsidesætter '--non-decimal-data'"
-#: main.c:557
+#: main.c:560
#, c-format
msgid "running %s setuid root may be a security problem"
msgstr "at køre %s setuid root kan være et sikkerhedsproblem"
-#: main.c:562
+#: main.c:565
msgid "`--posix' overrides `--binary'"
msgstr "'--posix' tilsidesætter '--binary'"
-#: main.c:613
+#: main.c:623
#, c-format
msgid "can't set binary mode on stdin (%s)"
msgstr "kan ikke sætte binær tilstand på standard ind (%s)"
-#: main.c:616
+#: main.c:626
#, c-format
msgid "can't set binary mode on stdout (%s)"
msgstr "kan ikke sætte binær tilstand på standard ud (%s)"
-#: main.c:618
+#: main.c:628
#, c-format
msgid "can't set binary mode on stderr (%s)"
msgstr "kan ikke sætte binær tilstand på standard fejl (%s)"
-#: main.c:657
+#: main.c:679
msgid "no program text at all!"
msgstr "ingen programtekst overhovedet!"
-#: main.c:734
+#: main.c:763
#, c-format
msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n"
msgstr "Brug: %s [flag i POSIX- eller GNU-stil] -f progfil [--] fil ...\n"
-#: main.c:736
+#: main.c:765
#, c-format
msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n"
msgstr "Brug: %s [flag i POSIX- eller GNU-stil] %cprogram%c fil ...\n"
-#: main.c:741
+#: main.c:770
msgid "POSIX options:\t\tGNU long options: (standard)\n"
msgstr "POSIX-flag:\t\tlange GNU-flag: (standard)\n"
-#: main.c:742
+#: main.c:771
msgid "\t-f progfile\t\t--file=progfile\n"
msgstr "\t-f progfil\t\t--file=progfil\n"
-#: main.c:743
+#: main.c:772
msgid "\t-F fs\t\t\t--field-separator=fs\n"
msgstr "\t-F fs\t\t\t--field-separator=fs\n"
-#: main.c:744
+#: main.c:773
msgid "\t-v var=val\t\t--assign=var=val\n"
msgstr "\t-v var=værdi\t\t--assign=var=værdi\n"
-#: main.c:745
+#: main.c:774
msgid "Short options:\t\tGNU long options: (extensions)\n"
msgstr "POSIX-flag:\t\tlange GNU-flag: (udvidelser)\n"
-#: main.c:746
+#: main.c:775
msgid "\t-b\t\t\t--characters-as-bytes\n"
msgstr "\t-b\t\t\t--characters-as-bytes\n"
-#: main.c:747
+#: main.c:776
msgid "\t-c\t\t\t--traditional\n"
msgstr "\t-c\t\t\t--traditional\n"
-#: main.c:748
+#: main.c:777
msgid "\t-C\t\t\t--copyright\n"
msgstr "\t-C\t\t\t--copyright\n"
-#: main.c:749
+#: main.c:778
msgid "\t-d[file]\t\t--dump-variables[=file]\n"
msgstr "\t-d[fil]\t\t--dump-variables[=fil]\n"
-#: main.c:750
+#: main.c:779
+#, fuzzy
+msgid "\t-D[file]\t\t--debug[=file]\n"
+msgstr "\t-p[fil]\t\t--profile[=fil]\n"
+
+#: main.c:780
msgid "\t-e 'program-text'\t--source='program-text'\n"
msgstr "\t-e 'programtekst'\t--source='programtekst'\n"
-#: main.c:751
+#: main.c:781
msgid "\t-E file\t\t\t--exec=file\n"
msgstr "\t-E fil\t\t\t--exec=fil\n"
-#: main.c:752
+#: main.c:782
msgid "\t-g\t\t\t--gen-pot\n"
msgstr "\t-g\t\t\t--gen-pot\n"
-#: main.c:753
+#: main.c:783
msgid "\t-h\t\t\t--help\n"
msgstr "\t-h\t\t\t--help\n"
-#: main.c:754
+#: main.c:784
+msgid "\t-l library\t\t--load=library\n"
+msgstr ""
+
+#: main.c:785
msgid "\t-L [fatal]\t\t--lint[=fatal]\n"
msgstr "\t-L [fatal]\t\t--lint[=fatal]\n"
-#: main.c:755
+#: main.c:786
msgid "\t-n\t\t\t--non-decimal-data\n"
msgstr "\t-n\t\t\t--non-decimal-data\n"
-#: main.c:756
+#: main.c:787
+#, fuzzy
+msgid "\t-M\t\t\t--bignum\n"
+msgstr "\t-g\t\t\t--gen-pot\n"
+
+#: main.c:788
msgid "\t-N\t\t\t--use-lc-numeric\n"
msgstr "\t-N\t\t\t--use-lc-numeric\n"
-#: main.c:757
+#: main.c:789
+#, fuzzy
+msgid "\t-o[file]\t\t--pretty-print[=file]\n"
+msgstr "\t-p[fil]\t\t--profile[=fil]\n"
+
+#: main.c:790
msgid "\t-O\t\t\t--optimize\n"
msgstr "\t-O\t\t\t--optimize\n"
-#: main.c:758
+#: main.c:791
msgid "\t-p[file]\t\t--profile[=file]\n"
msgstr "\t-p[fil]\t\t--profile[=fil]\n"
-#: main.c:759
+#: main.c:792
msgid "\t-P\t\t\t--posix\n"
msgstr "\t-P\t\t\t--posix\n"
-#: main.c:760
+#: main.c:793
msgid "\t-r\t\t\t--re-interval\n"
msgstr "\t-r\t\t\t--re-interval\n"
-#: main.c:762
-msgid "\t-R file\t\t\t--command=file\n"
-msgstr "\t-R file\t\t\t--command=fil\n"
-
-#: main.c:763
+#: main.c:794
msgid "\t-S\t\t\t--sandbox\n"
msgstr "\t-S\t\t\t--sandbox\n"
-#: main.c:764
+#: main.c:795
msgid "\t-t\t\t\t--lint-old\n"
msgstr "\t-t\t\t\t--lint-old\n"
-#: main.c:765
+#: main.c:796
msgid "\t-V\t\t\t--version\n"
msgstr "\t-V\t\t\t--version\n"
-#: main.c:767
+#: main.c:798
msgid "\t-W nostalgia\t\t--nostalgia\n"
msgstr "\t-W nostalgia\t\t--nostalgia\n"
-#: main.c:770
+#: main.c:801
msgid "\t-Y\t\t--parsedebug\n"
msgstr "\t-Y\t\t--parsedebug\n"
@@ -1806,7 +1717,7 @@ msgstr "\t-Y\t\t--parsedebug\n"
#. for this application. Please add _another line_ with the
#. address for translation bugs.
#. no-wrap
-#: main.c:779
+#: main.c:810
msgid ""
"\n"
"To report bugs, see node `Bugs' in `gawk.info', which is\n"
@@ -1819,7 +1730,7 @@ msgstr ""
"\n"
"Rapportér kommentarer til oversættelsen til <dansk@dansk-gruppen.dk>.\n"
-#: main.c:783
+#: main.c:814
msgid ""
"gawk is a pattern scanning and processing language.\n"
"By default it reads standard input and writes standard output.\n"
@@ -1829,7 +1740,7 @@ msgstr ""
"Almindeligvis læser gawk fra standard ind og skriver til standard ud.\n"
"\n"
-#: main.c:787
+#: main.c:818
msgid ""
"Examples:\n"
"\tgawk '{ sum += $1 }; END { print sum }' file\n"
@@ -1839,7 +1750,7 @@ msgstr ""
"\tgawk '{ sum += $1 }; END { print sum }' fil\n"
"\tgawk -F: '{ print $1 }' /etc/passwd\n"
-#: main.c:807
+#: main.c:838
#, c-format
msgid ""
"Copyright (C) 1989, 1991-%d Free Software Foundation.\n"
@@ -1859,7 +1770,7 @@ msgstr ""
"enhver senere version.\n"
"\n"
-#: main.c:815
+#: main.c:846
msgid ""
"This program is distributed in the hope that it will be useful,\n"
"but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
@@ -1873,7 +1784,7 @@ msgstr ""
"General Public License for yderligere information.\n"
"\n"
-#: main.c:821
+#: main.c:852
msgid ""
"You should have received a copy of the GNU General Public License\n"
"along with this program. If not, see http://www.gnu.org/licenses/.\n"
@@ -1881,16 +1792,16 @@ msgstr ""
"Du bør have fået en kopi af GNU General Public License sammen\n"
"med dette program. Hvis ikke, så se http://www.gnu.org/licenses/.\n"
-#: main.c:856
+#: main.c:887
msgid "-Ft does not set FS to tab in POSIX awk"
msgstr "-Ft sætter ikke FS til tab i POSIX-awk"
-#: main.c:1090
+#: main.c:1133
#, c-format
msgid "unknown value for field spec: %d\n"
msgstr "ukendt værdi for felt-spec: %d\n"
-#: main.c:1171
+#: main.c:1214
#, c-format
msgid ""
"%s: `%s' argument to `-v' not in `var=value' form\n"
@@ -1899,79 +1810,79 @@ msgstr ""
"%s: '%s' argument til '-v' ikke på formen 'var=værdi'\n"
"\n"
-#: main.c:1197
+#: main.c:1240
#, c-format
msgid "`%s' is not a legal variable name"
msgstr "'%s' er ikke et gyldigt variabelnavn"
-#: main.c:1200
+#: main.c:1243
#, c-format
msgid "`%s' is not a variable name, looking for file `%s=%s'"
msgstr "'%s' er ikke et variabelnavn, leder efter fil '%s=%s'"
-#: main.c:1204
+#: main.c:1247
#, c-format
msgid "cannot use gawk builtin `%s' as variable name"
msgstr "kan ikke bruge gawk's indbyggede '%s' som variabelnavn"
-#: main.c:1209
+#: main.c:1252
#, c-format
msgid "cannot use function `%s' as variable name"
msgstr "kan ikke bruge funktion '%s' som variabelnavn"
-#: main.c:1262
+#: main.c:1305
msgid "floating point exception"
msgstr "flydendetalsundtagelse"
-#: main.c:1269
+#: main.c:1312
msgid "fatal error: internal error"
msgstr "fatal fejl: intern fejl"
-#: main.c:1284
+#: main.c:1327
msgid "fatal error: internal error: segfault"
msgstr "fatal fejl: intern fejl: segmentfejl"
-#: main.c:1296
+#: main.c:1339
msgid "fatal error: internal error: stack overflow"
msgstr "fatal fejl: intern fejl: stakoverløb"
-#: main.c:1346
+#: main.c:1393
#, c-format
msgid "no pre-opened fd %d"
msgstr "ingen fd %d åbnet i forvejen"
-#: main.c:1353
+#: main.c:1400
#, c-format
msgid "could not pre-open /dev/null for fd %d"
msgstr "kunne ikke i forvejen åbne /dev/null for fd %d"
-#: msg.c:63
+#: msg.c:61
#, c-format
msgid "cmd. line:"
msgstr "kommandolinje:"
-#: msg.c:107
+#: msg.c:121
msgid "error: "
msgstr "fejl: "
-#: node.c:406
+#: node.c:436
msgid "backslash at end of string"
msgstr "omvendt skråstreg i slutningen af strengen"
-#: node.c:517
+#: node.c:520
#, c-format
msgid "old awk does not support the `\\%c' escape sequence"
msgstr "gamle versioner af awk understøtter ikke '\\%c' undvigesekvens"
-#: node.c:568
+#: node.c:571
msgid "POSIX does not allow `\\x' escapes"
msgstr "POSIX tillader ikke '\\x'-kontrolsekvenser"
-#: node.c:574
+#: node.c:577
msgid "no hex digits in `\\x' escape sequence"
msgstr "ingen heksadecimale cifre i '\\x'-kontrolsekvenser"
-#: node.c:596
+#: node.c:599
#, c-format
msgid ""
"hex escape \\x%.*s of %d characters probably not interpreted the way you "
@@ -1980,12 +1891,12 @@ msgstr ""
"den heksadecimale sekvens \\x%.*s på %d tegn nok ikke forstået som du "
"forventer det"
-#: node.c:611
+#: node.c:614
#, c-format
msgid "escape sequence `\\%c' treated as plain `%c'"
msgstr "kontrolsekvensen '\\%c' behandlet som kun '%c'"
-#: node.c:750
+#: node.c:759
msgid ""
"Invalid multibyte data detected. There may be a mismatch between your data "
"and your locale."
@@ -2003,16 +1914,16 @@ msgstr "%s %s '%s': kunne ikke få fat på fd flag: (fcntl F_GETFD: %s)"
msgid "%s %s `%s': could not set close-on-exec: (fcntl F_SETFD: %s)"
msgstr "%s %s '%s': kunne ikke sætte luk-ved-exec (fcntl F_SETFD: %s)"
-#: profile.c:83
+#: profile.c:69
#, c-format
msgid "could not open `%s' for writing: %s"
msgstr "kunne ikke åbne '%s' for skrivning: %s"
-#: profile.c:85
+#: profile.c:71
msgid "sending profile to standard error"
msgstr "sender profilen til standard fejl"
-#: profile.c:203
+#: profile.c:187
#, c-format
msgid ""
"\t# %s block(s)\n"
@@ -2021,7 +1932,7 @@ msgstr ""
"\t# %s blokke\n"
"\n"
-#: profile.c:208
+#: profile.c:192
#, c-format
msgid ""
"\t# Rule(s)\n"
@@ -2030,17 +1941,22 @@ msgstr ""
"\t# Regler\n"
"\n"
-#: profile.c:279
+#: profile.c:266
#, c-format
msgid "internal error: %s with null vname"
msgstr "intern fejl: %s med null vname"
-#: profile.c:952
+#: profile.c:528
+#, fuzzy
+msgid "internal error: builtin with null fname"
+msgstr "intern fejl: %s med null vname"
+
+#: profile.c:943
#, c-format
msgid "\t# gawk profile, created %s\n"
msgstr "\t# profil til gawk oprettet %s\n"
-#: profile.c:1331
+#: profile.c:1328
#, c-format
msgid ""
"\n"
@@ -2049,17 +1965,17 @@ msgstr ""
"\n"
"\t# Funktioner, listede alfabetisk\n"
-#: profile.c:1370
+#: profile.c:1366
#, c-format
msgid "redir2str: unknown redirection type %d"
msgstr "redir2str: uykendt omdirigeringstype %d"
-#: re.c:573
+#: re.c:571
#, c-format
msgid "range of the form `[%c-%c]' is locale dependent"
msgstr "område på formen `[%c-%c]' er locale-afhængig"
-#: re.c:600
+#: re.c:598
#, c-format
msgid "regexp component `%.*s' should probably be `[%.*s]'"
msgstr "regexp-komponent `%.*s' skulle nok være `[%.*s]'"
@@ -2136,6 +2052,78 @@ msgstr "Ubalanceret ) eller \\)"
msgid "No previous regular expression"
msgstr "Intet foregående regulært udtryk"
+#~ msgid "attempt to use function `%s' as an array"
+#~ msgstr "forsøg på at bruge funktionen '%s' som et array"
+
+#~ msgid "reference to uninitialized element `%s[\"%.*s\"]'"
+#~ msgstr "reference til ikke-initieret element '%s[\"%.*s\"]'"
+
+#~ msgid "subscript of array `%s' is null string"
+#~ msgstr "indeks i array '%s' er en tom streng"
+
+#~ msgid "%s: empty (null)\n"
+#~ msgstr "%s: tom (null)\n"
+
+#~ msgid "%s: empty (zero)\n"
+#~ msgstr "%s: tom (nul)\n"
+
+#~ msgid "%s: table_size = %d, array_size = %d\n"
+#~ msgstr "%s: tabelstørrelse = %d, arraystørrelse = %d\n"
+
+#~ msgid "%s: is parameter\n"
+#~ msgstr "%s: er parameter\n"
+
+#~ msgid "%s: array_ref to %s\n"
+#~ msgstr "%s: arrayreference til %s\n"
+
+#~ msgid "use of non-array as array"
+#~ msgstr "brug af ikke-array som array"
+
+#~ msgid "can't use function name `%s' as variable or array"
+#~ msgstr "kan ikke bruge funktionsnavnet '%s' som variabel eller array"
+
+#~ msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
+#~ msgstr "forsøg på at bruge array '%s[\"%.*s\"]' i skalarsammenhæng"
+
+#~ msgid "assignment used in conditional context"
+#~ msgstr "tildeling brugt i sammenligningsammenhæng"
+
+#~ msgid "statement has no effect"
+#~ msgstr "kommandoen har ingen effekt"
+
+#~ msgid ""
+#~ "for loop: array `%s' changed size from %ld to %ld during loop execution"
+#~ msgstr ""
+#~ "for-løkke: array '%s' ændrede størrelse fra %ld til %ld under udførelse "
+#~ "af løkken"
+
+#~ msgid "function called indirectly through `%s' does not exist"
+#~ msgstr "funktion kaldt indirekte via '%s' eksisterer ikke"
+
+#~ msgid "function `%s' not defined"
+#~ msgstr "funktionen '%s' er ikke defineret"
+
+#~ msgid "non-redirected `getline' invalid inside `%s' rule"
+#~ msgstr "ikke-omdirigeret 'getline' ugyldig inden i '%s'-regel"
+
+#~ msgid "error reading input file `%s': %s"
+#~ msgstr "fejl ved læsning af inddatafilen '%s': %s"
+
+#~ msgid "`nextfile' cannot be called from a `%s' rule"
+#~ msgstr "'nextfile' kan ikke kaldes fra en '%s'-regel"
+
+#~ msgid "`exit' cannot be called in the current context"
+#~ msgstr "'exit' kan ikke kaldes i den aktuelle kontekst"
+
+#~ msgid "`next' cannot be called from a `%s' rule"
+#~ msgstr "'next' kan ikke kaldes fra en '%s'-regel"
+
+#~ msgid "Sorry, don't know how to interpret `%s'"
+#~ msgstr "Véd desværre ikke hvordan '%s' skal fortolkes"
+
+#~ msgid "\t-R file\t\t\t--command=file\n"
+#~ msgstr "\t-R file\t\t\t--command=fil\n"
+
#~ msgid "could not find groups: %s"
#~ msgstr "kunne ikke finde grupper: %s"
diff --git a/po/de.gmo b/po/de.gmo
index 756fbf0f..a473dc50 100644
--- a/po/de.gmo
+++ b/po/de.gmo
Binary files differ
diff --git a/po/de.po b/po/de.po
index b69e0c02..ea1bcfe5 100644
--- a/po/de.po
+++ b/po/de.po
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: gawk 4.0.0h\n"
"Report-Msgid-Bugs-To: arnold@skeeve.com\n"
-"POT-Creation-Date: 2012-03-28 22:03+0200\n"
+"POT-Creation-Date: 2012-04-27 10:06+0300\n"
"PO-Revision-Date: 2012-01-30 16:21+0100\n"
"Last-Translator: Philipp Thomas <pth@suse.de>\n"
"Language-Team: German <translation-team-de@lists.sourceforge.net>\n"
@@ -17,525 +17,482 @@ msgstr ""
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
-#: array.c:140
+#: array.c:266
#, c-format
msgid "from %s"
msgstr "von %s"
-#: array.c:248
+#: array.c:366
msgid "attempt to use a scalar value as array"
msgstr "Es wird versucht, einen Skalar als Feld zu verwenden"
-#: array.c:251
-#, c-format
-msgid "attempt to use function `%s' as an array"
-msgstr "Es wird versucht, die Funktion »%s« als Feld zu verwenden"
-
-#: array.c:254
+#: array.c:368
#, c-format
msgid "attempt to use scalar parameter `%s' as an array"
msgstr "Es wird versucht, den skalaren Parameter »%s« als Feld zu verwenden"
-#: array.c:257
+#: array.c:371
#, c-format
msgid "attempt to use scalar `%s' as an array"
msgstr "Es wird versucht, den Skalar »%s« als Array zu verwenden"
-#: array.c:302 array.c:707 builtin.c:84 builtin.c:1385 builtin.c:1427
-#: builtin.c:1440 builtin.c:1859 builtin.c:1871 eval.c:1135 eval.c:1139
-#: eval.c:1495 eval.c:1812
+#: array.c:418 array.c:584 builtin.c:85 builtin.c:1560 builtin.c:1602
+#: builtin.c:1615 builtin.c:2041 builtin.c:2053 eval.c:1109 eval.c:1113
+#: eval.c:1508
#, c-format
msgid "attempt to use array `%s' in a scalar context"
msgstr "Es wird versucht, das Feld »%s« in einem Skalarkontext zu verwenden"
-#: array.c:513
-#, c-format
-msgid "reference to uninitialized element `%s[\"%.*s\"]'"
-msgstr "Bezug auf ein nicht initialisiertes Element »%s[\"%.*s\"]«"
-
-#: array.c:519
-#, c-format
-msgid "subscript of array `%s' is null string"
-msgstr "Der Index von Feld »%s« ist ein Nullstring"
-
-#: array.c:723
+#: array.c:591
#, c-format
msgid "delete: index `%s' not in array `%s'"
msgstr "delete: Index »%s« ist in Feld »%s« nicht vorhanden"
-#: array.c:734 eval.c:1865
+#: array.c:605
#, c-format
msgid "attempt to use scalar `%s[\"%.*s\"]' as an array"
msgstr "Es wird versucht, den Skalar »%s[\"%.*s\"]« als Feld zu verwenden"
-#: array.c:910
-#, c-format
-msgid "%s: empty (null)\n"
-msgstr "%s: leer (Null)\n"
-
-#: array.c:915
-#, c-format
-msgid "%s: empty (zero)\n"
-msgstr "%s: leer (0)\n"
-
-#: array.c:919
-#, c-format
-msgid "%s: table_size = %d, array_size = %d\n"
-msgstr "%s: Tabellengröße = %d, Feldgröße = %d\n"
-
-#: array.c:954
-#, c-format
-msgid "%s: is parameter\n"
-msgstr "%s: ist ein Parameter\n"
-
-#: array.c:958
-#, c-format
-msgid "%s: array_ref to %s\n"
-msgstr "%s: Feld-Referenz auf %s\n"
-
-#: array.c:963
-msgid "adump: argument not an array"
+#: array.c:784
+#, fuzzy
+msgid "adump: first argument not an array"
msgstr "adump: Das Argument ist kein Feld"
-#: array.c:1086
+#: array.c:823
msgid "asort: second argument not an array"
msgstr "asort: Das zweite Argument ist kein Feld"
-#: array.c:1087
+#: array.c:824
msgid "asorti: second argument not an array"
msgstr "asorti: Das zweite Argument ist kein Feld"
-#: array.c:1094
+#: array.c:831
msgid "asort: first argument not an array"
msgstr "asort: Das erste Argument ist kein Feld"
-#: array.c:1095
+#: array.c:832
msgid "asorti: first argument not an array"
msgstr "asorti: Das erste Argument ist kein Feld"
-#: array.c:1102
+#: array.c:839
msgid "asort: cannot use a subarray of first arg for second arg"
msgstr ""
"asort: ein untergeordnetes Feld des ersten Arguments kann nicht als zweites "
"Argument verwendet werden"
-#: array.c:1103
+#: array.c:840
msgid "asorti: cannot use a subarray of first arg for second arg"
msgstr ""
"asorti: ein untergeordnetes Feld des ersten Arguments kann nicht als zweites "
"Argument verwendet werden"
-#: array.c:1108
+#: array.c:845
msgid "asort: cannot use a subarray of second arg for first arg"
msgstr ""
"asort: ein untergeordnetes Feld des zweiten Arguments kann nicht als erstes "
"Argument verwendet werden"
-#: array.c:1109
+#: array.c:846
msgid "asorti: cannot use a subarray of second arg for first arg"
msgstr ""
"asorti: ein untergeordnetes Feld des zweiten Arguments kann nicht als erstes "
"Argument verwendet werden"
-#: array.c:1655
+#: array.c:1314
#, c-format
msgid "`%s' is invalid as a function name"
msgstr "»%s« ist ein unzulässiger Funktionsname"
-#: array.c:1659
+#: array.c:1318
#, c-format
msgid "sort comparison function `%s' is not defined"
msgstr "Die Vergleichsfunktion »%s« für das Sortieren ist nicht definiert"
-#: awkgram.y:249
+#: awkgram.y:223
#, c-format
msgid "%s blocks must have an action part"
msgstr "%s-Blöcke müssen einen Aktionsteil haben"
-#: awkgram.y:252
+#: awkgram.y:226
msgid "each rule must have a pattern or an action part"
msgstr "Jede Regel muss entweder ein Muster oder einen Aktionsteil haben"
-#: awkgram.y:323 awkgram.y:334
+#: awkgram.y:295 awkgram.y:306
msgid "old awk does not support multiple `BEGIN' or `END' rules"
msgstr "Das alte awk erlaubt keine mehrfachen »BEGIN«- oder »END«-Regeln"
-#: awkgram.y:371
+#: awkgram.y:343
#, c-format
msgid "`%s' is a built-in function, it cannot be redefined"
msgstr "»%s« ist eine eingebaute Funktion und kann nicht umdefiniert werden"
-#: awkgram.y:432
+#: awkgram.y:389
msgid "regexp constant `//' looks like a C++ comment, but is not"
msgstr ""
"Die Regulärer-Ausdruck-Konstante »//« sieht wie ein C-Kommentar aus, ist "
"aber keiner"
-#: awkgram.y:436
+#: awkgram.y:393
#, c-format
msgid "regexp constant `/%s/' looks like a C comment, but is not"
msgstr ""
"Die Regulärer-Ausdruck-Konstante »/%s/« sieht wie ein C-Kommentar aus, ist "
"aber keiner"
-#: awkgram.y:528
+#: awkgram.y:485
#, c-format
msgid "duplicate case values in switch body: %s"
msgstr "doppelte Case-Werte im Switch-Block: %s"
-#: awkgram.y:549
+#: awkgram.y:506
msgid "duplicate `default' detected in switch body"
msgstr "doppeltes »default« im Switch-Block gefunden"
-#: awkgram.y:809
+#: awkgram.y:766
msgid "`break' is not allowed outside a loop or switch"
msgstr ""
"»break« ist außerhalb einer Schleife oder eines Switch-Blocks nicht zulässig"
-#: awkgram.y:818
+#: awkgram.y:775
msgid "`continue' is not allowed outside a loop"
msgstr "»continue« ist außerhalb einer Schleife nicht zulässig"
-#: awkgram.y:828
+#: awkgram.y:785
#, c-format
msgid "`next' used in %s action"
msgstr "»next« wird in %s-Aktion verwendet"
-#: awkgram.y:836
+#: awkgram.y:793
msgid "`nextfile' is a gawk extension"
msgstr "»nextfile« ist eine gawk-Erweiterung"
-#: awkgram.y:841
+#: awkgram.y:798
#, c-format
msgid "`nextfile' used in %s action"
msgstr "»nextfile« wird in %s-Aktion verwendet"
-#: awkgram.y:865
+#: awkgram.y:822
msgid "`return' used outside function context"
msgstr "»return« wird außerhalb einer Funktion verwendet"
-#: awkgram.y:925
+#: awkgram.y:896
msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'"
msgstr ""
"Einfaches »print« in BEGIN- oder END-Regel soll vermutlich »print \"\"« sein"
-#: awkgram.y:995 awkgram.y:999 awkgram.y:1023
+#: awkgram.y:966 awkgram.y:970 awkgram.y:994
msgid "`delete array' is a gawk extension"
msgstr "»delete array« ist eine gawk-Erweiterung"
-#: awkgram.y:1019
+#: awkgram.y:990
msgid "`delete(array)' is a non-portable tawk extension"
msgstr "»delete(array)« ist eine gawk-Erweiterung"
-#: awkgram.y:1135
+#: awkgram.y:1108
msgid "multistage two-way pipelines don't work"
msgstr "mehrstufige Zweiwege-Pipes funktionieren nicht"
-#: awkgram.y:1238
+#: awkgram.y:1211
msgid "regular expression on right of assignment"
msgstr "Regulärer Ausdruck auf der rechten Seite einer Zuweisung"
-#: awkgram.y:1249
+#: awkgram.y:1222
msgid "regular expression on left of `~' or `!~' operator"
msgstr "Regulärer Ausdruck links vom »~«- oder »!~«-Operator"
-#: awkgram.y:1265 awkgram.y:1419
+#: awkgram.y:1238 awkgram.y:1389
msgid "old awk does not support the keyword `in' except after `for'"
msgstr "Das alte awk unterstützt das Schlüsselwort »in« nur nach »for«"
-#: awkgram.y:1275
+#: awkgram.y:1248
msgid "regular expression on right of comparison"
msgstr "Regulärer Ausdruck rechts von einem Vergleich"
-#: awkgram.y:1394
+#: awkgram.y:1364
#, c-format
msgid "`getline var' invalid inside `%s' rule"
msgstr "»getline var« ist ungültig innerhalb der »%s«-Regel"
-#: awkgram.y:1397 eval.c:2504
+#: awkgram.y:1367
#, c-format
msgid "`getline' invalid inside `%s' rule"
msgstr "»getline« ist ungültig innerhalb der »%s«-Regel"
-#: awkgram.y:1402
+#: awkgram.y:1372
msgid "non-redirected `getline' undefined inside END action"
msgstr ""
"Nicht-umgelenktes »getline« ist innerhalb der END-Aktion nicht definiert"
-#: awkgram.y:1421
+#: awkgram.y:1391
msgid "old awk does not support multidimensional arrays"
msgstr "Das alte awk unterstützt keine mehrdimensionalen Felder"
-#: awkgram.y:1517
+#: awkgram.y:1488
msgid "call of `length' without parentheses is not portable"
msgstr "Aufruf von »length« ohne Klammern ist nicht portabel"
-#: awkgram.y:1580
+#: awkgram.y:1554
msgid "indirect function calls are a gawk extension"
msgstr "indirekte Funktionsaufrufe sind eine gawk-Erweiterung"
-#: awkgram.y:1593
+#: awkgram.y:1567
#, c-format
msgid "can not use special variable `%s' for indirect function call"
msgstr ""
"die besondere Variable »%s« kann nicht für den indirekten Funktionsaufruf "
"verwendet werden"
-#: awkgram.y:1671
+#: awkgram.y:1645
msgid "invalid subscript expression"
msgstr "Ungültiger Index-Ausdruck"
-#: awkgram.y:1711
-msgid "use of non-array as array"
-msgstr "Verwendung eines Nicht-Feldes als Feld"
-
-#: awkgram.y:1975 awkgram.y:1995 msg.c:98
+#: awkgram.y:1966 awkgram.y:1986 msg.c:112
msgid "warning: "
msgstr "Warnung: "
-#: awkgram.y:1993 msg.c:130
+#: awkgram.y:1984 msg.c:144
msgid "fatal: "
msgstr "Fatal: "
-#: awkgram.y:2043
+#: awkgram.y:2034
msgid "unexpected newline or end of string"
msgstr "Unerwarteter Zeilenumbruch oder Ende der Zeichenkette"
-#: awkgram.y:2300 awkgram.y:2358 awkgram.y:2542
+#: awkgram.y:2299 awkgram.y:2357 awkgram.y:2545
#, c-format
msgid "can't open source file `%s' for reading (%s)"
msgstr "Quelldatei »%s« kann nicht zum Lesen geöffnet werden (%s)"
-#: awkgram.y:2301 awkgram.y:2359 builtin.c:122
+#: awkgram.y:2300 awkgram.y:2358 builtin.c:124
msgid "reason unknown"
msgstr "Unbekannte Ursache"
-#: awkgram.y:2317
+#: awkgram.y:2316
#, c-format
msgid "already included source file `%s'"
msgstr "Quelldatei »%s« wurde bereits eingebunden"
-#: awkgram.y:2343
+#: awkgram.y:2342
msgid "@include is a gawk extension"
msgstr "»@include« ist eine gawk-Erweiterung"
-#: awkgram.y:2349
+#: awkgram.y:2348
msgid "empty filename after @include"
msgstr "leerer Dateiname nach @include"
-#: awkgram.y:2494
+#: awkgram.y:2497
msgid "empty program text on command line"
msgstr "Kein Programmtext auf der Kommandozeile"
-#: awkgram.y:2609
+#: awkgram.y:2612
#, c-format
msgid "can't read sourcefile `%s' (%s)"
msgstr "Die Quelldatei »%s« kann nicht gelesen werden (%s)"
-#: awkgram.y:2620
+#: awkgram.y:2623
#, c-format
msgid "source file `%s' is empty"
msgstr "Die Quelldatei »%s« ist leer"
-#: awkgram.y:2797
+#: awkgram.y:2800
msgid "source file does not end in newline"
msgstr "Die Quelldatei hört nicht mit einem Zeilenende auf"
-#: awkgram.y:2900
+#: awkgram.y:2905
msgid "unterminated regexp ends with `\\' at end of file"
msgstr ""
"Nicht beendeter regulärer Ausdruck (hört mit '\\' auf) am Ende der Datei"
-#: awkgram.y:2924
+#: awkgram.y:2929
#, c-format
msgid "%s: %d: tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr ""
"%s: %d: der tawk-Modifizierer für reguläre Ausdrücke »/.../%c« funktioniert "
"nicht in gawk"
-#: awkgram.y:2928
+#: awkgram.y:2933
#, c-format
msgid "tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr ""
"Der tawk-Modifizierer für reguläre Ausdrücke »/.../%c« funktioniert nicht in "
"gawk"
-#: awkgram.y:2935
+#: awkgram.y:2940
msgid "unterminated regexp"
msgstr "Nicht beendeter regulärer Ausdruck"
-#: awkgram.y:2939
+#: awkgram.y:2944
msgid "unterminated regexp at end of file"
msgstr "Nicht beendeter regulärer Ausdruck am Dateiende"
-#: awkgram.y:2998
+#: awkgram.y:3003
msgid "use of `\\ #...' line continuation is not portable"
msgstr ""
"Die Verwendung von »\\#...« zur Fortsetzung von Zeilen ist nicht portabel"
-#: awkgram.y:3014
+#: awkgram.y:3019
msgid "backslash not last character on line"
msgstr "das letzte Zeichen auf der Zeile ist kein Backslash (»\\«)"
-#: awkgram.y:3075
+#: awkgram.y:3080
msgid "POSIX does not allow operator `**='"
msgstr "POSIX erlaubt den Operator »**=« nicht"
-#: awkgram.y:3077
+#: awkgram.y:3082
msgid "old awk does not support operator `**='"
msgstr "Das alte awk unterstützt den Operator »**=« nicht"
-#: awkgram.y:3086
+#: awkgram.y:3091
msgid "POSIX does not allow operator `**'"
msgstr "POSIX erlaubt den Operator »**« nicht"
-#: awkgram.y:3088
+#: awkgram.y:3093
msgid "old awk does not support operator `**'"
msgstr "Das alte awk unterstützt den Operator »**« nicht"
-#: awkgram.y:3123
+#: awkgram.y:3128
msgid "operator `^=' is not supported in old awk"
msgstr "Das alte awk unterstützt den Operator »^=« nicht"
-#: awkgram.y:3131
+#: awkgram.y:3136
msgid "operator `^' is not supported in old awk"
msgstr "Das alte awk unterstützt den Operator »^« nicht"
-#: awkgram.y:3224 awkgram.y:3240
+#: awkgram.y:3229 awkgram.y:3245
msgid "unterminated string"
msgstr "Nicht beendete Zeichenkette"
-#: awkgram.y:3436
+#: awkgram.y:3466
#, c-format
msgid "invalid char '%c' in expression"
msgstr "Ungültiges Zeichen »%c« in einem Ausdruck"
-#: awkgram.y:3483
+#: awkgram.y:3513
#, c-format
msgid "`%s' is a gawk extension"
msgstr "»%s« ist eine gawk-Erweiterung"
-#: awkgram.y:3488
+#: awkgram.y:3518
#, c-format
msgid "`%s' is a Bell Labs extension"
msgstr "»%s« ist eine Erweiterung der Bell Labs"
-#: awkgram.y:3493
+#: awkgram.y:3523
#, c-format
msgid "POSIX does not allow `%s'"
msgstr "POSIX erlaubt »%s« nicht"
-#: awkgram.y:3501
+#: awkgram.y:3531
#, c-format
msgid "`%s' is not supported in old awk"
msgstr "»%s« wird im alten awk nicht unterstützt"
-#: awkgram.y:3568
+#: awkgram.y:3598
msgid "`goto' considered harmful!\n"
msgstr "»goto« gilt als schlechter Stil!\n"
-#: awkgram.y:3619
+#: awkgram.y:3632
#, c-format
msgid "%d is invalid as number of arguments for %s"
msgstr "Unzulässige Argumentzahl %d für %s"
-#: awkgram.y:3654
+#: awkgram.y:3667
#, c-format
msgid "%s: string literal as last arg of substitute has no effect"
msgstr "%s: Ein String als letztes Argument von substitute hat keinen Effekt"
-#: awkgram.y:3659
+#: awkgram.y:3672
#, c-format
msgid "%s third parameter is not a changeable object"
msgstr "Der dritte Parameter von %s ist ein unveränderliches Objekt"
-#: awkgram.y:3732 awkgram.y:3735
+#: awkgram.y:3751 awkgram.y:3754
msgid "match: third argument is a gawk extension"
msgstr "match: Das dritte Argument ist eine gawk-Erweiterung"
-#: awkgram.y:3789 awkgram.y:3792
+#: awkgram.y:3808 awkgram.y:3811
msgid "close: second argument is a gawk extension"
msgstr "close: Das zweite Argument ist eine gawk-Erweiterung"
-#: awkgram.y:3804
+#: awkgram.y:3823
msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore"
msgstr ""
"Fehlerhafte Verwendung von dcgettext(_\"...\"): \n"
"Entfernen Sie den führenden Unterstrich"
-#: awkgram.y:3819
+#: awkgram.y:3838
msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore"
msgstr ""
"Fehlerhafte Verwendung von dcngettext(_\"...\"): \n"
"Entfernen Sie den führenden Unterstrich"
-#: awkgram.y:3911
-#, c-format
-msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
-msgstr "Funktion »%s«: Parameter #%d, »%s« wiederholt Parameter #%d"
-
-#: awkgram.y:3953
+#: awkgram.y:3904
#, c-format
msgid "function `%s': parameter `%s' shadows global variable"
msgstr "Funktion »%s«: Parameter »%s« verdeckt eine globale Variable"
-#: awkgram.y:4111
+#: awkgram.y:3961
#, c-format
msgid "could not open `%s' for writing (%s)"
msgstr "»%s« kann nicht zum Schreiben geöffne werden(%s)"
-#: awkgram.y:4112
+#: awkgram.y:3962
msgid "sending variable list to standard error"
msgstr "Die Liste der Variablen wird auf der Standardfehlerausgabe ausgegeben"
-#: awkgram.y:4118
+#: awkgram.y:3970
#, c-format
msgid "%s: close failed (%s)"
msgstr "%s: close ist gescheitert (%s)"
-#: awkgram.y:4170
+#: awkgram.y:3995
msgid "shadow_funcs() called twice!"
msgstr "shadow_funcs() zweimal aufgerufen!"
-#: awkgram.y:4176
+#: awkgram.y:4003
msgid "there were shadowed variables."
msgstr "es sind verdeckte Variablen vorhanden"
-#: awkgram.y:4206
+#: awkgram.y:4074
+#, c-format
+msgid "function name `%s' previously defined"
+msgstr "Funktion »%s« wurde bereits definiert"
+
+#: awkgram.y:4120
#, c-format
msgid "function `%s': can't use function name as parameter name"
msgstr "Funktion »%s«: Funktionsnamen können nicht als Parameternamen benutzen"
-#: awkgram.y:4210
+#: awkgram.y:4123
#, c-format
msgid "function `%s': can't use special variable `%s' as a function parameter"
msgstr ""
"Funktion »%s«: die spezielle Variable »%s« kann nicht als Parameter "
"verwendet werden"
-#: awkgram.y:4226
+#: awkgram.y:4131
#, c-format
-msgid "function name `%s' previously defined"
-msgstr "Funktion »%s« wurde bereits definiert"
+msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
+msgstr "Funktion »%s«: Parameter #%d, »%s« wiederholt Parameter #%d"
-#: awkgram.y:4394 awkgram.y:4400
+#: awkgram.y:4210 awkgram.y:4216
#, c-format
msgid "function `%s' called but never defined"
msgstr "Aufgerufene Funktion »%s« ist nirgends definiert"
-#: awkgram.y:4403
+#: awkgram.y:4219
#, c-format
msgid "function `%s' defined but never called directly"
msgstr "Funktion »%s« wurde definiert aber nirgends aufgerufen"
-#: awkgram.y:4435
+#: awkgram.y:4251
#, c-format
msgid "regexp constant for parameter #%d yields boolean value"
msgstr ""
"Regulärer-Ausdruck-Konstante für Parameter #%d ergibt einen \n"
"logischen Wert"
-#: awkgram.y:4544
+#: awkgram.y:4297
#, c-format
msgid ""
"function `%s' called with space between name and `(',\n"
@@ -544,233 +501,233 @@ msgstr ""
"Funktion »%s« wird mit Leerzeichen zwischen Name und »(« aufgerufen, \n"
"oder als Variable oder Feld verwendet"
-#: awkgram.y:4791 eval.c:2056
+#: awkgram.y:4505
msgid "division by zero attempted"
msgstr "Division durch Null wurde versucht"
-#: awkgram.y:4800 eval.c:2072
+#: awkgram.y:4514
#, c-format
msgid "division by zero attempted in `%%'"
msgstr "Division durch Null versucht in »%%«"
-#: builtin.c:120
+#: builtin.c:122
#, c-format
msgid "%s to \"%s\" failed (%s)"
msgstr "%s to \"%s\" fehlgeschlagen (%s)"
-#: builtin.c:121
+#: builtin.c:123
msgid "standard output"
msgstr "Standardausgabe"
-#: builtin.c:135
+#: builtin.c:137
msgid "exp: received non-numeric argument"
msgstr "exp: das Argument ist keine Zahl"
-#: builtin.c:141
+#: builtin.c:143
#, c-format
msgid "exp: argument %g is out of range"
msgstr "exp: das Argument %g liegt außerhalb des gültigen Bereichs"
-#: builtin.c:200
+#: builtin.c:202
#, c-format
msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing"
msgstr ""
"fflush: Leeren der Puffer nicht möglich, Pipe »%s« ist nur zum Lesen geöffnet"
-#: builtin.c:203
+#: builtin.c:205
#, c-format
msgid "fflush: cannot flush: file `%s' opened for reading, not writing"
msgstr ""
"fflush: Leeren der Puffer nicht möglich, Datei »%s« ist nur zum Lesen "
"geöffnet"
-#: builtin.c:215
+#: builtin.c:217
#, c-format
msgid "fflush: `%s' is not an open file, pipe or co-process"
msgstr "fflush: »%s« ist keine geöffnete Datei, Pipe oder Prozess"
-#: builtin.c:333
+#: builtin.c:335
msgid "index: received non-string first argument"
msgstr "index: Erstes Argument ist kein String"
-#: builtin.c:335
+#: builtin.c:337
msgid "index: received non-string second argument"
msgstr "index: Zweites Argument ist kein string"
-#: builtin.c:457
+#: builtin.c:461
msgid "int: received non-numeric argument"
msgstr "Argument ist keine Zahl"
-#: builtin.c:493
+#: builtin.c:497
msgid "length: received array argument"
msgstr "length: Argument ist ein Feld"
-#: builtin.c:496
+#: builtin.c:500
msgid "`length(array)' is a gawk extension"
msgstr "»length(array)« ist eine gawk-Erweiterung"
-#: builtin.c:504
+#: builtin.c:508
msgid "length: received non-string argument"
msgstr "length: Argument ist kein String"
-#: builtin.c:535
+#: builtin.c:539
msgid "log: received non-numeric argument"
msgstr "log: Argument ist keine Zahl"
-#: builtin.c:538
+#: builtin.c:542
#, c-format
msgid "log: received negative argument %g"
msgstr "log: Negatives Argument %g"
-#: builtin.c:694 builtin.c:699
+#: builtin.c:740 builtin.c:745
msgid "fatal: must use `count$' on all formats or none"
msgstr "Fatal: »count$« muss auf alle Formate angewandt werden oder auf keines"
-#: builtin.c:762
+#: builtin.c:815
#, c-format
msgid "field width is ignored for `%%' specifier"
msgstr "Feldbreite wird für die »%%«-Angabe ignoriert"
-#: builtin.c:764
+#: builtin.c:817
#, c-format
msgid "precision is ignored for `%%' specifier"
msgstr "Genauigkeit wird für die »%%«-Angabe ignoriert"
-#: builtin.c:766
+#: builtin.c:819
#, c-format
msgid "field width and precision are ignored for `%%' specifier"
msgstr "Feldbreite und Genauigkeit werden für die »%%«-Angabe ignoriert"
-#: builtin.c:817
+#: builtin.c:870
msgid "fatal: `$' is not permitted in awk formats"
msgstr "Fatal: »$« ist in awk-Formaten nicht zulässig"
-#: builtin.c:826
+#: builtin.c:879
msgid "fatal: arg count with `$' must be > 0"
msgstr "Fatal: die Anzahl der Argumen bei »$« muss > 0 sein"
-#: builtin.c:830
+#: builtin.c:883
#, c-format
msgid "fatal: arg count %ld greater than total number of supplied arguments"
msgstr ""
"Fatal: Argumentenanzahl %ld ist größer als die Gesamtzahl angegebener "
"Argumente"
-#: builtin.c:834
+#: builtin.c:887
msgid "fatal: `$' not permitted after period in format"
msgstr "Fatal: »$« nach Punkt in Formatangabe nicht zulässig"
-#: builtin.c:850
+#: builtin.c:903
msgid "fatal: no `$' supplied for positional field width or precision"
msgstr "Fatal: »$« fehlt in positionsabhängiger Feldbreite oder Genauigkeit"
#
-#: builtin.c:921
+#: builtin.c:975
msgid "`l' is meaningless in awk formats; ignored"
msgstr "»l« ist in awk-Formaten bedeutungslos, ignoriert"
-#: builtin.c:925
+#: builtin.c:979
msgid "fatal: `l' is not permitted in POSIX awk formats"
msgstr "Fatal: »l« ist in POSIX-awk-Formaten nicht zulässig"
-#: builtin.c:938
+#: builtin.c:992
msgid "`L' is meaningless in awk formats; ignored"
msgstr "»L« ist in awk-Formaten bedeutungslos, ignoriert"
-#: builtin.c:942
+#: builtin.c:996
msgid "fatal: `L' is not permitted in POSIX awk formats"
msgstr "Fatal: »L« ist in POSIX-awk-Formaten nicht zulässig"
-#: builtin.c:955
+#: builtin.c:1009
msgid "`h' is meaningless in awk formats; ignored"
msgstr "»h« ist in awk-Formaten bedeutungslos, ignoriert"
-#: builtin.c:959
+#: builtin.c:1013
msgid "fatal: `h' is not permitted in POSIX awk formats"
msgstr "Fatal: »h« ist in POSIX-awk-Formaten nicht zulässig"
-#: builtin.c:1272
+#: builtin.c:1408
#, c-format
msgid "[s]printf: value %g is out of range for `%%%c' format"
msgstr "[s]printf: Wert %g ist außerhalb des Bereichs für Format »%%%c«"
-#: builtin.c:1332
+#: builtin.c:1506
#, c-format
msgid "ignoring unknown format specifier character `%c': no argument converted"
msgstr ""
"das unbekannte Zeichen »%c« in der Formatspezifikation wird ignoriert: keine "
"Argumente umgewandelt"
-#: builtin.c:1337
+#: builtin.c:1511
msgid "fatal: not enough arguments to satisfy format string"
msgstr "Fatal: Nicht genügend Argumente für die Formatangabe"
-#: builtin.c:1339
+#: builtin.c:1513
msgid "^ ran out for this one"
msgstr "^ hierfür fehlte es"
-#: builtin.c:1346
+#: builtin.c:1520
msgid "[s]printf: format specifier does not have control letter"
msgstr "[s]printf: Format-Spezifikation hat keinen Controlcode"
-#: builtin.c:1349
+#: builtin.c:1523
msgid "too many arguments supplied for format string"
msgstr "Zu viele Argumente für den Formatstring"
-#: builtin.c:1423 builtin.c:1434
+#: builtin.c:1598 builtin.c:1609
msgid "printf: no arguments"
msgstr "printf: Keine Argumente"
-#: builtin.c:1475
+#: builtin.c:1650
msgid "sqrt: received non-numeric argument"
msgstr "sqrt: das Argument ist keine Zahl"
-#: builtin.c:1479
+#: builtin.c:1654
#, c-format
msgid "sqrt: called with negative argument %g"
msgstr "sqrt: das Argument %g ist negativ"
-#: builtin.c:1503
+#: builtin.c:1685
#, c-format
msgid "substr: length %g is not >= 1"
msgstr "substr: Länge %g ist nicht >= 1"
-#: builtin.c:1505
+#: builtin.c:1687
#, c-format
msgid "substr: length %g is not >= 0"
msgstr "substr: Länge %g ist nicht >= 0"
-#: builtin.c:1512
+#: builtin.c:1694
#, c-format
msgid "substr: non-integer length %g will be truncated"
msgstr "substr: Nicht ganzzahlige Länge %g wird abgeschnitten"
-#: builtin.c:1517
+#: builtin.c:1699
#, c-format
msgid "substr: length %g too big for string indexing, truncating to %g"
msgstr ""
"substr: Länge %g ist zu groß für Stringindizierung, wird auf %g gekürzt"
-#: builtin.c:1529
+#: builtin.c:1711
#, c-format
msgid "substr: start index %g is invalid, using 1"
msgstr "substr: Start-Index %g ist ungültig, 1 wird verwendet"
-#: builtin.c:1534
+#: builtin.c:1716
#, c-format
msgid "substr: non-integer start index %g will be truncated"
msgstr "substr: Nicht ganzzahliger Start-Wert %g wird abgeschnitten"
-#: builtin.c:1559
+#: builtin.c:1741
msgid "substr: source string is zero length"
msgstr "substr: Quellstring ist leer"
-#: builtin.c:1575
+#: builtin.c:1757
#, c-format
msgid "substr: start index %g is past end of string"
msgstr "substr: Start-Wert %g liegt hinter dem Ende des Strings"
-#: builtin.c:1583
+#: builtin.c:1765
#, c-format
msgid ""
"substr: length %g at start index %g exceeds length of first argument (%lu)"
@@ -778,235 +735,230 @@ msgstr ""
"substr: Länge %g am Start-Wert %g überschreitet die Länge des ersten "
"Arguments (%lu)"
-#: builtin.c:1657
+#: builtin.c:1839
msgid "strftime: format value in PROCINFO[\"strftime\"] has numeric type"
msgstr "strftime: Formatwert in PROCINFO[\"strftime\"] ist numerischen Typs"
-#: builtin.c:1680
+#: builtin.c:1862
msgid "strftime: received non-numeric second argument"
msgstr "strftime: Das zweite Argument ist keine Zahl"
-#: builtin.c:1683
+#: builtin.c:1866
msgid "strftime: second argument less than 0 or too big for time_t"
msgstr ""
"strftime: das zweite Argument ist kleiner als 0 oder zu groß für time_t"
-#: builtin.c:1690
+#: builtin.c:1873
msgid "strftime: received non-string first argument"
msgstr "strftime: Das erste Argument ist kein String"
-#: builtin.c:1696
+#: builtin.c:1880
msgid "strftime: received empty format string"
msgstr "strftime: Der Format-String ist leer"
-#: builtin.c:1762
+#: builtin.c:1946
msgid "mktime: received non-string argument"
msgstr "mktime: Das Argument ist kein String"
-#: builtin.c:1779
+#: builtin.c:1963
msgid "mktime: at least one of the values is out of the default range"
msgstr "mktime: mindestens einer der Werte ist außerhalb des normalen Bereichs"
-#: builtin.c:1814
+#: builtin.c:1998
msgid "'system' function not allowed in sandbox mode"
msgstr "Die Funktion »system« ist im Sandbox-Modus nicht erlaubt"
-#: builtin.c:1819
+#: builtin.c:2003
msgid "system: received non-string argument"
msgstr "system: Das Argument ist kein String"
-#: builtin.c:1874 eval.c:1159 eval.c:1790 eval.c:1803
-#, c-format
-msgid "reference to uninitialized variable `%s'"
-msgstr "Referenz auf die nicht initialisierte Variable »%s«"
-
-#: builtin.c:1941
+#: builtin.c:2121
#, c-format
msgid "reference to uninitialized field `$%d'"
msgstr "Referenz auf das nicht initialisierte Feld »$%d«"
-#: builtin.c:2028
+#: builtin.c:2208
msgid "tolower: received non-string argument"
msgstr "tolower: das Argument ist kein String"
-#: builtin.c:2062
+#: builtin.c:2242
msgid "toupper: received non-string argument"
msgstr "toupper: das Argument ist kein String"
-#: builtin.c:2098
+#: builtin.c:2278
msgid "atan2: received non-numeric first argument"
msgstr "atan2: das erste Argument ist keine Zahl"
-#: builtin.c:2100
+#: builtin.c:2280
msgid "atan2: received non-numeric second argument"
msgstr "atan2: das zweite Argument ist keine Zahl"
-#: builtin.c:2119
+#: builtin.c:2299
msgid "sin: received non-numeric argument"
msgstr "sin: das Argument ist keine Zahl"
-#: builtin.c:2135
+#: builtin.c:2315
msgid "cos: received non-numeric argument"
msgstr "cos: das Argument ist keine Zahl"
-#: builtin.c:2188
+#: builtin.c:2368
msgid "srand: received non-numeric argument"
msgstr "srand: das Argument ist keine Zahl"
-#: builtin.c:2219
+#: builtin.c:2399
msgid "match: third argument is not an array"
msgstr "match: das dritte Argument ist kein Array"
-#: builtin.c:2483
+#: builtin.c:2664
msgid "gensub: third argument of 0 treated as 1"
msgstr "gensub: 0 als drittes Argument wird als 1 interpretiert"
-#: builtin.c:2776
+#: builtin.c:2957
msgid "lshift: received non-numeric first argument"
msgstr "lshift: das erste Argument ist keine Zahl"
-#: builtin.c:2778
+#: builtin.c:2959
msgid "lshift: received non-numeric second argument"
msgstr "lshift: das zweite Argument ist keine Zahl"
-#: builtin.c:2784
+#: builtin.c:2965
#, c-format
msgid "lshift(%lf, %lf): negative values will give strange results"
msgstr ""
"lshift(%lf, %lf): Negative Werte werden zu merkwürdigen Ergebnissen führen"
-#: builtin.c:2786
+#: builtin.c:2967
#, c-format
msgid "lshift(%lf, %lf): fractional values will be truncated"
msgstr "lshift(%lf, %lf): Dezimalteil wird abgeschnitten"
-#: builtin.c:2788
+#: builtin.c:2969
#, c-format
msgid "lshift(%lf, %lf): too large shift value will give strange results"
msgstr ""
"lshift(%lf, %lf): Zu große Shift-Werte werden zu merkwürdigen Ergebnissen "
"führen"
-#: builtin.c:2813
+#: builtin.c:2994
msgid "rshift: received non-numeric first argument"
msgstr "rshift: das erste Argument ist keine Zahl"
-#: builtin.c:2815
+#: builtin.c:2996
msgid "rshift: received non-numeric second argument"
msgstr "rshift: das zweite Argument ist keine Zahl"
-#: builtin.c:2821
+#: builtin.c:3002
#, c-format
msgid "rshift(%lf, %lf): negative values will give strange results"
msgstr ""
"rshift (%lf, %lf): Negative Werte werden zu merkwürdigen Ergebnissen führen"
-#: builtin.c:2823
+#: builtin.c:3004
#, c-format
msgid "rshift(%lf, %lf): fractional values will be truncated"
msgstr "rshift(%lf, %lf): Dezimalteil wird abgeschnitten"
-#: builtin.c:2825
+#: builtin.c:3006
#, c-format
msgid "rshift(%lf, %lf): too large shift value will give strange results"
msgstr ""
"rshift(%lf, %lf): Zu große Shift-Werte werden zu merkwürdigen Ergebnissen "
"führen"
-#: builtin.c:2850
+#: builtin.c:3031
msgid "and: received non-numeric first argument"
msgstr "and: das erste Argument ist keine Zahl"
-#: builtin.c:2852
+#: builtin.c:3033
msgid "and: received non-numeric second argument"
msgstr "and: das zweite Argument ist keine Zahl"
-#: builtin.c:2858
+#: builtin.c:3039
#, c-format
msgid "and(%lf, %lf): negative values will give strange results"
msgstr ""
"and(%lf, %lf): Negative Werte werden zu merkwürdigen Ergebnissen führen"
-#: builtin.c:2860
+#: builtin.c:3041
#, c-format
msgid "and(%lf, %lf): fractional values will be truncated"
msgstr "and(%lf, %lf): Dezimalteil wird abgeschnitten"
-#: builtin.c:2885
+#: builtin.c:3066
msgid "or: received non-numeric first argument"
msgstr "or: das erste Argument ist keine Zahl"
-#: builtin.c:2887
+#: builtin.c:3068
msgid "or: received non-numeric second argument"
msgstr "or: das zweite Argument ist keine Zahl"
-#: builtin.c:2893
+#: builtin.c:3074
#, c-format
msgid "or(%lf, %lf): negative values will give strange results"
msgstr "or(%lf, %lf): Negative Werte werden zu merkwürdigen Ergebnissen führen"
-#: builtin.c:2895
+#: builtin.c:3076
#, c-format
msgid "or(%lf, %lf): fractional values will be truncated"
msgstr "or(%lf, %lf): Dezimalteil wird abgeschnitten"
-#: builtin.c:2923
+#: builtin.c:3102
msgid "xor: received non-numeric first argument"
msgstr "xor: das erste Argument ist keine Zahl"
-#: builtin.c:2925
+#: builtin.c:3104
msgid "xor: received non-numeric second argument"
msgstr "xor: das zweite Argument ist keine Zahl"
-#: builtin.c:2931
+#: builtin.c:3110
#, c-format
msgid "xor(%lf, %lf): negative values will give strange results"
msgstr "xor(%lf, %lf: Negative Werte werden zu merkwürdigen Ergebnissen führen"
-#: builtin.c:2933
+#: builtin.c:3112
#, c-format
msgid "xor(%lf, %lf): fractional values will be truncated"
msgstr "xor(%lf, %lf): Dezimalteil wird abgeschnitten"
-#: builtin.c:2957 builtin.c:2963
+#: builtin.c:3136
msgid "compl: received non-numeric argument"
msgstr "compl: das erste Argument ist keine Zahl"
-#: builtin.c:2965
+#: builtin.c:3142
#, c-format
msgid "compl(%lf): negative value will give strange results"
msgstr "compl(%lf): Negativer Wert wird zu merkwürdigen Ergebnissen führen"
-#: builtin.c:2967
+#: builtin.c:3144
#, c-format
msgid "compl(%lf): fractional value will be truncated"
msgstr "compl(%lf): Dezimalteil wird abgeschnitten"
-#: builtin.c:3136
+#: builtin.c:3313
#, c-format
msgid "dcgettext: `%s' is not a valid locale category"
msgstr "dcgettext: »%s« ist keine gültige Locale-Kategorie"
-#: eval.c:412
+#: eval.c:395
#, c-format
msgid "unknown nodetype %d"
msgstr "Unbekannter Knotentyp %d"
-#: eval.c:423 eval.c:437
+#: eval.c:406 eval.c:420
#, c-format
msgid "unknown opcode %d"
msgstr "Unbekannter Opcode %d"
-#: eval.c:434
+#: eval.c:417
#, c-format
msgid "opcode %s not an operator or keyword"
msgstr "Opcode %s ist weder ein Operator noch ein Schlüsselwort"
-#: eval.c:488
+#: eval.c:472
msgid "buffer overflow in genflags2str"
msgstr "Pufferüberlauf in genflags2str"
-#: eval.c:698
+#: eval.c:675
#, c-format
msgid ""
"\n"
@@ -1017,316 +969,259 @@ msgstr ""
"\t# Funktions-Aufruf-Stack\n"
"\n"
-#: eval.c:725
+#: eval.c:704
msgid "`IGNORECASE' is a gawk extension"
msgstr "»IGNORECASE« ist eine gawk-Erweiterung"
-#: eval.c:754
+#: eval.c:736
msgid "`BINMODE' is a gawk extension"
msgstr "»BINMODE« ist eine gawk-Erweiterung"
-#: eval.c:812
+#: eval.c:793
#, c-format
msgid "BINMODE value `%s' is invalid, treated as 3"
msgstr "BINMODE Wert »%s« ist ungültig und wird als 3 behandelt"
-#: eval.c:902
+#: eval.c:885
#, c-format
msgid "bad `%sFMT' specification `%s'"
msgstr "Falsche »%sFMT«-Angabe »%s«"
-#: eval.c:980
+#: eval.c:969
msgid "turning off `--lint' due to assignment to `LINT'"
msgstr "»--lint« wird abgeschaltet, da an »LINT« zugewiesen wird"
-#: eval.c:1127 eval.c:1777
-#, c-format
-msgid "can't use function name `%s' as variable or array"
-msgstr "Funktion »%s« kann nicht als Variable oder Feld verwendet werden"
-
-#: eval.c:1158 eval.c:1789 eval.c:1802
+#: eval.c:1132
#, c-format
msgid "reference to uninitialized argument `%s'"
msgstr "Referenz auf nicht initialisiertes Argument »%s«"
-#: eval.c:1177
+#: eval.c:1133
+#, c-format
+msgid "reference to uninitialized variable `%s'"
+msgstr "Referenz auf die nicht initialisierte Variable »%s«"
+
+#: eval.c:1151
msgid "attempt to field reference from non-numeric value"
msgstr "Nicht numerischer Wert für Feldreferenz verwendet"
-#: eval.c:1179
+#: eval.c:1153
msgid "attempt to field reference from null string"
msgstr "Referenz auf ein Feld von einem Null-String"
-#: eval.c:1185
+#: eval.c:1161
#, c-format
msgid "attempt to access field %ld"
msgstr "Versuch des Zugriffs auf Feld %ld"
-#: eval.c:1194
+#: eval.c:1170
#, c-format
msgid "reference to uninitialized field `$%ld'"
msgstr "Referenz auf das nicht initialisierte Feld »$%ld«"
-#: eval.c:1256
+#: eval.c:1257
#, c-format
msgid "function `%s' called with more arguments than declared"
msgstr "Funktion »%s« mit zu vielen Argumenten aufgerufen"
-#: eval.c:1437
+#: eval.c:1452
#, c-format
msgid "unwind_stack: unexpected type `%s'"
msgstr "unwind_stack: unerwarteter Typ »%s«"
-#: eval.c:1532
+#: eval.c:1546
msgid "division by zero attempted in `/='"
msgstr "Division durch Null versucht in »/=«"
-#: eval.c:1539
+#: eval.c:1553
#, c-format
msgid "division by zero attempted in `%%='"
msgstr "Division durch Null versucht in »%%=«"
-#: eval.c:1876 eval.c:2122
-#, c-format
-msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
-msgstr ""
-"Es wird versucht, das Feld »%s[\"%.*s\"]« in einem Skalarkontext zu verwenden"
-
-#: eval.c:1907
-msgid "assignment used in conditional context"
-msgstr "Zuweisung in einer Bedingung"
-
-#: eval.c:1911
-msgid "statement has no effect"
-msgstr "Anweisung hat keinen Effekt"
-
-#: eval.c:2343
-#, c-format
-msgid "for loop: array `%s' changed size from %ld to %ld during loop execution"
-msgstr ""
-"for-Schleife: Feld »%s« ändert seine Größe von %ld innerhalb der Schleife zu "
-"%ld"
-
-#: eval.c:2458
-#, c-format
-msgid "function called indirectly through `%s' does not exist"
-msgstr "die durch »%s« indirekt aufgerufene Funktion existiert nicht"
-
-#: eval.c:2470
-#, c-format
-msgid "function `%s' not defined"
-msgstr "Funktion »%s« ist nicht definiert"
-
-#: eval.c:2511
-#, c-format
-msgid "non-redirected `getline' invalid inside `%s' rule"
-msgstr "Nicht umgelenktes »getline« ist innerhalb der »%s«-Aktion unzuässig"
-
-#: eval.c:2600
-#, c-format
-msgid "error reading input file `%s': %s"
-msgstr "Fehler beim Lesen der Eingabedatei »%s«: %s"
-
-#: eval.c:2614
-#, c-format
-msgid "`nextfile' cannot be called from a `%s' rule"
-msgstr "»nextfile« kann nicht aus einer »«%s-Regel aufgerufen werden"
-
-#: eval.c:2661
-msgid "`exit' cannot be called in the current context"
-msgstr "»exit« kann im aktuellen Kontext nicht aufgerufen werden"
-
-#: eval.c:2700
-#, c-format
-msgid "`next' cannot be called from a `%s' rule"
-msgstr "»next« kann nicht in einer »%s«-Regel verwendet werden"
-
-#: eval.c:2766
-#, c-format
-msgid "Sorry, don't know how to interpret `%s'"
-msgstr "Entschuldigung, aber es ist unbekannt, wie »%s« zu interpretieren ist"
-
-#: ext.c:54
+#: ext.c:70
msgid "extensions are not allowed in sandbox mode"
msgstr "Erweiterungen sind im Sandbox-Modus nicht erlaubt"
-#: ext.c:60 ext.c:65
+#: ext.c:73
msgid "`extension' is a gawk extension"
msgstr "»extension« ist eine gawk-Erweiterung"
-#: ext.c:75
-#, c-format
-msgid "fatal: extension: cannot open `%s' (%s)\n"
+#: ext.c:80
+#, fuzzy, c-format
+msgid "extension: cannot open library `%s' (%s)\n"
msgstr "Fatal: extension: »%s« kann nicht geöffnet werden (%s)\n"
-#: ext.c:84
-#, c-format
+#: ext.c:86
+#, fuzzy, c-format
msgid ""
-"fatal: extension: library `%s': does not define "
-"`plugin_is_GPL_compatible' (%s)\n"
+"extension: library `%s': does not define `plugin_is_GPL_compatible' (%s)\n"
msgstr ""
"Fatal: Erweiterung: Bibliothek »%s«: definiert »plugin_is_GPL_compatible« "
"nicht (%s)\n"
-#: ext.c:93
-#, c-format
-msgid "fatal: extension: library `%s': cannot call function `%s' (%s)\n"
+#: ext.c:90
+#, fuzzy, c-format
+msgid "extension: library `%s': cannot call function `%s' (%s)\n"
msgstr ""
"Fatal: Erweiterung: Bibliothek »%s«: Funktion »%s« kann nicht aufgerufen "
"werden (%s)\n"
-#: ext.c:127
+#: ext.c:118
msgid "extension: missing function name"
msgstr "Erweiterung: Funktionsname fehlt"
-#: ext.c:132
+#: ext.c:123
#, c-format
msgid "extension: illegal character `%c' in function name `%s'"
msgstr "Erweiterung: unzulässiges Zeichen »%c« in Funktionsname »%s«"
-#: ext.c:141
+#: ext.c:131
#, c-format
msgid "extension: can't redefine function `%s'"
msgstr "Erweiterung: Funktion »%s« kann nicht neu definiert werden"
-#: ext.c:145
+#: ext.c:135
#, c-format
msgid "extension: function `%s' already defined"
msgstr "Erweiterung: Funktion »%s« wurde bereits definiert"
-#: ext.c:150
+#: ext.c:139
#, c-format
msgid "extension: function name `%s' previously defined"
msgstr "Erweiterung: Funktion »%s« wurde bereits vorher definiert"
-#: ext.c:152
+#: ext.c:141
#, c-format
msgid "extension: can't use gawk built-in `%s' as function name"
msgstr ""
"Erweiterung: die eingebaute Funktion »%s« kann nicht als Funktionsname "
"verwendet werden"
-#: ext.c:156
+#: ext.c:144
#, c-format
msgid "make_builtin: negative argument count for function `%s'"
msgstr "make_builtin: negative Anzahl von Argumenten für Funktion »%s«"
-#: ext.c:259
+#: ext.c:206
#, c-format
msgid "function `%s' defined to take no more than %d argument(s)"
msgstr ""
"Funktion »%s« wird als Funktion definiert, die nie mehr als %d Argument(e) "
"akzeptiert"
-#: ext.c:262
+#: ext.c:209
#, c-format
msgid "function `%s': missing argument #%d"
msgstr "Funktion »%s«: fehlendes Argument #%d"
-#: ext.c:279
+#: ext.c:226
#, c-format
msgid "function `%s': argument #%d: attempt to use scalar as an array"
msgstr ""
"Funktion »%s«: Argument #%d: Es wird versucht, einen Skalar als Feld zu "
"verwenden"
-#: ext.c:283
+#: ext.c:230
#, c-format
msgid "function `%s': argument #%d: attempt to use array as a scalar"
msgstr ""
"Funktion »%s«: Argument #%d: Es wird versucht, ein Feld als Skalar zu "
"verwenden"
-#: ext.c:296
+#: ext.c:244
msgid "Operation Not Supported"
msgstr "Die Operation wird nicht unterstützt"
-#: field.c:328
+#: ext.c:256
+msgid "dynamic loading of library not supported"
+msgstr ""
+
+#: field.c:339
msgid "NF set to negative value"
msgstr "NF wird ein negativer Wert zugewiesen"
-#: field.c:951 field.c:958 field.c:962
+#: field.c:962 field.c:969 field.c:973
msgid "split: fourth argument is a gawk extension"
msgstr "split: das vierte Argument ist eine gawk-Erweiterung"
-#: field.c:955
+#: field.c:966
msgid "split: fourth argument is not an array"
msgstr "split: das vierte Argument ist kein Feld"
-#: field.c:969
+#: field.c:980
msgid "split: second argument is not an array"
msgstr "split: das zweite Argument ist kein Feld"
-#: field.c:973
+#: field.c:984
msgid "split: cannot use the same array for second and fourth args"
msgstr ""
"split: als zweites und viertes Argument kann nicht das gleiche Feld "
"verwendet werden"
-#: field.c:978
+#: field.c:989
msgid "split: cannot use a subarray of second arg for fourth arg"
msgstr ""
"split: Ein untergeordnetes Feld des zweiten Arguments kann nicht als viertes "
"Argument verwendet werden"
-#: field.c:981
+#: field.c:992
msgid "split: cannot use a subarray of fourth arg for second arg"
msgstr ""
"split: Ein untergeordnetes Feld des vierten Arguments kann nicht als zweites "
"Argument verwendet werden"
-#: field.c:1010
+#: field.c:1021
msgid "split: null string for third arg is a gawk extension"
msgstr "split: Null-String als drittes Argument ist eine gawk-Erweiterung"
-#: field.c:1050
+#: field.c:1061
msgid "patsplit: fourth argument is not an array"
msgstr "patsplit: Das vierte Argument ist kein Feld"
-#: field.c:1055
+#: field.c:1066
msgid "patsplit: second argument is not an array"
msgstr "patsplit: Das zweite Argument ist kein Feld"
-#: field.c:1061
+#: field.c:1072
msgid "patsplit: third argument must be non-null"
msgstr "patsplit: Das dritte Argument darf nicht Null sein"
-#: field.c:1065
+#: field.c:1076
msgid "patsplit: cannot use the same array for second and fourth args"
msgstr ""
"patsplit: als zweites und viertes Argument kann nicht das gleiche Feld "
"verwendet werden"
-#: field.c:1070
+#: field.c:1081
msgid "patsplit: cannot use a subarray of second arg for fourth arg"
msgstr ""
"patsplit: Ein untergeordnetes Feld des zweiten Arguments kann nicht als "
"viertes Argument verwendet werden"
-#: field.c:1073
+#: field.c:1084
msgid "patsplit: cannot use a subarray of fourth arg for second arg"
msgstr ""
"patsplit: Ein untergeordnetes Feld des vierten Arguments kann nicht als "
"zweites Argument verwendet werden"
-#: field.c:1110
+#: field.c:1122
msgid "`FIELDWIDTHS' is a gawk extension"
msgstr "»FIELDWIDTHS« ist eine gawk-Erweiterung"
-#: field.c:1173
+#: field.c:1186
#, c-format
msgid "invalid FIELDWIDTHS value, near `%s'"
msgstr "ungültiger FIELDWIDTHS-Wert nah bei »%s«"
-#: field.c:1246
+#: field.c:1259
msgid "null string for `FS' is a gawk extension"
msgstr "Null-String für »FS« ist eine gawk-Erweiterung"
-#: field.c:1250
+#: field.c:1263
msgid "old awk does not support regexps as value of `FS'"
msgstr "Das alte awk unterstützt keine regulären Ausdrücke als Wert von »FS«"
-#: field.c:1369
+#: field.c:1382
msgid "`FPAT' is a gawk extension"
msgstr "»FPAT« ist eine gawk-Erweiterung"
@@ -1385,479 +1280,494 @@ msgstr "%s: Die Option »-W %s« hat keine Argumente\n"
msgid "%s: option '-W %s' requires an argument\n"
msgstr "%s: Die Option »-W %s« erfordert ein Argument\n"
-#: io.c:280
+#: io.c:326
#, c-format
msgid "command line argument `%s' is a directory: skipped"
msgstr ""
"das Kommandozeilen-Argument »%s« ist ein Verzeichnis: wird übersprungen"
-#: io.c:283 io.c:385
+#: io.c:329 io.c:438
#, c-format
msgid "cannot open file `%s' for reading (%s)"
msgstr "Die Datei »%s« kann nicht zum Lesen geöffnet werden (%s)"
-#: io.c:501
+#: io.c:568
#, c-format
msgid "close of fd %d (`%s') failed (%s)"
msgstr "Das Schließen des Dateideskriptors %d (»%s«) ist gescheitert (%s)"
-#: io.c:578
+#: io.c:645
msgid "redirection not allowed in sandbox mode"
msgstr "Umlenkungen sind im Sandbox-Modus nicht erlaubt"
-#: io.c:612
+#: io.c:679
#, c-format
msgid "expression in `%s' redirection only has numeric value"
msgstr ""
"Der Ausdruck in einer Umlenkung mittels »%s« hat nur einen numerischen Wert"
-#: io.c:618
+#: io.c:685
#, c-format
msgid "expression for `%s' redirection has null string value"
msgstr "Der Ausdruck für eine Umlenkung mittels »%s« ist ein leerer String"
-#: io.c:623
+#: io.c:690
#, c-format
msgid "filename `%s' for `%s' redirection may be result of logical expression"
msgstr ""
"Der Dateiname »%s« für eine Umlenkung mittels »%s« kann das Ergebnis eines "
"logischen Ausdrucks sein"
-#: io.c:666
+#: io.c:733
#, c-format
msgid "unnecessary mixing of `>' and `>>' for file `%.*s'"
msgstr "Unnötige Kombination von »>« und »>>« für Datei »%.*s«"
-#: io.c:719
+#: io.c:786
#, c-format
msgid "can't open pipe `%s' for output (%s)"
msgstr "Die Pipe »%s« kann nicht für die Ausgabe geöffnet werden (%s)"
-#: io.c:729
+#: io.c:796
#, c-format
msgid "can't open pipe `%s' for input (%s)"
msgstr "Die Pipe »%s« kann nicht für die Eingabe geöffnet werden (%s)"
-#: io.c:752
+#: io.c:819
#, c-format
msgid "can't open two way pipe `%s' for input/output (%s)"
msgstr ""
"Die bidirektionale Pipe »%s« kann nicht für die Ein-/Ausgabe geöffnet werden "
"(%s)"
-#: io.c:834
+#: io.c:900
#, c-format
msgid "can't redirect from `%s' (%s)"
msgstr "Von »%s« kann nicht umgelenkt werden (%s)"
-#: io.c:837
+#: io.c:903
#, c-format
msgid "can't redirect to `%s' (%s)"
msgstr "Zu »%s« kann nicht umgelenkt werden (%s)"
-#: io.c:888
+#: io.c:954
msgid ""
"reached system limit for open files: starting to multiplex file descriptors"
msgstr ""
"Die Systemgrenze offener Dateien ist erreicht, daher werden nun "
"Dateideskriptoren mehrfach verwendet"
-#: io.c:904
+#: io.c:970
#, c-format
msgid "close of `%s' failed (%s)."
msgstr "Das Schließen von »%s« ist gescheitert (%s)."
-#: io.c:912
+#: io.c:978
msgid "too many pipes or input files open"
msgstr "Zu viele Pipes oder Eingabedateien offen"
-#: io.c:934
+#: io.c:1000
msgid "close: second argument must be `to' or `from'"
msgstr "close: Das zweite Argument muss »to« oder »from« sein"
-#: io.c:951
+#: io.c:1017
#, c-format
msgid "close: `%.*s' is not an open file, pipe or co-process"
msgstr "close: »%.*s« ist weder offene Datei, noch Pipe oder Ko-Prozess"
-#: io.c:956
+#: io.c:1022
msgid "close of redirection that was never opened"
msgstr "»close« für eine Umlenkung, die nie geöffnet wurde"
-#: io.c:1053
+#: io.c:1120
#, c-format
msgid "close: redirection `%s' not opened with `|&', second argument ignored"
msgstr ""
"close: Umlenkung »%s« wurde nicht mit »[&« geöffnet, das zweite Argument "
"wird ignoriert"
-#: io.c:1069
+#: io.c:1137
#, c-format
msgid "failure status (%d) on pipe close of `%s' (%s)"
msgstr "Fehlerstatus (%d) beim Schließen der Pipe »%s« (%s)"
-#: io.c:1072
+#: io.c:1140
#, c-format
msgid "failure status (%d) on file close of `%s' (%s)"
msgstr "Fehlerstatus (%d) beim Schließen der Datei »%s« (%s)"
-#: io.c:1092
+#: io.c:1160
#, c-format
msgid "no explicit close of socket `%s' provided"
msgstr "Das explizite Schließen des Sockets »%s« fehlt"
-#: io.c:1095
+#: io.c:1163
#, c-format
msgid "no explicit close of co-process `%s' provided"
msgstr "Das explizite Schließen des Ko-Prozesses »%s« fehlt"
-#: io.c:1098
+#: io.c:1166
#, c-format
msgid "no explicit close of pipe `%s' provided"
msgstr "Das explizite Schließen der Pipe »%s« fehlt"
-#: io.c:1101
+#: io.c:1169
#, c-format
msgid "no explicit close of file `%s' provided"
msgstr "Das explizite Schließen der Datei »%s« fehlt"
-#: io.c:1129 io.c:1184 main.c:794 main.c:831
+#: io.c:1197 io.c:1252 main.c:825 main.c:862
#, c-format
msgid "error writing standard output (%s)"
msgstr "Fehler beim Schreiben auf die Standardausgabe (%s)"
-#: io.c:1133 io.c:1189
+#: io.c:1201 io.c:1257
#, c-format
msgid "error writing standard error (%s)"
msgstr "Fehler beim Schreiben auf die Standardfehlerausgabe (%s)"
-#: io.c:1141
+#: io.c:1209
#, c-format
msgid "pipe flush of `%s' failed (%s)."
msgstr "Das Leeren der Pipe »%s« ist gescheitert (%s)"
-#: io.c:1144
+#: io.c:1212
#, c-format
msgid "co-process flush of pipe to `%s' failed (%s)."
msgstr "Ko-Prozess: Das Leeren der Pipe zu »%s« ist gescheitert (%s)"
-#: io.c:1147
+#: io.c:1215
#, c-format
msgid "file flush of `%s' failed (%s)."
msgstr "Das Leeren der Datei »%s« ist gescheitert (%s)"
-#: io.c:1262
+#: io.c:1329
#, c-format
msgid "local port %s invalid in `/inet'"
msgstr "Der lokale Port »%s« ist ungültig in »/inet«"
-#: io.c:1279
+#: io.c:1347
#, c-format
msgid "remote host and port information (%s, %s) invalid"
msgstr "Die Angaben zu entferntem Host und Port (%s, %s) sind ungültig"
-#: io.c:1431
+#: io.c:1499
#, c-format
msgid "no (known) protocol supplied in special filename `%s'"
msgstr "Es wurde kein (bekanntes) Protokoll im Dateinamen »%s« angegeben"
-#: io.c:1445
+#: io.c:1513
#, c-format
msgid "special file name `%s' is incomplete"
msgstr "Der Dateiname »%s« ist unvollständig"
-#: io.c:1462
+#: io.c:1530
msgid "must supply a remote hostname to `/inet'"
msgstr "Sie müssen in /inet einen Rechnernamen angeben"
-#: io.c:1480
+#: io.c:1548
msgid "must supply a remote port to `/inet'"
msgstr "Sie müssen in »/inet« einen Port angeben"
-#: io.c:1526
+#: io.c:1594
msgid "TCP/IP communications are not supported"
msgstr "TCP/IP-Verbindungen werden nicht unterstützt"
-#: io.c:1693
+#: io.c:1764
#, c-format
msgid "could not open `%s', mode `%s'"
msgstr "»%s« konnte nicht geöffnet werden, Modus »%s«"
-#: io.c:1747
+#: io.c:1814
#, c-format
msgid "close of master pty failed (%s)"
msgstr ""
"Das Schließen der übergeordneten Terminal-Gerätedatei ist gescheitert (%s)"
-#: io.c:1749 io.c:1917 io.c:2074
+#: io.c:1816 io.c:1984 io.c:2145
#, c-format
msgid "close of stdout in child failed (%s)"
msgstr "Das Schließen der Standardausgabe im Kindprozess ist gescheitert (%s)"
-#: io.c:1752
+#: io.c:1819
#, c-format
msgid "moving slave pty to stdout in child failed (dup: %s)"
msgstr ""
"Das Verschieben der untergeordneten Terminal-Gerätedatei zur Standardausgabe "
"im Kindprozess ist gescheitert (dup: %s)"
-#: io.c:1754 io.c:1922
+#: io.c:1821 io.c:1989
#, c-format
msgid "close of stdin in child failed (%s)"
msgstr "Schließen von stdin im Kindprozess gescheitert (%s)"
-#: io.c:1757
+#: io.c:1824
#, c-format
msgid "moving slave pty to stdin in child failed (dup: %s)"
msgstr ""
"Das Verschieben der untergeordneten Terminal-Gerätedatei zur Standardeingabe "
"im Kindprozess ist gescheitert (dup: %s)"
-#: io.c:1759 io.c:1780
+#: io.c:1826 io.c:1847
#, c-format
msgid "close of slave pty failed (%s)"
msgstr ""
"Das Schließen der untergeordneten Terminal-Gerätedatei ist gescheitert (%s)"
-#: io.c:1858 io.c:1920 io.c:2052 io.c:2077
+#: io.c:1925 io.c:1987 io.c:2122 io.c:2148
#, c-format
msgid "moving pipe to stdout in child failed (dup: %s)"
msgstr ""
"Das Verschieben der Pipe zur Standardausgabe im Kindprozess ist gescheitert "
"(dup: %s)"
-#: io.c:1865 io.c:1925
+#: io.c:1932 io.c:1992
#, c-format
msgid "moving pipe to stdin in child failed (dup: %s)"
msgstr ""
"Das Verschieben der Pipe zur Standardeingabe im Kindprozess ist gescheitert "
"(dup: %s)"
-#: io.c:1885 io.c:2067
+#: io.c:1952 io.c:2138
msgid "restoring stdout in parent process failed\n"
msgstr ""
"Das Wiederherstellen der Standardausgabe im Elternprozess ist gescheitert\n"
-#: io.c:1893
+#: io.c:1960
msgid "restoring stdin in parent process failed\n"
msgstr ""
"Das Wiederherstellen der Standardeingabe im Elternprozess ist gescheitert\n"
-#: io.c:1928 io.c:2079 io.c:2093
+#: io.c:1995 io.c:2150 io.c:2164
#, c-format
msgid "close of pipe failed (%s)"
msgstr "Das Schließen der Pipe ist gescheitert (%s)"
-#: io.c:1973
+#: io.c:2040
msgid "`|&' not supported"
msgstr "»|&« wird nicht unterstützt"
-#: io.c:2039
+#: io.c:2107
#, c-format
msgid "cannot open pipe `%s' (%s)"
msgstr "Pipe »%s« kann nicht geöffnet werden (%s)"
-#: io.c:2087
+#: io.c:2158
#, c-format
msgid "cannot create child process for `%s' (fork: %s)"
msgstr "Kindprozess für »%s« kann nicht erzeugt werden (fork: %s)"
-#: io.c:2520
+#: io.c:2637
#, c-format
msgid "data file `%s' is empty"
msgstr "Die Datei »%s« ist leer"
-#: io.c:2561 io.c:2569
+#: io.c:2678 io.c:2686
msgid "could not allocate more input memory"
msgstr "Es konnte kein weiterer Speicher für die Eingabe beschafft werden"
-#: io.c:3127
+#: io.c:3236
msgid "multicharacter value of `RS' is a gawk extension"
msgstr "Multicharacter-Wert von »RS« ist eine gawk-Erweiterung"
-#: io.c:3232
+#: io.c:3326
msgid "IPv6 communication is not supported"
msgstr "IPv6-Verbindungen werden nicht unterstützt"
-#: main.c:366
+#: main.c:355
msgid "`-m[fr]' option irrelevant in gawk"
msgstr "Die Option »-m[fr]« ist in gawk bedeutungslos"
-#: main.c:368
+#: main.c:357
msgid "-m option usage: `-m[fr] nnn'"
msgstr "Anwendung der Option -m: »-m[fr] nnn«"
-#: main.c:391
+#: main.c:386
msgid "empty argument to `-e/--source' ignored"
msgstr "Das leere Argument für »--source« wird ignoriert"
-#: main.c:462
+#: main.c:472
#, c-format
msgid "%s: option `-W %s' unrecognized, ignored\n"
msgstr "%s: Die Option »-W %s« ist unbekannt und wird ignoriert\n"
-#: main.c:515
+#: main.c:518
#, c-format
msgid "%s: option requires an argument -- %c\n"
msgstr "%s: Die Option %c erfordert ein Argument\n"
-#: main.c:536
+#: main.c:539
msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'"
msgstr ""
"Die Umgebungsvariable »POSIXLY_CORRECT« ist gesetzt: »--posix« wird "
"eingeschaltet"
-#: main.c:542
+#: main.c:545
msgid "`--posix' overrides `--traditional'"
msgstr "»--posix« hat Vorrang vor »--traditional«"
-#: main.c:553
+#: main.c:556
msgid "`--posix'/`--traditional' overrides `--non-decimal-data'"
msgstr "»--posix« /»--traditional« hat Vorrang vor »--non-decimal-data«"
-#: main.c:557
+#: main.c:560
#, c-format
msgid "running %s setuid root may be a security problem"
msgstr "%s als setuid root auszuführen kann zu Sicherheitsproblemen führen"
-#: main.c:562
+#: main.c:565
msgid "`--posix' overrides `--binary'"
msgstr "»--posix« hat Vorrang vor »--binary«"
-#: main.c:613
+#: main.c:623
#, c-format
msgid "can't set binary mode on stdin (%s)"
msgstr ""
"Das Setzen des Binärermodus für die Standardeingabe ist nicht möglich (%s)"
-#: main.c:616
+#: main.c:626
#, c-format
msgid "can't set binary mode on stdout (%s)"
msgstr ""
"Das Setzen des Binärermodus für die Standardausgabe ist nicht möglich (%s)"
-#: main.c:618
+#: main.c:628
#, c-format
msgid "can't set binary mode on stderr (%s)"
msgstr ""
"Das Setzen des Binärermodus für die Standardfehlerausgabe ist nicht möglich "
"(%s)"
-#: main.c:657
+#: main.c:679
msgid "no program text at all!"
msgstr "Es wurde überhaupt kein Programmtext angegeben!"
-#: main.c:734
+#: main.c:763
#, c-format
msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n"
msgstr "Aufruf: %s [POSIX- oder GNU-Optionen] -f PROGRAMM [--] Datei ...\n"
-#: main.c:736
+#: main.c:765
#, c-format
msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n"
msgstr "Aufruf: %s [POSIX- oder GNU-Optionen] -- %cPROGRAMM%c Datei ...\n"
-#: main.c:741
+#: main.c:770
msgid "POSIX options:\t\tGNU long options: (standard)\n"
msgstr "POSIX-Optionen\t\tlange GNU-Optionen: (standard)\n"
-#: main.c:742
+#: main.c:771
msgid "\t-f progfile\t\t--file=progfile\n"
msgstr "\t-f PROGRAMM\t\t--file=PROGRAMM\n"
-#: main.c:743
+#: main.c:772
msgid "\t-F fs\t\t\t--field-separator=fs\n"
msgstr "\t-F Feldtrenner\t\t\t--field-separator=Feldtrenner\n"
-#: main.c:744
+#: main.c:773
msgid "\t-v var=val\t\t--assign=var=val\n"
msgstr "\t-v var=Wert\t\t--assign=var=Wert\n"
-#: main.c:745
+#: main.c:774
msgid "Short options:\t\tGNU long options: (extensions)\n"
msgstr "POSIX-Optionen\t\tGNU-Optionen (lang): (Erweiterungen)\n"
-#: main.c:746
+#: main.c:775
msgid "\t-b\t\t\t--characters-as-bytes\n"
msgstr "\t-b\t\t\t--characters-as-bytes\n"
-#: main.c:747
+#: main.c:776
msgid "\t-c\t\t\t--traditional\n"
msgstr "\t-c\t\t\t--traditional\n"
-#: main.c:748
+#: main.c:777
msgid "\t-C\t\t\t--copyright\n"
msgstr "\t-C\t\t\t--copyright\n"
-#: main.c:749
+#: main.c:778
msgid "\t-d[file]\t\t--dump-variables[=file]\n"
msgstr "\t-d [Datei]\t\t--dump-variables[=Datei]\n"
-#: main.c:750
+#: main.c:779
+#, fuzzy
+msgid "\t-D[file]\t\t--debug[=file]\n"
+msgstr "\t-p [Datei]\t\t--profile[=Datei]\n"
+
+#: main.c:780
msgid "\t-e 'program-text'\t--source='program-text'\n"
msgstr "\t-e 'Programmtext'\t--source=Programmtext\n"
-#: main.c:751
+#: main.c:781
msgid "\t-E file\t\t\t--exec=file\n"
msgstr "\t-E Datei\t\t\t--exec=Datei\n"
-#: main.c:752
+#: main.c:782
msgid "\t-g\t\t\t--gen-pot\n"
msgstr "\t-g\t\t\t--gen-pot\n"
-#: main.c:753
+#: main.c:783
msgid "\t-h\t\t\t--help\n"
msgstr "\t-h\t\t\t--help\n"
-#: main.c:754
+#: main.c:784
+msgid "\t-l library\t\t--load=library\n"
+msgstr ""
+
+#: main.c:785
msgid "\t-L [fatal]\t\t--lint[=fatal]\n"
msgstr "\t-L [fatal]\t\t--lint[=fatal]\n"
-#: main.c:755
+#: main.c:786
msgid "\t-n\t\t\t--non-decimal-data\n"
msgstr "\t-n\t\t\t--non-decimal-data\n"
-#: main.c:756
+#: main.c:787
+#, fuzzy
+msgid "\t-M\t\t\t--bignum\n"
+msgstr "\t-g\t\t\t--gen-pot\n"
+
+#: main.c:788
msgid "\t-N\t\t\t--use-lc-numeric\n"
msgstr "\t-N\t\t\t--use-lc-numeric\n"
-#: main.c:757
+#: main.c:789
+#, fuzzy
+msgid "\t-o[file]\t\t--pretty-print[=file]\n"
+msgstr "\t-p [Datei]\t\t--profile[=Datei]\n"
+
+#: main.c:790
msgid "\t-O\t\t\t--optimize\n"
msgstr "\t-O\t\t\t--optimize\n"
-#: main.c:758
+#: main.c:791
msgid "\t-p[file]\t\t--profile[=file]\n"
msgstr "\t-p [Datei]\t\t--profile[=Datei]\n"
-#: main.c:759
+#: main.c:792
msgid "\t-P\t\t\t--posix\n"
msgstr "\t-P\t\t\t--posix\n"
-#: main.c:760
+#: main.c:793
msgid "\t-r\t\t\t--re-interval\n"
msgstr "\t-r\t\t\t--re-interval\n"
-#: main.c:762
-msgid "\t-R file\t\t\t--command=file\n"
-msgstr "\t-R Datei\t\t\t--command=Datei\n"
-
-#: main.c:763
+#: main.c:794
msgid "\t-S\t\t\t--sandbox\n"
msgstr "\t-S\t\t\t--sandbox\n"
-#: main.c:764
+#: main.c:795
msgid "\t-t\t\t\t--lint-old\n"
msgstr "\t-t\t\t\t--lint-old\n"
-#: main.c:765
+#: main.c:796
msgid "\t-V\t\t\t--version\n"
msgstr "\t-V\t\t\t--version\n"
-#: main.c:767
+#: main.c:798
msgid "\t-W nostalgia\t\t--nostalgia\n"
msgstr "\t-W nostalgia\t\t--nostalgia\n"
-#: main.c:770
+#: main.c:801
msgid "\t-Y\t\t--parsedebug\n"
msgstr "\t-Y\t\t--parsedebug\n"
@@ -1866,7 +1776,7 @@ msgstr "\t-Y\t\t--parsedebug\n"
#. for this application. Please add _another line_ with the
#. address for translation bugs.
#. no-wrap
-#: main.c:779
+#: main.c:810
msgid ""
"\n"
"To report bugs, see node `Bugs' in `gawk.info', which is\n"
@@ -1882,7 +1792,7 @@ msgstr ""
"an translation-team-de@lists.sourceforge.net\n"
"\n"
-#: main.c:783
+#: main.c:814
msgid ""
"gawk is a pattern scanning and processing language.\n"
"By default it reads standard input and writes standard output.\n"
@@ -1893,7 +1803,7 @@ msgstr ""
"auf der Standardausgabe aus.\n"
"\n"
-#: main.c:787
+#: main.c:818
msgid ""
"Examples:\n"
"\tgawk '{ sum += $1 }; END { print sum }' file\n"
@@ -1903,7 +1813,7 @@ msgstr ""
"\tgawk '{ sum += $1 }; END { print sum }' file\n"
"\tgawk -F: '{ print $1 }' /etc/passwd\n"
-#: main.c:807
+#: main.c:838
#, c-format
msgid ""
"Copyright (C) 1989, 1991-%d Free Software Foundation.\n"
@@ -1923,7 +1833,7 @@ msgstr ""
"spätere Version.\n"
"\n"
-#: main.c:815
+#: main.c:846
msgid ""
"This program is distributed in the hope that it will be useful,\n"
"but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
@@ -1936,7 +1846,7 @@ msgstr ""
"leistung einer HANDELBARKEIT oder der EIGNUNG FÜR EINEN BESTIMMTEN ZWECK.\n"
"Sehen Sie bitte die GNU General Public License für weitere Details.\n"
-#: main.c:821
+#: main.c:852
msgid ""
"You should have received a copy of the GNU General Public License\n"
"along with this program. If not, see http://www.gnu.org/licenses/.\n"
@@ -1945,16 +1855,16 @@ msgstr ""
"diesem Programm erhalten haben. Wenn nicht, lesen Sie bitte\n"
"http://www.gnu.org/licenses/.\n"
-#: main.c:856
+#: main.c:887
msgid "-Ft does not set FS to tab in POSIX awk"
msgstr "-Ft setzt FS im POSIX-awk nicht auf Tab"
-#: main.c:1090
+#: main.c:1133
#, c-format
msgid "unknown value for field spec: %d\n"
msgstr "unbekannter Wert für eine Feldangabe: %d\n"
-#: main.c:1171
+#: main.c:1214
#, c-format
msgid ""
"%s: `%s' argument to `-v' not in `var=value' form\n"
@@ -1963,81 +1873,81 @@ msgstr ""
"%s: Argument »%s« von »-v« ist nicht in der Form »Variable=Wert«\n"
"\n"
-#: main.c:1197
+#: main.c:1240
#, c-format
msgid "`%s' is not a legal variable name"
msgstr "»%s« ist kein gültiger Variablenname"
-#: main.c:1200
+#: main.c:1243
#, c-format
msgid "`%s' is not a variable name, looking for file `%s=%s'"
msgstr "»%s« ist kein Variablenname, es wird nach der Datei »%s=%s« gesucht"
-#: main.c:1204
+#: main.c:1247
#, c-format
msgid "cannot use gawk builtin `%s' as variable name"
msgstr ""
"die eingebaute Funktion »%s« kann nicht als Variablenname verwendet werden"
# c-format
-#: main.c:1209
+#: main.c:1252
#, c-format
msgid "cannot use function `%s' as variable name"
msgstr "Funktion »%s« kann nicht als Name einer Variablen verwendet werden"
-#: main.c:1262
+#: main.c:1305
msgid "floating point exception"
msgstr "Fließkomma-Ausnahme"
-#: main.c:1269
+#: main.c:1312
msgid "fatal error: internal error"
msgstr "Fataler Fehler: interner Fehler"
-#: main.c:1284
+#: main.c:1327
msgid "fatal error: internal error: segfault"
msgstr "Fataler Fehler: interner Fehler: Speicherbegrenzungsfehler"
-#: main.c:1296
+#: main.c:1339
msgid "fatal error: internal error: stack overflow"
msgstr "Fataler Fehler: interner Fehler: Stapelüberlauf"
-#: main.c:1346
+#: main.c:1393
#, c-format
msgid "no pre-opened fd %d"
msgstr "Kein bereits geöffneter Dateideskriptor %d"
-#: main.c:1353
+#: main.c:1400
#, c-format
msgid "could not pre-open /dev/null for fd %d"
msgstr "/dev/null konnte nicht für Dateideskriptor %d geöffnet werden"
-#: msg.c:63
+#: msg.c:61
#, c-format
msgid "cmd. line:"
msgstr "Kommandozeile:"
-#: msg.c:107
+#: msg.c:121
msgid "error: "
msgstr "Fehler: "
-#: node.c:406
+#: node.c:436
msgid "backslash at end of string"
msgstr "Backslash am Ende der Zeichenkette"
-#: node.c:517
+#: node.c:520
#, c-format
msgid "old awk does not support the `\\%c' escape sequence"
msgstr "Das alte awk unterstützt die Fluchsequenz »\\%c« nicht"
-#: node.c:568
+#: node.c:571
msgid "POSIX does not allow `\\x' escapes"
msgstr "POSIX erlaubt keine »\\x«-Escapes"
-#: node.c:574
+#: node.c:577
msgid "no hex digits in `\\x' escape sequence"
msgstr "In der »\\x«-Fluchtsequenz sind keine hexadezimalen Zahlen"
-#: node.c:596
+#: node.c:599
#, c-format
msgid ""
"hex escape \\x%.*s of %d characters probably not interpreted the way you "
@@ -2046,12 +1956,12 @@ msgstr ""
"Die Hex-Sequenz \\x%.*s aus %d Zeichen wird wahrscheinlich nicht wie "
"gewünscht interpretiert"
-#: node.c:611
+#: node.c:614
#, c-format
msgid "escape sequence `\\%c' treated as plain `%c'"
msgstr "Fluchtsequenz »\\%c« wird wie ein normales »%c« behandelt"
-#: node.c:750
+#: node.c:759
msgid ""
"Invalid multibyte data detected. There may be a mismatch between your data "
"and your locale."
@@ -2072,16 +1982,16 @@ msgid "%s %s `%s': could not set close-on-exec: (fcntl F_SETFD: %s)"
msgstr ""
"%s %s »%s«: close-on-exec konnte nicht gesetzt werden: (fcntl F_SETFD: %s)"
-#: profile.c:83
+#: profile.c:69
#, c-format
msgid "could not open `%s' for writing: %s"
msgstr "»%s« konnte nicht zum Schreiben geöffnet werden: %s"
-#: profile.c:85
+#: profile.c:71
msgid "sending profile to standard error"
msgstr "Das Profil wird auf der Standardfehlerausgabe ausgegeben"
-#: profile.c:203
+#: profile.c:187
#, c-format
msgid ""
"\t# %s block(s)\n"
@@ -2090,7 +2000,7 @@ msgstr ""
"\t# %s Blöcke\n"
"\n"
-#: profile.c:208
+#: profile.c:192
#, c-format
msgid ""
"\t# Rule(s)\n"
@@ -2099,17 +2009,22 @@ msgstr ""
"\t# Regeln(s)\n"
"\n"
-#: profile.c:279
+#: profile.c:266
#, c-format
msgid "internal error: %s with null vname"
msgstr "Interner Fehler: %s mit null vname"
-#: profile.c:952
+#: profile.c:528
+#, fuzzy
+msgid "internal error: builtin with null fname"
+msgstr "Interner Fehler: %s mit null vname"
+
+#: profile.c:943
#, c-format
msgid "\t# gawk profile, created %s\n"
msgstr "\t# gawk-Profil, erzeugt %s\n"
-#: profile.c:1331
+#: profile.c:1328
#, c-format
msgid ""
"\n"
@@ -2118,18 +2033,18 @@ msgstr ""
"\n"
"\t# Funktionen in alphabetischer Reihenfolge\n"
-#: profile.c:1370
+#: profile.c:1366
#, c-format
msgid "redir2str: unknown redirection type %d"
msgstr "redir2str: unbekannter Umlenkungstyp %d"
-#: re.c:573
+#: re.c:571
#, c-format
msgid "range of the form `[%c-%c]' is locale dependent"
msgstr ""
"Ein Bereich in der Form »[%c-%c]« ist abhängig von der gesetzten Locale"
-#: re.c:600
+#: re.c:598
#, c-format
msgid "regexp component `%.*s' should probably be `[%.*s]'"
msgstr ""
@@ -2207,6 +2122,81 @@ msgstr ") oder \\) werden nicht geöffnet"
msgid "No previous regular expression"
msgstr "Kein vorangehender regulärer Ausdruck"
+#~ msgid "attempt to use function `%s' as an array"
+#~ msgstr "Es wird versucht, die Funktion »%s« als Feld zu verwenden"
+
+#~ msgid "reference to uninitialized element `%s[\"%.*s\"]'"
+#~ msgstr "Bezug auf ein nicht initialisiertes Element »%s[\"%.*s\"]«"
+
+#~ msgid "subscript of array `%s' is null string"
+#~ msgstr "Der Index von Feld »%s« ist ein Nullstring"
+
+#~ msgid "%s: empty (null)\n"
+#~ msgstr "%s: leer (Null)\n"
+
+#~ msgid "%s: empty (zero)\n"
+#~ msgstr "%s: leer (0)\n"
+
+#~ msgid "%s: table_size = %d, array_size = %d\n"
+#~ msgstr "%s: Tabellengröße = %d, Feldgröße = %d\n"
+
+#~ msgid "%s: is parameter\n"
+#~ msgstr "%s: ist ein Parameter\n"
+
+#~ msgid "%s: array_ref to %s\n"
+#~ msgstr "%s: Feld-Referenz auf %s\n"
+
+#~ msgid "use of non-array as array"
+#~ msgstr "Verwendung eines Nicht-Feldes als Feld"
+
+#~ msgid "can't use function name `%s' as variable or array"
+#~ msgstr "Funktion »%s« kann nicht als Variable oder Feld verwendet werden"
+
+#~ msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
+#~ msgstr ""
+#~ "Es wird versucht, das Feld »%s[\"%.*s\"]« in einem Skalarkontext zu "
+#~ "verwenden"
+
+#~ msgid "assignment used in conditional context"
+#~ msgstr "Zuweisung in einer Bedingung"
+
+#~ msgid "statement has no effect"
+#~ msgstr "Anweisung hat keinen Effekt"
+
+#~ msgid ""
+#~ "for loop: array `%s' changed size from %ld to %ld during loop execution"
+#~ msgstr ""
+#~ "for-Schleife: Feld »%s« ändert seine Größe von %ld innerhalb der Schleife "
+#~ "zu %ld"
+
+#~ msgid "function called indirectly through `%s' does not exist"
+#~ msgstr "die durch »%s« indirekt aufgerufene Funktion existiert nicht"
+
+#~ msgid "function `%s' not defined"
+#~ msgstr "Funktion »%s« ist nicht definiert"
+
+#~ msgid "non-redirected `getline' invalid inside `%s' rule"
+#~ msgstr "Nicht umgelenktes »getline« ist innerhalb der »%s«-Aktion unzuässig"
+
+#~ msgid "error reading input file `%s': %s"
+#~ msgstr "Fehler beim Lesen der Eingabedatei »%s«: %s"
+
+#~ msgid "`nextfile' cannot be called from a `%s' rule"
+#~ msgstr "»nextfile« kann nicht aus einer »«%s-Regel aufgerufen werden"
+
+#~ msgid "`exit' cannot be called in the current context"
+#~ msgstr "»exit« kann im aktuellen Kontext nicht aufgerufen werden"
+
+#~ msgid "`next' cannot be called from a `%s' rule"
+#~ msgstr "»next« kann nicht in einer »%s«-Regel verwendet werden"
+
+#~ msgid "Sorry, don't know how to interpret `%s'"
+#~ msgstr ""
+#~ "Entschuldigung, aber es ist unbekannt, wie »%s« zu interpretieren ist"
+
+#~ msgid "\t-R file\t\t\t--command=file\n"
+#~ msgstr "\t-R Datei\t\t\t--command=Datei\n"
+
#~ msgid "could not find groups: %s"
#~ msgstr "Die Gruppen konnten nicht gefunden werden: %s"
diff --git a/po/es.gmo b/po/es.gmo
index 54dd057c..ff97b5ad 100644
--- a/po/es.gmo
+++ b/po/es.gmo
Binary files differ
diff --git a/po/es.po b/po/es.po
index 6aeeeb75..1998136e 100644
--- a/po/es.po
+++ b/po/es.po
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: gawk 4.0.0h\n"
"Report-Msgid-Bugs-To: arnold@skeeve.com\n"
-"POT-Creation-Date: 2012-03-28 22:03+0200\n"
+"POT-Creation-Date: 2012-04-27 10:06+0300\n"
"PO-Revision-Date: 2012-01-30 07:42-0600\n"
"Last-Translator: Cristian Othón Martínez Vera <cfuga@cfuga.mx>\n"
"Language-Team: Spanish <es@li.org>\n"
@@ -16,519 +16,476 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-#: array.c:140
+#: array.c:266
#, c-format
msgid "from %s"
msgstr "desde %s"
-#: array.c:248
+#: array.c:366
msgid "attempt to use a scalar value as array"
msgstr "se intentó usar un valor escalar como una matriz"
-#: array.c:251
-#, c-format
-msgid "attempt to use function `%s' as an array"
-msgstr "se intentó usar la función `%s' como una matriz"
-
-#: array.c:254
+#: array.c:368
#, c-format
msgid "attempt to use scalar parameter `%s' as an array"
msgstr "se intentó usar el parámetro escalar `%s como una matriz'"
-#: array.c:257
+#: array.c:371
#, c-format
msgid "attempt to use scalar `%s' as an array"
msgstr "se intentó usar el escalar `%s' como una matriz"
-#: array.c:302 array.c:707 builtin.c:84 builtin.c:1385 builtin.c:1427
-#: builtin.c:1440 builtin.c:1859 builtin.c:1871 eval.c:1135 eval.c:1139
-#: eval.c:1495 eval.c:1812
+#: array.c:418 array.c:584 builtin.c:85 builtin.c:1560 builtin.c:1602
+#: builtin.c:1615 builtin.c:2041 builtin.c:2053 eval.c:1109 eval.c:1113
+#: eval.c:1508
#, c-format
msgid "attempt to use array `%s' in a scalar context"
msgstr "se intentó usar la matriz `%s' en un contexto escalar"
-#: array.c:513
-#, c-format
-msgid "reference to uninitialized element `%s[\"%.*s\"]'"
-msgstr "referencia al elemento sin inicializar `%s[\"%.*s\"]'"
-
-#: array.c:519
-#, c-format
-msgid "subscript of array `%s' is null string"
-msgstr "el subíndice de la matriz `%s' es la cadena nula"
-
-#: array.c:723
+#: array.c:591
#, c-format
msgid "delete: index `%s' not in array `%s'"
msgstr "delete: el índice `%s' no está en la matriz `%s'"
-#: array.c:734 eval.c:1865
+#: array.c:605
#, c-format
msgid "attempt to use scalar `%s[\"%.*s\"]' as an array"
msgstr "se intentó usar el dato escalar `%s[\"%.*s\"]' como una matriz"
-#: array.c:910
-#, c-format
-msgid "%s: empty (null)\n"
-msgstr "%s: vacío (nulo)\n"
-
-#: array.c:915
-#, c-format
-msgid "%s: empty (zero)\n"
-msgstr "%s: vacío (cero)\n"
-
-#: array.c:919
-#, c-format
-msgid "%s: table_size = %d, array_size = %d\n"
-msgstr "%s: tamaño_tabla = %d, tamaño_matriz = %d\n"
-
-#: array.c:954
-#, c-format
-msgid "%s: is parameter\n"
-msgstr "%s: es un parámetro\n"
-
-#: array.c:958
-#, c-format
-msgid "%s: array_ref to %s\n"
-msgstr "%s: array_ref a %s\n"
-
-#: array.c:963
-msgid "adump: argument not an array"
+#: array.c:784
+#, fuzzy
+msgid "adump: first argument not an array"
msgstr "adump: el argumento no es una matriz"
-#: array.c:1086
+#: array.c:823
msgid "asort: second argument not an array"
msgstr "asort: el segundo argumento no es una matriz"
-#: array.c:1087
+#: array.c:824
msgid "asorti: second argument not an array"
msgstr "asorti: el segundo argumento no es una matriz"
-#: array.c:1094
+#: array.c:831
msgid "asort: first argument not an array"
msgstr "asort: el primer argumento no es una matriz"
-#: array.c:1095
+#: array.c:832
msgid "asorti: first argument not an array"
msgstr "asorti: el primer argumento no es una matriz"
-#: array.c:1102
+#: array.c:839
msgid "asort: cannot use a subarray of first arg for second arg"
msgstr ""
"asort: no se puede usar una submatriz del primer argumento para el segundo "
"argumento"
-#: array.c:1103
+#: array.c:840
msgid "asorti: cannot use a subarray of first arg for second arg"
msgstr ""
"asorti: no se puede usar una submatriz del primer argumento para el segundo "
"argumento"
-#: array.c:1108
+#: array.c:845
msgid "asort: cannot use a subarray of second arg for first arg"
msgstr ""
"asort: no se puede usar una submatriz del segundo argumento para el primer "
"argumento"
-#: array.c:1109
+#: array.c:846
msgid "asorti: cannot use a subarray of second arg for first arg"
msgstr ""
"asorti: no se puede usar una submatriz del segundo argumento para el primer "
"argumento"
-#: array.c:1655
+#: array.c:1314
#, c-format
msgid "`%s' is invalid as a function name"
msgstr "`%s' es inválido como un nombre de función"
-#: array.c:1659
+#: array.c:1318
#, c-format
msgid "sort comparison function `%s' is not defined"
msgstr "la función de comparación de ordenamiento `%s' no está definida"
-#: awkgram.y:249
+#: awkgram.y:223
#, c-format
msgid "%s blocks must have an action part"
msgstr "los bloques %s deben tener una parte de acción"
-#: awkgram.y:252
+#: awkgram.y:226
msgid "each rule must have a pattern or an action part"
msgstr "cada regla debe tener un patrón o una parte de acción"
-#: awkgram.y:323 awkgram.y:334
+#: awkgram.y:295 awkgram.y:306
msgid "old awk does not support multiple `BEGIN' or `END' rules"
msgstr "el awk antiguo no admite múltiples reglas `BEGIN' o `END'"
-#: awkgram.y:371
+#: awkgram.y:343
#, c-format
msgid "`%s' is a built-in function, it cannot be redefined"
msgstr "`%s' es una función interna, no se puede redefinir"
-#: awkgram.y:432
+#: awkgram.y:389
msgid "regexp constant `//' looks like a C++ comment, but is not"
msgstr ""
"la constante de expresión regular `//' parece un comentario de C++, pero no "
"lo es"
-#: awkgram.y:436
+#: awkgram.y:393
#, c-format
msgid "regexp constant `/%s/' looks like a C comment, but is not"
msgstr ""
"la constante de expresión regular `/%s/' parece un comentario de C, pero no "
"lo es"
-#: awkgram.y:528
+#: awkgram.y:485
#, c-format
msgid "duplicate case values in switch body: %s"
msgstr "valores case duplicados en el cuerpo de un switch: %s"
-#: awkgram.y:549
+#: awkgram.y:506
msgid "duplicate `default' detected in switch body"
msgstr "se detectó un `default' duplicado en el cuerpo de un switch"
-#: awkgram.y:809
+#: awkgram.y:766
msgid "`break' is not allowed outside a loop or switch"
msgstr "no se permite `break' fuera de un bucle o switch"
-#: awkgram.y:818
+#: awkgram.y:775
msgid "`continue' is not allowed outside a loop"
msgstr "no se permite `continue' fuera de un bucle"
-#: awkgram.y:828
+#: awkgram.y:785
#, c-format
msgid "`next' used in %s action"
msgstr "se usó `next' en la acción %s"
-#: awkgram.y:836
+#: awkgram.y:793
msgid "`nextfile' is a gawk extension"
msgstr "`nextfile' es una extensión de gawk"
-#: awkgram.y:841
+#: awkgram.y:798
#, c-format
msgid "`nextfile' used in %s action"
msgstr "se usó `nextfile' en la acción %s"
-#: awkgram.y:865
+#: awkgram.y:822
msgid "`return' used outside function context"
msgstr "se usó `return' fuera del contexto de la función"
-#: awkgram.y:925
+#: awkgram.y:896
msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'"
msgstr ""
"el `print' simple en la regla BEGIN o END probablemente debe ser `print \"\"'"
-#: awkgram.y:995 awkgram.y:999 awkgram.y:1023
+#: awkgram.y:966 awkgram.y:970 awkgram.y:994
msgid "`delete array' is a gawk extension"
msgstr "`delete array' es una extensión de gawk"
-#: awkgram.y:1019
+#: awkgram.y:990
msgid "`delete(array)' is a non-portable tawk extension"
msgstr "`delete(array)' es una extensión de tawk que no es transportable"
-#: awkgram.y:1135
+#: awkgram.y:1108
msgid "multistage two-way pipelines don't work"
msgstr "las líneas de trabajo de dos vías multiestado no funcionan"
-#: awkgram.y:1238
+#: awkgram.y:1211
msgid "regular expression on right of assignment"
msgstr "expresión regular del lado derecho de una asignación"
-#: awkgram.y:1249
+#: awkgram.y:1222
msgid "regular expression on left of `~' or `!~' operator"
msgstr "expresión regular a la izquierda del operador `~' o `!~'"
-#: awkgram.y:1265 awkgram.y:1419
+#: awkgram.y:1238 awkgram.y:1389
msgid "old awk does not support the keyword `in' except after `for'"
msgstr ""
"el awk antiguo no admite la palabra clave `in' excepto después de `for'"
-#: awkgram.y:1275
+#: awkgram.y:1248
msgid "regular expression on right of comparison"
msgstr "expresión regular a la derecha de una comparación"
-#: awkgram.y:1394
+#: awkgram.y:1364
#, c-format
msgid "`getline var' invalid inside `%s' rule"
msgstr "`getline var' inválido dentro de la regla `%s'"
-#: awkgram.y:1397 eval.c:2504
+#: awkgram.y:1367
#, c-format
msgid "`getline' invalid inside `%s' rule"
msgstr "`getline' inválido dentro de la regla `%s'"
-#: awkgram.y:1402
+#: awkgram.y:1372
msgid "non-redirected `getline' undefined inside END action"
msgstr "`getline' no redirigido indefinido dentro de la acción de END"
-#: awkgram.y:1421
+#: awkgram.y:1391
msgid "old awk does not support multidimensional arrays"
msgstr "el awk antiguo no admite matrices multidimensionales"
-#: awkgram.y:1517
+#: awkgram.y:1488
msgid "call of `length' without parentheses is not portable"
msgstr "la llamada de `length' sin paréntesis no es transportable"
-#: awkgram.y:1580
+#: awkgram.y:1554
msgid "indirect function calls are a gawk extension"
msgstr "las llamadas indirectas a función son una extensión de gawk"
-#: awkgram.y:1593
+#: awkgram.y:1567
#, c-format
msgid "can not use special variable `%s' for indirect function call"
msgstr ""
"no se puede usar la variable especial `%s' como llamada indirecta a función"
-#: awkgram.y:1671
+#: awkgram.y:1645
msgid "invalid subscript expression"
msgstr "expresión de subíndice inválida"
-#: awkgram.y:1711
-msgid "use of non-array as array"
-msgstr "uso de una matriz que no es matriz"
-
-#: awkgram.y:1975 awkgram.y:1995 msg.c:98
+#: awkgram.y:1966 awkgram.y:1986 msg.c:112
msgid "warning: "
msgstr "aviso: "
-#: awkgram.y:1993 msg.c:130
+#: awkgram.y:1984 msg.c:144
msgid "fatal: "
msgstr "fatal: "
-#: awkgram.y:2043
+#: awkgram.y:2034
msgid "unexpected newline or end of string"
msgstr "nueva línea o fin de la cadena inesperados"
-#: awkgram.y:2300 awkgram.y:2358 awkgram.y:2542
+#: awkgram.y:2299 awkgram.y:2357 awkgram.y:2545
#, c-format
msgid "can't open source file `%s' for reading (%s)"
msgstr "no se puede abrir el fichero fuente `%s' para lectura (%s)"
-#: awkgram.y:2301 awkgram.y:2359 builtin.c:122
+#: awkgram.y:2300 awkgram.y:2358 builtin.c:124
msgid "reason unknown"
msgstr "razón desconocida"
-#: awkgram.y:2317
+#: awkgram.y:2316
#, c-format
msgid "already included source file `%s'"
msgstr "ya se incluyó el fichero fuente `%s'"
-#: awkgram.y:2343
+#: awkgram.y:2342
msgid "@include is a gawk extension"
msgstr "@include es una extensión de gawk"
-#: awkgram.y:2349
+#: awkgram.y:2348
msgid "empty filename after @include"
msgstr "nombre de fichero vacío después de @include"
-#: awkgram.y:2494
+#: awkgram.y:2497
msgid "empty program text on command line"
msgstr "texto de programa vacío en la linea de órdenes"
-#: awkgram.y:2609
+#: awkgram.y:2612
#, c-format
msgid "can't read sourcefile `%s' (%s)"
msgstr "no se puede leer el fichero fuente `%s' (%s)"
-#: awkgram.y:2620
+#: awkgram.y:2623
#, c-format
msgid "source file `%s' is empty"
msgstr "el fichero fuente `%s' está vacío"
-#: awkgram.y:2797
+#: awkgram.y:2800
msgid "source file does not end in newline"
msgstr "el fichero fuente no termina con línea nueva"
-#: awkgram.y:2900
+#: awkgram.y:2905
msgid "unterminated regexp ends with `\\' at end of file"
msgstr "expresión regular sin terminar termina con `\\` al final del fichero"
-#: awkgram.y:2924
+#: awkgram.y:2929
#, c-format
msgid "%s: %d: tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr ""
"%s: %d: el modificador de expresión regular `/.../%c` de tawk no funciona en "
"gawk"
-#: awkgram.y:2928
+#: awkgram.y:2933
#, c-format
msgid "tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr ""
"el modificador de expresión regular `/.../%c` de tawk no funciona en gawk"
-#: awkgram.y:2935
+#: awkgram.y:2940
msgid "unterminated regexp"
msgstr "expresión regular sin terminar"
-#: awkgram.y:2939
+#: awkgram.y:2944
msgid "unterminated regexp at end of file"
msgstr "expresión regular sin terminar al final del fichero"
-#: awkgram.y:2998
+#: awkgram.y:3003
msgid "use of `\\ #...' line continuation is not portable"
msgstr "el uso de la continuación de línea `\\ #...' no es transportable"
-#: awkgram.y:3014
+#: awkgram.y:3019
msgid "backslash not last character on line"
msgstr "la barra invertida no es el último caracter en la línea"
-#: awkgram.y:3075
+#: awkgram.y:3080
msgid "POSIX does not allow operator `**='"
msgstr "POSIX no permite el operador `**='"
-#: awkgram.y:3077
+#: awkgram.y:3082
msgid "old awk does not support operator `**='"
msgstr "el awk antiguo no admite el operador `**='"
-#: awkgram.y:3086
+#: awkgram.y:3091
msgid "POSIX does not allow operator `**'"
msgstr "POSIX no permite el operador `**'"
-#: awkgram.y:3088
+#: awkgram.y:3093
msgid "old awk does not support operator `**'"
msgstr "el awk antiguo no admite el operador `**='"
-#: awkgram.y:3123
+#: awkgram.y:3128
msgid "operator `^=' is not supported in old awk"
msgstr "el operador `^=' no se admite en el awk antiguo"
-#: awkgram.y:3131
+#: awkgram.y:3136
msgid "operator `^' is not supported in old awk"
msgstr "el operador `^' no se admite en el awk antiguo"
-#: awkgram.y:3224 awkgram.y:3240
+#: awkgram.y:3229 awkgram.y:3245
msgid "unterminated string"
msgstr "cadena sin terminar"
-#: awkgram.y:3436
+#: awkgram.y:3466
#, c-format
msgid "invalid char '%c' in expression"
msgstr "caracter '%c' inválido en la expresión"
-#: awkgram.y:3483
+#: awkgram.y:3513
#, c-format
msgid "`%s' is a gawk extension"
msgstr "`%s' es una extensión de gawk"
-#: awkgram.y:3488
+#: awkgram.y:3518
#, c-format
msgid "`%s' is a Bell Labs extension"
msgstr "`%s' es una extensión de Bell Labs"
-#: awkgram.y:3493
+#: awkgram.y:3523
#, c-format
msgid "POSIX does not allow `%s'"
msgstr "POSIX no permite `%s'"
-#: awkgram.y:3501
+#: awkgram.y:3531
#, c-format
msgid "`%s' is not supported in old awk"
msgstr "`%s' no se admite en el awk antiguo"
-#: awkgram.y:3568
+#: awkgram.y:3598
msgid "`goto' considered harmful!\n"
msgstr "¡`goto' se considera dañino!\n"
-#: awkgram.y:3619
+#: awkgram.y:3632
#, c-format
msgid "%d is invalid as number of arguments for %s"
msgstr "%d es inválido como número de argumentos para %s"
-#: awkgram.y:3654
+#: awkgram.y:3667
#, c-format
msgid "%s: string literal as last arg of substitute has no effect"
msgstr ""
"%s: la literal de cadena como último argumento de substitute no tiene efecto"
-#: awkgram.y:3659
+#: awkgram.y:3672
#, c-format
msgid "%s third parameter is not a changeable object"
msgstr "el tercer argumento de %s no es un objecto modificable"
-#: awkgram.y:3732 awkgram.y:3735
+#: awkgram.y:3751 awkgram.y:3754
msgid "match: third argument is a gawk extension"
msgstr "match: el tercer argumento es una extensión de gawk"
-#: awkgram.y:3789 awkgram.y:3792
+#: awkgram.y:3808 awkgram.y:3811
msgid "close: second argument is a gawk extension"
msgstr "close: el segundo argumento es una extensión de gawk"
-#: awkgram.y:3804
+#: awkgram.y:3823
msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore"
msgstr ""
"el uso de dcgettext(_\"...\") es incorrecto: quite el subrayado inicial"
-#: awkgram.y:3819
+#: awkgram.y:3838
msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore"
msgstr ""
"el uso de dcngettext(_\"...\") es incorrecto: quite el subrayado inicial"
-#: awkgram.y:3911
-#, c-format
-msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
-msgstr "función `%s': parámetro #%d, `%s', duplica el parámetro #%d"
-
-#: awkgram.y:3953
+#: awkgram.y:3904
#, c-format
msgid "function `%s': parameter `%s' shadows global variable"
msgstr "función `%s': parámetro `%s' oscurece la variable global"
-#: awkgram.y:4111
+#: awkgram.y:3961
#, c-format
msgid "could not open `%s' for writing (%s)"
msgstr "no se puede abrir `%s' para escritura (%s)"
-#: awkgram.y:4112
+#: awkgram.y:3962
msgid "sending variable list to standard error"
msgstr "se envía la lista de variables a la salida estándar de error"
-#: awkgram.y:4118
+#: awkgram.y:3970
#, c-format
msgid "%s: close failed (%s)"
msgstr "%s: falló close (%s)"
-#: awkgram.y:4170
+#: awkgram.y:3995
msgid "shadow_funcs() called twice!"
msgstr "¡se llamó shadow_funcs() dos veces!"
-#: awkgram.y:4176
+#: awkgram.y:4003
msgid "there were shadowed variables."
msgstr "hay variables opacadas."
-#: awkgram.y:4206
+#: awkgram.y:4074
+#, c-format
+msgid "function name `%s' previously defined"
+msgstr "el nombre de función `%s' se definió previamente"
+
+#: awkgram.y:4120
#, c-format
msgid "function `%s': can't use function name as parameter name"
msgstr ""
"función `%s': no se puede usar un nombre de función como nombre de parámetro"
-#: awkgram.y:4210
+#: awkgram.y:4123
#, c-format
msgid "function `%s': can't use special variable `%s' as a function parameter"
msgstr ""
"función `%s': no se puede usar la variable especial `%s' como un parámetro "
"de función"
-#: awkgram.y:4226
+#: awkgram.y:4131
#, c-format
-msgid "function name `%s' previously defined"
-msgstr "el nombre de función `%s' se definió previamente"
+msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
+msgstr "función `%s': parámetro #%d, `%s', duplica el parámetro #%d"
-#: awkgram.y:4394 awkgram.y:4400
+#: awkgram.y:4210 awkgram.y:4216
#, c-format
msgid "function `%s' called but never defined"
msgstr "se llamó a la función `%s' pero nunca se definió"
-#: awkgram.y:4403
+#: awkgram.y:4219
#, c-format
msgid "function `%s' defined but never called directly"
msgstr "se definió la función `%s' pero nunca se llamó directamente"
-#: awkgram.y:4435
+#: awkgram.y:4251
#, c-format
msgid "regexp constant for parameter #%d yields boolean value"
msgstr ""
"la constante de expresión regular para el parámetro #%d da un valor booleano"
-#: awkgram.y:4544
+#: awkgram.y:4297
#, c-format
msgid ""
"function `%s' called with space between name and `(',\n"
@@ -537,238 +494,238 @@ msgstr ""
"se llamó la función `%s' con espacio entre el nombre y el `(',\n"
"o se usó como una variable o una matriz"
-#: awkgram.y:4791 eval.c:2056
+#: awkgram.y:4505
msgid "division by zero attempted"
msgstr "se intentó una división por cero"
-#: awkgram.y:4800 eval.c:2072
+#: awkgram.y:4514
#, c-format
msgid "division by zero attempted in `%%'"
msgstr "se intentó una división por cero en `%%'"
-#: builtin.c:120
+#: builtin.c:122
#, c-format
msgid "%s to \"%s\" failed (%s)"
msgstr "falló %s a \"%s\" (%s)"
-#: builtin.c:121
+#: builtin.c:123
msgid "standard output"
msgstr "salida estándar"
-#: builtin.c:135
+#: builtin.c:137
msgid "exp: received non-numeric argument"
msgstr "exp: se recibió un argumento que no es númerico"
-#: builtin.c:141
+#: builtin.c:143
#, c-format
msgid "exp: argument %g is out of range"
msgstr "exp: el argumento %g está fuera de rango"
-#: builtin.c:200
+#: builtin.c:202
#, c-format
msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing"
msgstr ""
"fflush: no se puede limpiar: se abrió la tubería `%s' para lectura, no para "
"escritura"
-#: builtin.c:203
+#: builtin.c:205
#, c-format
msgid "fflush: cannot flush: file `%s' opened for reading, not writing"
msgstr ""
"fflush: no se puede limpiar: se abrió el fichero `%s' para lectura, no para "
"escritura"
-#: builtin.c:215
+#: builtin.c:217
#, c-format
msgid "fflush: `%s' is not an open file, pipe or co-process"
msgstr "fflush: `%s' no es un fichero abierto, tubería o co-proceso"
-#: builtin.c:333
+#: builtin.c:335
msgid "index: received non-string first argument"
msgstr "index: el primer argumento recibido no es una cadena"
-#: builtin.c:335
+#: builtin.c:337
msgid "index: received non-string second argument"
msgstr "index: el segundo argumento recibido no es una cadena"
-#: builtin.c:457
+#: builtin.c:461
msgid "int: received non-numeric argument"
msgstr "int: se recibió un argumento que no es númerico"
-#: builtin.c:493
+#: builtin.c:497
msgid "length: received array argument"
msgstr "length: se recibió un argumento de matriz"
-#: builtin.c:496
+#: builtin.c:500
msgid "`length(array)' is a gawk extension"
msgstr "`length(array)' es una extensión de gawk"
-#: builtin.c:504
+#: builtin.c:508
msgid "length: received non-string argument"
msgstr "length: se recibió un argumento que no es una cadena"
-#: builtin.c:535
+#: builtin.c:539
msgid "log: received non-numeric argument"
msgstr "log: se recibió un argumento que no es númerico"
-#: builtin.c:538
+#: builtin.c:542
#, c-format
msgid "log: received negative argument %g"
msgstr "log: se recibió el argumento negativo %g"
-#: builtin.c:694 builtin.c:699
+#: builtin.c:740 builtin.c:745
msgid "fatal: must use `count$' on all formats or none"
msgstr "fatal: se debe utilizar `count$' en todos los formatos o en ninguno"
-#: builtin.c:762
+#: builtin.c:815
#, c-format
msgid "field width is ignored for `%%' specifier"
msgstr "se descarta la anchura del campo para el especificador `%%'"
-#: builtin.c:764
+#: builtin.c:817
#, c-format
msgid "precision is ignored for `%%' specifier"
msgstr "se descarta la precisión para el especificador `%%'"
-#: builtin.c:766
+#: builtin.c:819
#, c-format
msgid "field width and precision are ignored for `%%' specifier"
msgstr ""
"se descartan la anchura del campo y la precisión para el especificador `%%'"
-#: builtin.c:817
+#: builtin.c:870
msgid "fatal: `$' is not permitted in awk formats"
msgstr "fatal: no se permite `$' en los formatos de awk"
-#: builtin.c:826
+#: builtin.c:879
msgid "fatal: arg count with `$' must be > 0"
msgstr "fatal: la cuenta de argumentos con `$' debe ser > 0"
-#: builtin.c:830
+#: builtin.c:883
#, c-format
msgid "fatal: arg count %ld greater than total number of supplied arguments"
msgstr ""
"fatal: la cuenta de argumentos %ld es mayor que el número total de "
"argumentos proporcionados"
-#: builtin.c:834
+#: builtin.c:887
msgid "fatal: `$' not permitted after period in format"
msgstr "fatal: no se permite `$' después de un punto en el formato"
-#: builtin.c:850
+#: builtin.c:903
msgid "fatal: no `$' supplied for positional field width or precision"
msgstr ""
"fatal: no se proporciona `$' para la anchura o la precisión del campo "
"posicional"
-#: builtin.c:921
+#: builtin.c:975
msgid "`l' is meaningless in awk formats; ignored"
msgstr "`l' no tiene significado en los formatos de awk; se descarta"
-#: builtin.c:925
+#: builtin.c:979
msgid "fatal: `l' is not permitted in POSIX awk formats"
msgstr "fatal: no se permite `l' en los formatos POSIX de awk"
-#: builtin.c:938
+#: builtin.c:992
msgid "`L' is meaningless in awk formats; ignored"
msgstr "`L' no tiene significado en los formatos de awk; se descarta"
-#: builtin.c:942
+#: builtin.c:996
msgid "fatal: `L' is not permitted in POSIX awk formats"
msgstr "fatal: no se permite `L' en los formatos POSIX de awk"
-#: builtin.c:955
+#: builtin.c:1009
msgid "`h' is meaningless in awk formats; ignored"
msgstr "`h' no tiene significado en los formatos de awk; se descarta"
-#: builtin.c:959
+#: builtin.c:1013
msgid "fatal: `h' is not permitted in POSIX awk formats"
msgstr "fatal: no se permite `h' en los formatos POSIX de awk"
-#: builtin.c:1272
+#: builtin.c:1408
#, c-format
msgid "[s]printf: value %g is out of range for `%%%c' format"
msgstr "[s]printf: el valor %g está fuera del rango para el formato `%%%c'"
-#: builtin.c:1332
+#: builtin.c:1506
#, c-format
msgid "ignoring unknown format specifier character `%c': no argument converted"
msgstr ""
"se descarta el carácter especificador de formato `%c' desconocido: no se "
"convirtió ningún argumento"
-#: builtin.c:1337
+#: builtin.c:1511
msgid "fatal: not enough arguments to satisfy format string"
msgstr ""
"fatal: no hay suficientes argumentos para satisfacer a la cadena de formato"
-#: builtin.c:1339
+#: builtin.c:1513
msgid "^ ran out for this one"
msgstr "se acabó ^ para éste"
-#: builtin.c:1346
+#: builtin.c:1520
msgid "[s]printf: format specifier does not have control letter"
msgstr "[s]printf: el especificador de formato no tiene letras de control"
-#: builtin.c:1349
+#: builtin.c:1523
msgid "too many arguments supplied for format string"
msgstr "se proporcionaron demasiados argumentos para la cadena de formato"
-#: builtin.c:1423 builtin.c:1434
+#: builtin.c:1598 builtin.c:1609
msgid "printf: no arguments"
msgstr "printf: sin argumentos"
-#: builtin.c:1475
+#: builtin.c:1650
msgid "sqrt: received non-numeric argument"
msgstr "sqrt: se recibió un argumento que no es un númerico"
-#: builtin.c:1479
+#: builtin.c:1654
#, c-format
msgid "sqrt: called with negative argument %g"
msgstr "sqrt: se llamó con el argumento negativo %g"
-#: builtin.c:1503
+#: builtin.c:1685
#, c-format
msgid "substr: length %g is not >= 1"
msgstr "substr: la longitud %g no es >= 1"
-#: builtin.c:1505
+#: builtin.c:1687
#, c-format
msgid "substr: length %g is not >= 0"
msgstr "substr: la longitud %g no es >= 0"
-#: builtin.c:1512
+#: builtin.c:1694
#, c-format
msgid "substr: non-integer length %g will be truncated"
msgstr "substr: se truncará la longitud no entera %g"
-#: builtin.c:1517
+#: builtin.c:1699
#, c-format
msgid "substr: length %g too big for string indexing, truncating to %g"
msgstr ""
"substr: la longitud %g es demasiado grande para ser índice de cadena, se "
"trunca a %g"
-#: builtin.c:1529
+#: builtin.c:1711
#, c-format
msgid "substr: start index %g is invalid, using 1"
msgstr "substr: el índice de inicio %g es inválido, se usa 1"
-#: builtin.c:1534
+#: builtin.c:1716
#, c-format
msgid "substr: non-integer start index %g will be truncated"
msgstr "substr: se truncará el índice de inicio no entero %g"
-#: builtin.c:1559
+#: builtin.c:1741
msgid "substr: source string is zero length"
msgstr "substr: la cadena de origen es de longitud cero"
-#: builtin.c:1575
+#: builtin.c:1757
#, c-format
msgid "substr: start index %g is past end of string"
msgstr "substr: el índice de inicio %g está después del fin de la cadena"
-#: builtin.c:1583
+#: builtin.c:1765
#, c-format
msgid ""
"substr: length %g at start index %g exceeds length of first argument (%lu)"
@@ -776,234 +733,229 @@ msgstr ""
"substr: la cadena %g en el índice de inicio %g excede la longitud del primer "
"argumento (%lu)"
-#: builtin.c:1657
+#: builtin.c:1839
msgid "strftime: format value in PROCINFO[\"strftime\"] has numeric type"
msgstr ""
"strftime: el valor de formato en PROCINFO[\"strftime\"] tiene tipo numérico"
-#: builtin.c:1680
+#: builtin.c:1862
msgid "strftime: received non-numeric second argument"
msgstr "strftime: el segundo argumento recibido no es númerico"
-#: builtin.c:1683
+#: builtin.c:1866
msgid "strftime: second argument less than 0 or too big for time_t"
msgstr ""
"strftime: el segundo argumento es menor que 0 o demasiado grande para time_t"
-#: builtin.c:1690
+#: builtin.c:1873
msgid "strftime: received non-string first argument"
msgstr "strftime: el primer argumento recibido no es una cadena"
-#: builtin.c:1696
+#: builtin.c:1880
msgid "strftime: received empty format string"
msgstr "strftime: se recibió una cadena de formato vacía"
-#: builtin.c:1762
+#: builtin.c:1946
msgid "mktime: received non-string argument"
msgstr "mktime: se recibió un argumento que no es una cadena"
-#: builtin.c:1779
+#: builtin.c:1963
msgid "mktime: at least one of the values is out of the default range"
msgstr ""
"mktime: por lo menos uno de los valores está fuera del rango por defecto"
-#: builtin.c:1814
+#: builtin.c:1998
msgid "'system' function not allowed in sandbox mode"
msgstr "no se permite la función 'system' en modo sandbox"
-#: builtin.c:1819
+#: builtin.c:2003
msgid "system: received non-string argument"
msgstr "system: se recibió un argumento que no es una cadena"
-#: builtin.c:1874 eval.c:1159 eval.c:1790 eval.c:1803
-#, c-format
-msgid "reference to uninitialized variable `%s'"
-msgstr "referencia a la variable sin inicializar `%s'"
-
-#: builtin.c:1941
+#: builtin.c:2121
#, c-format
msgid "reference to uninitialized field `$%d'"
msgstr "referencia al campo sin inicializar `$%d'"
-#: builtin.c:2028
+#: builtin.c:2208
msgid "tolower: received non-string argument"
msgstr "tolower: se recibió un argumento que no es una cadena"
-#: builtin.c:2062
+#: builtin.c:2242
msgid "toupper: received non-string argument"
msgstr "toupper: se recibió un argumento que no es una cadena"
-#: builtin.c:2098
+#: builtin.c:2278
msgid "atan2: received non-numeric first argument"
msgstr "atan2: el primer argumento recibido no es númerico"
-#: builtin.c:2100
+#: builtin.c:2280
msgid "atan2: received non-numeric second argument"
msgstr "atan2: el segundo argumento recibido no es númerico"
-#: builtin.c:2119
+#: builtin.c:2299
msgid "sin: received non-numeric argument"
msgstr "sin: se recibió un argumento que no es númerico"
-#: builtin.c:2135
+#: builtin.c:2315
msgid "cos: received non-numeric argument"
msgstr "cos: se recibió un argumento que no es númerico"
-#: builtin.c:2188
+#: builtin.c:2368
msgid "srand: received non-numeric argument"
msgstr "srand: se recibió un argumento que no es númerico"
-#: builtin.c:2219
+#: builtin.c:2399
msgid "match: third argument is not an array"
msgstr "match: el tercer argumento no es una matriz"
-#: builtin.c:2483
+#: builtin.c:2664
msgid "gensub: third argument of 0 treated as 1"
msgstr "gensub: el tercer argumento de 0 se trata como 1"
-#: builtin.c:2776
+#: builtin.c:2957
msgid "lshift: received non-numeric first argument"
msgstr "lshift: el primer argumento recibido no es númerico"
-#: builtin.c:2778
+#: builtin.c:2959
msgid "lshift: received non-numeric second argument"
msgstr "lshift: el segundo argumento recibido no es númerico"
-#: builtin.c:2784
+#: builtin.c:2965
#, c-format
msgid "lshift(%lf, %lf): negative values will give strange results"
msgstr "lshift(%lf, %lf): los valores negativos darán resultados extraños"
-#: builtin.c:2786
+#: builtin.c:2967
#, c-format
msgid "lshift(%lf, %lf): fractional values will be truncated"
msgstr "lshift(%lf, %lf): los valores fraccionarios se truncarán"
-#: builtin.c:2788
+#: builtin.c:2969
#, c-format
msgid "lshift(%lf, %lf): too large shift value will give strange results"
msgstr ""
"lshift(%lf, %lf): un valor de desplazamiento muy grande dará resultados "
"extraños"
-#: builtin.c:2813
+#: builtin.c:2994
msgid "rshift: received non-numeric first argument"
msgstr "rshift: el primer argumento recibido no es númerico"
-#: builtin.c:2815
+#: builtin.c:2996
msgid "rshift: received non-numeric second argument"
msgstr "rshift: el segundo argumento recibido no es númerico"
-#: builtin.c:2821
+#: builtin.c:3002
#, c-format
msgid "rshift(%lf, %lf): negative values will give strange results"
msgstr "rshift(%lf, %lf): los valores negativos darán resultados extraños"
-#: builtin.c:2823
+#: builtin.c:3004
#, c-format
msgid "rshift(%lf, %lf): fractional values will be truncated"
msgstr "rshift(%lf, %lf): los valores fraccionarios serán truncados"
-#: builtin.c:2825
+#: builtin.c:3006
#, c-format
msgid "rshift(%lf, %lf): too large shift value will give strange results"
msgstr ""
"rshift(%lf, %lf): un valor de desplazamiento muy grande dará resultados "
"extraños"
-#: builtin.c:2850
+#: builtin.c:3031
msgid "and: received non-numeric first argument"
msgstr "and: el primer argumento recibido no es númerico"
-#: builtin.c:2852
+#: builtin.c:3033
msgid "and: received non-numeric second argument"
msgstr "and: el segundo argumento recibido no es númerico"
-#: builtin.c:2858
+#: builtin.c:3039
#, c-format
msgid "and(%lf, %lf): negative values will give strange results"
msgstr "and(%lf, %lf): los valores negativos darán resultados extraños"
-#: builtin.c:2860
+#: builtin.c:3041
#, c-format
msgid "and(%lf, %lf): fractional values will be truncated"
msgstr "and(%lf, %lf): los valores fraccionarios serán truncados"
-#: builtin.c:2885
+#: builtin.c:3066
msgid "or: received non-numeric first argument"
msgstr "or: el primer argumento recibido no es númerico"
-#: builtin.c:2887
+#: builtin.c:3068
msgid "or: received non-numeric second argument"
msgstr "or: el segundo argumento recibido no es númerico"
-#: builtin.c:2893
+#: builtin.c:3074
#, c-format
msgid "or(%lf, %lf): negative values will give strange results"
msgstr "or(%lf, %lf): los valores negativos darán resultados extraños"
-#: builtin.c:2895
+#: builtin.c:3076
#, c-format
msgid "or(%lf, %lf): fractional values will be truncated"
msgstr "or(%lf, %lf): los valores fraccionarios serán truncados"
-#: builtin.c:2923
+#: builtin.c:3102
msgid "xor: received non-numeric first argument"
msgstr "xor: el primer argumento recibido no es númerico"
-#: builtin.c:2925
+#: builtin.c:3104
msgid "xor: received non-numeric second argument"
msgstr "xor: el segundo argumento recibido no es númerico"
-#: builtin.c:2931
+#: builtin.c:3110
#, c-format
msgid "xor(%lf, %lf): negative values will give strange results"
msgstr "xor(%lf, %lf): los valores negativos darán resultados extraños"
-#: builtin.c:2933
+#: builtin.c:3112
#, c-format
msgid "xor(%lf, %lf): fractional values will be truncated"
msgstr "xor(%lf, %lf): los valores fraccionarios se truncarán"
-#: builtin.c:2957 builtin.c:2963
+#: builtin.c:3136
msgid "compl: received non-numeric argument"
msgstr "compl: se recibió un argumento que no es númerico"
-#: builtin.c:2965
+#: builtin.c:3142
#, c-format
msgid "compl(%lf): negative value will give strange results"
msgstr "compl(%lf): el valor negativo dará resultados extraños"
-#: builtin.c:2967
+#: builtin.c:3144
#, c-format
msgid "compl(%lf): fractional value will be truncated"
msgstr "compl(%lf): el valor fraccionario se truncará"
-#: builtin.c:3136
+#: builtin.c:3313
#, c-format
msgid "dcgettext: `%s' is not a valid locale category"
msgstr "dcgettext: `%s' no es una categoría local válida"
-#: eval.c:412
+#: eval.c:395
#, c-format
msgid "unknown nodetype %d"
msgstr "tipo de nodo %d desconocido"
-#: eval.c:423 eval.c:437
+#: eval.c:406 eval.c:420
#, c-format
msgid "unknown opcode %d"
msgstr "código de operación %d desconocido"
-#: eval.c:434
+#: eval.c:417
#, c-format
msgid "opcode %s not an operator or keyword"
msgstr "el código de operación %s no es un operador o una palabra clave"
-#: eval.c:488
+#: eval.c:472
msgid "buffer overflow in genflags2str"
msgstr "desbordamiento de almacenamiento temporal en genflags2str"
-#: eval.c:698
+#: eval.c:675
#, c-format
msgid ""
"\n"
@@ -1014,311 +966,255 @@ msgstr ""
"\t# Pila de Llamadas de Funciones:\n"
"\n"
-#: eval.c:725
+#: eval.c:704
msgid "`IGNORECASE' is a gawk extension"
msgstr "`IGNORECASE' es una extensión de gawk"
-#: eval.c:754
+#: eval.c:736
msgid "`BINMODE' is a gawk extension"
msgstr "`BINMODE' es una extensión de gawk"
-#: eval.c:812
+#: eval.c:793
#, c-format
msgid "BINMODE value `%s' is invalid, treated as 3"
msgstr "el valor BINMODE `%s' es inválido; se trata como 3"
-#: eval.c:902
+#: eval.c:885
#, c-format
msgid "bad `%sFMT' specification `%s'"
msgstr "especificación `%sFMT' `%s' errónea"
-#: eval.c:980
+#: eval.c:969
msgid "turning off `--lint' due to assignment to `LINT'"
msgstr "se desactiva `--lint' debido a una asignación a `LINT'"
-#: eval.c:1127 eval.c:1777
-#, c-format
-msgid "can't use function name `%s' as variable or array"
-msgstr "no se puede usar el nombre de la función `%s' como variable o matriz"
-
-#: eval.c:1158 eval.c:1789 eval.c:1802
+#: eval.c:1132
#, c-format
msgid "reference to uninitialized argument `%s'"
msgstr "referencia al argumento sin inicializar `%s'"
-#: eval.c:1177
+#: eval.c:1133
+#, c-format
+msgid "reference to uninitialized variable `%s'"
+msgstr "referencia a la variable sin inicializar `%s'"
+
+#: eval.c:1151
msgid "attempt to field reference from non-numeric value"
msgstr "se intentó una referencia de campo desde un valor que no es númerico"
-#: eval.c:1179
+#: eval.c:1153
msgid "attempt to field reference from null string"
msgstr "se intentó una referencia de campo desde una cadena nula"
-#: eval.c:1185
+#: eval.c:1161
#, c-format
msgid "attempt to access field %ld"
msgstr "se intentó acceder al campo %ld"
-#: eval.c:1194
+#: eval.c:1170
#, c-format
msgid "reference to uninitialized field `$%ld'"
msgstr "referencia al campo sin inicializar `$%ld'"
-#: eval.c:1256
+#: eval.c:1257
#, c-format
msgid "function `%s' called with more arguments than declared"
msgstr "se llamó a la función `%s' con más argumentos de los declarados"
-#: eval.c:1437
+#: eval.c:1452
#, c-format
msgid "unwind_stack: unexpected type `%s'"
msgstr "unwind_stack: tipo `%s' inesperado"
-#: eval.c:1532
+#: eval.c:1546
msgid "division by zero attempted in `/='"
msgstr "se intentó una división por cero en `/='"
-#: eval.c:1539
+#: eval.c:1553
#, c-format
msgid "division by zero attempted in `%%='"
msgstr "se intentó una división por cero en `%%='"
-#: eval.c:1876 eval.c:2122
-#, c-format
-msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
-msgstr "se intentó usar la matriz `%s[\"%.*s\"]' en un contexto escalar"
-
-#: eval.c:1907
-msgid "assignment used in conditional context"
-msgstr "se usó una asignación en un contexto condicional"
-
-#: eval.c:1911
-msgid "statement has no effect"
-msgstr "la declaración no tiene efecto"
-
-#: eval.c:2343
-#, c-format
-msgid "for loop: array `%s' changed size from %ld to %ld during loop execution"
-msgstr ""
-"bucle for: la matriz `%s' cambió de tamaño de %ld a %ld durante la ejecución "
-"del bucle"
-
-#: eval.c:2458
-#, c-format
-msgid "function called indirectly through `%s' does not exist"
-msgstr "no existe la función llamada indirectamente a través de `%s'"
-
-#: eval.c:2470
-#, c-format
-msgid "function `%s' not defined"
-msgstr "la función `%s' no está definida"
-
-#: eval.c:2511
-#, c-format
-msgid "non-redirected `getline' invalid inside `%s' rule"
-msgstr "`getline' no redirigido es inválido dentro de la regla `%s'"
-
-#: eval.c:2600
-#, c-format
-msgid "error reading input file `%s': %s"
-msgstr "error al leer el fichero de entrada `%s': %s"
-
-#: eval.c:2614
-#, c-format
-msgid "`nextfile' cannot be called from a `%s' rule"
-msgstr "`nextfile' no se puede llamar desde una regla `%s'"
-
-#: eval.c:2661
-msgid "`exit' cannot be called in the current context"
-msgstr "`exit' no se puede llamar en el contexto actual"
-
-#: eval.c:2700
-#, c-format
-msgid "`next' cannot be called from a `%s' rule"
-msgstr "`next' no se puede llamar desde una regla `%s'"
-
-#: eval.c:2766
-#, c-format
-msgid "Sorry, don't know how to interpret `%s'"
-msgstr "Perdón, no se cómo interpretar `%s'"
-
-#: ext.c:54
+#: ext.c:70
msgid "extensions are not allowed in sandbox mode"
msgstr "no se permiten las extensiones en modo sandbox"
-#: ext.c:60 ext.c:65
+#: ext.c:73
msgid "`extension' is a gawk extension"
msgstr "`extension' es una extensión de gawk"
-#: ext.c:75
-#, c-format
-msgid "fatal: extension: cannot open `%s' (%s)\n"
+#: ext.c:80
+#, fuzzy, c-format
+msgid "extension: cannot open library `%s' (%s)\n"
msgstr "fatal: extension: no se puede abrir `%s' (%s)\n"
-#: ext.c:84
-#, c-format
+#: ext.c:86
+#, fuzzy, c-format
msgid ""
-"fatal: extension: library `%s': does not define "
-"`plugin_is_GPL_compatible' (%s)\n"
+"extension: library `%s': does not define `plugin_is_GPL_compatible' (%s)\n"
msgstr ""
"fatal: extension: la biblioteca `%s': no define "
"`plugin_is_GPL_compatible' (%s)\n"
-#: ext.c:93
-#, c-format
-msgid "fatal: extension: library `%s': cannot call function `%s' (%s)\n"
+#: ext.c:90
+#, fuzzy, c-format
+msgid "extension: library `%s': cannot call function `%s' (%s)\n"
msgstr ""
"fatal: extension: la biblioteca `%s': no puede llamar a la función `"
"%s' (%s)\n"
-#: ext.c:127
+#: ext.c:118
msgid "extension: missing function name"
msgstr "extension: falta el nombre de la función"
-#: ext.c:132
+#: ext.c:123
#, c-format
msgid "extension: illegal character `%c' in function name `%s'"
msgstr "extension: carácter ilegal `%c' en el nombre de la función `%s'"
-#: ext.c:141
+#: ext.c:131
#, c-format
msgid "extension: can't redefine function `%s'"
msgstr "extension: no se puede redefinir la función `%s'"
-#: ext.c:145
+#: ext.c:135
#, c-format
msgid "extension: function `%s' already defined"
msgstr "extension: la función `%s' ya está definida"
-#: ext.c:150
+#: ext.c:139
#, c-format
msgid "extension: function name `%s' previously defined"
msgstr "extension: el nombre de función `%s' se definió previamente"
-#: ext.c:152
+#: ext.c:141
#, c-format
msgid "extension: can't use gawk built-in `%s' as function name"
msgstr ""
"extension: no se puede utilizar la orden interna de gawk `%s' como nombre de "
"función"
-#: ext.c:156
+#: ext.c:144
#, c-format
msgid "make_builtin: negative argument count for function `%s'"
msgstr "make_builtin: cuenta de argumento negativa para la función `%s'"
-#: ext.c:259
+#: ext.c:206
#, c-format
msgid "function `%s' defined to take no more than %d argument(s)"
msgstr "la función `%s' se definió para tomar no más de %d argumento(s)"
-#: ext.c:262
+#: ext.c:209
#, c-format
msgid "function `%s': missing argument #%d"
msgstr "función `%s': falta el argumento #%d"
-#: ext.c:279
+#: ext.c:226
#, c-format
msgid "function `%s': argument #%d: attempt to use scalar as an array"
msgstr ""
"función `%s': argumento #%d: se intentó usar un escalar como una matriz"
-#: ext.c:283
+#: ext.c:230
#, c-format
msgid "function `%s': argument #%d: attempt to use array as a scalar"
msgstr ""
"función `%s': argumento #%d: se intentó usar una matriz como un escalar"
-#: ext.c:296
+#: ext.c:244
msgid "Operation Not Supported"
msgstr "No Se Admite La Operación"
-#: field.c:328
+#: ext.c:256
+msgid "dynamic loading of library not supported"
+msgstr ""
+
+#: field.c:339
msgid "NF set to negative value"
msgstr "se definió NF con un valor negativo"
-#: field.c:951 field.c:958 field.c:962
+#: field.c:962 field.c:969 field.c:973
msgid "split: fourth argument is a gawk extension"
msgstr "split: el cuarto argumento es una extensión de gawk"
-#: field.c:955
+#: field.c:966
msgid "split: fourth argument is not an array"
msgstr "split: el cuarto argumento no es una matriz"
-#: field.c:969
+#: field.c:980
msgid "split: second argument is not an array"
msgstr "split: el segundo argumento no es una matriz"
-#: field.c:973
+#: field.c:984
msgid "split: cannot use the same array for second and fourth args"
msgstr ""
"split: no se puede usar la misma matriz para el segundo y cuarto argumentos"
-#: field.c:978
+#: field.c:989
msgid "split: cannot use a subarray of second arg for fourth arg"
msgstr ""
"split: no se puede usar una submatriz del segundo argumento para el cuarto "
"argumento"
-#: field.c:981
+#: field.c:992
msgid "split: cannot use a subarray of fourth arg for second arg"
msgstr ""
"split: no se puede usar una submatriz del cuarto argumento para el segundo "
"argumento"
-#: field.c:1010
+#: field.c:1021
msgid "split: null string for third arg is a gawk extension"
msgstr ""
"split: la cadena nula para el tercer argumento es una extensión de gawk"
-#: field.c:1050
+#: field.c:1061
msgid "patsplit: fourth argument is not an array"
msgstr "patsplit: el cuarto argumento no es una matriz"
-#: field.c:1055
+#: field.c:1066
msgid "patsplit: second argument is not an array"
msgstr "patsplit: el segundo argumento no es una matriz"
-#: field.c:1061
+#: field.c:1072
msgid "patsplit: third argument must be non-null"
msgstr "patsplit: el tercer argumento no debe ser nulo"
-#: field.c:1065
+#: field.c:1076
msgid "patsplit: cannot use the same array for second and fourth args"
msgstr ""
"patsplit: no se puede usar la misma matriz para el segundo y cuarto "
"argumentos"
-#: field.c:1070
+#: field.c:1081
msgid "patsplit: cannot use a subarray of second arg for fourth arg"
msgstr ""
"patsplit: no se puede usar una submatriz del segundo argumento para el "
"cuarto argumento"
-#: field.c:1073
+#: field.c:1084
msgid "patsplit: cannot use a subarray of fourth arg for second arg"
msgstr ""
"patsplit: no se puede usar una submatriz del cuarto argumento para el "
"segundo argumento"
-#: field.c:1110
+#: field.c:1122
msgid "`FIELDWIDTHS' is a gawk extension"
msgstr "`FIELDWIDTHS' es una extensión gawk"
-#: field.c:1173
+#: field.c:1186
#, c-format
msgid "invalid FIELDWIDTHS value, near `%s'"
msgstr "valor de FIELDWIDTHS inválido, cerca de `%s'"
-#: field.c:1246
+#: field.c:1259
msgid "null string for `FS' is a gawk extension"
msgstr "la cadena nula para `FS' es una extensión de gawk"
-#: field.c:1250
+#: field.c:1263
msgid "old awk does not support regexps as value of `FS'"
msgstr "el awk antiguo no admite expresiones regulares como valor de `FS'"
-#: field.c:1369
+#: field.c:1382
msgid "`FPAT' is a gawk extension"
msgstr "`FPAT' es una extensión de gawk"
@@ -1377,471 +1273,486 @@ msgstr "%s: la opción '-W %s' no admite ningún argumento\n"
msgid "%s: option '-W %s' requires an argument\n"
msgstr "%s: la opción '-W %s' requiere un argumento\n"
-#: io.c:280
+#: io.c:326
#, c-format
msgid "command line argument `%s' is a directory: skipped"
msgstr "el argumento de la línea de órdenes `%s' es un directorio: se salta"
-#: io.c:283 io.c:385
+#: io.c:329 io.c:438
#, c-format
msgid "cannot open file `%s' for reading (%s)"
msgstr "no se puede abrir el fichero `%s' para lectura (%s)"
-#: io.c:501
+#: io.c:568
#, c-format
msgid "close of fd %d (`%s') failed (%s)"
msgstr "falló al cerrar el df %d (`%s') (%s)"
-#: io.c:578
+#: io.c:645
msgid "redirection not allowed in sandbox mode"
msgstr "no se permite la redirección en modo sandbox"
-#: io.c:612
+#: io.c:679
#, c-format
msgid "expression in `%s' redirection only has numeric value"
msgstr "la expresión en la redirección `%s' sólo tiene valor numérico"
-#: io.c:618
+#: io.c:685
#, c-format
msgid "expression for `%s' redirection has null string value"
msgstr "la expresión para la redirección `%s' tiene un valor de cadena nula"
-#: io.c:623
+#: io.c:690
#, c-format
msgid "filename `%s' for `%s' redirection may be result of logical expression"
msgstr ""
"el fichero `%s' para la redirección `%s' puede ser resultado de una "
"expresión lógica"
-#: io.c:666
+#: io.c:733
#, c-format
msgid "unnecessary mixing of `>' and `>>' for file `%.*s'"
msgstr "mezcla innecesaria de `>' y `>>' para el fichero `%.*s'"
-#: io.c:719
+#: io.c:786
#, c-format
msgid "can't open pipe `%s' for output (%s)"
msgstr "no se puede abrir la tubería `%s' para la salida (%s)"
-#: io.c:729
+#: io.c:796
#, c-format
msgid "can't open pipe `%s' for input (%s)"
msgstr "no se puede abrir la tubería `%s' para la entrada (%s)"
-#: io.c:752
+#: io.c:819
#, c-format
msgid "can't open two way pipe `%s' for input/output (%s)"
msgstr "no se puede abrir la tubería de dos vías `%s' para entrada/salida (%s)"
-#: io.c:834
+#: io.c:900
#, c-format
msgid "can't redirect from `%s' (%s)"
msgstr "no se puede redirigir desde `%s' (%s)"
-#: io.c:837
+#: io.c:903
#, c-format
msgid "can't redirect to `%s' (%s)"
msgstr "no se puede redirigir a `%s' (%s)"
-#: io.c:888
+#: io.c:954
msgid ""
"reached system limit for open files: starting to multiplex file descriptors"
msgstr ""
"se alcanzó el límite del sistema para ficheros abiertos: comenzando a "
"multiplexar los descriptores de fichero"
-#: io.c:904
+#: io.c:970
#, c-format
msgid "close of `%s' failed (%s)."
msgstr "falló al cerrar `%s' (%s)."
-#: io.c:912
+#: io.c:978
msgid "too many pipes or input files open"
msgstr "demasiadas tuberías o ficheros de entrada abiertos"
-#: io.c:934
+#: io.c:1000
msgid "close: second argument must be `to' or `from'"
msgstr "close: el segundo argumento debe ser `to' o `from'"
-#: io.c:951
+#: io.c:1017
#, c-format
msgid "close: `%.*s' is not an open file, pipe or co-process"
msgstr "close: `%.*s' no es un fichero abierto, tubería o co-proceso"
-#: io.c:956
+#: io.c:1022
msgid "close of redirection that was never opened"
msgstr "se cerró una redirección que nunca se abrió"
-#: io.c:1053
+#: io.c:1120
#, c-format
msgid "close: redirection `%s' not opened with `|&', second argument ignored"
msgstr ""
"close: la redirección `%s' no se abrió con `|&', se descarta el segundo "
"argumento"
-#: io.c:1069
+#: io.c:1137
#, c-format
msgid "failure status (%d) on pipe close of `%s' (%s)"
msgstr "estado de fallo (%d) al cerrar la tubería de `%s' (%s)"
-#: io.c:1072
+#: io.c:1140
#, c-format
msgid "failure status (%d) on file close of `%s' (%s)"
msgstr "estado de fallo (%d) al cerrar el fichero de `%s' (%s)"
-#: io.c:1092
+#: io.c:1160
#, c-format
msgid "no explicit close of socket `%s' provided"
msgstr "no se provee el cerrado explícito del `socket' `%s'"
-#: io.c:1095
+#: io.c:1163
#, c-format
msgid "no explicit close of co-process `%s' provided"
msgstr "no se provee el cerrado explícito del co-proceso `%s'"
-#: io.c:1098
+#: io.c:1166
#, c-format
msgid "no explicit close of pipe `%s' provided"
msgstr "no se provee el cerrado explícito del la tubería `%s'"
-#: io.c:1101
+#: io.c:1169
#, c-format
msgid "no explicit close of file `%s' provided"
msgstr "no se provee el cerrado explícito del fichero `%s'"
-#: io.c:1129 io.c:1184 main.c:794 main.c:831
+#: io.c:1197 io.c:1252 main.c:825 main.c:862
#, c-format
msgid "error writing standard output (%s)"
msgstr "error al escribir en la salida estándar (%s)"
-#: io.c:1133 io.c:1189
+#: io.c:1201 io.c:1257
#, c-format
msgid "error writing standard error (%s)"
msgstr "error al escribir en la salida estándar de error (%s)"
-#: io.c:1141
+#: io.c:1209
#, c-format
msgid "pipe flush of `%s' failed (%s)."
msgstr "falló la limpieza de la tubería de `%s' (%s)."
-#: io.c:1144
+#: io.c:1212
#, c-format
msgid "co-process flush of pipe to `%s' failed (%s)."
msgstr "falló la limpieza del co-proceso de la tubería a `%s' (%s)."
-#: io.c:1147
+#: io.c:1215
#, c-format
msgid "file flush of `%s' failed (%s)."
msgstr "falló la limpieza del fichero de `%s' (%s)."
-#: io.c:1262
+#: io.c:1329
#, c-format
msgid "local port %s invalid in `/inet'"
msgstr "puerto local %s inválido en `/inet'"
-#: io.c:1279
+#: io.c:1347
#, c-format
msgid "remote host and port information (%s, %s) invalid"
msgstr "anfitrión remoto e información de puerto (%s, %s) inválidos"
-#: io.c:1431
+#: io.c:1499
#, c-format
msgid "no (known) protocol supplied in special filename `%s'"
msgstr ""
"no se proporciona algún protocolo (conocido) en el nombre de fichero "
"especial `%s'"
-#: io.c:1445
+#: io.c:1513
#, c-format
msgid "special file name `%s' is incomplete"
msgstr "el nombre de fichero especial `%s' está incompleto"
-#: io.c:1462
+#: io.c:1530
msgid "must supply a remote hostname to `/inet'"
msgstr "se debe proporcionar a `/inet' un nombre de anfitrión remoto"
-#: io.c:1480
+#: io.c:1548
msgid "must supply a remote port to `/inet'"
msgstr "se debe proporcionar a `/inet' un puerto remoto"
-#: io.c:1526
+#: io.c:1594
msgid "TCP/IP communications are not supported"
msgstr "no se admiten las comunicaciones TCP/IP"
-#: io.c:1693
+#: io.c:1764
#, c-format
msgid "could not open `%s', mode `%s'"
msgstr "no se puede abrir `%s', modo `%s'"
-#: io.c:1747
+#: io.c:1814
#, c-format
msgid "close of master pty failed (%s)"
msgstr "falló al cerrar el pty maestro (%s)"
-#: io.c:1749 io.c:1917 io.c:2074
+#: io.c:1816 io.c:1984 io.c:2145
#, c-format
msgid "close of stdout in child failed (%s)"
msgstr "falló al cerrar la salida estándar en el hijo (%s)"
-#: io.c:1752
+#: io.c:1819
#, c-format
msgid "moving slave pty to stdout in child failed (dup: %s)"
msgstr ""
"falló el movimiento del pty esclavo a la salida estándar en el hijo (dup: %s)"
-#: io.c:1754 io.c:1922
+#: io.c:1821 io.c:1989
#, c-format
msgid "close of stdin in child failed (%s)"
msgstr "falló al cerrar la entrada estándar en el hijo (%s)"
-#: io.c:1757
+#: io.c:1824
#, c-format
msgid "moving slave pty to stdin in child failed (dup: %s)"
msgstr ""
"falló el movimiento del pty esclavo a la entrada estándar en el hijo (dup: "
"%s)"
-#: io.c:1759 io.c:1780
+#: io.c:1826 io.c:1847
#, c-format
msgid "close of slave pty failed (%s)"
msgstr "falló al cerrar el pty esclavo (%s)"
-#: io.c:1858 io.c:1920 io.c:2052 io.c:2077
+#: io.c:1925 io.c:1987 io.c:2122 io.c:2148
#, c-format
msgid "moving pipe to stdout in child failed (dup: %s)"
msgstr "falló el movimiento a la salida estándar en el hijo (dup: %s)"
-#: io.c:1865 io.c:1925
+#: io.c:1932 io.c:1992
#, c-format
msgid "moving pipe to stdin in child failed (dup: %s)"
msgstr ""
"falló el movimiento de la tubería a la entrada estándar en el hijo (dup: %s)"
-#: io.c:1885 io.c:2067
+#: io.c:1952 io.c:2138
msgid "restoring stdout in parent process failed\n"
msgstr "falló la restauración de la salida estándar en el proceso padre\n"
-#: io.c:1893
+#: io.c:1960
msgid "restoring stdin in parent process failed\n"
msgstr "falló la restauración de la entrada estándar en el proceso padre\n"
-#: io.c:1928 io.c:2079 io.c:2093
+#: io.c:1995 io.c:2150 io.c:2164
#, c-format
msgid "close of pipe failed (%s)"
msgstr "falló al cerrar la tubería (%s)"
-#: io.c:1973
+#: io.c:2040
msgid "`|&' not supported"
msgstr "no se admite `|&'"
-#: io.c:2039
+#: io.c:2107
#, c-format
msgid "cannot open pipe `%s' (%s)"
msgstr "no se puede abrir la tubería `%s' (%s)"
-#: io.c:2087
+#: io.c:2158
#, c-format
msgid "cannot create child process for `%s' (fork: %s)"
msgstr "no se puede crear el proceso hijo para `%s' (fork: %s)"
-#: io.c:2520
+#: io.c:2637
#, c-format
msgid "data file `%s' is empty"
msgstr "el fichero de datos `%s' está vacío"
-#: io.c:2561 io.c:2569
+#: io.c:2678 io.c:2686
msgid "could not allocate more input memory"
msgstr "no se puede reservar más memoria de entrada"
-#: io.c:3127
+#: io.c:3236
msgid "multicharacter value of `RS' is a gawk extension"
msgstr "el valor multicaracter de `RS' es una extensión de gawk"
-#: io.c:3232
+#: io.c:3326
msgid "IPv6 communication is not supported"
msgstr "no se admite la comunicación IPv6"
-#: main.c:366
+#: main.c:355
msgid "`-m[fr]' option irrelevant in gawk"
msgstr "la opción -m[fr] es irrelevante en gawk"
-#: main.c:368
+#: main.c:357
msgid "-m option usage: `-m[fr] nnn'"
msgstr "uso de la opción -m: `-m[fr]' nnn"
-#: main.c:391
+#: main.c:386
msgid "empty argument to `-e/--source' ignored"
msgstr "se descarta el argumento vacío para `-e/--source'"
-#: main.c:462
+#: main.c:472
#, c-format
msgid "%s: option `-W %s' unrecognized, ignored\n"
msgstr "%s: no se reconoce la opción `-W %s', se descarta\n"
-#: main.c:515
+#: main.c:518
#, c-format
msgid "%s: option requires an argument -- %c\n"
msgstr "%s: la opción requiere un argumento -- %c\n"
-#: main.c:536
+#: main.c:539
msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'"
msgstr ""
"la variable de ambiente `POSIXLY_CORRECT' está definida: se activa `--posix'"
-#: main.c:542
+#: main.c:545
msgid "`--posix' overrides `--traditional'"
msgstr "`--posix' se impone a `--traditional'"
-#: main.c:553
+#: main.c:556
msgid "`--posix'/`--traditional' overrides `--non-decimal-data'"
msgstr "`--posix'/`--traditional' se imponen a `--non-decimal-data'"
-#: main.c:557
+#: main.c:560
#, c-format
msgid "running %s setuid root may be a security problem"
msgstr "ejecutar %s como setuid root puede ser un problema de seguridad"
-#: main.c:562
+#: main.c:565
msgid "`--posix' overrides `--binary'"
msgstr "`--posix' se impone a `--binary'"
-#: main.c:613
+#: main.c:623
#, c-format
msgid "can't set binary mode on stdin (%s)"
msgstr "no se puede establecer el modo binario en la entrada estándar (%s)"
-#: main.c:616
+#: main.c:626
#, c-format
msgid "can't set binary mode on stdout (%s)"
msgstr "no se puede establecer el modo binario en la salida estándar (%s)"
-#: main.c:618
+#: main.c:628
#, c-format
msgid "can't set binary mode on stderr (%s)"
msgstr ""
"no se puede establecer el modo binario en la salida estándar de error (%s)"
-#: main.c:657
+#: main.c:679
msgid "no program text at all!"
msgstr "¡No hay ningún programa de texto!"
-#: main.c:734
+#: main.c:763
#, c-format
msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n"
msgstr ""
"Modo de empleo: %s [opciones estilo POSIX o GNU] -f fichprog [--] "
"fichero ...\n"
-#: main.c:736
+#: main.c:765
#, c-format
msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n"
msgstr ""
"Modo de empleo: %s [opciones estilo POSIX o GNU] [--] %cprograma%c "
"fichero ...\n"
-#: main.c:741
+#: main.c:770
msgid "POSIX options:\t\tGNU long options: (standard)\n"
msgstr "Opciones POSIX:\t\tOpciones largas GNU: (estándar)\n"
-#: main.c:742
+#: main.c:771
msgid "\t-f progfile\t\t--file=progfile\n"
msgstr "\t-f fichprog\t\t--file=fichprog\n"
-#: main.c:743
+#: main.c:772
msgid "\t-F fs\t\t\t--field-separator=fs\n"
msgstr "\t-F sc\t\t\t--field-separator=sc\n"
-#: main.c:744
+#: main.c:773
msgid "\t-v var=val\t\t--assign=var=val\n"
msgstr "\t-v var=valor\t\t--assign=var=valor\n"
-#: main.c:745
+#: main.c:774
msgid "Short options:\t\tGNU long options: (extensions)\n"
msgstr "Opciones cortas:\t\tOpciones largas GNU: (extensiones)\n"
-#: main.c:746
+#: main.c:775
msgid "\t-b\t\t\t--characters-as-bytes\n"
msgstr "\t-b\t\t\t--characters-as-bytes\n"
-#: main.c:747
+#: main.c:776
msgid "\t-c\t\t\t--traditional\n"
msgstr "\t-c\t\t\t--traditional\n"
-#: main.c:748
+#: main.c:777
msgid "\t-C\t\t\t--copyright\n"
msgstr "\t-C\t\t\t--copyright\n"
-#: main.c:749
+#: main.c:778
msgid "\t-d[file]\t\t--dump-variables[=file]\n"
msgstr "\t-d[fichero]\t\t--dump-variables[=fichero]\n"
+#: main.c:779
+#, fuzzy
+msgid "\t-D[file]\t\t--debug[=file]\n"
+msgstr "\t-p[fichero]\t\t--profile[=fichero]\n"
+
# Esta es la línea más larga de la lista de argumentos.
# Probar con gawk para revisar tabuladores. cfuga
-#: main.c:750
+#: main.c:780
msgid "\t-e 'program-text'\t--source='program-text'\n"
msgstr "\t-e 'texto-prog'\t--source='texto-prog'\n"
-#: main.c:751
+#: main.c:781
msgid "\t-E file\t\t\t--exec=file\n"
msgstr "\t-E fichero\t\t--exec=fichero\n"
-#: main.c:752
+#: main.c:782
msgid "\t-g\t\t\t--gen-pot\n"
msgstr "\t-g\t\t\t--gen-pot\n"
-#: main.c:753
+#: main.c:783
msgid "\t-h\t\t\t--help\n"
msgstr "\t-h\t\t\t--help\n"
-#: main.c:754
+#: main.c:784
+msgid "\t-l library\t\t--load=library\n"
+msgstr ""
+
+#: main.c:785
msgid "\t-L [fatal]\t\t--lint[=fatal]\n"
msgstr "\t-L [fatal]\t\t--lint[=fatal]\n"
-#: main.c:755
+#: main.c:786
msgid "\t-n\t\t\t--non-decimal-data\n"
msgstr "\t-n\t\t\t--non-decimal-data\n"
-#: main.c:756
+#: main.c:787
+#, fuzzy
+msgid "\t-M\t\t\t--bignum\n"
+msgstr "\t-g\t\t\t--gen-pot\n"
+
+#: main.c:788
msgid "\t-N\t\t\t--use-lc-numeric\n"
msgstr "\t-N\t\t\t--use-lc-numeric\n"
-#: main.c:757
+#: main.c:789
+#, fuzzy
+msgid "\t-o[file]\t\t--pretty-print[=file]\n"
+msgstr "\t-p[fichero]\t\t--profile[=fichero]\n"
+
+#: main.c:790
msgid "\t-O\t\t\t--optimize\n"
msgstr "\t-O\t\t\t--optimize\n"
-#: main.c:758
+#: main.c:791
msgid "\t-p[file]\t\t--profile[=file]\n"
msgstr "\t-p[fichero]\t\t--profile[=fichero]\n"
-#: main.c:759
+#: main.c:792
msgid "\t-P\t\t\t--posix\n"
msgstr "\t-P\t\t\t--posix\n"
-#: main.c:760
+#: main.c:793
msgid "\t-r\t\t\t--re-interval\n"
msgstr "\t-r\t\t\t--re-interval\n"
-#: main.c:762
-msgid "\t-R file\t\t\t--command=file\n"
-msgstr "\t-R fichero\t\t\t--command=fichero\n"
-
-#: main.c:763
+#: main.c:794
msgid "\t-S\t\t\t--sandbox\n"
msgstr "\t-S\t\t\t--sandbox\n"
-#: main.c:764
+#: main.c:795
msgid "\t-t\t\t\t--lint-old\n"
msgstr "\t-t\t\t\t--lint-old\n"
-#: main.c:765
+#: main.c:796
msgid "\t-V\t\t\t--version\n"
msgstr "\t-V\t\t\t--version\n"
-#: main.c:767
+#: main.c:798
msgid "\t-W nostalgia\t\t--nostalgia\n"
msgstr "\t-W nostalgia\t\t--nostalgia\n"
-#: main.c:770
+#: main.c:801
msgid "\t-Y\t\t--parsedebug\n"
msgstr "\t-Y\t\t--parsedebug\n"
@@ -1850,7 +1761,7 @@ msgstr "\t-Y\t\t--parsedebug\n"
#. for this application. Please add _another line_ with the
#. address for translation bugs.
#. no-wrap
-#: main.c:779
+#: main.c:810
msgid ""
"\n"
"To report bugs, see node `Bugs' in `gawk.info', which is\n"
@@ -1864,7 +1775,7 @@ msgstr ""
"Reporte los errores de los mensajes en español a <es@li.org>.\n"
"\n"
-#: main.c:783
+#: main.c:814
msgid ""
"gawk is a pattern scanning and processing language.\n"
"By default it reads standard input and writes standard output.\n"
@@ -1874,7 +1785,7 @@ msgstr ""
"Por defecto lee la entrada estándar y escribe en la salida estándar.\n"
"\n"
-#: main.c:787
+#: main.c:818
msgid ""
"Examples:\n"
"\tgawk '{ sum += $1 }; END { print sum }' file\n"
@@ -1884,7 +1795,7 @@ msgstr ""
"\tgawk '{ sum += $1 }; END { print sum }' fichero\n"
"\tgawk -F: '{ print $1 }' /etc/passwd\n"
-#: main.c:807
+#: main.c:838
#, c-format
msgid ""
"Copyright (C) 1989, 1991-%d Free Software Foundation.\n"
@@ -1904,7 +1815,7 @@ msgstr ""
"(a su elección) cualquier versión posterior.\n"
"\n"
-#: main.c:815
+#: main.c:846
msgid ""
"This program is distributed in the hope that it will be useful,\n"
"but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
@@ -1918,7 +1829,7 @@ msgstr ""
"Licencia Pública General de GNU para más detalles.\n"
"\n"
-#: main.c:821
+#: main.c:852
msgid ""
"You should have received a copy of the GNU General Public License\n"
"along with this program. If not, see http://www.gnu.org/licenses/.\n"
@@ -1927,16 +1838,16 @@ msgstr ""
"junto con este programa. Si no es así, consulte\n"
"http://www.gnu.org/licenses/.\n"
-#: main.c:856
+#: main.c:887
msgid "-Ft does not set FS to tab in POSIX awk"
msgstr "-Ft no establece FS a tabulador en el awk de POSIX"
-#: main.c:1090
+#: main.c:1133
#, c-format
msgid "unknown value for field spec: %d\n"
msgstr "valor desconocido para la especificación de campo: %d\n"
-#: main.c:1171
+#: main.c:1214
#, c-format
msgid ""
"%s: `%s' argument to `-v' not in `var=value' form\n"
@@ -1945,80 +1856,80 @@ msgstr ""
"%s: el argumento `%s' para `-v' no es de la forma `var=valor'\n"
"\n"
-#: main.c:1197
+#: main.c:1240
#, c-format
msgid "`%s' is not a legal variable name"
msgstr "`%s' no es un nombre de variable legal"
-#: main.c:1200
+#: main.c:1243
#, c-format
msgid "`%s' is not a variable name, looking for file `%s=%s'"
msgstr "`%s' no es un nombre de variable, se busca el fichero `%s=%s'"
-#: main.c:1204
+#: main.c:1247
#, c-format
msgid "cannot use gawk builtin `%s' as variable name"
msgstr ""
"no se puede utilizar la orden interna de gawk `%s' como nombre de variable"
-#: main.c:1209
+#: main.c:1252
#, c-format
msgid "cannot use function `%s' as variable name"
msgstr "no se puede usar la función `%s' como nombre de variable"
-#: main.c:1262
+#: main.c:1305
msgid "floating point exception"
msgstr "excepción de coma flotante"
-#: main.c:1269
+#: main.c:1312
msgid "fatal error: internal error"
msgstr "error fatal: error interno"
-#: main.c:1284
+#: main.c:1327
msgid "fatal error: internal error: segfault"
msgstr "error fatal: error interno: falla de segmentación"
-#: main.c:1296
+#: main.c:1339
msgid "fatal error: internal error: stack overflow"
msgstr "error fatal: error interno: desbordamiento de pila"
-#: main.c:1346
+#: main.c:1393
#, c-format
msgid "no pre-opened fd %d"
msgstr "no existe el df %d abierto previamente"
-#: main.c:1353
+#: main.c:1400
#, c-format
msgid "could not pre-open /dev/null for fd %d"
msgstr "no se puede abrir previamente /dev/null para el df %d"
-#: msg.c:63
+#: msg.c:61
#, c-format
msgid "cmd. line:"
msgstr "línea ord.:"
-#: msg.c:107
+#: msg.c:121
msgid "error: "
msgstr "error: "
-#: node.c:406
+#: node.c:436
msgid "backslash at end of string"
msgstr "barra invertida al final de la cadena"
-#: node.c:517
+#: node.c:520
#, c-format
msgid "old awk does not support the `\\%c' escape sequence"
msgstr "el awk antiguo no admite la secuencia de escape `\\%c'"
-#: node.c:568
+#: node.c:571
msgid "POSIX does not allow `\\x' escapes"
msgstr "POSIX no permite escapes `\\x'"
-#: node.c:574
+#: node.c:577
msgid "no hex digits in `\\x' escape sequence"
msgstr "no hay dígitos hexadecimales en la secuencia de escape `\\x'"
-#: node.c:596
+#: node.c:599
#, c-format
msgid ""
"hex escape \\x%.*s of %d characters probably not interpreted the way you "
@@ -2027,12 +1938,12 @@ msgstr ""
"el escape hexadecimal \\x%.*s de %d caracteres tal vez no se interprete de "
"la forma esperada"
-#: node.c:611
+#: node.c:614
#, c-format
msgid "escape sequence `\\%c' treated as plain `%c'"
msgstr "la secuencia de escape `\\%c' se trata como una simple `%c'"
-#: node.c:750
+#: node.c:759
msgid ""
"Invalid multibyte data detected. There may be a mismatch between your data "
"and your locale."
@@ -2051,16 +1962,16 @@ msgstr ""
msgid "%s %s `%s': could not set close-on-exec: (fcntl F_SETFD: %s)"
msgstr "%s %s `%s': no se puede establecer close-on-exec: (fcntl F_SETFD: %s)"
-#: profile.c:83
+#: profile.c:69
#, c-format
msgid "could not open `%s' for writing: %s"
msgstr "no se puede abrir `%s' para escritura: %s"
-#: profile.c:85
+#: profile.c:71
msgid "sending profile to standard error"
msgstr "se envía el perfil a la salida estándar de error"
-#: profile.c:203
+#: profile.c:187
#, c-format
msgid ""
"\t# %s block(s)\n"
@@ -2069,7 +1980,7 @@ msgstr ""
"\t# bloque(s) %s\n"
"\n"
-#: profile.c:208
+#: profile.c:192
#, c-format
msgid ""
"\t# Rule(s)\n"
@@ -2078,17 +1989,22 @@ msgstr ""
"\t# Regla(s)\n"
"\n"
-#: profile.c:279
+#: profile.c:266
#, c-format
msgid "internal error: %s with null vname"
msgstr "error interno: %s con vname nulo"
-#: profile.c:952
+#: profile.c:528
+#, fuzzy
+msgid "internal error: builtin with null fname"
+msgstr "error interno: %s con vname nulo"
+
+#: profile.c:943
#, c-format
msgid "\t# gawk profile, created %s\n"
msgstr "\t# perfil de gawk, creado %s\n"
-#: profile.c:1331
+#: profile.c:1328
#, c-format
msgid ""
"\n"
@@ -2097,17 +2013,17 @@ msgstr ""
"\n"
"\t# Funciones, enumeradas alfabéticamente\n"
-#: profile.c:1370
+#: profile.c:1366
#, c-format
msgid "redir2str: unknown redirection type %d"
msgstr "redir2str: tipo de redirección %d desconocida"
-#: re.c:573
+#: re.c:571
#, c-format
msgid "range of the form `[%c-%c]' is locale dependent"
msgstr "el rango de la forma `[%c-%c]' depende del local"
-#: re.c:600
+#: re.c:598
#, c-format
msgid "regexp component `%.*s' should probably be `[%.*s]'"
msgstr ""
@@ -2185,6 +2101,79 @@ msgstr ") o \\) desemparejados"
msgid "No previous regular expression"
msgstr "No hay una expresión regular previa"
+#~ msgid "attempt to use function `%s' as an array"
+#~ msgstr "se intentó usar la función `%s' como una matriz"
+
+#~ msgid "reference to uninitialized element `%s[\"%.*s\"]'"
+#~ msgstr "referencia al elemento sin inicializar `%s[\"%.*s\"]'"
+
+#~ msgid "subscript of array `%s' is null string"
+#~ msgstr "el subíndice de la matriz `%s' es la cadena nula"
+
+#~ msgid "%s: empty (null)\n"
+#~ msgstr "%s: vacío (nulo)\n"
+
+#~ msgid "%s: empty (zero)\n"
+#~ msgstr "%s: vacío (cero)\n"
+
+#~ msgid "%s: table_size = %d, array_size = %d\n"
+#~ msgstr "%s: tamaño_tabla = %d, tamaño_matriz = %d\n"
+
+#~ msgid "%s: is parameter\n"
+#~ msgstr "%s: es un parámetro\n"
+
+#~ msgid "%s: array_ref to %s\n"
+#~ msgstr "%s: array_ref a %s\n"
+
+#~ msgid "use of non-array as array"
+#~ msgstr "uso de una matriz que no es matriz"
+
+#~ msgid "can't use function name `%s' as variable or array"
+#~ msgstr ""
+#~ "no se puede usar el nombre de la función `%s' como variable o matriz"
+
+#~ msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
+#~ msgstr "se intentó usar la matriz `%s[\"%.*s\"]' en un contexto escalar"
+
+#~ msgid "assignment used in conditional context"
+#~ msgstr "se usó una asignación en un contexto condicional"
+
+#~ msgid "statement has no effect"
+#~ msgstr "la declaración no tiene efecto"
+
+#~ msgid ""
+#~ "for loop: array `%s' changed size from %ld to %ld during loop execution"
+#~ msgstr ""
+#~ "bucle for: la matriz `%s' cambió de tamaño de %ld a %ld durante la "
+#~ "ejecución del bucle"
+
+#~ msgid "function called indirectly through `%s' does not exist"
+#~ msgstr "no existe la función llamada indirectamente a través de `%s'"
+
+#~ msgid "function `%s' not defined"
+#~ msgstr "la función `%s' no está definida"
+
+#~ msgid "non-redirected `getline' invalid inside `%s' rule"
+#~ msgstr "`getline' no redirigido es inválido dentro de la regla `%s'"
+
+#~ msgid "error reading input file `%s': %s"
+#~ msgstr "error al leer el fichero de entrada `%s': %s"
+
+#~ msgid "`nextfile' cannot be called from a `%s' rule"
+#~ msgstr "`nextfile' no se puede llamar desde una regla `%s'"
+
+#~ msgid "`exit' cannot be called in the current context"
+#~ msgstr "`exit' no se puede llamar en el contexto actual"
+
+#~ msgid "`next' cannot be called from a `%s' rule"
+#~ msgstr "`next' no se puede llamar desde una regla `%s'"
+
+#~ msgid "Sorry, don't know how to interpret `%s'"
+#~ msgstr "Perdón, no se cómo interpretar `%s'"
+
+#~ msgid "\t-R file\t\t\t--command=file\n"
+#~ msgstr "\t-R fichero\t\t\t--command=fichero\n"
+
#~ msgid "could not find groups: %s"
#~ msgstr "no se pueden encontrar los grupos: %s"
diff --git a/po/fi.gmo b/po/fi.gmo
index 75bc4bfb..49a9c274 100644
--- a/po/fi.gmo
+++ b/po/fi.gmo
Binary files differ
diff --git a/po/fi.po b/po/fi.po
index 88eef60e..67dbc058 100644
--- a/po/fi.po
+++ b/po/fi.po
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: gawk 4.0.0h\n"
"Report-Msgid-Bugs-To: arnold@skeeve.com\n"
-"POT-Creation-Date: 2012-03-28 22:03+0200\n"
+"POT-Creation-Date: 2012-04-27 10:06+0300\n"
"PO-Revision-Date: 2012-03-13 18:00+0200\n"
"Last-Translator: Jorma Karvonen <karvonen.jorma@gmail.com>\n"
"Language-Team: Finnish <translation-team-fi@lists.sourceforge.net>\n"
@@ -17,508 +17,465 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
-#: array.c:140
+#: array.c:266
#, c-format
msgid "from %s"
msgstr "taulukosta %s"
-#: array.c:248
+#: array.c:366
msgid "attempt to use a scalar value as array"
msgstr "yritettiin käyttää skalaariarvoa taulukkona"
-#: array.c:251
-#, c-format
-msgid "attempt to use function `%s' as an array"
-msgstr "yritettiin käyttää funktiota â€%s†taulukkona"
-
-#: array.c:254
+#: array.c:368
#, c-format
msgid "attempt to use scalar parameter `%s' as an array"
msgstr "yritettiin käyttää skalaariparametria â€%s†taulukkona"
-#: array.c:257
+#: array.c:371
#, c-format
msgid "attempt to use scalar `%s' as an array"
msgstr "yritettiin käyttää skalaaria â€%s†taulukkona"
-#: array.c:302 array.c:707 builtin.c:84 builtin.c:1385 builtin.c:1427
-#: builtin.c:1440 builtin.c:1859 builtin.c:1871 eval.c:1135 eval.c:1139
-#: eval.c:1495 eval.c:1812
+#: array.c:418 array.c:584 builtin.c:85 builtin.c:1560 builtin.c:1602
+#: builtin.c:1615 builtin.c:2041 builtin.c:2053 eval.c:1109 eval.c:1113
+#: eval.c:1508
#, c-format
msgid "attempt to use array `%s' in a scalar context"
msgstr "yritettiin käyttää taulukkoa â€%s†skalaarikontekstissa"
-#: array.c:513
-#, c-format
-msgid "reference to uninitialized element `%s[\"%.*s\"]'"
-msgstr "viite alustamattomaan elementtiin â€%s[\"%.*s\"]â€"
-
-#: array.c:519
-#, c-format
-msgid "subscript of array `%s' is null string"
-msgstr "taulukon alaindeksi â€%s†on null-merkkijono"
-
-#: array.c:723
+#: array.c:591
#, c-format
msgid "delete: index `%s' not in array `%s'"
msgstr "delete: indeksi â€%s†ei ole taulukossa â€%sâ€"
-#: array.c:734 eval.c:1865
+#: array.c:605
#, c-format
msgid "attempt to use scalar `%s[\"%.*s\"]' as an array"
msgstr "yritettiin käyttää skalaaria â€%s[\"%.*s\"]†taulukkona"
-#: array.c:910
-#, c-format
-msgid "%s: empty (null)\n"
-msgstr "%s: tyhjä (null)\n"
-
-#: array.c:915
-#, c-format
-msgid "%s: empty (zero)\n"
-msgstr "%s: tyhjä (nolla)\n"
-
-#: array.c:919
-#, c-format
-msgid "%s: table_size = %d, array_size = %d\n"
-msgstr "%s: table_size = %d, array_size = %d\n"
-
-#: array.c:954
-#, c-format
-msgid "%s: is parameter\n"
-msgstr "%s: on parametri\n"
-
-#: array.c:958
-#, c-format
-msgid "%s: array_ref to %s\n"
-msgstr "%s: array_ref-viite taulukkoon %s\n"
-
-#: array.c:963
-msgid "adump: argument not an array"
+#: array.c:784
+#, fuzzy
+msgid "adump: first argument not an array"
msgstr "adump: argumentti ei ole taulukko"
-#: array.c:1086
+#: array.c:823
msgid "asort: second argument not an array"
msgstr "asort: toinen argumentti ei ole taulukko"
-#: array.c:1087
+#: array.c:824
msgid "asorti: second argument not an array"
msgstr "asorti: toinen argumentti ei ole taulukko"
-#: array.c:1094
+#: array.c:831
msgid "asort: first argument not an array"
msgstr "asort: ensimmäinen argumentti ei ole taulukko"
-#: array.c:1095
+#: array.c:832
msgid "asorti: first argument not an array"
msgstr "asorti: ensimmäinen argumentti ei ole taulukko"
-#: array.c:1102
+#: array.c:839
msgid "asort: cannot use a subarray of first arg for second arg"
msgstr ""
"asort: ei voida käyttää ensimmäisen argumentin alitaulukkoa toiselle "
"argumentille"
-#: array.c:1103
+#: array.c:840
msgid "asorti: cannot use a subarray of first arg for second arg"
msgstr ""
"asorti: ei voida käyttää ensimmäisen argumentin alitaulukkoa toiselle "
"argumentille"
-#: array.c:1108
+#: array.c:845
msgid "asort: cannot use a subarray of second arg for first arg"
msgstr ""
"asort: ei voida käyttää toisen argumentin alitaulukkoa ensimmäiselle "
"argumentille"
-#: array.c:1109
+#: array.c:846
msgid "asorti: cannot use a subarray of second arg for first arg"
msgstr ""
"asorti: ei voida käyttää toisen argumentin alitaulukkoa ensimmäiselle "
"argumentille"
-#: array.c:1655
+#: array.c:1314
#, c-format
msgid "`%s' is invalid as a function name"
msgstr "â€%s†on virheellinen funktionimenä"
-#: array.c:1659
+#: array.c:1318
#, c-format
msgid "sort comparison function `%s' is not defined"
msgstr "lajitteluvertailufunktiota â€%s†ei ole määritelty"
-#: awkgram.y:249
+#: awkgram.y:223
#, c-format
msgid "%s blocks must have an action part"
msgstr "%s lohkoilla on oltava toiminto-osa"
-#: awkgram.y:252
+#: awkgram.y:226
msgid "each rule must have a pattern or an action part"
msgstr "jokaisella säännöllä on oltava malli tai toiminto-osa"
-#: awkgram.y:323 awkgram.y:334
+#: awkgram.y:295 awkgram.y:306
msgid "old awk does not support multiple `BEGIN' or `END' rules"
msgstr "vanha awk ei tue useita â€BEGINâ€- tai â€ENDâ€-sääntöjä"
-#: awkgram.y:371
+#: awkgram.y:343
#, c-format
msgid "`%s' is a built-in function, it cannot be redefined"
msgstr "â€%s†on sisäänrakennettu funktio. Sitä ei voi määritellä uudelleen"
-#: awkgram.y:432
+#: awkgram.y:389
msgid "regexp constant `//' looks like a C++ comment, but is not"
msgstr ""
"säännöllisen lausekkeen vakio â€//†näyttää C++-kommentilta, mutta ei ole"
-#: awkgram.y:436
+#: awkgram.y:393
#, c-format
msgid "regexp constant `/%s/' looks like a C comment, but is not"
msgstr ""
"säännöllisen lausekkeen vakio â€/%s/†näyttää C-kommentilta, mutta ei ole"
-#: awkgram.y:528
+#: awkgram.y:485
#, c-format
msgid "duplicate case values in switch body: %s"
msgstr "kaksi samanlaista case-arvoa switch-rakenteen rungossa: %s"
-#: awkgram.y:549
+#: awkgram.y:506
msgid "duplicate `default' detected in switch body"
msgstr "kaksoiskappale â€default†havaittu switch-rungossa"
-#: awkgram.y:809
+#: awkgram.y:766
msgid "`break' is not allowed outside a loop or switch"
msgstr "â€break†ei ole sallittu silmukan tai switch-lauseen ulkopuolella"
-#: awkgram.y:818
+#: awkgram.y:775
msgid "`continue' is not allowed outside a loop"
msgstr "â€continue†ei ole sallittu silmukan ulkopuolella"
-#: awkgram.y:828
+#: awkgram.y:785
#, c-format
msgid "`next' used in %s action"
msgstr "â€next†käytetty %s-toiminnossa"
-#: awkgram.y:836
+#: awkgram.y:793
msgid "`nextfile' is a gawk extension"
msgstr "â€nextfile†on gawk-laajennus"
-#: awkgram.y:841
+#: awkgram.y:798
#, c-format
msgid "`nextfile' used in %s action"
msgstr "â€nextfile†käytetty %s-toiminnossa"
-#: awkgram.y:865
+#: awkgram.y:822
msgid "`return' used outside function context"
msgstr "â€return†käytetty funktiokontekstin ulkopuolella"
-#: awkgram.y:925
+#: awkgram.y:896
msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'"
msgstr ""
"pelkkä â€print†BEGIN- tai END-säännössä pitäisi luultavasti olla â€print \"\"â€"
-#: awkgram.y:995 awkgram.y:999 awkgram.y:1023
+#: awkgram.y:966 awkgram.y:970 awkgram.y:994
msgid "`delete array' is a gawk extension"
msgstr "â€delete array†on gawk-laajennus"
-#: awkgram.y:1019
+#: awkgram.y:990
msgid "`delete(array)' is a non-portable tawk extension"
msgstr "â€delete(array)†ei ole siirrettävä tawk-laajennus"
-#: awkgram.y:1135
+#: awkgram.y:1108
msgid "multistage two-way pipelines don't work"
msgstr "monivaiheiset kaksisuuntaiset putket eivät toimi"
-#: awkgram.y:1238
+#: awkgram.y:1211
msgid "regular expression on right of assignment"
msgstr "säännöllinen lauseke sijoituksen oikealla puolella"
-#: awkgram.y:1249
+#: awkgram.y:1222
msgid "regular expression on left of `~' or `!~' operator"
msgstr "säännöllinen lauseke â€~â€- tai â€!~â€-operaattorin vasemmalla puolella"
-#: awkgram.y:1265 awkgram.y:1419
+#: awkgram.y:1238 awkgram.y:1389
msgid "old awk does not support the keyword `in' except after `for'"
msgstr "vanha awk ei tue avainsanaa â€in†paitsi â€forâ€-sanan jälkeen"
-#: awkgram.y:1275
+#: awkgram.y:1248
msgid "regular expression on right of comparison"
msgstr "säännöllinen lauseke vertailun oikealla puolella"
-#: awkgram.y:1394
+#: awkgram.y:1364
#, c-format
msgid "`getline var' invalid inside `%s' rule"
msgstr "â€getline var†virheellinen säännön â€%s†sisällä"
-#: awkgram.y:1397 eval.c:2504
+#: awkgram.y:1367
#, c-format
msgid "`getline' invalid inside `%s' rule"
msgstr "â€getline†virheellinen säännön â€%s†sisällä"
-#: awkgram.y:1402
+#: awkgram.y:1372
msgid "non-redirected `getline' undefined inside END action"
msgstr "edelleenohjaamaton â€getline†määrittelemätön END-toiminnon sisällä"
-#: awkgram.y:1421
+#: awkgram.y:1391
msgid "old awk does not support multidimensional arrays"
msgstr "vanha awk ei tue moniulotteisia taulukkoja"
-#: awkgram.y:1517
+#: awkgram.y:1488
msgid "call of `length' without parentheses is not portable"
msgstr "â€lengthâ€-kutsu ilman sulkumerkkejä ei ole siirrettävä"
-#: awkgram.y:1580
+#: awkgram.y:1554
msgid "indirect function calls are a gawk extension"
msgstr "epäsuorat funktiokutsut ovat gawk-laajennus"
-#: awkgram.y:1593
+#: awkgram.y:1567
#, c-format
msgid "can not use special variable `%s' for indirect function call"
msgstr "ei voi käyttää erikoismuuttujaa â€%s†epäsuoralle funktiokutsulle"
-#: awkgram.y:1671
+#: awkgram.y:1645
msgid "invalid subscript expression"
msgstr "virheellinen indeksointilauseke"
-#: awkgram.y:1711
-msgid "use of non-array as array"
-msgstr "ei-taulukon käyttö taulukkona"
-
-#: awkgram.y:1975 awkgram.y:1995 msg.c:98
+#: awkgram.y:1966 awkgram.y:1986 msg.c:112
msgid "warning: "
msgstr "varoitus:"
-#: awkgram.y:1993 msg.c:130
+#: awkgram.y:1984 msg.c:144
msgid "fatal: "
msgstr "tuhoisa:"
-#: awkgram.y:2043
+#: awkgram.y:2034
msgid "unexpected newline or end of string"
msgstr "odottamaton rivinvaihto tai merkkijonon loppu"
-#: awkgram.y:2300 awkgram.y:2358 awkgram.y:2542
+#: awkgram.y:2299 awkgram.y:2357 awkgram.y:2545
#, c-format
msgid "can't open source file `%s' for reading (%s)"
msgstr "ei voi avata lähdetiedostoa â€%s†lukemista varten (%s)"
-#: awkgram.y:2301 awkgram.y:2359 builtin.c:122
+#: awkgram.y:2300 awkgram.y:2358 builtin.c:124
msgid "reason unknown"
msgstr "syy tuntematon"
-#: awkgram.y:2317
+#: awkgram.y:2316
#, c-format
msgid "already included source file `%s'"
msgstr "on jo sisällytetty lähdetiedostoon â€%sâ€"
-#: awkgram.y:2343
+#: awkgram.y:2342
msgid "@include is a gawk extension"
msgstr "@include on gawk-laajennus"
-#: awkgram.y:2349
+#: awkgram.y:2348
msgid "empty filename after @include"
msgstr "tyhjä tiedostonimi @include:n jälkeen"
-#: awkgram.y:2494
+#: awkgram.y:2497
msgid "empty program text on command line"
msgstr "tyhjä ohjelmateksti komentorivillä"
-#: awkgram.y:2609
+#: awkgram.y:2612
#, c-format
msgid "can't read sourcefile `%s' (%s)"
msgstr "ei voi lukea lähdetiedostoa â€%s†(%s)"
-#: awkgram.y:2620
+#: awkgram.y:2623
#, c-format
msgid "source file `%s' is empty"
msgstr "lähdetiedosto â€%s†on tyhjä"
-#: awkgram.y:2797
+#: awkgram.y:2800
msgid "source file does not end in newline"
msgstr "lähdetiedoston lopussa ei ole rivinvaihtoa"
-#: awkgram.y:2900
+#: awkgram.y:2905
msgid "unterminated regexp ends with `\\' at end of file"
msgstr ""
"päättämätön säännöllinen lauseke loppuu â€\\â€-merkkeihin tiedoston lopussa"
-#: awkgram.y:2924
+#: awkgram.y:2929
#, c-format
msgid "%s: %d: tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr "%s: %d: tawk:n regex-määre â€/.../%c†ei toimi gawk:ssa"
-#: awkgram.y:2928
+#: awkgram.y:2933
#, c-format
msgid "tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr "tawkin regex-määre â€/.../%c†ei toimi gawkissa"
-#: awkgram.y:2935
+#: awkgram.y:2940
msgid "unterminated regexp"
msgstr "päättämätön säännöllinen lauseke"
-#: awkgram.y:2939
+#: awkgram.y:2944
msgid "unterminated regexp at end of file"
msgstr "päättämätön säännöllinen lauseke tiedoston lopussa"
-#: awkgram.y:2998
+#: awkgram.y:3003
msgid "use of `\\ #...' line continuation is not portable"
msgstr "â€\\ #...â€-rivijatkamisen käyttö ei ole siirrettävä"
-#: awkgram.y:3014
+#: awkgram.y:3019
msgid "backslash not last character on line"
msgstr "kenoviiva ei ole rivin viimeinen merkki"
-#: awkgram.y:3075
+#: awkgram.y:3080
msgid "POSIX does not allow operator `**='"
msgstr "POSIX ei salli operaattoria â€**=â€"
-#: awkgram.y:3077
+#: awkgram.y:3082
msgid "old awk does not support operator `**='"
msgstr "vanha awk ei tue operaattoria â€**=â€"
-#: awkgram.y:3086
+#: awkgram.y:3091
msgid "POSIX does not allow operator `**'"
msgstr "POSIX ei salli operaattoria â€**â€"
-#: awkgram.y:3088
+#: awkgram.y:3093
msgid "old awk does not support operator `**'"
msgstr "vanha awk ei tue operaattoria â€**â€"
-#: awkgram.y:3123
+#: awkgram.y:3128
msgid "operator `^=' is not supported in old awk"
msgstr "operaattoria â€^=†ei tueta vanhassa awk:ssa"
-#: awkgram.y:3131
+#: awkgram.y:3136
msgid "operator `^' is not supported in old awk"
msgstr "operaattoria â€^†ei tueta vanhassa awk:ssa"
-#: awkgram.y:3224 awkgram.y:3240
+#: awkgram.y:3229 awkgram.y:3245
msgid "unterminated string"
msgstr "päättämätön merkkijono"
-#: awkgram.y:3436
+#: awkgram.y:3466
#, c-format
msgid "invalid char '%c' in expression"
msgstr "virheellinen merkki ’%c’ lausekkeessa"
-#: awkgram.y:3483
+#: awkgram.y:3513
#, c-format
msgid "`%s' is a gawk extension"
msgstr "â€%s†on gawk-laajennus"
-#: awkgram.y:3488
+#: awkgram.y:3518
#, c-format
msgid "`%s' is a Bell Labs extension"
msgstr "â€%s†on Bell Labs -laajennus"
-#: awkgram.y:3493
+#: awkgram.y:3523
#, c-format
msgid "POSIX does not allow `%s'"
msgstr "POSIX ei salli operaattori â€%sâ€"
-#: awkgram.y:3501
+#: awkgram.y:3531
#, c-format
msgid "`%s' is not supported in old awk"
msgstr "â€%s†ei ole tuettu vanhassa awk-ohjelmassa"
-#: awkgram.y:3568
+#: awkgram.y:3598
msgid "`goto' considered harmful!\n"
msgstr "â€gotoâ€-käskyä pidetään haitallisena!\n"
-#: awkgram.y:3619
+#: awkgram.y:3632
#, c-format
msgid "%d is invalid as number of arguments for %s"
msgstr "%d on virheellinen argumenttilukumäärä operaattorille %s"
-#: awkgram.y:3654
+#: awkgram.y:3667
#, c-format
msgid "%s: string literal as last arg of substitute has no effect"
msgstr ""
"%s: merkkijonoliteraalilla ei ole vaikutusta korvauksen viimeisenä "
"argumenttina"
-#: awkgram.y:3659
+#: awkgram.y:3672
#, c-format
msgid "%s third parameter is not a changeable object"
msgstr "%s kolmas parametri ei ole vaihdettava objekti"
-#: awkgram.y:3732 awkgram.y:3735
+#: awkgram.y:3751 awkgram.y:3754
msgid "match: third argument is a gawk extension"
msgstr "match: kolmas argumentti on gawk-laajennus"
-#: awkgram.y:3789 awkgram.y:3792
+#: awkgram.y:3808 awkgram.y:3811
msgid "close: second argument is a gawk extension"
msgstr "close: toinen argumentti on gawk-laajennus"
-#: awkgram.y:3804
+#: awkgram.y:3823
msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore"
msgstr "dcgettext(_\"...\")-käyttö on virheellinen: poista alaviiva alusta"
-#: awkgram.y:3819
+#: awkgram.y:3838
msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore"
msgstr "dcngettext(_\"...\")-käyttö on virheellinen: poista alaviiva alusta"
-#: awkgram.y:3911
-#, c-format
-msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
-msgstr "funktio â€%sâ€: parametri #%d, â€%sâ€, samanlainen parametri #%d"
-
-#: awkgram.y:3953
+#: awkgram.y:3904
#, c-format
msgid "function `%s': parameter `%s' shadows global variable"
msgstr "funktio â€%sâ€: parametri â€%s†varjostaa yleismuuttujaa"
-#: awkgram.y:4111
+#: awkgram.y:3961
#, c-format
msgid "could not open `%s' for writing (%s)"
msgstr "ei voitu avata tiedostoa â€%s†kirjoittamista varten (%s)"
-#: awkgram.y:4112
+#: awkgram.y:3962
msgid "sending variable list to standard error"
msgstr "lähetetään muuttujaluettelo vakiovirheeseen"
-#: awkgram.y:4118
+#: awkgram.y:3970
#, c-format
msgid "%s: close failed (%s)"
msgstr "%s: sulkeminen epäonnistui (%s)"
-#: awkgram.y:4170
+#: awkgram.y:3995
msgid "shadow_funcs() called twice!"
msgstr "shadow_funcs() kutsuttu kahdesti!"
-#: awkgram.y:4176
+#: awkgram.y:4003
msgid "there were shadowed variables."
msgstr "siellä oli varjostettuja muuttujia."
-#: awkgram.y:4206
+#: awkgram.y:4074
+#, c-format
+msgid "function name `%s' previously defined"
+msgstr "funktionimi â€%s†on jo aikaisemmin määritelty"
+
+#: awkgram.y:4120
#, c-format
msgid "function `%s': can't use function name as parameter name"
msgstr "funktio â€%sâ€: ei voi käyttää funktionimeä parametrinimenä"
-#: awkgram.y:4210
+#: awkgram.y:4123
#, c-format
msgid "function `%s': can't use special variable `%s' as a function parameter"
msgstr "funktio â€%sâ€: ei voi käyttää erikoismuuttujaa â€%s†funktioparametrina"
-#: awkgram.y:4226
+#: awkgram.y:4131
#, c-format
-msgid "function name `%s' previously defined"
-msgstr "funktionimi â€%s†on jo aikaisemmin määritelty"
+msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
+msgstr "funktio â€%sâ€: parametri #%d, â€%sâ€, samanlainen parametri #%d"
-#: awkgram.y:4394 awkgram.y:4400
+#: awkgram.y:4210 awkgram.y:4216
#, c-format
msgid "function `%s' called but never defined"
msgstr "funktiota â€%s†kutsuttiin, mutta sitä ei ole koskaan määritelty"
-#: awkgram.y:4403
+#: awkgram.y:4219
#, c-format
msgid "function `%s' defined but never called directly"
msgstr "funktio â€%s†määriteltiin, mutta sitä ei ole koskaan kutsuttu suoraan"
-#: awkgram.y:4435
+#: awkgram.y:4251
#, c-format
msgid "regexp constant for parameter #%d yields boolean value"
msgstr "säännöllisen lausekkeen vakio parametrille #%d antaa boolean-arvon"
-#: awkgram.y:4544
+#: awkgram.y:4297
#, c-format
msgid ""
"function `%s' called with space between name and `(',\n"
@@ -527,235 +484,235 @@ msgstr ""
"funktio â€%s†kutsuttu välilyönnillä nimen ja â€(â€-merkin\n"
"välillä, tai käytetty muuttujana tai taulukkona"
-#: awkgram.y:4791 eval.c:2056
+#: awkgram.y:4505
msgid "division by zero attempted"
msgstr "nollalla jakoa yritettiin"
-#: awkgram.y:4800 eval.c:2072
+#: awkgram.y:4514
#, c-format
msgid "division by zero attempted in `%%'"
msgstr "jakoa nollalla yritettiin operaattorissa â€%%â€"
# kohteena voi olla vakiotuloste tai joku muu
-#: builtin.c:120
+#: builtin.c:122
#, c-format
msgid "%s to \"%s\" failed (%s)"
msgstr "%s kohteeseen â€%s†epäonnistui (%s)"
-#: builtin.c:121
+#: builtin.c:123
msgid "standard output"
msgstr "vakiotuloste"
-#: builtin.c:135
+#: builtin.c:137
msgid "exp: received non-numeric argument"
msgstr "exp: vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:141
+#: builtin.c:143
#, c-format
msgid "exp: argument %g is out of range"
msgstr "exp: argumentti %g on lukualueen ulkopuolella"
-#: builtin.c:200
+#: builtin.c:202
#, c-format
msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing"
msgstr ""
"fflush: ei voi tyhjentää: putki â€%s†avattu lukemista varten, ei "
"kirjoittamiseen"
-#: builtin.c:203
+#: builtin.c:205
#, c-format
msgid "fflush: cannot flush: file `%s' opened for reading, not writing"
msgstr ""
"fflush: ei voi tyhjentää: tiedosto â€%s†avattu lukemista varten, ei "
"kirjoittamiseen"
-#: builtin.c:215
+#: builtin.c:217
#, c-format
msgid "fflush: `%s' is not an open file, pipe or co-process"
msgstr "fflush: â€%s†ei ole avoin tiedosto, putki tai apuprosessi"
-#: builtin.c:333
+#: builtin.c:335
msgid "index: received non-string first argument"
msgstr "index: ensimmäinen vastaanotettu argumentti ei ole merkkijono"
-#: builtin.c:335
+#: builtin.c:337
msgid "index: received non-string second argument"
msgstr "index: toinen vastaanotettu argumentti ei ole merkkijono"
-#: builtin.c:457
+#: builtin.c:461
msgid "int: received non-numeric argument"
msgstr "int: vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:493
+#: builtin.c:497
msgid "length: received array argument"
msgstr "length: vastaanotettu taulukkoargumentti"
-#: builtin.c:496
+#: builtin.c:500
msgid "`length(array)' is a gawk extension"
msgstr "â€length(array)†on gawk-laajennus"
-#: builtin.c:504
+#: builtin.c:508
msgid "length: received non-string argument"
msgstr "length: vastaanotettu argumentti ei ole merkkijono"
-#: builtin.c:535
+#: builtin.c:539
msgid "log: received non-numeric argument"
msgstr "log: vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:538
+#: builtin.c:542
#, c-format
msgid "log: received negative argument %g"
msgstr "log: vastaanotettu negatiivinen argumentti %g"
-#: builtin.c:694 builtin.c:699
+#: builtin.c:740 builtin.c:745
msgid "fatal: must use `count$' on all formats or none"
msgstr "kohtalokas: on käytettävä â€count$†kaikilla muodoilla tai ei missään"
-#: builtin.c:762
+#: builtin.c:815
#, c-format
msgid "field width is ignored for `%%' specifier"
msgstr "kenttäleveys ohitetaan â€%%%%â€-määritteelle"
-#: builtin.c:764
+#: builtin.c:817
#, c-format
msgid "precision is ignored for `%%' specifier"
msgstr "tarkkuus ohitetaan â€%%%%â€-määritteelle"
-#: builtin.c:766
+#: builtin.c:819
#, c-format
msgid "field width and precision are ignored for `%%' specifier"
msgstr "kenttäleveys ja tarkkuus ohitetaan â€%%%%â€-määritteelle"
-#: builtin.c:817
+#: builtin.c:870
msgid "fatal: `$' is not permitted in awk formats"
msgstr "kohtalokas: â€$â€-argumentti ei ole sallittu awk-muodoissa"
-#: builtin.c:826
+#: builtin.c:879
msgid "fatal: arg count with `$' must be > 0"
msgstr "kohtalokas: argumenttilukumäärän argumentilla â€$†on oltava > 0"
-#: builtin.c:830
+#: builtin.c:883
#, c-format
msgid "fatal: arg count %ld greater than total number of supplied arguments"
msgstr ""
"kohtalokas: argumenttilukumäärä %ld on suurempi kuin toimitettujen "
"argumenttien lukumäärä"
-#: builtin.c:834
+#: builtin.c:887
msgid "fatal: `$' not permitted after period in format"
msgstr "kohtalokas: â€$â€-argumentti ei ole sallittu pisteen jälkeen muodossa"
-#: builtin.c:850
+#: builtin.c:903
msgid "fatal: no `$' supplied for positional field width or precision"
msgstr ""
"kohtalokas: ei â€$â€-argumenttia tarjottu sijantikenttäleveydelle tai "
"tarkkuudelle"
-#: builtin.c:921
+#: builtin.c:975
msgid "`l' is meaningless in awk formats; ignored"
msgstr "â€l†on merkityksetön awk-muodoissa; ohitetaan"
-#: builtin.c:925
+#: builtin.c:979
msgid "fatal: `l' is not permitted in POSIX awk formats"
msgstr "kohtalokas: â€l†ei ole sallittu POSIX awk -muodoissa"
-#: builtin.c:938
+#: builtin.c:992
msgid "`L' is meaningless in awk formats; ignored"
msgstr "â€L†on merkityksetön awk-muodoissa; ohitetaan"
-#: builtin.c:942
+#: builtin.c:996
msgid "fatal: `L' is not permitted in POSIX awk formats"
msgstr "kohtalokas: â€L†ei ole sallittu POSIX awk -muodoissa"
-#: builtin.c:955
+#: builtin.c:1009
msgid "`h' is meaningless in awk formats; ignored"
msgstr "â€h†on merkityksetön awk-muodoissa; ohitetaan"
-#: builtin.c:959
+#: builtin.c:1013
msgid "fatal: `h' is not permitted in POSIX awk formats"
msgstr "kohtalokas: â€h†ei ole sallittu POSIX awk -muodoissa"
-#: builtin.c:1272
+#: builtin.c:1408
#, c-format
msgid "[s]printf: value %g is out of range for `%%%c' format"
msgstr "[s]printf: arvo %g on lukualueen ulkopuolella â€%%%câ€-muodolle"
-#: builtin.c:1332
+#: builtin.c:1506
#, c-format
msgid "ignoring unknown format specifier character `%c': no argument converted"
msgstr ""
"ohitetaan tuntematon muotoargumenttimerkki â€%câ€: ei muunnettu argumenttia"
-#: builtin.c:1337
+#: builtin.c:1511
msgid "fatal: not enough arguments to satisfy format string"
msgstr "kohtalokas: ei kylliksi argumentteja muotomerkkijonon tyydyttämiseksi"
-#: builtin.c:1339
+#: builtin.c:1513
msgid "^ ran out for this one"
msgstr "^ tällainen loppui kesken"
-#: builtin.c:1346
+#: builtin.c:1520
msgid "[s]printf: format specifier does not have control letter"
msgstr "[s]printf: muotoargumentilla ei ole ohjauskirjainta"
-#: builtin.c:1349
+#: builtin.c:1523
msgid "too many arguments supplied for format string"
msgstr "muotomerkkijonoon toimitettu liian monta argumenttia"
-#: builtin.c:1423 builtin.c:1434
+#: builtin.c:1598 builtin.c:1609
msgid "printf: no arguments"
msgstr "printf: ei argumentteja"
-#: builtin.c:1475
+#: builtin.c:1650
msgid "sqrt: received non-numeric argument"
msgstr "sqrt: vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:1479
+#: builtin.c:1654
#, c-format
msgid "sqrt: called with negative argument %g"
msgstr "sqrt: kutsuttu negatiivisella argumentilla %g"
-#: builtin.c:1503
+#: builtin.c:1685
#, c-format
msgid "substr: length %g is not >= 1"
msgstr "substr: pituus %g ei ole >= 1"
-#: builtin.c:1505
+#: builtin.c:1687
#, c-format
msgid "substr: length %g is not >= 0"
msgstr "substr: pituus %g ei ole >= 0"
-#: builtin.c:1512
+#: builtin.c:1694
#, c-format
msgid "substr: non-integer length %g will be truncated"
msgstr "substr: typistetään pituus %g, joka ei ole kokonaisluku"
-#: builtin.c:1517
+#: builtin.c:1699
#, c-format
msgid "substr: length %g too big for string indexing, truncating to %g"
msgstr ""
"substr: pituus %g liian suuri merkkijononindeksointiin, typistetään arvoon %g"
-#: builtin.c:1529
+#: builtin.c:1711
#, c-format
msgid "substr: start index %g is invalid, using 1"
msgstr "substr: aloitusindeksi %g on virheellinen, käytetään 1:tä"
-#: builtin.c:1534
+#: builtin.c:1716
#, c-format
msgid "substr: non-integer start index %g will be truncated"
msgstr "substr: typistetään aloitusindeksi %g, joka ei ole kokonaisluku"
-#: builtin.c:1559
+#: builtin.c:1741
msgid "substr: source string is zero length"
msgstr "substr: lähdemerkkijono on nollapituinen"
-#: builtin.c:1575
+#: builtin.c:1757
#, c-format
msgid "substr: start index %g is past end of string"
msgstr "substr: aloitusindeksi %g on merkkijonon lopun jälkeen"
-#: builtin.c:1583
+#: builtin.c:1765
#, c-format
msgid ""
"substr: length %g at start index %g exceeds length of first argument (%lu)"
@@ -763,230 +720,225 @@ msgstr ""
"substr: pituus %g alkuindeksissä %g ylittää ensimmäisen argumentin pituuden "
"(%lu)"
-#: builtin.c:1657
+#: builtin.c:1839
msgid "strftime: format value in PROCINFO[\"strftime\"] has numeric type"
msgstr ""
"strftime: muotoarvolla kohteessa PROCINFO[\"strftime\"] on numerotyyppi"
-#: builtin.c:1680
+#: builtin.c:1862
msgid "strftime: received non-numeric second argument"
msgstr "strftime: toinen vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:1683
+#: builtin.c:1866
msgid "strftime: second argument less than 0 or too big for time_t"
msgstr ""
"strftime: toinen argumentti on pienempi kuin 0 tai liian suuri time_t-"
"rakenteeseen"
-#: builtin.c:1690
+#: builtin.c:1873
msgid "strftime: received non-string first argument"
msgstr "strftime: ensimmäinen vastaanotettu argumentti ei ole merkkijono"
-#: builtin.c:1696
+#: builtin.c:1880
msgid "strftime: received empty format string"
msgstr "strftime: vastaanotettu tyhjä muotomerkkijono"
-#: builtin.c:1762
+#: builtin.c:1946
msgid "mktime: received non-string argument"
msgstr "mktime: vastaanotettu argumentti ei ole merkkijono"
-#: builtin.c:1779
+#: builtin.c:1963
msgid "mktime: at least one of the values is out of the default range"
msgstr "mktime: vähintään yksi arvoista on oletuslukualueen ulkopuolella"
-#: builtin.c:1814
+#: builtin.c:1998
msgid "'system' function not allowed in sandbox mode"
msgstr "â€systemâ€-funktio ei ole sallittu hiekkalaatikkotilassa"
-#: builtin.c:1819
+#: builtin.c:2003
msgid "system: received non-string argument"
msgstr "system: vastaanotettu argumentti ei ole merkkijono"
-#: builtin.c:1874 eval.c:1159 eval.c:1790 eval.c:1803
-#, c-format
-msgid "reference to uninitialized variable `%s'"
-msgstr "viite alustamattomaan muuttujaan â€%sâ€"
-
-#: builtin.c:1941
+#: builtin.c:2121
#, c-format
msgid "reference to uninitialized field `$%d'"
msgstr "viite alustamattomaan kenttään â€$%dâ€"
-#: builtin.c:2028
+#: builtin.c:2208
msgid "tolower: received non-string argument"
msgstr "tolower: vastaanotettu argumentti ei ole merkkijono"
-#: builtin.c:2062
+#: builtin.c:2242
msgid "toupper: received non-string argument"
msgstr "toupper: vastaanotettu argumentti ei ole merkkijono"
-#: builtin.c:2098
+#: builtin.c:2278
msgid "atan2: received non-numeric first argument"
msgstr "atan2: ensimmäinen vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:2100
+#: builtin.c:2280
msgid "atan2: received non-numeric second argument"
msgstr "atan2: toinen vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:2119
+#: builtin.c:2299
msgid "sin: received non-numeric argument"
msgstr "sin: vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:2135
+#: builtin.c:2315
msgid "cos: received non-numeric argument"
msgstr "cos: vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:2188
+#: builtin.c:2368
msgid "srand: received non-numeric argument"
msgstr "srand: vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:2219
+#: builtin.c:2399
msgid "match: third argument is not an array"
msgstr "match: kolmas argumentti ei ole taulukko"
-#: builtin.c:2483
+#: builtin.c:2664
msgid "gensub: third argument of 0 treated as 1"
msgstr "gensub: 0-arvoinen kolmas argumentti käsitellään kuin 1"
-#: builtin.c:2776
+#: builtin.c:2957
msgid "lshift: received non-numeric first argument"
msgstr "lshift: ensimmäinen vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:2778
+#: builtin.c:2959
msgid "lshift: received non-numeric second argument"
msgstr "lshift: toinen vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:2784
+#: builtin.c:2965
#, c-format
msgid "lshift(%lf, %lf): negative values will give strange results"
msgstr "lshift(%lf, %lf): negatiiviset arvot antavat outoja tuloksia"
-#: builtin.c:2786
+#: builtin.c:2967
#, c-format
msgid "lshift(%lf, %lf): fractional values will be truncated"
msgstr "lshift(%lf, %lf): jaosarvot typistetään"
-#: builtin.c:2788
+#: builtin.c:2969
#, c-format
msgid "lshift(%lf, %lf): too large shift value will give strange results"
msgstr "lshift(%lf, %lf): liian suuri siirrosarvo antaa outoja tuloksia"
-#: builtin.c:2813
+#: builtin.c:2994
msgid "rshift: received non-numeric first argument"
msgstr "rshift: ensimmäinen vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:2815
+#: builtin.c:2996
msgid "rshift: received non-numeric second argument"
msgstr "rshift: toinen vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:2821
+#: builtin.c:3002
#, c-format
msgid "rshift(%lf, %lf): negative values will give strange results"
msgstr "rshift(%lf, %lf): negatiiviset arvot antavat outoja tuloksia"
-#: builtin.c:2823
+#: builtin.c:3004
#, c-format
msgid "rshift(%lf, %lf): fractional values will be truncated"
msgstr "rshift(%lf, %lf): jaosarvot typistetään"
-#: builtin.c:2825
+#: builtin.c:3006
#, c-format
msgid "rshift(%lf, %lf): too large shift value will give strange results"
msgstr "rshift(%lf, %lf): liian suuri siirrosarvo antaa outoja tuloksia"
-#: builtin.c:2850
+#: builtin.c:3031
msgid "and: received non-numeric first argument"
msgstr "and: ensimmäinen vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:2852
+#: builtin.c:3033
msgid "and: received non-numeric second argument"
msgstr "and: toinen vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:2858
+#: builtin.c:3039
#, c-format
msgid "and(%lf, %lf): negative values will give strange results"
msgstr "and(%lf, %lf): negatiiviset arvot antavat outoja tuloksia"
-#: builtin.c:2860
+#: builtin.c:3041
#, c-format
msgid "and(%lf, %lf): fractional values will be truncated"
msgstr "and(%lf, %lf): jaosarvot typistetään"
-#: builtin.c:2885
+#: builtin.c:3066
msgid "or: received non-numeric first argument"
msgstr "or: ensimmäinen vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:2887
+#: builtin.c:3068
msgid "or: received non-numeric second argument"
msgstr "or: toinen vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:2893
+#: builtin.c:3074
#, c-format
msgid "or(%lf, %lf): negative values will give strange results"
msgstr "or(%lf, %lf): negatiiviset arvot antavat outoja tuloksia"
-#: builtin.c:2895
+#: builtin.c:3076
#, c-format
msgid "or(%lf, %lf): fractional values will be truncated"
msgstr "or(%lf, %lf): jaosarvot typistetään"
-#: builtin.c:2923
+#: builtin.c:3102
msgid "xor: received non-numeric first argument"
msgstr "xor: ensimmäinen vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:2925
+#: builtin.c:3104
msgid "xor: received non-numeric second argument"
msgstr "xor: toinen vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:2931
+#: builtin.c:3110
#, c-format
msgid "xor(%lf, %lf): negative values will give strange results"
msgstr "xor(%lf, %lf): negatiiviset arvot antavat outoja tuloksia"
-#: builtin.c:2933
+#: builtin.c:3112
#, c-format
msgid "xor(%lf, %lf): fractional values will be truncated"
msgstr "xor(%lf, %lf): jaosarvot typistetään"
-#: builtin.c:2957 builtin.c:2963
+#: builtin.c:3136
msgid "compl: received non-numeric argument"
msgstr "compl: vastaanotettu argumentti ei ole numeerinen"
-#: builtin.c:2965
+#: builtin.c:3142
#, c-format
msgid "compl(%lf): negative value will give strange results"
msgstr "compl(%lf): negatiiviset arvot antavat outoja tuloksia"
-#: builtin.c:2967
+#: builtin.c:3144
#, c-format
msgid "compl(%lf): fractional value will be truncated"
msgstr "compl(%lf): jaosarvo typistetään"
-#: builtin.c:3136
+#: builtin.c:3313
#, c-format
msgid "dcgettext: `%s' is not a valid locale category"
msgstr "dcgettext: â€%s†ei ole kelvollinen paikallinen kategoria"
-#: eval.c:412
+#: eval.c:395
#, c-format
msgid "unknown nodetype %d"
msgstr "tuntematon solmutyyppi %d"
-#: eval.c:423 eval.c:437
+#: eval.c:406 eval.c:420
#, c-format
msgid "unknown opcode %d"
msgstr "tuntematon käskykoodi %d"
-#: eval.c:434
+#: eval.c:417
#, c-format
msgid "opcode %s not an operator or keyword"
msgstr "käskykoodi %s ei ole operaattori tai avainsana"
-#: eval.c:488
+#: eval.c:472
msgid "buffer overflow in genflags2str"
msgstr "puskurin ylivuoto funktiossa genflags2str"
-#: eval.c:698
+#: eval.c:675
#, c-format
msgid ""
"\n"
@@ -997,306 +949,250 @@ msgstr ""
"\t# Funktiokutsupino:\n"
"\n"
-#: eval.c:725
+#: eval.c:704
msgid "`IGNORECASE' is a gawk extension"
msgstr "â€IGNORECASE†on gawk-laajennus"
-#: eval.c:754
+#: eval.c:736
msgid "`BINMODE' is a gawk extension"
msgstr "â€BINMODE†on gawk-laajennus"
-#: eval.c:812
+#: eval.c:793
#, c-format
msgid "BINMODE value `%s' is invalid, treated as 3"
msgstr "BINMODE-arvo â€%s†on virheellinen, käsiteltiin arvona 3"
-#: eval.c:902
+#: eval.c:885
#, c-format
msgid "bad `%sFMT' specification `%s'"
msgstr "väärä â€%sFMTâ€-määritys â€%sâ€"
-#: eval.c:980
+#: eval.c:969
msgid "turning off `--lint' due to assignment to `LINT'"
msgstr "käännetään pois â€--lintâ€-valitsin â€LINTâ€-sijoituksen vuoksi"
-#: eval.c:1127 eval.c:1777
-#, c-format
-msgid "can't use function name `%s' as variable or array"
-msgstr "funktionimeä â€%s†ei voi käyttää muuttujana tai taulukkona"
-
-#: eval.c:1158 eval.c:1789 eval.c:1802
+#: eval.c:1132
#, c-format
msgid "reference to uninitialized argument `%s'"
msgstr "viite alustamattomaan argumenttiin â€%sâ€"
-#: eval.c:1177
+#: eval.c:1133
+#, c-format
+msgid "reference to uninitialized variable `%s'"
+msgstr "viite alustamattomaan muuttujaan â€%sâ€"
+
+#: eval.c:1151
msgid "attempt to field reference from non-numeric value"
msgstr "yritettiin kenttäviitettä arvosta, joka ei ole numeerinen"
-#: eval.c:1179
+#: eval.c:1153
msgid "attempt to field reference from null string"
msgstr "yritettiin kenttäviitettä null-merkkijonosta"
-#: eval.c:1185
+#: eval.c:1161
#, c-format
msgid "attempt to access field %ld"
msgstr "yritettiin saantia kenttään %ld"
-#: eval.c:1194
+#: eval.c:1170
#, c-format
msgid "reference to uninitialized field `$%ld'"
msgstr "viite alustamattomaan kenttään â€$%ldâ€"
-#: eval.c:1256
+#: eval.c:1257
#, c-format
msgid "function `%s' called with more arguments than declared"
msgstr "funktio â€%s†kutsuttiin useammalla argumentilla kuin esiteltiin"
-#: eval.c:1437
+#: eval.c:1452
#, c-format
msgid "unwind_stack: unexpected type `%s'"
msgstr "unwind_stack: odottamaton tyyppi â€%sâ€"
-#: eval.c:1532
+#: eval.c:1546
msgid "division by zero attempted in `/='"
msgstr "jakoa nollalla yritettiin operaatiossa â€/=â€"
-#: eval.c:1539
+#: eval.c:1553
#, c-format
msgid "division by zero attempted in `%%='"
msgstr "jakoa nollalla yritettiin operaatiossa â€%%=â€"
-#: eval.c:1876 eval.c:2122
-#, c-format
-msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
-msgstr "yritettiin käyttää taulukkoa â€%s[\"%.*s\"]†skalaarikontekstissa"
-
-#: eval.c:1907
-msgid "assignment used in conditional context"
-msgstr "sijoitusta käytetty ehdollisessa kontekstissa"
-
-#: eval.c:1911
-msgid "statement has no effect"
-msgstr "käskyllä ei ole vaikutusta"
-
-#: eval.c:2343
-#, c-format
-msgid "for loop: array `%s' changed size from %ld to %ld during loop execution"
-msgstr ""
-"for-silmukka: taulukon â€%s†koko muuttui arvosta %ld arvoon %ld silmukan "
-"suorituksen aikana"
-
-#: eval.c:2458
-#, c-format
-msgid "function called indirectly through `%s' does not exist"
-msgstr "kohteen â€%s†kautta epäsuorasti kutsuttu funktio ei ole olemassa"
-
-#: eval.c:2470
-#, c-format
-msgid "function `%s' not defined"
-msgstr "funktio â€%s†ei ole määritelty"
-
-#: eval.c:2511
-#, c-format
-msgid "non-redirected `getline' invalid inside `%s' rule"
-msgstr "edelleenohjaamaton â€getline†virheellinen â€%sâ€-säännön sisällä"
-
-#: eval.c:2600
-#, c-format
-msgid "error reading input file `%s': %s"
-msgstr "virhe luettaessa syötetiedostoa â€%sâ€: %s"
-
-#: eval.c:2614
-#, c-format
-msgid "`nextfile' cannot be called from a `%s' rule"
-msgstr "â€nextfile†ei voida kutsua â€%sâ€-säännöstä"
-
-#: eval.c:2661
-msgid "`exit' cannot be called in the current context"
-msgstr "â€exit†ei voida kutsua nykyisessä asiayhteydessä"
-
-#: eval.c:2700
-#, c-format
-msgid "`next' cannot be called from a `%s' rule"
-msgstr "â€next†ei voida kutsua â€%sâ€-säännöstä"
-
-#: eval.c:2766
-#, c-format
-msgid "Sorry, don't know how to interpret `%s'"
-msgstr "Ei osata tulkita kohdetta â€%sâ€"
-
-#: ext.c:54
+#: ext.c:70
msgid "extensions are not allowed in sandbox mode"
msgstr "laajennuksia ei sallita hiekkalaatikkotilassa"
-#: ext.c:60 ext.c:65
+#: ext.c:73
msgid "`extension' is a gawk extension"
msgstr "â€extension†on gawk-laajennus"
-#: ext.c:75
-#, c-format
-msgid "fatal: extension: cannot open `%s' (%s)\n"
+#: ext.c:80
+#, fuzzy, c-format
+msgid "extension: cannot open library `%s' (%s)\n"
msgstr "tuhoisa: extension: ei voi avata solmua â€%s†(%s)\n"
-#: ext.c:84
-#, c-format
+#: ext.c:86
+#, fuzzy, c-format
msgid ""
-"fatal: extension: library `%s': does not define "
-"`plugin_is_GPL_compatible' (%s)\n"
+"extension: library `%s': does not define `plugin_is_GPL_compatible' (%s)\n"
msgstr ""
"tuhoisa: extension: kirjasto â€%sâ€: ei määrittele "
"â€plugin_is_GPL_compatible†(%s)\n"
-#: ext.c:93
-#, c-format
-msgid "fatal: extension: library `%s': cannot call function `%s' (%s)\n"
+#: ext.c:90
+#, fuzzy, c-format
+msgid "extension: library `%s': cannot call function `%s' (%s)\n"
msgstr "tuhoisa: extension: kirjasto â€%sâ€: ei voi kutsua funktiota â€%s†(%s)\n"
-#: ext.c:127
+#: ext.c:118
msgid "extension: missing function name"
msgstr "extension: puuttuva funktionimi"
-#: ext.c:132
+#: ext.c:123
#, c-format
msgid "extension: illegal character `%c' in function name `%s'"
msgstr "extension: virheellinen merkki â€%c†funktionimessä â€%sâ€"
-#: ext.c:141
+#: ext.c:131
#, c-format
msgid "extension: can't redefine function `%s'"
msgstr "extension: ei voi määritellä uudelleen funktiota â€%sâ€"
-#: ext.c:145
+#: ext.c:135
#, c-format
msgid "extension: function `%s' already defined"
msgstr "extension: funktio â€%s†on jo määritelty"
-#: ext.c:150
+#: ext.c:139
#, c-format
msgid "extension: function name `%s' previously defined"
msgstr "extension: funktionimi â€%s†on määritelty jo aiemmin"
-#: ext.c:152
+#: ext.c:141
#, c-format
msgid "extension: can't use gawk built-in `%s' as function name"
msgstr ""
"extension: ei voi käyttää gawk-ohjelman sisäistä muuttujanimeä â€%s†"
"funktionimenä"
-#: ext.c:156
+#: ext.c:144
#, c-format
msgid "make_builtin: negative argument count for function `%s'"
msgstr "make_builtin: negatiivinen argumenttilukumäärä funktiolle â€%sâ€"
-#: ext.c:259
+#: ext.c:206
#, c-format
msgid "function `%s' defined to take no more than %d argument(s)"
msgstr "funktio â€%s†on määritelty ottamaan enemmän kuin %d argumenttia"
-#: ext.c:262
+#: ext.c:209
#, c-format
msgid "function `%s': missing argument #%d"
msgstr "function â€%sâ€: puuttuva argumentti #%d"
-#: ext.c:279
+#: ext.c:226
#, c-format
msgid "function `%s': argument #%d: attempt to use scalar as an array"
msgstr "funktio â€%sâ€: argumentti #%d: yritettiin käyttää skalaaria taulukkona"
-#: ext.c:283
+#: ext.c:230
#, c-format
msgid "function `%s': argument #%d: attempt to use array as a scalar"
msgstr "funktio â€%sâ€: argumentti #%d: yritettiin käyttää taulukkoa skalaarina"
-#: ext.c:296
+#: ext.c:244
msgid "Operation Not Supported"
msgstr "Toimintoa ei tueta"
-#: field.c:328
+#: ext.c:256
+msgid "dynamic loading of library not supported"
+msgstr ""
+
+#: field.c:339
msgid "NF set to negative value"
msgstr "NF asetettu negatiiviseen arvoon"
-#: field.c:951 field.c:958 field.c:962
+#: field.c:962 field.c:969 field.c:973
msgid "split: fourth argument is a gawk extension"
msgstr "split: neljäs argumentti on gawk-laajennus"
-#: field.c:955
+#: field.c:966
msgid "split: fourth argument is not an array"
msgstr "split: neljäs argumentti ei ole taulukko"
-#: field.c:969
+#: field.c:980
msgid "split: second argument is not an array"
msgstr "split: toinen argumentti ei ole taulukko"
-#: field.c:973
+#: field.c:984
msgid "split: cannot use the same array for second and fourth args"
msgstr ""
"split: ei voida käyttää samaa taulukkoa toiselle ja neljännelle argumentille"
-#: field.c:978
+#: field.c:989
msgid "split: cannot use a subarray of second arg for fourth arg"
msgstr ""
"split: ei voida käyttää toisen argumentin alitaulukkoa neljännelle "
"argumentille"
-#: field.c:981
+#: field.c:992
msgid "split: cannot use a subarray of fourth arg for second arg"
msgstr ""
"split: ei voida käyttää neljännen argumentin alitaulukkoa toiselle "
"argumentille"
-#: field.c:1010
+#: field.c:1021
msgid "split: null string for third arg is a gawk extension"
msgstr "split: null-merkkijono kolmantena argumenttina on gawk-laajennus"
-#: field.c:1050
+#: field.c:1061
msgid "patsplit: fourth argument is not an array"
msgstr "patsplit: neljäs argumentti ei ole taulukko"
-#: field.c:1055
+#: field.c:1066
msgid "patsplit: second argument is not an array"
msgstr "patsplit: toinen argumentti ei ole taulukko"
-#: field.c:1061
+#: field.c:1072
msgid "patsplit: third argument must be non-null"
msgstr "patsplit: kolmas argumentti ei ole taulukko"
-#: field.c:1065
+#: field.c:1076
msgid "patsplit: cannot use the same array for second and fourth args"
msgstr ""
"patsplit: ei voida käyttää samaa taulukkoa toiselle ja neljännelle "
"argumentille"
-#: field.c:1070
+#: field.c:1081
msgid "patsplit: cannot use a subarray of second arg for fourth arg"
msgstr ""
"patsplit: ei voida käyttää toisen argumentin alitaulukkkoa neljännelle "
"argumentille"
-#: field.c:1073
+#: field.c:1084
msgid "patsplit: cannot use a subarray of fourth arg for second arg"
msgstr ""
"patsplit: ei voida käyttää neljännen argumentin alitaulukkoa toiselle "
"argumentille"
-#: field.c:1110
+#: field.c:1122
msgid "`FIELDWIDTHS' is a gawk extension"
msgstr "â€FIELDWIDTHS†on gawk-laajennus"
-#: field.c:1173
+#: field.c:1186
#, c-format
msgid "invalid FIELDWIDTHS value, near `%s'"
msgstr "virheellinen FIELDWIDTHS-arvo, lähellä â€%sâ€"
-#: field.c:1246
+#: field.c:1259
msgid "null string for `FS' is a gawk extension"
msgstr "null-merkkijono â€FSâ€-kenttäerotinmuuttujalle on gawk-laajennus"
-#: field.c:1250
+#: field.c:1263
msgid "old awk does not support regexps as value of `FS'"
msgstr "vanha awk ei tue regexp-arvoja â€FSâ€-kenttäerotinmuuttujana"
-#: field.c:1369
+#: field.c:1382
msgid "`FPAT' is a gawk extension"
msgstr "â€FPAT†on gawk-laajennus"
@@ -1355,470 +1251,485 @@ msgstr "%s: valitsin ’-W %s’ ei salli argumenttia\n"
msgid "%s: option '-W %s' requires an argument\n"
msgstr "%s: valitsin ’-W %s’ vaatii argumentin\n"
-#: io.c:280
+#: io.c:326
#, c-format
msgid "command line argument `%s' is a directory: skipped"
msgstr "komentoriviargumentti â€%s†on hakemisto: ohitettiin"
-#: io.c:283 io.c:385
+#: io.c:329 io.c:438
#, c-format
msgid "cannot open file `%s' for reading (%s)"
msgstr "ei voi avata tiedostoa â€%s†lukemista varten (%s)"
-#: io.c:501
+#: io.c:568
#, c-format
msgid "close of fd %d (`%s') failed (%s)"
msgstr "tiedostomäärittelijän %d (â€%sâ€) sulkeminen epäonnistui (%s)"
-#: io.c:578
+#: io.c:645
msgid "redirection not allowed in sandbox mode"
msgstr "edelleenohjaus ei ole sallittua hiekkalaatikkotilassa"
-#: io.c:612
+#: io.c:679
#, c-format
msgid "expression in `%s' redirection only has numeric value"
msgstr "lausekkeella â€%sâ€-uudellenohjauksessa on vain numeerinen arvo"
-#: io.c:618
+#: io.c:685
#, c-format
msgid "expression for `%s' redirection has null string value"
msgstr "lausekkeella â€%sâ€-uudelleenohjauksessa on null-merkkijonoarvo"
-#: io.c:623
+#: io.c:690
#, c-format
msgid "filename `%s' for `%s' redirection may be result of logical expression"
msgstr ""
"tiedostonimi â€%s†â€%sâ€-uudelleenohjaukselle saattaa olla loogisen lausekkeen "
"tulos"
-#: io.c:666
+#: io.c:733
#, c-format
msgid "unnecessary mixing of `>' and `>>' for file `%.*s'"
msgstr "turha merkkien â€>†ja â€>>†sekoittaminen tiedostolle â€%.*sâ€"
-#: io.c:719
+#: io.c:786
#, c-format
msgid "can't open pipe `%s' for output (%s)"
msgstr "ei voi avata putkea â€%s†tulosteelle (%s)"
-#: io.c:729
+#: io.c:796
#, c-format
msgid "can't open pipe `%s' for input (%s)"
msgstr "ei voi avata putkea â€%s†syötteelle (%s)"
-#: io.c:752
+#: io.c:819
#, c-format
msgid "can't open two way pipe `%s' for input/output (%s)"
msgstr "ei voi avata kaksisuuntaista putkea â€%s†syötteelle/tulosteelle (%s)"
-#: io.c:834
+#: io.c:900
#, c-format
msgid "can't redirect from `%s' (%s)"
msgstr "ei voi uudelleenohjata putkesta â€%s†(%s)"
-#: io.c:837
+#: io.c:903
#, c-format
msgid "can't redirect to `%s' (%s)"
msgstr "ei voi uudelleenohjata putkeen â€%s†(%s)"
-#: io.c:888
+#: io.c:954
msgid ""
"reached system limit for open files: starting to multiplex file descriptors"
msgstr ""
"saavutettiin avoimien tiedostojen järjestelmäraja: aloitetaan "
"tiedostomäärittelijöiden lomittaminen"
-#: io.c:904
+#: io.c:970
#, c-format
msgid "close of `%s' failed (%s)."
msgstr "uudelleenohjauksen â€%s†sulkeminen epäonnistui (%s)."
-#: io.c:912
+#: io.c:978
msgid "too many pipes or input files open"
msgstr "avoinna liian monta putkea tai syötetiedostoa"
-#: io.c:934
+#: io.c:1000
msgid "close: second argument must be `to' or `from'"
msgstr "close: toisen argumentin on oltava â€to†tai â€fromâ€"
-#: io.c:951
+#: io.c:1017
#, c-format
msgid "close: `%.*s' is not an open file, pipe or co-process"
msgstr "close: â€%.*s†ei ole avoin tiedosto, putki tai apuprosessi"
-#: io.c:956
+#: io.c:1022
msgid "close of redirection that was never opened"
msgstr "suljettiin uudelleenohjaus, jota ei avattu koskaan"
-#: io.c:1053
+#: io.c:1120
#, c-format
msgid "close: redirection `%s' not opened with `|&', second argument ignored"
msgstr ""
"close: uudelleenohjaus â€%s†ei ole avattu operaattoreilla â€|&â€, toinen "
"argumentti ohitettu"
-#: io.c:1069
+#: io.c:1137
#, c-format
msgid "failure status (%d) on pipe close of `%s' (%s)"
msgstr "virhetila (%d) putken â€%s†sulkemisessa (%s)"
-#: io.c:1072
+#: io.c:1140
#, c-format
msgid "failure status (%d) on file close of `%s' (%s)"
msgstr "virhetila (%d) tiedoston â€%s†sulkemisessa (%s)"
-#: io.c:1092
+#: io.c:1160
#, c-format
msgid "no explicit close of socket `%s' provided"
msgstr "pistokkeen â€%s†eksplisiittistä sulkemista ei tarjota"
-#: io.c:1095
+#: io.c:1163
#, c-format
msgid "no explicit close of co-process `%s' provided"
msgstr "apuprosessin â€%s†eksplisiittistä sulkemista ei tarjota"
-#: io.c:1098
+#: io.c:1166
#, c-format
msgid "no explicit close of pipe `%s' provided"
msgstr "putken â€%s†eksplisiittistä sulkemista ei tarjota"
-#: io.c:1101
+#: io.c:1169
#, c-format
msgid "no explicit close of file `%s' provided"
msgstr "tiedoston â€%s†eksplisiittistä sulkemista ei tarjota"
-#: io.c:1129 io.c:1184 main.c:794 main.c:831
+#: io.c:1197 io.c:1252 main.c:825 main.c:862
#, c-format
msgid "error writing standard output (%s)"
msgstr "virhe kirjoitettaessa vakiotulosteeseen (%s)"
-#: io.c:1133 io.c:1189
+#: io.c:1201 io.c:1257
#, c-format
msgid "error writing standard error (%s)"
msgstr "virhe kirjoitettaessa vakiovirheeseen (%s)"
-#: io.c:1141
+#: io.c:1209
#, c-format
msgid "pipe flush of `%s' failed (%s)."
msgstr "uudelleenohjauksen â€%s†putken tyhjennys epäonnistui (%s)."
-#: io.c:1144
+#: io.c:1212
#, c-format
msgid "co-process flush of pipe to `%s' failed (%s)."
msgstr "putken apuprosessityhjennys uudelleenohjaukseen â€%s†epäonnistui (%s)."
-#: io.c:1147
+#: io.c:1215
#, c-format
msgid "file flush of `%s' failed (%s)."
msgstr "uudelleenohjauksen â€%s†tiedostontyhjennys epäonnistui (%s)."
-#: io.c:1262
+#: io.c:1329
#, c-format
msgid "local port %s invalid in `/inet'"
msgstr "paikallinen portti %s virheellinen pistokkeessa â€/inetâ€"
-#: io.c:1279
+#: io.c:1347
#, c-format
msgid "remote host and port information (%s, %s) invalid"
msgstr "etäkone- ja porttitiedot (%s, %s) ovat virheellisiä"
-#: io.c:1431
+#: io.c:1499
#, c-format
msgid "no (known) protocol supplied in special filename `%s'"
msgstr "ei (tunnettua) yhteyskäytäntöä tarjottu erikoistiedostonimessä â€%sâ€"
-#: io.c:1445
+#: io.c:1513
#, c-format
msgid "special file name `%s' is incomplete"
msgstr "erikoistiedostonimi â€%s†on vaillinainen"
-#: io.c:1462
+#: io.c:1530
msgid "must supply a remote hostname to `/inet'"
msgstr "on tarjottava etäkoneen nimi pistokkeeseen â€/inetâ€"
-#: io.c:1480
+#: io.c:1548
msgid "must supply a remote port to `/inet'"
msgstr "on tarjottava etäportti pistokkeeseen â€/inetâ€"
-#: io.c:1526
+#: io.c:1594
msgid "TCP/IP communications are not supported"
msgstr "TCP/IP-viestintää ei tueta"
-#: io.c:1693
+#: io.c:1764
#, c-format
msgid "could not open `%s', mode `%s'"
msgstr "ei voitu avata laitetta â€%sâ€, tila â€%sâ€"
-#: io.c:1747
+#: io.c:1814
#, c-format
msgid "close of master pty failed (%s)"
msgstr "â€master ptyâ€-sulkeminen epäonnistui (%s)"
-#: io.c:1749 io.c:1917 io.c:2074
+#: io.c:1816 io.c:1984 io.c:2145
#, c-format
msgid "close of stdout in child failed (%s)"
msgstr "vakiotulosteen sulkeminen lapsiprosessissa epäonnistui (%s)"
-#: io.c:1752
+#: io.c:1819
#, c-format
msgid "moving slave pty to stdout in child failed (dup: %s)"
msgstr ""
"â€slave ptyâ€:n siirtäminen vakiotulosteeseen lapsiprosessissa epäonnistui "
"(dup: %s)"
-#: io.c:1754 io.c:1922
+#: io.c:1821 io.c:1989
#, c-format
msgid "close of stdin in child failed (%s)"
msgstr "vakiosyötteen sulkeminen lapsiprosessissa epäonnistui (%s)"
-#: io.c:1757
+#: io.c:1824
#, c-format
msgid "moving slave pty to stdin in child failed (dup: %s)"
msgstr ""
"â€slave ptyâ€:n siirtäminen vakiosyötteeseen lapsiprosessissa epäonnistui "
"(dup: %s)"
-#: io.c:1759 io.c:1780
+#: io.c:1826 io.c:1847
#, c-format
msgid "close of slave pty failed (%s)"
msgstr "â€slave ptyâ€:n sulkeminen epäonnistui (%s)"
-#: io.c:1858 io.c:1920 io.c:2052 io.c:2077
+#: io.c:1925 io.c:1987 io.c:2122 io.c:2148
#, c-format
msgid "moving pipe to stdout in child failed (dup: %s)"
msgstr ""
"putken siirtäminen vakiotulosteeseen lapsiprosessissa epäonnistui (dup: %s)"
-#: io.c:1865 io.c:1925
+#: io.c:1932 io.c:1992
#, c-format
msgid "moving pipe to stdin in child failed (dup: %s)"
msgstr ""
"putken siirtäminen vakiosyötteeseen lapsiprosessissa epäonnistui (dup: %s)"
-#: io.c:1885 io.c:2067
+#: io.c:1952 io.c:2138
msgid "restoring stdout in parent process failed\n"
msgstr "vakiotulosteen palauttaminen äitiprosessissa epäonnistui\n"
-#: io.c:1893
+#: io.c:1960
msgid "restoring stdin in parent process failed\n"
msgstr "vakiosyötön palauttaminen äitiprosessissa epäonnistui\n"
-#: io.c:1928 io.c:2079 io.c:2093
+#: io.c:1995 io.c:2150 io.c:2164
#, c-format
msgid "close of pipe failed (%s)"
msgstr "putken sulkeminen epäonnistui (%s)"
-#: io.c:1973
+#: io.c:2040
msgid "`|&' not supported"
msgstr "â€|&†ei tueta"
-#: io.c:2039
+#: io.c:2107
#, c-format
msgid "cannot open pipe `%s' (%s)"
msgstr "ei voi avata putkea â€%s†(%s)"
-#: io.c:2087
+#: io.c:2158
#, c-format
msgid "cannot create child process for `%s' (fork: %s)"
msgstr "ei voida luoda lapsiprosessia komennolle â€%s†(fork: %s)"
-#: io.c:2520
+#: io.c:2637
#, c-format
msgid "data file `%s' is empty"
msgstr "data-tiedosto â€%s†on tyhjä"
-#: io.c:2561 io.c:2569
+#: io.c:2678 io.c:2686
msgid "could not allocate more input memory"
msgstr "ei voitu varata lisää syötemuistia"
-#: io.c:3127
+#: io.c:3236
msgid "multicharacter value of `RS' is a gawk extension"
msgstr "â€RSâ€-monimerkkiarvo on gawk-laajennus"
-#: io.c:3232
+#: io.c:3326
msgid "IPv6 communication is not supported"
msgstr "IPv6-viestintää ei tueta"
-#: main.c:366
+#: main.c:355
msgid "`-m[fr]' option irrelevant in gawk"
msgstr "â€-m[fr]â€-valitsin asiaanliittymätön gawk:ssa"
-#: main.c:368
+#: main.c:357
msgid "-m option usage: `-m[fr] nnn'"
msgstr "-m valitsinkäyttö: â€-m[fr] nnnâ€"
-#: main.c:391
+#: main.c:386
msgid "empty argument to `-e/--source' ignored"
msgstr "tyhjä argumentti valitsimelle â€-e/--source†ohitetaan"
-#: main.c:462
+#: main.c:472
#, c-format
msgid "%s: option `-W %s' unrecognized, ignored\n"
msgstr "%s: valitsin â€-W %s†on tunnistamaton, ohitetaan\n"
-#: main.c:515
+#: main.c:518
#, c-format
msgid "%s: option requires an argument -- %c\n"
msgstr "%s: valitsin vaatii argumentin -- %c\n"
-#: main.c:536
+#: main.c:539
msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'"
msgstr ""
"ympäristömuuttuja â€POSIXLY_CORRECT†asetettu: käännetään päälle valitsin â€--"
"posixâ€"
-#: main.c:542
+#: main.c:545
msgid "`--posix' overrides `--traditional'"
msgstr "valitsin â€--posix†korvaa valitsimen â€--traditionalâ€"
-#: main.c:553
+#: main.c:556
msgid "`--posix'/`--traditional' overrides `--non-decimal-data'"
msgstr ""
"valitsin â€--posix†tai â€--traditional†korvaa valitsimen â€--non-decimal-dataâ€"
-#: main.c:557
+#: main.c:560
#, c-format
msgid "running %s setuid root may be a security problem"
msgstr "suorittaminen â€%s setuid rootâ€-käyttäjänä saattaa olla turvapulma"
-#: main.c:562
+#: main.c:565
msgid "`--posix' overrides `--binary'"
msgstr "valitsin â€--posix†korvaa valitsimen â€--binaryâ€"
-#: main.c:613
+#: main.c:623
#, c-format
msgid "can't set binary mode on stdin (%s)"
msgstr "ei voi asettaa binaaritilaa vakiosyötteessä (%s)"
-#: main.c:616
+#: main.c:626
#, c-format
msgid "can't set binary mode on stdout (%s)"
msgstr "ei voi asettaa binaaritilaa vakiotulosteessa (%s)"
-#: main.c:618
+#: main.c:628
#, c-format
msgid "can't set binary mode on stderr (%s)"
msgstr "ei voi asettaa binaaritilaa vakiovirheessä (%s)"
-#: main.c:657
+#: main.c:679
msgid "no program text at all!"
msgstr "ei ohjelmatekstiä ollenkaan!"
-#: main.c:734
+#: main.c:763
#, c-format
msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n"
msgstr ""
"Käyttö: %s [POSIX- tai GNU-tyyliset valitsimet] -f ohjelmatiedosto [--] "
"tiedosto ...\n"
-#: main.c:736
+#: main.c:765
#, c-format
msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n"
msgstr ""
"Käyttö: %s [POSIX- tai GNU-tyyliset valitsimet] [--] %cohjelma%c "
"tiedosto ...\n"
-#: main.c:741
+#: main.c:770
msgid "POSIX options:\t\tGNU long options: (standard)\n"
msgstr "POSIX-valitsimet:\t\tGNU-pitkät valitsimet: (vakio)\n"
-#: main.c:742
+#: main.c:771
msgid "\t-f progfile\t\t--file=progfile\n"
msgstr "\t-f ohjelmatiedosto\t\t--file=ohjelmatiedosto\n"
-#: main.c:743
+#: main.c:772
msgid "\t-F fs\t\t\t--field-separator=fs\n"
msgstr "\t-F fs\t\t\t--field-separator=fs\n"
-#: main.c:744
+#: main.c:773
msgid "\t-v var=val\t\t--assign=var=val\n"
msgstr "\t-v var=arvo\t\t--assign=muuttuja=arvo\n"
-#: main.c:745
+#: main.c:774
msgid "Short options:\t\tGNU long options: (extensions)\n"
msgstr "Lyhyet valitsimet:\t\tGNU-pitkät valitsimet: (laajennukset)\n"
-#: main.c:746
+#: main.c:775
msgid "\t-b\t\t\t--characters-as-bytes\n"
msgstr "\t-b\t\t\t--characters-as-bytes\n"
-#: main.c:747
+#: main.c:776
msgid "\t-c\t\t\t--traditional\n"
msgstr "\t-c\t\t\t--traditional\n"
-#: main.c:748
+#: main.c:777
msgid "\t-C\t\t\t--copyright\n"
msgstr "\t-C\t\t\t--copyright\n"
-#: main.c:749
+#: main.c:778
msgid "\t-d[file]\t\t--dump-variables[=file]\n"
msgstr "\t-d[tiedosto]\t\t--dump-variables[=tiedosto]\n"
-#: main.c:750
+#: main.c:779
+#, fuzzy
+msgid "\t-D[file]\t\t--debug[=file]\n"
+msgstr "\t-p[tiedosto]\t\t--profile[=tiedosto]\n"
+
+#: main.c:780
msgid "\t-e 'program-text'\t--source='program-text'\n"
msgstr "\t-e 'program-text'\t--source='program-text'\n"
-#: main.c:751
+#: main.c:781
msgid "\t-E file\t\t\t--exec=file\n"
msgstr "\t-E file\t\t\t--exec=tiedosto\n"
-#: main.c:752
+#: main.c:782
msgid "\t-g\t\t\t--gen-pot\n"
msgstr "\t-g\t\t\t--gen-po\n"
-#: main.c:753
+#: main.c:783
msgid "\t-h\t\t\t--help\n"
msgstr "\t-h\t\t\t--help\n"
-#: main.c:754
+#: main.c:784
+msgid "\t-l library\t\t--load=library\n"
+msgstr ""
+
+#: main.c:785
msgid "\t-L [fatal]\t\t--lint[=fatal]\n"
msgstr "\t-L [fatal]\t\t--lint[=fatal]\n"
-#: main.c:755
+#: main.c:786
msgid "\t-n\t\t\t--non-decimal-data\n"
msgstr "\t-n\t\t\t--non-decimal-data\n"
-#: main.c:756
+#: main.c:787
+#, fuzzy
+msgid "\t-M\t\t\t--bignum\n"
+msgstr "\t-g\t\t\t--gen-po\n"
+
+#: main.c:788
msgid "\t-N\t\t\t--use-lc-numeric\n"
msgstr "\t-N\t\t\t--use-lc-numeric\n"
-#: main.c:757
+#: main.c:789
+#, fuzzy
+msgid "\t-o[file]\t\t--pretty-print[=file]\n"
+msgstr "\t-p[tiedosto]\t\t--profile[=tiedosto]\n"
+
+#: main.c:790
msgid "\t-O\t\t\t--optimize\n"
msgstr "\t-O\t\t\t--optimize\n"
-#: main.c:758
+#: main.c:791
msgid "\t-p[file]\t\t--profile[=file]\n"
msgstr "\t-p[tiedosto]\t\t--profile[=tiedosto]\n"
-#: main.c:759
+#: main.c:792
msgid "\t-P\t\t\t--posix\n"
msgstr "\t-P\t\t\t--posix\n"
-#: main.c:760
+#: main.c:793
msgid "\t-r\t\t\t--re-interval\n"
msgstr "\t-r\t\t\t--re-interval\n"
-#: main.c:762
-msgid "\t-R file\t\t\t--command=file\n"
-msgstr "\t-R tiedosto\t\t\t--exec=tiedosto\n"
-
-#: main.c:763
+#: main.c:794
msgid "\t-S\t\t\t--sandbox\n"
msgstr "\t-S\t\t\t--sandbox\n"
-#: main.c:764
+#: main.c:795
msgid "\t-t\t\t\t--lint-old\n"
msgstr "\t-t\t\t\t--lint-old\n"
-#: main.c:765
+#: main.c:796
msgid "\t-V\t\t\t--version\n"
msgstr "\t-V\t\t\t--version\n"
-#: main.c:767
+#: main.c:798
msgid "\t-W nostalgia\t\t--nostalgia\n"
msgstr "\t-W nostalgia\t\t--nostalgia\n"
-#: main.c:770
+#: main.c:801
msgid "\t-Y\t\t--parsedebug\n"
msgstr "\t-Y\t\t--parsedebug\n"
@@ -1827,7 +1738,7 @@ msgstr "\t-Y\t\t--parsedebug\n"
#. for this application. Please add _another line_ with the
#. address for translation bugs.
#. no-wrap
-#: main.c:779
+#: main.c:810
msgid ""
"\n"
"To report bugs, see node `Bugs' in `gawk.info', which is\n"
@@ -1840,7 +1751,7 @@ msgstr ""
"joka on kappale â€Reporting Problems and Bugs†painetussa versiossa.\n"
"\n"
-#: main.c:783
+#: main.c:814
msgid ""
"gawk is a pattern scanning and processing language.\n"
"By default it reads standard input and writes standard output.\n"
@@ -1850,7 +1761,7 @@ msgstr ""
"Oletuksena se lukee vakiosyötettä ja kirjoittaa vakiotulosteeseen.\n"
"\n"
-#: main.c:787
+#: main.c:818
msgid ""
"Examples:\n"
"\tgawk '{ sum += $1 }; END { print sum }' file\n"
@@ -1860,7 +1771,7 @@ msgstr ""
"\tgawk '{ sum += $1 }; END { print sum }' tiedosto\n"
"\tgawk -F: '{ print $1 }' /etc/passwd\n"
-#: main.c:807
+#: main.c:838
#, c-format
msgid ""
"Copyright (C) 1989, 1991-%d Free Software Foundation.\n"
@@ -1879,7 +1790,7 @@ msgstr ""
"ehtojen mukaisesti.\n"
"\n"
-#: main.c:815
+#: main.c:846
msgid ""
"This program is distributed in the hope that it will be useful,\n"
"but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
@@ -1893,7 +1804,7 @@ msgstr ""
"GNU General Public License-ehdoista.\n"
"\n"
-#: main.c:821
+#: main.c:852
msgid ""
"You should have received a copy of the GNU General Public License\n"
"along with this program. If not, see http://www.gnu.org/licenses/.\n"
@@ -1901,16 +1812,16 @@ msgstr ""
"Sinun pitäisi vastaanottaa kopion GNU General Public Licence-lisenssistä\n"
"tämän ohjelman mukana. Jos näin ei ole, katso http://www.gnu.org/licenses/.\n"
-#: main.c:856
+#: main.c:887
msgid "-Ft does not set FS to tab in POSIX awk"
msgstr "-Ft ei aseta FS välilehteen POSIX awk:ssa"
-#: main.c:1090
+#: main.c:1133
#, c-format
msgid "unknown value for field spec: %d\n"
msgstr "tuntematon arvo kenttämääritteelle: %d\n"
-#: main.c:1171
+#: main.c:1214
#, c-format
msgid ""
"%s: `%s' argument to `-v' not in `var=value' form\n"
@@ -1919,79 +1830,79 @@ msgstr ""
"%s: â€%s†argumentti valitsimelle â€-v†ei ole â€var=arvoâ€-muodossa\n"
"\n"
-#: main.c:1197
+#: main.c:1240
#, c-format
msgid "`%s' is not a legal variable name"
msgstr "â€%s†ei ole laillinen muuttujanimi"
-#: main.c:1200
+#: main.c:1243
#, c-format
msgid "`%s' is not a variable name, looking for file `%s=%s'"
msgstr "â€%s†ei ole muuttujanimi, etsitään tiedostoa â€%s=%sâ€"
-#: main.c:1204
+#: main.c:1247
#, c-format
msgid "cannot use gawk builtin `%s' as variable name"
msgstr "ei voi käyttää gawk-ohjelman sisäistä â€%sâ€-määrittelyä muuttujanimenä"
-#: main.c:1209
+#: main.c:1252
#, c-format
msgid "cannot use function `%s' as variable name"
msgstr "funktionimeä â€%s†ei voi käyttää muuttujanimenä"
-#: main.c:1262
+#: main.c:1305
msgid "floating point exception"
msgstr "liukulukupoikkeus"
-#: main.c:1269
+#: main.c:1312
msgid "fatal error: internal error"
msgstr "tuhoisa virhe: sisäinen virhe"
-#: main.c:1284
+#: main.c:1327
msgid "fatal error: internal error: segfault"
msgstr "tuhoisa virhe: sisäinen virhe: segmenttivirhe"
-#: main.c:1296
+#: main.c:1339
msgid "fatal error: internal error: stack overflow"
msgstr "tuhoisa virhe: sisäinen virhe: pinoylivuoto"
-#: main.c:1346
+#: main.c:1393
#, c-format
msgid "no pre-opened fd %d"
msgstr "ei avattu uudelleen tiedostomäärittelijää %d"
-#: main.c:1353
+#: main.c:1400
#, c-format
msgid "could not pre-open /dev/null for fd %d"
msgstr "ei voitu avata uudelleen laitetta /dev/null tiedostomäärittelijälle %d"
-#: msg.c:63
+#: msg.c:61
#, c-format
msgid "cmd. line:"
msgstr "komentorivi:"
-#: msg.c:107
+#: msg.c:121
msgid "error: "
msgstr "virhe:"
-#: node.c:406
+#: node.c:436
msgid "backslash at end of string"
msgstr "kenoviiva merkkijonon lopussa"
-#: node.c:517
+#: node.c:520
#, c-format
msgid "old awk does not support the `\\%c' escape sequence"
msgstr "vanha awk ei tue â€\\%câ€-koodinvaihtosekvenssiä"
-#: node.c:568
+#: node.c:571
msgid "POSIX does not allow `\\x' escapes"
msgstr "POSIX ei salli â€\\xâ€-koodinvaihtoja"
-#: node.c:574
+#: node.c:577
msgid "no hex digits in `\\x' escape sequence"
msgstr "ei heksadesimaalilukuja â€\\xâ€-koodinvaihtosekvenssissä"
-#: node.c:596
+#: node.c:599
#, c-format
msgid ""
"hex escape \\x%.*s of %d characters probably not interpreted the way you "
@@ -2000,12 +1911,12 @@ msgstr ""
"heksadesimaalikoodinvaihtomerkkejä \\x%.*s / %d ei ole luultavasti tulkittu "
"sillä tavalla kuin odotat"
-#: node.c:611
+#: node.c:614
#, c-format
msgid "escape sequence `\\%c' treated as plain `%c'"
msgstr "koodinvaihtosekvenssi â€\\%c†käsitelty kuin pelkkä â€%câ€"
-#: node.c:750
+#: node.c:759
msgid ""
"Invalid multibyte data detected. There may be a mismatch between your data "
"and your locale."
@@ -2023,16 +1934,16 @@ msgstr "%s %s â€%sâ€: ei voitu hakea fd-lippuja: (fcntl F_GETFD: %s)"
msgid "%s %s `%s': could not set close-on-exec: (fcntl F_SETFD: %s)"
msgstr "%s %s â€%sâ€: ei voitu asettaa close-on-exec: (fcntl F_SETFD: %s)"
-#: profile.c:83
+#: profile.c:69
#, c-format
msgid "could not open `%s' for writing: %s"
msgstr "ei voitu avata tiedostoa â€%s†kirjoittamista varten: %s"
-#: profile.c:85
+#: profile.c:71
msgid "sending profile to standard error"
msgstr "lähetetään profiili vakiovirheeseen"
-#: profile.c:203
+#: profile.c:187
#, c-format
msgid ""
"\t# %s block(s)\n"
@@ -2041,7 +1952,7 @@ msgstr ""
"\t# %s-lohko(t)\n"
"\n"
-#: profile.c:208
+#: profile.c:192
#, c-format
msgid ""
"\t# Rule(s)\n"
@@ -2050,17 +1961,22 @@ msgstr ""
"\t# Säännöt\n"
"\n"
-#: profile.c:279
+#: profile.c:266
#, c-format
msgid "internal error: %s with null vname"
msgstr "sisäinen virhe: %s null vname-arvolla"
-#: profile.c:952
+#: profile.c:528
+#, fuzzy
+msgid "internal error: builtin with null fname"
+msgstr "sisäinen virhe: %s null vname-arvolla"
+
+#: profile.c:943
#, c-format
msgid "\t# gawk profile, created %s\n"
msgstr "\t# gawk-profiili, luotu %s\n"
-#: profile.c:1331
+#: profile.c:1328
#, c-format
msgid ""
"\n"
@@ -2069,17 +1985,17 @@ msgstr ""
"\n"
"\t# Funktiot, luetteloitu aakkosjärjestyksessä\n"
-#: profile.c:1370
+#: profile.c:1366
#, c-format
msgid "redir2str: unknown redirection type %d"
msgstr "redir2str: tuntematon edelleenohjaustyyppi %d"
-#: re.c:573
+#: re.c:571
#, c-format
msgid "range of the form `[%c-%c]' is locale dependent"
msgstr "muodon â€[%c-%c]†lukualue on paikallisasetuksesta riippuvainen"
-#: re.c:600
+#: re.c:598
#, c-format
msgid "regexp component `%.*s' should probably be `[%.*s]'"
msgstr ""
@@ -2157,6 +2073,78 @@ msgstr "Pariton ) tai \\)"
msgid "No previous regular expression"
msgstr "Ei edellistä säännöllistä lauseketta"
+#~ msgid "attempt to use function `%s' as an array"
+#~ msgstr "yritettiin käyttää funktiota â€%s†taulukkona"
+
+#~ msgid "reference to uninitialized element `%s[\"%.*s\"]'"
+#~ msgstr "viite alustamattomaan elementtiin â€%s[\"%.*s\"]â€"
+
+#~ msgid "subscript of array `%s' is null string"
+#~ msgstr "taulukon alaindeksi â€%s†on null-merkkijono"
+
+#~ msgid "%s: empty (null)\n"
+#~ msgstr "%s: tyhjä (null)\n"
+
+#~ msgid "%s: empty (zero)\n"
+#~ msgstr "%s: tyhjä (nolla)\n"
+
+#~ msgid "%s: table_size = %d, array_size = %d\n"
+#~ msgstr "%s: table_size = %d, array_size = %d\n"
+
+#~ msgid "%s: is parameter\n"
+#~ msgstr "%s: on parametri\n"
+
+#~ msgid "%s: array_ref to %s\n"
+#~ msgstr "%s: array_ref-viite taulukkoon %s\n"
+
+#~ msgid "use of non-array as array"
+#~ msgstr "ei-taulukon käyttö taulukkona"
+
+#~ msgid "can't use function name `%s' as variable or array"
+#~ msgstr "funktionimeä â€%s†ei voi käyttää muuttujana tai taulukkona"
+
+#~ msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
+#~ msgstr "yritettiin käyttää taulukkoa â€%s[\"%.*s\"]†skalaarikontekstissa"
+
+#~ msgid "assignment used in conditional context"
+#~ msgstr "sijoitusta käytetty ehdollisessa kontekstissa"
+
+#~ msgid "statement has no effect"
+#~ msgstr "käskyllä ei ole vaikutusta"
+
+#~ msgid ""
+#~ "for loop: array `%s' changed size from %ld to %ld during loop execution"
+#~ msgstr ""
+#~ "for-silmukka: taulukon â€%s†koko muuttui arvosta %ld arvoon %ld silmukan "
+#~ "suorituksen aikana"
+
+#~ msgid "function called indirectly through `%s' does not exist"
+#~ msgstr "kohteen â€%s†kautta epäsuorasti kutsuttu funktio ei ole olemassa"
+
+#~ msgid "function `%s' not defined"
+#~ msgstr "funktio â€%s†ei ole määritelty"
+
+#~ msgid "non-redirected `getline' invalid inside `%s' rule"
+#~ msgstr "edelleenohjaamaton â€getline†virheellinen â€%sâ€-säännön sisällä"
+
+#~ msgid "error reading input file `%s': %s"
+#~ msgstr "virhe luettaessa syötetiedostoa â€%sâ€: %s"
+
+#~ msgid "`nextfile' cannot be called from a `%s' rule"
+#~ msgstr "â€nextfile†ei voida kutsua â€%sâ€-säännöstä"
+
+#~ msgid "`exit' cannot be called in the current context"
+#~ msgstr "â€exit†ei voida kutsua nykyisessä asiayhteydessä"
+
+#~ msgid "`next' cannot be called from a `%s' rule"
+#~ msgstr "â€next†ei voida kutsua â€%sâ€-säännöstä"
+
+#~ msgid "Sorry, don't know how to interpret `%s'"
+#~ msgstr "Ei osata tulkita kohdetta â€%sâ€"
+
+#~ msgid "\t-R file\t\t\t--command=file\n"
+#~ msgstr "\t-R tiedosto\t\t\t--exec=tiedosto\n"
+
#~ msgid "could not find groups: %s"
#~ msgstr "ei voitu löytää ryhmiä: %s"
diff --git a/po/fr.gmo b/po/fr.gmo
index 840e6c9b..a6e5a9d5 100644
--- a/po/fr.gmo
+++ b/po/fr.gmo
Binary files differ
diff --git a/po/fr.po b/po/fr.po
index daba98e8..d91375d5 100644
--- a/po/fr.po
+++ b/po/fr.po
@@ -9,7 +9,7 @@ msgid ""
msgstr ""
"Project-Id-Version: gawk 4.0.0h\n"
"Report-Msgid-Bugs-To: arnold@skeeve.com\n"
-"POT-Creation-Date: 2012-03-28 22:03+0200\n"
+"POT-Creation-Date: 2012-04-27 10:06+0300\n"
"PO-Revision-Date: 2012-01-30 23:52+0100\n"
"Last-Translator: Jean-Philippe Guérard <jean-philippe.guerard@corbeaunoir."
"org>\n"
@@ -20,512 +20,469 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
-#: array.c:140
+#: array.c:266
#, c-format
msgid "from %s"
msgstr "de %s"
-#: array.c:248
+#: array.c:366
msgid "attempt to use a scalar value as array"
msgstr "tentative d'utiliser un scalaire comme tableau"
-#: array.c:251
-#, c-format
-msgid "attempt to use function `%s' as an array"
-msgstr "tentative d'utiliser la fonction « %s » comme tableau"
-
-#: array.c:254
+#: array.c:368
#, c-format
msgid "attempt to use scalar parameter `%s' as an array"
msgstr "tentative d'utiliser le paramètre scalaire « %s » comme tableau"
-#: array.c:257
+#: array.c:371
#, c-format
msgid "attempt to use scalar `%s' as an array"
msgstr "tentative d'utiliser le scalaire « %s » comme tableau"
-#: array.c:302 array.c:707 builtin.c:84 builtin.c:1385 builtin.c:1427
-#: builtin.c:1440 builtin.c:1859 builtin.c:1871 eval.c:1135 eval.c:1139
-#: eval.c:1495 eval.c:1812
+#: array.c:418 array.c:584 builtin.c:85 builtin.c:1560 builtin.c:1602
+#: builtin.c:1615 builtin.c:2041 builtin.c:2053 eval.c:1109 eval.c:1113
+#: eval.c:1508
#, c-format
msgid "attempt to use array `%s' in a scalar context"
msgstr "tentative d'utilisation du tableau « %s » dans un contexte scalaire"
-#: array.c:513
-#, c-format
-msgid "reference to uninitialized element `%s[\"%.*s\"]'"
-msgstr "référence à un élément non initialisé « %s[\"%.*s\"] »"
-
-#: array.c:519
-#, c-format
-msgid "subscript of array `%s' is null string"
-msgstr "l'indice du tableau « %s » est une chaîne vide"
-
-#: array.c:723
+#: array.c:591
#, c-format
msgid "delete: index `%s' not in array `%s'"
msgstr "delete : l'indice « %s » est absent du tableau « %s »"
-#: array.c:734 eval.c:1865
+#: array.c:605
#, c-format
msgid "attempt to use scalar `%s[\"%.*s\"]' as an array"
msgstr "tentative d'utiliser le scalaire « %s[\"%.*s\"] » comme tableau"
-#: array.c:910
-#, c-format
-msgid "%s: empty (null)\n"
-msgstr "%s : vide (non défini)\n"
-
-#: array.c:915
-#, c-format
-msgid "%s: empty (zero)\n"
-msgstr "%s : vide (vide)\n"
-
-#: array.c:919
-#, c-format
-msgid "%s: table_size = %d, array_size = %d\n"
-msgstr "%s : table_size = %d, array_size = %d\n"
-
-#: array.c:954
-#, c-format
-msgid "%s: is parameter\n"
-msgstr "%s : est un paramètre\n"
-
-#: array.c:958
-#, c-format
-msgid "%s: array_ref to %s\n"
-msgstr "%s : array_ref à %s\n"
-
-#: array.c:963
-msgid "adump: argument not an array"
+#: array.c:784
+#, fuzzy
+msgid "adump: first argument not an array"
msgstr "adump : l'argument n'est pas un tableau"
-#: array.c:1086
+#: array.c:823
msgid "asort: second argument not an array"
msgstr "asort : le 2nd argument n'est pas un tableau"
-#: array.c:1087
+#: array.c:824
msgid "asorti: second argument not an array"
msgstr "asorti : le 2nd argument n'est pas un tableau"
-#: array.c:1094
+#: array.c:831
msgid "asort: first argument not an array"
msgstr "asort : le 1er argument n'est pas un tableau"
-#: array.c:1095
+#: array.c:832
msgid "asorti: first argument not an array"
msgstr "asorti : le 1er argument n'est pas un tableau"
-#: array.c:1102
+#: array.c:839
msgid "asort: cannot use a subarray of first arg for second arg"
msgstr "asort : le 2nd argument ne doit pas être un sous-tableau du 1er"
-#: array.c:1103
+#: array.c:840
msgid "asorti: cannot use a subarray of first arg for second arg"
msgstr "asorti : le 2nd argument ne doit pas être un sous-tableau du 1er"
-#: array.c:1108
+#: array.c:845
msgid "asort: cannot use a subarray of second arg for first arg"
msgstr "asort : le 1er argument ne doit pas être un sous-tableau du 2nd"
-#: array.c:1109
+#: array.c:846
msgid "asorti: cannot use a subarray of second arg for first arg"
msgstr "asorti : le 1er argument ne doit pas être un sous-tableau du 2nd"
-#: array.c:1655
+#: array.c:1314
#, c-format
msgid "`%s' is invalid as a function name"
msgstr "« %s » n'est pas un nom de fonction valide"
-#: array.c:1659
+#: array.c:1318
#, c-format
msgid "sort comparison function `%s' is not defined"
msgstr "la fonction de comparaison « %s » du tri n'est pas définie"
-#: awkgram.y:249
+#: awkgram.y:223
#, c-format
msgid "%s blocks must have an action part"
msgstr "les blocs %s doivent avoir une partie action"
-#: awkgram.y:252
+#: awkgram.y:226
msgid "each rule must have a pattern or an action part"
msgstr "chaque règle doit avoir au moins une partie motif ou action"
-#: awkgram.y:323 awkgram.y:334
+#: awkgram.y:295 awkgram.y:306
msgid "old awk does not support multiple `BEGIN' or `END' rules"
msgstr "l'ancien awk ne permet pas les « BEGIN » ou « END » multiples"
-#: awkgram.y:371
+#: awkgram.y:343
#, c-format
msgid "`%s' is a built-in function, it cannot be redefined"
msgstr "« %s » est une fonction interne, elle ne peut être redéfinie"
-#: awkgram.y:432
+#: awkgram.y:389
msgid "regexp constant `//' looks like a C++ comment, but is not"
msgstr "l'expression rationnelle constante « // » n'est pas un commentaire C++"
-#: awkgram.y:436
+#: awkgram.y:393
#, c-format
msgid "regexp constant `/%s/' looks like a C comment, but is not"
msgstr "l'expression rationnelle constante « /%s/ » n'est pas un commentaire C"
-#: awkgram.y:528
+#: awkgram.y:485
#, c-format
msgid "duplicate case values in switch body: %s"
msgstr "le corps du switch comporte des cas répétés : %s"
-#: awkgram.y:549
+#: awkgram.y:506
msgid "duplicate `default' detected in switch body"
msgstr "plusieurs « default » ont été détectés dans le corps du switch"
-#: awkgram.y:809
+#: awkgram.y:766
msgid "`break' is not allowed outside a loop or switch"
msgstr "« break » est interdit en dehors d'une boucle ou d'un switch"
-#: awkgram.y:818
+#: awkgram.y:775
msgid "`continue' is not allowed outside a loop"
msgstr "« continue » est interdit en dehors d'une boucle ou d'un switch"
-#: awkgram.y:828
+#: awkgram.y:785
#, c-format
msgid "`next' used in %s action"
msgstr "« next » est utilisé dans l'action %s"
-#: awkgram.y:836
+#: awkgram.y:793
msgid "`nextfile' is a gawk extension"
msgstr "« nextfile » est une extension gawk"
-#: awkgram.y:841
+#: awkgram.y:798
#, c-format
msgid "`nextfile' used in %s action"
msgstr "« nextfile » est utilisé dans l'action %s"
-#: awkgram.y:865
+#: awkgram.y:822
msgid "`return' used outside function context"
msgstr "« return » est utilisé hors du contexte d'une fonction"
-#: awkgram.y:925
+#: awkgram.y:896
msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'"
msgstr ""
"dans BEGIN ou END, un « print » seul devrait sans doute être un « print "
"\"\" »"
-#: awkgram.y:995 awkgram.y:999 awkgram.y:1023
+#: awkgram.y:966 awkgram.y:970 awkgram.y:994
msgid "`delete array' is a gawk extension"
msgstr "« delete array » est une extension gawk"
-#: awkgram.y:1019
+#: awkgram.y:990
msgid "`delete(array)' is a non-portable tawk extension"
msgstr "« delete(array) » est une extension non portable de tawk"
-#: awkgram.y:1135
+#: awkgram.y:1108
msgid "multistage two-way pipelines don't work"
msgstr "impossible d'utiliser des tubes bidirectionnels en série"
-#: awkgram.y:1238
+#: awkgram.y:1211
msgid "regular expression on right of assignment"
msgstr "expression rationnelle à droite d'une affectation"
-#: awkgram.y:1249
+#: awkgram.y:1222
msgid "regular expression on left of `~' or `!~' operator"
msgstr "expression rationnelle à gauche d'un opérateur « ~ » ou « !~ »"
-#: awkgram.y:1265 awkgram.y:1419
+#: awkgram.y:1238 awkgram.y:1389
msgid "old awk does not support the keyword `in' except after `for'"
msgstr "l'ancien awk n'autorise le mot-clef « in » qu'après « for »"
-#: awkgram.y:1275
+#: awkgram.y:1248
msgid "regular expression on right of comparison"
msgstr "expression rationnelle à droite d'une comparaison"
-#: awkgram.y:1394
+#: awkgram.y:1364
#, c-format
msgid "`getline var' invalid inside `%s' rule"
msgstr "« getline var » n'est pas valable dans une règle « %s »"
-#: awkgram.y:1397 eval.c:2504
+#: awkgram.y:1367
#, c-format
msgid "`getline' invalid inside `%s' rule"
msgstr "« getline » n'est pas valable dans une règle « %s »"
-#: awkgram.y:1402
+#: awkgram.y:1372
msgid "non-redirected `getline' undefined inside END action"
msgstr "dans une action END, un « getline » non redirigé n'est pas défini"
-#: awkgram.y:1421
+#: awkgram.y:1391
msgid "old awk does not support multidimensional arrays"
msgstr "l'ancien awk ne dispose pas des tableaux multidimensionnels"
-#: awkgram.y:1517
+#: awkgram.y:1488
msgid "call of `length' without parentheses is not portable"
msgstr "l'appel de « length » sans parenthèses n'est pas portable"
-#: awkgram.y:1580
+#: awkgram.y:1554
msgid "indirect function calls are a gawk extension"
msgstr "les appels indirects de fonctions sont une extension gawk"
-#: awkgram.y:1593
+#: awkgram.y:1567
#, c-format
msgid "can not use special variable `%s' for indirect function call"
msgstr ""
"impossible d'utiliser la variable spéciale « %s » pour un appel indirect de "
"fonction"
-#: awkgram.y:1671
+#: awkgram.y:1645
msgid "invalid subscript expression"
msgstr "expression indice non valide"
-#: awkgram.y:1711
-msgid "use of non-array as array"
-msgstr "utilisation d'un non tableau comme tableau"
-
-#: awkgram.y:1975 awkgram.y:1995 msg.c:98
+#: awkgram.y:1966 awkgram.y:1986 msg.c:112
msgid "warning: "
msgstr "avertissement : "
-#: awkgram.y:1993 msg.c:130
+#: awkgram.y:1984 msg.c:144
msgid "fatal: "
msgstr "fatal : "
-#: awkgram.y:2043
+#: awkgram.y:2034
msgid "unexpected newline or end of string"
msgstr "fin de chaîne ou passage à la ligne inattendu"
-#: awkgram.y:2300 awkgram.y:2358 awkgram.y:2542
+#: awkgram.y:2299 awkgram.y:2357 awkgram.y:2545
#, c-format
msgid "can't open source file `%s' for reading (%s)"
msgstr "impossible d'ouvrir le fichier source « %s » en lecture (%s)"
-#: awkgram.y:2301 awkgram.y:2359 builtin.c:122
+#: awkgram.y:2300 awkgram.y:2358 builtin.c:124
msgid "reason unknown"
msgstr "raison inconnue"
-#: awkgram.y:2317
+#: awkgram.y:2316
#, c-format
msgid "already included source file `%s'"
msgstr "le fichier source « %s » a déjà été intégré"
-#: awkgram.y:2343
+#: awkgram.y:2342
msgid "@include is a gawk extension"
msgstr "@include est une extension gawk"
-#: awkgram.y:2349
+#: awkgram.y:2348
msgid "empty filename after @include"
msgstr "Le nom de fichier après @include est vide"
-#: awkgram.y:2494
+#: awkgram.y:2497
msgid "empty program text on command line"
msgstr "le programme indiqué en ligne de commande est vide"
-#: awkgram.y:2609
+#: awkgram.y:2612
#, c-format
msgid "can't read sourcefile `%s' (%s)"
msgstr "impossible de lire le fichier source « %s » (%s)"
-#: awkgram.y:2620
+#: awkgram.y:2623
#, c-format
msgid "source file `%s' is empty"
msgstr "le fichier source « %s » est vide"
-#: awkgram.y:2797
+#: awkgram.y:2800
msgid "source file does not end in newline"
msgstr "le fichier source ne se termine pas par un passage à la ligne"
-#: awkgram.y:2900
+#: awkgram.y:2905
msgid "unterminated regexp ends with `\\' at end of file"
msgstr ""
"expression rationnelle non refermée terminée par un « \\ » en fin de fichier"
-#: awkgram.y:2924
+#: awkgram.y:2929
#, c-format
msgid "%s: %d: tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr ""
"%s : %d : le modificateur d'expressions rationnelles « /.../%c » de tawk ne "
"marche pas dans gawk"
-#: awkgram.y:2928
+#: awkgram.y:2933
#, c-format
msgid "tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr ""
"le modificateur d'expressions rationnelles « /.../%c » de tawk ne marche pas "
"dans gawk"
-#: awkgram.y:2935
+#: awkgram.y:2940
msgid "unterminated regexp"
msgstr "expression rationnelle non refermée"
-#: awkgram.y:2939
+#: awkgram.y:2944
msgid "unterminated regexp at end of file"
msgstr "expression rationnelle non refermée en fin de fichier"
-#: awkgram.y:2998
+#: awkgram.y:3003
msgid "use of `\\ #...' line continuation is not portable"
msgstr ""
"l'utilisation de « \\ #... » pour prolonger une ligne n'est pas portable"
-#: awkgram.y:3014
+#: awkgram.y:3019
msgid "backslash not last character on line"
msgstr "la barre oblique inverse n'est pas le dernier caractère de la ligne"
-#: awkgram.y:3075
+#: awkgram.y:3080
msgid "POSIX does not allow operator `**='"
msgstr "POSIX n'autorise pas l'opérateur « **= »"
-#: awkgram.y:3077
+#: awkgram.y:3082
msgid "old awk does not support operator `**='"
msgstr "l'ancien awk ne dispose pas de l'opérateur « **= »"
-#: awkgram.y:3086
+#: awkgram.y:3091
msgid "POSIX does not allow operator `**'"
msgstr "POSIX n'autorise pas l'opérateur « ** »"
-#: awkgram.y:3088
+#: awkgram.y:3093
msgid "old awk does not support operator `**'"
msgstr "l'ancien awk ne dispose pas de l'opérateur « ** »"
-#: awkgram.y:3123
+#: awkgram.y:3128
msgid "operator `^=' is not supported in old awk"
msgstr "l'ancien awk ne dispose pas de l'opérateur « ^= »"
-#: awkgram.y:3131
+#: awkgram.y:3136
msgid "operator `^' is not supported in old awk"
msgstr "l'ancien awk ne dispose pas de l'opérateur « ^ »"
-#: awkgram.y:3224 awkgram.y:3240
+#: awkgram.y:3229 awkgram.y:3245
msgid "unterminated string"
msgstr "chaîne non refermée"
-#: awkgram.y:3436
+#: awkgram.y:3466
#, c-format
msgid "invalid char '%c' in expression"
msgstr "caractère non valide « %c » dans l'expression"
-#: awkgram.y:3483
+#: awkgram.y:3513
#, c-format
msgid "`%s' is a gawk extension"
msgstr "« %s » est une extension gawk"
-#: awkgram.y:3488
+#: awkgram.y:3518
#, c-format
msgid "`%s' is a Bell Labs extension"
msgstr "« %s » est une extension Bell Labs"
-#: awkgram.y:3493
+#: awkgram.y:3523
#, c-format
msgid "POSIX does not allow `%s'"
msgstr "POSIX n'autorise pas « %s »"
-#: awkgram.y:3501
+#: awkgram.y:3531
#, c-format
msgid "`%s' is not supported in old awk"
msgstr "l'ancien awk ne dispose pas de « %s »"
-#: awkgram.y:3568
+#: awkgram.y:3598
msgid "`goto' considered harmful!\n"
msgstr "« goto est jugé dangereux ! » (Edsger W. Dijkstra)\n"
-#: awkgram.y:3619
+#: awkgram.y:3632
#, c-format
msgid "%d is invalid as number of arguments for %s"
msgstr "%d n'est pas un nombre d'arguments valide de %s"
-#: awkgram.y:3654
+#: awkgram.y:3667
#, c-format
msgid "%s: string literal as last arg of substitute has no effect"
msgstr ""
"%s : une chaîne littérale en dernier argument d'une substitution est sans "
"effet"
-#: awkgram.y:3659
+#: awkgram.y:3672
#, c-format
msgid "%s third parameter is not a changeable object"
msgstr "le 3e paramètre de %s n'est pas un objet modifiable"
-#: awkgram.y:3732 awkgram.y:3735
+#: awkgram.y:3751 awkgram.y:3754
msgid "match: third argument is a gawk extension"
msgstr "match : le 3e argument est une extension gawk"
-#: awkgram.y:3789 awkgram.y:3792
+#: awkgram.y:3808 awkgram.y:3811
msgid "close: second argument is a gawk extension"
msgstr "close : le 2e argument est une extension gawk"
-#: awkgram.y:3804
+#: awkgram.y:3823
msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore"
msgstr ""
"utilisation incorrecte de dcgettext(_\"...\") : enlevez le souligné de tête"
-#: awkgram.y:3819
+#: awkgram.y:3838
msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore"
msgstr ""
"utilisation incorrecte de dcngettext(_\"...\") : enlevez le souligné de tête"
-#: awkgram.y:3911
-#, c-format
-msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
-msgstr ""
-"fonction « %s » : paramètre #%d, « %s » est un doublon du paramètre #%d"
-
-#: awkgram.y:3953
+#: awkgram.y:3904
#, c-format
msgid "function `%s': parameter `%s' shadows global variable"
msgstr "fonction « %s » : le paramètre « %s » masque la variable globale"
-#: awkgram.y:4111
+#: awkgram.y:3961
#, c-format
msgid "could not open `%s' for writing (%s)"
msgstr "impossible d'ouvrir « %s » en écriture (%s)"
-#: awkgram.y:4112
+#: awkgram.y:3962
msgid "sending variable list to standard error"
msgstr "envoi de la liste des variables vers la sortie d'erreur standard"
-#: awkgram.y:4118
+#: awkgram.y:3970
#, c-format
msgid "%s: close failed (%s)"
msgstr "%s : échec de la fermeture (%s)"
-#: awkgram.y:4170
+#: awkgram.y:3995
msgid "shadow_funcs() called twice!"
msgstr "shadows_funcs() a été appelé deux fois !"
-#: awkgram.y:4176
+#: awkgram.y:4003
msgid "there were shadowed variables."
msgstr "il y avait des variables masquées."
-#: awkgram.y:4206
+#: awkgram.y:4074
+#, c-format
+msgid "function name `%s' previously defined"
+msgstr "nom de fonction « %s » déjà défini"
+
+#: awkgram.y:4120
#, c-format
msgid "function `%s': can't use function name as parameter name"
msgstr ""
"fonction « %s » : impossible d'utiliser un nom de fonction comme paramètre"
-#: awkgram.y:4210
+#: awkgram.y:4123
#, c-format
msgid "function `%s': can't use special variable `%s' as a function parameter"
msgstr ""
"fonction « %s » : impossible d'utiliser la variable spéciale « %s » comme "
"paramètre d'une fonction"
-#: awkgram.y:4226
+#: awkgram.y:4131
#, c-format
-msgid "function name `%s' previously defined"
-msgstr "nom de fonction « %s » déjà défini"
+msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
+msgstr ""
+"fonction « %s » : paramètre #%d, « %s » est un doublon du paramètre #%d"
-#: awkgram.y:4394 awkgram.y:4400
+#: awkgram.y:4210 awkgram.y:4216
#, c-format
msgid "function `%s' called but never defined"
msgstr "fonction « %s » appelée sans être définie"
-#: awkgram.y:4403
+#: awkgram.y:4219
#, c-format
msgid "function `%s' defined but never called directly"
msgstr "fonction « %s » définie mais jamais appelée directement"
-#: awkgram.y:4435
+#: awkgram.y:4251
#, c-format
msgid "regexp constant for parameter #%d yields boolean value"
msgstr "le paramètre #%d, une expr. rationnelle constante, fournit un booléen"
-#: awkgram.y:4544
+#: awkgram.y:4297
#, c-format
msgid ""
"function `%s' called with space between name and `(',\n"
@@ -534,232 +491,232 @@ msgstr ""
"fonction « %s » appelée avec un espace entre son nom\n"
"et « ( », ou utilisée comme variable ou tableau"
-#: awkgram.y:4791 eval.c:2056
+#: awkgram.y:4505
msgid "division by zero attempted"
msgstr "tentative de division par zéro"
-#: awkgram.y:4800 eval.c:2072
+#: awkgram.y:4514
#, c-format
msgid "division by zero attempted in `%%'"
msgstr "tentative de division par zéro dans « %% »"
-#: builtin.c:120
+#: builtin.c:122
#, c-format
msgid "%s to \"%s\" failed (%s)"
msgstr "échec de %s vers « %s » (%s)"
-#: builtin.c:121
+#: builtin.c:123
msgid "standard output"
msgstr "sortie standard"
-#: builtin.c:135
+#: builtin.c:137
msgid "exp: received non-numeric argument"
msgstr "exp : l'argument n'est pas numérique"
-#: builtin.c:141
+#: builtin.c:143
#, c-format
msgid "exp: argument %g is out of range"
msgstr "exp : l'argument %g est hors limite"
-#: builtin.c:200
+#: builtin.c:202
#, c-format
msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing"
msgstr ""
"fflush : vidage impossible : le tube « %s » est ouvert en lecture et non en "
"écriture"
-#: builtin.c:203
+#: builtin.c:205
#, c-format
msgid "fflush: cannot flush: file `%s' opened for reading, not writing"
msgstr ""
"fflush : vidage impossible : fichier « %s » ouvert en lecture, pas en "
"écriture"
-#: builtin.c:215
+#: builtin.c:217
#, c-format
msgid "fflush: `%s' is not an open file, pipe or co-process"
msgstr ""
"fflush : « %s » n'est ni un fichier ouvert, ni un tube, ni un co-processus"
-#: builtin.c:333
+#: builtin.c:335
msgid "index: received non-string first argument"
msgstr "index : le premier argument n'est pas une chaîne"
-#: builtin.c:335
+#: builtin.c:337
msgid "index: received non-string second argument"
msgstr "index : le second argument n'est pas une chaîne"
-#: builtin.c:457
+#: builtin.c:461
msgid "int: received non-numeric argument"
msgstr "int : l'argument n'est pas numérique"
-#: builtin.c:493
+#: builtin.c:497
msgid "length: received array argument"
msgstr "length : l'argument reçu est un tableau"
-#: builtin.c:496
+#: builtin.c:500
msgid "`length(array)' is a gawk extension"
msgstr "« length(tableau) » est une extension gawk"
-#: builtin.c:504
+#: builtin.c:508
msgid "length: received non-string argument"
msgstr "length : l'argument n'est pas une chaîne"
-#: builtin.c:535
+#: builtin.c:539
msgid "log: received non-numeric argument"
msgstr "log : l'argument n'est pas numérique"
-#: builtin.c:538
+#: builtin.c:542
#, c-format
msgid "log: received negative argument %g"
msgstr "log : l'argument est négatif %g"
-#: builtin.c:694 builtin.c:699
+#: builtin.c:740 builtin.c:745
msgid "fatal: must use `count$' on all formats or none"
msgstr ""
"fatal : « numéro$ » doit être utilisé pour toutes les formats ou pour aucun"
-#: builtin.c:762
+#: builtin.c:815
#, c-format
msgid "field width is ignored for `%%' specifier"
msgstr "taille du champ de la spécification « %% » ignorée"
-#: builtin.c:764
+#: builtin.c:817
#, c-format
msgid "precision is ignored for `%%' specifier"
msgstr "précision de la spécification « %% » ignorée"
-#: builtin.c:766
+#: builtin.c:819
#, c-format
msgid "field width and precision are ignored for `%%' specifier"
msgstr "taille du champ et précision de la spécification « %% » ignorées"
-#: builtin.c:817
+#: builtin.c:870
msgid "fatal: `$' is not permitted in awk formats"
msgstr "fatal : « $ » n'est pas autorisé dans les formats awk"
-#: builtin.c:826
+#: builtin.c:879
msgid "fatal: arg count with `$' must be > 0"
msgstr "fatal : le numéro d'argument de « $ » doit être > 0"
-#: builtin.c:830
+#: builtin.c:883
#, c-format
msgid "fatal: arg count %ld greater than total number of supplied arguments"
msgstr ""
"fatal : le numéro d'argument %ld est > au nombre total d'arguments fournis"
-#: builtin.c:834
+#: builtin.c:887
msgid "fatal: `$' not permitted after period in format"
msgstr "fatal : dans un format, « $ » ne doit pas suivre un point"
-#: builtin.c:850
+#: builtin.c:903
msgid "fatal: no `$' supplied for positional field width or precision"
msgstr ""
"fatal : aucun « $ » fourni pour la taille ou la précision du champ positionné"
-#: builtin.c:921
+#: builtin.c:975
msgid "`l' is meaningless in awk formats; ignored"
msgstr "« l » n'a aucun sens dans un format awk ; ignoré"
-#: builtin.c:925
+#: builtin.c:979
msgid "fatal: `l' is not permitted in POSIX awk formats"
msgstr "fatal : « l » est interdit dans un format awk POSIX"
-#: builtin.c:938
+#: builtin.c:992
msgid "`L' is meaningless in awk formats; ignored"
msgstr "« L » n'a aucun sens dans un format awk ; ignoré"
-#: builtin.c:942
+#: builtin.c:996
msgid "fatal: `L' is not permitted in POSIX awk formats"
msgstr "fatal : « L » est interdit dans un format awk POSIX"
-#: builtin.c:955
+#: builtin.c:1009
msgid "`h' is meaningless in awk formats; ignored"
msgstr "« h » n'a aucun sens dans un format awk ; ignoré"
-#: builtin.c:959
+#: builtin.c:1013
msgid "fatal: `h' is not permitted in POSIX awk formats"
msgstr "fatal : « h » est interdit dans un format awk POSIX"
-#: builtin.c:1272
+#: builtin.c:1408
#, c-format
msgid "[s]printf: value %g is out of range for `%%%c' format"
msgstr "[s]printf : valeur %g hors limite pour le format « %%%c »"
-#: builtin.c:1332
+#: builtin.c:1506
#, c-format
msgid "ignoring unknown format specifier character `%c': no argument converted"
msgstr "caractère de format inconnu « %c » ignoré : aucun argument converti"
-#: builtin.c:1337
+#: builtin.c:1511
msgid "fatal: not enough arguments to satisfy format string"
msgstr "fatal : pas assez d'arguments pour satisfaire la chaîne de formatage"
-#: builtin.c:1339
+#: builtin.c:1513
msgid "^ ran out for this one"
msgstr "^ à court pour celui-ci"
-#: builtin.c:1346
+#: builtin.c:1520
msgid "[s]printf: format specifier does not have control letter"
msgstr "[s]printf : spécification de format sans lettre de contrôle"
-#: builtin.c:1349
+#: builtin.c:1523
msgid "too many arguments supplied for format string"
msgstr "trop d'arguments pour la chaîne de formatage"
-#: builtin.c:1423 builtin.c:1434
+#: builtin.c:1598 builtin.c:1609
msgid "printf: no arguments"
msgstr "printf : aucun argument"
-#: builtin.c:1475
+#: builtin.c:1650
msgid "sqrt: received non-numeric argument"
msgstr "sqrt : l'argument n'est pas numérique"
-#: builtin.c:1479
+#: builtin.c:1654
#, c-format
msgid "sqrt: called with negative argument %g"
msgstr "sqrt : appelé avec un argument négatif %g"
-#: builtin.c:1503
+#: builtin.c:1685
#, c-format
msgid "substr: length %g is not >= 1"
msgstr "substr : la longueur %g n'est pas >= 1"
-#: builtin.c:1505
+#: builtin.c:1687
#, c-format
msgid "substr: length %g is not >= 0"
msgstr "substr : la longueur %g n'est pas >= 0"
-#: builtin.c:1512
+#: builtin.c:1694
#, c-format
msgid "substr: non-integer length %g will be truncated"
msgstr "substr : la longueur %g n'est pas entière, elle sera tronquée"
-#: builtin.c:1517
+#: builtin.c:1699
#, c-format
msgid "substr: length %g too big for string indexing, truncating to %g"
msgstr "substr : la longueur %g est trop grande, tronquée à %g"
-#: builtin.c:1529
+#: builtin.c:1711
#, c-format
msgid "substr: start index %g is invalid, using 1"
msgstr "substr : l'index de début %g n'est pas valide, utilisation de 1"
-#: builtin.c:1534
+#: builtin.c:1716
#, c-format
msgid "substr: non-integer start index %g will be truncated"
msgstr "substr : l'index de début %g n'est pas un entier, il sera tronqué"
-#: builtin.c:1559
+#: builtin.c:1741
msgid "substr: source string is zero length"
msgstr "substr : la chaîne source est de longueur nulle"
-#: builtin.c:1575
+#: builtin.c:1757
#, c-format
msgid "substr: start index %g is past end of string"
msgstr "substr : l'index de début %g est au-delà de la fin de la chaîne"
-#: builtin.c:1583
+#: builtin.c:1765
#, c-format
msgid ""
"substr: length %g at start index %g exceeds length of first argument (%lu)"
@@ -767,237 +724,232 @@ msgstr ""
"substr : la longueur %g à partir de %g dépasse la fin du 1er argument (%lu)"
# Exemple : gawk --lint 'BEGIN { PROCINFO["strftime"]=123 ; print strftime() }'
-#: builtin.c:1657
+#: builtin.c:1839
msgid "strftime: format value in PROCINFO[\"strftime\"] has numeric type"
msgstr ""
"strftime : la valeur de formatage PROCINFO[\"strftime\"] est de type "
"numérique"
-#: builtin.c:1680
+#: builtin.c:1862
msgid "strftime: received non-numeric second argument"
msgstr "strftime : le second argument n'est pas numérique"
-#: builtin.c:1683
+#: builtin.c:1866
msgid "strftime: second argument less than 0 or too big for time_t"
msgstr "strftime: second argument négatif ou trop grand pour time_t"
-#: builtin.c:1690
+#: builtin.c:1873
msgid "strftime: received non-string first argument"
msgstr "strftim : le premier argument n'est pas une chaîne"
-#: builtin.c:1696
+#: builtin.c:1880
msgid "strftime: received empty format string"
msgstr "strftime : la chaîne de formatage est vide"
-#: builtin.c:1762
+#: builtin.c:1946
msgid "mktime: received non-string argument"
msgstr "mktime : l'argument n'est pas une chaîne"
-#: builtin.c:1779
+#: builtin.c:1963
msgid "mktime: at least one of the values is out of the default range"
msgstr ""
"mktime : au moins l'une des valeurs est en dehors de la plage par défaut"
-#: builtin.c:1814
+#: builtin.c:1998
msgid "'system' function not allowed in sandbox mode"
msgstr "La fonction « system » est interdite en isolement (mode sandbox)"
-#: builtin.c:1819
+#: builtin.c:2003
msgid "system: received non-string argument"
msgstr "system : l'argument n'est pas une chaîne"
-#: builtin.c:1874 eval.c:1159 eval.c:1790 eval.c:1803
-#, c-format
-msgid "reference to uninitialized variable `%s'"
-msgstr "référence à une variable non initialisée « %s »"
-
-#: builtin.c:1941
+#: builtin.c:2121
#, c-format
msgid "reference to uninitialized field `$%d'"
msgstr "référence à un champ non initialisé « $%d »"
-#: builtin.c:2028
+#: builtin.c:2208
msgid "tolower: received non-string argument"
msgstr "tolower : l'argument n'est pas une chaîne"
-#: builtin.c:2062
+#: builtin.c:2242
msgid "toupper: received non-string argument"
msgstr "toupper : l'argument n'est pas une chaîne"
-#: builtin.c:2098
+#: builtin.c:2278
msgid "atan2: received non-numeric first argument"
msgstr "atan2 : le premier argument n'est pas numérique"
-#: builtin.c:2100
+#: builtin.c:2280
msgid "atan2: received non-numeric second argument"
msgstr "atan2 : le second argument n'est pas numérique"
-#: builtin.c:2119
+#: builtin.c:2299
msgid "sin: received non-numeric argument"
msgstr "sin : l'argument n'est pas numérique"
-#: builtin.c:2135
+#: builtin.c:2315
msgid "cos: received non-numeric argument"
msgstr "cos : l'argument n'est pas numérique"
-#: builtin.c:2188
+#: builtin.c:2368
msgid "srand: received non-numeric argument"
msgstr "srand : l'argument n'est pas numérique"
-#: builtin.c:2219
+#: builtin.c:2399
msgid "match: third argument is not an array"
msgstr "match : le 3e argument n'est pas un tableau"
-#: builtin.c:2483
+#: builtin.c:2664
msgid "gensub: third argument of 0 treated as 1"
msgstr "gensub : le 3e argument vaut 0, il sera traité comme un 1"
-#: builtin.c:2776
+#: builtin.c:2957
msgid "lshift: received non-numeric first argument"
msgstr "lshift : le premier argument n'est pas numérique"
-#: builtin.c:2778
+#: builtin.c:2959
msgid "lshift: received non-numeric second argument"
msgstr "lshift : le second argument reçu n'est pas numérique"
-#: builtin.c:2784
+#: builtin.c:2965
#, c-format
msgid "lshift(%lf, %lf): negative values will give strange results"
msgstr ""
"lshift(%lf, %lf) : les valeurs négatives donneront des résultats inattendus"
-#: builtin.c:2786
+#: builtin.c:2967
#, c-format
msgid "lshift(%lf, %lf): fractional values will be truncated"
msgstr "lshift(%lf, %lf) : les valeurs non entières seront tronquées"
-#: builtin.c:2788
+#: builtin.c:2969
#, c-format
msgid "lshift(%lf, %lf): too large shift value will give strange results"
msgstr ""
"lshift(%lf, %lf) : un décalage trop grand donnera des résultats inattendus"
-#: builtin.c:2813
+#: builtin.c:2994
msgid "rshift: received non-numeric first argument"
msgstr "rshift : le premier argument n'est pas numérique"
-#: builtin.c:2815
+#: builtin.c:2996
msgid "rshift: received non-numeric second argument"
msgstr "rshift : le second argument reçu n'est pas numérique"
-#: builtin.c:2821
+#: builtin.c:3002
#, c-format
msgid "rshift(%lf, %lf): negative values will give strange results"
msgstr ""
"rshift(%lf, %lf) : les valeurs négatives donneront des résultats inattendus"
-#: builtin.c:2823
+#: builtin.c:3004
#, c-format
msgid "rshift(%lf, %lf): fractional values will be truncated"
msgstr "rshift(%lf, %lf) : les valeurs non entières seront tronquées"
-#: builtin.c:2825
+#: builtin.c:3006
#, c-format
msgid "rshift(%lf, %lf): too large shift value will give strange results"
msgstr ""
"rshift(%lf, %lf) : un décalage trop grand donnera des résultats inattendus"
-#: builtin.c:2850
+#: builtin.c:3031
msgid "and: received non-numeric first argument"
msgstr "and : le premier argument n'est pas numérique"
-#: builtin.c:2852
+#: builtin.c:3033
msgid "and: received non-numeric second argument"
msgstr "and : le second argument reçu n'est pas numérique"
-#: builtin.c:2858
+#: builtin.c:3039
#, c-format
msgid "and(%lf, %lf): negative values will give strange results"
msgstr ""
"and(%lf, %lf) : les valeurs négatives donneront des résultats inattendus"
-#: builtin.c:2860
+#: builtin.c:3041
#, c-format
msgid "and(%lf, %lf): fractional values will be truncated"
msgstr "and(%lf, %lf): les valeurs non entières seront tronquées"
-#: builtin.c:2885
+#: builtin.c:3066
msgid "or: received non-numeric first argument"
msgstr "or : le premier argument n'est pas numérique"
-#: builtin.c:2887
+#: builtin.c:3068
msgid "or: received non-numeric second argument"
msgstr "or : le second argument reçu n'est pas numérique"
-#: builtin.c:2893
+#: builtin.c:3074
#, c-format
msgid "or(%lf, %lf): negative values will give strange results"
msgstr ""
"or(%lf, %lf) : les valeurs négatives donneront des résultats inattendus"
-#: builtin.c:2895
+#: builtin.c:3076
#, c-format
msgid "or(%lf, %lf): fractional values will be truncated"
msgstr "or(%lf, %lf) : les valeurs non entières seront tronquées"
-#: builtin.c:2923
+#: builtin.c:3102
msgid "xor: received non-numeric first argument"
msgstr "xor : le premier argument n'est pas numérique"
-#: builtin.c:2925
+#: builtin.c:3104
msgid "xor: received non-numeric second argument"
msgstr "xor : le second argument reçu n'est pas numérique"
-#: builtin.c:2931
+#: builtin.c:3110
#, c-format
msgid "xor(%lf, %lf): negative values will give strange results"
msgstr ""
"xor(%lf, %lf) : les valeurs négatives donneront des résultats inattendus"
-#: builtin.c:2933
+#: builtin.c:3112
#, c-format
msgid "xor(%lf, %lf): fractional values will be truncated"
msgstr "xor(%lf, %lf) : les valeurs non entières seront tronquées"
-#: builtin.c:2957 builtin.c:2963
+#: builtin.c:3136
msgid "compl: received non-numeric argument"
msgstr "compl : l'argument n'est pas numérique"
-#: builtin.c:2965
+#: builtin.c:3142
#, c-format
msgid "compl(%lf): negative value will give strange results"
msgstr "compl(%lf) : les valeurs négatives donneront des résultats inattendus"
-#: builtin.c:2967
+#: builtin.c:3144
#, c-format
msgid "compl(%lf): fractional value will be truncated"
msgstr "compl(%lf) : les valeurs non entières seront tronquées"
-#: builtin.c:3136
+#: builtin.c:3313
#, c-format
msgid "dcgettext: `%s' is not a valid locale category"
msgstr "dcgettext : « %s » n'est pas dans un catégorie valide de la locale"
-#: eval.c:412
+#: eval.c:395
#, c-format
msgid "unknown nodetype %d"
msgstr "type de nœud %d inconnu"
-#: eval.c:423 eval.c:437
+#: eval.c:406 eval.c:420
#, c-format
msgid "unknown opcode %d"
msgstr "code opération %d inconnu"
-#: eval.c:434
+#: eval.c:417
#, c-format
msgid "opcode %s not an operator or keyword"
msgstr "le code opération %s n'est pas un opérateur ou un mot-clef"
-#: eval.c:488
+#: eval.c:472
msgid "buffer overflow in genflags2str"
msgstr "débordement de tampon dans genflag2str"
-#: eval.c:698
+#: eval.c:675
#, c-format
msgid ""
"\n"
@@ -1008,308 +960,253 @@ msgstr ""
"\t# Pile des appels de fonctions :\n"
"\n"
-#: eval.c:725
+#: eval.c:704
msgid "`IGNORECASE' is a gawk extension"
msgstr "« IGNORECASE » est une extension gawk"
-#: eval.c:754
+#: eval.c:736
msgid "`BINMODE' is a gawk extension"
msgstr "« BINMODE » est une extension gawk"
-#: eval.c:812
+#: eval.c:793
#, c-format
msgid "BINMODE value `%s' is invalid, treated as 3"
msgstr "la valeur « %s » de BINMODE n'est pas valide, 3 utilisé à la place"
-#: eval.c:902
+#: eval.c:885
#, c-format
msgid "bad `%sFMT' specification `%s'"
msgstr "spécification de « %sFMT » erronée « %s »"
-#: eval.c:980
+#: eval.c:969
msgid "turning off `--lint' due to assignment to `LINT'"
msgstr "désactivation de « --lint » en raison d'une affectation à « LINT »"
-#: eval.c:1127 eval.c:1777
-#, c-format
-msgid "can't use function name `%s' as variable or array"
-msgstr "impossible d'utiliser la fonction « %s » comme variable ou tableau"
-
-#: eval.c:1158 eval.c:1789 eval.c:1802
+#: eval.c:1132
#, c-format
msgid "reference to uninitialized argument `%s'"
msgstr "référence à un argument non initialisé « %s »"
-#: eval.c:1177
+#: eval.c:1133
+#, c-format
+msgid "reference to uninitialized variable `%s'"
+msgstr "référence à une variable non initialisée « %s »"
+
+#: eval.c:1151
msgid "attempt to field reference from non-numeric value"
msgstr "tentative de référence à un champ via une valeur non numérique"
-#: eval.c:1179
+#: eval.c:1153
msgid "attempt to field reference from null string"
msgstr "tentative de référence à un champ via une chaîne nulle"
-#: eval.c:1185
+#: eval.c:1161
#, c-format
msgid "attempt to access field %ld"
msgstr "tentative d'accès au champ %ld"
-#: eval.c:1194
+#: eval.c:1170
#, c-format
msgid "reference to uninitialized field `$%ld'"
msgstr "référence à un champ non initialisé « $%ld »"
-#: eval.c:1256
+#: eval.c:1257
#, c-format
msgid "function `%s' called with more arguments than declared"
msgstr "la fonction « %s » a été appelée avec trop d'arguments"
-#: eval.c:1437
+#: eval.c:1452
#, c-format
msgid "unwind_stack: unexpected type `%s'"
msgstr "unwind_stack: type « %s » inattendu"
-#: eval.c:1532
+#: eval.c:1546
msgid "division by zero attempted in `/='"
msgstr "tentative de division par zéro dans « /= »"
-#: eval.c:1539
+#: eval.c:1553
#, c-format
msgid "division by zero attempted in `%%='"
msgstr "tentative de division par zéro dans « %%= »"
-#: eval.c:1876 eval.c:2122
-#, c-format
-msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
-msgstr ""
-"tentative d'utilisation du tableau « %s[\"%.*s\"] » dans un contexte scalaire"
-
-#: eval.c:1907
-msgid "assignment used in conditional context"
-msgstr "affectation utilisée dans un contexte conditionnel"
-
-#: eval.c:1911
-msgid "statement has no effect"
-msgstr "la déclaration est sans effet"
-
-#: eval.c:2343
-#, c-format
-msgid "for loop: array `%s' changed size from %ld to %ld during loop execution"
-msgstr "boucle for : la taille du tableau « %s » est passée de %ld à %ld"
-
-#: eval.c:2458
-#, c-format
-msgid "function called indirectly through `%s' does not exist"
-msgstr "la fonction indirectement appelée via « %s » n'existe pas"
-
-#: eval.c:2470
-#, c-format
-msgid "function `%s' not defined"
-msgstr "fonction « %s » non définie"
-
-#: eval.c:2511
-#, c-format
-msgid "non-redirected `getline' invalid inside `%s' rule"
-msgstr "un « getline » non redirigé n'est pas valable dans une règle « %s »"
-
-#: eval.c:2600
-#, c-format
-msgid "error reading input file `%s': %s"
-msgstr "erreur lors de la lecture du fichier en entrée « %s » : %s"
-
-#: eval.c:2614
-#, c-format
-msgid "`nextfile' cannot be called from a `%s' rule"
-msgstr "« nextfile » ne peut pas être appelé depuis une règle « %s »"
-
-#: eval.c:2661
-msgid "`exit' cannot be called in the current context"
-msgstr "« exit » ne peut pas être appelé dans ce contexte"
-
-#: eval.c:2700
-#, c-format
-msgid "`next' cannot be called from a `%s' rule"
-msgstr "« next » ne peut pas être appelé depuis une règle « %s »"
-
-#: eval.c:2766
-#, c-format
-msgid "Sorry, don't know how to interpret `%s'"
-msgstr "Désolé, je ne sais pas comment interpréter « %s »"
-
-#: ext.c:54
+#: ext.c:70
msgid "extensions are not allowed in sandbox mode"
msgstr "les extensions sont interdites en isolement (mode sandbox)"
-#: ext.c:60 ext.c:65
+#: ext.c:73
msgid "`extension' is a gawk extension"
msgstr "« extension » est une extension gawk"
-#: ext.c:75
-#, c-format
-msgid "fatal: extension: cannot open `%s' (%s)\n"
+#: ext.c:80
+#, fuzzy, c-format
+msgid "extension: cannot open library `%s' (%s)\n"
msgstr "fatal : extension : impossible d'ouvrir « %s » (%s)\n"
-#: ext.c:84
-#, c-format
+#: ext.c:86
+#, fuzzy, c-format
msgid ""
-"fatal: extension: library `%s': does not define "
-"`plugin_is_GPL_compatible' (%s)\n"
+"extension: library `%s': does not define `plugin_is_GPL_compatible' (%s)\n"
msgstr ""
"fatal : extension : la bibliothèque « %s »ne définit pas "
"« plugin_is_GPL_compatible » (%s)\n"
-#: ext.c:93
-#, c-format
-msgid "fatal: extension: library `%s': cannot call function `%s' (%s)\n"
+#: ext.c:90
+#, fuzzy, c-format
+msgid "extension: library `%s': cannot call function `%s' (%s)\n"
msgstr ""
"fatal : extension : bibliothèque « %s » : impossible d'appeler la fonction "
"« %s » (%s)\n"
-#: ext.c:127
+#: ext.c:118
msgid "extension: missing function name"
msgstr "extension : nom de fonction manquant"
-#: ext.c:132
+#: ext.c:123
#, c-format
msgid "extension: illegal character `%c' in function name `%s'"
msgstr "extension : caractère illégal « %c » dans le nom de la fonction « %s »"
-#: ext.c:141
+#: ext.c:131
#, c-format
msgid "extension: can't redefine function `%s'"
msgstr "extension : impossible de redéfinir la fonction « %s »"
-#: ext.c:145
+#: ext.c:135
#, c-format
msgid "extension: function `%s' already defined"
msgstr "extension : fonction « %s » est déjà définie"
-#: ext.c:150
+#: ext.c:139
#, c-format
msgid "extension: function name `%s' previously defined"
msgstr "extension : nom de la fonction « %s » déjà défini"
-#: ext.c:152
+#: ext.c:141
#, c-format
msgid "extension: can't use gawk built-in `%s' as function name"
msgstr ""
"extension : impossible d'utiliser la fonction interne gawk « %s » comme nom "
"de fonction"
-#: ext.c:156
+#: ext.c:144
#, c-format
msgid "make_builtin: negative argument count for function `%s'"
msgstr "make_builtin : la fonction « %s » a un nombre négatif d'arguments"
-#: ext.c:259
+#: ext.c:206
#, c-format
msgid "function `%s' defined to take no more than %d argument(s)"
msgstr "fonction « %s » définie comme ayant au maximum« %d » argument(s)"
-#: ext.c:262
+#: ext.c:209
#, c-format
msgid "function `%s': missing argument #%d"
msgstr "fonction « %s » : argument #%d manquant"
-#: ext.c:279
+#: ext.c:226
#, c-format
msgid "function `%s': argument #%d: attempt to use scalar as an array"
msgstr ""
"fonction « %s » : argument #%d : tentative d'utilisation d'un scalaire comme "
"tableau"
-#: ext.c:283
+#: ext.c:230
#, c-format
msgid "function `%s': argument #%d: attempt to use array as a scalar"
msgstr ""
"fonction « %s » : argument #%d : tentative d'utiliser un tableau comme "
"scalaire"
-#: ext.c:296
+#: ext.c:244
msgid "Operation Not Supported"
msgstr "Opération non disponible"
-#: field.c:328
+#: ext.c:256
+msgid "dynamic loading of library not supported"
+msgstr ""
+
+#: field.c:339
msgid "NF set to negative value"
msgstr "une valeur négative a été assignée à NF"
-#: field.c:951 field.c:958 field.c:962
+#: field.c:962 field.c:969 field.c:973
msgid "split: fourth argument is a gawk extension"
msgstr "split : le 4e argument est une extension gawk"
-#: field.c:955
+#: field.c:966
msgid "split: fourth argument is not an array"
msgstr "split : le 4e argument n'est pas un tableau"
-#: field.c:969
+#: field.c:980
msgid "split: second argument is not an array"
msgstr "split : le 2e argument n'est pas un tableau"
-#: field.c:973
+#: field.c:984
msgid "split: cannot use the same array for second and fourth args"
msgstr "split : impossible d'utiliser le même tableau comme 2e et 4e argument"
-#: field.c:978
+#: field.c:989
msgid "split: cannot use a subarray of second arg for fourth arg"
msgstr ""
"split : impossible d'utiliser un sous-tableau du 2e argument en 4e argument"
-#: field.c:981
+#: field.c:992
msgid "split: cannot use a subarray of fourth arg for second arg"
msgstr ""
"split : impossible d'utiliser un sous-tableau du 4e argument en 2e argument"
-#: field.c:1010
+#: field.c:1021
msgid "split: null string for third arg is a gawk extension"
msgstr "split : utiliser une chaîne vide en 3e argument est une extension gawk"
-#: field.c:1050
+#: field.c:1061
msgid "patsplit: fourth argument is not an array"
msgstr "patsplit : le 4e argument n'est pas un tableau"
-#: field.c:1055
+#: field.c:1066
msgid "patsplit: second argument is not an array"
msgstr "patsplit : le 2e argument n'est pas un tableau"
-#: field.c:1061
+#: field.c:1072
msgid "patsplit: third argument must be non-null"
msgstr "patsplit : le 3e argument n'est pas un tableau"
-#: field.c:1065
+#: field.c:1076
msgid "patsplit: cannot use the same array for second and fourth args"
msgstr ""
"patsplit : impossible d'utiliser le même tableau comme 2e et 4e argument"
-#: field.c:1070
+#: field.c:1081
msgid "patsplit: cannot use a subarray of second arg for fourth arg"
msgstr ""
"patsplit : impossible d'utiliser un sous-tableau du 2e argument en 4e "
"argument"
-#: field.c:1073
+#: field.c:1084
msgid "patsplit: cannot use a subarray of fourth arg for second arg"
msgstr ""
"patsplit : impossible d'utiliser un sous-tableau du 4e argument en 2e "
"argument"
-#: field.c:1110
+#: field.c:1122
msgid "`FIELDWIDTHS' is a gawk extension"
msgstr "« FIELDWIDTHS » est une extension gawk"
-#: field.c:1173
+#: field.c:1186
#, c-format
msgid "invalid FIELDWIDTHS value, near `%s'"
msgstr "valeur de FIELDWIDTHS non valide, près de « %s »"
-#: field.c:1246
+#: field.c:1259
msgid "null string for `FS' is a gawk extension"
msgstr "utiliser une chaîne vide pour « FS » est une extension gawk"
-#: field.c:1250
+#: field.c:1263
msgid "old awk does not support regexps as value of `FS'"
msgstr ""
"l'ancien awk n'accepte pas les expr. rationnelles comme valeur de « FS »"
-#: field.c:1369
+#: field.c:1382
msgid "`FPAT' is a gawk extension"
msgstr "« FPAT » est une extension gawk"
@@ -1368,472 +1265,487 @@ msgstr "%s : l'option « -W %s » n'accepte pas d'argument\n"
msgid "%s: option '-W %s' requires an argument\n"
msgstr "%s : l'option « -W %s » nécessite un argument\n"
-#: io.c:280
+#: io.c:326
#, c-format
msgid "command line argument `%s' is a directory: skipped"
msgstr "L'argument « %s » de la ligne de commande est un répertoire : ignoré"
-#: io.c:283 io.c:385
+#: io.c:329 io.c:438
#, c-format
msgid "cannot open file `%s' for reading (%s)"
msgstr "impossible d'ouvrir le fichier « %s » en lecture (%s)"
-#: io.c:501
+#: io.c:568
#, c-format
msgid "close of fd %d (`%s') failed (%s)"
msgstr "échec de la fermeture du fd %d (« %s ») : %s"
-#: io.c:578
+#: io.c:645
msgid "redirection not allowed in sandbox mode"
msgstr "les redirections sont interdites en isolement (mode sandbox)"
-#: io.c:612
+#: io.c:679
#, c-format
msgid "expression in `%s' redirection only has numeric value"
msgstr "l'expression dans la redirection « %s » n'a qu'une valeur numérique"
-#: io.c:618
+#: io.c:685
#, c-format
msgid "expression for `%s' redirection has null string value"
msgstr "l'expression dans la redirection « %s » donne une chaîne nulle"
-#: io.c:623
+#: io.c:690
#, c-format
msgid "filename `%s' for `%s' redirection may be result of logical expression"
msgstr ""
"le fichier « %s » de la redirection « %s » pourrait être le résultat d'une "
"expression booléenne"
-#: io.c:666
+#: io.c:733
#, c-format
msgid "unnecessary mixing of `>' and `>>' for file `%.*s'"
msgstr "mélange non nécessaire de « > » et « >> » pour le fichier « %.*s »"
-#: io.c:719
+#: io.c:786
#, c-format
msgid "can't open pipe `%s' for output (%s)"
msgstr "impossible d'ouvrir le tube « %s » en sortie (%s)"
-#: io.c:729
+#: io.c:796
#, c-format
msgid "can't open pipe `%s' for input (%s)"
msgstr "impossible d'ouvrir le tube « %s » en entrée (%s)"
-#: io.c:752
+#: io.c:819
#, c-format
msgid "can't open two way pipe `%s' for input/output (%s)"
msgstr ""
"impossible d'ouvrir un tube bidirectionnel « %s » en entrées-sorties (%s)"
-#: io.c:834
+#: io.c:900
#, c-format
msgid "can't redirect from `%s' (%s)"
msgstr "impossible de rediriger depuis « %s » (%s)"
-#: io.c:837
+#: io.c:903
#, c-format
msgid "can't redirect to `%s' (%s)"
msgstr "impossible de rediriger vers « %s » (%s)"
-#: io.c:888
+#: io.c:954
msgid ""
"reached system limit for open files: starting to multiplex file descriptors"
msgstr ""
"limite système du nombre de fichiers ouverts atteinte : début du "
"multiplexage des descripteurs de fichiers"
-#: io.c:904
+#: io.c:970
#, c-format
msgid "close of `%s' failed (%s)."
msgstr "échec de la fermeture de « %s » (%s)"
-#: io.c:912
+#: io.c:978
msgid "too many pipes or input files open"
msgstr "trop de fichiers d'entrées ou de tubes ouverts"
-#: io.c:934
+#: io.c:1000
msgid "close: second argument must be `to' or `from'"
msgstr "close : le second argument doit être « to » ou « from »"
-#: io.c:951
+#: io.c:1017
#, c-format
msgid "close: `%.*s' is not an open file, pipe or co-process"
msgstr ""
"close : « %.*s » n'est ni un fichier ouvert, ni un tube ou un co-processus"
-#: io.c:956
+#: io.c:1022
msgid "close of redirection that was never opened"
msgstr "fermeture d'une redirection qui n'a jamais été ouverte"
-#: io.c:1053
+#: io.c:1120
#, c-format
msgid "close: redirection `%s' not opened with `|&', second argument ignored"
msgstr ""
"close : la redirection « %s » n'a pas été ouverte avec « |& », second "
"argument ignoré"
-#: io.c:1069
+#: io.c:1137
#, c-format
msgid "failure status (%d) on pipe close of `%s' (%s)"
msgstr "résultat d'échec (%d) sur la fermeture du tube « %s » (%s)"
-#: io.c:1072
+#: io.c:1140
#, c-format
msgid "failure status (%d) on file close of `%s' (%s)"
msgstr "résultat d'échec (%d) sur la fermeture du fichier « %s » (%s)"
-#: io.c:1092
+#: io.c:1160
#, c-format
msgid "no explicit close of socket `%s' provided"
msgstr "aucune fermeture explicite du connecteur « %s » fournie"
-#: io.c:1095
+#: io.c:1163
#, c-format
msgid "no explicit close of co-process `%s' provided"
msgstr "aucune fermeture explicite du co-processus « %s » fournie"
-#: io.c:1098
+#: io.c:1166
#, c-format
msgid "no explicit close of pipe `%s' provided"
msgstr "aucune fermeture explicite du tube « %s » fournie"
-#: io.c:1101
+#: io.c:1169
#, c-format
msgid "no explicit close of file `%s' provided"
msgstr "aucune fermeture explicite du fichier « %s » fournie"
-#: io.c:1129 io.c:1184 main.c:794 main.c:831
+#: io.c:1197 io.c:1252 main.c:825 main.c:862
#, c-format
msgid "error writing standard output (%s)"
msgstr "erreur lors de l'écriture vers la sortie standard (%s)"
-#: io.c:1133 io.c:1189
+#: io.c:1201 io.c:1257
#, c-format
msgid "error writing standard error (%s)"
msgstr "erreur lors de l'écriture vers l'erreur standard (%s)"
-#: io.c:1141
+#: io.c:1209
#, c-format
msgid "pipe flush of `%s' failed (%s)."
msgstr "échec du vidage du tube « %s » (%s)."
-#: io.c:1144
+#: io.c:1212
#, c-format
msgid "co-process flush of pipe to `%s' failed (%s)."
msgstr "échec du vidage du tube vers « %s » par le co-processus (%s)."
-#: io.c:1147
+#: io.c:1215
#, c-format
msgid "file flush of `%s' failed (%s)."
msgstr "échec du vidage vers le fichier « %s » (%s)"
-#: io.c:1262
+#: io.c:1329
#, c-format
msgid "local port %s invalid in `/inet'"
msgstr "le port local %s n'est pas valide dans « /inet »"
-#: io.c:1279
+#: io.c:1347
#, c-format
msgid "remote host and port information (%s, %s) invalid"
msgstr ""
"les informations sur l'hôte et le port distants (%s, %s) ne sont pas valides"
-#: io.c:1431
+#: io.c:1499
#, c-format
msgid "no (known) protocol supplied in special filename `%s'"
msgstr ""
"aucun protocole (connu) n'a été fourni dans le nom de fichier spécial « %s »"
-#: io.c:1445
+#: io.c:1513
#, c-format
msgid "special file name `%s' is incomplete"
msgstr "nom de fichier spécial « %s » incomplet"
-#: io.c:1462
+#: io.c:1530
msgid "must supply a remote hostname to `/inet'"
msgstr "un nom d'hôte distant doit être fourni à « /inet »"
-#: io.c:1480
+#: io.c:1548
msgid "must supply a remote port to `/inet'"
msgstr "un port distant doit être fourni à « /inet »"
-#: io.c:1526
+#: io.c:1594
msgid "TCP/IP communications are not supported"
msgstr "les communications TCP/IP ne sont pas disponibles"
-#: io.c:1693
+#: io.c:1764
#, c-format
msgid "could not open `%s', mode `%s'"
msgstr "impossible d'ouvrir « %s », mode « %s »"
-#: io.c:1747
+#: io.c:1814
#, c-format
msgid "close of master pty failed (%s)"
msgstr "échec de la fermeture du pty maître (%s)"
-#: io.c:1749 io.c:1917 io.c:2074
+#: io.c:1816 io.c:1984 io.c:2145
#, c-format
msgid "close of stdout in child failed (%s)"
msgstr "échec de la fermeture de stdout du processus fils (%s)"
-#: io.c:1752
+#: io.c:1819
#, c-format
msgid "moving slave pty to stdout in child failed (dup: %s)"
msgstr ""
"échec du déplacement du pty esclave vers le stdout du processus fils (dup : "
"%s)"
-#: io.c:1754 io.c:1922
+#: io.c:1821 io.c:1989
#, c-format
msgid "close of stdin in child failed (%s)"
msgstr "échec de fermeture du stdin du processus fils (%s)"
-#: io.c:1757
+#: io.c:1824
#, c-format
msgid "moving slave pty to stdin in child failed (dup: %s)"
msgstr ""
"échec du déplacement du pty esclave vers le stdin du processus fils (dup : "
"%s)"
-#: io.c:1759 io.c:1780
+#: io.c:1826 io.c:1847
#, c-format
msgid "close of slave pty failed (%s)"
msgstr "échec de la fermeture du pty esclave (%s)"
-#: io.c:1858 io.c:1920 io.c:2052 io.c:2077
+#: io.c:1925 io.c:1987 io.c:2122 io.c:2148
#, c-format
msgid "moving pipe to stdout in child failed (dup: %s)"
msgstr "échec du déplacement du tube vers stdout du processus fils (dup : %s)"
-#: io.c:1865 io.c:1925
+#: io.c:1932 io.c:1992
#, c-format
msgid "moving pipe to stdin in child failed (dup: %s)"
msgstr "échec de déplacement du tube vers stdin du processus fils (dup : %s)"
-#: io.c:1885 io.c:2067
+#: io.c:1952 io.c:2138
msgid "restoring stdout in parent process failed\n"
msgstr "échec de la restauration du stdout dans le processus parent\n"
-#: io.c:1893
+#: io.c:1960
msgid "restoring stdin in parent process failed\n"
msgstr "échec de la restauration du stdin dans le processus parent\n"
-#: io.c:1928 io.c:2079 io.c:2093
+#: io.c:1995 io.c:2150 io.c:2164
#, c-format
msgid "close of pipe failed (%s)"
msgstr "échec de la fermeture du tube (%s)"
-#: io.c:1973
+#: io.c:2040
msgid "`|&' not supported"
msgstr "« |& » non disponible"
-#: io.c:2039
+#: io.c:2107
#, c-format
msgid "cannot open pipe `%s' (%s)"
msgstr "impossible d'ouvrir le tube « %s » (%s)"
-#: io.c:2087
+#: io.c:2158
#, c-format
msgid "cannot create child process for `%s' (fork: %s)"
msgstr "impossible de créer le processus fils pour « %s » (fork : %s)"
-#: io.c:2520
+#: io.c:2637
#, c-format
msgid "data file `%s' is empty"
msgstr "le fichier de données « %s » est vide"
-#: io.c:2561 io.c:2569
+#: io.c:2678 io.c:2686
msgid "could not allocate more input memory"
msgstr "impossible d'allouer plus de mémoire d'entrée"
-#: io.c:3127
+#: io.c:3236
msgid "multicharacter value of `RS' is a gawk extension"
msgstr ""
"l'utilisation d'un « RS » de plusieurs caractères est une extension gawk"
-#: io.c:3232
+#: io.c:3326
msgid "IPv6 communication is not supported"
msgstr "les communications IPv6 ne sont pas disponibles"
-#: main.c:366
+#: main.c:355
msgid "`-m[fr]' option irrelevant in gawk"
msgstr "l'option « -m[fr] » n'est pas pertinente en gawk"
-#: main.c:368
+#: main.c:357
msgid "-m option usage: `-m[fr] nnn'"
msgstr "utilisation de l'option « -m » : « -m[fr] nnn »"
-#: main.c:391
+#: main.c:386
msgid "empty argument to `-e/--source' ignored"
msgstr "argument vide de l'option « -e / --source » ignoré"
-#: main.c:462
+#: main.c:472
#, c-format
msgid "%s: option `-W %s' unrecognized, ignored\n"
msgstr "%s : option « -W %s » non reconnue, ignorée\n"
-#: main.c:515
+#: main.c:518
#, c-format
msgid "%s: option requires an argument -- %c\n"
msgstr "%s : l'option requiert un argument -- %c\n"
-#: main.c:536
+#: main.c:539
msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'"
msgstr ""
"variable d'environnement « POSIXLY__CORRECT » définie : activation de « --"
"posix »"
-#: main.c:542
+#: main.c:545
msgid "`--posix' overrides `--traditional'"
msgstr "« --posix » prend le pas sur « --traditional »"
-#: main.c:553
+#: main.c:556
msgid "`--posix'/`--traditional' overrides `--non-decimal-data'"
msgstr ""
"« --posix » et « --traditional » prennent le pas sur « --non-decimal-data »"
-#: main.c:557
+#: main.c:560
#, c-format
msgid "running %s setuid root may be a security problem"
msgstr ""
"l'exécution de %s en mode setuid root peut être un problème de sécurité"
-#: main.c:562
+#: main.c:565
msgid "`--posix' overrides `--binary'"
msgstr "« --posix » prend le pas sur « --binary »"
-#: main.c:613
+#: main.c:623
#, c-format
msgid "can't set binary mode on stdin (%s)"
msgstr "impossible d'activer le mode binaire sur stdin (%s)"
-#: main.c:616
+#: main.c:626
#, c-format
msgid "can't set binary mode on stdout (%s)"
msgstr "impossible d'activer le mode binaire sur stdout (%s)"
-#: main.c:618
+#: main.c:628
#, c-format
msgid "can't set binary mode on stderr (%s)"
msgstr "impossible d'activer le mode binaire sur stderr (%s)"
-#: main.c:657
+#: main.c:679
msgid "no program text at all!"
msgstr "aucun programme !"
-#: main.c:734
+#: main.c:763
#, c-format
msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n"
msgstr ""
"Utilisation : %s [options GNU ou POSIX] -f fichier_prog [--] fichier ...\n"
-#: main.c:736
+#: main.c:765
#, c-format
msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n"
msgstr ""
"Utilisation : %s [options GNU ou POSIX] [--] %cprogramme%c fichier ...\n"
-#: main.c:741
+#: main.c:770
msgid "POSIX options:\t\tGNU long options: (standard)\n"
msgstr "Options POSIX :\t\tOptions longues GNU : (standard)\n"
-#: main.c:742
+#: main.c:771
msgid "\t-f progfile\t\t--file=progfile\n"
msgstr "\t-f fichier_prog\t\t--file=fichier_prog\n"
-#: main.c:743
+#: main.c:772
msgid "\t-F fs\t\t\t--field-separator=fs\n"
msgstr "\t-F fs\t\t\t--field-separator=fs\n"
-#: main.c:744
+#: main.c:773
msgid "\t-v var=val\t\t--assign=var=val\n"
msgstr "\t-v var=valeur\t\t--assign=var=valeur\n"
-#: main.c:745
+#: main.c:774
msgid "Short options:\t\tGNU long options: (extensions)\n"
msgstr "Options POSIX :\t\tOptions longues GNU : (extensions)\n"
-#: main.c:746
+#: main.c:775
msgid "\t-b\t\t\t--characters-as-bytes\n"
msgstr "\t-b\t\t\t--characters-as-bytes\n"
-#: main.c:747
+#: main.c:776
msgid "\t-c\t\t\t--traditional\n"
msgstr "\t-c\t\t\t--traditional\n"
-#: main.c:748
+#: main.c:777
msgid "\t-C\t\t\t--copyright\n"
msgstr "\t-C\t\t\t--copyright\n"
-#: main.c:749
+#: main.c:778
msgid "\t-d[file]\t\t--dump-variables[=file]\n"
msgstr "\t-d[fichier]\t\t--dump-variables[=fichier]\n"
-#: main.c:750
+#: main.c:779
+#, fuzzy
+msgid "\t-D[file]\t\t--debug[=file]\n"
+msgstr "\t-p[fichier]\t\t--profile[=fichier]\n"
+
+#: main.c:780
msgid "\t-e 'program-text'\t--source='program-text'\n"
msgstr "\t-e 'programme'\t\t--source='programme'\n"
-#: main.c:751
+#: main.c:781
msgid "\t-E file\t\t\t--exec=file\n"
msgstr "\t-E fichier\t\t--exec=fichier\n"
-#: main.c:752
+#: main.c:782
msgid "\t-g\t\t\t--gen-pot\n"
msgstr "\t-g\t\t\t--gen-pot\n"
-#: main.c:753
+#: main.c:783
msgid "\t-h\t\t\t--help\n"
msgstr "\t-h\t\t\t--help\n"
-#: main.c:754
+#: main.c:784
+msgid "\t-l library\t\t--load=library\n"
+msgstr ""
+
+#: main.c:785
msgid "\t-L [fatal]\t\t--lint[=fatal]\n"
msgstr "\t-L [fatal]\t\t--lint[=fatal]\n"
-#: main.c:755
+#: main.c:786
msgid "\t-n\t\t\t--non-decimal-data\n"
msgstr "\t-n\t\t\t--non-decimal-data\n"
-#: main.c:756
+#: main.c:787
+#, fuzzy
+msgid "\t-M\t\t\t--bignum\n"
+msgstr "\t-g\t\t\t--gen-pot\n"
+
+#: main.c:788
msgid "\t-N\t\t\t--use-lc-numeric\n"
msgstr "\t-N\t\t\t--use-lc-numeric\n"
-#: main.c:757
+#: main.c:789
+#, fuzzy
+msgid "\t-o[file]\t\t--pretty-print[=file]\n"
+msgstr "\t-p[fichier]\t\t--profile[=fichier]\n"
+
+#: main.c:790
msgid "\t-O\t\t\t--optimize\n"
msgstr "\t-O\t\t\t--optimize\n"
-#: main.c:758
+#: main.c:791
msgid "\t-p[file]\t\t--profile[=file]\n"
msgstr "\t-p[fichier]\t\t--profile[=fichier]\n"
-#: main.c:759
+#: main.c:792
msgid "\t-P\t\t\t--posix\n"
msgstr "\t-P\t\t\t--posix\n"
-#: main.c:760
+#: main.c:793
msgid "\t-r\t\t\t--re-interval\n"
msgstr "\t-r\t\t\t--re-interval\n"
-#: main.c:762
-msgid "\t-R file\t\t\t--command=file\n"
-msgstr "\t-R fichier\t\t\t--command=fichier\n"
-
-#: main.c:763
+#: main.c:794
msgid "\t-S\t\t\t--sandbox\n"
msgstr "\t-S\t\t\t--sandbox\n"
-#: main.c:764
+#: main.c:795
msgid "\t-t\t\t\t--lint-old\n"
msgstr "\t-t\t\t\t--lint-old\n"
-#: main.c:765
+#: main.c:796
msgid "\t-V\t\t\t--version\n"
msgstr "\t-V\t\t\t--version\n"
-#: main.c:767
+#: main.c:798
msgid "\t-W nostalgia\t\t--nostalgia\n"
msgstr "\t-W nostalgia\t\t--nostalgia\n"
-#: main.c:770
+#: main.c:801
msgid "\t-Y\t\t--parsedebug\n"
msgstr "\t-Y\t\t--parsedebug\n"
@@ -1842,7 +1754,7 @@ msgstr "\t-Y\t\t--parsedebug\n"
#. for this application. Please add _another line_ with the
#. address for translation bugs.
#. no-wrap
-#: main.c:779
+#: main.c:810
msgid ""
"\n"
"To report bugs, see node `Bugs' in `gawk.info', which is\n"
@@ -1857,7 +1769,7 @@ msgstr ""
"<traduc CHEZ traduc POINT org>.\n"
"\n"
-#: main.c:783
+#: main.c:814
msgid ""
"gawk is a pattern scanning and processing language.\n"
"By default it reads standard input and writes standard output.\n"
@@ -1867,7 +1779,7 @@ msgstr ""
"Par défaut, il lit l'entrée standard et écrit sur la sortie standard.\n"
"\n"
-#: main.c:787
+#: main.c:818
msgid ""
"Examples:\n"
"\tgawk '{ sum += $1 }; END { print sum }' file\n"
@@ -1877,7 +1789,7 @@ msgstr ""
"\tgawk '{ somme += $1 }; END { print somme }' fichier\n"
"\tgawk -F: '{ print $1 }' /etc/passwd\n"
-#: main.c:807
+#: main.c:838
#, c-format
msgid ""
"Copyright (C) 1989, 1991-%d Free Software Foundation.\n"
@@ -1897,7 +1809,7 @@ msgstr ""
"version ultérieure de votre choix.\n"
"\n"
-#: main.c:815
+#: main.c:846
msgid ""
"This program is distributed in the hope that it will be useful,\n"
"but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
@@ -1912,7 +1824,7 @@ msgstr ""
"General Public License).\n"
"\n"
-#: main.c:821
+#: main.c:852
msgid ""
"You should have received a copy of the GNU General Public License\n"
"along with this program. If not, see http://www.gnu.org/licenses/.\n"
@@ -1921,16 +1833,16 @@ msgstr ""
"(GNU General Public License) avec ce programme. Sinon, consultez\n"
"http://www.gnu.org/licenses/.\n"
-#: main.c:856
+#: main.c:887
msgid "-Ft does not set FS to tab in POSIX awk"
msgstr "-Ft ne définit pas le FS comme étant une tabulation en awk POSIX"
-#: main.c:1090
+#: main.c:1133
#, c-format
msgid "unknown value for field spec: %d\n"
msgstr "valeur inconnue pour la définition de champ : %d\n"
-#: main.c:1171
+#: main.c:1214
#, c-format
msgid ""
"%s: `%s' argument to `-v' not in `var=value' form\n"
@@ -1939,79 +1851,79 @@ msgstr ""
"%s : « %s » l'argument de « -v » ne respecte pas la forme « var=valeur »\n"
"\n"
-#: main.c:1197
+#: main.c:1240
#, c-format
msgid "`%s' is not a legal variable name"
msgstr "« %s » n'est pas un nom de variable valide"
-#: main.c:1200
+#: main.c:1243
#, c-format
msgid "`%s' is not a variable name, looking for file `%s=%s'"
msgstr "« %s » n'est pas un nom de variable, recherche du fichier « %s=%s »"
-#: main.c:1204
+#: main.c:1247
#, c-format
msgid "cannot use gawk builtin `%s' as variable name"
msgstr "impossible d'utiliser le mot clef gawk « %s » comme variable"
-#: main.c:1209
+#: main.c:1252
#, c-format
msgid "cannot use function `%s' as variable name"
msgstr "impossible d'utiliser la fonction « %s » comme variable"
-#: main.c:1262
+#: main.c:1305
msgid "floating point exception"
msgstr "exception du traitement en virgule flottante"
-#: main.c:1269
+#: main.c:1312
msgid "fatal error: internal error"
msgstr "fatal : erreur interne"
-#: main.c:1284
+#: main.c:1327
msgid "fatal error: internal error: segfault"
msgstr "fatal : erreur interne : erreur de segmentation"
-#: main.c:1296
+#: main.c:1339
msgid "fatal error: internal error: stack overflow"
msgstr "fatal : erreur interne : débordement de la pile"
-#: main.c:1346
+#: main.c:1393
#, c-format
msgid "no pre-opened fd %d"
msgstr "aucun descripteur fd %d pré-ouvert"
-#: main.c:1353
+#: main.c:1400
#, c-format
msgid "could not pre-open /dev/null for fd %d"
msgstr "impossible de pré-ouvrir /dev/null pour le descripteud fd %d"
-#: msg.c:63
+#: msg.c:61
#, c-format
msgid "cmd. line:"
msgstr "ligne de commande:"
-#: msg.c:107
+#: msg.c:121
msgid "error: "
msgstr "erreur : "
-#: node.c:406
+#: node.c:436
msgid "backslash at end of string"
msgstr "barre oblique inverse à la fin de la chaîne"
-#: node.c:517
+#: node.c:520
#, c-format
msgid "old awk does not support the `\\%c' escape sequence"
msgstr "l'ancien awk ne dispose pas de la séquence d'échappement « \\%c »"
-#: node.c:568
+#: node.c:571
msgid "POSIX does not allow `\\x' escapes"
msgstr "POSIX n'autorise pas les séquences d'échappement « \\x »"
-#: node.c:574
+#: node.c:577
msgid "no hex digits in `\\x' escape sequence"
msgstr "aucun chiffre hexadécimal dans la séquence d'échappement « \\x » "
-#: node.c:596
+#: node.c:599
#, c-format
msgid ""
"hex escape \\x%.*s of %d characters probably not interpreted the way you "
@@ -2020,12 +1932,12 @@ msgstr ""
"la séquence d'échappement hexa. \\x%.*s de %d caractères ne sera "
"probablement pas interprétée comme vous l'imaginez"
-#: node.c:611
+#: node.c:614
#, c-format
msgid "escape sequence `\\%c' treated as plain `%c'"
msgstr "séquence d'échappement « \\%c » traitée comme un simple « %c »"
-#: node.c:750
+#: node.c:759
msgid ""
"Invalid multibyte data detected. There may be a mismatch between your data "
"and your locale."
@@ -2045,16 +1957,16 @@ msgid "%s %s `%s': could not set close-on-exec: (fcntl F_SETFD: %s)"
msgstr ""
"%s %s « %s »: impossible de positionner close-on-exec: (fcntl F_SETFD: %s)"
-#: profile.c:83
+#: profile.c:69
#, c-format
msgid "could not open `%s' for writing: %s"
msgstr "impossible d'ouvrir « %s » en écriture : %s"
-#: profile.c:85
+#: profile.c:71
msgid "sending profile to standard error"
msgstr "envoi du profil vers la sortie d'erreur standard"
-#: profile.c:203
+#: profile.c:187
#, c-format
msgid ""
"\t# %s block(s)\n"
@@ -2063,7 +1975,7 @@ msgstr ""
"\t# Bloc(s) %s\n"
"\n"
-#: profile.c:208
+#: profile.c:192
#, c-format
msgid ""
"\t# Rule(s)\n"
@@ -2072,17 +1984,22 @@ msgstr ""
"\t# Règle(s)\n"
"\n"
-#: profile.c:279
+#: profile.c:266
#, c-format
msgid "internal error: %s with null vname"
msgstr "erreur interne : %s avec un vname nul"
-#: profile.c:952
+#: profile.c:528
+#, fuzzy
+msgid "internal error: builtin with null fname"
+msgstr "erreur interne : %s avec un vname nul"
+
+#: profile.c:943
#, c-format
msgid "\t# gawk profile, created %s\n"
msgstr "\t# profile gawk, créé %s\n"
-#: profile.c:1331
+#: profile.c:1328
#, c-format
msgid ""
"\n"
@@ -2091,17 +2008,17 @@ msgstr ""
"\n"
"\t# Fonctions, par ordre alphabétique\n"
-#: profile.c:1370
+#: profile.c:1366
#, c-format
msgid "redir2str: unknown redirection type %d"
msgstr "redir2str : type de redirection %d inconnu"
-#: re.c:573
+#: re.c:571
#, c-format
msgid "range of the form `[%c-%c]' is locale dependent"
msgstr "les plages « [%c-%c] » sont dépendantes des paramètres régionaux"
-#: re.c:600
+#: re.c:598
#, c-format
msgid "regexp component `%.*s' should probably be `[%.*s]'"
msgstr ""
@@ -2180,6 +2097,78 @@ msgstr ") ou \\) sans correspondance"
msgid "No previous regular expression"
msgstr "Aucune expression rationnelle précédente"
+#~ msgid "attempt to use function `%s' as an array"
+#~ msgstr "tentative d'utiliser la fonction « %s » comme tableau"
+
+#~ msgid "reference to uninitialized element `%s[\"%.*s\"]'"
+#~ msgstr "référence à un élément non initialisé « %s[\"%.*s\"] »"
+
+#~ msgid "subscript of array `%s' is null string"
+#~ msgstr "l'indice du tableau « %s » est une chaîne vide"
+
+#~ msgid "%s: empty (null)\n"
+#~ msgstr "%s : vide (non défini)\n"
+
+#~ msgid "%s: empty (zero)\n"
+#~ msgstr "%s : vide (vide)\n"
+
+#~ msgid "%s: table_size = %d, array_size = %d\n"
+#~ msgstr "%s : table_size = %d, array_size = %d\n"
+
+#~ msgid "%s: is parameter\n"
+#~ msgstr "%s : est un paramètre\n"
+
+#~ msgid "%s: array_ref to %s\n"
+#~ msgstr "%s : array_ref à %s\n"
+
+#~ msgid "use of non-array as array"
+#~ msgstr "utilisation d'un non tableau comme tableau"
+
+#~ msgid "can't use function name `%s' as variable or array"
+#~ msgstr "impossible d'utiliser la fonction « %s » comme variable ou tableau"
+
+#~ msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
+#~ msgstr ""
+#~ "tentative d'utilisation du tableau « %s[\"%.*s\"] » dans un contexte "
+#~ "scalaire"
+
+#~ msgid "assignment used in conditional context"
+#~ msgstr "affectation utilisée dans un contexte conditionnel"
+
+#~ msgid "statement has no effect"
+#~ msgstr "la déclaration est sans effet"
+
+#~ msgid ""
+#~ "for loop: array `%s' changed size from %ld to %ld during loop execution"
+#~ msgstr "boucle for : la taille du tableau « %s » est passée de %ld à %ld"
+
+#~ msgid "function called indirectly through `%s' does not exist"
+#~ msgstr "la fonction indirectement appelée via « %s » n'existe pas"
+
+#~ msgid "function `%s' not defined"
+#~ msgstr "fonction « %s » non définie"
+
+#~ msgid "non-redirected `getline' invalid inside `%s' rule"
+#~ msgstr "un « getline » non redirigé n'est pas valable dans une règle « %s »"
+
+#~ msgid "error reading input file `%s': %s"
+#~ msgstr "erreur lors de la lecture du fichier en entrée « %s » : %s"
+
+#~ msgid "`nextfile' cannot be called from a `%s' rule"
+#~ msgstr "« nextfile » ne peut pas être appelé depuis une règle « %s »"
+
+#~ msgid "`exit' cannot be called in the current context"
+#~ msgstr "« exit » ne peut pas être appelé dans ce contexte"
+
+#~ msgid "`next' cannot be called from a `%s' rule"
+#~ msgstr "« next » ne peut pas être appelé depuis une règle « %s »"
+
+#~ msgid "Sorry, don't know how to interpret `%s'"
+#~ msgstr "Désolé, je ne sais pas comment interpréter « %s »"
+
+#~ msgid "\t-R file\t\t\t--command=file\n"
+#~ msgstr "\t-R fichier\t\t\t--command=fichier\n"
+
#~ msgid "could not find groups: %s"
#~ msgstr "impossible de trouver les groupes : %s"
diff --git a/po/ga.gmo b/po/ga.gmo
deleted file mode 100644
index 21141c51..00000000
--- a/po/ga.gmo
+++ /dev/null
Binary files differ
diff --git a/po/gawk.pot b/po/gawk.pot
index 7a0ddbc8..9fd02146 100644
--- a/po/gawk.pot
+++ b/po/gawk.pot
@@ -6,9 +6,9 @@
#, fuzzy
msgid ""
msgstr ""
-"Project-Id-Version: gawk 4.0.1\n"
+"Project-Id-Version: gawk 4.0.70\n"
"Report-Msgid-Bugs-To: arnold@skeeve.com\n"
-"POT-Creation-Date: 2012-03-28 22:03+0200\n"
+"POT-Creation-Date: 2012-04-27 10:06+0300\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -17,944 +17,895 @@ msgstr ""
"Content-Type: text/plain; charset=CHARSET\n"
"Content-Transfer-Encoding: 8bit\n"
-#: array.c:140
+#: array.c:266
#, c-format
msgid "from %s"
msgstr ""
-#: array.c:248
+#: array.c:366
msgid "attempt to use a scalar value as array"
msgstr ""
-#: array.c:251
-#, c-format
-msgid "attempt to use function `%s' as an array"
-msgstr ""
-
-#: array.c:254
+#: array.c:368
#, c-format
msgid "attempt to use scalar parameter `%s' as an array"
msgstr ""
-#: array.c:257
+#: array.c:371
#, c-format
msgid "attempt to use scalar `%s' as an array"
msgstr ""
-#: array.c:302 array.c:707 builtin.c:84 builtin.c:1385 builtin.c:1427
-#: builtin.c:1440 builtin.c:1859 builtin.c:1871 eval.c:1135 eval.c:1139
-#: eval.c:1495 eval.c:1812
+#: array.c:418 array.c:584 builtin.c:85 builtin.c:1560 builtin.c:1602
+#: builtin.c:1615 builtin.c:2041 builtin.c:2053 eval.c:1109 eval.c:1113
+#: eval.c:1508
#, c-format
msgid "attempt to use array `%s' in a scalar context"
msgstr ""
-#: array.c:513
-#, c-format
-msgid "reference to uninitialized element `%s[\"%.*s\"]'"
-msgstr ""
-
-#: array.c:519
-#, c-format
-msgid "subscript of array `%s' is null string"
-msgstr ""
-
-#: array.c:723
+#: array.c:591
#, c-format
msgid "delete: index `%s' not in array `%s'"
msgstr ""
-#: array.c:734 eval.c:1865
+#: array.c:605
#, c-format
msgid "attempt to use scalar `%s[\"%.*s\"]' as an array"
msgstr ""
-#: array.c:910
-#, c-format
-msgid "%s: empty (null)\n"
+#: array.c:784
+msgid "adump: first argument not an array"
msgstr ""
-#: array.c:915
-#, c-format
-msgid "%s: empty (zero)\n"
-msgstr ""
-
-#: array.c:919
-#, c-format
-msgid "%s: table_size = %d, array_size = %d\n"
-msgstr ""
-
-#: array.c:954
-#, c-format
-msgid "%s: is parameter\n"
-msgstr ""
-
-#: array.c:958
-#, c-format
-msgid "%s: array_ref to %s\n"
-msgstr ""
-
-#: array.c:963
-msgid "adump: argument not an array"
-msgstr ""
-
-#: array.c:1086
+#: array.c:823
msgid "asort: second argument not an array"
msgstr ""
-#: array.c:1087
+#: array.c:824
msgid "asorti: second argument not an array"
msgstr ""
-#: array.c:1094
+#: array.c:831
msgid "asort: first argument not an array"
msgstr ""
-#: array.c:1095
+#: array.c:832
msgid "asorti: first argument not an array"
msgstr ""
-#: array.c:1102
+#: array.c:839
msgid "asort: cannot use a subarray of first arg for second arg"
msgstr ""
-#: array.c:1103
+#: array.c:840
msgid "asorti: cannot use a subarray of first arg for second arg"
msgstr ""
-#: array.c:1108
+#: array.c:845
msgid "asort: cannot use a subarray of second arg for first arg"
msgstr ""
-#: array.c:1109
+#: array.c:846
msgid "asorti: cannot use a subarray of second arg for first arg"
msgstr ""
-#: array.c:1655
+#: array.c:1314
#, c-format
msgid "`%s' is invalid as a function name"
msgstr ""
-#: array.c:1659
+#: array.c:1318
#, c-format
msgid "sort comparison function `%s' is not defined"
msgstr ""
-#: awkgram.y:249
+#: awkgram.y:223
#, c-format
msgid "%s blocks must have an action part"
msgstr ""
-#: awkgram.y:252
+#: awkgram.y:226
msgid "each rule must have a pattern or an action part"
msgstr ""
-#: awkgram.y:323 awkgram.y:334
+#: awkgram.y:295 awkgram.y:306
msgid "old awk does not support multiple `BEGIN' or `END' rules"
msgstr ""
-#: awkgram.y:371
+#: awkgram.y:343
#, c-format
msgid "`%s' is a built-in function, it cannot be redefined"
msgstr ""
-#: awkgram.y:432
+#: awkgram.y:389
msgid "regexp constant `//' looks like a C++ comment, but is not"
msgstr ""
-#: awkgram.y:436
+#: awkgram.y:393
#, c-format
msgid "regexp constant `/%s/' looks like a C comment, but is not"
msgstr ""
-#: awkgram.y:528
+#: awkgram.y:485
#, c-format
msgid "duplicate case values in switch body: %s"
msgstr ""
-#: awkgram.y:549
+#: awkgram.y:506
msgid "duplicate `default' detected in switch body"
msgstr ""
-#: awkgram.y:809
+#: awkgram.y:766
msgid "`break' is not allowed outside a loop or switch"
msgstr ""
-#: awkgram.y:818
+#: awkgram.y:775
msgid "`continue' is not allowed outside a loop"
msgstr ""
-#: awkgram.y:828
+#: awkgram.y:785
#, c-format
msgid "`next' used in %s action"
msgstr ""
-#: awkgram.y:836
+#: awkgram.y:793
msgid "`nextfile' is a gawk extension"
msgstr ""
-#: awkgram.y:841
+#: awkgram.y:798
#, c-format
msgid "`nextfile' used in %s action"
msgstr ""
-#: awkgram.y:865
+#: awkgram.y:822
msgid "`return' used outside function context"
msgstr ""
-#: awkgram.y:925
+#: awkgram.y:896
msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'"
msgstr ""
-#: awkgram.y:995 awkgram.y:999 awkgram.y:1023
+#: awkgram.y:966 awkgram.y:970 awkgram.y:994
msgid "`delete array' is a gawk extension"
msgstr ""
-#: awkgram.y:1019
+#: awkgram.y:990
msgid "`delete(array)' is a non-portable tawk extension"
msgstr ""
-#: awkgram.y:1135
+#: awkgram.y:1108
msgid "multistage two-way pipelines don't work"
msgstr ""
-#: awkgram.y:1238
+#: awkgram.y:1211
msgid "regular expression on right of assignment"
msgstr ""
-#: awkgram.y:1249
+#: awkgram.y:1222
msgid "regular expression on left of `~' or `!~' operator"
msgstr ""
-#: awkgram.y:1265 awkgram.y:1419
+#: awkgram.y:1238 awkgram.y:1389
msgid "old awk does not support the keyword `in' except after `for'"
msgstr ""
-#: awkgram.y:1275
+#: awkgram.y:1248
msgid "regular expression on right of comparison"
msgstr ""
-#: awkgram.y:1394
+#: awkgram.y:1364
#, c-format
msgid "`getline var' invalid inside `%s' rule"
msgstr ""
-#: awkgram.y:1397 eval.c:2504
+#: awkgram.y:1367
#, c-format
msgid "`getline' invalid inside `%s' rule"
msgstr ""
-#: awkgram.y:1402
+#: awkgram.y:1372
msgid "non-redirected `getline' undefined inside END action"
msgstr ""
-#: awkgram.y:1421
+#: awkgram.y:1391
msgid "old awk does not support multidimensional arrays"
msgstr ""
-#: awkgram.y:1517
+#: awkgram.y:1488
msgid "call of `length' without parentheses is not portable"
msgstr ""
-#: awkgram.y:1580
+#: awkgram.y:1554
msgid "indirect function calls are a gawk extension"
msgstr ""
-#: awkgram.y:1593
+#: awkgram.y:1567
#, c-format
msgid "can not use special variable `%s' for indirect function call"
msgstr ""
-#: awkgram.y:1671
+#: awkgram.y:1645
msgid "invalid subscript expression"
msgstr ""
-#: awkgram.y:1711
-msgid "use of non-array as array"
-msgstr ""
-
-#: awkgram.y:1975 awkgram.y:1995 msg.c:98
+#: awkgram.y:1966 awkgram.y:1986 msg.c:112
msgid "warning: "
msgstr ""
-#: awkgram.y:1993 msg.c:130
+#: awkgram.y:1984 msg.c:144
msgid "fatal: "
msgstr ""
-#: awkgram.y:2043
+#: awkgram.y:2034
msgid "unexpected newline or end of string"
msgstr ""
-#: awkgram.y:2300 awkgram.y:2358 awkgram.y:2542
+#: awkgram.y:2299 awkgram.y:2357 awkgram.y:2545
#, c-format
msgid "can't open source file `%s' for reading (%s)"
msgstr ""
-#: awkgram.y:2301 awkgram.y:2359 builtin.c:122
+#: awkgram.y:2300 awkgram.y:2358 builtin.c:124
msgid "reason unknown"
msgstr ""
-#: awkgram.y:2317
+#: awkgram.y:2316
#, c-format
msgid "already included source file `%s'"
msgstr ""
-#: awkgram.y:2343
+#: awkgram.y:2342
msgid "@include is a gawk extension"
msgstr ""
-#: awkgram.y:2349
+#: awkgram.y:2348
msgid "empty filename after @include"
msgstr ""
-#: awkgram.y:2494
+#: awkgram.y:2497
msgid "empty program text on command line"
msgstr ""
-#: awkgram.y:2609
+#: awkgram.y:2612
#, c-format
msgid "can't read sourcefile `%s' (%s)"
msgstr ""
-#: awkgram.y:2620
+#: awkgram.y:2623
#, c-format
msgid "source file `%s' is empty"
msgstr ""
-#: awkgram.y:2797
+#: awkgram.y:2800
msgid "source file does not end in newline"
msgstr ""
-#: awkgram.y:2900
+#: awkgram.y:2905
msgid "unterminated regexp ends with `\\' at end of file"
msgstr ""
-#: awkgram.y:2924
+#: awkgram.y:2929
#, c-format
msgid "%s: %d: tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr ""
-#: awkgram.y:2928
+#: awkgram.y:2933
#, c-format
msgid "tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr ""
-#: awkgram.y:2935
+#: awkgram.y:2940
msgid "unterminated regexp"
msgstr ""
-#: awkgram.y:2939
+#: awkgram.y:2944
msgid "unterminated regexp at end of file"
msgstr ""
-#: awkgram.y:2998
+#: awkgram.y:3003
msgid "use of `\\ #...' line continuation is not portable"
msgstr ""
-#: awkgram.y:3014
+#: awkgram.y:3019
msgid "backslash not last character on line"
msgstr ""
-#: awkgram.y:3075
+#: awkgram.y:3080
msgid "POSIX does not allow operator `**='"
msgstr ""
-#: awkgram.y:3077
+#: awkgram.y:3082
msgid "old awk does not support operator `**='"
msgstr ""
-#: awkgram.y:3086
+#: awkgram.y:3091
msgid "POSIX does not allow operator `**'"
msgstr ""
-#: awkgram.y:3088
+#: awkgram.y:3093
msgid "old awk does not support operator `**'"
msgstr ""
-#: awkgram.y:3123
+#: awkgram.y:3128
msgid "operator `^=' is not supported in old awk"
msgstr ""
-#: awkgram.y:3131
+#: awkgram.y:3136
msgid "operator `^' is not supported in old awk"
msgstr ""
-#: awkgram.y:3224 awkgram.y:3240
+#: awkgram.y:3229 awkgram.y:3245
msgid "unterminated string"
msgstr ""
-#: awkgram.y:3436
+#: awkgram.y:3466
#, c-format
msgid "invalid char '%c' in expression"
msgstr ""
-#: awkgram.y:3483
+#: awkgram.y:3513
#, c-format
msgid "`%s' is a gawk extension"
msgstr ""
-#: awkgram.y:3488
+#: awkgram.y:3518
#, c-format
msgid "`%s' is a Bell Labs extension"
msgstr ""
-#: awkgram.y:3493
+#: awkgram.y:3523
#, c-format
msgid "POSIX does not allow `%s'"
msgstr ""
-#: awkgram.y:3501
+#: awkgram.y:3531
#, c-format
msgid "`%s' is not supported in old awk"
msgstr ""
-#: awkgram.y:3568
+#: awkgram.y:3598
msgid "`goto' considered harmful!\n"
msgstr ""
-#: awkgram.y:3619
+#: awkgram.y:3632
#, c-format
msgid "%d is invalid as number of arguments for %s"
msgstr ""
-#: awkgram.y:3654
+#: awkgram.y:3667
#, c-format
msgid "%s: string literal as last arg of substitute has no effect"
msgstr ""
-#: awkgram.y:3659
+#: awkgram.y:3672
#, c-format
msgid "%s third parameter is not a changeable object"
msgstr ""
-#: awkgram.y:3732 awkgram.y:3735
+#: awkgram.y:3751 awkgram.y:3754
msgid "match: third argument is a gawk extension"
msgstr ""
-#: awkgram.y:3789 awkgram.y:3792
+#: awkgram.y:3808 awkgram.y:3811
msgid "close: second argument is a gawk extension"
msgstr ""
-#: awkgram.y:3804
+#: awkgram.y:3823
msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore"
msgstr ""
-#: awkgram.y:3819
+#: awkgram.y:3838
msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore"
msgstr ""
-#: awkgram.y:3911
-#, c-format
-msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
-msgstr ""
-
-#: awkgram.y:3953
+#: awkgram.y:3904
#, c-format
msgid "function `%s': parameter `%s' shadows global variable"
msgstr ""
-#: awkgram.y:4111
+#: awkgram.y:3961
#, c-format
msgid "could not open `%s' for writing (%s)"
msgstr ""
-#: awkgram.y:4112
+#: awkgram.y:3962
msgid "sending variable list to standard error"
msgstr ""
-#: awkgram.y:4118
+#: awkgram.y:3970
#, c-format
msgid "%s: close failed (%s)"
msgstr ""
-#: awkgram.y:4170
+#: awkgram.y:3995
msgid "shadow_funcs() called twice!"
msgstr ""
-#: awkgram.y:4176
+#: awkgram.y:4003
msgid "there were shadowed variables."
msgstr ""
-#: awkgram.y:4206
+#: awkgram.y:4074
+#, c-format
+msgid "function name `%s' previously defined"
+msgstr ""
+
+#: awkgram.y:4120
#, c-format
msgid "function `%s': can't use function name as parameter name"
msgstr ""
-#: awkgram.y:4210
+#: awkgram.y:4123
#, c-format
msgid "function `%s': can't use special variable `%s' as a function parameter"
msgstr ""
-#: awkgram.y:4226
+#: awkgram.y:4131
#, c-format
-msgid "function name `%s' previously defined"
+msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
msgstr ""
-#: awkgram.y:4394 awkgram.y:4400
+#: awkgram.y:4210 awkgram.y:4216
#, c-format
msgid "function `%s' called but never defined"
msgstr ""
-#: awkgram.y:4403
+#: awkgram.y:4219
#, c-format
msgid "function `%s' defined but never called directly"
msgstr ""
-#: awkgram.y:4435
+#: awkgram.y:4251
#, c-format
msgid "regexp constant for parameter #%d yields boolean value"
msgstr ""
-#: awkgram.y:4544
+#: awkgram.y:4297
#, c-format
msgid ""
"function `%s' called with space between name and `(',\n"
"or used as a variable or an array"
msgstr ""
-#: awkgram.y:4791 eval.c:2056
+#: awkgram.y:4505
msgid "division by zero attempted"
msgstr ""
-#: awkgram.y:4800 eval.c:2072
+#: awkgram.y:4514
#, c-format
msgid "division by zero attempted in `%%'"
msgstr ""
-#: builtin.c:120
+#: builtin.c:122
#, c-format
msgid "%s to \"%s\" failed (%s)"
msgstr ""
-#: builtin.c:121
+#: builtin.c:123
msgid "standard output"
msgstr ""
-#: builtin.c:135
+#: builtin.c:137
msgid "exp: received non-numeric argument"
msgstr ""
-#: builtin.c:141
+#: builtin.c:143
#, c-format
msgid "exp: argument %g is out of range"
msgstr ""
-#: builtin.c:200
+#: builtin.c:202
#, c-format
msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing"
msgstr ""
-#: builtin.c:203
+#: builtin.c:205
#, c-format
msgid "fflush: cannot flush: file `%s' opened for reading, not writing"
msgstr ""
-#: builtin.c:215
+#: builtin.c:217
#, c-format
msgid "fflush: `%s' is not an open file, pipe or co-process"
msgstr ""
-#: builtin.c:333
+#: builtin.c:335
msgid "index: received non-string first argument"
msgstr ""
-#: builtin.c:335
+#: builtin.c:337
msgid "index: received non-string second argument"
msgstr ""
-#: builtin.c:457
+#: builtin.c:461
msgid "int: received non-numeric argument"
msgstr ""
-#: builtin.c:493
+#: builtin.c:497
msgid "length: received array argument"
msgstr ""
-#: builtin.c:496
+#: builtin.c:500
msgid "`length(array)' is a gawk extension"
msgstr ""
-#: builtin.c:504
+#: builtin.c:508
msgid "length: received non-string argument"
msgstr ""
-#: builtin.c:535
+#: builtin.c:539
msgid "log: received non-numeric argument"
msgstr ""
-#: builtin.c:538
+#: builtin.c:542
#, c-format
msgid "log: received negative argument %g"
msgstr ""
-#: builtin.c:694 builtin.c:699
+#: builtin.c:740 builtin.c:745
msgid "fatal: must use `count$' on all formats or none"
msgstr ""
-#: builtin.c:762
+#: builtin.c:815
#, c-format
msgid "field width is ignored for `%%' specifier"
msgstr ""
-#: builtin.c:764
+#: builtin.c:817
#, c-format
msgid "precision is ignored for `%%' specifier"
msgstr ""
-#: builtin.c:766
+#: builtin.c:819
#, c-format
msgid "field width and precision are ignored for `%%' specifier"
msgstr ""
-#: builtin.c:817
+#: builtin.c:870
msgid "fatal: `$' is not permitted in awk formats"
msgstr ""
-#: builtin.c:826
+#: builtin.c:879
msgid "fatal: arg count with `$' must be > 0"
msgstr ""
-#: builtin.c:830
+#: builtin.c:883
#, c-format
msgid "fatal: arg count %ld greater than total number of supplied arguments"
msgstr ""
-#: builtin.c:834
+#: builtin.c:887
msgid "fatal: `$' not permitted after period in format"
msgstr ""
-#: builtin.c:850
+#: builtin.c:903
msgid "fatal: no `$' supplied for positional field width or precision"
msgstr ""
-#: builtin.c:921
+#: builtin.c:975
msgid "`l' is meaningless in awk formats; ignored"
msgstr ""
-#: builtin.c:925
+#: builtin.c:979
msgid "fatal: `l' is not permitted in POSIX awk formats"
msgstr ""
-#: builtin.c:938
+#: builtin.c:992
msgid "`L' is meaningless in awk formats; ignored"
msgstr ""
-#: builtin.c:942
+#: builtin.c:996
msgid "fatal: `L' is not permitted in POSIX awk formats"
msgstr ""
-#: builtin.c:955
+#: builtin.c:1009
msgid "`h' is meaningless in awk formats; ignored"
msgstr ""
-#: builtin.c:959
+#: builtin.c:1013
msgid "fatal: `h' is not permitted in POSIX awk formats"
msgstr ""
-#: builtin.c:1272
+#: builtin.c:1408
#, c-format
msgid "[s]printf: value %g is out of range for `%%%c' format"
msgstr ""
-#: builtin.c:1332
+#: builtin.c:1506
#, c-format
msgid "ignoring unknown format specifier character `%c': no argument converted"
msgstr ""
-#: builtin.c:1337
+#: builtin.c:1511
msgid "fatal: not enough arguments to satisfy format string"
msgstr ""
-#: builtin.c:1339
+#: builtin.c:1513
msgid "^ ran out for this one"
msgstr ""
-#: builtin.c:1346
+#: builtin.c:1520
msgid "[s]printf: format specifier does not have control letter"
msgstr ""
-#: builtin.c:1349
+#: builtin.c:1523
msgid "too many arguments supplied for format string"
msgstr ""
-#: builtin.c:1423 builtin.c:1434
+#: builtin.c:1598 builtin.c:1609
msgid "printf: no arguments"
msgstr ""
-#: builtin.c:1475
+#: builtin.c:1650
msgid "sqrt: received non-numeric argument"
msgstr ""
-#: builtin.c:1479
+#: builtin.c:1654
#, c-format
msgid "sqrt: called with negative argument %g"
msgstr ""
-#: builtin.c:1503
+#: builtin.c:1685
#, c-format
msgid "substr: length %g is not >= 1"
msgstr ""
-#: builtin.c:1505
+#: builtin.c:1687
#, c-format
msgid "substr: length %g is not >= 0"
msgstr ""
-#: builtin.c:1512
+#: builtin.c:1694
#, c-format
msgid "substr: non-integer length %g will be truncated"
msgstr ""
-#: builtin.c:1517
+#: builtin.c:1699
#, c-format
msgid "substr: length %g too big for string indexing, truncating to %g"
msgstr ""
-#: builtin.c:1529
+#: builtin.c:1711
#, c-format
msgid "substr: start index %g is invalid, using 1"
msgstr ""
-#: builtin.c:1534
+#: builtin.c:1716
#, c-format
msgid "substr: non-integer start index %g will be truncated"
msgstr ""
-#: builtin.c:1559
+#: builtin.c:1741
msgid "substr: source string is zero length"
msgstr ""
-#: builtin.c:1575
+#: builtin.c:1757
#, c-format
msgid "substr: start index %g is past end of string"
msgstr ""
-#: builtin.c:1583
+#: builtin.c:1765
#, c-format
msgid ""
"substr: length %g at start index %g exceeds length of first argument (%lu)"
msgstr ""
-#: builtin.c:1657
+#: builtin.c:1839
msgid "strftime: format value in PROCINFO[\"strftime\"] has numeric type"
msgstr ""
-#: builtin.c:1680
+#: builtin.c:1862
msgid "strftime: received non-numeric second argument"
msgstr ""
-#: builtin.c:1683
+#: builtin.c:1866
msgid "strftime: second argument less than 0 or too big for time_t"
msgstr ""
-#: builtin.c:1690
+#: builtin.c:1873
msgid "strftime: received non-string first argument"
msgstr ""
-#: builtin.c:1696
+#: builtin.c:1880
msgid "strftime: received empty format string"
msgstr ""
-#: builtin.c:1762
+#: builtin.c:1946
msgid "mktime: received non-string argument"
msgstr ""
-#: builtin.c:1779
+#: builtin.c:1963
msgid "mktime: at least one of the values is out of the default range"
msgstr ""
-#: builtin.c:1814
+#: builtin.c:1998
msgid "'system' function not allowed in sandbox mode"
msgstr ""
-#: builtin.c:1819
+#: builtin.c:2003
msgid "system: received non-string argument"
msgstr ""
-#: builtin.c:1874 eval.c:1159 eval.c:1790 eval.c:1803
-#, c-format
-msgid "reference to uninitialized variable `%s'"
-msgstr ""
-
-#: builtin.c:1941
+#: builtin.c:2121
#, c-format
msgid "reference to uninitialized field `$%d'"
msgstr ""
-#: builtin.c:2028
+#: builtin.c:2208
msgid "tolower: received non-string argument"
msgstr ""
-#: builtin.c:2062
+#: builtin.c:2242
msgid "toupper: received non-string argument"
msgstr ""
-#: builtin.c:2098
+#: builtin.c:2278
msgid "atan2: received non-numeric first argument"
msgstr ""
-#: builtin.c:2100
+#: builtin.c:2280
msgid "atan2: received non-numeric second argument"
msgstr ""
-#: builtin.c:2119
+#: builtin.c:2299
msgid "sin: received non-numeric argument"
msgstr ""
-#: builtin.c:2135
+#: builtin.c:2315
msgid "cos: received non-numeric argument"
msgstr ""
-#: builtin.c:2188
+#: builtin.c:2368
msgid "srand: received non-numeric argument"
msgstr ""
-#: builtin.c:2219
+#: builtin.c:2399
msgid "match: third argument is not an array"
msgstr ""
-#: builtin.c:2483
+#: builtin.c:2664
msgid "gensub: third argument of 0 treated as 1"
msgstr ""
-#: builtin.c:2776
+#: builtin.c:2957
msgid "lshift: received non-numeric first argument"
msgstr ""
-#: builtin.c:2778
+#: builtin.c:2959
msgid "lshift: received non-numeric second argument"
msgstr ""
-#: builtin.c:2784
+#: builtin.c:2965
#, c-format
msgid "lshift(%lf, %lf): negative values will give strange results"
msgstr ""
-#: builtin.c:2786
+#: builtin.c:2967
#, c-format
msgid "lshift(%lf, %lf): fractional values will be truncated"
msgstr ""
-#: builtin.c:2788
+#: builtin.c:2969
#, c-format
msgid "lshift(%lf, %lf): too large shift value will give strange results"
msgstr ""
-#: builtin.c:2813
+#: builtin.c:2994
msgid "rshift: received non-numeric first argument"
msgstr ""
-#: builtin.c:2815
+#: builtin.c:2996
msgid "rshift: received non-numeric second argument"
msgstr ""
-#: builtin.c:2821
+#: builtin.c:3002
#, c-format
msgid "rshift(%lf, %lf): negative values will give strange results"
msgstr ""
-#: builtin.c:2823
+#: builtin.c:3004
#, c-format
msgid "rshift(%lf, %lf): fractional values will be truncated"
msgstr ""
-#: builtin.c:2825
+#: builtin.c:3006
#, c-format
msgid "rshift(%lf, %lf): too large shift value will give strange results"
msgstr ""
-#: builtin.c:2850
+#: builtin.c:3031
msgid "and: received non-numeric first argument"
msgstr ""
-#: builtin.c:2852
+#: builtin.c:3033
msgid "and: received non-numeric second argument"
msgstr ""
-#: builtin.c:2858
+#: builtin.c:3039
#, c-format
msgid "and(%lf, %lf): negative values will give strange results"
msgstr ""
-#: builtin.c:2860
+#: builtin.c:3041
#, c-format
msgid "and(%lf, %lf): fractional values will be truncated"
msgstr ""
-#: builtin.c:2885
+#: builtin.c:3066
msgid "or: received non-numeric first argument"
msgstr ""
-#: builtin.c:2887
+#: builtin.c:3068
msgid "or: received non-numeric second argument"
msgstr ""
-#: builtin.c:2893
+#: builtin.c:3074
#, c-format
msgid "or(%lf, %lf): negative values will give strange results"
msgstr ""
-#: builtin.c:2895
+#: builtin.c:3076
#, c-format
msgid "or(%lf, %lf): fractional values will be truncated"
msgstr ""
-#: builtin.c:2923
+#: builtin.c:3102
msgid "xor: received non-numeric first argument"
msgstr ""
-#: builtin.c:2925
+#: builtin.c:3104
msgid "xor: received non-numeric second argument"
msgstr ""
-#: builtin.c:2931
+#: builtin.c:3110
#, c-format
msgid "xor(%lf, %lf): negative values will give strange results"
msgstr ""
-#: builtin.c:2933
+#: builtin.c:3112
#, c-format
msgid "xor(%lf, %lf): fractional values will be truncated"
msgstr ""
-#: builtin.c:2957 builtin.c:2963
+#: builtin.c:3136
msgid "compl: received non-numeric argument"
msgstr ""
-#: builtin.c:2965
+#: builtin.c:3142
#, c-format
msgid "compl(%lf): negative value will give strange results"
msgstr ""
-#: builtin.c:2967
+#: builtin.c:3144
#, c-format
msgid "compl(%lf): fractional value will be truncated"
msgstr ""
-#: builtin.c:3136
+#: builtin.c:3313
#, c-format
msgid "dcgettext: `%s' is not a valid locale category"
msgstr ""
-#: eval.c:412
+#: eval.c:395
#, c-format
msgid "unknown nodetype %d"
msgstr ""
-#: eval.c:423 eval.c:437
+#: eval.c:406 eval.c:420
#, c-format
msgid "unknown opcode %d"
msgstr ""
-#: eval.c:434
+#: eval.c:417
#, c-format
msgid "opcode %s not an operator or keyword"
msgstr ""
-#: eval.c:488
+#: eval.c:472
msgid "buffer overflow in genflags2str"
msgstr ""
-#: eval.c:698
+#: eval.c:675
#, c-format
msgid ""
"\n"
@@ -962,289 +913,235 @@ msgid ""
"\n"
msgstr ""
-#: eval.c:725
+#: eval.c:704
msgid "`IGNORECASE' is a gawk extension"
msgstr ""
-#: eval.c:754
+#: eval.c:736
msgid "`BINMODE' is a gawk extension"
msgstr ""
-#: eval.c:812
+#: eval.c:793
#, c-format
msgid "BINMODE value `%s' is invalid, treated as 3"
msgstr ""
-#: eval.c:902
+#: eval.c:885
#, c-format
msgid "bad `%sFMT' specification `%s'"
msgstr ""
-#: eval.c:980
+#: eval.c:969
msgid "turning off `--lint' due to assignment to `LINT'"
msgstr ""
-#: eval.c:1127 eval.c:1777
+#: eval.c:1132
#, c-format
-msgid "can't use function name `%s' as variable or array"
+msgid "reference to uninitialized argument `%s'"
msgstr ""
-#: eval.c:1158 eval.c:1789 eval.c:1802
+#: eval.c:1133
#, c-format
-msgid "reference to uninitialized argument `%s'"
+msgid "reference to uninitialized variable `%s'"
msgstr ""
-#: eval.c:1177
+#: eval.c:1151
msgid "attempt to field reference from non-numeric value"
msgstr ""
-#: eval.c:1179
+#: eval.c:1153
msgid "attempt to field reference from null string"
msgstr ""
-#: eval.c:1185
+#: eval.c:1161
#, c-format
msgid "attempt to access field %ld"
msgstr ""
-#: eval.c:1194
+#: eval.c:1170
#, c-format
msgid "reference to uninitialized field `$%ld'"
msgstr ""
-#: eval.c:1256
+#: eval.c:1257
#, c-format
msgid "function `%s' called with more arguments than declared"
msgstr ""
-#: eval.c:1437
+#: eval.c:1452
#, c-format
msgid "unwind_stack: unexpected type `%s'"
msgstr ""
-#: eval.c:1532
+#: eval.c:1546
msgid "division by zero attempted in `/='"
msgstr ""
-#: eval.c:1539
+#: eval.c:1553
#, c-format
msgid "division by zero attempted in `%%='"
msgstr ""
-#: eval.c:1876 eval.c:2122
-#, c-format
-msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
-msgstr ""
-
-#: eval.c:1907
-msgid "assignment used in conditional context"
-msgstr ""
-
-#: eval.c:1911
-msgid "statement has no effect"
-msgstr ""
-
-#: eval.c:2343
-#, c-format
-msgid "for loop: array `%s' changed size from %ld to %ld during loop execution"
-msgstr ""
-
-#: eval.c:2458
-#, c-format
-msgid "function called indirectly through `%s' does not exist"
-msgstr ""
-
-#: eval.c:2470
-#, c-format
-msgid "function `%s' not defined"
-msgstr ""
-
-#: eval.c:2511
-#, c-format
-msgid "non-redirected `getline' invalid inside `%s' rule"
-msgstr ""
-
-#: eval.c:2600
-#, c-format
-msgid "error reading input file `%s': %s"
-msgstr ""
-
-#: eval.c:2614
-#, c-format
-msgid "`nextfile' cannot be called from a `%s' rule"
-msgstr ""
-
-#: eval.c:2661
-msgid "`exit' cannot be called in the current context"
-msgstr ""
-
-#: eval.c:2700
-#, c-format
-msgid "`next' cannot be called from a `%s' rule"
-msgstr ""
-
-#: eval.c:2766
-#, c-format
-msgid "Sorry, don't know how to interpret `%s'"
-msgstr ""
-
-#: ext.c:54
+#: ext.c:70
msgid "extensions are not allowed in sandbox mode"
msgstr ""
-#: ext.c:60 ext.c:65
+#: ext.c:73
msgid "`extension' is a gawk extension"
msgstr ""
-#: ext.c:75
+#: ext.c:80
#, c-format
-msgid "fatal: extension: cannot open `%s' (%s)\n"
+msgid "extension: cannot open library `%s' (%s)\n"
msgstr ""
-#: ext.c:84
+#: ext.c:86
#, c-format
msgid ""
-"fatal: extension: library `%s': does not define "
-"`plugin_is_GPL_compatible' (%s)\n"
+"extension: library `%s': does not define `plugin_is_GPL_compatible' (%s)\n"
msgstr ""
-#: ext.c:93
+#: ext.c:90
#, c-format
-msgid "fatal: extension: library `%s': cannot call function `%s' (%s)\n"
+msgid "extension: library `%s': cannot call function `%s' (%s)\n"
msgstr ""
-#: ext.c:127
+#: ext.c:118
msgid "extension: missing function name"
msgstr ""
-#: ext.c:132
+#: ext.c:123
#, c-format
msgid "extension: illegal character `%c' in function name `%s'"
msgstr ""
-#: ext.c:141
+#: ext.c:131
#, c-format
msgid "extension: can't redefine function `%s'"
msgstr ""
-#: ext.c:145
+#: ext.c:135
#, c-format
msgid "extension: function `%s' already defined"
msgstr ""
-#: ext.c:150
+#: ext.c:139
#, c-format
msgid "extension: function name `%s' previously defined"
msgstr ""
-#: ext.c:152
+#: ext.c:141
#, c-format
msgid "extension: can't use gawk built-in `%s' as function name"
msgstr ""
-#: ext.c:156
+#: ext.c:144
#, c-format
msgid "make_builtin: negative argument count for function `%s'"
msgstr ""
-#: ext.c:259
+#: ext.c:206
#, c-format
msgid "function `%s' defined to take no more than %d argument(s)"
msgstr ""
-#: ext.c:262
+#: ext.c:209
#, c-format
msgid "function `%s': missing argument #%d"
msgstr ""
-#: ext.c:279
+#: ext.c:226
#, c-format
msgid "function `%s': argument #%d: attempt to use scalar as an array"
msgstr ""
-#: ext.c:283
+#: ext.c:230
#, c-format
msgid "function `%s': argument #%d: attempt to use array as a scalar"
msgstr ""
-#: ext.c:296
+#: ext.c:244
msgid "Operation Not Supported"
msgstr ""
-#: field.c:328
+#: ext.c:256
+msgid "dynamic loading of library not supported"
+msgstr ""
+
+#: field.c:339
msgid "NF set to negative value"
msgstr ""
-#: field.c:951 field.c:958 field.c:962
+#: field.c:962 field.c:969 field.c:973
msgid "split: fourth argument is a gawk extension"
msgstr ""
-#: field.c:955
+#: field.c:966
msgid "split: fourth argument is not an array"
msgstr ""
-#: field.c:969
+#: field.c:980
msgid "split: second argument is not an array"
msgstr ""
-#: field.c:973
+#: field.c:984
msgid "split: cannot use the same array for second and fourth args"
msgstr ""
-#: field.c:978
+#: field.c:989
msgid "split: cannot use a subarray of second arg for fourth arg"
msgstr ""
-#: field.c:981
+#: field.c:992
msgid "split: cannot use a subarray of fourth arg for second arg"
msgstr ""
-#: field.c:1010
+#: field.c:1021
msgid "split: null string for third arg is a gawk extension"
msgstr ""
-#: field.c:1050
+#: field.c:1061
msgid "patsplit: fourth argument is not an array"
msgstr ""
-#: field.c:1055
+#: field.c:1066
msgid "patsplit: second argument is not an array"
msgstr ""
-#: field.c:1061
+#: field.c:1072
msgid "patsplit: third argument must be non-null"
msgstr ""
-#: field.c:1065
+#: field.c:1076
msgid "patsplit: cannot use the same array for second and fourth args"
msgstr ""
-#: field.c:1070
+#: field.c:1081
msgid "patsplit: cannot use a subarray of second arg for fourth arg"
msgstr ""
-#: field.c:1073
+#: field.c:1084
msgid "patsplit: cannot use a subarray of fourth arg for second arg"
msgstr ""
-#: field.c:1110
+#: field.c:1122
msgid "`FIELDWIDTHS' is a gawk extension"
msgstr ""
-#: field.c:1173
+#: field.c:1186
#, c-format
msgid "invalid FIELDWIDTHS value, near `%s'"
msgstr ""
-#: field.c:1246
+#: field.c:1259
msgid "null string for `FS' is a gawk extension"
msgstr ""
-#: field.c:1250
+#: field.c:1263
msgid "old awk does not support regexps as value of `FS'"
msgstr ""
-#: field.c:1369
+#: field.c:1382
msgid "`FPAT' is a gawk extension"
msgstr ""
@@ -1303,451 +1200,463 @@ msgstr ""
msgid "%s: option '-W %s' requires an argument\n"
msgstr ""
-#: io.c:280
+#: io.c:326
#, c-format
msgid "command line argument `%s' is a directory: skipped"
msgstr ""
-#: io.c:283 io.c:385
+#: io.c:329 io.c:438
#, c-format
msgid "cannot open file `%s' for reading (%s)"
msgstr ""
-#: io.c:501
+#: io.c:568
#, c-format
msgid "close of fd %d (`%s') failed (%s)"
msgstr ""
-#: io.c:578
+#: io.c:645
msgid "redirection not allowed in sandbox mode"
msgstr ""
-#: io.c:612
+#: io.c:679
#, c-format
msgid "expression in `%s' redirection only has numeric value"
msgstr ""
-#: io.c:618
+#: io.c:685
#, c-format
msgid "expression for `%s' redirection has null string value"
msgstr ""
-#: io.c:623
+#: io.c:690
#, c-format
msgid "filename `%s' for `%s' redirection may be result of logical expression"
msgstr ""
-#: io.c:666
+#: io.c:733
#, c-format
msgid "unnecessary mixing of `>' and `>>' for file `%.*s'"
msgstr ""
-#: io.c:719
+#: io.c:786
#, c-format
msgid "can't open pipe `%s' for output (%s)"
msgstr ""
-#: io.c:729
+#: io.c:796
#, c-format
msgid "can't open pipe `%s' for input (%s)"
msgstr ""
-#: io.c:752
+#: io.c:819
#, c-format
msgid "can't open two way pipe `%s' for input/output (%s)"
msgstr ""
-#: io.c:834
+#: io.c:900
#, c-format
msgid "can't redirect from `%s' (%s)"
msgstr ""
-#: io.c:837
+#: io.c:903
#, c-format
msgid "can't redirect to `%s' (%s)"
msgstr ""
-#: io.c:888
+#: io.c:954
msgid ""
"reached system limit for open files: starting to multiplex file descriptors"
msgstr ""
-#: io.c:904
+#: io.c:970
#, c-format
msgid "close of `%s' failed (%s)."
msgstr ""
-#: io.c:912
+#: io.c:978
msgid "too many pipes or input files open"
msgstr ""
-#: io.c:934
+#: io.c:1000
msgid "close: second argument must be `to' or `from'"
msgstr ""
-#: io.c:951
+#: io.c:1017
#, c-format
msgid "close: `%.*s' is not an open file, pipe or co-process"
msgstr ""
-#: io.c:956
+#: io.c:1022
msgid "close of redirection that was never opened"
msgstr ""
-#: io.c:1053
+#: io.c:1120
#, c-format
msgid "close: redirection `%s' not opened with `|&', second argument ignored"
msgstr ""
-#: io.c:1069
+#: io.c:1137
#, c-format
msgid "failure status (%d) on pipe close of `%s' (%s)"
msgstr ""
-#: io.c:1072
+#: io.c:1140
#, c-format
msgid "failure status (%d) on file close of `%s' (%s)"
msgstr ""
-#: io.c:1092
+#: io.c:1160
#, c-format
msgid "no explicit close of socket `%s' provided"
msgstr ""
-#: io.c:1095
+#: io.c:1163
#, c-format
msgid "no explicit close of co-process `%s' provided"
msgstr ""
-#: io.c:1098
+#: io.c:1166
#, c-format
msgid "no explicit close of pipe `%s' provided"
msgstr ""
-#: io.c:1101
+#: io.c:1169
#, c-format
msgid "no explicit close of file `%s' provided"
msgstr ""
-#: io.c:1129 io.c:1184 main.c:794 main.c:831
+#: io.c:1197 io.c:1252 main.c:825 main.c:862
#, c-format
msgid "error writing standard output (%s)"
msgstr ""
-#: io.c:1133 io.c:1189
+#: io.c:1201 io.c:1257
#, c-format
msgid "error writing standard error (%s)"
msgstr ""
-#: io.c:1141
+#: io.c:1209
#, c-format
msgid "pipe flush of `%s' failed (%s)."
msgstr ""
-#: io.c:1144
+#: io.c:1212
#, c-format
msgid "co-process flush of pipe to `%s' failed (%s)."
msgstr ""
-#: io.c:1147
+#: io.c:1215
#, c-format
msgid "file flush of `%s' failed (%s)."
msgstr ""
-#: io.c:1262
+#: io.c:1329
#, c-format
msgid "local port %s invalid in `/inet'"
msgstr ""
-#: io.c:1279
+#: io.c:1347
#, c-format
msgid "remote host and port information (%s, %s) invalid"
msgstr ""
-#: io.c:1431
+#: io.c:1499
#, c-format
msgid "no (known) protocol supplied in special filename `%s'"
msgstr ""
-#: io.c:1445
+#: io.c:1513
#, c-format
msgid "special file name `%s' is incomplete"
msgstr ""
-#: io.c:1462
+#: io.c:1530
msgid "must supply a remote hostname to `/inet'"
msgstr ""
-#: io.c:1480
+#: io.c:1548
msgid "must supply a remote port to `/inet'"
msgstr ""
-#: io.c:1526
+#: io.c:1594
msgid "TCP/IP communications are not supported"
msgstr ""
-#: io.c:1693
+#: io.c:1764
#, c-format
msgid "could not open `%s', mode `%s'"
msgstr ""
-#: io.c:1747
+#: io.c:1814
#, c-format
msgid "close of master pty failed (%s)"
msgstr ""
-#: io.c:1749 io.c:1917 io.c:2074
+#: io.c:1816 io.c:1984 io.c:2145
#, c-format
msgid "close of stdout in child failed (%s)"
msgstr ""
-#: io.c:1752
+#: io.c:1819
#, c-format
msgid "moving slave pty to stdout in child failed (dup: %s)"
msgstr ""
-#: io.c:1754 io.c:1922
+#: io.c:1821 io.c:1989
#, c-format
msgid "close of stdin in child failed (%s)"
msgstr ""
-#: io.c:1757
+#: io.c:1824
#, c-format
msgid "moving slave pty to stdin in child failed (dup: %s)"
msgstr ""
-#: io.c:1759 io.c:1780
+#: io.c:1826 io.c:1847
#, c-format
msgid "close of slave pty failed (%s)"
msgstr ""
-#: io.c:1858 io.c:1920 io.c:2052 io.c:2077
+#: io.c:1925 io.c:1987 io.c:2122 io.c:2148
#, c-format
msgid "moving pipe to stdout in child failed (dup: %s)"
msgstr ""
-#: io.c:1865 io.c:1925
+#: io.c:1932 io.c:1992
#, c-format
msgid "moving pipe to stdin in child failed (dup: %s)"
msgstr ""
-#: io.c:1885 io.c:2067
+#: io.c:1952 io.c:2138
msgid "restoring stdout in parent process failed\n"
msgstr ""
-#: io.c:1893
+#: io.c:1960
msgid "restoring stdin in parent process failed\n"
msgstr ""
-#: io.c:1928 io.c:2079 io.c:2093
+#: io.c:1995 io.c:2150 io.c:2164
#, c-format
msgid "close of pipe failed (%s)"
msgstr ""
-#: io.c:1973
+#: io.c:2040
msgid "`|&' not supported"
msgstr ""
-#: io.c:2039
+#: io.c:2107
#, c-format
msgid "cannot open pipe `%s' (%s)"
msgstr ""
-#: io.c:2087
+#: io.c:2158
#, c-format
msgid "cannot create child process for `%s' (fork: %s)"
msgstr ""
-#: io.c:2520
+#: io.c:2637
#, c-format
msgid "data file `%s' is empty"
msgstr ""
-#: io.c:2561 io.c:2569
+#: io.c:2678 io.c:2686
msgid "could not allocate more input memory"
msgstr ""
-#: io.c:3127
+#: io.c:3236
msgid "multicharacter value of `RS' is a gawk extension"
msgstr ""
-#: io.c:3232
+#: io.c:3326
msgid "IPv6 communication is not supported"
msgstr ""
-#: main.c:366
+#: main.c:355
msgid "`-m[fr]' option irrelevant in gawk"
msgstr ""
-#: main.c:368
+#: main.c:357
msgid "-m option usage: `-m[fr] nnn'"
msgstr ""
-#: main.c:391
+#: main.c:386
msgid "empty argument to `-e/--source' ignored"
msgstr ""
-#: main.c:462
+#: main.c:472
#, c-format
msgid "%s: option `-W %s' unrecognized, ignored\n"
msgstr ""
-#: main.c:515
+#: main.c:518
#, c-format
msgid "%s: option requires an argument -- %c\n"
msgstr ""
-#: main.c:536
+#: main.c:539
msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'"
msgstr ""
-#: main.c:542
+#: main.c:545
msgid "`--posix' overrides `--traditional'"
msgstr ""
-#: main.c:553
+#: main.c:556
msgid "`--posix'/`--traditional' overrides `--non-decimal-data'"
msgstr ""
-#: main.c:557
+#: main.c:560
#, c-format
msgid "running %s setuid root may be a security problem"
msgstr ""
-#: main.c:562
+#: main.c:565
msgid "`--posix' overrides `--binary'"
msgstr ""
-#: main.c:613
+#: main.c:623
#, c-format
msgid "can't set binary mode on stdin (%s)"
msgstr ""
-#: main.c:616
+#: main.c:626
#, c-format
msgid "can't set binary mode on stdout (%s)"
msgstr ""
-#: main.c:618
+#: main.c:628
#, c-format
msgid "can't set binary mode on stderr (%s)"
msgstr ""
-#: main.c:657
+#: main.c:679
msgid "no program text at all!"
msgstr ""
-#: main.c:734
+#: main.c:763
#, c-format
msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n"
msgstr ""
-#: main.c:736
+#: main.c:765
#, c-format
msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n"
msgstr ""
-#: main.c:741
+#: main.c:770
msgid "POSIX options:\t\tGNU long options: (standard)\n"
msgstr ""
-#: main.c:742
+#: main.c:771
msgid "\t-f progfile\t\t--file=progfile\n"
msgstr ""
-#: main.c:743
+#: main.c:772
msgid "\t-F fs\t\t\t--field-separator=fs\n"
msgstr ""
-#: main.c:744
+#: main.c:773
msgid "\t-v var=val\t\t--assign=var=val\n"
msgstr ""
-#: main.c:745
+#: main.c:774
msgid "Short options:\t\tGNU long options: (extensions)\n"
msgstr ""
-#: main.c:746
+#: main.c:775
msgid "\t-b\t\t\t--characters-as-bytes\n"
msgstr ""
-#: main.c:747
+#: main.c:776
msgid "\t-c\t\t\t--traditional\n"
msgstr ""
-#: main.c:748
+#: main.c:777
msgid "\t-C\t\t\t--copyright\n"
msgstr ""
-#: main.c:749
+#: main.c:778
msgid "\t-d[file]\t\t--dump-variables[=file]\n"
msgstr ""
-#: main.c:750
+#: main.c:779
+msgid "\t-D[file]\t\t--debug[=file]\n"
+msgstr ""
+
+#: main.c:780
msgid "\t-e 'program-text'\t--source='program-text'\n"
msgstr ""
-#: main.c:751
+#: main.c:781
msgid "\t-E file\t\t\t--exec=file\n"
msgstr ""
-#: main.c:752
+#: main.c:782
msgid "\t-g\t\t\t--gen-pot\n"
msgstr ""
-#: main.c:753
+#: main.c:783
msgid "\t-h\t\t\t--help\n"
msgstr ""
-#: main.c:754
+#: main.c:784
+msgid "\t-l library\t\t--load=library\n"
+msgstr ""
+
+#: main.c:785
msgid "\t-L [fatal]\t\t--lint[=fatal]\n"
msgstr ""
-#: main.c:755
+#: main.c:786
msgid "\t-n\t\t\t--non-decimal-data\n"
msgstr ""
-#: main.c:756
+#: main.c:787
+msgid "\t-M\t\t\t--bignum\n"
+msgstr ""
+
+#: main.c:788
msgid "\t-N\t\t\t--use-lc-numeric\n"
msgstr ""
-#: main.c:757
+#: main.c:789
+msgid "\t-o[file]\t\t--pretty-print[=file]\n"
+msgstr ""
+
+#: main.c:790
msgid "\t-O\t\t\t--optimize\n"
msgstr ""
-#: main.c:758
+#: main.c:791
msgid "\t-p[file]\t\t--profile[=file]\n"
msgstr ""
-#: main.c:759
+#: main.c:792
msgid "\t-P\t\t\t--posix\n"
msgstr ""
-#: main.c:760
+#: main.c:793
msgid "\t-r\t\t\t--re-interval\n"
msgstr ""
-#: main.c:762
-msgid "\t-R file\t\t\t--command=file\n"
-msgstr ""
-
-#: main.c:763
+#: main.c:794
msgid "\t-S\t\t\t--sandbox\n"
msgstr ""
-#: main.c:764
+#: main.c:795
msgid "\t-t\t\t\t--lint-old\n"
msgstr ""
-#: main.c:765
+#: main.c:796
msgid "\t-V\t\t\t--version\n"
msgstr ""
-#: main.c:767
+#: main.c:798
msgid "\t-W nostalgia\t\t--nostalgia\n"
msgstr ""
-#: main.c:770
+#: main.c:801
msgid "\t-Y\t\t--parsedebug\n"
msgstr ""
@@ -1756,7 +1665,7 @@ msgstr ""
#. for this application. Please add _another line_ with the
#. address for translation bugs.
#. no-wrap
-#: main.c:779
+#: main.c:810
msgid ""
"\n"
"To report bugs, see node `Bugs' in `gawk.info', which is\n"
@@ -1764,21 +1673,21 @@ msgid ""
"\n"
msgstr ""
-#: main.c:783
+#: main.c:814
msgid ""
"gawk is a pattern scanning and processing language.\n"
"By default it reads standard input and writes standard output.\n"
"\n"
msgstr ""
-#: main.c:787
+#: main.c:818
msgid ""
"Examples:\n"
"\tgawk '{ sum += $1 }; END { print sum }' file\n"
"\tgawk -F: '{ print $1 }' /etc/passwd\n"
msgstr ""
-#: main.c:807
+#: main.c:838
#, c-format
msgid ""
"Copyright (C) 1989, 1991-%d Free Software Foundation.\n"
@@ -1790,7 +1699,7 @@ msgid ""
"\n"
msgstr ""
-#: main.c:815
+#: main.c:846
msgid ""
"This program is distributed in the hope that it will be useful,\n"
"but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
@@ -1799,113 +1708,113 @@ msgid ""
"\n"
msgstr ""
-#: main.c:821
+#: main.c:852
msgid ""
"You should have received a copy of the GNU General Public License\n"
"along with this program. If not, see http://www.gnu.org/licenses/.\n"
msgstr ""
-#: main.c:856
+#: main.c:887
msgid "-Ft does not set FS to tab in POSIX awk"
msgstr ""
-#: main.c:1090
+#: main.c:1133
#, c-format
msgid "unknown value for field spec: %d\n"
msgstr ""
-#: main.c:1171
+#: main.c:1214
#, c-format
msgid ""
"%s: `%s' argument to `-v' not in `var=value' form\n"
"\n"
msgstr ""
-#: main.c:1197
+#: main.c:1240
#, c-format
msgid "`%s' is not a legal variable name"
msgstr ""
-#: main.c:1200
+#: main.c:1243
#, c-format
msgid "`%s' is not a variable name, looking for file `%s=%s'"
msgstr ""
-#: main.c:1204
+#: main.c:1247
#, c-format
msgid "cannot use gawk builtin `%s' as variable name"
msgstr ""
-#: main.c:1209
+#: main.c:1252
#, c-format
msgid "cannot use function `%s' as variable name"
msgstr ""
-#: main.c:1262
+#: main.c:1305
msgid "floating point exception"
msgstr ""
-#: main.c:1269
+#: main.c:1312
msgid "fatal error: internal error"
msgstr ""
-#: main.c:1284
+#: main.c:1327
msgid "fatal error: internal error: segfault"
msgstr ""
-#: main.c:1296
+#: main.c:1339
msgid "fatal error: internal error: stack overflow"
msgstr ""
-#: main.c:1346
+#: main.c:1393
#, c-format
msgid "no pre-opened fd %d"
msgstr ""
-#: main.c:1353
+#: main.c:1400
#, c-format
msgid "could not pre-open /dev/null for fd %d"
msgstr ""
-#: msg.c:63
+#: msg.c:61
#, c-format
msgid "cmd. line:"
msgstr ""
-#: msg.c:107
+#: msg.c:121
msgid "error: "
msgstr ""
-#: node.c:406
+#: node.c:436
msgid "backslash at end of string"
msgstr ""
-#: node.c:517
+#: node.c:520
#, c-format
msgid "old awk does not support the `\\%c' escape sequence"
msgstr ""
-#: node.c:568
+#: node.c:571
msgid "POSIX does not allow `\\x' escapes"
msgstr ""
-#: node.c:574
+#: node.c:577
msgid "no hex digits in `\\x' escape sequence"
msgstr ""
-#: node.c:596
+#: node.c:599
#, c-format
msgid ""
"hex escape \\x%.*s of %d characters probably not interpreted the way you "
"expect"
msgstr ""
-#: node.c:611
+#: node.c:614
#, c-format
msgid "escape sequence `\\%c' treated as plain `%c'"
msgstr ""
-#: node.c:750
+#: node.c:759
msgid ""
"Invalid multibyte data detected. There may be a mismatch between your data "
"and your locale."
@@ -1921,57 +1830,61 @@ msgstr ""
msgid "%s %s `%s': could not set close-on-exec: (fcntl F_SETFD: %s)"
msgstr ""
-#: profile.c:83
+#: profile.c:69
#, c-format
msgid "could not open `%s' for writing: %s"
msgstr ""
-#: profile.c:85
+#: profile.c:71
msgid "sending profile to standard error"
msgstr ""
-#: profile.c:203
+#: profile.c:187
#, c-format
msgid ""
"\t# %s block(s)\n"
"\n"
msgstr ""
-#: profile.c:208
+#: profile.c:192
#, c-format
msgid ""
"\t# Rule(s)\n"
"\n"
msgstr ""
-#: profile.c:279
+#: profile.c:266
#, c-format
msgid "internal error: %s with null vname"
msgstr ""
-#: profile.c:952
+#: profile.c:528
+msgid "internal error: builtin with null fname"
+msgstr ""
+
+#: profile.c:943
#, c-format
msgid "\t# gawk profile, created %s\n"
msgstr ""
-#: profile.c:1331
+#: profile.c:1328
#, c-format
msgid ""
"\n"
"\t# Functions, listed alphabetically\n"
msgstr ""
-#: profile.c:1370
+#: profile.c:1366
#, c-format
msgid "redir2str: unknown redirection type %d"
msgstr ""
-#: re.c:573
+#: re.c:571
#, c-format
msgid "range of the form `[%c-%c]' is locale dependent"
msgstr ""
-#: re.c:600
+#: re.c:598
#, c-format
msgid "regexp component `%.*s' should probably be `[%.*s]'"
msgstr ""
diff --git a/po/he.gmo b/po/he.gmo
deleted file mode 100644
index b9cb6d3c..00000000
--- a/po/he.gmo
+++ /dev/null
Binary files differ
diff --git a/po/id.gmo b/po/id.gmo
deleted file mode 100644
index 272d5f8c..00000000
--- a/po/id.gmo
+++ /dev/null
Binary files differ
diff --git a/po/it.gmo b/po/it.gmo
index 05925e49..d7f7432a 100644
--- a/po/it.gmo
+++ b/po/it.gmo
Binary files differ
diff --git a/po/it.po b/po/it.po
index 70f0a81e..799e5917 100644
--- a/po/it.po
+++ b/po/it.po
@@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: gawk 3.1.81\n"
"Report-Msgid-Bugs-To: arnold@skeeve.com\n"
-"POT-Creation-Date: 2012-03-28 22:03+0200\n"
+"POT-Creation-Date: 2012-04-27 10:06+0300\n"
"PO-Revision-Date: 2011-03-19 16:52+0100\n"
"Last-Translator: Antonio Colombo <azc100@gmail.com>\n"
"Language-Team: Italian <it@li.org>\n"
@@ -15,513 +15,470 @@ msgstr ""
"Content-Type: text/plain; charset=ISO-8859-1\n"
"Content-Transfer-Encoding: 8-bit\n"
-#: array.c:140
+#: array.c:266
#, c-format
msgid "from %s"
msgstr "da %s"
-#: array.c:248
+#: array.c:366
msgid "attempt to use a scalar value as array"
msgstr "tentativo di usare valore scalare come vettore"
-#: array.c:251
-#, c-format
-msgid "attempt to use function `%s' as an array"
-msgstr "tentativo di usare funzione '%s' come vettore"
-
-#: array.c:254
+#: array.c:368
#, c-format
msgid "attempt to use scalar parameter `%s' as an array"
msgstr "tentativo di usare il parametro scalare `%s' come un vettore"
-#: array.c:257
+#: array.c:371
#, c-format
msgid "attempt to use scalar `%s' as an array"
msgstr "tentativo di usare scalare '%s' come vettore"
-#: array.c:302 array.c:707 builtin.c:84 builtin.c:1385 builtin.c:1427
-#: builtin.c:1440 builtin.c:1859 builtin.c:1871 eval.c:1135 eval.c:1139
-#: eval.c:1495 eval.c:1812
+#: array.c:418 array.c:584 builtin.c:85 builtin.c:1560 builtin.c:1602
+#: builtin.c:1615 builtin.c:2041 builtin.c:2053 eval.c:1109 eval.c:1113
+#: eval.c:1508
#, c-format
msgid "attempt to use array `%s' in a scalar context"
msgstr "tentativo di usare vettore `%s' in un contesto scalare"
-#: array.c:513
-#, c-format
-msgid "reference to uninitialized element `%s[\"%.*s\"]'"
-msgstr "riferimento a elemento non inizializzato `%s[\"%.*s\"]'"
-
-#: array.c:519
-#, c-format
-msgid "subscript of array `%s' is null string"
-msgstr "l'indice del vettore '%s' è una stringa nulla"
-
-#: array.c:723
+#: array.c:591
#, c-format
msgid "delete: index `%s' not in array `%s'"
msgstr "delete: indice `%s' non presente nel vettore `%s'"
-#: array.c:734 eval.c:1865
+#: array.c:605
#, c-format
msgid "attempt to use scalar `%s[\"%.*s\"]' as an array"
msgstr "tentativo di usare scalare`%s[\"%.*s\"]' come vettore"
-#: array.c:910
-#, c-format
-msgid "%s: empty (null)\n"
-msgstr "%s: vuoto (nullo)\n"
-
-#: array.c:915
-#, c-format
-msgid "%s: empty (zero)\n"
-msgstr "%s: vuoto (zero)\n"
-
-#: array.c:919
-#, c-format
-msgid "%s: table_size = %d, array_size = %d\n"
-msgstr "%s: dimensione_tabella = %d, dimensione_vettore = %d\n"
-
-#: array.c:954
-#, c-format
-msgid "%s: is parameter\n"
-msgstr "%s: è parametro\n"
-
-#: array.c:958
-#, c-format
-msgid "%s: array_ref to %s\n"
-msgstr "%s: riferimento_vettoriale a %s\n"
-
-#: array.c:963
-msgid "adump: argument not an array"
+#: array.c:784
+#, fuzzy
+msgid "adump: first argument not an array"
msgstr "adump: l'argomento non è un vettore"
-#: array.c:1086
+#: array.c:823
msgid "asort: second argument not an array"
msgstr "asort: il secondo argomento non è un vettore"
-#: array.c:1087
+#: array.c:824
msgid "asorti: second argument not an array"
msgstr "asorti: il secondo argomento non è un vettore"
-#: array.c:1094
+#: array.c:831
msgid "asort: first argument not an array"
msgstr "asort: il primo argomento non è un vettore"
-#: array.c:1095
+#: array.c:832
msgid "asorti: first argument not an array"
msgstr "asorti: il primo argomento non è un vettore"
-#: array.c:1102
+#: array.c:839
#, fuzzy
msgid "asort: cannot use a subarray of first arg for second arg"
msgstr ""
"patsplit: non si può usare lo stesso vettore come secondo e quarto argomento"
-#: array.c:1103
+#: array.c:840
#, fuzzy
msgid "asorti: cannot use a subarray of first arg for second arg"
msgstr ""
"patsplit: non si può usare lo stesso vettore come secondo e quarto argomento"
-#: array.c:1108
+#: array.c:845
#, fuzzy
msgid "asort: cannot use a subarray of second arg for first arg"
msgstr ""
"split: non si può usare lo stesso vettore come secondo e quarto argomento"
-#: array.c:1109
+#: array.c:846
#, fuzzy
msgid "asorti: cannot use a subarray of second arg for first arg"
msgstr ""
"split: non si può usare lo stesso vettore come secondo e quarto argomento"
-#: array.c:1655
+#: array.c:1314
#, fuzzy, c-format
msgid "`%s' is invalid as a function name"
msgstr "estensione: manca nome di funzione"
-#: array.c:1659
+#: array.c:1318
#, fuzzy, c-format
msgid "sort comparison function `%s' is not defined"
msgstr "funzione `%s' non definita"
-#: awkgram.y:249
+#: awkgram.y:223
#, c-format
msgid "%s blocks must have an action part"
msgstr "blocchi %s richiedono una 'azione'"
-#: awkgram.y:252
+#: awkgram.y:226
msgid "each rule must have a pattern or an action part"
msgstr "ogni regola deve avere una parte 'espressione' o una parte 'azione'"
-#: awkgram.y:323 awkgram.y:334
+#: awkgram.y:295 awkgram.y:306
msgid "old awk does not support multiple `BEGIN' or `END' rules"
msgstr "il vecchio awk non supporta più di una regola `BEGIN' o `END'"
-#: awkgram.y:371
+#: awkgram.y:343
#, c-format
msgid "`%s' is a built-in function, it cannot be redefined"
msgstr "`%s' è una funzione interna, non si può ridefinire"
-#: awkgram.y:432
+#: awkgram.y:389
msgid "regexp constant `//' looks like a C++ comment, but is not"
msgstr "espressione regolare costante `//' sembra un commento C++, ma non lo è"
-#: awkgram.y:436
+#: awkgram.y:393
#, c-format
msgid "regexp constant `/%s/' looks like a C comment, but is not"
msgstr "espressione regolare costante `/%s/' sembra un commento C, ma non lo è"
-#: awkgram.y:528
+#: awkgram.y:485
#, c-format
msgid "duplicate case values in switch body: %s"
msgstr "valori di 'case' doppi all'interno di uno 'switch': %s"
-#: awkgram.y:549
+#: awkgram.y:506
msgid "duplicate `default' detected in switch body"
msgstr "valori di default doppi all'interno di uno 'switch'"
-#: awkgram.y:809
+#: awkgram.y:766
msgid "`break' is not allowed outside a loop or switch"
msgstr "`break' non permesso fuori da un ciclo o da uno 'switch'"
-#: awkgram.y:818
+#: awkgram.y:775
msgid "`continue' is not allowed outside a loop"
msgstr "`continue' non permesso fuori da un un ciclo"
-#: awkgram.y:828
+#: awkgram.y:785
#, c-format
msgid "`next' used in %s action"
msgstr "`next' usato in 'azione' %s"
-#: awkgram.y:836
+#: awkgram.y:793
msgid "`nextfile' is a gawk extension"
msgstr "`nextfile' è un'estensione gawk"
-#: awkgram.y:841
+#: awkgram.y:798
#, c-format
msgid "`nextfile' used in %s action"
msgstr "`nextfile' usato in 'azione' %s"
-#: awkgram.y:865
+#: awkgram.y:822
msgid "`return' used outside function context"
msgstr "`return' usato fuori da una funzione"
-#: awkgram.y:925
+#: awkgram.y:896
msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'"
msgstr "`print' da solo in BEGIN o END dovrebbe forse essere `print \"\"'"
-#: awkgram.y:995 awkgram.y:999 awkgram.y:1023
+#: awkgram.y:966 awkgram.y:970 awkgram.y:994
msgid "`delete array' is a gawk extension"
msgstr "`delete array' è un'estensione gawk"
-#: awkgram.y:1019
+#: awkgram.y:990
msgid "`delete(array)' is a non-portable tawk extension"
msgstr "`delete(array)' è un'estensione tawk non-portabile"
-#: awkgram.y:1135
+#: awkgram.y:1108
msgid "multistage two-way pipelines don't work"
msgstr "'pipeline' multistadio bidirezionali non funzionano"
-#: awkgram.y:1238
+#: awkgram.y:1211
msgid "regular expression on right of assignment"
msgstr "espressione regolare usata per assegnare un valore"
-#: awkgram.y:1249
+#: awkgram.y:1222
msgid "regular expression on left of `~' or `!~' operator"
msgstr "espressione regolare prima di operatore `~' o `!~'"
-#: awkgram.y:1265 awkgram.y:1419
+#: awkgram.y:1238 awkgram.y:1389
msgid "old awk does not support the keyword `in' except after `for'"
msgstr "il vecchio awk non supporta la parola-chiave `in' se non dopo `for'"
-#: awkgram.y:1275
+#: awkgram.y:1248
msgid "regular expression on right of comparison"
msgstr "espressione regolare a destra in un confronto"
-#: awkgram.y:1394
+#: awkgram.y:1364
#, c-format
msgid "`getline var' invalid inside `%s' rule"
msgstr "`getline var' invalida all'interno della regola `%s'"
-#: awkgram.y:1397 eval.c:2504
+#: awkgram.y:1367
#, c-format
msgid "`getline' invalid inside `%s' rule"
msgstr "`getline' invalida all'interno della regola `%s'"
-#: awkgram.y:1402
+#: awkgram.y:1372
msgid "non-redirected `getline' undefined inside END action"
msgstr "`getline' non re-diretta indefinita dentro 'azione' END"
-#: awkgram.y:1421
+#: awkgram.y:1391
msgid "old awk does not support multidimensional arrays"
msgstr "il vecchio awk non supporta vettori multidimensionali"
-#: awkgram.y:1517
+#: awkgram.y:1488
msgid "call of `length' without parentheses is not portable"
msgstr "chiamata a `length' senza parentesi non portabile"
-#: awkgram.y:1580
+#: awkgram.y:1554
msgid "indirect function calls are a gawk extension"
msgstr "chiamate a funzione indirette sono un'estensione gawk"
-#: awkgram.y:1593
+#: awkgram.y:1567
#, c-format
msgid "can not use special variable `%s' for indirect function call"
msgstr ""
"non posso usare la variabile speciale `%s' come parametro indiretto di "
"funzione "
-#: awkgram.y:1671
+#: awkgram.y:1645
msgid "invalid subscript expression"
msgstr "espressione indice invalida"
-#: awkgram.y:1711
-msgid "use of non-array as array"
-msgstr "uso di non-vettore come vettore"
-
-#: awkgram.y:1975 awkgram.y:1995 msg.c:98
+#: awkgram.y:1966 awkgram.y:1986 msg.c:112
msgid "warning: "
msgstr "attenzione: "
-#: awkgram.y:1993 msg.c:130
+#: awkgram.y:1984 msg.c:144
msgid "fatal: "
msgstr "fatale: "
-#: awkgram.y:2043
+#: awkgram.y:2034
msgid "unexpected newline or end of string"
msgstr "carattere 'a capo' o fine stringa inaspettati"
-#: awkgram.y:2300 awkgram.y:2358 awkgram.y:2542
+#: awkgram.y:2299 awkgram.y:2357 awkgram.y:2545
#, c-format
msgid "can't open source file `%s' for reading (%s)"
msgstr "non riesco ad aprire file sorgente `%s' in lettura (%s)"
-#: awkgram.y:2301 awkgram.y:2359 builtin.c:122
+#: awkgram.y:2300 awkgram.y:2358 builtin.c:124
msgid "reason unknown"
msgstr "ragione indeterminata"
-#: awkgram.y:2317
+#: awkgram.y:2316
#, c-format
msgid "already included source file `%s'"
msgstr "file sorgente `%s' già incluso"
-#: awkgram.y:2343
+#: awkgram.y:2342
msgid "@include is a gawk extension"
msgstr "@include è un'estensione gawk"
-#: awkgram.y:2349
+#: awkgram.y:2348
msgid "empty filename after @include"
msgstr "nome-file mancante dopo @include"
-#: awkgram.y:2494
+#: awkgram.y:2497
msgid "empty program text on command line"
msgstr "programma nullo sulla linea comandi"
-#: awkgram.y:2609
+#: awkgram.y:2612
#, c-format
msgid "can't read sourcefile `%s' (%s)"
msgstr "non riesco a leggere file sorgente `%s' (%s)"
-#: awkgram.y:2620
+#: awkgram.y:2623
#, c-format
msgid "source file `%s' is empty"
msgstr "file sorgente `%s' vuoto"
-#: awkgram.y:2797
+#: awkgram.y:2800
msgid "source file does not end in newline"
msgstr "file sorgente non termina con carattere 'a capo'"
-#: awkgram.y:2900
+#: awkgram.y:2905
msgid "unterminated regexp ends with `\\' at end of file"
msgstr "espressione regolare non completata termina con `\\' a fine file"
-#: awkgram.y:2924
+#: awkgram.y:2929
#, c-format
msgid "%s: %d: tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr ""
"%s: %d: modificatore di espressione regolare tawk `/.../%c' non valido in "
"gawk"
-#: awkgram.y:2928
+#: awkgram.y:2933
#, c-format
msgid "tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr "modificatore di espressione regolare tawk `/.../%c' non valido in gawk"
-#: awkgram.y:2935
+#: awkgram.y:2940
msgid "unterminated regexp"
msgstr "espressione regolare non completata"
-#: awkgram.y:2939
+#: awkgram.y:2944
msgid "unterminated regexp at end of file"
msgstr "espressione regolare non completata a fine file"
-#: awkgram.y:2998
+#: awkgram.y:3003
msgid "use of `\\ #...' line continuation is not portable"
msgstr "uso di `\\ #...' continuazione linea non portabile"
-#: awkgram.y:3014
+#: awkgram.y:3019
msgid "backslash not last character on line"
msgstr "'\\' non è l'ultimo carattere della linea"
-#: awkgram.y:3075
+#: awkgram.y:3080
msgid "POSIX does not allow operator `**='"
msgstr "POSIX non permette l'operatore `**='"
-#: awkgram.y:3077
+#: awkgram.y:3082
msgid "old awk does not support operator `**='"
msgstr "il vecchio awk non supporta l'operatore `**='"
-#: awkgram.y:3086
+#: awkgram.y:3091
msgid "POSIX does not allow operator `**'"
msgstr "POSIX non permette l'operatore `**'"
-#: awkgram.y:3088
+#: awkgram.y:3093
msgid "old awk does not support operator `**'"
msgstr "il vecchio awk non supporta l'operatore `**'"
-#: awkgram.y:3123
+#: awkgram.y:3128
msgid "operator `^=' is not supported in old awk"
msgstr "l'operatore `^=' non è supportato nel vecchio awk"
-#: awkgram.y:3131
+#: awkgram.y:3136
msgid "operator `^' is not supported in old awk"
msgstr "l'operatore `^' non è supportato nel vecchio awk"
-#: awkgram.y:3224 awkgram.y:3240
+#: awkgram.y:3229 awkgram.y:3245
msgid "unterminated string"
msgstr "stringa non terminata"
-#: awkgram.y:3436
+#: awkgram.y:3466
#, c-format
msgid "invalid char '%c' in expression"
msgstr "carattere '%c' non valido in un'espressione"
-#: awkgram.y:3483
+#: awkgram.y:3513
#, c-format
msgid "`%s' is a gawk extension"
msgstr "`%s' è un'estensione gawk"
-#: awkgram.y:3488
+#: awkgram.y:3518
#, c-format
msgid "`%s' is a Bell Labs extension"
msgstr "`%s' è un'estensione Bell Labs"
-#: awkgram.y:3493
+#: awkgram.y:3523
#, c-format
msgid "POSIX does not allow `%s'"
msgstr "POSIX non permette `%s'"
-#: awkgram.y:3501
+#: awkgram.y:3531
#, c-format
msgid "`%s' is not supported in old awk"
msgstr "`%s' non è supportato nel vecchio awk"
-#: awkgram.y:3568
+#: awkgram.y:3598
msgid "`goto' considered harmful!\n"
msgstr "`goto' considerato pericoloso!\n"
-#: awkgram.y:3619
+#: awkgram.y:3632
#, c-format
msgid "%d is invalid as number of arguments for %s"
msgstr "%d non valido come numero di argomenti per %s"
-#: awkgram.y:3654
+#: awkgram.y:3667
#, c-format
msgid "%s: string literal as last arg of substitute has no effect"
msgstr "%s: una stringa come ultimo argomento di 'substitute' non ha effetto"
-#: awkgram.y:3659
+#: awkgram.y:3672
#, c-format
msgid "%s third parameter is not a changeable object"
msgstr "il terzo parametro di '%s' non è un oggetto modificabile"
-#: awkgram.y:3732 awkgram.y:3735
+#: awkgram.y:3751 awkgram.y:3754
msgid "match: third argument is a gawk extension"
msgstr "match: il terzo argomento è un'estensione gawk"
-#: awkgram.y:3789 awkgram.y:3792
+#: awkgram.y:3808 awkgram.y:3811
msgid "close: second argument is a gawk extension"
msgstr "close: il secondo argomento è un'estensione gawk"
-#: awkgram.y:3804
+#: awkgram.y:3823
msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore"
msgstr ""
"uso scorretto di dcgettext(_\"...\"): togliere il carattere '_' iniziale"
-#: awkgram.y:3819
+#: awkgram.y:3838
msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore"
msgstr ""
"uso scorretto di dcngettext(_\"...\"): togliere il carattere '_' iniziale"
-#: awkgram.y:3911
-#, c-format
-msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
-msgstr "funzione `%s': parametro #%d, `%s', duplica parametro #%d"
-
-#: awkgram.y:3953
+#: awkgram.y:3904
#, c-format
msgid "function `%s': parameter `%s' shadows global variable"
msgstr "funzione `%s': parametro `%s' nasconde variabile globale"
-#: awkgram.y:4111
+#: awkgram.y:3961
#, c-format
msgid "could not open `%s' for writing (%s)"
msgstr "non riesco ad aprire `%s' in scrittura (%s)"
-#: awkgram.y:4112
+#: awkgram.y:3962
#, fuzzy
msgid "sending variable list to standard error"
msgstr "mando profilo a 'standard error'"
-#: awkgram.y:4118
+#: awkgram.y:3970
#, c-format
msgid "%s: close failed (%s)"
msgstr "%s: 'close' fallita (%s)"
-#: awkgram.y:4170
+#: awkgram.y:3995
msgid "shadow_funcs() called twice!"
msgstr "shadow_funcs() chiamata due volte!"
-#: awkgram.y:4176
+#: awkgram.y:4003
msgid "there were shadowed variables."
msgstr "c'erano variabili nascoste."
-#: awkgram.y:4206
+#: awkgram.y:4074
+#, c-format
+msgid "function name `%s' previously defined"
+msgstr "funzione di nome `%s' definita in precedenza"
+
+#: awkgram.y:4120
#, c-format
msgid "function `%s': can't use function name as parameter name"
msgstr "funzione `%s': non posso usare nome della funzione come nome parametro"
-#: awkgram.y:4210
+#: awkgram.y:4123
#, c-format
msgid "function `%s': can't use special variable `%s' as a function parameter"
msgstr ""
"funzione `%s': non posso usare la variabile speciale `%s' come parametro di "
"funzione"
-#: awkgram.y:4226
+#: awkgram.y:4131
#, c-format
-msgid "function name `%s' previously defined"
-msgstr "funzione di nome `%s' definita in precedenza"
+msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
+msgstr "funzione `%s': parametro #%d, `%s', duplica parametro #%d"
-#: awkgram.y:4394 awkgram.y:4400
+#: awkgram.y:4210 awkgram.y:4216
#, c-format
msgid "function `%s' called but never defined"
msgstr "funzione `%s' chiamata ma mai definita"
-#: awkgram.y:4403
+#: awkgram.y:4219
#, c-format
msgid "function `%s' defined but never called directly"
msgstr "funzione `%s' definita ma mai chiamata direttamente"
-#: awkgram.y:4435
+#: awkgram.y:4251
#, c-format
msgid "regexp constant for parameter #%d yields boolean value"
msgstr ""
"espressione regolare di valore costante per parametro #%d genera valore "
"booleano"
-#: awkgram.y:4544
+#: awkgram.y:4297
#, c-format
msgid ""
"function `%s' called with space between name and `(',\n"
@@ -530,227 +487,227 @@ msgstr ""
"funzione `%s' chiamata con spazio tra il nome e `(',\n"
"o usata come variabile o vettore"
-#: awkgram.y:4791 eval.c:2056
+#: awkgram.y:4505
msgid "division by zero attempted"
msgstr "tentativo di dividere per zero"
-#: awkgram.y:4800 eval.c:2072
+#: awkgram.y:4514
#, c-format
msgid "division by zero attempted in `%%'"
msgstr "tentativo di dividere per zero in `%%'"
-#: builtin.c:120
+#: builtin.c:122
#, c-format
msgid "%s to \"%s\" failed (%s)"
msgstr "%s a \"%s\" fallita (%s)"
-#: builtin.c:121
+#: builtin.c:123
msgid "standard output"
msgstr "standard output"
-#: builtin.c:135
+#: builtin.c:137
msgid "exp: received non-numeric argument"
msgstr "exp: argomento non numerico"
-#: builtin.c:141
+#: builtin.c:143
#, c-format
msgid "exp: argument %g is out of range"
msgstr "exp: argomento %g non accettabile"
-#: builtin.c:200
+#: builtin.c:202
#, c-format
msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing"
msgstr ""
"fflush: non posso scaricare: 'pipe' `%s' aperta in lettura, non in scrittura"
-#: builtin.c:203
+#: builtin.c:205
#, c-format
msgid "fflush: cannot flush: file `%s' opened for reading, not writing"
msgstr ""
"fflush: non posso scaricare: file `%s' aperto in lettura, non in scrittura"
-#: builtin.c:215
+#: builtin.c:217
#, c-format
msgid "fflush: `%s' is not an open file, pipe or co-process"
msgstr "fflush: `%s' non è un file aperto, una 'pipe' o un co-processo"
-#: builtin.c:333
+#: builtin.c:335
msgid "index: received non-string first argument"
msgstr "index: il primo argomento non è una stringa"
-#: builtin.c:335
+#: builtin.c:337
msgid "index: received non-string second argument"
msgstr "index: il secondo argomento non è una stringa"
-#: builtin.c:457
+#: builtin.c:461
msgid "int: received non-numeric argument"
msgstr "int: argomento non numerico"
-#: builtin.c:493
+#: builtin.c:497
msgid "length: received array argument"
msgstr "length: l'argomento fornito è un vettore"
-#: builtin.c:496
+#: builtin.c:500
msgid "`length(array)' is a gawk extension"
msgstr "`length(array)' è un'estensione gawk"
-#: builtin.c:504
+#: builtin.c:508
msgid "length: received non-string argument"
msgstr "length: l'argomento non è una stringa"
-#: builtin.c:535
+#: builtin.c:539
msgid "log: received non-numeric argument"
msgstr "log: argomento non numerico"
-#: builtin.c:538
+#: builtin.c:542
#, c-format
msgid "log: received negative argument %g"
msgstr "log: argomento negativo %g"
-#: builtin.c:694 builtin.c:699
+#: builtin.c:740 builtin.c:745
msgid "fatal: must use `count$' on all formats or none"
msgstr ""
-#: builtin.c:762
+#: builtin.c:815
#, c-format
msgid "field width is ignored for `%%' specifier"
msgstr ""
-#: builtin.c:764
+#: builtin.c:817
#, c-format
msgid "precision is ignored for `%%' specifier"
msgstr ""
-#: builtin.c:766
+#: builtin.c:819
#, c-format
msgid "field width and precision are ignored for `%%' specifier"
msgstr ""
-#: builtin.c:817
+#: builtin.c:870
#, fuzzy
msgid "fatal: `$' is not permitted in awk formats"
msgstr "l'operatore `^' non è supportato nel vecchio awk"
-#: builtin.c:826
+#: builtin.c:879
msgid "fatal: arg count with `$' must be > 0"
msgstr ""
-#: builtin.c:830
+#: builtin.c:883
#, c-format
msgid "fatal: arg count %ld greater than total number of supplied arguments"
msgstr ""
-#: builtin.c:834
+#: builtin.c:887
msgid "fatal: `$' not permitted after period in format"
msgstr ""
-#: builtin.c:850
+#: builtin.c:903
msgid "fatal: no `$' supplied for positional field width or precision"
msgstr ""
-#: builtin.c:921
+#: builtin.c:975
msgid "`l' is meaningless in awk formats; ignored"
msgstr ""
-#: builtin.c:925
+#: builtin.c:979
msgid "fatal: `l' is not permitted in POSIX awk formats"
msgstr ""
-#: builtin.c:938
+#: builtin.c:992
msgid "`L' is meaningless in awk formats; ignored"
msgstr ""
-#: builtin.c:942
+#: builtin.c:996
msgid "fatal: `L' is not permitted in POSIX awk formats"
msgstr ""
-#: builtin.c:955
+#: builtin.c:1009
msgid "`h' is meaningless in awk formats; ignored"
msgstr ""
-#: builtin.c:959
+#: builtin.c:1013
msgid "fatal: `h' is not permitted in POSIX awk formats"
msgstr ""
-#: builtin.c:1272
+#: builtin.c:1408
#, c-format
msgid "[s]printf: value %g is out of range for `%%%c' format"
msgstr ""
-#: builtin.c:1332
+#: builtin.c:1506
#, c-format
msgid "ignoring unknown format specifier character `%c': no argument converted"
msgstr ""
-#: builtin.c:1337
+#: builtin.c:1511
msgid "fatal: not enough arguments to satisfy format string"
msgstr ""
-#: builtin.c:1339
+#: builtin.c:1513
msgid "^ ran out for this one"
msgstr ""
-#: builtin.c:1346
+#: builtin.c:1520
msgid "[s]printf: format specifier does not have control letter"
msgstr ""
-#: builtin.c:1349
+#: builtin.c:1523
msgid "too many arguments supplied for format string"
msgstr ""
-#: builtin.c:1423 builtin.c:1434
+#: builtin.c:1598 builtin.c:1609
msgid "printf: no arguments"
msgstr "printf: manca argomento"
-#: builtin.c:1475
+#: builtin.c:1650
msgid "sqrt: received non-numeric argument"
msgstr "sqrt: argomento non numerico"
-#: builtin.c:1479
+#: builtin.c:1654
#, c-format
msgid "sqrt: called with negative argument %g"
msgstr "sqrt: chiamata con argomento negativo %g"
-#: builtin.c:1503
+#: builtin.c:1685
#, c-format
msgid "substr: length %g is not >= 1"
msgstr "substr: lunghezza %g non >= 1"
-#: builtin.c:1505
+#: builtin.c:1687
#, c-format
msgid "substr: length %g is not >= 0"
msgstr "substr: lunghezza %g non >= 0"
-#: builtin.c:1512
+#: builtin.c:1694
#, c-format
msgid "substr: non-integer length %g will be truncated"
msgstr "substr: lunghezza non intera %g: sarà troncata"
-#: builtin.c:1517
+#: builtin.c:1699
#, c-format
msgid "substr: length %g too big for string indexing, truncating to %g"
msgstr "substr: lunghezza %g troppo elevata per indice stringa, tronco a %g"
-#: builtin.c:1529
+#: builtin.c:1711
#, c-format
msgid "substr: start index %g is invalid, using 1"
msgstr "substr: indice di partenza %g non valido, uso 1"
-#: builtin.c:1534
+#: builtin.c:1716
#, c-format
msgid "substr: non-integer start index %g will be truncated"
msgstr "substr: indice di partenza non intero %g: sarà troncato"
-#: builtin.c:1559
+#: builtin.c:1741
msgid "substr: source string is zero length"
msgstr "substr: stringa di partenza lunga zero"
-#: builtin.c:1575
+#: builtin.c:1757
#, c-format
msgid "substr: start index %g is past end of string"
msgstr "substr: indice di partenza %g oltre la fine della stringa"
-#: builtin.c:1583
+#: builtin.c:1765
#, c-format
msgid ""
"substr: length %g at start index %g exceeds length of first argument (%lu)"
@@ -758,228 +715,223 @@ msgstr ""
"substr: lunghezza %g all'indice di partenza %g supera la lunghezza del primo "
"argomento (%lu)"
-#: builtin.c:1657
+#: builtin.c:1839
msgid "strftime: format value in PROCINFO[\"strftime\"] has numeric type"
msgstr ""
"strftime: il valore del 'format' in PROCINFO[\"strftime\"] è di tipo numerico"
-#: builtin.c:1680
+#: builtin.c:1862
msgid "strftime: received non-numeric second argument"
msgstr "strftime: il secondo argomento non è numerico"
-#: builtin.c:1683
+#: builtin.c:1866
msgid "strftime: second argument less than 0 or too big for time_t"
msgstr ""
-#: builtin.c:1690
+#: builtin.c:1873
msgid "strftime: received non-string first argument"
msgstr "strftime: il primo argomento non è una stringa"
-#: builtin.c:1696
+#: builtin.c:1880
msgid "strftime: received empty format string"
msgstr "strftime: 'format' è una stringa nulla"
-#: builtin.c:1762
+#: builtin.c:1946
msgid "mktime: received non-string argument"
msgstr "mktime: l'argomento non è una stringa"
-#: builtin.c:1779
+#: builtin.c:1963
msgid "mktime: at least one of the values is out of the default range"
msgstr "mktime: almeno un valore è fuori dall'intervallo di default"
-#: builtin.c:1814
+#: builtin.c:1998
msgid "'system' function not allowed in sandbox mode"
msgstr "la funzione 'system' non è permessa in modo 'sandbox'"
-#: builtin.c:1819
+#: builtin.c:2003
msgid "system: received non-string argument"
msgstr "system: l'argomento non è una stringa"
-#: builtin.c:1874 eval.c:1159 eval.c:1790 eval.c:1803
-#, c-format
-msgid "reference to uninitialized variable `%s'"
-msgstr "riferimento a variabile non inizializzata `%s'"
-
-#: builtin.c:1941
+#: builtin.c:2121
#, c-format
msgid "reference to uninitialized field `$%d'"
msgstr "riferimento a variabile non inizializzata `$%d'"
-#: builtin.c:2028
+#: builtin.c:2208
msgid "tolower: received non-string argument"
msgstr "tolower: l'argomento non è una stringa"
-#: builtin.c:2062
+#: builtin.c:2242
msgid "toupper: received non-string argument"
msgstr "toupper: l'argomento non è una stringa"
-#: builtin.c:2098
+#: builtin.c:2278
msgid "atan2: received non-numeric first argument"
msgstr "atan2: il primo argomento non è numerico"
-#: builtin.c:2100
+#: builtin.c:2280
msgid "atan2: received non-numeric second argument"
msgstr "atan2: il secondo argomento non è numerico"
-#: builtin.c:2119
+#: builtin.c:2299
msgid "sin: received non-numeric argument"
msgstr "sin: l'argomento non è numerico"
-#: builtin.c:2135
+#: builtin.c:2315
msgid "cos: received non-numeric argument"
msgstr "cos: l'argomento non è numerico"
-#: builtin.c:2188
+#: builtin.c:2368
msgid "srand: received non-numeric argument"
msgstr "srand: l'argomento non è numerico"
-#: builtin.c:2219
+#: builtin.c:2399
msgid "match: third argument is not an array"
msgstr "match: il terzo argomento non è un vettore"
-#: builtin.c:2483
+#: builtin.c:2664
msgid "gensub: third argument of 0 treated as 1"
msgstr "gensub: il terzo argomento è 0, trattato come 1"
-#: builtin.c:2776
+#: builtin.c:2957
msgid "lshift: received non-numeric first argument"
msgstr "lshift: il primo argomento non è numerico"
-#: builtin.c:2778
+#: builtin.c:2959
msgid "lshift: received non-numeric second argument"
msgstr "lshift: il secondo argomento non è numerico"
-#: builtin.c:2784
+#: builtin.c:2965
#, c-format
msgid "lshift(%lf, %lf): negative values will give strange results"
msgstr "lshift(%lf, %lf): valori negativi daranno risultati strani"
-#: builtin.c:2786
+#: builtin.c:2967
#, c-format
msgid "lshift(%lf, %lf): fractional values will be truncated"
msgstr "lshift(%lf, %lf): valori con decimali verranno troncati"
-#: builtin.c:2788
+#: builtin.c:2969
#, c-format
msgid "lshift(%lf, %lf): too large shift value will give strange results"
msgstr "lshift(%lf, %lf): valori troppo alti daranno risultati strani"
-#: builtin.c:2813
+#: builtin.c:2994
msgid "rshift: received non-numeric first argument"
msgstr "rshift: il primo argomento non è numerico"
-#: builtin.c:2815
+#: builtin.c:2996
msgid "rshift: received non-numeric second argument"
msgstr "rshift: il secondo argomento non è numerico"
-#: builtin.c:2821
+#: builtin.c:3002
#, c-format
msgid "rshift(%lf, %lf): negative values will give strange results"
msgstr "rshift(%lf, %lf): valori negativi daranno risultati strani"
-#: builtin.c:2823
+#: builtin.c:3004
#, c-format
msgid "rshift(%lf, %lf): fractional values will be truncated"
msgstr "rshift(%lf, %lf): valori con decimali verranno troncati"
-#: builtin.c:2825
+#: builtin.c:3006
#, c-format
msgid "rshift(%lf, %lf): too large shift value will give strange results"
msgstr "rshift(%lf, %lf): valori troppo alti daranno risultati strani"
-#: builtin.c:2850
+#: builtin.c:3031
msgid "and: received non-numeric first argument"
msgstr "and: il primo argomento non è numerico"
-#: builtin.c:2852
+#: builtin.c:3033
msgid "and: received non-numeric second argument"
msgstr "and: il secondo argomento non è numerico"
-#: builtin.c:2858
+#: builtin.c:3039
#, c-format
msgid "and(%lf, %lf): negative values will give strange results"
msgstr "and(%lf, %lf): valori negativi daranno risultati strani"
-#: builtin.c:2860
+#: builtin.c:3041
#, c-format
msgid "and(%lf, %lf): fractional values will be truncated"
msgstr "and(%lf, %lf): valori con decimali verranno troncati"
-#: builtin.c:2885
+#: builtin.c:3066
msgid "or: received non-numeric first argument"
msgstr "or: il primo argomento non è numerico"
-#: builtin.c:2887
+#: builtin.c:3068
msgid "or: received non-numeric second argument"
msgstr "or: il secondo argomento non è numerico"
-#: builtin.c:2893
+#: builtin.c:3074
#, c-format
msgid "or(%lf, %lf): negative values will give strange results"
msgstr "or(%lf, %lf): valori negativi daranno risultati strani"
-#: builtin.c:2895
+#: builtin.c:3076
#, c-format
msgid "or(%lf, %lf): fractional values will be truncated"
msgstr "or(%lf, %lf): valori con decimali verranno troncati"
-#: builtin.c:2923
+#: builtin.c:3102
msgid "xor: received non-numeric first argument"
msgstr "xor: il primo argomento non è numerico"
-#: builtin.c:2925
+#: builtin.c:3104
msgid "xor: received non-numeric second argument"
msgstr "xor: il secondo argomento non è numerico"
-#: builtin.c:2931
+#: builtin.c:3110
#, c-format
msgid "xor(%lf, %lf): negative values will give strange results"
msgstr "xor(%lf, %lf): valori negativi daranno risultati strani"
-#: builtin.c:2933
+#: builtin.c:3112
#, c-format
msgid "xor(%lf, %lf): fractional values will be truncated"
msgstr "xor(%lf, %lf): valori con decimali verranno troncati"
-#: builtin.c:2957 builtin.c:2963
+#: builtin.c:3136
msgid "compl: received non-numeric argument"
msgstr "compl: l'argomento non è numerico"
-#: builtin.c:2965
+#: builtin.c:3142
#, c-format
msgid "compl(%lf): negative value will give strange results"
msgstr "compl(%lf): valore negativo darà risultati strani"
-#: builtin.c:2967
+#: builtin.c:3144
#, c-format
msgid "compl(%lf): fractional value will be truncated"
msgstr "compl(%lf): valore con decimali verrà troncato"
-#: builtin.c:3136
+#: builtin.c:3313
#, c-format
msgid "dcgettext: `%s' is not a valid locale category"
msgstr "dcgettext: `%s' non è una categoria 'locale' valida"
-#: eval.c:412
+#: eval.c:395
#, c-format
msgid "unknown nodetype %d"
msgstr "tipo nodo sconosciuto %d"
-#: eval.c:423 eval.c:437
+#: eval.c:406 eval.c:420
#, c-format
msgid "unknown opcode %d"
msgstr "codice operativo sconosciuto %d"
-#: eval.c:434
+#: eval.c:417
#, c-format
msgid "opcode %s not an operator or keyword"
msgstr "codice operativo %s non è un operatore o una parola chiave"
-#: eval.c:488
+#: eval.c:472
msgid "buffer overflow in genflags2str"
msgstr "superamento limiti buffer in 'genflags2str'"
-#: eval.c:698
+#: eval.c:675
#, c-format
msgid ""
"\n"
@@ -990,308 +942,251 @@ msgstr ""
"\t# 'Stack' (Pila) Chiamate Funzione:\n"
"\n"
-#: eval.c:725
+#: eval.c:704
msgid "`IGNORECASE' is a gawk extension"
msgstr "`IGNORECASE' è un'estensione gawk"
-#: eval.c:754
+#: eval.c:736
msgid "`BINMODE' is a gawk extension"
msgstr "`BINMODE' è un'estensione gawk"
-#: eval.c:812
+#: eval.c:793
#, c-format
msgid "BINMODE value `%s' is invalid, treated as 3"
msgstr "valore di BINMODE `%s' non valido, considerato come 3"
-#: eval.c:902
+#: eval.c:885
#, c-format
msgid "bad `%sFMT' specification `%s'"
msgstr "specificazione invalida `%sFMT' `%s'"
-#: eval.c:980
+#: eval.c:969
msgid "turning off `--lint' due to assignment to `LINT'"
msgstr "disabilito `--lint' a causa di assegnamento a `LINT'"
-#: eval.c:1127 eval.c:1777
-#, c-format
-msgid "can't use function name `%s' as variable or array"
-msgstr "non posso usare nome di funzione `%s' come variabile o vettore"
-
-#: eval.c:1158 eval.c:1789 eval.c:1802
+#: eval.c:1132
#, c-format
msgid "reference to uninitialized argument `%s'"
msgstr "riferimento ad argomento non inizializzato `%s'"
-#: eval.c:1177
+#: eval.c:1133
+#, c-format
+msgid "reference to uninitialized variable `%s'"
+msgstr "riferimento a variabile non inizializzata `%s'"
+
+#: eval.c:1151
msgid "attempt to field reference from non-numeric value"
msgstr "tentativo di riferimento a un campo da valore non numerico"
-#: eval.c:1179
+#: eval.c:1153
msgid "attempt to field reference from null string"
msgstr "tentativo di riferimento a un campo da una stringa nulla"
-#: eval.c:1185
+#: eval.c:1161
#, c-format
msgid "attempt to access field %ld"
msgstr "tentativo di accedere al campo %ld"
-#: eval.c:1194
+#: eval.c:1170
#, c-format
msgid "reference to uninitialized field `$%ld'"
msgstr "riferimento a campo non inizializzato `$%ld'"
-#: eval.c:1256
+#: eval.c:1257
#, c-format
msgid "function `%s' called with more arguments than declared"
msgstr "funzione `%s' chiamata con più argomenti di quelli previsti"
-#: eval.c:1437
+#: eval.c:1452
#, c-format
msgid "unwind_stack: unexpected type `%s'"
msgstr "unwind_stack: tipo non previsto `%s'"
-#: eval.c:1532
+#: eval.c:1546
msgid "division by zero attempted in `/='"
msgstr "divisione per zero tentata in `/='"
-#: eval.c:1539
+#: eval.c:1553
#, c-format
msgid "division by zero attempted in `%%='"
msgstr "divisione per zero tentata in `%%='"
-#: eval.c:1876 eval.c:2122
-#, fuzzy, c-format
-msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
-msgstr "tentativo di usare vettore `%s' in un contesto scalare"
-
-#: eval.c:1907
-msgid "assignment used in conditional context"
-msgstr "assegnamento usato nel contesto di un test condizionale"
-
-#: eval.c:1911
-msgid "statement has no effect"
-msgstr "istruzione che non fa nulla"
-
-#: eval.c:2343
-#, c-format
-msgid "for loop: array `%s' changed size from %ld to %ld during loop execution"
-msgstr ""
-"ciclo for: vettore `%s' ha cambiato dimensione da %ld a %ld durante "
-"l'esecuzione del ciclo"
-
-#: eval.c:2458
-#, c-format
-msgid "function called indirectly through `%s' does not exist"
-msgstr "la funzione chiamata indirettamente tramite `%s' non esiste"
-
-#: eval.c:2470
-#, c-format
-msgid "function `%s' not defined"
-msgstr "funzione `%s' non definita"
-
-#: eval.c:2511
-#, c-format
-msgid "non-redirected `getline' invalid inside `%s' rule"
-msgstr "`getline' non-diretta indefinita dentro regola '%s'"
-
-#: eval.c:2600
-#, c-format
-msgid "error reading input file `%s': %s"
-msgstr "errore leggendo file di input `%s': %s"
-
-#: eval.c:2614
-#, c-format
-msgid "`nextfile' cannot be called from a `%s' rule"
-msgstr "`nextfile' non può essere chiamato da una regola `%s'"
-
-#: eval.c:2661
-#, fuzzy
-msgid "`exit' cannot be called in the current context"
-msgstr "`next' non può essere chiamato da una regola `%s'"
-
-#: eval.c:2700
-#, c-format
-msgid "`next' cannot be called from a `%s' rule"
-msgstr "`next' non può essere chiamato da una regola `%s'"
-
-#: eval.c:2766
-#, c-format
-msgid "Sorry, don't know how to interpret `%s'"
-msgstr "Spiacente, non so come interpretare `%s'"
-
-#: ext.c:54
+#: ext.c:70
msgid "extensions are not allowed in sandbox mode"
msgstr "le estensioni non sono permesse in modo 'sandbox'"
-#: ext.c:60 ext.c:65
+#: ext.c:73
msgid "`extension' is a gawk extension"
msgstr "`extension' è un'estensione gawk"
-#: ext.c:75
-#, c-format
-msgid "fatal: extension: cannot open `%s' (%s)\n"
+#: ext.c:80
+#, fuzzy, c-format
+msgid "extension: cannot open library `%s' (%s)\n"
msgstr "fatale: estensione: non riesco ad aprire `%s' (%s)\n"
-#: ext.c:84
-#, c-format
+#: ext.c:86
+#, fuzzy, c-format
msgid ""
-"fatal: extension: library `%s': does not define "
-"`plugin_is_GPL_compatible' (%s)\n"
+"extension: library `%s': does not define `plugin_is_GPL_compatible' (%s)\n"
msgstr ""
"fatale: estensione: libreria `%s': non definisce "
"`plugin_is_GPL_compatible' (%s)\n"
-#: ext.c:93
-#, c-format
-msgid "fatal: extension: library `%s': cannot call function `%s' (%s)\n"
+#: ext.c:90
+#, fuzzy, c-format
+msgid "extension: library `%s': cannot call function `%s' (%s)\n"
msgstr ""
"fatale: estensione: libreria `%s': non riesco a chiamare funzione `%s' (%s)\n"
-#: ext.c:127
+#: ext.c:118
msgid "extension: missing function name"
msgstr "estensione: manca nome di funzione"
-#: ext.c:132
+#: ext.c:123
#, c-format
msgid "extension: illegal character `%c' in function name `%s'"
msgstr "estensione: carattere non ammesso `%c' nel nome di funzione `%s'"
-#: ext.c:141
+#: ext.c:131
#, c-format
msgid "extension: can't redefine function `%s'"
msgstr "estensione: non riesco a ridefinire funzione `%s'"
-#: ext.c:145
+#: ext.c:135
#, c-format
msgid "extension: function `%s' already defined"
msgstr "estensione: funzione `%s' già definita"
-#: ext.c:150
+#: ext.c:139
#, c-format
msgid "extension: function name `%s' previously defined"
msgstr "estensione: funzione di nome `%s' definita in precedenza"
-#: ext.c:152
+#: ext.c:141
#, c-format
msgid "extension: can't use gawk built-in `%s' as function name"
msgstr ""
"estensione: nome funzione interna gawk `%s' non ammesso come nome funzione"
-#: ext.c:156
+#: ext.c:144
#, c-format
msgid "make_builtin: negative argument count for function `%s'"
msgstr "make_builtin: contatore argomenti negativo per la funzione `%s'"
-#: ext.c:259
+#: ext.c:206
#, c-format
msgid "function `%s' defined to take no more than %d argument(s)"
msgstr "funzione `%s' definita per avere al massimo %d argomenti(o)"
-#: ext.c:262
+#: ext.c:209
#, c-format
msgid "function `%s': missing argument #%d"
msgstr "funzione `%s': manca argomento #%d"
-#: ext.c:279
+#: ext.c:226
#, c-format
msgid "function `%s': argument #%d: attempt to use scalar as an array"
msgstr "funzione `%s': argomento #%d: tentativo di usare scalare come vettore"
-#: ext.c:283
+#: ext.c:230
#, c-format
msgid "function `%s': argument #%d: attempt to use array as a scalar"
msgstr "funzione `%s': argomento #%d: tentativo di usare vettore come scalare"
-#: ext.c:296
+#: ext.c:244
msgid "Operation Not Supported"
msgstr "Operazione Non Supportata"
-#: field.c:328
+#: ext.c:256
+msgid "dynamic loading of library not supported"
+msgstr ""
+
+#: field.c:339
msgid "NF set to negative value"
msgstr "NF impostato a un valore negativo"
-#: field.c:951 field.c:958 field.c:962
+#: field.c:962 field.c:969 field.c:973
msgid "split: fourth argument is a gawk extension"
msgstr "split: il quarto argomento è un'estensione gawk"
-#: field.c:955
+#: field.c:966
msgid "split: fourth argument is not an array"
msgstr "split: il quarto argomento non è un vettore"
-#: field.c:969
+#: field.c:980
msgid "split: second argument is not an array"
msgstr "split: il secondo argomento non è un vettore"
-#: field.c:973
+#: field.c:984
#, fuzzy
msgid "split: cannot use the same array for second and fourth args"
msgstr ""
"split: non si può usare lo stesso vettore come secondo e quarto argomento"
-#: field.c:978
+#: field.c:989
#, fuzzy
msgid "split: cannot use a subarray of second arg for fourth arg"
msgstr ""
"split: non si può usare lo stesso vettore come secondo e quarto argomento"
-#: field.c:981
+#: field.c:992
#, fuzzy
msgid "split: cannot use a subarray of fourth arg for second arg"
msgstr ""
"split: non si può usare lo stesso vettore come secondo e quarto argomento"
-#: field.c:1010
+#: field.c:1021
msgid "split: null string for third arg is a gawk extension"
msgstr "split: la stringa nulla come terzo arg. è un'estensione gawk"
-#: field.c:1050
+#: field.c:1061
msgid "patsplit: fourth argument is not an array"
msgstr "patsplit: il secondo argomento non è un vettore"
-#: field.c:1055
+#: field.c:1066
msgid "patsplit: second argument is not an array"
msgstr "patsplit: il secondo argomento non è un vettore"
-#: field.c:1061
+#: field.c:1072
msgid "patsplit: third argument must be non-null"
msgstr "patsplit: il terzo argomento non può essere nullo"
-#: field.c:1065
+#: field.c:1076
#, fuzzy
msgid "patsplit: cannot use the same array for second and fourth args"
msgstr ""
"patsplit: non si può usare lo stesso vettore come secondo e quarto argomento"
-#: field.c:1070
+#: field.c:1081
#, fuzzy
msgid "patsplit: cannot use a subarray of second arg for fourth arg"
msgstr ""
"patsplit: non si può usare lo stesso vettore come secondo e quarto argomento"
-#: field.c:1073
+#: field.c:1084
#, fuzzy
msgid "patsplit: cannot use a subarray of fourth arg for second arg"
msgstr ""
"patsplit: non si può usare lo stesso vettore come secondo e quarto argomento"
-#: field.c:1110
+#: field.c:1122
msgid "`FIELDWIDTHS' is a gawk extension"
msgstr "`FIELDWIDTHS' è un'estensione gawk"
-#: field.c:1173
+#: field.c:1186
#, c-format
msgid "invalid FIELDWIDTHS value, near `%s'"
msgstr "valore di FIELDWIDTHS non valido, vicino a `%s'"
-#: field.c:1246
+#: field.c:1259
msgid "null string for `FS' is a gawk extension"
msgstr "la stringa nulla usata come `FS' è un'estensione gawk"
-#: field.c:1250
+#: field.c:1263
msgid "old awk does not support regexps as value of `FS'"
msgstr "il vecchio awk non supporta espressioni come valori di `FS'"
-#: field.c:1369
+#: field.c:1382
msgid "`FPAT' is a gawk extension"
msgstr "`FPAT' è un'estensione gawk"
@@ -1350,461 +1245,476 @@ msgstr "%s: l'opzione '-W %s' non ammette un argomento\n"
msgid "%s: option '-W %s' requires an argument\n"
msgstr "%s: l'opzione '-W %s' richiede un argomento\n"
-#: io.c:280
+#: io.c:326
#, c-format
msgid "command line argument `%s' is a directory: skipped"
msgstr "l'argomento in linea comando `%s' è una directory: saltato"
-#: io.c:283 io.c:385
+#: io.c:329 io.c:438
#, c-format
msgid "cannot open file `%s' for reading (%s)"
msgstr "non riesco ad aprire file `%s' in lettura (%s)"
-#: io.c:501
+#: io.c:568
#, c-format
msgid "close of fd %d (`%s') failed (%s)"
msgstr "chiusura di fd %d (`%s') fallita (%s)"
-#: io.c:578
+#: io.c:645
msgid "redirection not allowed in sandbox mode"
msgstr "re-direzione non permessa in modo 'sandbox'"
-#: io.c:612
+#: io.c:679
#, c-format
msgid "expression in `%s' redirection only has numeric value"
msgstr "espressione nella re-direzione `%s' ha solo un valore numerico"
-#: io.c:618
+#: io.c:685
#, c-format
msgid "expression for `%s' redirection has null string value"
msgstr "espressione nella re-direzione `%s' ha per valore la stringa nulla"
-#: io.c:623
+#: io.c:690
#, c-format
msgid "filename `%s' for `%s' redirection may be result of logical expression"
msgstr ""
"nome-file `%s' per la re-direzione `%s' può essere il risultato di una "
"espressione logica"
-#: io.c:666
+#: io.c:733
#, c-format
msgid "unnecessary mixing of `>' and `>>' for file `%.*s'"
msgstr "mistura non necessaria di `>' e `>>' per il file `%.*s'"
-#: io.c:719
+#: io.c:786
#, c-format
msgid "can't open pipe `%s' for output (%s)"
msgstr "non posso aprire 'pipe' `%s' in scrittura (%s)"
-#: io.c:729
+#: io.c:796
#, c-format
msgid "can't open pipe `%s' for input (%s)"
msgstr "non posso aprire 'pipe' `%s' in lettura (%s)"
-#: io.c:752
+#: io.c:819
#, c-format
msgid "can't open two way pipe `%s' for input/output (%s)"
msgstr "non posso aprire 'pipe' bidirezionale `%s' per lettura/scrittura (%s)"
-#: io.c:834
+#: io.c:900
#, c-format
msgid "can't redirect from `%s' (%s)"
msgstr "non posso re-dirigere da `%s' (%s)"
-#: io.c:837
+#: io.c:903
#, c-format
msgid "can't redirect to `%s' (%s)"
msgstr "non posso re-dirigere a `%s' (%s)"
-#: io.c:888
+#: io.c:954
msgid ""
"reached system limit for open files: starting to multiplex file descriptors"
msgstr ""
"numero massimo consentito di file aperti raggiunto: comincio a riutilizzare "
"i descrittori di file"
-#: io.c:904
+#: io.c:970
#, c-format
msgid "close of `%s' failed (%s)."
msgstr "chiusura di `%s' fallita (%s)."
-#: io.c:912
+#: io.c:978
msgid "too many pipes or input files open"
msgstr "troppe 'pipe' o file di input aperti"
-#: io.c:934
+#: io.c:1000
msgid "close: second argument must be `to' or `from'"
msgstr "close: il secondo argomento deve essere `a' o `da'"
-#: io.c:951
+#: io.c:1017
#, c-format
msgid "close: `%.*s' is not an open file, pipe or co-process"
msgstr "close: `%.*s' non è un file aperto, una 'pipe' o un co-processo"
-#: io.c:956
+#: io.c:1022
msgid "close of redirection that was never opened"
msgstr "chiusura di una re-direzione mai aperta"
-#: io.c:1053
+#: io.c:1120
#, c-format
msgid "close: redirection `%s' not opened with `|&', second argument ignored"
msgstr "close: re-direzione `%s' non aperta con `|&', ignoro secondo argomento"
-#: io.c:1069
+#: io.c:1137
#, c-format
msgid "failure status (%d) on pipe close of `%s' (%s)"
msgstr "errore ritornato (%d) dalla chiusura della 'pipe' `%s' (%s)"
-#: io.c:1072
+#: io.c:1140
#, c-format
msgid "failure status (%d) on file close of `%s' (%s)"
msgstr "errore ritornato (%d) dalla chiusura del file `%s' (%s)"
-#: io.c:1092
+#: io.c:1160
#, c-format
msgid "no explicit close of socket `%s' provided"
msgstr "nessuna chiusura esplicita richiesta per 'socket' `%s'"
-#: io.c:1095
+#: io.c:1163
#, c-format
msgid "no explicit close of co-process `%s' provided"
msgstr "nessuna chiusura esplicita richiesta per co-processo `%s'"
-#: io.c:1098
+#: io.c:1166
#, c-format
msgid "no explicit close of pipe `%s' provided"
msgstr "nessuna chiusura esplicita richiesta per 'pipe' `%s'"
-#: io.c:1101
+#: io.c:1169
#, c-format
msgid "no explicit close of file `%s' provided"
msgstr "nessuna chiusura esplicita richiesta per file `%s'"
-#: io.c:1129 io.c:1184 main.c:794 main.c:831
+#: io.c:1197 io.c:1252 main.c:825 main.c:862
#, c-format
msgid "error writing standard output (%s)"
msgstr "errore scrivendo 'standard output' (%s)"
-#: io.c:1133 io.c:1189
+#: io.c:1201 io.c:1257
#, c-format
msgid "error writing standard error (%s)"
msgstr "errore scrivendo 'standard error' (%s)"
-#: io.c:1141
+#: io.c:1209
#, c-format
msgid "pipe flush of `%s' failed (%s)."
msgstr "scaricamento di 'pipe' `%s' fallita (%s)."
-#: io.c:1144
+#: io.c:1212
#, c-format
msgid "co-process flush of pipe to `%s' failed (%s)."
msgstr "scaricamento da co-processo di 'pipe' a `%s' fallita (%s)."
-#: io.c:1147
+#: io.c:1215
#, c-format
msgid "file flush of `%s' failed (%s)."
msgstr "scaricamento di file `%s' fallita (%s)."
-#: io.c:1262
+#: io.c:1329
#, c-format
msgid "local port %s invalid in `/inet'"
msgstr "porta locale %s invalida in `/inet'"
-#: io.c:1279
+#: io.c:1347
#, c-format
msgid "remote host and port information (%s, %s) invalid"
msgstr "host remoto e informazione di porta (%s, %s) invalidi"
-#: io.c:1431
+#: io.c:1499
#, c-format
msgid "no (known) protocol supplied in special filename `%s'"
msgstr "nessuno protocollo (noto) specificato nel filename speciale `%s'"
-#: io.c:1445
+#: io.c:1513
#, c-format
msgid "special file name `%s' is incomplete"
msgstr "nome-file speciale `%s' incompleto"
-#: io.c:1462
+#: io.c:1530
msgid "must supply a remote hostname to `/inet'"
msgstr "va fornito nome di 'host' remoto a `/inet'"
-#: io.c:1480
+#: io.c:1548
msgid "must supply a remote port to `/inet'"
msgstr "va fornita porta remota a `/inet'"
-#: io.c:1526
+#: io.c:1594
msgid "TCP/IP communications are not supported"
msgstr "comunicazioni TCP/IP non supportate"
-#: io.c:1693
+#: io.c:1764
#, c-format
msgid "could not open `%s', mode `%s'"
msgstr "non riesco ad aprire `%s', modo `%s'"
-#: io.c:1747
+#: io.c:1814
#, c-format
msgid "close of master pty failed (%s)"
msgstr "fallita chiusura di 'pty' principale (%s)"
-#: io.c:1749 io.c:1917 io.c:2074
+#: io.c:1816 io.c:1984 io.c:2145
#, c-format
msgid "close of stdout in child failed (%s)"
msgstr "fallita chiusura di 'stdout' nel processo-figlio (%s)"
-#: io.c:1752
+#: io.c:1819
#, c-format
msgid "moving slave pty to stdout in child failed (dup: %s)"
msgstr ""
"fallito trasferimento di 'pty' secondaria a 'stdout' nel processo-figlio "
"(dup: %s)"
-#: io.c:1754 io.c:1922
+#: io.c:1821 io.c:1989
#, c-format
msgid "close of stdin in child failed (%s)"
msgstr "fallita chiusura di 'stdin' nel processo-figlio (%s)"
-#: io.c:1757
+#: io.c:1824
#, c-format
msgid "moving slave pty to stdin in child failed (dup: %s)"
msgstr ""
"fallito trasferimento di 'pty' secondaria a 'stdin' nel processo-figlio "
"(dup: %s)"
-#: io.c:1759 io.c:1780
+#: io.c:1826 io.c:1847
#, c-format
msgid "close of slave pty failed (%s)"
msgstr "fallita chiusura di 'pty' secondaria (%s)"
-#: io.c:1858 io.c:1920 io.c:2052 io.c:2077
+#: io.c:1925 io.c:1987 io.c:2122 io.c:2148
#, c-format
msgid "moving pipe to stdout in child failed (dup: %s)"
msgstr "fallito passaggio di 'pipe' a 'stdout' nel processo-figlio (dup: %s)"
-#: io.c:1865 io.c:1925
+#: io.c:1932 io.c:1992
#, c-format
msgid "moving pipe to stdin in child failed (dup: %s)"
msgstr "fallito passaggio di pipe a 'stdin' nel processo-figlio (dup: %s)"
-#: io.c:1885 io.c:2067
+#: io.c:1952 io.c:2138
msgid "restoring stdout in parent process failed\n"
msgstr "fallito ripristino di 'stdout' nel processo-padre\n"
-#: io.c:1893
+#: io.c:1960
msgid "restoring stdin in parent process failed\n"
msgstr "fallito ripristino di 'stdin' nel processo-padre\n"
-#: io.c:1928 io.c:2079 io.c:2093
+#: io.c:1995 io.c:2150 io.c:2164
#, c-format
msgid "close of pipe failed (%s)"
msgstr "fallita chiusura di 'pipe' (%s)"
-#: io.c:1973
+#: io.c:2040
msgid "`|&' not supported"
msgstr "`|&' non supportato"
-#: io.c:2039
+#: io.c:2107
#, c-format
msgid "cannot open pipe `%s' (%s)"
msgstr "non riesco ad aprire 'pipe' `%s' (%s)"
-#: io.c:2087
+#: io.c:2158
#, c-format
msgid "cannot create child process for `%s' (fork: %s)"
msgstr "non riesco a creare processo-figlio per `%s' (fork: %s)"
-#: io.c:2520
+#: io.c:2637
#, c-format
msgid "data file `%s' is empty"
msgstr "file dati `%s' vuoto"
-#: io.c:2561 io.c:2569
+#: io.c:2678 io.c:2686
msgid "could not allocate more input memory"
msgstr "non riesco ad allocare ulteriore memoria per l'input"
-#: io.c:3127
+#: io.c:3236
msgid "multicharacter value of `RS' is a gawk extension"
msgstr "valore multicarattere per `RS' è un'estensione gawk"
-#: io.c:3232
+#: io.c:3326
msgid "IPv6 communication is not supported"
msgstr "comunicazioni IPv6 non supportate"
-#: main.c:366
+#: main.c:355
msgid "`-m[fr]' option irrelevant in gawk"
msgstr "`-m[fr]' opzione irrilevante per gawk"
-#: main.c:368
+#: main.c:357
msgid "-m option usage: `-m[fr] nnn'"
msgstr "-m uso opzione: `-m[fr] nnn'"
-#: main.c:391
+#: main.c:386
msgid "empty argument to `-e/--source' ignored"
msgstr "argomento di `-e/--source' nullo, ignorato"
-#: main.c:462
+#: main.c:472
#, c-format
msgid "%s: option `-W %s' unrecognized, ignored\n"
msgstr "%s: opzione `-W %s' non riconosciuta, ignorata\n"
-#: main.c:515
+#: main.c:518
#, c-format
msgid "%s: option requires an argument -- %c\n"
msgstr "%s: l'opzione richiede un argomento -- %c\n"
-#: main.c:536
+#: main.c:539
msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'"
msgstr "variable d'ambiente `POSIXLY_CORRECT' impostata: attivo `--posix'"
-#: main.c:542
+#: main.c:545
msgid "`--posix' overrides `--traditional'"
msgstr "`--posix' annulla `--traditional'"
-#: main.c:553
+#: main.c:556
msgid "`--posix'/`--traditional' overrides `--non-decimal-data'"
msgstr "`--posix'/`--traditional' annulla `--non-decimal-data'"
-#: main.c:557
+#: main.c:560
#, c-format
msgid "running %s setuid root may be a security problem"
msgstr "eseguire %s con 'setuid' root può essere un rischio per la sicurezza"
-#: main.c:562
+#: main.c:565
msgid "`--posix' overrides `--binary'"
msgstr "`--posix' annulla `--binary"
-#: main.c:613
+#: main.c:623
#, c-format
msgid "can't set binary mode on stdin (%s)"
msgstr "non posso impostare modalità binaria su 'stdin'(%s)"
-#: main.c:616
+#: main.c:626
#, c-format
msgid "can't set binary mode on stdout (%s)"
msgstr "non posso impostare modalità binaria su 'stdout'(%s)"
-#: main.c:618
+#: main.c:628
#, c-format
msgid "can't set binary mode on stderr (%s)"
msgstr "non posso impostare modalità binaria su 'stderr'(%s)"
-#: main.c:657
+#: main.c:679
msgid "no program text at all!"
msgstr "manca del tutto il testo del programma!"
-#: main.c:734
+#: main.c:763
#, c-format
msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n"
msgstr "Uso: %s [opzioni in stile POSIX o GNU] -f file-prog. [--] file ...\n"
-#: main.c:736
+#: main.c:765
#, c-format
msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n"
msgstr "Usage: %s [opzioni in stile POSIX o GNU] [--] %cprogramma%c file ...\n"
-#: main.c:741
+#: main.c:770
msgid "POSIX options:\t\tGNU long options: (standard)\n"
msgstr "Opzioni POSIX:\t\topzioni lunghe GNU: (standard)\n"
-#: main.c:742
+#: main.c:771
msgid "\t-f progfile\t\t--file=progfile\n"
msgstr "\t-f fileprog\t\t--file=file-prog.\n"
-#: main.c:743
+#: main.c:772
msgid "\t-F fs\t\t\t--field-separator=fs\n"
msgstr "\t-F fs\t\t\t--field-separator=fs\n"
-#: main.c:744
+#: main.c:773
msgid "\t-v var=val\t\t--assign=var=val\n"
msgstr "\t-v var=valore\t\t--assign=var=valore\n"
-#: main.c:745
+#: main.c:774
msgid "Short options:\t\tGNU long options: (extensions)\n"
msgstr "Opzioni brevi:\t\topzioni lunghe GNU: (estensioni)\n"
-#: main.c:746
+#: main.c:775
msgid "\t-b\t\t\t--characters-as-bytes\n"
msgstr "\t-b\t\t\t--characters-as-bytes\n"
-#: main.c:747
+#: main.c:776
msgid "\t-c\t\t\t--traditional\n"
msgstr "\t-c\t\t\t--traditional\n"
-#: main.c:748
+#: main.c:777
msgid "\t-C\t\t\t--copyright\n"
msgstr "\t-C\t\t\t--copyright\n"
-#: main.c:749
+#: main.c:778
#, fuzzy
msgid "\t-d[file]\t\t--dump-variables[=file]\n"
msgstr "\t-d [file]\t\t--dump-variables[=file]\n"
-#: main.c:750
+#: main.c:779
+#, fuzzy
+msgid "\t-D[file]\t\t--debug[=file]\n"
+msgstr "\t-p [file]\t\t--profile[=file]\n"
+
+#: main.c:780
msgid "\t-e 'program-text'\t--source='program-text'\n"
msgstr "\t-e 'testo-del-programma'\t--source='testo-del-programma'\n"
-#: main.c:751
+#: main.c:781
msgid "\t-E file\t\t\t--exec=file\n"
msgstr "\t-E file\t\t\t--exec=file\n"
-#: main.c:752
+#: main.c:782
msgid "\t-g\t\t\t--gen-pot\n"
msgstr "\t-g\t\t\t--gen-pot\n"
-#: main.c:753
+#: main.c:783
msgid "\t-h\t\t\t--help\n"
msgstr "\t-h\t\t\t--help\n"
-#: main.c:754
+#: main.c:784
+msgid "\t-l library\t\t--load=library\n"
+msgstr ""
+
+#: main.c:785
msgid "\t-L [fatal]\t\t--lint[=fatal]\n"
msgstr "\t-L [fatal]\t\t--lint[=fatal]\n"
-#: main.c:755
+#: main.c:786
msgid "\t-n\t\t\t--non-decimal-data\n"
msgstr "\t-n\t\t\t--non-decimal-data\n"
-#: main.c:756
+#: main.c:787
+#, fuzzy
+msgid "\t-M\t\t\t--bignum\n"
+msgstr "\t-g\t\t\t--gen-pot\n"
+
+#: main.c:788
msgid "\t-N\t\t\t--use-lc-numeric\n"
msgstr "\t-N\t\t\t--use-lc-numeric\n"
-#: main.c:757
+#: main.c:789
+#, fuzzy
+msgid "\t-o[file]\t\t--pretty-print[=file]\n"
+msgstr "\t-p [file]\t\t--profile[=file]\n"
+
+#: main.c:790
msgid "\t-O\t\t\t--optimize\n"
msgstr "\t-O\t\t\t--optimize\n"
-#: main.c:758
+#: main.c:791
#, fuzzy
msgid "\t-p[file]\t\t--profile[=file]\n"
msgstr "\t-p [file]\t\t--profile[=file]\n"
-#: main.c:759
+#: main.c:792
msgid "\t-P\t\t\t--posix\n"
msgstr "\t-P\t\t\t--posix\n"
-#: main.c:760
+#: main.c:793
msgid "\t-r\t\t\t--re-interval\n"
msgstr "\t-r\t\t\t--re-interval\n"
-#: main.c:762
-msgid "\t-R file\t\t\t--command=file\n"
-msgstr "\t-R file\t\t\t--command=file\n"
-
-#: main.c:763
+#: main.c:794
msgid "\t-S\t\t\t--sandbox\n"
msgstr "\t-S\t\t\t--sandbox\n"
-#: main.c:764
+#: main.c:795
msgid "\t-t\t\t\t--lint-old\n"
msgstr "\t-t\t\t\t--lint-old\n"
-#: main.c:765
+#: main.c:796
msgid "\t-V\t\t\t--version\n"
msgstr "\t-V\t\t\t--version\n"
-#: main.c:767
+#: main.c:798
msgid "\t-W nostalgia\t\t--nostalgia\n"
msgstr "\t-W nostalgia\t\t--nostalgia\n"
-#: main.c:770
+#: main.c:801
msgid "\t-Y\t\t--parsedebug\n"
msgstr "\t-Y\t\t--parsedebug\n"
@@ -1813,7 +1723,7 @@ msgstr "\t-Y\t\t--parsedebug\n"
#. for this application. Please add _another line_ with the
#. address for translation bugs.
#. no-wrap
-#: main.c:779
+#: main.c:810
msgid ""
"\n"
"To report bugs, see node `Bugs' in `gawk.info', which is\n"
@@ -1825,7 +1735,7 @@ msgstr ""
"sezione `Reporting Problems and Bugs' nella versione a stampa.\n"
"\n"
-#: main.c:783
+#: main.c:814
msgid ""
"gawk is a pattern scanning and processing language.\n"
"By default it reads standard input and writes standard output.\n"
@@ -1835,7 +1745,7 @@ msgstr ""
"Senza parametri, legge da 'standard input' e scrive su 'standard output'.\n"
"\n"
-#: main.c:787
+#: main.c:818
msgid ""
"Examples:\n"
"\tgawk '{ sum += $1 }; END { print sum }' file\n"
@@ -1845,7 +1755,7 @@ msgstr ""
"\tgawk '{ sum += $1 }; END { print sum }' file\n"
"\tgawk -F: '{ print $1 }' /etc/passwd\n"
-#: main.c:807
+#: main.c:838
#, c-format
msgid ""
"Copyright (C) 1989, 1991-%d Free Software Foundation.\n"
@@ -1864,7 +1774,7 @@ msgstr ""
"Licenza, o (a tua scelta) a una qualsiasi versione successiva.\n"
"\n"
-#: main.c:815
+#: main.c:846
msgid ""
"This program is distributed in the hope that it will be useful,\n"
"but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
@@ -1878,7 +1788,7 @@ msgstr ""
"Vedi la 'GNU General Public License' per ulteriori dettagli.\n"
"\n"
-#: main.c:821
+#: main.c:852
msgid ""
"You should have received a copy of the GNU General Public License\n"
"along with this program. If not, see http://www.gnu.org/licenses/.\n"
@@ -1887,16 +1797,16 @@ msgstr ""
"assieme a questo programma; se non è così, vedi http://www.gnu.org/"
"licenses/.\n"
-#: main.c:856
+#: main.c:887
msgid "-Ft does not set FS to tab in POSIX awk"
msgstr "-Ft non imposta FS a 'tab' nell'awk POSIX"
-#: main.c:1090
+#: main.c:1133
#, c-format
msgid "unknown value for field spec: %d\n"
msgstr "valore non noto per specifica campo: %d\n"
-#: main.c:1171
+#: main.c:1214
#, c-format
msgid ""
"%s: `%s' argument to `-v' not in `var=value' form\n"
@@ -1905,80 +1815,80 @@ msgstr ""
"%s: `%s' argomento di `-v' non in forma `var=valore'\n"
"\n"
-#: main.c:1197
+#: main.c:1240
#, c-format
msgid "`%s' is not a legal variable name"
msgstr "`%s' non è un nome di variabile ammesso"
-#: main.c:1200
+#: main.c:1243
#, c-format
msgid "`%s' is not a variable name, looking for file `%s=%s'"
msgstr "`%s' non è un nome di variabile, cerco il file `%s=%s'"
-#: main.c:1204
+#: main.c:1247
#, fuzzy, c-format
msgid "cannot use gawk builtin `%s' as variable name"
msgstr ""
"estensione: nome funzione interna gawk `%s' non ammesso come nome funzione"
-#: main.c:1209
+#: main.c:1252
#, fuzzy, c-format
msgid "cannot use function `%s' as variable name"
msgstr "non posso usare nome di funzione `%s' come variabile o vettore"
-#: main.c:1262
+#: main.c:1305
msgid "floating point exception"
msgstr "eccezione floating point"
-#: main.c:1269
+#: main.c:1312
msgid "fatal error: internal error"
msgstr "errore fatale: errore interno"
-#: main.c:1284
+#: main.c:1327
msgid "fatal error: internal error: segfault"
msgstr "errore fatale: errore interno: segfault"
-#: main.c:1296
+#: main.c:1339
msgid "fatal error: internal error: stack overflow"
msgstr "errore fatale: errore interno: stack overflow"
-#: main.c:1346
+#: main.c:1393
#, c-format
msgid "no pre-opened fd %d"
msgstr "manca 'fd' pre-aperta %d"
-#: main.c:1353
+#: main.c:1400
#, c-format
msgid "could not pre-open /dev/null for fd %d"
msgstr "non riesco a pre-aprire /dev/null per 'fd' %d"
-#: msg.c:63
+#: msg.c:61
#, c-format
msgid "cmd. line:"
msgstr "linea com.:"
-#: msg.c:107
+#: msg.c:121
msgid "error: "
msgstr "errore: "
-#: node.c:406
+#: node.c:436
msgid "backslash at end of string"
msgstr "'\\' a fine stringa"
-#: node.c:517
+#: node.c:520
#, c-format
msgid "old awk does not support the `\\%c' escape sequence"
msgstr "il vecchio awk non supporta la sequenza di escape '\\%c'"
-#: node.c:568
+#: node.c:571
msgid "POSIX does not allow `\\x' escapes"
msgstr "POSIX non permette escape `\\x'"
-#: node.c:574
+#: node.c:577
msgid "no hex digits in `\\x' escape sequence"
msgstr "niente cifre esadecimali nella sequenza di escape `\\x'"
-#: node.c:596
+#: node.c:599
#, c-format
msgid ""
"hex escape \\x%.*s of %d characters probably not interpreted the way you "
@@ -1987,12 +1897,12 @@ msgstr ""
"sequenza di escape esadec.\\x%.*s di %d caratteri probabilmente non "
"interpretata nel modo previsto"
-#: node.c:611
+#: node.c:614
#, c-format
msgid "escape sequence `\\%c' treated as plain `%c'"
msgstr "sequenza di escape `\\%c' considerata come semplice `%c'"
-#: node.c:750
+#: node.c:759
msgid ""
"Invalid multibyte data detected. There may be a mismatch between your data "
"and your locale."
@@ -2011,16 +1921,16 @@ msgid "%s %s `%s': could not set close-on-exec: (fcntl F_SETFD: %s)"
msgstr ""
"%s %s `%s': non riesco a impostare 'close-on-exec': (fcntl F_SETFD: %s)"
-#: profile.c:83
+#: profile.c:69
#, c-format
msgid "could not open `%s' for writing: %s"
msgstr "non riesco ad aprire `%s' in scrittura: %s"
-#: profile.c:85
+#: profile.c:71
msgid "sending profile to standard error"
msgstr "mando profilo a 'standard error'"
-#: profile.c:203
+#: profile.c:187
#, c-format
msgid ""
"\t# %s block(s)\n"
@@ -2029,7 +1939,7 @@ msgstr ""
"\t# blocco(hi) %s\n"
"\n"
-#: profile.c:208
+#: profile.c:192
#, c-format
msgid ""
"\t# Rule(s)\n"
@@ -2038,17 +1948,22 @@ msgstr ""
"\t# Regola(e)\n"
"\n"
-#: profile.c:279
+#: profile.c:266
#, c-format
msgid "internal error: %s with null vname"
msgstr "errore interno: %s con 'vname' nullo"
-#: profile.c:952
+#: profile.c:528
+#, fuzzy
+msgid "internal error: builtin with null fname"
+msgstr "errore interno: %s con 'vname' nullo"
+
+#: profile.c:943
#, c-format
msgid "\t# gawk profile, created %s\n"
msgstr "\t# profilo gawk, creato %s\n"
-#: profile.c:1331
+#: profile.c:1328
#, c-format
msgid ""
"\n"
@@ -2057,17 +1972,17 @@ msgstr ""
"\n"
"\t# Funzioni, listate in ordine alfabetico\n"
-#: profile.c:1370
+#: profile.c:1366
#, c-format
msgid "redir2str: unknown redirection type %d"
msgstr "redir2str: tipo di re-direzione non noto %d"
-#: re.c:573
+#: re.c:571
#, fuzzy, c-format
msgid "range of the form `[%c-%c]' is locale dependent"
msgstr "intervallo nella forma `[%c-%c]' dipende da 'locale'"
-#: re.c:600
+#: re.c:598
#, c-format
msgid "regexp component `%.*s' should probably be `[%.*s]'"
msgstr ""
@@ -2145,6 +2060,80 @@ msgstr ") o \\) non aperta"
msgid "No previous regular expression"
msgstr "Nessuna espressione regolare precedente"
+#~ msgid "attempt to use function `%s' as an array"
+#~ msgstr "tentativo di usare funzione '%s' come vettore"
+
+#~ msgid "reference to uninitialized element `%s[\"%.*s\"]'"
+#~ msgstr "riferimento a elemento non inizializzato `%s[\"%.*s\"]'"
+
+#~ msgid "subscript of array `%s' is null string"
+#~ msgstr "l'indice del vettore '%s' è una stringa nulla"
+
+#~ msgid "%s: empty (null)\n"
+#~ msgstr "%s: vuoto (nullo)\n"
+
+#~ msgid "%s: empty (zero)\n"
+#~ msgstr "%s: vuoto (zero)\n"
+
+#~ msgid "%s: table_size = %d, array_size = %d\n"
+#~ msgstr "%s: dimensione_tabella = %d, dimensione_vettore = %d\n"
+
+#~ msgid "%s: is parameter\n"
+#~ msgstr "%s: è parametro\n"
+
+#~ msgid "%s: array_ref to %s\n"
+#~ msgstr "%s: riferimento_vettoriale a %s\n"
+
+#~ msgid "use of non-array as array"
+#~ msgstr "uso di non-vettore come vettore"
+
+#~ msgid "can't use function name `%s' as variable or array"
+#~ msgstr "non posso usare nome di funzione `%s' come variabile o vettore"
+
+#, fuzzy
+#~ msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
+#~ msgstr "tentativo di usare vettore `%s' in un contesto scalare"
+
+#~ msgid "assignment used in conditional context"
+#~ msgstr "assegnamento usato nel contesto di un test condizionale"
+
+#~ msgid "statement has no effect"
+#~ msgstr "istruzione che non fa nulla"
+
+#~ msgid ""
+#~ "for loop: array `%s' changed size from %ld to %ld during loop execution"
+#~ msgstr ""
+#~ "ciclo for: vettore `%s' ha cambiato dimensione da %ld a %ld durante "
+#~ "l'esecuzione del ciclo"
+
+#~ msgid "function called indirectly through `%s' does not exist"
+#~ msgstr "la funzione chiamata indirettamente tramite `%s' non esiste"
+
+#~ msgid "function `%s' not defined"
+#~ msgstr "funzione `%s' non definita"
+
+#~ msgid "non-redirected `getline' invalid inside `%s' rule"
+#~ msgstr "`getline' non-diretta indefinita dentro regola '%s'"
+
+#~ msgid "error reading input file `%s': %s"
+#~ msgstr "errore leggendo file di input `%s': %s"
+
+#~ msgid "`nextfile' cannot be called from a `%s' rule"
+#~ msgstr "`nextfile' non può essere chiamato da una regola `%s'"
+
+#, fuzzy
+#~ msgid "`exit' cannot be called in the current context"
+#~ msgstr "`next' non può essere chiamato da una regola `%s'"
+
+#~ msgid "`next' cannot be called from a `%s' rule"
+#~ msgstr "`next' non può essere chiamato da una regola `%s'"
+
+#~ msgid "Sorry, don't know how to interpret `%s'"
+#~ msgstr "Spiacente, non so come interpretare `%s'"
+
+#~ msgid "\t-R file\t\t\t--command=file\n"
+#~ msgstr "\t-R file\t\t\t--command=file\n"
+
#~ msgid "could not find groups: %s"
#~ msgstr "non riesco a trovare gruppi: %s"
diff --git a/po/ja.gmo b/po/ja.gmo
index fae94fed..6e20cbfd 100644
--- a/po/ja.gmo
+++ b/po/ja.gmo
Binary files differ
diff --git a/po/ja.po b/po/ja.po
index e6b26803..1f396cd2 100644
--- a/po/ja.po
+++ b/po/ja.po
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: gawk 4.0.0\n"
"Report-Msgid-Bugs-To: arnold@skeeve.com\n"
-"POT-Creation-Date: 2012-03-28 22:03+0200\n"
+"POT-Creation-Date: 2012-04-27 10:06+0300\n"
"PO-Revision-Date: 2011-07-17 08:28+0900\n"
"Last-Translator: Yasuaki Taniguchi <yasuakit@gmail.com>\n"
"Language-Team: Japanese <translation-team-ja@lists.sourceforge.net>\n"
@@ -18,499 +18,456 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=1; plural=0;\n"
-#: array.c:140
+#: array.c:266
#, c-format
msgid "from %s"
msgstr "%s ã‹ã‚‰"
-#: array.c:248
+#: array.c:366
msgid "attempt to use a scalar value as array"
msgstr "スカラー値をé…列ã¨ã—ã¦ä½¿ç”¨ã™ã‚‹è©¦ã¿ã§ã™"
-#: array.c:251
-#, c-format
-msgid "attempt to use function `%s' as an array"
-msgstr "関数 `%s' ã‚’é…列ã¨ã—ã¦ä½¿ç”¨ã™ã‚‹è©¦ã¿ã§ã™"
-
-#: array.c:254
+#: array.c:368
#, c-format
msgid "attempt to use scalar parameter `%s' as an array"
msgstr "スカラー仮引数 `%s' ã‚’é…列ã¨ã—ã¦ä½¿ç”¨ã™ã‚‹è©¦ã¿ã§ã™"
-#: array.c:257
+#: array.c:371
#, c-format
msgid "attempt to use scalar `%s' as an array"
msgstr "スカラー `%s' ã‚’é…列ã¨ã—ã¦ä½¿ç”¨ã™ã‚‹è©¦ã¿ã§ã™"
-#: array.c:302 array.c:707 builtin.c:84 builtin.c:1385 builtin.c:1427
-#: builtin.c:1440 builtin.c:1859 builtin.c:1871 eval.c:1135 eval.c:1139
-#: eval.c:1495 eval.c:1812
+#: array.c:418 array.c:584 builtin.c:85 builtin.c:1560 builtin.c:1602
+#: builtin.c:1615 builtin.c:2041 builtin.c:2053 eval.c:1109 eval.c:1113
+#: eval.c:1508
#, c-format
msgid "attempt to use array `%s' in a scalar context"
msgstr "スカラーコンテキストã§é…列 `%s' を使用ã™ã‚‹è©¦ã¿ã§ã™"
-#: array.c:513
-#, c-format
-msgid "reference to uninitialized element `%s[\"%.*s\"]'"
-msgstr "åˆæœŸåŒ–ã•れã¦ã„ãªã„è¦ç´  `%s[\"%.*s\"]' ã¸ã®å‚ç…§ã§ã™"
-
-#: array.c:519
-#, c-format
-msgid "subscript of array `%s' is null string"
-msgstr "é…列 `%s' ã®æ·»å­—㌠NULL 文字列ã§ã™"
-
-#: array.c:723
+#: array.c:591
#, c-format
msgid "delete: index `%s' not in array `%s'"
msgstr "delete: é…列 `%2$s' 内ã«ã‚¤ãƒ³ãƒ‡ãƒƒã‚¯ã‚¹ `%1$s' ãŒã‚りã¾ã›ã‚“"
-#: array.c:734 eval.c:1865
+#: array.c:605
#, c-format
msgid "attempt to use scalar `%s[\"%.*s\"]' as an array"
msgstr "スカラー `%s[\"%.*s\"]' ã‚’é…列ã¨ã—ã¦ä½¿ç”¨ã™ã‚‹è©¦ã¿ã§ã™"
-#: array.c:910
-#, c-format
-msgid "%s: empty (null)\n"
-msgstr "%s: 空 (null)\n"
-
-#: array.c:915
-#, c-format
-msgid "%s: empty (zero)\n"
-msgstr "%s: 空 (zero)\n"
-
-#: array.c:919
-#, c-format
-msgid "%s: table_size = %d, array_size = %d\n"
-msgstr "%s: テーブルサイズ (table_size) = %d, é…列サイズ (array_size) = %d\n"
-
-#: array.c:954
-#, c-format
-msgid "%s: is parameter\n"
-msgstr "%s: 仮引数ã§ã™\n"
-
-#: array.c:958
-#, c-format
-msgid "%s: array_ref to %s\n"
-msgstr "%s: %s ã¸ã®é…列å‚ç…§ (array_ref) ã§ã™\n"
-
-#: array.c:963
-msgid "adump: argument not an array"
+#: array.c:784
+#, fuzzy
+msgid "adump: first argument not an array"
msgstr "adump: 引数ãŒé…列ã§ã¯ã‚りã¾ã›ã‚“"
-#: array.c:1086
+#: array.c:823
msgid "asort: second argument not an array"
msgstr "asort: 第二引数ãŒé…列ã§ã¯ã‚りã¾ã›ã‚“"
-#: array.c:1087
+#: array.c:824
msgid "asorti: second argument not an array"
msgstr "asorti: 第二引数ãŒé…列ã§ã¯ã‚りã¾ã›ã‚“"
-#: array.c:1094
+#: array.c:831
msgid "asort: first argument not an array"
msgstr "asort: 第一引数ãŒé…列ã§ã¯ã‚りã¾ã›ã‚“"
-#: array.c:1095
+#: array.c:832
msgid "asorti: first argument not an array"
msgstr "asorti: 第一引数ãŒé…列ã§ã¯ã‚りã¾ã›ã‚“"
-#: array.c:1102
+#: array.c:839
msgid "asort: cannot use a subarray of first arg for second arg"
msgstr "asort: 第一引数ã®éƒ¨åˆ†é…列を第二引数用ã«ä½¿ç”¨ã™ã‚‹ã“ã¨ã¯å‡ºæ¥ã¾ã›ã‚“"
-#: array.c:1103
+#: array.c:840
msgid "asorti: cannot use a subarray of first arg for second arg"
msgstr "asorti: 第一引数ã®éƒ¨åˆ†é…列を第二引数用ã«ä½¿ç”¨ã™ã‚‹ã“ã¨ã¯å‡ºæ¥ã¾ã›ã‚“"
-#: array.c:1108
+#: array.c:845
msgid "asort: cannot use a subarray of second arg for first arg"
msgstr "asort: 第二引数ã®éƒ¨åˆ†é…列を第一引数用ã«ä½¿ç”¨ã™ã‚‹ã“ã¨ã¯å‡ºæ¥ã¾ã›ã‚“"
-#: array.c:1109
+#: array.c:846
msgid "asorti: cannot use a subarray of second arg for first arg"
msgstr "asorti: 第二引数ã®éƒ¨åˆ†é…列を第一引数用ã«ä½¿ç”¨ã™ã‚‹ã“ã¨ã¯å‡ºæ¥ã¾ã›ã‚“"
-#: array.c:1655
+#: array.c:1314
#, c-format
msgid "`%s' is invalid as a function name"
msgstr "`%s' ã¯é–¢æ•°åã¨ã—ã¦ã¯ç„¡åйã§ã™"
-#: array.c:1659
+#: array.c:1318
#, c-format
msgid "sort comparison function `%s' is not defined"
msgstr "ソート比較関数 `%s' ãŒå®šç¾©ã•れã¦ã„ã¾ã›ã‚“"
-#: awkgram.y:249
+#: awkgram.y:223
#, c-format
msgid "%s blocks must have an action part"
msgstr "%s ブロックã«ã¯ã‚¢ã‚¯ã‚·ãƒ§ãƒ³éƒ¨ãŒå¿…é ˆã§ã™"
-#: awkgram.y:252
+#: awkgram.y:226
msgid "each rule must have a pattern or an action part"
msgstr "å„ルールã«ã¯ãƒ‘ターンã¾ãŸã¯ã‚¢ã‚¯ã‚·ãƒ§ãƒ³éƒ¨ãŒå¿…é ˆã§ã™ã€‚"
-#: awkgram.y:323 awkgram.y:334
+#: awkgram.y:295 awkgram.y:306
msgid "old awk does not support multiple `BEGIN' or `END' rules"
msgstr "å¤ã„ awk ã¯è¤‡æ•°ã® `BEGIN' ã¾ãŸã¯ `END' ルールをサãƒãƒ¼ãƒˆã—ã¾ã›ã‚“"
-#: awkgram.y:371
+#: awkgram.y:343
#, c-format
msgid "`%s' is a built-in function, it cannot be redefined"
msgstr "`%s' ã¯çµ„è¾¼ã¿é–¢æ•°ã§ã™ã€‚å†å®šç¾©ã§ãã¾ã›ã‚“"
-#: awkgram.y:432
+#: awkgram.y:389
msgid "regexp constant `//' looks like a C++ comment, but is not"
msgstr "æ­£è¦è¡¨ç¾å®šæ•° `//' 㯠C++コメントã«ä¼¼ã¦ã„ã¾ã™ãŒã€é•ã„ã¾ã™ã€‚"
-#: awkgram.y:436
+#: awkgram.y:393
#, c-format
msgid "regexp constant `/%s/' looks like a C comment, but is not"
msgstr "æ­£è¦è¡¨ç¾å®šæ•° `/%s/' 㯠C コメントã«ä¼¼ã¦ã„ã¾ã™ãŒã€ç•°ãªã‚Šã¾ã™"
-#: awkgram.y:528
+#: awkgram.y:485
#, c-format
msgid "duplicate case values in switch body: %s"
msgstr "switch æ–‡ã®ä¸­ã§é‡è¤‡ã—㟠case 値ãŒä½¿ç”¨ã•れã¦ã„ã¾ã™: %s"
-#: awkgram.y:549
+#: awkgram.y:506
msgid "duplicate `default' detected in switch body"
msgstr "switch æ–‡ã®ä¸­ã§é‡è¤‡ã—㟠`default' ãŒæ¤œå‡ºã•れã¾ã—ãŸ"
-#: awkgram.y:809
+#: awkgram.y:766
msgid "`break' is not allowed outside a loop or switch"
msgstr "`break' ã¯ãƒ«ãƒ¼ãƒ—ã¾ãŸã¯ switch ã®å¤–ã§ã¯è¨±å¯ã•れã¦ã„ã¾ã›ã‚“"
-#: awkgram.y:818
+#: awkgram.y:775
msgid "`continue' is not allowed outside a loop"
msgstr "`continue' ã¯ãƒ«ãƒ¼ãƒ—ã®å¤–ã§ã¯è¨±å¯ã•れã¦ã„ã¾ã›ã‚“"
-#: awkgram.y:828
+#: awkgram.y:785
#, c-format
msgid "`next' used in %s action"
msgstr "%s アクション内㧠`next' ãŒä½¿ç”¨ã•れã¾ã—ãŸ"
-#: awkgram.y:836
+#: awkgram.y:793
msgid "`nextfile' is a gawk extension"
msgstr "`nextfile' 㯠gawk æ‹¡å¼µã§ã™"
-#: awkgram.y:841
+#: awkgram.y:798
#, c-format
msgid "`nextfile' used in %s action"
msgstr "`nextfile' ㌠%s アクション内ã§ä½¿ç”¨ã•れã¾ã—ãŸ"
-#: awkgram.y:865
+#: awkgram.y:822
msgid "`return' used outside function context"
msgstr "`return' ãŒé–¢æ•°å®šç¾©æ–‡ã®å¤–ã§ä½¿ã‚れã¾ã—ãŸ"
-#: awkgram.y:925
+#: awkgram.y:896
msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'"
msgstr ""
"BEGIN ã¾ãŸã¯ END ルール内ã®å¼•æ•°ã®ç„¡ã„ `print' 㯠`print \"\"' ã ã¨æ€ã‚れã¾ã™"
-#: awkgram.y:995 awkgram.y:999 awkgram.y:1023
+#: awkgram.y:966 awkgram.y:970 awkgram.y:994
msgid "`delete array' is a gawk extension"
msgstr "`delete array' 㯠gawk æ‹¡å¼µã§ã™"
-#: awkgram.y:1019
+#: awkgram.y:990
msgid "`delete(array)' is a non-portable tawk extension"
msgstr "`delete(array)' ã¯ç§»æ¤æ€§ã®ç„¡ã„ tawk æ‹¡å¼µã§ã™"
-#: awkgram.y:1135
+#: awkgram.y:1108
msgid "multistage two-way pipelines don't work"
msgstr "多段階ã§åŒæ–¹å‘パイプを利用ã—ãŸå¼ã¯ä½¿ç”¨ã§ãã¾ã›ã‚“"
-#: awkgram.y:1238
+#: awkgram.y:1211
msgid "regular expression on right of assignment"
msgstr "æ­£è¦è¡¨ç¾ãŒä»£å…¥å¼ã®å³è¾ºã«ä½¿ç”¨ã•れã¦ã„ã¾ã™"
-#: awkgram.y:1249
+#: awkgram.y:1222
msgid "regular expression on left of `~' or `!~' operator"
msgstr "`~' ã‚„ `!~' 演算å­ã®å·¦è¾ºã«æ­£è¦è¡¨ç¾ãŒä½¿ç”¨ã•れã¦ã„ã¾ã™"
-#: awkgram.y:1265 awkgram.y:1419
+#: awkgram.y:1238 awkgram.y:1389
msgid "old awk does not support the keyword `in' except after `for'"
msgstr "å¤ã„ awk ã§ã¯ `in' 予約語㯠`for' ã®å¾Œã‚’除ãサãƒãƒ¼ãƒˆã—ã¾ã›ã‚“"
-#: awkgram.y:1275
+#: awkgram.y:1248
msgid "regular expression on right of comparison"
msgstr "比較å¼ã®å³è¾ºã«æ­£è¦è¡¨ç¾ãŒä½¿ç”¨ã•れã¦ã„ã¾ã™ã€‚"
-#: awkgram.y:1394
+#: awkgram.y:1364
#, c-format
msgid "`getline var' invalid inside `%s' rule"
msgstr "`%s' ルールã®å†…部ã§ã¯ `getline var' ã¯ç„¡åйã§ã™"
-#: awkgram.y:1397 eval.c:2504
+#: awkgram.y:1367
#, c-format
msgid "`getline' invalid inside `%s' rule"
msgstr "`%s' ルールã®å†…部ã§ã¯ `getline' ã¯ç„¡åйã§ã™"
-#: awkgram.y:1402
+#: awkgram.y:1372
msgid "non-redirected `getline' undefined inside END action"
msgstr "リダイレクトã•れã¦ã„ãªã„ `getline' 㯠END アクションã§ã¯æœªå®šç¾©ã§ã™ã€‚"
-#: awkgram.y:1421
+#: awkgram.y:1391
msgid "old awk does not support multidimensional arrays"
msgstr "å¤ã„ awk ã¯å¤šæ¬¡å…ƒé…列をサãƒãƒ¼ãƒˆã—ã¾ã›ã‚“"
-#: awkgram.y:1517
+#: awkgram.y:1488
msgid "call of `length' without parentheses is not portable"
msgstr "å°æ‹¬å¼§ãŒç„¡ã„ `length' ã¯ç§»æ¤æ€§ãŒã‚りã¾ã›ã‚“"
-#: awkgram.y:1580
+#: awkgram.y:1554
msgid "indirect function calls are a gawk extension"
msgstr "間接関数呼ã³å‡ºã—㯠gawk æ‹¡å¼µã§ã™"
-#: awkgram.y:1593
+#: awkgram.y:1567
#, c-format
msgid "can not use special variable `%s' for indirect function call"
msgstr "特別ãªå¤‰æ•° `%s' ã¯é–“接関数呼ã³å‡ºã—用ã«ã¯ä½¿ç”¨å‡ºæ¥ã¾ã›ã‚“"
-#: awkgram.y:1671
+#: awkgram.y:1645
msgid "invalid subscript expression"
msgstr "添字ã®å¼ãŒç„¡åйã§ã™"
-#: awkgram.y:1711
-msgid "use of non-array as array"
-msgstr "é…列ã§ãªã„ã‚‚ã®ã‚’é…列ã¨ã—ã¦ä½¿ç”¨ã—ã¦ã„ã¾ã™"
-
-#: awkgram.y:1975 awkgram.y:1995 msg.c:98
+#: awkgram.y:1966 awkgram.y:1986 msg.c:112
msgid "warning: "
msgstr "警告: "
-#: awkgram.y:1993 msg.c:130
+#: awkgram.y:1984 msg.c:144
msgid "fatal: "
msgstr "致命的: "
-#: awkgram.y:2043
+#: awkgram.y:2034
msgid "unexpected newline or end of string"
msgstr "予期ã—ãªã„改行ã¾ãŸã¯æ–‡å­—列終端ã§ã™"
-#: awkgram.y:2300 awkgram.y:2358 awkgram.y:2542
+#: awkgram.y:2299 awkgram.y:2357 awkgram.y:2545
#, c-format
msgid "can't open source file `%s' for reading (%s)"
msgstr "ソースファイル `%s' を読ã¿è¾¼ã¿ç”¨ã«é–‹ã‘ã¾ã›ã‚“ (%s)"
-#: awkgram.y:2301 awkgram.y:2359 builtin.c:122
+#: awkgram.y:2300 awkgram.y:2358 builtin.c:124
msgid "reason unknown"
msgstr "åŽŸå› ä¸æ˜Ž"
-#: awkgram.y:2317
+#: awkgram.y:2316
#, c-format
msgid "already included source file `%s'"
msgstr "ソースファイル `%s' ã¯æ—¢ã«èª­ã¿è¾¼ã¾ã‚Œã¦ã„ã¾ã™"
-#: awkgram.y:2343
+#: awkgram.y:2342
msgid "@include is a gawk extension"
msgstr "@include 㯠gawk æ‹¡å¼µã§ã™"
-#: awkgram.y:2349
+#: awkgram.y:2348
msgid "empty filename after @include"
msgstr "@include ã®å¾Œã«ç©ºã®ãƒ•ァイルåãŒã‚りã¾ã™"
-#: awkgram.y:2494
+#: awkgram.y:2497
msgid "empty program text on command line"
msgstr "コマンド行ã®ãƒ—ログラム表記ãŒç©ºã§ã™"
-#: awkgram.y:2609
+#: awkgram.y:2612
#, c-format
msgid "can't read sourcefile `%s' (%s)"
msgstr "ソースファイル `%s' を読ã¿è¾¼ã‚ã¾ã›ã‚“ (%s)"
-#: awkgram.y:2620
+#: awkgram.y:2623
#, c-format
msgid "source file `%s' is empty"
msgstr "ソースファイル `%s' ã¯ç©ºã§ã™"
-#: awkgram.y:2797
+#: awkgram.y:2800
msgid "source file does not end in newline"
msgstr "ã‚½ãƒ¼ã‚¹ãƒ•ã‚¡ã‚¤ãƒ«ãŒæ”¹è¡Œã§çµ‚ã£ã¦ã„ã¾ã›ã‚“"
-#: awkgram.y:2900
+#: awkgram.y:2905
msgid "unterminated regexp ends with `\\' at end of file"
msgstr "終端ã•れã¦ã„ãªã„æ­£è¦è¡¨ç¾ãŒãƒ•ァイル最後㮠`\\' ã§çµ‚ã£ã¦ã„ã¾ã™ã€‚"
-#: awkgram.y:2924
+#: awkgram.y:2929
#, c-format
msgid "%s: %d: tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr "%s: %d: tawk ã®æ­£è¦è¡¨ç¾ä¿®é£¾å­ `/.../%c' 㯠gawk ã§ä½¿ç”¨ã§ãã¾ã›ã‚“"
-#: awkgram.y:2928
+#: awkgram.y:2933
#, c-format
msgid "tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr "tawk ã®æ­£è¦è¡¨ç¾ä¿®é£¾å­ `/.../%c' 㯠gawk ã§ä½¿ç”¨ã§ãã¾ã›ã‚“"
-#: awkgram.y:2935
+#: awkgram.y:2940
msgid "unterminated regexp"
msgstr "æ­£è¦è¡¨ç¾ãŒçµ‚端ã•れã¦ã„ã¾ã›ã‚“"
-#: awkgram.y:2939
+#: awkgram.y:2944
msgid "unterminated regexp at end of file"
msgstr "ファイルã®ä¸­ã§æ­£è¦è¡¨ç¾ãŒçµ‚端ã•れã¦ã„ã¾ã›ã‚“"
-#: awkgram.y:2998
+#: awkgram.y:3003
msgid "use of `\\ #...' line continuation is not portable"
msgstr "`\\ #...' å½¢å¼ã®è¡Œç¶™ç¶šã¯ç§»æ¤æ€§ãŒã‚りã¾ã›ã‚“"
-#: awkgram.y:3014
+#: awkgram.y:3019
msgid "backslash not last character on line"
msgstr "ãƒãƒƒã‚¯ã‚¹ãƒ©ãƒƒã‚·ãƒ¥ãŒè¡Œæœ€å¾Œã®æ–‡å­—ã«ãªã£ã¦ã„ã¾ã›ã‚“。"
-#: awkgram.y:3075
+#: awkgram.y:3080
msgid "POSIX does not allow operator `**='"
msgstr "POSIX ã§ã¯æ¼”ç®—å­ `**=' ã¯è¨±å¯ã•れã¦ã„ã¾ã›ã‚“"
-#: awkgram.y:3077
+#: awkgram.y:3082
msgid "old awk does not support operator `**='"
msgstr "å¤ã„ awk ã¯æ¼”ç®—å­ `**=' をサãƒãƒ¼ãƒˆã—ã¾ã›ã‚“"
-#: awkgram.y:3086
+#: awkgram.y:3091
msgid "POSIX does not allow operator `**'"
msgstr "POSIX ã§ã¯æ¼”ç®—å­ `**' ã¯è¨±å¯ã•れã¦ã„ã¾ã›ã‚“"
-#: awkgram.y:3088
+#: awkgram.y:3093
msgid "old awk does not support operator `**'"
msgstr "å¤ã„ awk ã¯æ¼”ç®—å­ `**' をサãƒãƒ¼ãƒˆã—ã¾ã›ã‚“"
-#: awkgram.y:3123
+#: awkgram.y:3128
msgid "operator `^=' is not supported in old awk"
msgstr "å¤ã„ awk ã¯æ¼”ç®—å­ `^=' をサãƒãƒ¼ãƒˆã—ã¾ã›ã‚“"
-#: awkgram.y:3131
+#: awkgram.y:3136
msgid "operator `^' is not supported in old awk"
msgstr "å¤ã„ awk ã¯æ¼”ç®—å­ `^' をサãƒãƒ¼ãƒˆã—ã¾ã›ã‚“"
-#: awkgram.y:3224 awkgram.y:3240
+#: awkgram.y:3229 awkgram.y:3245
msgid "unterminated string"
msgstr "文字列ãŒçµ‚端ã•れã¦ã„ã¾ã›ã‚“"
-#: awkgram.y:3436
+#: awkgram.y:3466
#, c-format
msgid "invalid char '%c' in expression"
msgstr "å¼å†…ã«ç„¡åŠ¹ãªæ–‡å­— '%c' ãŒã‚りã¾ã™"
-#: awkgram.y:3483
+#: awkgram.y:3513
#, c-format
msgid "`%s' is a gawk extension"
msgstr "`%s' 㯠gawk æ‹¡å¼µã§ã™"
-#: awkgram.y:3488
+#: awkgram.y:3518
#, c-format
msgid "`%s' is a Bell Labs extension"
msgstr "`%s' ã¯ãƒ™ãƒ«ç ”究所ã«ã‚ˆã‚‹æ‹¡å¼µã§ã™"
-#: awkgram.y:3493
+#: awkgram.y:3523
#, c-format
msgid "POSIX does not allow `%s'"
msgstr "POSIX ã§ã¯ `%s' ã¯è¨±å¯ã•れã¦ã„ã¾ã›ã‚“"
-#: awkgram.y:3501
+#: awkgram.y:3531
#, c-format
msgid "`%s' is not supported in old awk"
msgstr "å¤ã„ awk 㯠`%s' をサãƒãƒ¼ãƒˆã—ã¾ã›ã‚“"
-#: awkgram.y:3568
+#: awkgram.y:3598
msgid "`goto' considered harmful!\n"
msgstr "`goto' ã¯æœ‰å®³ã ã¨è¦‹ãªã•れã¦ã„ã¾ã™!\n"
-#: awkgram.y:3619
+#: awkgram.y:3632
#, c-format
msgid "%d is invalid as number of arguments for %s"
msgstr "%d 㯠%s 用ã®å¼•æ•°ã®æ•°ã¨ã—ã¦ã¯ç„¡åйã§ã™"
-#: awkgram.y:3654
+#: awkgram.y:3667
#, c-format
msgid "%s: string literal as last arg of substitute has no effect"
msgstr "%s: æ–‡å­—åˆ—ãƒªãƒ†ãƒ©ãƒ«ã‚’ç½®ãæ›ãˆæœ€å¾Œã®å¼•æ•°ã«ä½¿ç”¨ã™ã‚‹ã¨åŠ¹æžœãŒã‚りã¾ã›ã‚“"
-#: awkgram.y:3659
+#: awkgram.y:3672
#, c-format
msgid "%s third parameter is not a changeable object"
msgstr "%s 第三仮引数ã¯å¯å¤‰ã‚ªãƒ–ジェクトã§ã¯ã‚りã¾ã›ã‚“"
-#: awkgram.y:3732 awkgram.y:3735
+#: awkgram.y:3751 awkgram.y:3754
msgid "match: third argument is a gawk extension"
msgstr "match: 第三引数㯠gawk æ‹¡å¼µã§ã™"
-#: awkgram.y:3789 awkgram.y:3792
+#: awkgram.y:3808 awkgram.y:3811
msgid "close: second argument is a gawk extension"
msgstr "close: 第二引数㯠gawk æ‹¡å¼µã§ã™"
-#: awkgram.y:3804
+#: awkgram.y:3823
msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore"
msgstr ""
"dcgettext(_\"...\")ã®ä½¿ç”¨æ³•ãŒé–“é•ã£ã¦ã„ã¾ã™: 先頭ã®ã‚¢ãƒ³ãƒ€ãƒ¼ã‚¹ã‚³ã‚¢(_)を削除ã—"
"ã¦ãã ã•ã„"
-#: awkgram.y:3819
+#: awkgram.y:3838
msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore"
msgstr ""
"dcngettext(_\"...\")ã®ä½¿ç”¨æ³•ãŒé–“é•ã£ã¦ã„ã¾ã™: 先頭ã®ã‚¢ãƒ³ãƒ€ãƒ¼ã‚¹ã‚³ã‚¢(_)を削除ã—"
"ã¦ãã ã•ã„"
-#: awkgram.y:3911
-#, c-format
-msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
-msgstr "関数 `%s': 仮引数 #%d, `%s' ãŒä»®å¼•æ•° #%d ã¨é‡è¤‡ã—ã¦ã„ã¾ã™"
-
-#: awkgram.y:3953
+#: awkgram.y:3904
#, c-format
msgid "function `%s': parameter `%s' shadows global variable"
msgstr "関数 `%s': 仮引数 `%s' ãŒå¤§åŸŸå¤‰æ•°ã‚’覆ã„éš ã—ã¦ã„ã¾ã™"
-#: awkgram.y:4111
+#: awkgram.y:3961
#, c-format
msgid "could not open `%s' for writing (%s)"
msgstr "`%s' を書込ã¿ç”¨ã«é–‹ã‘ã¾ã›ã‚“ã§ã—㟠(%s)"
-#: awkgram.y:4112
+#: awkgram.y:3962
msgid "sending variable list to standard error"
msgstr "変数リストを標準エラーã«é€ã£ã¦ã„ã¾ã™"
-#: awkgram.y:4118
+#: awkgram.y:3970
#, c-format
msgid "%s: close failed (%s)"
msgstr "%s: é–‰ã˜ã‚‹ã®ã«å¤±æ•—ã—ã¾ã—㟠(%s)"
-#: awkgram.y:4170
+#: awkgram.y:3995
msgid "shadow_funcs() called twice!"
msgstr "shadow_funcs() を二回呼ã³å‡ºã—ã¦ã„ã¾ã™!"
-#: awkgram.y:4176
+#: awkgram.y:4003
msgid "there were shadowed variables."
msgstr "覆ã„éš ã•れãŸå¤‰æ•°ãŒã‚りã¾ã—ãŸ"
-#: awkgram.y:4206
+#: awkgram.y:4074
+#, c-format
+msgid "function name `%s' previously defined"
+msgstr "関数å `%s' ã¯å‰ã«å®šç¾©ã•れã¦ã„ã¾ã™"
+
+#: awkgram.y:4120
#, c-format
msgid "function `%s': can't use function name as parameter name"
msgstr "関数 `%s': 関数åを仮引数åã¨ã—ã¦ä½¿ç”¨å‡ºæ¥ã¾ã›ã‚“"
-#: awkgram.y:4210
+#: awkgram.y:4123
#, c-format
msgid "function `%s': can't use special variable `%s' as a function parameter"
msgstr "関数 `%s': 特別ãªå¤‰æ•° `%s' ã¯é–¢æ•°ã®ä»®å¼•æ•°ã¨ã—ã¦ä½¿ç”¨å‡ºæ¥ã¾ã›ã‚“"
-#: awkgram.y:4226
+#: awkgram.y:4131
#, c-format
-msgid "function name `%s' previously defined"
-msgstr "関数å `%s' ã¯å‰ã«å®šç¾©ã•れã¦ã„ã¾ã™"
+msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
+msgstr "関数 `%s': 仮引数 #%d, `%s' ãŒä»®å¼•æ•° #%d ã¨é‡è¤‡ã—ã¦ã„ã¾ã™"
-#: awkgram.y:4394 awkgram.y:4400
+#: awkgram.y:4210 awkgram.y:4216
#, c-format
msgid "function `%s' called but never defined"
msgstr "未定義ã®é–¢æ•° `%s' を呼ã³å‡ºã—ã¾ã—ãŸ"
-#: awkgram.y:4403
+#: awkgram.y:4219
#, c-format
msgid "function `%s' defined but never called directly"
msgstr "関数 `%s' ã¯å®šç¾©ã•れã¦ã„ã¾ã™ãŒã€ä¸€åº¦ã‚‚直接呼ã³å‡ºã•れã¦ã„ã¾ã›ã‚“"
-#: awkgram.y:4435
+#: awkgram.y:4251
#, c-format
msgid "regexp constant for parameter #%d yields boolean value"
msgstr "仮引数 #%d ç”¨ã®æ­£è¦è¡¨ç¾å®šæ•°ã¯çœŸå½å€¤ã‚’出力ã—ã¾ã™"
-#: awkgram.y:4544
+#: awkgram.y:4297
#, c-format
msgid ""
"function `%s' called with space between name and `(',\n"
@@ -519,230 +476,230 @@ msgstr ""
"関数å㨠`(' ã®é–“ã«ã‚¹ãƒšãƒ¼ã‚¹ã‚’入れã¦é–¢æ•° `%s' を呼ã³å‡ºã—ã¦ã„ã¾ã™ã€‚\n"
"ã¾ãŸã¯ã€å¤‰æ•°ã‹é…列ã¨ã—ã¦ä½¿ã‚れã¦ã„ã¾ã™ã€‚"
-#: awkgram.y:4791 eval.c:2056
+#: awkgram.y:4505
msgid "division by zero attempted"
msgstr "ゼロã«ã‚ˆã‚‹é™¤ç®—ãŒè©¦ã¿ã‚‰ã‚Œã¾ã—ãŸ"
-#: awkgram.y:4800 eval.c:2072
+#: awkgram.y:4514
#, c-format
msgid "division by zero attempted in `%%'"
msgstr "`%%' 内ã§ã‚¼ãƒ­ã«ã‚ˆã‚‹é™¤ç®—ãŒè©¦ã¿ã‚‰ã‚Œã¾ã—ãŸ"
-#: builtin.c:120
+#: builtin.c:122
#, c-format
msgid "%s to \"%s\" failed (%s)"
msgstr "%s ã‹ã‚‰ \"%s\" ã¸å‡ºåŠ›ã§ãã¾ã›ã‚“ (%s)。"
-#: builtin.c:121
+#: builtin.c:123
msgid "standard output"
msgstr "標準出力"
-#: builtin.c:135
+#: builtin.c:137
msgid "exp: received non-numeric argument"
msgstr "exp: å¼•æ•°ãŒæ•°å€¤ã§ã¯ã‚りã¾ã›ã‚“"
-#: builtin.c:141
+#: builtin.c:143
#, c-format
msgid "exp: argument %g is out of range"
msgstr "exp: 引数 %g ãŒç¯„囲外ã§ã™"
-#: builtin.c:200
+#: builtin.c:202
#, c-format
msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing"
msgstr ""
"fflush: flush ã§ãã¾ã›ã‚“: パイプ `%s' ã¯èª­ã¿è¾¼ã¿ç”¨ã«é–‹ã‹ã‚Œã¦ã„ã¾ã™ã€‚書ãè¾¼ã¿"
"用ã§ã¯ã‚りã¾ã›ã‚“"
-#: builtin.c:203
+#: builtin.c:205
#, c-format
msgid "fflush: cannot flush: file `%s' opened for reading, not writing"
msgstr ""
"fflush: flush ã§ãã¾ã›ã‚“: ファイル `%s' ã¯èª­ã¿è¾¼ã¿ç”¨ã«é–‹ã‹ã‚Œã¦ã„ã¾ã™ã€‚書ãè¾¼"
"ã¿ç”¨ã§ã¯ã‚りã¾ã›ã‚“"
-#: builtin.c:215
+#: builtin.c:217
#, c-format
msgid "fflush: `%s' is not an open file, pipe or co-process"
msgstr "fflush: `%s' ãŒé–‹ã‹ã‚ŒãŸãƒ•ァイルã€ãƒ‘イプã€ãƒ—ロセス共有ã§ã¯ã‚りã¾ã›ã‚“"
-#: builtin.c:333
+#: builtin.c:335
msgid "index: received non-string first argument"
msgstr "index: 文字列ã§ã¯ç„¡ã„第一引数をå—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:335
+#: builtin.c:337
msgid "index: received non-string second argument"
msgstr "index: 文字列ã§ã¯ç„¡ã„第二引数をå—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:457
+#: builtin.c:461
msgid "int: received non-numeric argument"
msgstr "int: 数値ã§ã¯ç„¡ã„引数をå—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:493
+#: builtin.c:497
msgid "length: received array argument"
msgstr "length: é…列引数をå—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:496
+#: builtin.c:500
msgid "`length(array)' is a gawk extension"
msgstr "`length(array)' 㯠gawk æ‹¡å¼µã§ã™"
-#: builtin.c:504
+#: builtin.c:508
msgid "length: received non-string argument"
msgstr "length: 文字列ã§ã¯ç„¡ã„引数をå—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:535
+#: builtin.c:539
msgid "log: received non-numeric argument"
msgstr "log: 数値ã§ã¯ç„¡ã„引数をå—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:538
+#: builtin.c:542
#, c-format
msgid "log: received negative argument %g"
msgstr "log: è² ã®å¼•æ•° %g ã‚’å—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:694 builtin.c:699
+#: builtin.c:740 builtin.c:745
msgid "fatal: must use `count$' on all formats or none"
msgstr ""
"致命的: `count$’ ã¯å…¨ã¦ã®æ›¸å¼ä½¿ç”¨ã™ã‚‹ã€ã¾ãŸã¯å…¨ã¦ã«ä½¿ç”¨ã—ãªã„ã®ã„ãšã‚Œã‹ã§ãªã‘"
"れã°ã„ã‘ã¾ã›ã‚“"
-#: builtin.c:762
+#: builtin.c:815
#, c-format
msgid "field width is ignored for `%%' specifier"
msgstr "`%%' 指定用ã®ãƒ•ィールド幅ã¯ç„¡è¦–ã•れã¾ã™"
-#: builtin.c:764
+#: builtin.c:817
#, c-format
msgid "precision is ignored for `%%' specifier"
msgstr "`%%' 指定用ã®ãƒ•ィールド幅ã¯ç„¡è¦–ã•れã¾ã™"
-#: builtin.c:766
+#: builtin.c:819
#, c-format
msgid "field width and precision are ignored for `%%' specifier"
msgstr "`%%' 指定用ã®ãƒ•ィールド幅ãŠã‚ˆã³ç²¾åº¦ã¯ç„¡è¦–ã•れã¾ã™"
-#: builtin.c:817
+#: builtin.c:870
msgid "fatal: `$' is not permitted in awk formats"
msgstr "致命的: `$' 㯠awk å½¢å¼å†…ã§ã¯è¨±å¯ã•れã¦ã„ã¾ã›ã‚“"
-#: builtin.c:826
+#: builtin.c:879
msgid "fatal: arg count with `$' must be > 0"
msgstr "致命的: `$' ã§æŒ‡å®šã™ã‚‹å¼•æ•°ã®ç•ªå·ã¯æ­£ã§ãªã‘れã°ã„ã‘ã¾ã›ã‚“"
-#: builtin.c:830
+#: builtin.c:883
#, c-format
msgid "fatal: arg count %ld greater than total number of supplied arguments"
msgstr "致命的: 引数ã®ç•ªå· %ld ã¯å¼•æ•°ã¨ã—ã¦ä¸Žãˆã‚‰ã‚ŒãŸæ•°ã‚ˆã‚Šå¤§ãã„ã§ã™"
-#: builtin.c:834
+#: builtin.c:887
msgid "fatal: `$' not permitted after period in format"
msgstr "致命的: `$' ã¯æ›¸å¼æŒ‡å®šå†…ã®ãƒ”リオド `.' ã®å¾Œã«ä½¿ç”¨ã§ãã¾ã›ã‚“"
-#: builtin.c:850
+#: builtin.c:903
msgid "fatal: no `$' supplied for positional field width or precision"
msgstr "致命的: フィールド幅ã€ã¾ãŸã¯ç²¾åº¦ã®æŒ‡å®šå­ã« `$' ãŒä¸Žãˆã‚‰ã‚Œã¦ã„ã¾ã›ã‚“"
-#: builtin.c:921
+#: builtin.c:975
msgid "`l' is meaningless in awk formats; ignored"
msgstr "awk ã®æ›¸å¼æŒ‡å®šã§ã¯ `l' ã¯ç„¡æ„味ã§ã™ã€‚無視ã—ã¾ã™"
-#: builtin.c:925
+#: builtin.c:979
msgid "fatal: `l' is not permitted in POSIX awk formats"
msgstr "致命的: POSIX awk 書å¼å†…ã§ã¯ `l' ã¯è¨±å¯ã•れã¦ã„ã¾ã›ã‚“"
-#: builtin.c:938
+#: builtin.c:992
msgid "`L' is meaningless in awk formats; ignored"
msgstr "awk ã®æ›¸å¼æŒ‡å®šã§ã¯ `L' ã¯ç„¡æ„味ã§ã™ã€‚無視ã—ã¾ã™ã€‚"
-#: builtin.c:942
+#: builtin.c:996
msgid "fatal: `L' is not permitted in POSIX awk formats"
msgstr "致命的: POSIX awk 書å¼å†…ã§ã¯ `L' ã¯è¨±å¯ã•れã¦ã„ã¾ã›ã‚“"
-#: builtin.c:955
+#: builtin.c:1009
msgid "`h' is meaningless in awk formats; ignored"
msgstr "awk ã®æ›¸å¼æŒ‡å®šã§ã¯ `h' ã¯ç„¡æ„味ã§ã™ã€‚無視ã—ã¾ã™ã€‚"
-#: builtin.c:959
+#: builtin.c:1013
msgid "fatal: `h' is not permitted in POSIX awk formats"
msgstr "致命的: POSIX awk 書å¼å†…ã§ã¯ `h' ã¯è¨±å¯ã•れã¦ã„ã¾ã›ã‚“"
-#: builtin.c:1272
+#: builtin.c:1408
#, c-format
msgid "[s]printf: value %g is out of range for `%%%c' format"
msgstr "[s]printf: 値 %g ã¯æ›¸å¼ `%%%c' ã®ç¯„囲外ã§ã™"
-#: builtin.c:1332
+#: builtin.c:1506
#, c-format
msgid "ignoring unknown format specifier character `%c': no argument converted"
msgstr "䏿˜Žãªæ›¸å¼æŒ‡å®šæ–‡å­— `%c' を無視ã—ã¦ã„ã¾ã™: 変æ›ã•れる引数ã¯ã‚りã¾ã›ã‚“"
-#: builtin.c:1337
+#: builtin.c:1511
msgid "fatal: not enough arguments to satisfy format string"
msgstr "致命的: æ›¸å¼æ–‡å­—列を満ãŸã™ååˆ†ãªæ•°ã®å¼•æ•°ãŒã‚りã¾ã›ã‚“"
-#: builtin.c:1339
+#: builtin.c:1513
msgid "^ ran out for this one"
msgstr "^ ã“ã“ã‹ã‚‰è¶³ã‚Šã¾ã›ã‚“"
-#: builtin.c:1346
+#: builtin.c:1520
msgid "[s]printf: format specifier does not have control letter"
msgstr "[s]printf: æ›¸å¼æŒ‡å®šå­ã«åˆ¶å¾¡æ–‡å­—ãŒã‚りã¾ã›ã‚“"
-#: builtin.c:1349
+#: builtin.c:1523
msgid "too many arguments supplied for format string"
msgstr "æ›¸å¼æ–‡å­—列ã«ä¸Žãˆã‚‰ã‚Œã¦ã„る引数ãŒå¤šã™ãŽã¾ã™"
-#: builtin.c:1423 builtin.c:1434
+#: builtin.c:1598 builtin.c:1609
msgid "printf: no arguments"
msgstr "printf: 引数ãŒã‚りã¾ã›ã‚“"
-#: builtin.c:1475
+#: builtin.c:1650
msgid "sqrt: received non-numeric argument"
msgstr "sqrt: 数値ã§ã¯ç„¡ã„引数をå—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:1479
+#: builtin.c:1654
#, c-format
msgid "sqrt: called with negative argument %g"
msgstr "sqrt: è² ã®å€¤ %g を引数ã«ä½¿ç”¨ã—ã¦å‘¼ã³å‡ºã•れã¾ã—ãŸ"
-#: builtin.c:1503
+#: builtin.c:1685
#, c-format
msgid "substr: length %g is not >= 1"
msgstr "substr: é•·ã• %g ㌠1 以上ã§ã¯ã‚りã¾ã›ã‚“"
-#: builtin.c:1505
+#: builtin.c:1687
#, c-format
msgid "substr: length %g is not >= 0"
msgstr "substr: é•·ã• %g ㌠0 以上ã§ã¯ã‚りã¾ã›ã‚“"
-#: builtin.c:1512
+#: builtin.c:1694
#, c-format
msgid "substr: non-integer length %g will be truncated"
msgstr "substr: 文字数 %g ã®å°æ•°ç‚¹ä»¥ä¸‹ã¯åˆ‡ã‚Šæ¨ã¦ã¾ã™ã€‚"
-#: builtin.c:1517
+#: builtin.c:1699
#, c-format
msgid "substr: length %g too big for string indexing, truncating to %g"
msgstr "substr: 文字数 %g ã¯æœ€å¤§å€¤ã‚’è¶…ãˆã¦ã„ã¾ã™ã€‚%g を使ã„ã¾ã™ã€‚"
-#: builtin.c:1529
+#: builtin.c:1711
#, c-format
msgid "substr: start index %g is invalid, using 1"
msgstr "substr: 開始インデックス %g ãŒç„¡åйã§ã™ã€‚1を使用ã—ã¾ã™"
-#: builtin.c:1534
+#: builtin.c:1716
#, c-format
msgid "substr: non-integer start index %g will be truncated"
msgstr "substr: 開始インデックス %g ãŒéžæ•´æ•°ã®ãŸã‚ã€å€¤ã¯åˆ‡ã‚Šæ¨ã¦ã‚‰ã‚Œã¾ã™"
-#: builtin.c:1559
+#: builtin.c:1741
msgid "substr: source string is zero length"
msgstr "substr: 文字列ã®é•·ã•ãŒã‚¼ãƒ­ã§ã™ã€‚"
-#: builtin.c:1575
+#: builtin.c:1757
#, c-format
msgid "substr: start index %g is past end of string"
msgstr "substr: 開始インデックス %g ãŒæ–‡å­—列終端ã®å¾Œã«ã‚りã¾ã™"
-#: builtin.c:1583
+#: builtin.c:1765
#, c-format
msgid ""
"substr: length %g at start index %g exceeds length of first argument (%lu)"
@@ -750,227 +707,222 @@ msgstr ""
"substr: 開始インデックス %2$g ã‹ã‚‰ã®é•·ã• %1$g ã¯ç¬¬ä¸€å¼•æ•°ã®é•·ã•ã‚’è¶…ãˆã¦ã„ã¾ã™ "
"(%3$lu)"
-#: builtin.c:1657
+#: builtin.c:1839
msgid "strftime: format value in PROCINFO[\"strftime\"] has numeric type"
msgstr "strftime: PROCINFO[\"strftime\"] ã®æ›¸å¼ã®å€¤ã¯æ•°å€¤åž‹ã§ã™"
-#: builtin.c:1680
+#: builtin.c:1862
msgid "strftime: received non-numeric second argument"
msgstr "strftime: éžæ•°å€¤ã®ç¬¬äºŒå¼•æ•°ã‚’å—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:1683
+#: builtin.c:1866
msgid "strftime: second argument less than 0 or too big for time_t"
msgstr ""
-#: builtin.c:1690
+#: builtin.c:1873
msgid "strftime: received non-string first argument"
msgstr "strftime: éžæ–‡å­—列ã®ç¬¬ä¸€å¼•æ•°ã‚’å—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:1696
+#: builtin.c:1880
msgid "strftime: received empty format string"
msgstr "strftime: ç©ºã®æ›¸å¼æ–‡å­—列をå—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:1762
+#: builtin.c:1946
msgid "mktime: received non-string argument"
msgstr "mktime: éžæ–‡å­—列引数をå—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:1779
+#: builtin.c:1963
msgid "mktime: at least one of the values is out of the default range"
msgstr "mktime: 一ã¤ä»¥ä¸Šã®å€¤ãŒãƒ‡ãƒ•ォルトã®ç¯„囲を超ãˆã¦ã„ã¾ã™"
-#: builtin.c:1814
+#: builtin.c:1998
msgid "'system' function not allowed in sandbox mode"
msgstr "サンドボックスモードã§ã¯ 'system' 関数ã¯è¨±å¯ã•れã¦ã„ã¾ã›ã‚“"
-#: builtin.c:1819
+#: builtin.c:2003
msgid "system: received non-string argument"
msgstr "system: 文字列ã§ã¯ç„¡ã„引数をå—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:1874 eval.c:1159 eval.c:1790 eval.c:1803
-#, c-format
-msgid "reference to uninitialized variable `%s'"
-msgstr "åˆæœŸåŒ–ã•れã¦ã„ãªã„変数 `%s' ã¸ã®å‚ç…§ã§ã™"
-
-#: builtin.c:1941
+#: builtin.c:2121
#, c-format
msgid "reference to uninitialized field `$%d'"
msgstr "åˆæœŸåŒ–ã•れã¦ã„ãªã„フィールド `$%d' ã¸ã®å‚ç…§ã§ã™"
-#: builtin.c:2028
+#: builtin.c:2208
msgid "tolower: received non-string argument"
msgstr "tolower: éžæ–‡å­—列引数をå—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:2062
+#: builtin.c:2242
msgid "toupper: received non-string argument"
msgstr "toupper: éžæ–‡å­—列引数をå—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:2098
+#: builtin.c:2278
msgid "atan2: received non-numeric first argument"
msgstr "atan2: éžæ•°å€¤ã®ç¬¬ä¸€å¼•æ•°ã‚’å—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:2100
+#: builtin.c:2280
msgid "atan2: received non-numeric second argument"
msgstr "atan2: éžæ•°å€¤ã®ç¬¬äºŒå¼•æ•°ã‚’å—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:2119
+#: builtin.c:2299
msgid "sin: received non-numeric argument"
msgstr "sin: éžæ•°å€¤ã®å¼•æ•°ã‚’å—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:2135
+#: builtin.c:2315
msgid "cos: received non-numeric argument"
msgstr "cos: éžæ•°å€¤ã®å¼•æ•°ã‚’å—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:2188
+#: builtin.c:2368
msgid "srand: received non-numeric argument"
msgstr "srand: éžæ•°å€¤ã®å¼•æ•°ã‚’å—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:2219
+#: builtin.c:2399
msgid "match: third argument is not an array"
msgstr "match: 第三引数ãŒé…列ã§ã¯ã‚りã¾ã›ã‚“"
-#: builtin.c:2483
+#: builtin.c:2664
msgid "gensub: third argument of 0 treated as 1"
msgstr "gensub: 第三引数㌠0 ã§ã™ã€‚1 を代ã‚りã«ä½¿ç”¨ã—ã¾ã™"
-#: builtin.c:2776
+#: builtin.c:2957
msgid "lshift: received non-numeric first argument"
msgstr "lshift: éžæ•°å€¤ã®ç¬¬ä¸€å¼•æ•°ã‚’å—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:2778
+#: builtin.c:2959
msgid "lshift: received non-numeric second argument"
msgstr "lshift: éžæ•°å€¤ã®ç¬¬äºŒå¼•æ•°ã‚’å—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:2784
+#: builtin.c:2965
#, c-format
msgid "lshift(%lf, %lf): negative values will give strange results"
msgstr "lshift(%lf, %lf): è² ã®æ•°å€¤ã‚’使用ã™ã‚‹ã¨ç•°å¸¸ãªçµæžœã«ãªã‚Šã¾ã™"
-#: builtin.c:2786
+#: builtin.c:2967
#, c-format
msgid "lshift(%lf, %lf): fractional values will be truncated"
msgstr "lshift(%lf, %lf): å°æ•°ç‚¹ä»¥ä¸‹ã¯åˆ‡ã‚Šæ¨ã¦ã‚‰ã‚Œã¾ã™"
-#: builtin.c:2788
+#: builtin.c:2969
#, c-format
msgid "lshift(%lf, %lf): too large shift value will give strange results"
msgstr "lshift(%lf, %lf): シフト値ãŒå¤§ãéŽãŽã‚‹ã¨ç•°å¸¸ãªçµæžœã«ãªã‚Šã¾ã™"
-#: builtin.c:2813
+#: builtin.c:2994
msgid "rshift: received non-numeric first argument"
msgstr "rshift: éžæ•°å€¤ã®ç¬¬ä¸€å¼•æ•°ã‚’å—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:2815
+#: builtin.c:2996
msgid "rshift: received non-numeric second argument"
msgstr "rshift: éžæ•°å€¤ã®ç¬¬äºŒå¼•æ•°ã‚’å—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:2821
+#: builtin.c:3002
#, c-format
msgid "rshift(%lf, %lf): negative values will give strange results"
msgstr "rshift(%lf, %lf): è² ã®æ•°å€¤ã‚’使用ã™ã‚‹ã¨ç•°å¸¸ãªçµæžœã«ãªã‚Šã¾ã™"
-#: builtin.c:2823
+#: builtin.c:3004
#, c-format
msgid "rshift(%lf, %lf): fractional values will be truncated"
msgstr "rshift(%lf, %lf): å°æ•°ç‚¹ä»¥ä¸‹ã¯åˆ‡ã‚Šæ¨ã¦ã‚‰ã‚Œã¾ã™"
-#: builtin.c:2825
+#: builtin.c:3006
#, c-format
msgid "rshift(%lf, %lf): too large shift value will give strange results"
msgstr "rshift(%lf, %lf): シフト値ãŒå¤§ãéŽãŽã‚‹ã¨ç•°å¸¸ãªçµæžœã«ãªã‚Šã¾ã™"
-#: builtin.c:2850
+#: builtin.c:3031
msgid "and: received non-numeric first argument"
msgstr "and: éžæ•°å€¤ã®ç¬¬ä¸€å¼•æ•°ã‚’å—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:2852
+#: builtin.c:3033
msgid "and: received non-numeric second argument"
msgstr "and: éžæ•°å€¤ã®ç¬¬äºŒå¼•æ•°ã‚’å—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:2858
+#: builtin.c:3039
#, c-format
msgid "and(%lf, %lf): negative values will give strange results"
msgstr "and(%lf, %lf): è² ã®æ•°å€¤ã‚’使用ã™ã‚‹ã¨ç•°å¸¸ãªçµæžœã«ãªã‚Šã¾ã™"
-#: builtin.c:2860
+#: builtin.c:3041
#, c-format
msgid "and(%lf, %lf): fractional values will be truncated"
msgstr "and(%lf, %lf): å°æ•°ç‚¹ä»¥ä¸‹ã¯åˆ‡ã‚Šæ¨ã¦ã‚‰ã‚Œã¾ã™"
-#: builtin.c:2885
+#: builtin.c:3066
msgid "or: received non-numeric first argument"
msgstr "or: éžæ•°å€¤ã®ç¬¬ä¸€å¼•æ•°ã‚’å—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:2887
+#: builtin.c:3068
msgid "or: received non-numeric second argument"
msgstr "or: éžæ•°å€¤ã®ç¬¬äºŒå¼•æ•°ã‚’å—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:2893
+#: builtin.c:3074
#, c-format
msgid "or(%lf, %lf): negative values will give strange results"
msgstr "or(%lf, %lf): è² ã®æ•°å€¤ã‚’使用ã™ã‚‹ã¨ç•°å¸¸ãªçµæžœã«ãªã‚Šã¾ã™"
-#: builtin.c:2895
+#: builtin.c:3076
#, c-format
msgid "or(%lf, %lf): fractional values will be truncated"
msgstr "or(%lf, %lf): å°æ•°ç‚¹ä»¥ä¸‹ã¯åˆ‡ã‚Šæ¨ã¦ã‚‰ã‚Œã¾ã™"
-#: builtin.c:2923
+#: builtin.c:3102
msgid "xor: received non-numeric first argument"
msgstr "xor: éžæ•°å€¤ã®ç¬¬ä¸€å¼•æ•°ã‚’å—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:2925
+#: builtin.c:3104
msgid "xor: received non-numeric second argument"
msgstr "xor: éžæ•°å€¤ã®ç¬¬äºŒå¼•æ•°ã‚’å—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:2931
+#: builtin.c:3110
#, c-format
msgid "xor(%lf, %lf): negative values will give strange results"
msgstr "xor(%lf, %lf): è² ã®æ•°å€¤ã‚’使用ã™ã‚‹ã¨ç•°å¸¸ãªçµæžœã«ãªã‚Šã¾ã™"
-#: builtin.c:2933
+#: builtin.c:3112
#, c-format
msgid "xor(%lf, %lf): fractional values will be truncated"
msgstr "xor(%lf, %lf): å°æ•°ç‚¹ä»¥ä¸‹ã¯åˆ‡ã‚Šæ¨ã¦ã‚‰ã‚Œã¾ã™"
-#: builtin.c:2957 builtin.c:2963
+#: builtin.c:3136
msgid "compl: received non-numeric argument"
msgstr "compl: éžæ•°å€¤ã®å¼•æ•°ã‚’å—ã‘å–りã¾ã—ãŸ"
-#: builtin.c:2965
+#: builtin.c:3142
#, c-format
msgid "compl(%lf): negative value will give strange results"
msgstr "compl(%lf): è² ã®æ•°å€¤ã‚’使用ã™ã‚‹ã¨ç•°å¸¸ãªçµæžœã«ãªã‚Šã¾ã™"
-#: builtin.c:2967
+#: builtin.c:3144
#, c-format
msgid "compl(%lf): fractional value will be truncated"
msgstr "compl(%lf): å°æ•°ç‚¹ä»¥ä¸‹ã¯åˆ‡ã‚Šæ¨ã¦ã‚‰ã‚Œã¾ã™"
-#: builtin.c:3136
+#: builtin.c:3313
#, c-format
msgid "dcgettext: `%s' is not a valid locale category"
msgstr "dcgettext: `%s' ã¯ç„¡åйãªãƒ­ã‚±ãƒ¼ãƒ«åŒºåˆ†ã§ã™"
-#: eval.c:412
+#: eval.c:395
#, c-format
msgid "unknown nodetype %d"
msgstr "䏿˜ŽãªãƒŽãƒ¼ãƒ‰åž‹ %d ã§ã™"
-#: eval.c:423 eval.c:437
+#: eval.c:406 eval.c:420
#, c-format
msgid "unknown opcode %d"
msgstr "䏿˜Žãªã‚ªãƒšã‚³ãƒ¼ãƒ‰ %d ã§ã™"
-#: eval.c:434
+#: eval.c:417
#, c-format
msgid "opcode %s not an operator or keyword"
msgstr "オペコード %s ã¯æ¼”ç®—å­ã¾ãŸã¯äºˆç´„語ã§ã¯ã‚りã¾ã›ã‚“"
-#: eval.c:488
+#: eval.c:472
msgid "buffer overflow in genflags2str"
msgstr "genflags2str 内ã§ãƒãƒƒãƒ•ァオーãƒãƒ¼ãƒ•ローãŒç™ºç”Ÿã—ã¾ã—ãŸ"
-#: eval.c:698
+#: eval.c:675
#, c-format
msgid ""
"\n"
@@ -981,295 +933,239 @@ msgstr ""
"\t# 呼出関数スタック:\n"
"\n"
-#: eval.c:725
+#: eval.c:704
msgid "`IGNORECASE' is a gawk extension"
msgstr "`IGNORECASE' 㯠gawk æ‹¡å¼µã§ã™"
-#: eval.c:754
+#: eval.c:736
msgid "`BINMODE' is a gawk extension"
msgstr "`BINMODE' 㯠gawk æ‹¡å¼µã§ã™"
-#: eval.c:812
+#: eval.c:793
#, c-format
msgid "BINMODE value `%s' is invalid, treated as 3"
msgstr "BINMODE 値 `%s' ã¯ç„¡åйã§ã™ã€‚代ã‚り㫠3 を使用ã—ã¾ã™"
-#: eval.c:902
+#: eval.c:885
#, c-format
msgid "bad `%sFMT' specification `%s'"
msgstr "誤ã£ãŸ `%sFMT' 指定 `%s' ã§ã™"
-#: eval.c:980
+#: eval.c:969
msgid "turning off `--lint' due to assignment to `LINT'"
msgstr "`LINT' ã¸ã®ä»£å…¥ã«å¾“ã„ `--lint' を無効ã«ã—ã¾ã™"
-#: eval.c:1127 eval.c:1777
-#, c-format
-msgid "can't use function name `%s' as variable or array"
-msgstr "関数å `%s' ã¯å¤‰æ•°ã¾ãŸã¯é…列ã¨ã—ã¦ä½¿ç”¨å‡ºæ¥ã¾ã›ã‚“"
-
-#: eval.c:1158 eval.c:1789 eval.c:1802
+#: eval.c:1132
#, c-format
msgid "reference to uninitialized argument `%s'"
msgstr "åˆæœŸåŒ–ã•れã¦ã„ãªã„引数 `%s' ã¸ã®å‚ç…§ã§ã™"
-#: eval.c:1177
+#: eval.c:1133
+#, c-format
+msgid "reference to uninitialized variable `%s'"
+msgstr "åˆæœŸåŒ–ã•れã¦ã„ãªã„変数 `%s' ã¸ã®å‚ç…§ã§ã™"
+
+#: eval.c:1151
msgid "attempt to field reference from non-numeric value"
msgstr "éžæ•°å€¤ã‚’使用ã—ãŸãƒ•イールドå‚ç…§ã®è©¦ã¿ã§ã™"
-#: eval.c:1179
+#: eval.c:1153
msgid "attempt to field reference from null string"
msgstr "NULL 文字列を使用ã—ã¦ãƒ•ィールドã®å‚照を試ã¿ã¦ã„ã¾ã™"
-#: eval.c:1185
+#: eval.c:1161
#, c-format
msgid "attempt to access field %ld"
msgstr "フィールド %ld ã¸ã®ã‚¢ã‚¯ã‚»ã‚¹ã®è©¦ã¿ã§ã™"
-#: eval.c:1194
+#: eval.c:1170
#, c-format
msgid "reference to uninitialized field `$%ld'"
msgstr "åˆæœŸåŒ–ã•れã¦ã„ãªã„フィールド `$%ld' ã¸ã®å‚ç…§ã§ã™"
-#: eval.c:1256
+#: eval.c:1257
#, c-format
msgid "function `%s' called with more arguments than declared"
msgstr "宣言ã•れã¦ã„る数より多ã„引数を使ã£ã¦é–¢æ•° `%s' を呼ã³å‡ºã—ã¾ã—ãŸ"
-#: eval.c:1437
+#: eval.c:1452
#, c-format
msgid "unwind_stack: unexpected type `%s'"
msgstr "unwind_stack: 予期ã—ãªã„åž‹ `%s' ã§ã™"
-#: eval.c:1532
+#: eval.c:1546
msgid "division by zero attempted in `/='"
msgstr "`/=' 内ã§ã‚¼ãƒ­ã«ã‚ˆã‚‹é™¤ç®—ãŒè¡Œã‚れã¾ã—ãŸ"
-#: eval.c:1539
+#: eval.c:1553
#, c-format
msgid "division by zero attempted in `%%='"
msgstr "`%%=' 内ã§ã‚¼ãƒ­ã«ã‚ˆã‚‹é™¤ç®—ãŒè¡Œã‚れã¾ã—ãŸ"
-#: eval.c:1876 eval.c:2122
-#, c-format
-msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
-msgstr "スカラーコンテキスト内ã§é…列 `%s[\"%.*s\"]' ã®ä½¿ç”¨ã®è©¦ã¿ã§ã™"
-
-#: eval.c:1907
-msgid "assignment used in conditional context"
-msgstr "æ¡ä»¶ã‚³ãƒ³ãƒ†ã‚­ã‚¹ãƒˆå†…ã§ä»£å…¥ãŒä½¿ç”¨ã•れã¾ã—ãŸ"
-
-#: eval.c:1911
-msgid "statement has no effect"
-msgstr "æ–‡ã«åŠ¹æžœãŒã‚りã¾ã›ã‚“"
-
-#: eval.c:2343
-#, c-format
-msgid "for loop: array `%s' changed size from %ld to %ld during loop execution"
-msgstr ""
-"for ループ: ループ実行中ã«é…列 `%s' ã®ã‚µã‚¤ã‚ºãŒ %ld ã‹ã‚‰ %ld ã¸å¤‰æ›´ã•れã¾ã—ãŸ"
-
-#: eval.c:2458
-#, c-format
-msgid "function called indirectly through `%s' does not exist"
-msgstr "`%s' を通ã—ã¦é–“接的ã«å‘¼ã³å‡ºã•れãŸé–¢æ•°ãŒå­˜åœ¨ã—ã¾ã›ã‚“"
-
-#: eval.c:2470
-#, c-format
-msgid "function `%s' not defined"
-msgstr "関数 `%s' ã¯å®šç¾©ã•れã¦ã„ã¾ã›ã‚“"
-
-#: eval.c:2511
-#, c-format
-msgid "non-redirected `getline' invalid inside `%s' rule"
-msgstr "`%s' ルールã®å†…å´ã§ã¯ãƒªãƒ€ã‚¤ãƒ¬ã‚¯ãƒˆã•れã¦ã„ãªã„ `getline' ã¯ç„¡åйã§ã™"
-
-#: eval.c:2600
-#, c-format
-msgid "error reading input file `%s': %s"
-msgstr "入力ファイル `%s' を読ã¿è¾¼ã¿ä¸­ã«ã‚¨ãƒ©ãƒ¼ãŒç™ºç”Ÿã—ã¾ã—ãŸ: %s"
-
-#: eval.c:2614
-#, c-format
-msgid "`nextfile' cannot be called from a `%s' rule"
-msgstr "`nextfile' 㯠`%s' ルールã‹ã‚‰å‘¼ã³å‡ºã™ã“ã¨ãŒå‡ºæ¥ã¾ã›ã‚“"
-
-#: eval.c:2661
-#, fuzzy
-msgid "`exit' cannot be called in the current context"
-msgstr "`next' 㯠`%s' ã‹ã‚‰å‘¼ã³å‡ºã™ã“ã¨ãŒå‡ºæ¥ã¾ã›ã‚“"
-
-#: eval.c:2700
-#, c-format
-msgid "`next' cannot be called from a `%s' rule"
-msgstr "`next' 㯠`%s' ã‹ã‚‰å‘¼ã³å‡ºã™ã“ã¨ãŒå‡ºæ¥ã¾ã›ã‚“"
-
-#: eval.c:2766
-#, c-format
-msgid "Sorry, don't know how to interpret `%s'"
-msgstr "申ã—訳ã‚りã¾ã›ã‚“㌠`%s' ã‚’ã©ã®ã‚ˆã†ã«è§£é‡ˆã™ã‚‹ã‹åˆ†ã‹ã‚Šã¾ã›ã‚“"
-
-#: ext.c:54
+#: ext.c:70
msgid "extensions are not allowed in sandbox mode"
msgstr "サンドボックスモード内ã§ã¯æ‹¡å¼µã¯è¨±å¯ã•れã¦ã„ã¾ã›ã‚“"
-#: ext.c:60 ext.c:65
+#: ext.c:73
msgid "`extension' is a gawk extension"
msgstr "`extension' 㯠gawk æ‹¡å¼µã§ã™"
-#: ext.c:75
-#, c-format
-msgid "fatal: extension: cannot open `%s' (%s)\n"
+#: ext.c:80
+#, fuzzy, c-format
+msgid "extension: cannot open library `%s' (%s)\n"
msgstr "致命的: extension: `%s' ã‚’é–‹ãã“ã¨ãŒå‡ºæ¥ã¾ã›ã‚“ (%s)\n"
-#: ext.c:84
-#, c-format
+#: ext.c:86
+#, fuzzy, c-format
msgid ""
-"fatal: extension: library `%s': does not define "
-"`plugin_is_GPL_compatible' (%s)\n"
+"extension: library `%s': does not define `plugin_is_GPL_compatible' (%s)\n"
msgstr ""
"致命的: extension: ライブラリ `%s': `plugin_is_GPL_compatible' ãŒå®šç¾©ã•れã¦ã„"
"ã¾ã›ã‚“ (%s)\n"
-#: ext.c:93
-#, c-format
-msgid "fatal: extension: library `%s': cannot call function `%s' (%s)\n"
+#: ext.c:90
+#, fuzzy, c-format
+msgid "extension: library `%s': cannot call function `%s' (%s)\n"
msgstr ""
"致命的: extension: ライブラリ `%s': 関数 `%s' を呼ã³å‡ºã™ã“ã¨ãŒå‡ºæ¥ã¾ã›ã‚“ "
"(%s)\n"
-#: ext.c:127
+#: ext.c:118
msgid "extension: missing function name"
msgstr "extension: 関数åãŒã‚りã¾ã›ã‚“"
-#: ext.c:132
+#: ext.c:123
#, c-format
msgid "extension: illegal character `%c' in function name `%s'"
msgstr "extension: 関数å `%2$s' ã®ä¸­ã§ä¸æ­£ãªæ–‡å­— `%1$c' ãŒä½¿ç”¨ã•れã¦ã„ã¾ã™"
-#: ext.c:141
+#: ext.c:131
#, c-format
msgid "extension: can't redefine function `%s'"
msgstr "extension: 関数 `%s' ã‚’å†å®šç¾©ã§ãã¾ã›ã‚“"
-#: ext.c:145
+#: ext.c:135
#, c-format
msgid "extension: function `%s' already defined"
msgstr "extension: 関数 `%s' ã¯æ—¢ã«å®šç¾©ã•れã¦ã„ã¾ã™"
-#: ext.c:150
+#: ext.c:139
#, c-format
msgid "extension: function name `%s' previously defined"
msgstr "extension: 関数å `%s' ã¯å‰ã«å®šç¾©ã•れã¦ã„ã¾ã™"
-#: ext.c:152
+#: ext.c:141
#, c-format
msgid "extension: can't use gawk built-in `%s' as function name"
msgstr "extension: gawk ã«çµ„ã¿è¾¼ã¾ã‚Œã¦ã„ã‚‹ `%s' ã¯é–¢æ•°åã¨ã—ã¦ä½¿ç”¨å‡ºæ¥ã¾ã›ã‚“"
-#: ext.c:156
+#: ext.c:144
#, c-format
msgid "make_builtin: negative argument count for function `%s'"
msgstr "make_builtin: 関数 `%s' ã®å¼•æ•°ã®æ•°ãŒè² ã§ã™"
-#: ext.c:259
+#: ext.c:206
#, c-format
msgid "function `%s' defined to take no more than %d argument(s)"
msgstr "関数 `%s' ã«ä½¿ãˆã‚‹å¼•æ•°ã®æ•°ã¯ `%d' 以下ã¨å®šç¾©ã•れã¦ã„ã¾ã™"
-#: ext.c:262
+#: ext.c:209
#, c-format
msgid "function `%s': missing argument #%d"
msgstr "関数 `%s': 引数 #%d ãŒã‚りã¾ã›ã‚“"
-#: ext.c:279
+#: ext.c:226
#, c-format
msgid "function `%s': argument #%d: attempt to use scalar as an array"
msgstr "関数 `%s': 引数 #%d: スカラーをé…列ã¨ã—ã¦ä½¿ç”¨ã™ã‚‹è©¦ã¿ã§ã™"
-#: ext.c:283
+#: ext.c:230
#, c-format
msgid "function `%s': argument #%d: attempt to use array as a scalar"
msgstr "関数 `%s': 引数 #%d: é…列をスカラーã¨ã—ã¦ä½¿ç”¨ã™ã‚‹è©¦ã¿ã§ã™"
-#: ext.c:296
+#: ext.c:244
msgid "Operation Not Supported"
msgstr "ã“ã®æ“作ã¯ã‚µãƒãƒ¼ãƒˆã•れã¦ã„ã¾ã›ã‚“"
-#: field.c:328
+#: ext.c:256
+msgid "dynamic loading of library not supported"
+msgstr ""
+
+#: field.c:339
msgid "NF set to negative value"
msgstr "NF ãŒè² ã®å€¤ã«è¨­å®šã•れã¦ã„ã¾ã™"
-#: field.c:951 field.c:958 field.c:962
+#: field.c:962 field.c:969 field.c:973
msgid "split: fourth argument is a gawk extension"
msgstr "split: 第四引数㯠gawk æ‹¡å¼µã§ã™"
-#: field.c:955
+#: field.c:966
msgid "split: fourth argument is not an array"
msgstr "split: 第四引数ãŒé…列ã§ã¯ã‚りã¾ã›ã‚“"
-#: field.c:969
+#: field.c:980
msgid "split: second argument is not an array"
msgstr "split: 第二引数ãŒé…列ã§ã¯ã‚りã¾ã›ã‚“"
-#: field.c:973
+#: field.c:984
msgid "split: cannot use the same array for second and fourth args"
msgstr "split: 第二引数ã¨ç¬¬å››å¼•æ•°ã«åŒã˜é…列を使用ã™ã‚‹ã“ã¨ã¯å‡ºæ¥ã¾ã›ã‚“"
-#: field.c:978
+#: field.c:989
msgid "split: cannot use a subarray of second arg for fourth arg"
msgstr "split: 第四引数ã«ç¬¬äºŒå¼•æ•°ã®éƒ¨åˆ†é…列を使用ã™ã‚‹ã“ã¨ã¯å‡ºæ¥ã¾ã›ã‚“"
-#: field.c:981
+#: field.c:992
msgid "split: cannot use a subarray of fourth arg for second arg"
msgstr "split: 第二引数ã«ç¬¬å››å¼•æ•°ã®éƒ¨åˆ†é…列を使用ã™ã‚‹ã“ã¨ã¯å‡ºæ¥ã¾ã›ã‚“"
-#: field.c:1010
+#: field.c:1021
msgid "split: null string for third arg is a gawk extension"
msgstr "split: 第三引数㫠NULL 文字列を使用ã™ã‚‹ã“ã¨ã¯ gawk æ‹¡å¼µã§ã™"
-#: field.c:1050
+#: field.c:1061
msgid "patsplit: fourth argument is not an array"
msgstr "patsplit: 第四引数ãŒé…列ã§ã¯ã‚りã¾ã›ã‚“"
-#: field.c:1055
+#: field.c:1066
msgid "patsplit: second argument is not an array"
msgstr "patsplit: 第二引数ãŒé…列ã§ã¯ã‚りã¾ã›ã‚“"
-#: field.c:1061
+#: field.c:1072
msgid "patsplit: third argument must be non-null"
msgstr "patsplit: 第三引数ã¯éž NULL ã§ãªã‘れã°ã„ã‘ã¾ã›ã‚“"
-#: field.c:1065
+#: field.c:1076
msgid "patsplit: cannot use the same array for second and fourth args"
msgstr "patsplit: 第二引数ã¨ç¬¬å››å¼•æ•°ã«åŒã˜é…列を使用ã™ã‚‹ã“ã¨ã¯å‡ºæ¥ã¾ã›ã‚“"
-#: field.c:1070
+#: field.c:1081
msgid "patsplit: cannot use a subarray of second arg for fourth arg"
msgstr "patsplit: 第四引数ã«ç¬¬äºŒå¼•æ•°ã®éƒ¨åˆ†é…列を使用ã™ã‚‹ã“ã¨ã¯å‡ºæ¥ã¾ã›ã‚“"
-#: field.c:1073
+#: field.c:1084
msgid "patsplit: cannot use a subarray of fourth arg for second arg"
msgstr "patsplit: 第二引数ã«ç¬¬å››å¼•æ•°ã®éƒ¨åˆ†é…列を使用ã™ã‚‹ã“ã¨ã¯å‡ºæ¥ã¾ã›ã‚“"
-#: field.c:1110
+#: field.c:1122
msgid "`FIELDWIDTHS' is a gawk extension"
msgstr "`FIELDWIDTHS' 㯠gawk æ‹¡å¼µã§ã™"
-#: field.c:1173
+#: field.c:1186
#, c-format
msgid "invalid FIELDWIDTHS value, near `%s'"
msgstr "`%s' 付近㮠FIELDWIDTHS 値ãŒç„¡åйã§ã™"
-#: field.c:1246
+#: field.c:1259
msgid "null string for `FS' is a gawk extension"
msgstr "`FS' ã« NULL 文字列を使用ã™ã‚‹ã®ã¯ gawk æ‹¡å¼µã§ã™"
-#: field.c:1250
+#: field.c:1263
msgid "old awk does not support regexps as value of `FS'"
msgstr "å¤ã„ awk 㯠`FS' ã®å€¤ã¨ã—ã¦æ­£è¦è¡¨ç¾ã‚’サãƒãƒ¼ãƒˆã—ã¾ã›ã‚“"
-#: field.c:1369
+#: field.c:1382
msgid "`FPAT' is a gawk extension"
msgstr "`FPAT' 㯠gawk æ‹¡å¼µã§ã™"
@@ -1328,465 +1224,480 @@ msgstr "%s: オプション '-W %s' ã¯å¼•æ•°ã‚’å–ã‚‹ã“ã¨ãŒã§ãã¾ã›ã‚“\n
msgid "%s: option '-W %s' requires an argument\n"
msgstr "%s: オプション '-W %s' ã«ã¯å¼•æ•°ãŒå¿…è¦ã§ã™\n"
-#: io.c:280
+#: io.c:326
#, c-format
msgid "command line argument `%s' is a directory: skipped"
msgstr "コマンドライン引数 `%s' ã¯ãƒ‡ã‚£ãƒ¬ã‚¯ãƒˆãƒªã§ã™: スキップã•れã¾ã—ãŸ"
-#: io.c:283 io.c:385
+#: io.c:329 io.c:438
#, c-format
msgid "cannot open file `%s' for reading (%s)"
msgstr "ファイル `%s' を読ã¿è¾¼ã¿ç”¨ã«é–‹ã‘ã¾ã›ã‚“ (%s)"
-#: io.c:501
+#: io.c:568
#, c-format
msgid "close of fd %d (`%s') failed (%s)"
msgstr "fd %d (`%s') ã‚’é–‰ã˜ã‚‹ã“ã¨ãŒã§ãã¾ã›ã‚“ (%s)"
-#: io.c:578
+#: io.c:645
msgid "redirection not allowed in sandbox mode"
msgstr "サンドボックスモード内ã§ã¯ãƒªãƒ€ã‚¤ãƒ¬ã‚¯ãƒˆã¯è¨±å¯ã•れã¦ã„ã¾ã›ã‚“"
-#: io.c:612
+#: io.c:679
#, c-format
msgid "expression in `%s' redirection only has numeric value"
msgstr "`%s' リダイレクトã®å‘½ä»¤å¼ã«æ•°å€¤ã—ã‹è¨˜è¿°ã•れã¦ã„ã¾ã›ã‚“。"
-#: io.c:618
+#: io.c:685
#, c-format
msgid "expression for `%s' redirection has null string value"
msgstr "`%s' リダイレクトã®å‘½ä»¤å¼ãŒç©ºåˆ—ã§ã™ã€‚"
-#: io.c:623
+#: io.c:690
#, c-format
msgid "filename `%s' for `%s' redirection may be result of logical expression"
msgstr ""
"`%2$s' リダイレクトã«è«–ç†æ¼”ç®—ã®çµæžœã¨æ€ã‚れるファイルå `%1$s' ãŒä½¿ã‚れã¦ã„ã¾"
"ã™ã€‚"
-#: io.c:666
+#: io.c:733
#, c-format
msgid "unnecessary mixing of `>' and `>>' for file `%.*s'"
msgstr "ファイル `%.*s' ã§å¿…è¦ä»¥ä¸Šã« `>' 㨠`>>' を組åˆã›ã¦ã„ã¾ã™ã€‚"
-#: io.c:719
+#: io.c:786
#, c-format
msgid "can't open pipe `%s' for output (%s)"
msgstr "出力用ã«ãƒ‘イプ `%s' ã‚’é–‹ã‘ã¾ã›ã‚“ (%s)"
-#: io.c:729
+#: io.c:796
#, c-format
msgid "can't open pipe `%s' for input (%s)"
msgstr "入力用ã«ãƒ‘イプ `%s' ã‚’é–‹ã‘ã¾ã›ã‚“ (%s)"
-#: io.c:752
+#: io.c:819
#, c-format
msgid "can't open two way pipe `%s' for input/output (%s)"
msgstr "入出力用ã®åŒæ–¹å‘パイプ `%s' ãŒé–‹ã‘ã¾ã›ã‚“ (%s)"
-#: io.c:834
+#: io.c:900
#, c-format
msgid "can't redirect from `%s' (%s)"
msgstr "`%s' ã‹ã‚‰ãƒªãƒ€ã‚¤ãƒ¬ã‚¯ãƒˆã§ãã¾ã›ã‚“ (%s)"
-#: io.c:837
+#: io.c:903
#, c-format
msgid "can't redirect to `%s' (%s)"
msgstr "`%s' ã«ãƒªãƒ€ã‚¤ãƒ¬ã‚¯ãƒˆã§ãã¾ã›ã‚“ (%s)"
-#: io.c:888
+#: io.c:954
msgid ""
"reached system limit for open files: starting to multiplex file descriptors"
msgstr ""
"é–‹ã„ã¦ã„ã‚‹ãƒ•ã‚¡ã‚¤ãƒ«ã®æ•°ãŒã‚·ã‚¹ãƒ†ãƒ åˆ¶é™ã«é”ã—ã¾ã—ãŸã€‚ファイル記述å­ã‚’多é‡åŒ–ã—ã¾"
"ã™ã€‚"
-#: io.c:904
+#: io.c:970
#, c-format
msgid "close of `%s' failed (%s)."
msgstr "`%s' ã‚’é–‰ã˜ã‚‹ã®ã«å¤±æ•—ã—ã¾ã—㟠(%s)"
-#: io.c:912
+#: io.c:978
msgid "too many pipes or input files open"
msgstr "é–‹ã„ã¦ã„るパイプã¾ãŸã¯å…¥åŠ›ãƒ•ã‚¡ã‚¤ãƒ«ã®æ•°ãŒå¤šéŽãŽã¾ã™ã€‚"
-#: io.c:934
+#: io.c:1000
msgid "close: second argument must be `to' or `from'"
msgstr "close: 第二引数㯠`to' ã¾ãŸã¯ `from' ã§ãªã‘れã°ã„ã‘ã¾ã›ã‚“"
-#: io.c:951
+#: io.c:1017
#, c-format
msgid "close: `%.*s' is not an open file, pipe or co-process"
msgstr "close: `%.*s' ã¯é–‹ã„ã¦ã„るファイルã€ãƒ‘イプã€ãƒ—ロセス共有ã§ã¯ã‚りã¾ã›ã‚“"
-#: io.c:956
+#: io.c:1022
msgid "close of redirection that was never opened"
msgstr "é–‹ã„ã¦ãªã„リダイレクトを閉ã˜ã‚ˆã†ã¨ã—ã¦ã„ã¾ã™"
-#: io.c:1053
+#: io.c:1120
#, c-format
msgid "close: redirection `%s' not opened with `|&', second argument ignored"
msgstr ""
"close: リダイレクト `%s' 㯠`|&' を使用ã—ã¦é–‹ã‹ã‚Œã¦ã„ã¾ã›ã‚“。第二引数ã¯ç„¡è¦–ã•"
"れã¾ã—ãŸ"
-#: io.c:1069
+#: io.c:1137
#, c-format
msgid "failure status (%d) on pipe close of `%s' (%s)"
msgstr "パイプ `%2$s' ã‚’é–‰ã˜ãŸã¨ãã®çŠ¶æ…‹ã‚³ãƒ¼ãƒ‰ãŒå¤±æ•— (%1$d) ã§ã—㟠(%3$s)。"
-#: io.c:1072
+#: io.c:1140
#, c-format
msgid "failure status (%d) on file close of `%s' (%s)"
msgstr "ファイル `%2$s' ã‚’é–‰ã˜ãŸã¨ãã®çŠ¶æ…‹ã‚³ãƒ¼ãƒ‰ãŒå¤±æ•— (%1$d) ã§ã—㟠(%3$s)。"
-#: io.c:1092
+#: io.c:1160
#, c-format
msgid "no explicit close of socket `%s' provided"
msgstr "ソケット `%s' を明示ã—ã¦é–‰ã˜ã¦ã„ã¾ã›ã‚“。"
-#: io.c:1095
+#: io.c:1163
#, c-format
msgid "no explicit close of co-process `%s' provided"
msgstr "並行プロセス `%s' を明示ã—ã¦é–‰ã˜ã¦ã„ã¾ã›ã‚“。"
-#: io.c:1098
+#: io.c:1166
#, c-format
msgid "no explicit close of pipe `%s' provided"
msgstr "パイプ `%s' を明示ã—ã¦é–‰ã˜ã¦ã„ã¾ã›ã‚“。"
-#: io.c:1101
+#: io.c:1169
#, c-format
msgid "no explicit close of file `%s' provided"
msgstr "ファイル `%s' を明示ã—ã¦é–‰ã˜ã¦ã„ã¾ã›ã‚“。"
-#: io.c:1129 io.c:1184 main.c:794 main.c:831
+#: io.c:1197 io.c:1252 main.c:825 main.c:862
#, c-format
msgid "error writing standard output (%s)"
msgstr "標準出力ã¸ã®æ›¸è¾¼ã¿ã‚¨ãƒ©ãƒ¼ (%s)"
-#: io.c:1133 io.c:1189
+#: io.c:1201 io.c:1257
#, c-format
msgid "error writing standard error (%s)"
msgstr "標準エラーã¸ã®æ›¸è¾¼ã¿ã‚¨ãƒ©ãƒ¼ (%s)"
-#: io.c:1141
+#: io.c:1209
#, c-format
msgid "pipe flush of `%s' failed (%s)."
msgstr "パイプ `%s' をフラッシュã§ãã¾ã›ã‚“ (%s)。"
-#: io.c:1144
+#: io.c:1212
#, c-format
msgid "co-process flush of pipe to `%s' failed (%s)."
msgstr "`%s' ã¸æŽ¥ç¶šã™ã‚‹ãƒ‘イプを並行プロセスã‹ã‚‰ãƒ•ラッシュã§ãã¾ã›ã‚“ (%s)。"
-#: io.c:1147
+#: io.c:1215
#, c-format
msgid "file flush of `%s' failed (%s)."
msgstr "ファイル `%s' をフラッシュã§ãã¾ã›ã‚“ (%s)。"
-#: io.c:1262
+#: io.c:1329
#, c-format
msgid "local port %s invalid in `/inet'"
msgstr "`/inet' 内ã®ãƒ­ãƒ¼ã‚«ãƒ«ãƒãƒ¼ãƒˆ %s ãŒç„¡åйã§ã™"
-#: io.c:1279
+#: io.c:1347
#, c-format
msgid "remote host and port information (%s, %s) invalid"
msgstr "リモートã®ãƒ›ã‚¹ãƒˆãŠã‚ˆã³ãƒãƒ¼ãƒˆæƒ…å ± (%s, %s) ãŒç„¡åйã§ã™"
-#: io.c:1431
+#: io.c:1499
#, c-format
msgid "no (known) protocol supplied in special filename `%s'"
msgstr ""
"スペシャルファイルå `%s' ã«ï¼ˆèªè­˜ã§ãã‚‹ï¼‰ãƒ—ãƒ­ãƒˆã‚³ãƒ«ãŒæŒ‡å®šã•れã¦ã„ã¾ã›ã‚“"
-#: io.c:1445
+#: io.c:1513
#, c-format
msgid "special file name `%s' is incomplete"
msgstr "スペシャルファイルå `%s' ã¯ä¸å®Œå…¨ã§ã™"
-#: io.c:1462
+#: io.c:1530
msgid "must supply a remote hostname to `/inet'"
msgstr "`/inet' ã«ã¯ãƒªãƒ¢ãƒ¼ãƒˆãƒ›ã‚¹ãƒˆåを与ãˆãªã‘れã°ã„ã‘ã¾ã›ã‚“"
-#: io.c:1480
+#: io.c:1548
msgid "must supply a remote port to `/inet'"
msgstr "`/inet' ã«ã¯ãƒªãƒ¢ãƒ¼ãƒˆãƒãƒ¼ãƒˆç•ªå·ã‚’与ãˆãªã‘れã°ã„ã‘ã¾ã›ã‚“"
-#: io.c:1526
+#: io.c:1594
msgid "TCP/IP communications are not supported"
msgstr "TCP/IP 通信ã¯ã‚µãƒãƒ¼ãƒˆã•れã¦ã„ã¾ã›ã‚“"
-#: io.c:1693
+#: io.c:1764
#, c-format
msgid "could not open `%s', mode `%s'"
msgstr "`%s' をモード `%s' ã§é–‹ã‘ã¾ã›ã‚“"
-#: io.c:1747
+#: io.c:1814
#, c-format
msgid "close of master pty failed (%s)"
msgstr "マスター pty ã‚’é–‰ã˜ã‚‹ã®ã«å¤±æ•—ã—ã¾ã—㟠(%s)"
-#: io.c:1749 io.c:1917 io.c:2074
+#: io.c:1816 io.c:1984 io.c:2145
#, c-format
msgid "close of stdout in child failed (%s)"
msgstr "å­ãƒ—ãƒ­ã‚»ã‚¹ãŒæ¨™æº–出力を閉ã˜ã‚‹ã®ã«å¤±æ•—ã—ã¾ã—㟠(%s)"
-#: io.c:1752
+#: io.c:1819
#, c-format
msgid "moving slave pty to stdout in child failed (dup: %s)"
msgstr "å­ãƒ—ロセスãŒã‚¹ãƒ¬ãƒ¼ãƒ– pty を標準出力ã«ç§»å‹•ã§ãã¾ã›ã‚“ (dup: %s)。"
-#: io.c:1754 io.c:1922
+#: io.c:1821 io.c:1989
#, c-format
msgid "close of stdin in child failed (%s)"
msgstr "å­ãƒ—ãƒ­ã‚»ã‚¹ãŒæ¨™æº–入力を閉ã˜ã‚‰ã‚Œã¾ã›ã‚“ (%s)。"
-#: io.c:1757
+#: io.c:1824
#, c-format
msgid "moving slave pty to stdin in child failed (dup: %s)"
msgstr "å­ãƒ—ロセスãŒã‚¹ãƒ¬ãƒ¼ãƒ– pty を標準入力ã«ç§»å‹•ã§ãã¾ã›ã‚“ (dup: %s)。"
-#: io.c:1759 io.c:1780
+#: io.c:1826 io.c:1847
#, c-format
msgid "close of slave pty failed (%s)"
msgstr "スレーブ pty ã‚’é–‰ã˜ã‚‹ã®ã«å¤±æ•—ã—ã¾ã—㟠(%s)"
-#: io.c:1858 io.c:1920 io.c:2052 io.c:2077
+#: io.c:1925 io.c:1987 io.c:2122 io.c:2148
#, c-format
msgid "moving pipe to stdout in child failed (dup: %s)"
msgstr "å­ãƒ—ロセスãŒãƒ‘イプを標準出力ã«ç§»å‹•ã§ãã¾ã›ã‚“ (dup: %s)。"
-#: io.c:1865 io.c:1925
+#: io.c:1932 io.c:1992
#, c-format
msgid "moving pipe to stdin in child failed (dup: %s)"
msgstr "å­ãƒ—ロセスãŒãƒ‘イプを標準入力ã«ç§»å‹•ã§ãã¾ã›ã‚“ (dup: %s)。"
-#: io.c:1885 io.c:2067
+#: io.c:1952 io.c:2138
msgid "restoring stdout in parent process failed\n"
msgstr "è¦ªãƒ—ãƒ­ã‚»ã‚¹ãŒæ¨™æº–出力を復旧ã§ãã¾ã›ã‚“。\n"
-#: io.c:1893
+#: io.c:1960
msgid "restoring stdin in parent process failed\n"
msgstr "è¦ªãƒ—ãƒ­ã‚»ã‚¹ãŒæ¨™æº–入力を復旧ã§ãã¾ã›ã‚“。\n"
-#: io.c:1928 io.c:2079 io.c:2093
+#: io.c:1995 io.c:2150 io.c:2164
#, c-format
msgid "close of pipe failed (%s)"
msgstr "パイプを閉ã˜ã‚‰ã‚Œã¾ã›ã‚“ (%s)。"
-#: io.c:1973
+#: io.c:2040
msgid "`|&' not supported"
msgstr "`|&' ã¯ä½¿ç”¨ã§ãã¾ã›ã‚“。"
-#: io.c:2039
+#: io.c:2107
#, c-format
msgid "cannot open pipe `%s' (%s)"
msgstr "パイプ `%s' ãŒé–‹ã‘ã¾ã›ã‚“ (%s)。"
-#: io.c:2087
+#: io.c:2158
#, c-format
msgid "cannot create child process for `%s' (fork: %s)"
msgstr "`%s' 用ã®å­ãƒ—ロセスを実行ã§ãã¾ã›ã‚“ (fork: %s)。"
-#: io.c:2520
+#: io.c:2637
#, c-format
msgid "data file `%s' is empty"
msgstr "データファイル `%s' ã¯ç©ºã§ã™ã€‚"
-#: io.c:2561 io.c:2569
+#: io.c:2678 io.c:2686
msgid "could not allocate more input memory"
msgstr "入力用メモリーをã“れ以上確ä¿ã§ãã¾ã›ã‚“。"
-#: io.c:3127
+#: io.c:3236
msgid "multicharacter value of `RS' is a gawk extension"
msgstr "è¤‡æ•°ã®æ–‡å­—ã‚’ `RS' ã«ä½¿ç”¨ã™ã‚‹ã®ã¯ gawk ç‰¹æœ‰ã®æ‹¡å¼µã§ã™ã€‚"
-#: io.c:3232
+#: io.c:3326
msgid "IPv6 communication is not supported"
msgstr "IPv6 通信ã¯ã‚µãƒãƒ¼ãƒˆã•れã¦ã„ã¾ã›ã‚“"
-#: main.c:366
+#: main.c:355
msgid "`-m[fr]' option irrelevant in gawk"
msgstr "gawk ã§ã¯ã‚ªãƒ—ション `-m[fr]' ã«åŠ¹æžœã¯ã‚りã¾ã›ã‚“。"
-#: main.c:368
+#: main.c:357
msgid "-m option usage: `-m[fr] nnn'"
msgstr "-m オプションã®ä½¿ç”¨æ³•: `-m[fr] 数値'"
-#: main.c:391
+#: main.c:386
msgid "empty argument to `-e/--source' ignored"
msgstr "`-e/--source' ã¸ã®ç©ºã®å¼•æ•°ã¯ç„¡è¦–ã•れã¾ã—ãŸ"
-#: main.c:462
+#: main.c:472
#, c-format
msgid "%s: option `-W %s' unrecognized, ignored\n"
msgstr "%s: オプション `-W %s' ã¯èªè­˜ã§ãã¾ã›ã‚“。無視ã•れã¾ã—ãŸ\n"
-#: main.c:515
+#: main.c:518
#, c-format
msgid "%s: option requires an argument -- %c\n"
msgstr "%s: 引数ãŒå¿…è¦ãªã‚ªãƒ—ション -- %c\n"
-#: main.c:536
+#: main.c:539
msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'"
msgstr ""
"環境変数 `POSIXLY_CORRECT' ãŒæŒ‡å®šã•れã¦ã„ã¾ã™ã€‚オプション `--posix' を有効ã«"
"ã—ã¾ã™"
-#: main.c:542
+#: main.c:545
msgid "`--posix' overrides `--traditional'"
msgstr "オプション `--posix' 㯠`--traditional' を無効ã«ã—ã¾ã™ã€‚"
-#: main.c:553
+#: main.c:556
msgid "`--posix'/`--traditional' overrides `--non-decimal-data'"
msgstr ""
"オプション `--posix'/`--traditional' 㯠`--non-decimal-data' を無効ã«ã—ã¾ã™ã€‚"
-#: main.c:557
+#: main.c:560
#, c-format
msgid "running %s setuid root may be a security problem"
msgstr ""
"setuid root ã§ %s を実行ã™ã‚‹ã¨ã€ã‚»ã‚­ãƒ¥ãƒªãƒ†ã‚£ä¸Šã®å•題ãŒç™ºç”Ÿã™ã‚‹å ´åˆãŒã‚りã¾"
"ã™ã€‚"
-#: main.c:562
+#: main.c:565
msgid "`--posix' overrides `--binary'"
msgstr "`--posix' 㯠`--binary' を上書ãã—ã¾ã™"
-#: main.c:613
+#: main.c:623
#, c-format
msgid "can't set binary mode on stdin (%s)"
msgstr "標準入力をãƒã‚¤ãƒŠãƒªãƒ¢ãƒ¼ãƒ‰ã«è¨­å®šã§ãã¾ã›ã‚“ (%s)"
-#: main.c:616
+#: main.c:626
#, c-format
msgid "can't set binary mode on stdout (%s)"
msgstr "標準出力をãƒã‚¤ãƒŠãƒªãƒ¢ãƒ¼ãƒ‰ã«è¨­å®šã§ãã¾ã›ã‚“ (%s)"
-#: main.c:618
+#: main.c:628
#, c-format
msgid "can't set binary mode on stderr (%s)"
msgstr "標準エラーをãƒã‚¤ãƒŠãƒªãƒ¢ãƒ¼ãƒ‰ã«è¨­å®šã§ãã¾ã›ã‚“ (%s)"
-#: main.c:657
+#: main.c:679
msgid "no program text at all!"
msgstr "プログラム文ãŒå…¨ãã‚りã¾ã›ã‚“!"
-#: main.c:734
+#: main.c:763
#, c-format
msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n"
msgstr ""
"使用法: %s [POSIX ã¾ãŸã¯ GNU å½¢å¼ã®ã‚ªãƒ—ション] -f progfile [--] file ...\n"
-#: main.c:736
+#: main.c:765
#, c-format
msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n"
msgstr ""
"使用法: %s [POSIX ã¾ãŸã¯ GNU å½¢å¼ã®ã‚ªãƒ—ション] [--] %cprogram%c file ...\n"
-#: main.c:741
+#: main.c:770
msgid "POSIX options:\t\tGNU long options: (standard)\n"
msgstr "POSIX オプション:\t\tGNU é•·ã„å½¢å¼ã®ã‚ªãƒ—ション: (標準)\n"
-#: main.c:742
+#: main.c:771
msgid "\t-f progfile\t\t--file=progfile\n"
msgstr "\t-f progfile\t\t--file=progfile\n"
-#: main.c:743
+#: main.c:772
msgid "\t-F fs\t\t\t--field-separator=fs\n"
msgstr "\t-F fs\t\t\t--field-separator=fs\n"
-#: main.c:744
+#: main.c:773
msgid "\t-v var=val\t\t--assign=var=val\n"
msgstr "\t-v var=val\t\t--assign=var=val\n"
-#: main.c:745
+#: main.c:774
msgid "Short options:\t\tGNU long options: (extensions)\n"
msgstr "短ã„オプション:\t\tGNU é•·ã„å½¢å¼ã®ã‚ªãƒ—ション: (æ‹¡å¼µ)\n"
-#: main.c:746
+#: main.c:775
msgid "\t-b\t\t\t--characters-as-bytes\n"
msgstr "\t-b\t\t\t--characters-as-bytes\n"
-#: main.c:747
+#: main.c:776
msgid "\t-c\t\t\t--traditional\n"
msgstr "\t-c\t\t\t--traditional\n"
-#: main.c:748
+#: main.c:777
msgid "\t-C\t\t\t--copyright\n"
msgstr "\t-C\t\t\t--copyright\n"
-#: main.c:749
+#: main.c:778
msgid "\t-d[file]\t\t--dump-variables[=file]\n"
msgstr "\t-d[file]\t\t--dump-variables[=file]\n"
-#: main.c:750
+#: main.c:779
+#, fuzzy
+msgid "\t-D[file]\t\t--debug[=file]\n"
+msgstr "\t-p[file]\t\t--profile[=file]\n"
+
+#: main.c:780
msgid "\t-e 'program-text'\t--source='program-text'\n"
msgstr "\t-e 'program-text'\t--source='program-text'\n"
-#: main.c:751
+#: main.c:781
msgid "\t-E file\t\t\t--exec=file\n"
msgstr "\t-E file\t\t\t--exec=file\n"
-#: main.c:752
+#: main.c:782
msgid "\t-g\t\t\t--gen-pot\n"
msgstr "\t-g\t\t\t--gen-pot\n"
-#: main.c:753
+#: main.c:783
msgid "\t-h\t\t\t--help\n"
msgstr "\t-h\t\t\t--help\n"
-#: main.c:754
+#: main.c:784
+msgid "\t-l library\t\t--load=library\n"
+msgstr ""
+
+#: main.c:785
msgid "\t-L [fatal]\t\t--lint[=fatal]\n"
msgstr "\t-L [fatal]\t\t--lint[=fatal]\n"
-#: main.c:755
+#: main.c:786
msgid "\t-n\t\t\t--non-decimal-data\n"
msgstr "\t-n\t\t\t--non-decimal-data\n"
-#: main.c:756
+#: main.c:787
+#, fuzzy
+msgid "\t-M\t\t\t--bignum\n"
+msgstr "\t-g\t\t\t--gen-pot\n"
+
+#: main.c:788
msgid "\t-N\t\t\t--use-lc-numeric\n"
msgstr "\t-N\t\t\t--use-lc-numeric\n"
-#: main.c:757
+#: main.c:789
+#, fuzzy
+msgid "\t-o[file]\t\t--pretty-print[=file]\n"
+msgstr "\t-p[file]\t\t--profile[=file]\n"
+
+#: main.c:790
msgid "\t-O\t\t\t--optimize\n"
msgstr "\t-O\t\t\t--optimize\n"
-#: main.c:758
+#: main.c:791
msgid "\t-p[file]\t\t--profile[=file]\n"
msgstr "\t-p[file]\t\t--profile[=file]\n"
-#: main.c:759
+#: main.c:792
msgid "\t-P\t\t\t--posix\n"
msgstr "\t-P\t\t\t--posix\n"
-#: main.c:760
+#: main.c:793
msgid "\t-r\t\t\t--re-interval\n"
msgstr "\t-r\t\t\t--re-interval\n"
-#: main.c:762
-msgid "\t-R file\t\t\t--command=file\n"
-msgstr "\t-R file\t\t\t--command=file\n"
-
-#: main.c:763
+#: main.c:794
msgid "\t-S\t\t\t--sandbox\n"
msgstr "\t-S\t\t\t--sandbox\n"
-#: main.c:764
+#: main.c:795
msgid "\t-t\t\t\t--lint-old\n"
msgstr "\t-t\t\t\t--lint-old\n"
-#: main.c:765
+#: main.c:796
msgid "\t-V\t\t\t--version\n"
msgstr "\t-V\t\t\t--version\n"
-#: main.c:767
+#: main.c:798
msgid "\t-W nostalgia\t\t--nostalgia\n"
msgstr "\t-W nostalgia\t\t--nostalgia\n"
-#: main.c:770
+#: main.c:801
msgid "\t-Y\t\t--parsedebug\n"
msgstr "\t-Y\t\t--parsedebug\n"
@@ -1795,7 +1706,7 @@ msgstr "\t-Y\t\t--parsedebug\n"
#. for this application. Please add _another line_ with the
#. address for translation bugs.
#. no-wrap
-#: main.c:779
+#: main.c:810
msgid ""
"\n"
"To report bugs, see node `Bugs' in `gawk.info', which is\n"
@@ -1810,7 +1721,7 @@ msgstr ""
"翻訳ã«é–¢ã™ã‚‹ãƒã‚°ã¯<translation-team-ja@lists.sourceforge.net>ã«å ±å‘Šã—ã¦ãã ã•"
"ã„。\n"
-#: main.c:783
+#: main.c:814
msgid ""
"gawk is a pattern scanning and processing language.\n"
"By default it reads standard input and writes standard output.\n"
@@ -1820,7 +1731,7 @@ msgstr ""
"デフォルト設定ã§ã¯ã€æ¨™æº–入力を読ã¿è¾¼ã¿ã€æ¨™æº–å‡ºåŠ›ã«æ›¸ã出ã—ã¾ã™ã€‚\n"
"\n"
-#: main.c:787
+#: main.c:818
msgid ""
"Examples:\n"
"\tgawk '{ sum += $1 }; END { print sum }' file\n"
@@ -1830,7 +1741,7 @@ msgstr ""
"\tgawk '{ sum += $1 }; END { print sum }' file\n"
"\tgawk -F: '{ print $1 }' /etc/passwd\n"
-#: main.c:807
+#: main.c:838
#, c-format
msgid ""
"Copyright (C) 1989, 1991-%d Free Software Foundation.\n"
@@ -1849,7 +1760,7 @@ msgstr ""
"(at your option) any later version.\n"
"\n"
-#: main.c:815
+#: main.c:846
msgid ""
"This program is distributed in the hope that it will be useful,\n"
"but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
@@ -1863,7 +1774,7 @@ msgstr ""
"GNU General Public License for more details.\n"
"\n"
-#: main.c:821
+#: main.c:852
msgid ""
"You should have received a copy of the GNU General Public License\n"
"along with this program. If not, see http://www.gnu.org/licenses/.\n"
@@ -1871,16 +1782,16 @@ msgstr ""
"You should have received a copy of the GNU General Public License\n"
"along with this program. If not, see http://www.gnu.org/licenses/.\n"
-#: main.c:856
+#: main.c:887
msgid "-Ft does not set FS to tab in POSIX awk"
msgstr "POSIX awk ã§ã¯ -Ft 㯠FS をタブã«è¨­å®šã—ã¾ã›ã‚“"
-#: main.c:1090
+#: main.c:1133
#, c-format
msgid "unknown value for field spec: %d\n"
msgstr "フィールド指定ã«ä¸æ˜Žãªå€¤ãŒã‚りã¾ã™: %d\n"
-#: main.c:1171
+#: main.c:1214
#, c-format
msgid ""
"%s: `%s' argument to `-v' not in `var=value' form\n"
@@ -1889,79 +1800,79 @@ msgstr ""
"%s: オプション `-v' ã®å¼•æ•° `%s' ㌠`変数=代入値' ã®å½¢å¼ã«ãªã£ã¦ã„ã¾ã›ã‚“。\n"
"\n"
-#: main.c:1197
+#: main.c:1240
#, c-format
msgid "`%s' is not a legal variable name"
msgstr "`%s' ã¯ä¸æ­£ãªå¤‰æ•°åã§ã™"
-#: main.c:1200
+#: main.c:1243
#, c-format
msgid "`%s' is not a variable name, looking for file `%s=%s'"
msgstr "`%s' ã¯å¤‰æ•°åã§ã¯ã‚りã¾ã›ã‚“。`%s=%s' ã®ãƒ•ァイルを探ã—ã¾ã™ã€‚"
-#: main.c:1204
+#: main.c:1247
#, c-format
msgid "cannot use gawk builtin `%s' as variable name"
msgstr "gawk ã«çµ„ã¿è¾¼ã¿ã® `%s' ã¯å¤‰æ•°åã¨ã—ã¦ä½¿ç”¨å‡ºæ¥ã¾ã›ã‚“"
-#: main.c:1209
+#: main.c:1252
#, c-format
msgid "cannot use function `%s' as variable name"
msgstr "関数 `%s' ã¯å¤‰æ•°åã¨ã—ã¦ä½¿ç”¨å‡ºæ¥ã¾ã›ã‚“"
-#: main.c:1262
+#: main.c:1305
msgid "floating point exception"
msgstr "æµ®å‹•å°æ•°ç‚¹ä¾‹å¤–"
-#: main.c:1269
+#: main.c:1312
msgid "fatal error: internal error"
msgstr "致命的エラー: 内部エラー"
-#: main.c:1284
+#: main.c:1327
msgid "fatal error: internal error: segfault"
msgstr "致命的エラー: 内部エラー: セグメンテーションé•å"
-#: main.c:1296
+#: main.c:1339
msgid "fatal error: internal error: stack overflow"
msgstr "致命的エラー: 内部エラー: スタックオーãƒãƒ¼ãƒ•ロー"
-#: main.c:1346
+#: main.c:1393
#, c-format
msgid "no pre-opened fd %d"
msgstr "fd %d ãŒäº‹å‰ã«é–‹ã„ã¦ã„ã¾ã›ã‚“。"
-#: main.c:1353
+#: main.c:1400
#, c-format
msgid "could not pre-open /dev/null for fd %d"
msgstr "事å‰ã« fd %d 用㫠/dev/null ã‚’é–‹ã‘ã¾ã›ã‚“。"
-#: msg.c:63
+#: msg.c:61
#, c-format
msgid "cmd. line:"
msgstr "コマンドライン:"
-#: msg.c:107
+#: msg.c:121
msgid "error: "
msgstr "エラー: "
-#: node.c:406
+#: node.c:436
msgid "backslash at end of string"
msgstr "文字列ã®çµ‚りã«ãƒãƒƒã‚¯ã‚¹ãƒ©ãƒƒã‚·ãƒ¥ãŒä½¿ã‚れã¦ã„ã¾ã™ã€‚"
-#: node.c:517
+#: node.c:520
#, c-format
msgid "old awk does not support the `\\%c' escape sequence"
msgstr "å¤ã„ awk 㯠`\\%c' エスケープシーケンスをサãƒãƒ¼ãƒˆã—ã¾ã›ã‚“"
-#: node.c:568
+#: node.c:571
msgid "POSIX does not allow `\\x' escapes"
msgstr "POSIX ã§ã¯ `\\x' エスケープã¯è¨±å¯ã•れã¦ã„ã¾ã›ã‚“"
-#: node.c:574
+#: node.c:577
msgid "no hex digits in `\\x' escape sequence"
msgstr "`\\x' エスケープシーケンスã«å六進数ãŒã‚りã¾ã›ã‚“"
-#: node.c:596
+#: node.c:599
#, c-format
msgid ""
"hex escape \\x%.*s of %d characters probably not interpreted the way you "
@@ -1970,12 +1881,12 @@ msgstr ""
"å六進エスケープ \\x%.*s (%d 文字) ã¯ãŠãらã予期ã—ãŸã‚ˆã†ã«ã¯è§£é‡ˆã•れãªã„ã§"
"ã—ょã†"
-#: node.c:611
+#: node.c:614
#, c-format
msgid "escape sequence `\\%c' treated as plain `%c'"
msgstr "エスケープシーケンス `\\%c' 㯠`%c' ã¨åŒç­‰ã«æ‰±ã‚れã¾ã™"
-#: node.c:750
+#: node.c:759
msgid ""
"Invalid multibyte data detected. There may be a mismatch between your data "
"and your locale."
@@ -1993,16 +1904,16 @@ msgstr "%s %s `%s': fd フラグをå–å¾—ã§ãã¾ã›ã‚“: (fcntl F_GETFD: %s)"
msgid "%s %s `%s': could not set close-on-exec: (fcntl F_SETFD: %s)"
msgstr "%s %s `%s': close-on-exec を設定ã§ãã¾ã›ã‚“: (fcntl F_SETFD: %s)"
-#: profile.c:83
+#: profile.c:69
#, c-format
msgid "could not open `%s' for writing: %s"
msgstr "`%s' を書込ã¿ç”¨ã«é–‹ã‘ã¾ã›ã‚“ã§ã—ãŸ: %s"
-#: profile.c:85
+#: profile.c:71
msgid "sending profile to standard error"
msgstr "プロファイルを標準エラーã«é€ã£ã¦ã„ã¾ã™"
-#: profile.c:203
+#: profile.c:187
#, c-format
msgid ""
"\t# %s block(s)\n"
@@ -2011,7 +1922,7 @@ msgstr ""
"\t# %s ブロック\n"
"\n"
-#: profile.c:208
+#: profile.c:192
#, c-format
msgid ""
"\t# Rule(s)\n"
@@ -2020,17 +1931,22 @@ msgstr ""
"\t# ルール\n"
"\n"
-#: profile.c:279
+#: profile.c:266
#, c-format
msgid "internal error: %s with null vname"
msgstr "内部エラー: %s ã® vname ãŒç„¡åйã§ã™ã€‚"
-#: profile.c:952
+#: profile.c:528
+#, fuzzy
+msgid "internal error: builtin with null fname"
+msgstr "内部エラー: %s ã® vname ãŒç„¡åйã§ã™ã€‚"
+
+#: profile.c:943
#, c-format
msgid "\t# gawk profile, created %s\n"
msgstr "\t# gawk プロファイルã€ä½œæˆæ—¥æ™‚ %s\n"
-#: profile.c:1331
+#: profile.c:1328
#, c-format
msgid ""
"\n"
@@ -2039,17 +1955,17 @@ msgstr ""
"\n"
"\t# 関数一覧(アルファベット順)\n"
-#: profile.c:1370
+#: profile.c:1366
#, c-format
msgid "redir2str: unknown redirection type %d"
msgstr "redir2str: 䏿˜Žãªãƒªãƒ€ã‚¤ãƒ¬ã‚¯ãƒˆåž‹ %d ã§ã™"
-#: re.c:573
+#: re.c:571
#, fuzzy, c-format
msgid "range of the form `[%c-%c]' is locale dependent"
msgstr "`[%c-%c]' å½¢å¼ã®ç¯„囲ã¯ãƒ­ã‚±ãƒ¼ãƒ«ä¾å­˜ã§ã™"
-#: re.c:600
+#: re.c:598
#, c-format
msgid "regexp component `%.*s' should probably be `[%.*s]'"
msgstr "æ­£è¦è¡¨ç¾ã®è¦ç´  `%.*s' ã¯ãŠãらã `[%.*s]' ã§ã‚ã‚‹ã¹ãã§ã™"
@@ -2126,6 +2042,80 @@ msgstr ") ã¾ãŸã¯ \\) ãŒä¸ä¸€è‡´ã§ã™"
msgid "No previous regular expression"
msgstr "以å‰ã«æ­£è¦è¡¨ç¾ãŒã‚りã¾ã›ã‚“"
+#~ msgid "attempt to use function `%s' as an array"
+#~ msgstr "関数 `%s' ã‚’é…列ã¨ã—ã¦ä½¿ç”¨ã™ã‚‹è©¦ã¿ã§ã™"
+
+#~ msgid "reference to uninitialized element `%s[\"%.*s\"]'"
+#~ msgstr "åˆæœŸåŒ–ã•れã¦ã„ãªã„è¦ç´  `%s[\"%.*s\"]' ã¸ã®å‚ç…§ã§ã™"
+
+#~ msgid "subscript of array `%s' is null string"
+#~ msgstr "é…列 `%s' ã®æ·»å­—㌠NULL 文字列ã§ã™"
+
+#~ msgid "%s: empty (null)\n"
+#~ msgstr "%s: 空 (null)\n"
+
+#~ msgid "%s: empty (zero)\n"
+#~ msgstr "%s: 空 (zero)\n"
+
+#~ msgid "%s: table_size = %d, array_size = %d\n"
+#~ msgstr ""
+#~ "%s: テーブルサイズ (table_size) = %d, é…列サイズ (array_size) = %d\n"
+
+#~ msgid "%s: is parameter\n"
+#~ msgstr "%s: 仮引数ã§ã™\n"
+
+#~ msgid "%s: array_ref to %s\n"
+#~ msgstr "%s: %s ã¸ã®é…列å‚ç…§ (array_ref) ã§ã™\n"
+
+#~ msgid "use of non-array as array"
+#~ msgstr "é…列ã§ãªã„ã‚‚ã®ã‚’é…列ã¨ã—ã¦ä½¿ç”¨ã—ã¦ã„ã¾ã™"
+
+#~ msgid "can't use function name `%s' as variable or array"
+#~ msgstr "関数å `%s' ã¯å¤‰æ•°ã¾ãŸã¯é…列ã¨ã—ã¦ä½¿ç”¨å‡ºæ¥ã¾ã›ã‚“"
+
+#~ msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
+#~ msgstr "スカラーコンテキスト内ã§é…列 `%s[\"%.*s\"]' ã®ä½¿ç”¨ã®è©¦ã¿ã§ã™"
+
+#~ msgid "assignment used in conditional context"
+#~ msgstr "æ¡ä»¶ã‚³ãƒ³ãƒ†ã‚­ã‚¹ãƒˆå†…ã§ä»£å…¥ãŒä½¿ç”¨ã•れã¾ã—ãŸ"
+
+#~ msgid "statement has no effect"
+#~ msgstr "æ–‡ã«åŠ¹æžœãŒã‚りã¾ã›ã‚“"
+
+#~ msgid ""
+#~ "for loop: array `%s' changed size from %ld to %ld during loop execution"
+#~ msgstr ""
+#~ "for ループ: ループ実行中ã«é…列 `%s' ã®ã‚µã‚¤ã‚ºãŒ %ld ã‹ã‚‰ %ld ã¸å¤‰æ›´ã•れã¾ã—"
+#~ "ãŸ"
+
+#~ msgid "function called indirectly through `%s' does not exist"
+#~ msgstr "`%s' を通ã—ã¦é–“接的ã«å‘¼ã³å‡ºã•れãŸé–¢æ•°ãŒå­˜åœ¨ã—ã¾ã›ã‚“"
+
+#~ msgid "function `%s' not defined"
+#~ msgstr "関数 `%s' ã¯å®šç¾©ã•れã¦ã„ã¾ã›ã‚“"
+
+#~ msgid "non-redirected `getline' invalid inside `%s' rule"
+#~ msgstr "`%s' ルールã®å†…å´ã§ã¯ãƒªãƒ€ã‚¤ãƒ¬ã‚¯ãƒˆã•れã¦ã„ãªã„ `getline' ã¯ç„¡åйã§ã™"
+
+#~ msgid "error reading input file `%s': %s"
+#~ msgstr "入力ファイル `%s' を読ã¿è¾¼ã¿ä¸­ã«ã‚¨ãƒ©ãƒ¼ãŒç™ºç”Ÿã—ã¾ã—ãŸ: %s"
+
+#~ msgid "`nextfile' cannot be called from a `%s' rule"
+#~ msgstr "`nextfile' 㯠`%s' ルールã‹ã‚‰å‘¼ã³å‡ºã™ã“ã¨ãŒå‡ºæ¥ã¾ã›ã‚“"
+
+#, fuzzy
+#~ msgid "`exit' cannot be called in the current context"
+#~ msgstr "`next' 㯠`%s' ã‹ã‚‰å‘¼ã³å‡ºã™ã“ã¨ãŒå‡ºæ¥ã¾ã›ã‚“"
+
+#~ msgid "`next' cannot be called from a `%s' rule"
+#~ msgstr "`next' 㯠`%s' ã‹ã‚‰å‘¼ã³å‡ºã™ã“ã¨ãŒå‡ºæ¥ã¾ã›ã‚“"
+
+#~ msgid "Sorry, don't know how to interpret `%s'"
+#~ msgstr "申ã—訳ã‚りã¾ã›ã‚“㌠`%s' ã‚’ã©ã®ã‚ˆã†ã«è§£é‡ˆã™ã‚‹ã‹åˆ†ã‹ã‚Šã¾ã›ã‚“"
+
+#~ msgid "\t-R file\t\t\t--command=file\n"
+#~ msgstr "\t-R file\t\t\t--command=file\n"
+
#~ msgid "could not find groups: %s"
#~ msgstr "グループãŒè¦‹ã¤ã‹ã‚Šã¾ã›ã‚“: %s"
diff --git a/po/nl.gmo b/po/nl.gmo
index 00f34760..afaec62c 100644
--- a/po/nl.gmo
+++ b/po/nl.gmo
Binary files differ
diff --git a/po/nl.po b/po/nl.po
index 40930c21..2d21c58b 100644
--- a/po/nl.po
+++ b/po/nl.po
@@ -10,7 +10,7 @@ msgid ""
msgstr ""
"Project-Id-Version: gawk 4.0.0h\n"
"Report-Msgid-Bugs-To: arnold@skeeve.com\n"
-"POT-Creation-Date: 2012-03-28 22:03+0200\n"
+"POT-Creation-Date: 2012-04-27 10:06+0300\n"
"PO-Revision-Date: 2012-01-30 20:40+0100\n"
"Last-Translator: Benno Schulenberg <benno@vertaalt.nl>\n"
"Language-Team: Dutch <vertaling@vrijschrift.org>\n"
@@ -21,505 +21,462 @@ msgstr ""
"X-Generator: Lokalize 1.0\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
-#: array.c:140
+#: array.c:266
#, c-format
msgid "from %s"
msgstr "van %s"
-#: array.c:248
+#: array.c:366
msgid "attempt to use a scalar value as array"
msgstr "scalaire waarde wordt gebruikt als array"
-#: array.c:251
-#, c-format
-msgid "attempt to use function `%s' as an array"
-msgstr "functie '%s' wordt gebruikt als array"
-
-#: array.c:254
+#: array.c:368
#, c-format
msgid "attempt to use scalar parameter `%s' as an array"
msgstr "scalaire parameter '%s' wordt gebruikt als array"
-#: array.c:257
+#: array.c:371
#, c-format
msgid "attempt to use scalar `%s' as an array"
msgstr "scalair '%s' wordt gebruikt als array"
-#: array.c:302 array.c:707 builtin.c:84 builtin.c:1385 builtin.c:1427
-#: builtin.c:1440 builtin.c:1859 builtin.c:1871 eval.c:1135 eval.c:1139
-#: eval.c:1495 eval.c:1812
+#: array.c:418 array.c:584 builtin.c:85 builtin.c:1560 builtin.c:1602
+#: builtin.c:1615 builtin.c:2041 builtin.c:2053 eval.c:1109 eval.c:1113
+#: eval.c:1508
#, c-format
msgid "attempt to use array `%s' in a scalar context"
msgstr "array '%s' wordt gebruikt in een scalaire context"
-#: array.c:513
-#, c-format
-msgid "reference to uninitialized element `%s[\"%.*s\"]'"
-msgstr "verwijzing naar ongeïnitialiseerd element '%s[\"%.*s\"]'"
-
-#: array.c:519
-#, c-format
-msgid "subscript of array `%s' is null string"
-msgstr "index van array '%s' is lege string"
-
-#: array.c:723
+#: array.c:591
#, c-format
msgid "delete: index `%s' not in array `%s'"
msgstr "delete: index '%s' niet in array '%s'"
-#: array.c:734 eval.c:1865
+#: array.c:605
#, c-format
msgid "attempt to use scalar `%s[\"%.*s\"]' as an array"
msgstr "scalair '%s[\"%.*s\"]' wordt gebruikt als array"
-#: array.c:910
-#, c-format
-msgid "%s: empty (null)\n"
-msgstr "%s: leeg (nil)\n"
-
-#: array.c:915
-#, c-format
-msgid "%s: empty (zero)\n"
-msgstr "%s: leeg (nul)\n"
-
-#: array.c:919
-#, c-format
-msgid "%s: table_size = %d, array_size = %d\n"
-msgstr "%s: tabelgrootte = %d, arraygrootte = %d\n"
-
-#: array.c:954
-#, c-format
-msgid "%s: is parameter\n"
-msgstr "%s: is een parameter\n"
-
-#: array.c:958
-#, c-format
-msgid "%s: array_ref to %s\n"
-msgstr "%s: array-verwijzing naar %s\n"
-
-#: array.c:963
-msgid "adump: argument not an array"
+#: array.c:784
+#, fuzzy
+msgid "adump: first argument not an array"
msgstr "adump: argument is geen array"
-#: array.c:1086
+#: array.c:823
msgid "asort: second argument not an array"
msgstr "asort: tweede argument is geen array"
-#: array.c:1087
+#: array.c:824
msgid "asorti: second argument not an array"
msgstr "asorti: tweede argument is geen array"
-#: array.c:1094
+#: array.c:831
msgid "asort: first argument not an array"
msgstr "asort: eerste argument is geen array"
-#: array.c:1095
+#: array.c:832
msgid "asorti: first argument not an array"
msgstr "asorti: eerste argument is geen array"
-#: array.c:1102
+#: array.c:839
msgid "asort: cannot use a subarray of first arg for second arg"
msgstr ""
"asort: een subarray van het eerste argument kan niet als tweede argument "
"gebruikt worden"
-#: array.c:1103
+#: array.c:840
msgid "asorti: cannot use a subarray of first arg for second arg"
msgstr ""
"asorti: een subarray van het eerste argument kan niet als tweede argument "
"gebruikt worden"
-#: array.c:1108
+#: array.c:845
msgid "asort: cannot use a subarray of second arg for first arg"
msgstr ""
"asort: een subarray van het tweede argument kan niet als eerste argument "
"gebruikt worden"
-#: array.c:1109
+#: array.c:846
msgid "asorti: cannot use a subarray of second arg for first arg"
msgstr ""
"asorti: een subarray van het tweede argument kan niet als eerste argument "
"gebruikt worden"
-#: array.c:1655
+#: array.c:1314
#, c-format
msgid "`%s' is invalid as a function name"
msgstr "'%s' is ongeldig als functienaam"
-#: array.c:1659
+#: array.c:1318
#, c-format
msgid "sort comparison function `%s' is not defined"
msgstr "sorteervergelijkingsfunctie '%s' is niet gedefinieerd"
-#: awkgram.y:249
+#: awkgram.y:223
#, c-format
msgid "%s blocks must have an action part"
msgstr "%s-blokken horen een actiedeel te hebben"
-#: awkgram.y:252
+#: awkgram.y:226
msgid "each rule must have a pattern or an action part"
msgstr "elke regel hoort een patroon of een actiedeel te hebben"
-#: awkgram.y:323 awkgram.y:334
+#: awkgram.y:295 awkgram.y:306
msgid "old awk does not support multiple `BEGIN' or `END' rules"
msgstr "oude 'awk' staat meerdere 'BEGIN'- en 'END'-regels niet toe"
-#: awkgram.y:371
+#: awkgram.y:343
#, c-format
msgid "`%s' is a built-in function, it cannot be redefined"
msgstr "'%s' is een ingebouwde functie en is niet te herdefiniëren"
-#: awkgram.y:432
+#: awkgram.y:389
msgid "regexp constant `//' looks like a C++ comment, but is not"
msgstr "regexp-constante '//' lijkt op C-commentaar, maar is het niet"
-#: awkgram.y:436
+#: awkgram.y:393
#, c-format
msgid "regexp constant `/%s/' looks like a C comment, but is not"
msgstr "regexp-constante '/%s/' lijkt op C-commentaar, maar is het niet"
-#: awkgram.y:528
+#: awkgram.y:485
#, c-format
msgid "duplicate case values in switch body: %s"
msgstr "dubbele 'case'-waarde in 'switch'-opdracht: %s"
-#: awkgram.y:549
+#: awkgram.y:506
msgid "duplicate `default' detected in switch body"
msgstr "dubbele 'default' in 'switch'-opdracht"
-#: awkgram.y:809
+#: awkgram.y:766
msgid "`break' is not allowed outside a loop or switch"
msgstr "'break' buiten een lus of 'switch'-opdracht is niet toegestaan"
-#: awkgram.y:818
+#: awkgram.y:775
msgid "`continue' is not allowed outside a loop"
msgstr "'continue' buiten een lus is niet toegestaan"
-#: awkgram.y:828
+#: awkgram.y:785
#, c-format
msgid "`next' used in %s action"
msgstr "'next' wordt gebruikt in %s-actie"
-#: awkgram.y:836
+#: awkgram.y:793
msgid "`nextfile' is a gawk extension"
msgstr "'nextfile' is een gawk-uitbreiding"
-#: awkgram.y:841
+#: awkgram.y:798
#, c-format
msgid "`nextfile' used in %s action"
msgstr "'nextfile' wordt gebruikt in %s-actie"
-#: awkgram.y:865
+#: awkgram.y:822
msgid "`return' used outside function context"
msgstr "'return' wordt gebruikt buiten functiecontext"
-#: awkgram.y:925
+#: awkgram.y:896
msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'"
msgstr ""
"kale 'print' in BEGIN- of END-regel moet vermoedelijk 'print \"\"' zijn"
-#: awkgram.y:995 awkgram.y:999 awkgram.y:1023
+#: awkgram.y:966 awkgram.y:970 awkgram.y:994
msgid "`delete array' is a gawk extension"
msgstr "'delete array' is een gawk-uitbreiding"
-#: awkgram.y:1019
+#: awkgram.y:990
msgid "`delete(array)' is a non-portable tawk extension"
msgstr "'delete(array)' is een niet-overdraagbare 'tawk'-uitbreiding"
-#: awkgram.y:1135
+#: awkgram.y:1108
msgid "multistage two-way pipelines don't work"
msgstr "meerfase-tweerichtings-pijplijnen werken niet"
-#: awkgram.y:1238
+#: awkgram.y:1211
msgid "regular expression on right of assignment"
msgstr "reguliere expressie rechts van toewijzing"
-#: awkgram.y:1249
+#: awkgram.y:1222
msgid "regular expression on left of `~' or `!~' operator"
msgstr "reguliere expressie links van operator '~' of '!~'"
-#: awkgram.y:1265 awkgram.y:1419
+#: awkgram.y:1238 awkgram.y:1389
msgid "old awk does not support the keyword `in' except after `for'"
msgstr "oude 'awk' kent het sleutelwoord 'in' niet, behalve na 'for'"
-#: awkgram.y:1275
+#: awkgram.y:1248
msgid "regular expression on right of comparison"
msgstr "reguliere expressie rechts van vergelijking"
-#: awkgram.y:1394
+#: awkgram.y:1364
#, c-format
msgid "`getline var' invalid inside `%s' rule"
msgstr "'getline var' is ongeldig binnen een '%s'-regel"
-#: awkgram.y:1397 eval.c:2504
+#: awkgram.y:1367
#, c-format
msgid "`getline' invalid inside `%s' rule"
msgstr "'getline' is ongeldig binnen een '%s'-regel"
-#: awkgram.y:1402
+#: awkgram.y:1372
msgid "non-redirected `getline' undefined inside END action"
msgstr "niet-omgeleide 'getline' is ongedefinieerd binnen een END-actie"
-#: awkgram.y:1421
+#: awkgram.y:1391
msgid "old awk does not support multidimensional arrays"
msgstr "oude 'awk' kent geen meerdimensionale arrays"
-#: awkgram.y:1517
+#: awkgram.y:1488
msgid "call of `length' without parentheses is not portable"
msgstr "aanroep van 'length' zonder haakjes is niet overdraagbaar"
-#: awkgram.y:1580
+#: awkgram.y:1554
msgid "indirect function calls are a gawk extension"
msgstr "indirecte functieaanroepen zijn een gawk-uitbreiding"
-#: awkgram.y:1593
+#: awkgram.y:1567
#, c-format
msgid "can not use special variable `%s' for indirect function call"
msgstr ""
"kan speciale variabele '%s' niet voor indirecte functieaanroep gebruiken"
-#: awkgram.y:1671
+#: awkgram.y:1645
msgid "invalid subscript expression"
msgstr "ongeldige index-expressie"
-#: awkgram.y:1711
-msgid "use of non-array as array"
-msgstr "non-array wordt gebruikt als array"
-
-#: awkgram.y:1975 awkgram.y:1995 msg.c:98
+#: awkgram.y:1966 awkgram.y:1986 msg.c:112
msgid "warning: "
msgstr "waarschuwing: "
-#: awkgram.y:1993 msg.c:130
+#: awkgram.y:1984 msg.c:144
msgid "fatal: "
msgstr "fataal: "
-#: awkgram.y:2043
+#: awkgram.y:2034
msgid "unexpected newline or end of string"
msgstr "onverwacht regeleinde of einde van string"
-#: awkgram.y:2300 awkgram.y:2358 awkgram.y:2542
+#: awkgram.y:2299 awkgram.y:2357 awkgram.y:2545
#, c-format
msgid "can't open source file `%s' for reading (%s)"
msgstr "kan bronbestand '%s' niet openen om te lezen (%s)"
-#: awkgram.y:2301 awkgram.y:2359 builtin.c:122
+#: awkgram.y:2300 awkgram.y:2358 builtin.c:124
msgid "reason unknown"
msgstr "reden onbekend"
-#: awkgram.y:2317
+#: awkgram.y:2316
#, c-format
msgid "already included source file `%s'"
msgstr "bronbestand '%s' is reeds ingesloten"
-#: awkgram.y:2343
+#: awkgram.y:2342
msgid "@include is a gawk extension"
msgstr "'@include' is een gawk-uitbreiding"
-#: awkgram.y:2349
+#: awkgram.y:2348
msgid "empty filename after @include"
msgstr "lege bestandsnaam na '@include'"
-#: awkgram.y:2494
+#: awkgram.y:2497
msgid "empty program text on command line"
msgstr "lege programmatekst op commandoregel"
-#: awkgram.y:2609
+#: awkgram.y:2612
#, c-format
msgid "can't read sourcefile `%s' (%s)"
msgstr "kan bronbestand '%s' niet lezen (%s)"
-#: awkgram.y:2620
+#: awkgram.y:2623
#, c-format
msgid "source file `%s' is empty"
msgstr "bronbestand '%s' is leeg"
-#: awkgram.y:2797
+#: awkgram.y:2800
msgid "source file does not end in newline"
msgstr "bronbestand eindigt niet met een regeleindeteken (LF)"
-#: awkgram.y:2900
+#: awkgram.y:2905
msgid "unterminated regexp ends with `\\' at end of file"
msgstr "onafgesloten reguliere expressie eindigt met '\\' aan bestandseinde"
-#: awkgram.y:2924
+#: awkgram.y:2929
#, c-format
msgid "%s: %d: tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr "%s: %d: regexp-optie '/.../%c' van 'tawk' werkt niet in gawk"
-#: awkgram.y:2928
+#: awkgram.y:2933
#, c-format
msgid "tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr "regexp-optie '/.../%c' van 'tawk' werkt niet in gawk"
-#: awkgram.y:2935
+#: awkgram.y:2940
msgid "unterminated regexp"
msgstr "onafgesloten reguliere expressie"
-#: awkgram.y:2939
+#: awkgram.y:2944
msgid "unterminated regexp at end of file"
msgstr "onafgesloten reguliere expressie aan bestandseinde"
-#: awkgram.y:2998
+#: awkgram.y:3003
msgid "use of `\\ #...' line continuation is not portable"
msgstr "gebruik van regelvoortzetting '\\ #...' is niet overdraagbaar"
-#: awkgram.y:3014
+#: awkgram.y:3019
msgid "backslash not last character on line"
msgstr "backslash is niet het laatste teken op de regel"
-#: awkgram.y:3075
+#: awkgram.y:3080
msgid "POSIX does not allow operator `**='"
msgstr "POSIX staat operator '**=' niet toe"
-#: awkgram.y:3077
+#: awkgram.y:3082
msgid "old awk does not support operator `**='"
msgstr "oude 'awk' kent de operator '**=' niet"
-#: awkgram.y:3086
+#: awkgram.y:3091
msgid "POSIX does not allow operator `**'"
msgstr "POSIX staat operator '**' niet toe"
-#: awkgram.y:3088
+#: awkgram.y:3093
msgid "old awk does not support operator `**'"
msgstr "oude 'awk' kent de operator '**' niet"
-#: awkgram.y:3123
+#: awkgram.y:3128
msgid "operator `^=' is not supported in old awk"
msgstr "oude 'awk' kent de operator '^=' niet"
-#: awkgram.y:3131
+#: awkgram.y:3136
msgid "operator `^' is not supported in old awk"
msgstr "oude 'awk' kent de operator '^' niet"
-#: awkgram.y:3224 awkgram.y:3240
+#: awkgram.y:3229 awkgram.y:3245
msgid "unterminated string"
msgstr "onafgesloten string"
-#: awkgram.y:3436
+#: awkgram.y:3466
#, c-format
msgid "invalid char '%c' in expression"
msgstr "ongeldig teken '%c' in expressie"
-#: awkgram.y:3483
+#: awkgram.y:3513
#, c-format
msgid "`%s' is a gawk extension"
msgstr "'%s' is een gawk-uitbreiding"
-#: awkgram.y:3488
+#: awkgram.y:3518
#, c-format
msgid "`%s' is a Bell Labs extension"
msgstr "'%s' is een uitbreiding door Bell Labs"
-#: awkgram.y:3493
+#: awkgram.y:3523
#, c-format
msgid "POSIX does not allow `%s'"
msgstr "POSIX staat '%s' niet toe"
-#: awkgram.y:3501
+#: awkgram.y:3531
#, c-format
msgid "`%s' is not supported in old awk"
msgstr "oude 'awk' kent '%s' niet"
-#: awkgram.y:3568
+#: awkgram.y:3598
msgid "`goto' considered harmful!\n"
msgstr "'goto' wordt als schadelijk beschouwd!\n"
-#: awkgram.y:3619
+#: awkgram.y:3632
#, c-format
msgid "%d is invalid as number of arguments for %s"
msgstr "%d is een ongeldig aantal argumenten voor %s"
-#: awkgram.y:3654
+#: awkgram.y:3667
#, c-format
msgid "%s: string literal as last arg of substitute has no effect"
msgstr "%s: een stringwaarde als laatste vervangingsargument heeft geen effect"
-#: awkgram.y:3659
+#: awkgram.y:3672
#, c-format
msgid "%s third parameter is not a changeable object"
msgstr "%s: derde parameter is geen veranderbaar object"
-#: awkgram.y:3732 awkgram.y:3735
+#: awkgram.y:3751 awkgram.y:3754
msgid "match: third argument is a gawk extension"
msgstr "match: derde argument is een gawk-uitbreiding"
-#: awkgram.y:3789 awkgram.y:3792
+#: awkgram.y:3808 awkgram.y:3811
msgid "close: second argument is a gawk extension"
msgstr "close: tweede argument is een gawk-uitbreiding"
-#: awkgram.y:3804
+#: awkgram.y:3823
msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore"
msgstr "dcgettext(_\"...\") is onjuist: verwijder het liggende streepje"
-#: awkgram.y:3819
+#: awkgram.y:3838
msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore"
msgstr "dcngettext(_\"...\") is onjuist: verwijder het liggende streepje"
-#: awkgram.y:3911
-#, c-format
-msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
-msgstr "functie '%s': parameter #%d, '%s', dupliceert parameter #%d"
-
-#: awkgram.y:3953
+#: awkgram.y:3904
#, c-format
msgid "function `%s': parameter `%s' shadows global variable"
msgstr "functie '%s': parameter '%s' schaduwt een globale variabele"
-#: awkgram.y:4111
+#: awkgram.y:3961
#, c-format
msgid "could not open `%s' for writing (%s)"
msgstr "kan '%s' niet openen om te schrijven (%s)"
-#: awkgram.y:4112
+#: awkgram.y:3962
msgid "sending variable list to standard error"
msgstr "variabelenlijst gaat naar standaardfoutuitvoer"
-#: awkgram.y:4118
+#: awkgram.y:3970
#, c-format
msgid "%s: close failed (%s)"
msgstr "%s: sluiten is mislukt (%s)"
-#: awkgram.y:4170
+#: awkgram.y:3995
msgid "shadow_funcs() called twice!"
msgstr "shadow_funcs() twee keer aangeroepen!"
-#: awkgram.y:4176
+#: awkgram.y:4003
msgid "there were shadowed variables."
msgstr "er waren geschaduwde variabelen."
-#: awkgram.y:4206
+#: awkgram.y:4074
+#, c-format
+msgid "function name `%s' previously defined"
+msgstr "functienaam '%s' is al eerder gedefinieerd"
+
+#: awkgram.y:4120
#, c-format
msgid "function `%s': can't use function name as parameter name"
msgstr "functie '%s': kan functienaam niet als parameternaam gebruiken"
-#: awkgram.y:4210
+#: awkgram.y:4123
#, c-format
msgid "function `%s': can't use special variable `%s' as a function parameter"
msgstr ""
"functie '%s': kan speciale variabele '%s' niet als functieparameter gebruiken"
-#: awkgram.y:4226
+#: awkgram.y:4131
#, c-format
-msgid "function name `%s' previously defined"
-msgstr "functienaam '%s' is al eerder gedefinieerd"
+msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
+msgstr "functie '%s': parameter #%d, '%s', dupliceert parameter #%d"
-#: awkgram.y:4394 awkgram.y:4400
+#: awkgram.y:4210 awkgram.y:4216
#, c-format
msgid "function `%s' called but never defined"
msgstr "functie '%s' wordt aangeroepen maar is nergens gedefinieerd"
-#: awkgram.y:4403
+#: awkgram.y:4219
#, c-format
msgid "function `%s' defined but never called directly"
msgstr "functie '%s' is gedefinieerd maar wordt nergens direct aangeroepen"
-#: awkgram.y:4435
+#: awkgram.y:4251
#, c-format
msgid "regexp constant for parameter #%d yields boolean value"
msgstr "regexp-constante als parameter #%d levert booleanwaarde op"
-#: awkgram.y:4544
+#: awkgram.y:4297
#, c-format
msgid ""
"function `%s' called with space between name and `(',\n"
@@ -528,230 +485,230 @@ msgstr ""
"functie '%s' wordt aangeroepen met een spatie tussen naam en '(',\n"
"of wordt gebruikt als variabele of array"
-#: awkgram.y:4791 eval.c:2056
+#: awkgram.y:4505
msgid "division by zero attempted"
msgstr "deling door nul"
-#: awkgram.y:4800 eval.c:2072
+#: awkgram.y:4514
#, c-format
msgid "division by zero attempted in `%%'"
msgstr "deling door nul in '%%'"
-#: builtin.c:120
+#: builtin.c:122
#, c-format
msgid "%s to \"%s\" failed (%s)"
msgstr "%s naar \"%s\" is mislukt (%s)"
-#: builtin.c:121
+#: builtin.c:123
msgid "standard output"
msgstr "standaarduitvoer"
-#: builtin.c:135
+#: builtin.c:137
msgid "exp: received non-numeric argument"
msgstr "exp: argument is geen getal"
-#: builtin.c:141
+#: builtin.c:143
#, c-format
msgid "exp: argument %g is out of range"
msgstr "exp: argument %g ligt buiten toegestane bereik"
-#: builtin.c:200
+#: builtin.c:202
#, c-format
msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing"
msgstr ""
"fflush: kan pijp niet leegmaken: '%s' is geopend om te lezen, niet om te "
"schrijven"
-#: builtin.c:203
+#: builtin.c:205
#, c-format
msgid "fflush: cannot flush: file `%s' opened for reading, not writing"
msgstr ""
"fflush: kan bestand niet leegmaken: '%s' is geopend om te lezen, niet om te "
"schrijven"
-#: builtin.c:215
+#: builtin.c:217
#, c-format
msgid "fflush: `%s' is not an open file, pipe or co-process"
msgstr "fflush: '%s' is geen open bestand, pijp, of co-proces"
-#: builtin.c:333
+#: builtin.c:335
msgid "index: received non-string first argument"
msgstr "index: eerste argument is geen string"
-#: builtin.c:335
+#: builtin.c:337
msgid "index: received non-string second argument"
msgstr "index: tweede argument is geen string"
-#: builtin.c:457
+#: builtin.c:461
msgid "int: received non-numeric argument"
msgstr "int: argument is geen getal"
-#: builtin.c:493
+#: builtin.c:497
msgid "length: received array argument"
msgstr "length: argument is een array"
-#: builtin.c:496
+#: builtin.c:500
msgid "`length(array)' is a gawk extension"
msgstr "'length(array)' is een gawk-uitbreiding"
-#: builtin.c:504
+#: builtin.c:508
msgid "length: received non-string argument"
msgstr "length: argument is geen string"
-#: builtin.c:535
+#: builtin.c:539
msgid "log: received non-numeric argument"
msgstr "log: argument is geen getal"
-#: builtin.c:538
+#: builtin.c:542
#, c-format
msgid "log: received negative argument %g"
msgstr "log: argument %g is negatief"
-#: builtin.c:694 builtin.c:699
+#: builtin.c:740 builtin.c:745
msgid "fatal: must use `count$' on all formats or none"
msgstr "fataal: 'count$' hoort in alle opmaken gebruikt te worden, of in geen"
-#: builtin.c:762
+#: builtin.c:815
#, c-format
msgid "field width is ignored for `%%' specifier"
msgstr "veldbreedte wordt genegeerd voor opmaakaanduiding '%%'"
-#: builtin.c:764
+#: builtin.c:817
#, c-format
msgid "precision is ignored for `%%' specifier"
msgstr "veldprecisie wordt genegeerd voor opmaakaanduiding '%%'"
-#: builtin.c:766
+#: builtin.c:819
#, c-format
msgid "field width and precision are ignored for `%%' specifier"
msgstr "veldbreedte en -precisie worden genegeerd voor opmaakaanduiding '%%'"
-#: builtin.c:817
+#: builtin.c:870
msgid "fatal: `$' is not permitted in awk formats"
msgstr "fataal: '$' is niet toegestaan in awk-opmaak"
-#: builtin.c:826
+#: builtin.c:879
msgid "fatal: arg count with `$' must be > 0"
msgstr "fataal: het aantal argumenten met '$' moet > 0 zijn"
-#: builtin.c:830
+#: builtin.c:883
#, c-format
msgid "fatal: arg count %ld greater than total number of supplied arguments"
msgstr "fataal: argumentental %ld is groter dan het gegeven aantal argumenten"
-#: builtin.c:834
+#: builtin.c:887
msgid "fatal: `$' not permitted after period in format"
msgstr "fataal: '$' is niet toegestaan na een punt in de opmaak"
-#: builtin.c:850
+#: builtin.c:903
msgid "fatal: no `$' supplied for positional field width or precision"
msgstr "fataal: geen '$' opgegeven bij positionele veldbreedte of -precisie"
-#: builtin.c:921
+#: builtin.c:975
msgid "`l' is meaningless in awk formats; ignored"
msgstr "'l' is betekenisloos in awk-opmaak; genegeerd"
-#: builtin.c:925
+#: builtin.c:979
msgid "fatal: `l' is not permitted in POSIX awk formats"
msgstr "fataal: 'l' is niet toegestaan in POSIX awk-opmaak"
-#: builtin.c:938
+#: builtin.c:992
msgid "`L' is meaningless in awk formats; ignored"
msgstr "'L' is betekenisloos in awk-opmaak; genegeerd"
-#: builtin.c:942
+#: builtin.c:996
msgid "fatal: `L' is not permitted in POSIX awk formats"
msgstr "fataal: 'L' is niet toegestaan in POSIX awk-opmaak"
-#: builtin.c:955
+#: builtin.c:1009
msgid "`h' is meaningless in awk formats; ignored"
msgstr "'h' is betekenisloos in awk-opmaak; genegeerd"
-#: builtin.c:959
+#: builtin.c:1013
msgid "fatal: `h' is not permitted in POSIX awk formats"
msgstr "fataal: 'h' is niet toegestaan in POSIX awk-opmaak"
-#: builtin.c:1272
+#: builtin.c:1408
#, c-format
msgid "[s]printf: value %g is out of range for `%%%c' format"
msgstr "[s]printf: waarde %g ligt buiten toegestaan bereik voor opmaak '%%%c'"
-#: builtin.c:1332
+#: builtin.c:1506
#, c-format
msgid "ignoring unknown format specifier character `%c': no argument converted"
msgstr ""
"onbekend opmaakteken '%c' wordt genegeerd: geen argument is geconverteerd"
-#: builtin.c:1337
+#: builtin.c:1511
msgid "fatal: not enough arguments to satisfy format string"
msgstr "fataal: niet genoeg argumenten voor opmaakstring"
-#: builtin.c:1339
+#: builtin.c:1513
msgid "^ ran out for this one"
msgstr "niet genoeg ^ voor deze"
-#: builtin.c:1346
+#: builtin.c:1520
msgid "[s]printf: format specifier does not have control letter"
msgstr "[s]printf: opmaakaanduiding mist een stuurletter"
-#: builtin.c:1349
+#: builtin.c:1523
msgid "too many arguments supplied for format string"
msgstr "te veel argumenten voor opmaakstring"
-#: builtin.c:1423 builtin.c:1434
+#: builtin.c:1598 builtin.c:1609
msgid "printf: no arguments"
msgstr "printf: geen argumenten"
-#: builtin.c:1475
+#: builtin.c:1650
msgid "sqrt: received non-numeric argument"
msgstr "sqrt: argument is geen getal"
-#: builtin.c:1479
+#: builtin.c:1654
#, c-format
msgid "sqrt: called with negative argument %g"
msgstr "sqrt: argument %g is negatief"
-#: builtin.c:1503
+#: builtin.c:1685
#, c-format
msgid "substr: length %g is not >= 1"
msgstr "substr: lengte %g is niet >= 1"
-#: builtin.c:1505
+#: builtin.c:1687
#, c-format
msgid "substr: length %g is not >= 0"
msgstr "substr: lengte %g is niet >= 0"
-#: builtin.c:1512
+#: builtin.c:1694
#, c-format
msgid "substr: non-integer length %g will be truncated"
msgstr "substr: lengte %g is geen integer; wordt afgekapt"
-#: builtin.c:1517
+#: builtin.c:1699
#, c-format
msgid "substr: length %g too big for string indexing, truncating to %g"
msgstr ""
"substr: lengte %g is te groot voor stringindexering; wordt verkort tot %g"
-#: builtin.c:1529
+#: builtin.c:1711
#, c-format
msgid "substr: start index %g is invalid, using 1"
msgstr "substr: startindex %g is ongeldig; 1 wordt gebruikt"
-#: builtin.c:1534
+#: builtin.c:1716
#, c-format
msgid "substr: non-integer start index %g will be truncated"
msgstr "substr: startindex %g is geen integer; wordt afgekapt"
-#: builtin.c:1559
+#: builtin.c:1741
msgid "substr: source string is zero length"
msgstr "substr: bronstring heeft lengte nul"
-#: builtin.c:1575
+#: builtin.c:1757
#, c-format
msgid "substr: start index %g is past end of string"
msgstr "substr: startindex %g ligt voorbij het einde van de string"
-#: builtin.c:1583
+#: builtin.c:1765
#, c-format
msgid ""
"substr: length %g at start index %g exceeds length of first argument (%lu)"
@@ -759,227 +716,222 @@ msgstr ""
"substr: lengte %g bij startindex %g is groter dan de lengte van het eerste "
"argument (%lu)"
-#: builtin.c:1657
+#: builtin.c:1839
msgid "strftime: format value in PROCINFO[\"strftime\"] has numeric type"
msgstr "strftime: opmaakwaarde in PROCINFO[\"strftime\"] is numeriek"
-#: builtin.c:1680
+#: builtin.c:1862
msgid "strftime: received non-numeric second argument"
msgstr "strftime: tweede argument is geen getal"
-#: builtin.c:1683
+#: builtin.c:1866
msgid "strftime: second argument less than 0 or too big for time_t"
msgstr "strftime: tweede argument is kleiner dan nul of te groot voor 'time_t'"
-#: builtin.c:1690
+#: builtin.c:1873
msgid "strftime: received non-string first argument"
msgstr "strftime: eerste argument is geen string"
-#: builtin.c:1696
+#: builtin.c:1880
msgid "strftime: received empty format string"
msgstr "strftime: opmaakstring is leeg"
-#: builtin.c:1762
+#: builtin.c:1946
msgid "mktime: received non-string argument"
msgstr "mktime: argument is geen string"
-#: builtin.c:1779
+#: builtin.c:1963
msgid "mktime: at least one of the values is out of the default range"
msgstr "mktime: minstens één van waarden valt buiten het standaardbereik"
-#: builtin.c:1814
+#: builtin.c:1998
msgid "'system' function not allowed in sandbox mode"
msgstr "'system'-functie is niet toegestaan in sandbox-modus"
-#: builtin.c:1819
+#: builtin.c:2003
msgid "system: received non-string argument"
msgstr "system: argument is geen string"
-#: builtin.c:1874 eval.c:1159 eval.c:1790 eval.c:1803
-#, c-format
-msgid "reference to uninitialized variable `%s'"
-msgstr "verwijzing naar ongeïnitialiseerde variabele '%s'"
-
-#: builtin.c:1941
+#: builtin.c:2121
#, c-format
msgid "reference to uninitialized field `$%d'"
msgstr "verwijzing naar ongeïnitialiseerd veld '$%d'"
-#: builtin.c:2028
+#: builtin.c:2208
msgid "tolower: received non-string argument"
msgstr "tolower: argument is geen string"
-#: builtin.c:2062
+#: builtin.c:2242
msgid "toupper: received non-string argument"
msgstr "toupper: argument is geen string"
-#: builtin.c:2098
+#: builtin.c:2278
msgid "atan2: received non-numeric first argument"
msgstr "atan2: eerste argument is geen getal"
-#: builtin.c:2100
+#: builtin.c:2280
msgid "atan2: received non-numeric second argument"
msgstr "atan2: tweede argument is geen getal"
-#: builtin.c:2119
+#: builtin.c:2299
msgid "sin: received non-numeric argument"
msgstr "sin: argument is geen getal"
-#: builtin.c:2135
+#: builtin.c:2315
msgid "cos: received non-numeric argument"
msgstr "cos: argument is geen getal"
-#: builtin.c:2188
+#: builtin.c:2368
msgid "srand: received non-numeric argument"
msgstr "srand: argument is geen getal"
-#: builtin.c:2219
+#: builtin.c:2399
msgid "match: third argument is not an array"
msgstr "match: derde argument is geen array"
-#: builtin.c:2483
+#: builtin.c:2664
msgid "gensub: third argument of 0 treated as 1"
msgstr "gensub: derde argument is 0; wordt beschouwd als 1"
-#: builtin.c:2776
+#: builtin.c:2957
msgid "lshift: received non-numeric first argument"
msgstr "lshift: eerste argument is geen getal"
-#: builtin.c:2778
+#: builtin.c:2959
msgid "lshift: received non-numeric second argument"
msgstr "lshift: tweede argument is geen getal"
-#: builtin.c:2784
+#: builtin.c:2965
#, c-format
msgid "lshift(%lf, %lf): negative values will give strange results"
msgstr "lshift(%lf, %lf): negatieve waarden geven rare resultaten"
-#: builtin.c:2786
+#: builtin.c:2967
#, c-format
msgid "lshift(%lf, %lf): fractional values will be truncated"
msgstr "lshift(%lf, %lf): cijfers na de komma worden afgekapt"
-#: builtin.c:2788
+#: builtin.c:2969
#, c-format
msgid "lshift(%lf, %lf): too large shift value will give strange results"
msgstr "lshift(%lf, %lf): te grote opschuifwaarden geven rare resultaten"
-#: builtin.c:2813
+#: builtin.c:2994
msgid "rshift: received non-numeric first argument"
msgstr "rshift: eerste argument is geen getal"
-#: builtin.c:2815
+#: builtin.c:2996
msgid "rshift: received non-numeric second argument"
msgstr "rshift: tweede argument is geen getal"
-#: builtin.c:2821
+#: builtin.c:3002
#, c-format
msgid "rshift(%lf, %lf): negative values will give strange results"
msgstr "rshift(%lf, %lf): negatieve waarden geven rare resultaten"
-#: builtin.c:2823
+#: builtin.c:3004
#, c-format
msgid "rshift(%lf, %lf): fractional values will be truncated"
msgstr "rshift(%lf, %lf): cijfers na de komma worden afgekapt"
-#: builtin.c:2825
+#: builtin.c:3006
#, c-format
msgid "rshift(%lf, %lf): too large shift value will give strange results"
msgstr "rshift(%lf, %lf): te grote opschuifwaarden geven rare resultaten"
-#: builtin.c:2850
+#: builtin.c:3031
msgid "and: received non-numeric first argument"
msgstr "and: eerste argument is geen getal"
-#: builtin.c:2852
+#: builtin.c:3033
msgid "and: received non-numeric second argument"
msgstr "and: tweede argument is geen getal"
-#: builtin.c:2858
+#: builtin.c:3039
#, c-format
msgid "and(%lf, %lf): negative values will give strange results"
msgstr "and(%lf, %lf): negatieve waarden geven rare resultaten"
-#: builtin.c:2860
+#: builtin.c:3041
#, c-format
msgid "and(%lf, %lf): fractional values will be truncated"
msgstr "and(%lf, %lf): cijfers na de komma worden afgekapt"
-#: builtin.c:2885
+#: builtin.c:3066
msgid "or: received non-numeric first argument"
msgstr "or: eerste argument is geen getal"
-#: builtin.c:2887
+#: builtin.c:3068
msgid "or: received non-numeric second argument"
msgstr "or: tweede argument is geen getal"
-#: builtin.c:2893
+#: builtin.c:3074
#, c-format
msgid "or(%lf, %lf): negative values will give strange results"
msgstr "or(%lf, %lf): negatieve waarden geven rare resultaten"
-#: builtin.c:2895
+#: builtin.c:3076
#, c-format
msgid "or(%lf, %lf): fractional values will be truncated"
msgstr "or(%lf, %lf): cijfers na de komma worden afgekapt"
-#: builtin.c:2923
+#: builtin.c:3102
msgid "xor: received non-numeric first argument"
msgstr "xor: eerste argument is geen getal"
-#: builtin.c:2925
+#: builtin.c:3104
msgid "xor: received non-numeric second argument"
msgstr "xor: tweede argument is geen getal"
-#: builtin.c:2931
+#: builtin.c:3110
#, c-format
msgid "xor(%lf, %lf): negative values will give strange results"
msgstr "xor(%lf, %lf): negatieve waarden geven rare resultaten"
-#: builtin.c:2933
+#: builtin.c:3112
#, c-format
msgid "xor(%lf, %lf): fractional values will be truncated"
msgstr "xor(%lf, %lf): cijfers na de komma worden afgekapt"
-#: builtin.c:2957 builtin.c:2963
+#: builtin.c:3136
msgid "compl: received non-numeric argument"
msgstr "compl: argument is geen getal"
-#: builtin.c:2965
+#: builtin.c:3142
#, c-format
msgid "compl(%lf): negative value will give strange results"
msgstr "compl(%lf): negatieve waarden geven rare resultaten"
-#: builtin.c:2967
+#: builtin.c:3144
#, c-format
msgid "compl(%lf): fractional value will be truncated"
msgstr "compl(%lf): cijfers na de komma worden afgekapt"
-#: builtin.c:3136
+#: builtin.c:3313
#, c-format
msgid "dcgettext: `%s' is not a valid locale category"
msgstr "dcgettext: '%s' is geen geldige taalregio-deelcategorie"
-#: eval.c:412
+#: eval.c:395
#, c-format
msgid "unknown nodetype %d"
msgstr "onbekend knooptype %d"
-#: eval.c:423 eval.c:437
+#: eval.c:406 eval.c:420
#, c-format
msgid "unknown opcode %d"
msgstr "onbekende opcode %d"
-#: eval.c:434
+#: eval.c:417
#, c-format
msgid "opcode %s not an operator or keyword"
msgstr "opcode %s is geen operator noch sleutelwoord"
-#: eval.c:488
+#: eval.c:472
msgid "buffer overflow in genflags2str"
msgstr "bufferoverloop in genflags2str()"
-#: eval.c:698
+#: eval.c:675
#, c-format
msgid ""
"\n"
@@ -990,308 +942,252 @@ msgstr ""
"\t# Functieaanroepen-stack:\n"
"\n"
-#: eval.c:725
+#: eval.c:704
msgid "`IGNORECASE' is a gawk extension"
msgstr "'IGNORECASE' is een gawk-uitbreiding"
-#: eval.c:754
+#: eval.c:736
msgid "`BINMODE' is a gawk extension"
msgstr "'BINMODE' is een gawk-uitbreiding"
-#: eval.c:812
+#: eval.c:793
#, c-format
msgid "BINMODE value `%s' is invalid, treated as 3"
msgstr "BINMODE-waarde '%s' is ongeldig, wordt behandeld als 3"
-#: eval.c:902
+#: eval.c:885
#, c-format
msgid "bad `%sFMT' specification `%s'"
msgstr "onjuiste opgave van '%sFMT': '%s'"
-#: eval.c:980
+#: eval.c:969
msgid "turning off `--lint' due to assignment to `LINT'"
msgstr "'--lint' wordt uitgeschakeld wegens toewijzing aan 'LINT'"
-#: eval.c:1127 eval.c:1777
-#, c-format
-msgid "can't use function name `%s' as variable or array"
-msgstr "kan functienaam '%s' niet als variabele of array gebruiken"
-
-#: eval.c:1158 eval.c:1789 eval.c:1802
+#: eval.c:1132
#, c-format
msgid "reference to uninitialized argument `%s'"
msgstr "verwijzing naar ongeïnitialiseerd argument '%s'"
-#: eval.c:1177
+#: eval.c:1133
+#, c-format
+msgid "reference to uninitialized variable `%s'"
+msgstr "verwijzing naar ongeïnitialiseerde variabele '%s'"
+
+#: eval.c:1151
msgid "attempt to field reference from non-numeric value"
msgstr "veldverwijzingspoging via een waarde die geen getal is"
-#: eval.c:1179
+#: eval.c:1153
msgid "attempt to field reference from null string"
msgstr "veldverwijzingspoging via een lege string"
-#: eval.c:1185
+#: eval.c:1161
#, c-format
msgid "attempt to access field %ld"
msgstr "toegangspoging tot veld %ld"
-#: eval.c:1194
+#: eval.c:1170
#, c-format
msgid "reference to uninitialized field `$%ld'"
msgstr "verwijzing naar ongeïnitialiseerd veld '$%ld'"
-#: eval.c:1256
+#: eval.c:1257
#, c-format
msgid "function `%s' called with more arguments than declared"
msgstr "functie '%s' aangeroepen met meer argumenten dan gedeclareerd"
-#: eval.c:1437
+#: eval.c:1452
#, c-format
msgid "unwind_stack: unexpected type `%s'"
msgstr "unwind_stack(): onverwacht type '%s'"
-#: eval.c:1532
+#: eval.c:1546
msgid "division by zero attempted in `/='"
msgstr "deling door nul in '/='"
-#: eval.c:1539
+#: eval.c:1553
#, c-format
msgid "division by zero attempted in `%%='"
msgstr "deling door nul in '%%='"
-#: eval.c:1876 eval.c:2122
-#, c-format
-msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
-msgstr "array '%s[\"%.*s\"]' wordt gebruikt in een scalaire context"
-
-#: eval.c:1907
-msgid "assignment used in conditional context"
-msgstr "toewijzing wordt gebruikt in een conditionele context"
-
-#: eval.c:1911
-msgid "statement has no effect"
-msgstr "opdracht heeft geen effect"
-
-#: eval.c:2343
-#, c-format
-msgid "for loop: array `%s' changed size from %ld to %ld during loop execution"
-msgstr ""
-"for: array '%s' veranderde van grootte %ld naar %ld tijdens uitvoer van de "
-"lus"
-
-#: eval.c:2458
-#, c-format
-msgid "function called indirectly through `%s' does not exist"
-msgstr "indirect (via '%s') aangeroepen functie bestaat niet"
-
-#: eval.c:2470
-#, c-format
-msgid "function `%s' not defined"
-msgstr "functie '%s' is niet gedefinieerd"
-
-#: eval.c:2511
-#, c-format
-msgid "non-redirected `getline' invalid inside `%s' rule"
-msgstr "niet-omgeleide 'getline' is ongeldig binnen een '%s'-regel"
-
-#: eval.c:2600
-#, c-format
-msgid "error reading input file `%s': %s"
-msgstr "fout tijdens lezen van invoerbestand '%s': %s"
-
-#: eval.c:2614
-#, c-format
-msgid "`nextfile' cannot be called from a `%s' rule"
-msgstr "'nextfile' kan niet aangeroepen worden in een '%s'-regel"
-
-#: eval.c:2661
-msgid "`exit' cannot be called in the current context"
-msgstr "'exit' kan niet aangeroepen worden in de huidige context"
-
-#: eval.c:2700
-#, c-format
-msgid "`next' cannot be called from a `%s' rule"
-msgstr "'next' kan niet aangeroepen worden in een '%s'-regel"
-
-#: eval.c:2766
-#, c-format
-msgid "Sorry, don't know how to interpret `%s'"
-msgstr "Kan '%s' niet interpreteren"
-
-#: ext.c:54
+#: ext.c:70
msgid "extensions are not allowed in sandbox mode"
msgstr "uitbreidingen zijn niet toegestaan in sandbox-modus"
-#: ext.c:60 ext.c:65
+#: ext.c:73
msgid "`extension' is a gawk extension"
msgstr "'extension' is een gawk-uitbreiding"
-#: ext.c:75
-#, c-format
-msgid "fatal: extension: cannot open `%s' (%s)\n"
+#: ext.c:80
+#, fuzzy, c-format
+msgid "extension: cannot open library `%s' (%s)\n"
msgstr "fatale fout: extension: kan '%s' niet openen (%s)\n"
-#: ext.c:84
-#, c-format
+#: ext.c:86
+#, fuzzy, c-format
msgid ""
-"fatal: extension: library `%s': does not define "
-"`plugin_is_GPL_compatible' (%s)\n"
+"extension: library `%s': does not define `plugin_is_GPL_compatible' (%s)\n"
msgstr ""
"fatale fout: extension: bibliotheek '%s': definieert "
"'plugin_is_GPL_compatible' niet (%s)\n"
-#: ext.c:93
-#, c-format
-msgid "fatal: extension: library `%s': cannot call function `%s' (%s)\n"
+#: ext.c:90
+#, fuzzy, c-format
+msgid "extension: library `%s': cannot call function `%s' (%s)\n"
msgstr ""
"fatale fout: extension: bibliotheek '%s': kan functie '%s' niet aanroepen "
"(%s)\n"
-#: ext.c:127
+#: ext.c:118
msgid "extension: missing function name"
msgstr "extension: ontbrekende functienaam"
-#: ext.c:132
+#: ext.c:123
#, c-format
msgid "extension: illegal character `%c' in function name `%s'"
msgstr "extension: ongeldig teken '%c' in functienaam '%s'"
-#: ext.c:141
+#: ext.c:131
#, c-format
msgid "extension: can't redefine function `%s'"
msgstr "extension: kan functie '%s' niet herdefiniëren"
-#: ext.c:145
+#: ext.c:135
#, c-format
msgid "extension: function `%s' already defined"
msgstr "extension: functie '%s' is al gedefinieerd"
-#: ext.c:150
+#: ext.c:139
#, c-format
msgid "extension: function name `%s' previously defined"
msgstr "extension: functienaam '%s' is al eerder gedefinieerd"
-#: ext.c:152
+#: ext.c:141
#, c-format
msgid "extension: can't use gawk built-in `%s' as function name"
msgstr "extension: kan in gawk ingebouwde '%s' niet als functienaam gebruiken"
-#: ext.c:156
+#: ext.c:144
#, c-format
msgid "make_builtin: negative argument count for function `%s'"
msgstr "make_builtin: negatief aantal argumenten voor functie '%s'"
-#: ext.c:259
+#: ext.c:206
#, c-format
msgid "function `%s' defined to take no more than %d argument(s)"
msgstr ""
"functie '%s' is gedefinieerd om niet meer dan %d argument(en) te accepteren"
-#: ext.c:262
+#: ext.c:209
#, c-format
msgid "function `%s': missing argument #%d"
msgstr "functie '%s': ontbrekend argument #%d"
-#: ext.c:279
+#: ext.c:226
#, c-format
msgid "function `%s': argument #%d: attempt to use scalar as an array"
msgstr "functie '%s': argument #%d: een scalair wordt gebruikt als array"
-#: ext.c:283
+#: ext.c:230
#, c-format
msgid "function `%s': argument #%d: attempt to use array as a scalar"
msgstr "functie '%s': argument #%d: een array wordt gebruikt als scalair"
-#: ext.c:296
+#: ext.c:244
msgid "Operation Not Supported"
msgstr "Actie wordt niet ondersteund"
-#: field.c:328
+#: ext.c:256
+msgid "dynamic loading of library not supported"
+msgstr ""
+
+#: field.c:339
msgid "NF set to negative value"
msgstr "NF is op een negatieve waarde gezet"
-#: field.c:951 field.c:958 field.c:962
+#: field.c:962 field.c:969 field.c:973
msgid "split: fourth argument is a gawk extension"
msgstr "split: vierde argument is een gawk-uitbreiding"
-#: field.c:955
+#: field.c:966
msgid "split: fourth argument is not an array"
msgstr "split: vierde argument is geen array"
-#: field.c:969
+#: field.c:980
msgid "split: second argument is not an array"
msgstr "split: tweede argument is geen array"
-#: field.c:973
+#: field.c:984
msgid "split: cannot use the same array for second and fourth args"
msgstr ""
"split: hetzelfde array kan niet zowel als tweede als als vierde argument "
"gebruikt worden"
-#: field.c:978
+#: field.c:989
msgid "split: cannot use a subarray of second arg for fourth arg"
msgstr ""
"split: een subarray van het tweede argument kan niet als vierde argument "
"gebruikt worden"
-#: field.c:981
+#: field.c:992
msgid "split: cannot use a subarray of fourth arg for second arg"
msgstr ""
"split: een subarray van het vierde argument kan niet als tweede argument "
"gebruikt worden"
-#: field.c:1010
+#: field.c:1021
msgid "split: null string for third arg is a gawk extension"
msgstr "split: lege string als derde argument is een gawk-uitbreiding"
-#: field.c:1050
+#: field.c:1061
msgid "patsplit: fourth argument is not an array"
msgstr "patsplit: vierde argument is geen array"
-#: field.c:1055
+#: field.c:1066
msgid "patsplit: second argument is not an array"
msgstr "patsplit: tweede argument is geen array"
-#: field.c:1061
+#: field.c:1072
msgid "patsplit: third argument must be non-null"
msgstr "patsplit: derde argument moet niet-nil zijn"
-#: field.c:1065
+#: field.c:1076
msgid "patsplit: cannot use the same array for second and fourth args"
msgstr ""
"patsplit: hetzelfde array kan niet zowel als tweede als als vierde argument "
"gebruikt worden"
-#: field.c:1070
+#: field.c:1081
msgid "patsplit: cannot use a subarray of second arg for fourth arg"
msgstr ""
"patsplit: een subarray van het tweede argument kan niet als vierde argument "
"gebruikt worden"
-#: field.c:1073
+#: field.c:1084
msgid "patsplit: cannot use a subarray of fourth arg for second arg"
msgstr ""
"patsplit: een subarray van het vierde argument kan niet als tweede argument "
"gebruikt worden"
-#: field.c:1110
+#: field.c:1122
msgid "`FIELDWIDTHS' is a gawk extension"
msgstr "'FIELDWIDTHS' is een gawk-uitbreiding"
-#: field.c:1173
+#: field.c:1186
#, c-format
msgid "invalid FIELDWIDTHS value, near `%s'"
msgstr "ongeldige waarde voor FIELDWIDTHS, nabij '%s'"
-#: field.c:1246
+#: field.c:1259
msgid "null string for `FS' is a gawk extension"
msgstr "een lege string als 'FS' is een gawk-uitbreiding"
-#: field.c:1250
+#: field.c:1263
msgid "old awk does not support regexps as value of `FS'"
msgstr "oude 'awk' staat geen reguliere expressies toe als waarde van 'FS'"
-#: field.c:1369
+#: field.c:1382
msgid "`FPAT' is a gawk extension"
msgstr "'FPAT' is een gawk-uitbreiding"
@@ -1350,466 +1246,481 @@ msgstr "%s: optie '-W %s' staat geen argument toe\n"
msgid "%s: option '-W %s' requires an argument\n"
msgstr "%s: optie '-W %s' vereist een argument\n"
-#: io.c:280
+#: io.c:326
#, c-format
msgid "command line argument `%s' is a directory: skipped"
msgstr "opdrachtregelargument '%s' is een map -- overgeslagen"
-#: io.c:283 io.c:385
+#: io.c:329 io.c:438
#, c-format
msgid "cannot open file `%s' for reading (%s)"
msgstr "kan bestand '%s' niet openen om te lezen (%s)"
-#: io.c:501
+#: io.c:568
#, c-format
msgid "close of fd %d (`%s') failed (%s)"
msgstr "sluiten van bestandsdescriptor %d ('%s') is mislukt (%s)"
-#: io.c:578
+#: io.c:645
msgid "redirection not allowed in sandbox mode"
msgstr "omleiding is niet toegestaan in sandbox-modus"
-#: io.c:612
+#: io.c:679
#, c-format
msgid "expression in `%s' redirection only has numeric value"
msgstr "expressie in omleiding '%s' heeft alleen een getal als waarde"
-#: io.c:618
+#: io.c:685
#, c-format
msgid "expression for `%s' redirection has null string value"
msgstr "expressie voor omleiding '%s' heeft een lege string als waarde"
-#: io.c:623
+#: io.c:690
#, c-format
msgid "filename `%s' for `%s' redirection may be result of logical expression"
msgstr ""
"bestandsnaam '%s' voor omleiding '%s' kan het resultaat zijn van een "
"logische expressie"
-#: io.c:666
+#: io.c:733
#, c-format
msgid "unnecessary mixing of `>' and `>>' for file `%.*s'"
msgstr "onnodige mix van '>' en '>>' voor bestand '%.*s'"
-#: io.c:719
+#: io.c:786
#, c-format
msgid "can't open pipe `%s' for output (%s)"
msgstr "kan pijp '%s' niet openen voor uitvoer (%s)"
-#: io.c:729
+#: io.c:796
#, c-format
msgid "can't open pipe `%s' for input (%s)"
msgstr "kan pijp '%s' niet openen voor invoer (%s)"
-#: io.c:752
+#: io.c:819
#, c-format
msgid "can't open two way pipe `%s' for input/output (%s)"
msgstr "kan tweerichtings-pijp '%s' niet openen voor in- en uitvoer (%s)"
-#: io.c:834
+#: io.c:900
#, c-format
msgid "can't redirect from `%s' (%s)"
msgstr "kan niet omleiden van '%s' (%s)"
-#: io.c:837
+#: io.c:903
#, c-format
msgid "can't redirect to `%s' (%s)"
msgstr "kan niet omleiden naar '%s' (%s)"
-#: io.c:888
+#: io.c:954
msgid ""
"reached system limit for open files: starting to multiplex file descriptors"
msgstr ""
"systeemgrens voor aantal open bestanden is bereikt: begonnen met multiplexen"
-#: io.c:904
+#: io.c:970
#, c-format
msgid "close of `%s' failed (%s)."
msgstr "sluiten van '%s' is mislukt (%s)"
-#: io.c:912
+#: io.c:978
msgid "too many pipes or input files open"
msgstr "te veel pijpen of invoerbestanden geopend"
-#: io.c:934
+#: io.c:1000
msgid "close: second argument must be `to' or `from'"
msgstr "close: tweede argument moet 'to' of 'from' zijn"
-#: io.c:951
+#: io.c:1017
#, c-format
msgid "close: `%.*s' is not an open file, pipe or co-process"
msgstr "close: '%.*s' is geen open bestand, pijp, of co-proces"
-#: io.c:956
+#: io.c:1022
msgid "close of redirection that was never opened"
msgstr "sluiten van een nooit-geopende omleiding"
-#: io.c:1053
+#: io.c:1120
#, c-format
msgid "close: redirection `%s' not opened with `|&', second argument ignored"
msgstr ""
"close: omleiding '%s' is niet geopend met '|&'; tweede argument wordt "
"genegeerd"
-#: io.c:1069
+#: io.c:1137
#, c-format
msgid "failure status (%d) on pipe close of `%s' (%s)"
msgstr "afsluitwaarde %d bij mislukte sluiting van pijp '%s' (%s)"
-#: io.c:1072
+#: io.c:1140
#, c-format
msgid "failure status (%d) on file close of `%s' (%s)"
msgstr "afsluitwaarde %d bij mislukte sluiting van bestand '%s' (%s)"
-#: io.c:1092
+#: io.c:1160
#, c-format
msgid "no explicit close of socket `%s' provided"
msgstr "geen expliciete sluiting van socket '%s' aangegeven"
-#: io.c:1095
+#: io.c:1163
#, c-format
msgid "no explicit close of co-process `%s' provided"
msgstr "geen expliciete sluiting van co-proces '%s' aangegeven"
-#: io.c:1098
+#: io.c:1166
#, c-format
msgid "no explicit close of pipe `%s' provided"
msgstr "geen expliciete sluiting van pijp '%s' aangegeven"
-#: io.c:1101
+#: io.c:1169
#, c-format
msgid "no explicit close of file `%s' provided"
msgstr "geen expliciete sluiting van bestand '%s' aangegeven"
-#: io.c:1129 io.c:1184 main.c:794 main.c:831
+#: io.c:1197 io.c:1252 main.c:825 main.c:862
#, c-format
msgid "error writing standard output (%s)"
msgstr "fout tijdens schrijven van standaarduitvoer (%s)"
-#: io.c:1133 io.c:1189
+#: io.c:1201 io.c:1257
#, c-format
msgid "error writing standard error (%s)"
msgstr "fout tijdens schrijven van standaardfoutuitvoer (%s)"
-#: io.c:1141
+#: io.c:1209
#, c-format
msgid "pipe flush of `%s' failed (%s)."
msgstr "leegmaken van pijp '%s' is mislukt (%s)"
-#: io.c:1144
+#: io.c:1212
#, c-format
msgid "co-process flush of pipe to `%s' failed (%s)."
msgstr "leegmaken door co-proces van pijp naar '%s' is mislukt (%s)"
-#: io.c:1147
+#: io.c:1215
#, c-format
msgid "file flush of `%s' failed (%s)."
msgstr "leegmaken van bestand '%s' is mislukt (%s)"
-#: io.c:1262
+#: io.c:1329
#, c-format
msgid "local port %s invalid in `/inet'"
msgstr "lokale poort %s is ongeldig in '/inet'"
-#: io.c:1279
+#: io.c:1347
#, c-format
msgid "remote host and port information (%s, %s) invalid"
msgstr "host- en poortinformatie (%s, %s) zijn ongeldig"
-#: io.c:1431
+#: io.c:1499
#, c-format
msgid "no (known) protocol supplied in special filename `%s'"
msgstr "geen (bekend) protocol aangegeven in speciale bestandsnaam '%s'"
-#: io.c:1445
+#: io.c:1513
#, c-format
msgid "special file name `%s' is incomplete"
msgstr "speciale bestandsnaam '%s' is onvolledig"
-#: io.c:1462
+#: io.c:1530
msgid "must supply a remote hostname to `/inet'"
msgstr "'/inet' heeft een gindse hostnaam nodig"
-#: io.c:1480
+#: io.c:1548
msgid "must supply a remote port to `/inet'"
msgstr "'/inet' heeft een gindse poort nodig"
-#: io.c:1526
+#: io.c:1594
msgid "TCP/IP communications are not supported"
msgstr "TCP/IP-communicatie wordt niet ondersteund"
-#: io.c:1693
+#: io.c:1764
#, c-format
msgid "could not open `%s', mode `%s'"
msgstr "kan '%s' niet openen -- modus '%s'"
-#: io.c:1747
+#: io.c:1814
#, c-format
msgid "close of master pty failed (%s)"
msgstr "kan meester-pty van dochterproces niet sluiten (%s)"
-#: io.c:1749 io.c:1917 io.c:2074
+#: io.c:1816 io.c:1984 io.c:2145
#, c-format
msgid "close of stdout in child failed (%s)"
msgstr "kan standaarduitvoer van dochterproces niet sluiten (%s)"
-#: io.c:1752
+#: io.c:1819
#, c-format
msgid "moving slave pty to stdout in child failed (dup: %s)"
msgstr ""
"kan slaaf-pty niet overzetten naar standaarduitvoer van dochterproces (dup: "
"%s)"
-#: io.c:1754 io.c:1922
+#: io.c:1821 io.c:1989
#, c-format
msgid "close of stdin in child failed (%s)"
msgstr "kan standaardinvoer van dochterproces niet sluiten (%s)"
-#: io.c:1757
+#: io.c:1824
#, c-format
msgid "moving slave pty to stdin in child failed (dup: %s)"
msgstr ""
"kan slaaf-pty niet overzetten naar standaardinvoer van dochterproces (dup: "
"%s)"
-#: io.c:1759 io.c:1780
+#: io.c:1826 io.c:1847
#, c-format
msgid "close of slave pty failed (%s)"
msgstr "kan slaaf-pty niet sluiten (%s)"
-#: io.c:1858 io.c:1920 io.c:2052 io.c:2077
+#: io.c:1925 io.c:1987 io.c:2122 io.c:2148
#, c-format
msgid "moving pipe to stdout in child failed (dup: %s)"
msgstr ""
"kan pijp niet overzetten naar standaarduitvoer van dochterproces (dup: %s)"
-#: io.c:1865 io.c:1925
+#: io.c:1932 io.c:1992
#, c-format
msgid "moving pipe to stdin in child failed (dup: %s)"
msgstr ""
"kan pijp niet overzetten naar standaardinvoer van dochterproces (dup: %s)"
-#: io.c:1885 io.c:2067
+#: io.c:1952 io.c:2138
msgid "restoring stdout in parent process failed\n"
msgstr "kan standaarduitvoer van ouderproces niet herstellen\n"
-#: io.c:1893
+#: io.c:1960
msgid "restoring stdin in parent process failed\n"
msgstr "kan standaardinvoer van ouderproces niet herstellen\n"
-#: io.c:1928 io.c:2079 io.c:2093
+#: io.c:1995 io.c:2150 io.c:2164
#, c-format
msgid "close of pipe failed (%s)"
msgstr "kan pijp niet sluiten (%s)"
-#: io.c:1973
+#: io.c:2040
msgid "`|&' not supported"
msgstr "'|&' wordt niet ondersteund"
-#: io.c:2039
+#: io.c:2107
#, c-format
msgid "cannot open pipe `%s' (%s)"
msgstr "kan pijp '%s' niet openen (%s)"
-#: io.c:2087
+#: io.c:2158
#, c-format
msgid "cannot create child process for `%s' (fork: %s)"
msgstr "kan voor '%s' geen dochterproces starten (fork: %s)"
-#: io.c:2520
+#: io.c:2637
#, c-format
msgid "data file `%s' is empty"
msgstr "databestand '%s' is leeg"
-#: io.c:2561 io.c:2569
+#: io.c:2678 io.c:2686
msgid "could not allocate more input memory"
msgstr "kan geen extra invoergeheugen meer toewijzen"
-#: io.c:3127
+#: io.c:3236
msgid "multicharacter value of `RS' is a gawk extension"
msgstr "een 'RS' van meerdere tekens is een gawk-uitbreiding"
-#: io.c:3232
+#: io.c:3326
msgid "IPv6 communication is not supported"
msgstr "IPv6-communicatie wordt niet ondersteund"
-#: main.c:366
+#: main.c:355
msgid "`-m[fr]' option irrelevant in gawk"
msgstr "optie '-m[fr]' is irrelevant in gawk"
-#: main.c:368
+#: main.c:357
msgid "-m option usage: `-m[fr] nnn'"
msgstr "gebruikswijze van optie -m: '-m[fr] nnn'"
-#: main.c:391
+#: main.c:386
msgid "empty argument to `-e/--source' ignored"
msgstr "argument van '-e/--source' is leeg; genegeerd"
-#: main.c:462
+#: main.c:472
#, c-format
msgid "%s: option `-W %s' unrecognized, ignored\n"
msgstr "%s: optie '-W %s' is onbekend; genegeerd\n"
-#: main.c:515
+#: main.c:518
#, c-format
msgid "%s: option requires an argument -- %c\n"
msgstr "%s: optie vereist een argument -- %c\n"
-#: main.c:536
+#: main.c:539
msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'"
msgstr "omgevingsvariabele 'POSIXLY_CORRECT' is gezet: '--posix' ingeschakeld"
-#: main.c:542
+#: main.c:545
msgid "`--posix' overrides `--traditional'"
msgstr "'--posix' overstijgt '--traditional'"
-#: main.c:553
+#: main.c:556
msgid "`--posix'/`--traditional' overrides `--non-decimal-data'"
msgstr "'--posix'/'--traditional' overstijgen '--non-decimal-data'"
-#: main.c:557
+#: main.c:560
#, c-format
msgid "running %s setuid root may be a security problem"
msgstr "het uitvoeren van %s als 'setuid root' kan een veiligheidsrisico zijn"
-#: main.c:562
+#: main.c:565
msgid "`--posix' overrides `--binary'"
msgstr "'--posix' overstijgt '--binary'"
-#: main.c:613
+#: main.c:623
#, c-format
msgid "can't set binary mode on stdin (%s)"
msgstr "kan standaardinvoer niet in binaire modus zetten (%s)"
-#: main.c:616
+#: main.c:626
#, c-format
msgid "can't set binary mode on stdout (%s)"
msgstr "kan standaarduitvoer niet in binaire modus zetten (%s)"
-#: main.c:618
+#: main.c:628
#, c-format
msgid "can't set binary mode on stderr (%s)"
msgstr "kan standaardfoutuitvoer niet in binaire modus zetten (%s)"
-#: main.c:657
+#: main.c:679
msgid "no program text at all!"
msgstr "helemaal geen programmatekst!"
-#: main.c:734
+#: main.c:763
#, c-format
msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n"
msgstr "Gebruik: %s [opties] -f programmabestand [--] bestand...\n"
-#: main.c:736
+#: main.c:765
#, c-format
msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n"
msgstr ""
" of: %s [opties] [--] %cprogrammatekst%c bestand...\n"
"\n"
-#: main.c:741
+#: main.c:770
msgid "POSIX options:\t\tGNU long options: (standard)\n"
msgstr "\tPOSIX-opties:\t\tEquivalente GNU-opties: (standaard)\n"
-#: main.c:742
+#: main.c:771
msgid "\t-f progfile\t\t--file=progfile\n"
msgstr "\t-f programmabestand\t--file=programmabestand\n"
-#: main.c:743
+#: main.c:772
msgid "\t-F fs\t\t\t--field-separator=fs\n"
msgstr "\t-F veldscheidingsteken\t--field-separator=veldscheidingsteken\n"
-#: main.c:744
+#: main.c:773
msgid "\t-v var=val\t\t--assign=var=val\n"
msgstr ""
"\t-v var=waarde\t\t--assign=var=waarde\n"
"\n"
-#: main.c:745
+#: main.c:774
msgid "Short options:\t\tGNU long options: (extensions)\n"
msgstr "\tKorte opties:\t\tEquivalente GNU-opties: (uitbreidingen)\n"
-#: main.c:746
+#: main.c:775
msgid "\t-b\t\t\t--characters-as-bytes\n"
msgstr "\t-b\t\t\t--characters-as-bytes\n"
-#: main.c:747
+#: main.c:776
msgid "\t-c\t\t\t--traditional\n"
msgstr "\t-c\t\t\t--traditional\n"
-#: main.c:748
+#: main.c:777
msgid "\t-C\t\t\t--copyright\n"
msgstr "\t-C\t\t\t--copyright\n"
-#: main.c:749
+#: main.c:778
msgid "\t-d[file]\t\t--dump-variables[=file]\n"
msgstr "\t-d[bestand]\t\t--dump-variables[=bestand]\n"
-#: main.c:750
+#: main.c:779
+#, fuzzy
+msgid "\t-D[file]\t\t--debug[=file]\n"
+msgstr "\t-p[bestand]\t\t--profile[=bestand]\n"
+
+#: main.c:780
msgid "\t-e 'program-text'\t--source='program-text'\n"
msgstr "\t-e 'programmatekst'\t--source='programmatekst'\n"
-#: main.c:751
+#: main.c:781
msgid "\t-E file\t\t\t--exec=file\n"
msgstr "\t-E bestand\t\t--exec=bestand\n"
-#: main.c:752
+#: main.c:782
msgid "\t-g\t\t\t--gen-pot\n"
msgstr "\t-g\t\t\t--gen-pot\n"
-#: main.c:753
+#: main.c:783
msgid "\t-h\t\t\t--help\n"
msgstr "\t-h\t\t\t--help\n"
-#: main.c:754
+#: main.c:784
+msgid "\t-l library\t\t--load=library\n"
+msgstr ""
+
+#: main.c:785
msgid "\t-L [fatal]\t\t--lint[=fatal]\n"
msgstr "\t-L [fataal]\t\t--lint[=fataal]\n"
-#: main.c:755
+#: main.c:786
msgid "\t-n\t\t\t--non-decimal-data\n"
msgstr "\t-n\t\t\t--non-decimal-data\n"
-#: main.c:756
+#: main.c:787
+#, fuzzy
+msgid "\t-M\t\t\t--bignum\n"
+msgstr "\t-g\t\t\t--gen-pot\n"
+
+#: main.c:788
msgid "\t-N\t\t\t--use-lc-numeric\n"
msgstr "\t-N\t\t\t--use-lc-numeric\n"
-#: main.c:757
+#: main.c:789
+#, fuzzy
+msgid "\t-o[file]\t\t--pretty-print[=file]\n"
+msgstr "\t-p[bestand]\t\t--profile[=bestand]\n"
+
+#: main.c:790
msgid "\t-O\t\t\t--optimize\n"
msgstr "\t-O\t\t\t--optimize\n"
-#: main.c:758
+#: main.c:791
msgid "\t-p[file]\t\t--profile[=file]\n"
msgstr "\t-p[bestand]\t\t--profile[=bestand]\n"
-#: main.c:759
+#: main.c:792
msgid "\t-P\t\t\t--posix\n"
msgstr "\t-P\t\t\t--posix\n"
-#: main.c:760
+#: main.c:793
msgid "\t-r\t\t\t--re-interval\n"
msgstr "\t-r\t\t\t--re-interval\n"
-#: main.c:762
-msgid "\t-R file\t\t\t--command=file\n"
-msgstr "\t-R bestand\t\t\t--command=bestand\n"
-
-#: main.c:763
+#: main.c:794
msgid "\t-S\t\t\t--sandbox\n"
msgstr "\t-S\t\t\t--sandbox\n"
-#: main.c:764
+#: main.c:795
msgid "\t-t\t\t\t--lint-old\n"
msgstr "\t-t\t\t\t--lint-old\n"
-#: main.c:765
+#: main.c:796
msgid "\t-V\t\t\t--version\n"
msgstr "\t-V\t\t\t--version\n"
-#: main.c:767
+#: main.c:798
msgid "\t-W nostalgia\t\t--nostalgia\n"
msgstr "\t-W nostalgia\t\t\t--nostalgia\n"
-#: main.c:770
+#: main.c:801
msgid "\t-Y\t\t--parsedebug\n"
msgstr "\t-Y\t\t\t--parsedebug\n"
@@ -1818,7 +1729,7 @@ msgstr "\t-Y\t\t\t--parsedebug\n"
#. for this application. Please add _another line_ with the
#. address for translation bugs.
#. no-wrap
-#: main.c:779
+#: main.c:810
msgid ""
"\n"
"To report bugs, see node `Bugs' in `gawk.info', which is\n"
@@ -1831,7 +1742,7 @@ msgstr ""
"Meld fouten in de vertaling aan <vertaling@vrijschrift.org>.\n"
"\n"
-#: main.c:783
+#: main.c:814
msgid ""
"gawk is a pattern scanning and processing language.\n"
"By default it reads standard input and writes standard output.\n"
@@ -1841,7 +1752,7 @@ msgstr ""
"Standaard leest het van standaardinvoer en schrijft naar standaarduitvoer.\n"
"\n"
-#: main.c:787
+#: main.c:818
msgid ""
"Examples:\n"
"\tgawk '{ sum += $1 }; END { print sum }' file\n"
@@ -1851,7 +1762,7 @@ msgstr ""
"\tgawk '{ som += $1 }; END { print som }' bestand\n"
"\tgawk -F: '{ print $1 }' /etc/passwd\n"
-#: main.c:807
+#: main.c:838
#, c-format
msgid ""
"Copyright (C) 1989, 1991-%d Free Software Foundation.\n"
@@ -1869,7 +1780,7 @@ msgstr ""
"uitgegeven door de Free Software Foundation, naar keuze ofwel onder\n"
"versie 3 of onder een nieuwere versie van die licentie.\n"
-#: main.c:815
+#: main.c:846
msgid ""
"This program is distributed in the hope that it will be useful,\n"
"but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
@@ -1883,7 +1794,7 @@ msgstr ""
"Zie de GNU General Public License voor meer details.\n"
"\n"
-#: main.c:821
+#: main.c:852
msgid ""
"You should have received a copy of the GNU General Public License\n"
"along with this program. If not, see http://www.gnu.org/licenses/.\n"
@@ -1892,16 +1803,16 @@ msgstr ""
"ontvangen te hebben; is dit niet het geval, dan kunt u deze licentie\n"
"ook vinden op http://www.gnu.org/licenses/.\n"
-#: main.c:856
+#: main.c:887
msgid "-Ft does not set FS to tab in POSIX awk"
msgstr "-Ft maakt van FS geen tab in POSIX-awk"
-#: main.c:1090
+#: main.c:1133
#, c-format
msgid "unknown value for field spec: %d\n"
msgstr "onbekende waarde voor veldspecificatie: %d\n"
-#: main.c:1171
+#: main.c:1214
#, c-format
msgid ""
"%s: `%s' argument to `-v' not in `var=value' form\n"
@@ -1910,79 +1821,79 @@ msgstr ""
"%s: argument '%s' van '-v' is niet van de vorm 'var=waarde'\n"
"\n"
-#: main.c:1197
+#: main.c:1240
#, c-format
msgid "`%s' is not a legal variable name"
msgstr "'%s' is geen geldige variabelenaam"
-#: main.c:1200
+#: main.c:1243
#, c-format
msgid "`%s' is not a variable name, looking for file `%s=%s'"
msgstr "'%s' is geen variabelenaam; zoekend naar bestand '%s=%s'"
-#: main.c:1204
+#: main.c:1247
#, c-format
msgid "cannot use gawk builtin `%s' as variable name"
msgstr "kan in gawk ingebouwde '%s' niet als variabelenaam gebruiken"
-#: main.c:1209
+#: main.c:1252
#, c-format
msgid "cannot use function `%s' as variable name"
msgstr "kan functie '%s' niet als variabelenaam gebruiken"
-#: main.c:1262
+#: main.c:1305
msgid "floating point exception"
msgstr "drijvendekomma-berekeningsfout"
-#: main.c:1269
+#: main.c:1312
msgid "fatal error: internal error"
msgstr "fatale fout: **interne fout**"
-#: main.c:1284
+#: main.c:1327
msgid "fatal error: internal error: segfault"
msgstr "fatale fout: **interne fout**: segmentatiefout"
-#: main.c:1296
+#: main.c:1339
msgid "fatal error: internal error: stack overflow"
msgstr "fatale fout: **interne fout**: stack is vol"
-#: main.c:1346
+#: main.c:1393
#, c-format
msgid "no pre-opened fd %d"
msgstr "geen reeds-geopende bestandsdescriptor %d"
-#: main.c:1353
+#: main.c:1400
#, c-format
msgid "could not pre-open /dev/null for fd %d"
msgstr "kan /dev/null niet openen voor bestandsdescriptor %d"
-#: msg.c:63
+#: msg.c:61
#, c-format
msgid "cmd. line:"
msgstr "commandoregel:"
-#: msg.c:107
+#: msg.c:121
msgid "error: "
msgstr "fout: "
-#: node.c:406
+#: node.c:436
msgid "backslash at end of string"
msgstr "backslash aan het einde van de string"
-#: node.c:517
+#: node.c:520
#, c-format
msgid "old awk does not support the `\\%c' escape sequence"
msgstr "oude 'awk' kent de stuurcodereeks '\\%c' niet"
-#: node.c:568
+#: node.c:571
msgid "POSIX does not allow `\\x' escapes"
msgstr "POSIX staat stuurcode '\\x' niet toe"
-#: node.c:574
+#: node.c:577
msgid "no hex digits in `\\x' escape sequence"
msgstr "geen hex cijfers in stuurcodereeks '\\x'"
-#: node.c:596
+#: node.c:599
#, c-format
msgid ""
"hex escape \\x%.*s of %d characters probably not interpreted the way you "
@@ -1991,12 +1902,12 @@ msgstr ""
"hexadecimale stuurcode \\x%.*s van %d tekens wordt waarschijnlijk niet "
"afgehandeld zoals u verwacht"
-#: node.c:611
+#: node.c:614
#, c-format
msgid "escape sequence `\\%c' treated as plain `%c'"
msgstr "stuurcodereeks '\\%c' behandeld als normale '%c'"
-#: node.c:750
+#: node.c:759
msgid ""
"Invalid multibyte data detected. There may be a mismatch between your data "
"and your locale."
@@ -2016,16 +1927,16 @@ msgstr ""
msgid "%s %s `%s': could not set close-on-exec: (fcntl F_SETFD: %s)"
msgstr "%s %s '%s': kan 'close-on-exec' niet activeren: (fcntl F_SETFD: %s)"
-#: profile.c:83
+#: profile.c:69
#, c-format
msgid "could not open `%s' for writing: %s"
msgstr "kan '%s' niet openen om te schrijven: %s"
-#: profile.c:85
+#: profile.c:71
msgid "sending profile to standard error"
msgstr "profiel gaat naar standaardfoutuitvoer"
-#: profile.c:203
+#: profile.c:187
#, c-format
msgid ""
"\t# %s block(s)\n"
@@ -2034,7 +1945,7 @@ msgstr ""
"\t# %s-blok(ken)\n"
"\n"
-#: profile.c:208
+#: profile.c:192
#, c-format
msgid ""
"\t# Rule(s)\n"
@@ -2043,17 +1954,22 @@ msgstr ""
"\t# Regel(s)\n"
"\n"
-#: profile.c:279
+#: profile.c:266
#, c-format
msgid "internal error: %s with null vname"
msgstr "**interne fout**: %s heeft een lege 'vname'"
-#: profile.c:952
+#: profile.c:528
+#, fuzzy
+msgid "internal error: builtin with null fname"
+msgstr "**interne fout**: %s heeft een lege 'vname'"
+
+#: profile.c:943
#, c-format
msgid "\t# gawk profile, created %s\n"
msgstr "\t# gawk-profiel, gemaakt op %s\n"
-#: profile.c:1331
+#: profile.c:1328
#, c-format
msgid ""
"\n"
@@ -2062,19 +1978,19 @@ msgstr ""
"\n"
"\t# Functies, alfabetisch geordend\n"
-#: profile.c:1370
+#: profile.c:1366
#, c-format
msgid "redir2str: unknown redirection type %d"
msgstr "redir2str(): onbekend omleidingstype %d"
-#: re.c:573
+#: re.c:571
#, c-format
msgid "range of the form `[%c-%c]' is locale dependent"
msgstr ""
"de betekenis van een bereik van de vorm '[%c-%c]' is afhankelijk van de "
"taalregio"
-#: re.c:600
+#: re.c:598
#, c-format
msgid "regexp component `%.*s' should probably be `[%.*s]'"
msgstr ""
@@ -2152,6 +2068,78 @@ msgstr "Ongepaarde ) of \\)"
msgid "No previous regular expression"
msgstr "Geen eerdere reguliere expressie"
+#~ msgid "attempt to use function `%s' as an array"
+#~ msgstr "functie '%s' wordt gebruikt als array"
+
+#~ msgid "reference to uninitialized element `%s[\"%.*s\"]'"
+#~ msgstr "verwijzing naar ongeïnitialiseerd element '%s[\"%.*s\"]'"
+
+#~ msgid "subscript of array `%s' is null string"
+#~ msgstr "index van array '%s' is lege string"
+
+#~ msgid "%s: empty (null)\n"
+#~ msgstr "%s: leeg (nil)\n"
+
+#~ msgid "%s: empty (zero)\n"
+#~ msgstr "%s: leeg (nul)\n"
+
+#~ msgid "%s: table_size = %d, array_size = %d\n"
+#~ msgstr "%s: tabelgrootte = %d, arraygrootte = %d\n"
+
+#~ msgid "%s: is parameter\n"
+#~ msgstr "%s: is een parameter\n"
+
+#~ msgid "%s: array_ref to %s\n"
+#~ msgstr "%s: array-verwijzing naar %s\n"
+
+#~ msgid "use of non-array as array"
+#~ msgstr "non-array wordt gebruikt als array"
+
+#~ msgid "can't use function name `%s' as variable or array"
+#~ msgstr "kan functienaam '%s' niet als variabele of array gebruiken"
+
+#~ msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
+#~ msgstr "array '%s[\"%.*s\"]' wordt gebruikt in een scalaire context"
+
+#~ msgid "assignment used in conditional context"
+#~ msgstr "toewijzing wordt gebruikt in een conditionele context"
+
+#~ msgid "statement has no effect"
+#~ msgstr "opdracht heeft geen effect"
+
+#~ msgid ""
+#~ "for loop: array `%s' changed size from %ld to %ld during loop execution"
+#~ msgstr ""
+#~ "for: array '%s' veranderde van grootte %ld naar %ld tijdens uitvoer van "
+#~ "de lus"
+
+#~ msgid "function called indirectly through `%s' does not exist"
+#~ msgstr "indirect (via '%s') aangeroepen functie bestaat niet"
+
+#~ msgid "function `%s' not defined"
+#~ msgstr "functie '%s' is niet gedefinieerd"
+
+#~ msgid "non-redirected `getline' invalid inside `%s' rule"
+#~ msgstr "niet-omgeleide 'getline' is ongeldig binnen een '%s'-regel"
+
+#~ msgid "error reading input file `%s': %s"
+#~ msgstr "fout tijdens lezen van invoerbestand '%s': %s"
+
+#~ msgid "`nextfile' cannot be called from a `%s' rule"
+#~ msgstr "'nextfile' kan niet aangeroepen worden in een '%s'-regel"
+
+#~ msgid "`exit' cannot be called in the current context"
+#~ msgstr "'exit' kan niet aangeroepen worden in de huidige context"
+
+#~ msgid "`next' cannot be called from a `%s' rule"
+#~ msgstr "'next' kan niet aangeroepen worden in een '%s'-regel"
+
+#~ msgid "Sorry, don't know how to interpret `%s'"
+#~ msgstr "Kan '%s' niet interpreteren"
+
+#~ msgid "\t-R file\t\t\t--command=file\n"
+#~ msgstr "\t-R bestand\t\t\t--command=bestand\n"
+
#~ msgid "could not find groups: %s"
#~ msgstr "kan groepen niet vinden: %s"
diff --git a/po/pl.gmo b/po/pl.gmo
index 549de4f7..d7272593 100644
--- a/po/pl.gmo
+++ b/po/pl.gmo
Binary files differ
diff --git a/po/pl.po b/po/pl.po
index fb71cae5..edd132ae 100644
--- a/po/pl.po
+++ b/po/pl.po
@@ -9,7 +9,7 @@ msgid ""
msgstr ""
"Project-Id-Version: gawk 4.0.0h\n"
"Report-Msgid-Bugs-To: arnold@skeeve.com\n"
-"POT-Creation-Date: 2012-03-28 22:03+0200\n"
+"POT-Creation-Date: 2012-04-27 10:06+0300\n"
"PO-Revision-Date: 2012-02-04 19:17+0100\n"
"Last-Translator: Wojciech Polak <polak@gnu.org>\n"
"Language-Team: Polish <translation-team-pl@lists.sourceforge.net>\n"
@@ -20,514 +20,471 @@ msgstr ""
"Plural-Forms: nplurals=3; plural=(n==1 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 "
"|| n%100>=20) ? 1 : 2);\n"
-#: array.c:140
+#: array.c:266
#, c-format
msgid "from %s"
msgstr "od %s"
-#: array.c:248
+#: array.c:366
msgid "attempt to use a scalar value as array"
msgstr "próba użycia wartości skalarnej jako tablicy"
-#: array.c:251
-#, c-format
-msgid "attempt to use function `%s' as an array"
-msgstr "próba użycia funkcji `%s' jako tablicy"
-
-#: array.c:254
+#: array.c:368
#, c-format
msgid "attempt to use scalar parameter `%s' as an array"
msgstr "próba użycia parametru `%s' skalaru jako tablicy"
-#: array.c:257
+#: array.c:371
#, c-format
msgid "attempt to use scalar `%s' as an array"
msgstr "próba użycia skalaru `%s' jako tablicy"
-#: array.c:302 array.c:707 builtin.c:84 builtin.c:1385 builtin.c:1427
-#: builtin.c:1440 builtin.c:1859 builtin.c:1871 eval.c:1135 eval.c:1139
-#: eval.c:1495 eval.c:1812
+#: array.c:418 array.c:584 builtin.c:85 builtin.c:1560 builtin.c:1602
+#: builtin.c:1615 builtin.c:2041 builtin.c:2053 eval.c:1109 eval.c:1113
+#: eval.c:1508
#, c-format
msgid "attempt to use array `%s' in a scalar context"
msgstr "próba użycia tablicy `%s' w kontekście skalaru"
-#: array.c:513
-#, c-format
-msgid "reference to uninitialized element `%s[\"%.*s\"]'"
-msgstr "odwołanie do niezainicjowanego elementu `%s[\"%.*s\"]'"
-
-#: array.c:519
-#, c-format
-msgid "subscript of array `%s' is null string"
-msgstr "indeks tablicy `%s' jest zerowym łańcuchem"
-
-#: array.c:723
+#: array.c:591
#, c-format
msgid "delete: index `%s' not in array `%s'"
msgstr "delete: indeks `%s' nie jest w tablicy `%s'"
-#: array.c:734 eval.c:1865
+#: array.c:605
#, c-format
msgid "attempt to use scalar `%s[\"%.*s\"]' as an array"
msgstr "próba użycia skalaru `%s[\"%.*s\"]' jako tablicy"
-#: array.c:910
-#, c-format
-msgid "%s: empty (null)\n"
-msgstr "%s: pusty (null)\n"
-
-#: array.c:915
-#, c-format
-msgid "%s: empty (zero)\n"
-msgstr "%s: pusty (zero)\n"
-
-#: array.c:919
-#, c-format
-msgid "%s: table_size = %d, array_size = %d\n"
-msgstr "%s: table_size = %d, array_size = %d\n"
-
-#: array.c:954
-#, c-format
-msgid "%s: is parameter\n"
-msgstr "%s: jest parametrem\n"
-
-#: array.c:958
-#, c-format
-msgid "%s: array_ref to %s\n"
-msgstr "%s: array_ref do %s\n"
-
-#: array.c:963
-msgid "adump: argument not an array"
+#: array.c:784
+#, fuzzy
+msgid "adump: first argument not an array"
msgstr "adump: argument nie jest tablicÄ…"
-#: array.c:1086
+#: array.c:823
msgid "asort: second argument not an array"
msgstr "asort: drugi argument nie jest tablicÄ…"
-#: array.c:1087
+#: array.c:824
msgid "asorti: second argument not an array"
msgstr "asorti: drugi argument nie jest tablicÄ…"
-#: array.c:1094
+#: array.c:831
msgid "asort: first argument not an array"
msgstr "asort: pierwszy argument nie jest tablicÄ…"
-#: array.c:1095
+#: array.c:832
msgid "asorti: first argument not an array"
msgstr "asorti: pierwszy argument nie jest tablicÄ…"
-#: array.c:1102
+#: array.c:839
msgid "asort: cannot use a subarray of first arg for second arg"
msgstr ""
"asort: nie można użyć podtablicy pierwszego argumentu dla drugiego argumentu"
-#: array.c:1103
+#: array.c:840
msgid "asorti: cannot use a subarray of first arg for second arg"
msgstr ""
"asorti: nie można użyć podtablicy pierwszego argumentu dla drugiego argumentu"
-#: array.c:1108
+#: array.c:845
msgid "asort: cannot use a subarray of second arg for first arg"
msgstr ""
"asort: nie można użyć podtablicy drugiego argumentu dla pierwszego argumentu"
-#: array.c:1109
+#: array.c:846
msgid "asorti: cannot use a subarray of second arg for first arg"
msgstr ""
"asorti: nie można użyć podtablicy drugiego argumentu dla pierwszego argumentu"
-#: array.c:1655
+#: array.c:1314
#, c-format
msgid "`%s' is invalid as a function name"
msgstr "nieprawidłowa nazwa funkcji `%s'"
-#: array.c:1659
+#: array.c:1318
#, c-format
msgid "sort comparison function `%s' is not defined"
msgstr "funkcja porównująca w sortowaniu `%s' nie została zdefiniowna"
-#: awkgram.y:249
+#: awkgram.y:223
#, c-format
msgid "%s blocks must have an action part"
msgstr "%s bloków musi posiadać część dotyczącą akcji"
-#: awkgram.y:252
+#: awkgram.y:226
msgid "each rule must have a pattern or an action part"
msgstr "każda reguła musi posiadać wzorzec lub część dotyczącą akcji"
-#: awkgram.y:323 awkgram.y:334
+#: awkgram.y:295 awkgram.y:306
msgid "old awk does not support multiple `BEGIN' or `END' rules"
msgstr "stary awk nie wspiera wielokrotnych reguł `BEGIN' lub `END'"
-#: awkgram.y:371
+#: awkgram.y:343
#, c-format
msgid "`%s' is a built-in function, it cannot be redefined"
msgstr ""
"`%s' jest funkcją wbudowaną, więc nie może zostać ponownie zdefiniowana"
-#: awkgram.y:432
+#: awkgram.y:389
msgid "regexp constant `//' looks like a C++ comment, but is not"
msgstr ""
"stałe wyrażenie regularne `//' wygląda jak komentarz C++, ale nim nie jest"
-#: awkgram.y:436
+#: awkgram.y:393
#, c-format
msgid "regexp constant `/%s/' looks like a C comment, but is not"
msgstr ""
"stałe wyrażenie regularne `/%s/' wygląda jak komentarz C, ale nim nie jest"
-#: awkgram.y:528
+#: awkgram.y:485
#, c-format
msgid "duplicate case values in switch body: %s"
msgstr "powielone wartości case w ciele switch: %s"
-#: awkgram.y:549
+#: awkgram.y:506
msgid "duplicate `default' detected in switch body"
msgstr "wykryto powielony `default' w ciele switch"
-#: awkgram.y:809
+#: awkgram.y:766
msgid "`break' is not allowed outside a loop or switch"
msgstr "instrukcja `break' poza pętlą lub switch'em jest niedozwolona"
-#: awkgram.y:818
+#: awkgram.y:775
msgid "`continue' is not allowed outside a loop"
msgstr "instrukcja `continue' poza pętlą jest niedozwolona"
-#: awkgram.y:828
+#: awkgram.y:785
#, c-format
msgid "`next' used in %s action"
msgstr "`next' użyty w akcji %s"
-#: awkgram.y:836
+#: awkgram.y:793
msgid "`nextfile' is a gawk extension"
msgstr "`nextfile' jest rozszerzeniem gawk"
-#: awkgram.y:841
+#: awkgram.y:798
#, c-format
msgid "`nextfile' used in %s action"
msgstr "`nextfile' użyty w akcji %s"
-#: awkgram.y:865
+#: awkgram.y:822
msgid "`return' used outside function context"
msgstr "`return' użyty poza kontekstem funkcji"
-#: awkgram.y:925
+#: awkgram.y:896
msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'"
msgstr ""
"zwykły `print' w regułach BEGIN lub END powinien prawdopodobnie być jako "
"`print \"\"'"
-#: awkgram.y:995 awkgram.y:999 awkgram.y:1023
+#: awkgram.y:966 awkgram.y:970 awkgram.y:994
msgid "`delete array' is a gawk extension"
msgstr "`delete tablica' jest rozszerzeniem gawk"
-#: awkgram.y:1019
+#: awkgram.y:990
msgid "`delete(array)' is a non-portable tawk extension"
msgstr "`delete(tablica)' jest nieprzenośnym rozszerzeniem tawk"
-#: awkgram.y:1135
+#: awkgram.y:1108
msgid "multistage two-way pipelines don't work"
msgstr "wieloetapowe dwukierunkowe linie potokowe nie działają"
-#: awkgram.y:1238
+#: awkgram.y:1211
msgid "regular expression on right of assignment"
msgstr "wyrażanie regularne po prawej stronie przypisania"
-#: awkgram.y:1249
+#: awkgram.y:1222
msgid "regular expression on left of `~' or `!~' operator"
msgstr "wyrażenie regularne po lewej stronie operatora `~' lub `!~'"
-#: awkgram.y:1265 awkgram.y:1419
+#: awkgram.y:1238 awkgram.y:1389
msgid "old awk does not support the keyword `in' except after `for'"
msgstr ""
"stary awk nie wspiera słowa kluczowego `in', z wyjątkiem po słowie `for'"
-#: awkgram.y:1275
+#: awkgram.y:1248
msgid "regular expression on right of comparison"
msgstr "wyrażenie regularne po prawej stronie porównania"
-#: awkgram.y:1394
+#: awkgram.y:1364
#, c-format
msgid "`getline var' invalid inside `%s' rule"
msgstr "nieprawidłowy `getline var' wewnątrz reguły `%s'"
-#: awkgram.y:1397 eval.c:2504
+#: awkgram.y:1367
#, c-format
msgid "`getline' invalid inside `%s' rule"
msgstr "nieprawidłowy `getline' wewnątrz reguły `%s'"
-#: awkgram.y:1402
+#: awkgram.y:1372
msgid "non-redirected `getline' undefined inside END action"
msgstr ""
"komenda `getline' bez przekierowania nie jest zdefiniowana wewnÄ…trz akcji END"
-#: awkgram.y:1421
+#: awkgram.y:1391
msgid "old awk does not support multidimensional arrays"
msgstr "stary awk nie wspiera wielowymiarowych tablic"
-#: awkgram.y:1517
+#: awkgram.y:1488
msgid "call of `length' without parentheses is not portable"
msgstr "wywołanie `length' bez nawiasów jest nieprzenośne"
-#: awkgram.y:1580
+#: awkgram.y:1554
msgid "indirect function calls are a gawk extension"
msgstr "pośrednie wywołania funkcji są rozszerzeniem gawk"
-#: awkgram.y:1593
+#: awkgram.y:1567
#, c-format
msgid "can not use special variable `%s' for indirect function call"
msgstr ""
"nie można użyć specjalnej zmiennej `%s' do pośredniego wywołania funkcji"
-#: awkgram.y:1671
+#: awkgram.y:1645
msgid "invalid subscript expression"
msgstr "nieprawidłowe wyrażenie indeksowe"
-#: awkgram.y:1711
-msgid "use of non-array as array"
-msgstr "użycie nie-tablicy jako tablicy"
-
-#: awkgram.y:1975 awkgram.y:1995 msg.c:98
+#: awkgram.y:1966 awkgram.y:1986 msg.c:112
msgid "warning: "
msgstr "ostrzeżenie: "
-#: awkgram.y:1993 msg.c:130
+#: awkgram.y:1984 msg.c:144
msgid "fatal: "
msgstr "fatalny błąd: "
-#: awkgram.y:2043
+#: awkgram.y:2034
msgid "unexpected newline or end of string"
msgstr "niespodziewany znak nowego wiersza lub końca łańcucha"
-#: awkgram.y:2300 awkgram.y:2358 awkgram.y:2542
+#: awkgram.y:2299 awkgram.y:2357 awkgram.y:2545
#, c-format
msgid "can't open source file `%s' for reading (%s)"
msgstr "nie można otworzyć pliku źródłowego `%s' do czytania (%s)"
-#: awkgram.y:2301 awkgram.y:2359 builtin.c:122
+#: awkgram.y:2300 awkgram.y:2358 builtin.c:124
msgid "reason unknown"
msgstr "nieznany powód"
-#: awkgram.y:2317
+#: awkgram.y:2316
#, c-format
msgid "already included source file `%s'"
msgstr "plik źródłowy `%s' jest już załączony"
-#: awkgram.y:2343
+#: awkgram.y:2342
msgid "@include is a gawk extension"
msgstr "@include jest rozszerzeniem gawk"
-#: awkgram.y:2349
+#: awkgram.y:2348
msgid "empty filename after @include"
msgstr "pusta nazwa pliku po @include"
-#: awkgram.y:2494
+#: awkgram.y:2497
msgid "empty program text on command line"
msgstr "pusty tekst programu w linii poleceń"
-#: awkgram.y:2609
+#: awkgram.y:2612
#, c-format
msgid "can't read sourcefile `%s' (%s)"
msgstr "nie można otworzyć pliku źródłowego `%s' (%s)"
-#: awkgram.y:2620
+#: awkgram.y:2623
#, c-format
msgid "source file `%s' is empty"
msgstr "plik źródłowy `%s' jest pusty"
-#: awkgram.y:2797
+#: awkgram.y:2800
msgid "source file does not end in newline"
msgstr "plik źródłowy nie posiada na końcu znaku nowego wiersza"
-#: awkgram.y:2900
+#: awkgram.y:2905
msgid "unterminated regexp ends with `\\' at end of file"
msgstr ""
"niezakończone prawidłowo wyrażenie regularne kończy się znakiem `\\' na "
"końcu pliku"
-#: awkgram.y:2924
+#: awkgram.y:2929
#, c-format
msgid "%s: %d: tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr ""
"%s: %d: modyfikator wyrażenia regularnego `/.../%c' tawk nie działa w gawk"
-#: awkgram.y:2928
+#: awkgram.y:2933
#, c-format
msgid "tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr "modyfikator wyrażenia regularnego `/.../%c' tawk nie działa w gawk"
-#: awkgram.y:2935
+#: awkgram.y:2940
msgid "unterminated regexp"
msgstr "niezakończone wyrażenie regularne"
-#: awkgram.y:2939
+#: awkgram.y:2944
msgid "unterminated regexp at end of file"
msgstr "niezakończone wyrażenie regularne na końcu pliku"
-#: awkgram.y:2998
+#: awkgram.y:3003
msgid "use of `\\ #...' line continuation is not portable"
msgstr "użycie `\\ #...' kontynuacji linii nie jest przenośne"
-#: awkgram.y:3014
+#: awkgram.y:3019
msgid "backslash not last character on line"
msgstr "backslash nie jest ostatnim znakiem w wierszu"
-#: awkgram.y:3075
+#: awkgram.y:3080
msgid "POSIX does not allow operator `**='"
msgstr "POSIX nie zezwala na operator `**='"
-#: awkgram.y:3077
+#: awkgram.y:3082
msgid "old awk does not support operator `**='"
msgstr "stary awk nie wspiera operatora `**='"
-#: awkgram.y:3086
+#: awkgram.y:3091
msgid "POSIX does not allow operator `**'"
msgstr "POSIX nie zezwala na operator `**'"
-#: awkgram.y:3088
+#: awkgram.y:3093
msgid "old awk does not support operator `**'"
msgstr "stary awk nie wspiera operatora `**'"
-#: awkgram.y:3123
+#: awkgram.y:3128
msgid "operator `^=' is not supported in old awk"
msgstr "operator `^=' nie jest wspierany w starym awk"
-#: awkgram.y:3131
+#: awkgram.y:3136
msgid "operator `^' is not supported in old awk"
msgstr "operator `^' nie jest wspierany w starym awk"
-#: awkgram.y:3224 awkgram.y:3240
+#: awkgram.y:3229 awkgram.y:3245
msgid "unterminated string"
msgstr "niezakończony łańcuch"
-#: awkgram.y:3436
+#: awkgram.y:3466
#, c-format
msgid "invalid char '%c' in expression"
msgstr "nieprawidłowy znak '%c' w wyrażeniu"
-#: awkgram.y:3483
+#: awkgram.y:3513
#, c-format
msgid "`%s' is a gawk extension"
msgstr "`%s' jest rozszerzeniem gawk"
-#: awkgram.y:3488
+#: awkgram.y:3518
#, c-format
msgid "`%s' is a Bell Labs extension"
msgstr "`%s' jest rozszerzeniem Bell Labs"
-#: awkgram.y:3493
+#: awkgram.y:3523
#, c-format
msgid "POSIX does not allow `%s'"
msgstr "POSIX nie zezwala na `%s'"
-#: awkgram.y:3501
+#: awkgram.y:3531
#, c-format
msgid "`%s' is not supported in old awk"
msgstr "`%s' nie jest wspierany w starym awk"
-#: awkgram.y:3568
+#: awkgram.y:3598
msgid "`goto' considered harmful!\n"
msgstr "`goto' uważane za szkodliwe!\n"
-#: awkgram.y:3619
+#: awkgram.y:3632
#, c-format
msgid "%d is invalid as number of arguments for %s"
msgstr "%d jest nieprawidłowe jako liczba argumentów dla %s"
-#: awkgram.y:3654
+#: awkgram.y:3667
#, c-format
msgid "%s: string literal as last arg of substitute has no effect"
msgstr ""
"%s: literał łańcuchowy jako ostatni argument podstawienia nie ma żadnego "
"efektu"
-#: awkgram.y:3659
+#: awkgram.y:3672
#, c-format
msgid "%s third parameter is not a changeable object"
msgstr "%s trzeci parametr nie jest zmiennym obiektem"
-#: awkgram.y:3732 awkgram.y:3735
+#: awkgram.y:3751 awkgram.y:3754
msgid "match: third argument is a gawk extension"
msgstr "match: trzeci argument jest rozszerzeniem gawk"
-#: awkgram.y:3789 awkgram.y:3792
+#: awkgram.y:3808 awkgram.y:3811
msgid "close: second argument is a gawk extension"
msgstr "close: drugi argument jest rozszerzeniem gawk"
-#: awkgram.y:3804
+#: awkgram.y:3823
msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore"
msgstr "nieprawidłowe użycie dcgettext(_\"...\"): usuń znak podkreślenia"
-#: awkgram.y:3819
+#: awkgram.y:3838
msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore"
msgstr "nieprawidłowe użycie dcngettext(_\"...\"): usuń znak podkreślenia"
-#: awkgram.y:3911
-#, c-format
-msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
-msgstr "funkcja `%s': parametr #%d, `%s', powiela parametr #%d"
-
-#: awkgram.y:3953
+#: awkgram.y:3904
#, c-format
msgid "function `%s': parameter `%s' shadows global variable"
msgstr "funkcja `%s': parametr `%s' zasłania globalną zmienną"
-#: awkgram.y:4111
+#: awkgram.y:3961
#, c-format
msgid "could not open `%s' for writing (%s)"
msgstr "nie można otworzyć `%s' do zapisu (%s)"
-#: awkgram.y:4112
+#: awkgram.y:3962
msgid "sending variable list to standard error"
msgstr "wysyłanie listy zmiennych na standardowe wyjście diagnostyczne"
-#: awkgram.y:4118
+#: awkgram.y:3970
#, c-format
msgid "%s: close failed (%s)"
msgstr "%s: zamknięcie nie powiodło się (%s)"
-#: awkgram.y:4170
+#: awkgram.y:3995
msgid "shadow_funcs() called twice!"
msgstr "shadow_funcs() wywołana podwójnie!"
-#: awkgram.y:4176
+#: awkgram.y:4003
msgid "there were shadowed variables."
msgstr "wystąpiły przykryte zmienne."
-#: awkgram.y:4206
+#: awkgram.y:4074
+#, c-format
+msgid "function name `%s' previously defined"
+msgstr "nazwa funkcji `%s' została zdefiniowana poprzednio"
+
+#: awkgram.y:4120
#, c-format
msgid "function `%s': can't use function name as parameter name"
msgstr "funkcja `%s': nie można użyć nazwy funkcji jako nazwy parametru"
-#: awkgram.y:4210
+#: awkgram.y:4123
#, c-format
msgid "function `%s': can't use special variable `%s' as a function parameter"
msgstr ""
"funkcja `%s': nie można użyć specjalnej zmiennej `%s' jako parametru funkcji"
-#: awkgram.y:4226
+#: awkgram.y:4131
#, c-format
-msgid "function name `%s' previously defined"
-msgstr "nazwa funkcji `%s' została zdefiniowana poprzednio"
+msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
+msgstr "funkcja `%s': parametr #%d, `%s', powiela parametr #%d"
-#: awkgram.y:4394 awkgram.y:4400
+#: awkgram.y:4210 awkgram.y:4216
#, c-format
msgid "function `%s' called but never defined"
msgstr "funkcja `%s' została wywołana, ale nigdy nie została zdefiniowana"
-#: awkgram.y:4403
+#: awkgram.y:4219
#, c-format
msgid "function `%s' defined but never called directly"
msgstr ""
"funkcja `%s' została zdefiniowana, ale nigdy nie została wywołana "
"bezpośrednio"
-#: awkgram.y:4435
+#: awkgram.y:4251
#, c-format
msgid "regexp constant for parameter #%d yields boolean value"
msgstr "stałe wyrażenie regularne dla parametru #%d daje wartość logiczną"
-#: awkgram.y:4544
+#: awkgram.y:4297
#, c-format
msgid ""
"function `%s' called with space between name and `(',\n"
@@ -537,233 +494,233 @@ msgstr ""
"`(',\n"
"lub użyta jako zmienna lub jako tablica"
-#: awkgram.y:4791 eval.c:2056
+#: awkgram.y:4505
msgid "division by zero attempted"
msgstr "próba dzielenia przez zero"
-#: awkgram.y:4800 eval.c:2072
+#: awkgram.y:4514
#, c-format
msgid "division by zero attempted in `%%'"
msgstr "próba dzielenia przez zero w `%%'"
-#: builtin.c:120
+#: builtin.c:122
#, c-format
msgid "%s to \"%s\" failed (%s)"
msgstr "%s do \"%s\" nie powiódł się (%s)"
-#: builtin.c:121
+#: builtin.c:123
msgid "standard output"
msgstr "standardowe wyjście"
-#: builtin.c:135
+#: builtin.c:137
msgid "exp: received non-numeric argument"
msgstr "exp: otrzymano argument nie będący liczbą"
-#: builtin.c:141
+#: builtin.c:143
#, c-format
msgid "exp: argument %g is out of range"
msgstr "exp: argument %g jest poza zasięgiem"
-#: builtin.c:200
+#: builtin.c:202
#, c-format
msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing"
msgstr ""
"fflush: nie można opróżnić: potok `%s' otwarty do czytania, a nie do zapisu"
-#: builtin.c:203
+#: builtin.c:205
#, c-format
msgid "fflush: cannot flush: file `%s' opened for reading, not writing"
msgstr ""
"fflush: nie można opróżnić: plik `%s' otwarty do czytania, a nie do zapisu"
-#: builtin.c:215
+#: builtin.c:217
#, c-format
msgid "fflush: `%s' is not an open file, pipe or co-process"
msgstr "fflush: `%s' nie jest ani otwartym plikiem, ani potokiem, ani procesem"
-#: builtin.c:333
+#: builtin.c:335
msgid "index: received non-string first argument"
msgstr "index: otrzymano pierwszy argument, który nie jest łańcuchem"
-#: builtin.c:335
+#: builtin.c:337
msgid "index: received non-string second argument"
msgstr "index: otrzymano drugi argument, który nie jest łańcuchem"
-#: builtin.c:457
+#: builtin.c:461
msgid "int: received non-numeric argument"
msgstr "int: otrzymano argument, który nie jest liczbą"
-#: builtin.c:493
+#: builtin.c:497
msgid "length: received array argument"
msgstr "length: otrzymano argument, który jest tablicą"
-#: builtin.c:496
+#: builtin.c:500
msgid "`length(array)' is a gawk extension"
msgstr "`length(tablica)' jest rozszerzeniem gawk"
-#: builtin.c:504
+#: builtin.c:508
msgid "length: received non-string argument"
msgstr "length: otrzymano argument, który nie jest łańcuchem"
-#: builtin.c:535
+#: builtin.c:539
msgid "log: received non-numeric argument"
msgstr "log: otrzymano argument, który nie jest liczbą"
-#: builtin.c:538
+#: builtin.c:542
#, c-format
msgid "log: received negative argument %g"
msgstr "log: otrzymano ujemny argument %g"
-#: builtin.c:694 builtin.c:699
+#: builtin.c:740 builtin.c:745
msgid "fatal: must use `count$' on all formats or none"
msgstr "fatal: należy użyć `count$' we wszystkich formatach lub nic"
-#: builtin.c:762
+#: builtin.c:815
#, c-format
msgid "field width is ignored for `%%' specifier"
msgstr "szerokość pola jest ignorowana dla specyfikatora `%%'"
-#: builtin.c:764
+#: builtin.c:817
#, c-format
msgid "precision is ignored for `%%' specifier"
msgstr "precyzja jest ignorowana dla specyfikatora `%%'"
-#: builtin.c:766
+#: builtin.c:819
#, c-format
msgid "field width and precision are ignored for `%%' specifier"
msgstr "szerokość pola i precyzja są ignorowane dla specyfikatora `%%'"
-#: builtin.c:817
+#: builtin.c:870
msgid "fatal: `$' is not permitted in awk formats"
msgstr "fatal: `$' jest niedozwolony w formatach awk"
-#: builtin.c:826
+#: builtin.c:879
msgid "fatal: arg count with `$' must be > 0"
msgstr "fatal: argument count z `$' musi być > 0"
-#: builtin.c:830
+#: builtin.c:883
#, c-format
msgid "fatal: arg count %ld greater than total number of supplied arguments"
msgstr ""
"fatal: argument count %ld większy niż całkowita suma argumentów dostarczonych"
-#: builtin.c:834
+#: builtin.c:887
msgid "fatal: `$' not permitted after period in format"
msgstr "fatal: `$' jest niedozwolony po kropce w formacie"
-#: builtin.c:850
+#: builtin.c:903
msgid "fatal: no `$' supplied for positional field width or precision"
msgstr "fatal: brak `$' dla pozycyjnej szerokości pola lub precyzji"
-#: builtin.c:921
+#: builtin.c:975
msgid "`l' is meaningless in awk formats; ignored"
msgstr "`l' jest bezsensowny w formatach awk; zignorowany"
-#: builtin.c:925
+#: builtin.c:979
msgid "fatal: `l' is not permitted in POSIX awk formats"
msgstr "fatal: `l' jest niedozwolony w formatach POSIX awk"
-#: builtin.c:938
+#: builtin.c:992
msgid "`L' is meaningless in awk formats; ignored"
msgstr "`L' jest bezsensowny w formatach awk; zignorowany"
-#: builtin.c:942
+#: builtin.c:996
msgid "fatal: `L' is not permitted in POSIX awk formats"
msgstr "fatal: `L' jest niedozwolony w formatach POSIX awk"
-#: builtin.c:955
+#: builtin.c:1009
msgid "`h' is meaningless in awk formats; ignored"
msgstr "`h' jest bezsensowny w formatach awk; zignorowany"
-#: builtin.c:959
+#: builtin.c:1013
msgid "fatal: `h' is not permitted in POSIX awk formats"
msgstr "fatal: `h' jest niedozwolony w formatach POSIX awk"
-#: builtin.c:1272
+#: builtin.c:1408
#, c-format
msgid "[s]printf: value %g is out of range for `%%%c' format"
msgstr "[s]printf: wartość %g jest poza zasięgiem dla formatu `%%%c'"
-#: builtin.c:1332
+#: builtin.c:1506
#, c-format
msgid "ignoring unknown format specifier character `%c': no argument converted"
msgstr ""
"pominięcie nieznanego formatu specyfikatora znaku `%c': nie skonwertowano "
"argumentu"
-#: builtin.c:1337
+#: builtin.c:1511
msgid "fatal: not enough arguments to satisfy format string"
msgstr ""
"fatal: brak wystarczającej liczby argumentów, aby zaspokoić łańcuch "
"formatujÄ…cy"
-#: builtin.c:1339
+#: builtin.c:1513
msgid "^ ran out for this one"
msgstr "zabrakło ^"
-#: builtin.c:1346
+#: builtin.c:1520
msgid "[s]printf: format specifier does not have control letter"
msgstr "[s]printf: specyfikator formatu nie posiada kontrolnej litery"
-#: builtin.c:1349
+#: builtin.c:1523
msgid "too many arguments supplied for format string"
msgstr "zbyt dużo podanych argumentów w łańcuchu formatującym"
-#: builtin.c:1423 builtin.c:1434
+#: builtin.c:1598 builtin.c:1609
msgid "printf: no arguments"
msgstr "printf: brak argumentów"
-#: builtin.c:1475
+#: builtin.c:1650
msgid "sqrt: received non-numeric argument"
msgstr "sqrt: otrzymano argument, który nie jest liczbą"
-#: builtin.c:1479
+#: builtin.c:1654
#, c-format
msgid "sqrt: called with negative argument %g"
msgstr "sqrt: wywołana z ujemnym argumentem %g"
-#: builtin.c:1503
+#: builtin.c:1685
#, c-format
msgid "substr: length %g is not >= 1"
msgstr "substr: długość %g nie jest >= 1"
-#: builtin.c:1505
+#: builtin.c:1687
#, c-format
msgid "substr: length %g is not >= 0"
msgstr "substr: długość %g nie jest >= 0"
-#: builtin.c:1512
+#: builtin.c:1694
#, c-format
msgid "substr: non-integer length %g will be truncated"
msgstr "substr: długość %g, która nie jest liczbą całkowitą, zostanie obcięta"
-#: builtin.c:1517
+#: builtin.c:1699
#, c-format
msgid "substr: length %g too big for string indexing, truncating to %g"
msgstr "substr: długość %g zbyt duża dla indeksu łańcucha, obcinanie do %g"
-#: builtin.c:1529
+#: builtin.c:1711
#, c-format
msgid "substr: start index %g is invalid, using 1"
msgstr "substr: początkowy indeks %g jest nieprawidłowy, nastąpi użycie 1"
-#: builtin.c:1534
+#: builtin.c:1716
#, c-format
msgid "substr: non-integer start index %g will be truncated"
msgstr ""
"substr: początkowy indeks %g, który nie jest liczbą całkowitą, zostanie "
"obcięty"
-#: builtin.c:1559
+#: builtin.c:1741
msgid "substr: source string is zero length"
msgstr "substr: łańcuch źródłowy ma zerową długość"
-#: builtin.c:1575
+#: builtin.c:1757
#, c-format
msgid "substr: start index %g is past end of string"
msgstr "substr: początkowy indeks %g leży poza końcem łańcucha"
-#: builtin.c:1583
+#: builtin.c:1765
#, c-format
msgid ""
"substr: length %g at start index %g exceeds length of first argument (%lu)"
@@ -771,230 +728,225 @@ msgstr ""
"substr: długość %g zaczynając od %g przekracza długość pierwszego argumentu "
"(%lu)"
-#: builtin.c:1657
+#: builtin.c:1839
msgid "strftime: format value in PROCINFO[\"strftime\"] has numeric type"
msgstr ""
"strftime: wartość formatu w PROCINFO[\"strftime\"] posiada typ numeryczny"
-#: builtin.c:1680
+#: builtin.c:1862
msgid "strftime: received non-numeric second argument"
msgstr "strftime: otrzymano drugi argument, który nie jest liczbą"
-#: builtin.c:1683
+#: builtin.c:1866
msgid "strftime: second argument less than 0 or too big for time_t"
msgstr "strftime: drugi argument mniejszy od 0 lub zbyt duży dla time_t"
-#: builtin.c:1690
+#: builtin.c:1873
msgid "strftime: received non-string first argument"
msgstr "strftime: otrzymano pierwszy argument, który nie jest łańcuchem"
-#: builtin.c:1696
+#: builtin.c:1880
msgid "strftime: received empty format string"
msgstr "strftime: otrzymano pusty łańcuch formatujący"
-#: builtin.c:1762
+#: builtin.c:1946
msgid "mktime: received non-string argument"
msgstr "mktime: otrzymano argument, który nie jest łańcuchem"
-#: builtin.c:1779
+#: builtin.c:1963
msgid "mktime: at least one of the values is out of the default range"
msgstr "mktime: przynajmniej jedna z wartości jest poza domyślnym zakresem"
-#: builtin.c:1814
+#: builtin.c:1998
msgid "'system' function not allowed in sandbox mode"
msgstr "funkcja 'system' nie jest dozwolona w trybie piaskownicy"
-#: builtin.c:1819
+#: builtin.c:2003
msgid "system: received non-string argument"
msgstr "system: otrzymano argument, który nie jest łańcuchem"
-#: builtin.c:1874 eval.c:1159 eval.c:1790 eval.c:1803
-#, c-format
-msgid "reference to uninitialized variable `%s'"
-msgstr "odwołanie do niezainicjowanej zmiennej `%s'"
-
-#: builtin.c:1941
+#: builtin.c:2121
#, c-format
msgid "reference to uninitialized field `$%d'"
msgstr "odwołanie do niezainicjowanego pola `$%d'"
-#: builtin.c:2028
+#: builtin.c:2208
msgid "tolower: received non-string argument"
msgstr "tolower: otrzymano argument, który nie jest łańcuchem"
-#: builtin.c:2062
+#: builtin.c:2242
msgid "toupper: received non-string argument"
msgstr "toupper: otrzymano argument, który nie jest łańcuchem"
-#: builtin.c:2098
+#: builtin.c:2278
msgid "atan2: received non-numeric first argument"
msgstr "atan2: otrzymano pierwszy argument, który nie jest liczbą"
-#: builtin.c:2100
+#: builtin.c:2280
msgid "atan2: received non-numeric second argument"
msgstr "atan2: otrzymano drugi argument, który nie jest liczbą"
-#: builtin.c:2119
+#: builtin.c:2299
msgid "sin: received non-numeric argument"
msgstr "sin: otrzymano argument, który nie jest liczbą"
-#: builtin.c:2135
+#: builtin.c:2315
msgid "cos: received non-numeric argument"
msgstr "cos: otrzymano argument, który nie jest liczbą"
-#: builtin.c:2188
+#: builtin.c:2368
msgid "srand: received non-numeric argument"
msgstr "srand: otrzymano argument, który nie jest liczbą"
-#: builtin.c:2219
+#: builtin.c:2399
msgid "match: third argument is not an array"
msgstr "match: otrzymano trzeci argument, który nie jest tablicą"
-#: builtin.c:2483
+#: builtin.c:2664
msgid "gensub: third argument of 0 treated as 1"
msgstr "gensub: trzeci argument 0 potraktowany jako 1"
-#: builtin.c:2776
+#: builtin.c:2957
msgid "lshift: received non-numeric first argument"
msgstr "lshift: otrzymano pierwszy argument, który nie jest liczbą"
-#: builtin.c:2778
+#: builtin.c:2959
msgid "lshift: received non-numeric second argument"
msgstr "lshift: otrzymano drugi argument, który nie jest liczbą"
-#: builtin.c:2784
+#: builtin.c:2965
#, c-format
msgid "lshift(%lf, %lf): negative values will give strange results"
msgstr "lshift(%lf, %lf): ujemne wartości spowodują dziwne wyniki"
-#: builtin.c:2786
+#: builtin.c:2967
#, c-format
msgid "lshift(%lf, %lf): fractional values will be truncated"
msgstr "lshift(%lf, %lf): ułamkowe wartości zostaną obcięte"
-#: builtin.c:2788
+#: builtin.c:2969
#, c-format
msgid "lshift(%lf, %lf): too large shift value will give strange results"
msgstr ""
"lshift(%lf, %lf): zbyt duża wartość przesunięcia spowoduje dziwne wyniki"
-#: builtin.c:2813
+#: builtin.c:2994
msgid "rshift: received non-numeric first argument"
msgstr "rshift: otrzymano pierwszy argument, który nie jest liczbą"
-#: builtin.c:2815
+#: builtin.c:2996
msgid "rshift: received non-numeric second argument"
msgstr "rshift: otrzymano drugi argument, który nie jest liczbą"
-#: builtin.c:2821
+#: builtin.c:3002
#, c-format
msgid "rshift(%lf, %lf): negative values will give strange results"
msgstr "rshift(%lf, %lf): ujemne wartości spowodują dziwne wyniki"
-#: builtin.c:2823
+#: builtin.c:3004
#, c-format
msgid "rshift(%lf, %lf): fractional values will be truncated"
msgstr "rshift(%lf, %lf): ułamkowe wartości zostaną obcięte"
-#: builtin.c:2825
+#: builtin.c:3006
#, c-format
msgid "rshift(%lf, %lf): too large shift value will give strange results"
msgstr ""
"rshift(%lf, %lf): zbyt duża wartość przesunięcia spowoduje dziwne wyniki"
-#: builtin.c:2850
+#: builtin.c:3031
msgid "and: received non-numeric first argument"
msgstr "and: otrzymano pierwszy argument, który nie jest liczbą"
-#: builtin.c:2852
+#: builtin.c:3033
msgid "and: received non-numeric second argument"
msgstr "and: otrzymano drugi argument, który nie jest liczbą"
-#: builtin.c:2858
+#: builtin.c:3039
#, c-format
msgid "and(%lf, %lf): negative values will give strange results"
msgstr "and(%lf, %lf): ujemne wartości spowodują dziwne wyniki"
-#: builtin.c:2860
+#: builtin.c:3041
#, c-format
msgid "and(%lf, %lf): fractional values will be truncated"
msgstr "and(%lf, %lf): ułamkowe wartości zostaną obcięte"
-#: builtin.c:2885
+#: builtin.c:3066
msgid "or: received non-numeric first argument"
msgstr "or: otrzymano pierwszy argument, który nie jest liczbą"
-#: builtin.c:2887
+#: builtin.c:3068
msgid "or: received non-numeric second argument"
msgstr "or: otrzymano drugi argument, który nie jest liczbą"
-#: builtin.c:2893
+#: builtin.c:3074
#, c-format
msgid "or(%lf, %lf): negative values will give strange results"
msgstr "or(%lf, %lf): ujemne wartości spowodują dziwne wyniki"
-#: builtin.c:2895
+#: builtin.c:3076
#, c-format
msgid "or(%lf, %lf): fractional values will be truncated"
msgstr "or(%lf, %lf): ułamkowe wartości zostaną obcięte"
-#: builtin.c:2923
+#: builtin.c:3102
msgid "xor: received non-numeric first argument"
msgstr "xor: otrzymano pierwszy argument, który nie jest liczbą"
-#: builtin.c:2925
+#: builtin.c:3104
msgid "xor: received non-numeric second argument"
msgstr "xor: otrzymano drugi argument, który nie jest liczbą"
-#: builtin.c:2931
+#: builtin.c:3110
#, c-format
msgid "xor(%lf, %lf): negative values will give strange results"
msgstr "xor(%lf, %lf): ujemne wartości spowodują dziwne wyniki"
-#: builtin.c:2933
+#: builtin.c:3112
#, c-format
msgid "xor(%lf, %lf): fractional values will be truncated"
msgstr "xor(%lf, %lf): ułamkowe wartości zostaną obcięte"
-#: builtin.c:2957 builtin.c:2963
+#: builtin.c:3136
msgid "compl: received non-numeric argument"
msgstr "compl: otrzymano argument, który nie jest liczbą"
-#: builtin.c:2965
+#: builtin.c:3142
#, c-format
msgid "compl(%lf): negative value will give strange results"
msgstr "compl(%lf): ujemne wartości spowodują dziwne wyniki"
-#: builtin.c:2967
+#: builtin.c:3144
#, c-format
msgid "compl(%lf): fractional value will be truncated"
msgstr "compl(%lf): ułamkowe wartości zostaną obcięte"
-#: builtin.c:3136
+#: builtin.c:3313
#, c-format
msgid "dcgettext: `%s' is not a valid locale category"
msgstr "dcgettext: `%s' nie jest prawidłową kategorią lokalizacji"
-#: eval.c:412
+#: eval.c:395
#, c-format
msgid "unknown nodetype %d"
msgstr "nieznany typ węzła %d"
-#: eval.c:423 eval.c:437
+#: eval.c:406 eval.c:420
#, c-format
msgid "unknown opcode %d"
msgstr "nieznany opcode %d"
-#: eval.c:434
+#: eval.c:417
#, c-format
msgid "opcode %s not an operator or keyword"
msgstr "opcode %s nie jest operatorem ani słowem kluczowym"
-#: eval.c:488
+#: eval.c:472
msgid "buffer overflow in genflags2str"
msgstr "przepełnienie bufora w genflags2str"
-#: eval.c:698
+#: eval.c:675
#, c-format
msgid ""
"\n"
@@ -1005,305 +957,248 @@ msgstr ""
"\t# Stos Wywoławczy Funkcji:\n"
"\n"
-#: eval.c:725
+#: eval.c:704
msgid "`IGNORECASE' is a gawk extension"
msgstr "`IGNORECASE' jest rozszerzeniem gawk"
-#: eval.c:754
+#: eval.c:736
msgid "`BINMODE' is a gawk extension"
msgstr "`BINMODE' jest rozszerzeniem gawk"
-#: eval.c:812
+#: eval.c:793
#, c-format
msgid "BINMODE value `%s' is invalid, treated as 3"
msgstr "wartość BINMODE `%s' jest nieprawidłowa, przyjęto ją jako 3"
-#: eval.c:902
+#: eval.c:885
#, c-format
msgid "bad `%sFMT' specification `%s'"
msgstr "zła specyfikacja `%sFMT' `%s'"
-#: eval.c:980
+#: eval.c:969
msgid "turning off `--lint' due to assignment to `LINT'"
msgstr "wyłączenie `--lint' z powodu przypisania do `LINT'"
-#: eval.c:1127 eval.c:1777
-#, c-format
-msgid "can't use function name `%s' as variable or array"
-msgstr "nie można użyć nazwy funkcji `%s' jako zmiennej lub tablicy"
-
-#: eval.c:1158 eval.c:1789 eval.c:1802
+#: eval.c:1132
#, c-format
msgid "reference to uninitialized argument `%s'"
msgstr "odwołanie do niezainicjowanego argumentu `%s'"
-#: eval.c:1177
+#: eval.c:1133
+#, c-format
+msgid "reference to uninitialized variable `%s'"
+msgstr "odwołanie do niezainicjowanej zmiennej `%s'"
+
+#: eval.c:1151
msgid "attempt to field reference from non-numeric value"
msgstr "próba odwołania do pola poprzez nienumeryczną wartość"
-#: eval.c:1179
+#: eval.c:1153
msgid "attempt to field reference from null string"
msgstr "próba odwołania z zerowego łańcucha"
-#: eval.c:1185
+#: eval.c:1161
#, c-format
msgid "attempt to access field %ld"
msgstr "próba dostępu do pola %ld"
-#: eval.c:1194
+#: eval.c:1170
#, c-format
msgid "reference to uninitialized field `$%ld'"
msgstr "odwołanie do niezainicjowanego pola `$%ld'"
-#: eval.c:1256
+#: eval.c:1257
#, c-format
msgid "function `%s' called with more arguments than declared"
msgstr ""
"funkcja `%s' została wywołana z większą ilością argumentów niż zostało to "
"zadeklarowane"
-#: eval.c:1437
+#: eval.c:1452
#, c-format
msgid "unwind_stack: unexpected type `%s'"
msgstr "unwind_stack: niespodziewany typ `%s'"
-#: eval.c:1532
+#: eval.c:1546
msgid "division by zero attempted in `/='"
msgstr "próba dzielenia przez zero w `/='"
-#: eval.c:1539
+#: eval.c:1553
#, c-format
msgid "division by zero attempted in `%%='"
msgstr "próba dzielenia przez zero w `%%='"
-#: eval.c:1876 eval.c:2122
-#, c-format
-msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
-msgstr "próba użycia tablicy `%s[\"%.*s\"]' w kontekście skalaru"
-
-#: eval.c:1907
-msgid "assignment used in conditional context"
-msgstr "przypisanie użyte w kontekście warunkowym"
-
-#: eval.c:1911
-msgid "statement has no effect"
-msgstr "instrukcja nie ma żadnego efektu"
-
-#: eval.c:2343
-#, c-format
-msgid "for loop: array `%s' changed size from %ld to %ld during loop execution"
-msgstr ""
-"pętla for: tablica `%s' zmieniła rozmiar z %ld do %ld podczas wykonywania "
-"pętli"
-
-#: eval.c:2458
-#, c-format
-msgid "function called indirectly through `%s' does not exist"
-msgstr "pośrednio wywołana funkcja poprzez `%s' nie istnieje"
-
-#: eval.c:2470
-#, c-format
-msgid "function `%s' not defined"
-msgstr "funkcja `%s' nie została zdefiniowana"
-
-#: eval.c:2511
-#, c-format
-msgid "non-redirected `getline' invalid inside `%s' rule"
-msgstr ""
-"komenda `getline' bez przekierowania jest nieprawidłowa wewnątrz reguły `%s'"
-
-#: eval.c:2600
-#, c-format
-msgid "error reading input file `%s': %s"
-msgstr "błąd podczas czytania z pliku `%s': %s"
-
-#: eval.c:2614
-#, c-format
-msgid "`nextfile' cannot be called from a `%s' rule"
-msgstr "instrukcja `nextfile' nie może być wywołana z wnętrza reguły `%s'"
-
-#: eval.c:2661
-msgid "`exit' cannot be called in the current context"
-msgstr "instrukcja `exit' nie może być wywołana w tym kontekście"
-
-#: eval.c:2700
-#, c-format
-msgid "`next' cannot be called from a `%s' rule"
-msgstr "instrukcja `next' nie może być wywołana z wnętrza reguły `%s'"
-
-#: eval.c:2766
-#, c-format
-msgid "Sorry, don't know how to interpret `%s'"
-msgstr "Niestety nie wiem jak zinterpretować `%s'"
-
-#: ext.c:54
+#: ext.c:70
msgid "extensions are not allowed in sandbox mode"
msgstr "rozszerzenia nie sÄ… dozwolone w trybie piaskownicy"
-#: ext.c:60 ext.c:65
+#: ext.c:73
msgid "`extension' is a gawk extension"
msgstr "`extension' jest rozszerzeniem gawk"
-#: ext.c:75
-#, c-format
-msgid "fatal: extension: cannot open `%s' (%s)\n"
+#: ext.c:80
+#, fuzzy, c-format
+msgid "extension: cannot open library `%s' (%s)\n"
msgstr "fatal: rozszerzenie: nie można otworzyć `%s' (%s)\n"
-#: ext.c:84
-#, c-format
+#: ext.c:86
+#, fuzzy, c-format
msgid ""
-"fatal: extension: library `%s': does not define "
-"`plugin_is_GPL_compatible' (%s)\n"
+"extension: library `%s': does not define `plugin_is_GPL_compatible' (%s)\n"
msgstr ""
"fatal: rozszerzenie: biblioteka `%s': nie definiuje "
"`plugin_is_GPL_compatible' (%s)\n"
-#: ext.c:93
-#, c-format
-msgid "fatal: extension: library `%s': cannot call function `%s' (%s)\n"
+#: ext.c:90
+#, fuzzy, c-format
+msgid "extension: library `%s': cannot call function `%s' (%s)\n"
msgstr ""
"fatal: rozszerzenie: biblioteka `%s': nie można wywołać funkcji `%s' (%s)\n"
-#: ext.c:127
+#: ext.c:118
msgid "extension: missing function name"
msgstr "rozszerzenie: brakujÄ…ca nazwa funkcji"
-#: ext.c:132
+#: ext.c:123
#, c-format
msgid "extension: illegal character `%c' in function name `%s'"
msgstr "rozszerzenie: nieprawidłowy znak `%c' w nazwie funkcji `%s'"
-#: ext.c:141
+#: ext.c:131
#, c-format
msgid "extension: can't redefine function `%s'"
msgstr "rozszerzenie: nie można zredefiniować funkcji `%s'"
-#: ext.c:145
+#: ext.c:135
#, c-format
msgid "extension: function `%s' already defined"
msgstr "rozserzenie: funkcja `%s' została już zdefiniowana"
-#: ext.c:150
+#: ext.c:139
#, c-format
msgid "extension: function name `%s' previously defined"
msgstr "rozserzenie: nazwa funkcji `%s' została zdefiniowana wcześniej"
-#: ext.c:152
+#: ext.c:141
#, c-format
msgid "extension: can't use gawk built-in `%s' as function name"
msgstr "rozszerzenie: nie można użyć wbudowanej w gawk `%s' jako nazwy funkcji"
-#: ext.c:156
+#: ext.c:144
#, c-format
msgid "make_builtin: negative argument count for function `%s'"
msgstr "make_builtin: ujemny licznik argumentów dla funkcji `%s'"
-#: ext.c:259
+#: ext.c:206
#, c-format
msgid "function `%s' defined to take no more than %d argument(s)"
msgstr "funkcja `%s' zdefiniowana aby pobrać nie więcej niż %d argument(ów)"
-#: ext.c:262
+#: ext.c:209
#, c-format
msgid "function `%s': missing argument #%d"
msgstr "funkcja `%s': brakuje #%d argumentu"
-#: ext.c:279
+#: ext.c:226
#, c-format
msgid "function `%s': argument #%d: attempt to use scalar as an array"
msgstr "funkcja `%s': argument #%d: próba użycia skalaru jako tablicy"
-#: ext.c:283
+#: ext.c:230
#, c-format
msgid "function `%s': argument #%d: attempt to use array as a scalar"
msgstr "funkcja `%s': argument #%d: próba użycia tablicy jako skalaru"
-#: ext.c:296
+#: ext.c:244
msgid "Operation Not Supported"
msgstr "Operacja nie jest wspierana"
-#: field.c:328
+#: ext.c:256
+msgid "dynamic loading of library not supported"
+msgstr ""
+
+#: field.c:339
msgid "NF set to negative value"
msgstr "NF ustawiony na wartość ujemną"
-#: field.c:951 field.c:958 field.c:962
+#: field.c:962 field.c:969 field.c:973
msgid "split: fourth argument is a gawk extension"
msgstr "split: czwarty argument jest rozszerzeniem gawk"
-#: field.c:955
+#: field.c:966
msgid "split: fourth argument is not an array"
msgstr "split: czwarty argument nie jest tablicÄ…"
-#: field.c:969
+#: field.c:980
msgid "split: second argument is not an array"
msgstr "split: drugi argument nie jest tablicÄ…"
-#: field.c:973
+#: field.c:984
msgid "split: cannot use the same array for second and fourth args"
msgstr ""
"split: nie można użyć tej samej tablicy dla drugiego i czwartego argumentu"
-#: field.c:978
+#: field.c:989
msgid "split: cannot use a subarray of second arg for fourth arg"
msgstr ""
"split: nie można użyć podtablicy drugiego argumentu dla czwartego argumentu"
-#: field.c:981
+#: field.c:992
msgid "split: cannot use a subarray of fourth arg for second arg"
msgstr ""
"split: nie można użyć podtablicy czwartego argumentu dla drugiego argumentu"
-#: field.c:1010
+#: field.c:1021
msgid "split: null string for third arg is a gawk extension"
msgstr "split: zerowy łańcuch dla trzeciego argumentu jest rozszerzeniem gawk"
-#: field.c:1050
+#: field.c:1061
msgid "patsplit: fourth argument is not an array"
msgstr "patsplit: czwarty argument nie jest tablicÄ…"
-#: field.c:1055
+#: field.c:1066
msgid "patsplit: second argument is not an array"
msgstr "patsplit: drugi argument nie jest tablicÄ…"
-#: field.c:1061
+#: field.c:1072
msgid "patsplit: third argument must be non-null"
msgstr "patsplit: trzeci argument nie może być pusty"
-#: field.c:1065
+#: field.c:1076
msgid "patsplit: cannot use the same array for second and fourth args"
msgstr ""
"patsplit: nie można użyć tej samej tablicy dla drugiego i czwartego argumentu"
-#: field.c:1070
+#: field.c:1081
msgid "patsplit: cannot use a subarray of second arg for fourth arg"
msgstr ""
"patsplit: nie można użyć podtablicy drugiego argumentu dla czwartego "
"argumentu"
-#: field.c:1073
+#: field.c:1084
msgid "patsplit: cannot use a subarray of fourth arg for second arg"
msgstr ""
"patsplit: nie można użyć podtablicy czwartego argumentu dla drugiego "
"argumentu"
-#: field.c:1110
+#: field.c:1122
msgid "`FIELDWIDTHS' is a gawk extension"
msgstr "`FIELDWIDTHS' jest rozszerzeniem gawk"
-#: field.c:1173
+#: field.c:1186
#, c-format
msgid "invalid FIELDWIDTHS value, near `%s'"
msgstr "nieprawidłowa wartość FIELDWIDTHS, w pobliżu `%s'"
-#: field.c:1246
+#: field.c:1259
msgid "null string for `FS' is a gawk extension"
msgstr "zerowy łańcuch dla `FS' jest rozszerzeniem gawk"
-#: field.c:1250
+#: field.c:1263
msgid "old awk does not support regexps as value of `FS'"
msgstr "stary awk nie wspiera wyrażeń regularnych jako wartości `FS'"
-#: field.c:1369
+#: field.c:1382
msgid "`FPAT' is a gawk extension"
msgstr "`FPAT' jest rozszerzeniem gawk"
@@ -1362,475 +1257,490 @@ msgstr "%s: opcja '-W %s' nie może mieć argumentów\n"
msgid "%s: option '-W %s' requires an argument\n"
msgstr "%s: opcja '-W %s' wymaga argumentu\n"
-#: io.c:280
+#: io.c:326
#, c-format
msgid "command line argument `%s' is a directory: skipped"
msgstr "argument linii poleceń `%s' jest katalogiem: pominięto"
-#: io.c:283 io.c:385
+#: io.c:329 io.c:438
#, c-format
msgid "cannot open file `%s' for reading (%s)"
msgstr "nie można otworzyć pliku `%s' do czytania (%s)"
-#: io.c:501
+#: io.c:568
#, c-format
msgid "close of fd %d (`%s') failed (%s)"
msgstr "zamknięcie fd %d (`%s') nie powiodło się (%s)"
-#: io.c:578
+#: io.c:645
msgid "redirection not allowed in sandbox mode"
msgstr "przekierowanie nie jest dozwolone w trybie piaskownicy"
-#: io.c:612
+#: io.c:679
#, c-format
msgid "expression in `%s' redirection only has numeric value"
msgstr "wyrażenie w przekierowaniu `%s' ma tylko wartość numeryczną"
-#: io.c:618
+#: io.c:685
#, c-format
msgid "expression for `%s' redirection has null string value"
msgstr "wyrażenie dla przekierowania `%s' ma zerową wartość łańcucha"
-#: io.c:623
+#: io.c:690
#, c-format
msgid "filename `%s' for `%s' redirection may be result of logical expression"
msgstr ""
"nazwa pliku `%s' dla przekierowania `%s' może być rezultatem logicznego "
"wyrażenia"
-#: io.c:666
+#: io.c:733
#, c-format
msgid "unnecessary mixing of `>' and `>>' for file `%.*s'"
msgstr "niepotrzebne mieszanie `>' i `>>' dla pliku `%.*s'"
-#: io.c:719
+#: io.c:786
#, c-format
msgid "can't open pipe `%s' for output (%s)"
msgstr "nie można otworzyć potoku `%s' jako wyjścia (%s)"
-#: io.c:729
+#: io.c:796
#, c-format
msgid "can't open pipe `%s' for input (%s)"
msgstr "nie można otworzyć potoku `%s' jako wejścia (%s)"
-#: io.c:752
+#: io.c:819
#, c-format
msgid "can't open two way pipe `%s' for input/output (%s)"
msgstr ""
"nie można otworzyć dwukierunkowego potoku `%s' jako wejścia/wyjścia (%s)"
-#: io.c:834
+#: io.c:900
#, c-format
msgid "can't redirect from `%s' (%s)"
msgstr "nie można przekierować z `%s' (%s)"
-#: io.c:837
+#: io.c:903
#, c-format
msgid "can't redirect to `%s' (%s)"
msgstr "nie można przekierować do `%s' (%s)"
-#: io.c:888
+#: io.c:954
msgid ""
"reached system limit for open files: starting to multiplex file descriptors"
msgstr ""
"osiągnięto systemowy limit otwartych plików: rozpoczęcie multipleksowania "
"deskryptorów plików"
-#: io.c:904
+#: io.c:970
#, c-format
msgid "close of `%s' failed (%s)."
msgstr "zamknięcie `%s' nie powiodło się (%s)."
-#: io.c:912
+#: io.c:978
msgid "too many pipes or input files open"
msgstr "zbyt dużo otwartych potoków lub plików wejściowych"
-#: io.c:934
+#: io.c:1000
msgid "close: second argument must be `to' or `from'"
msgstr "close: drugim argumentem musi być `to' lub `from'"
-#: io.c:951
+#: io.c:1017
#, c-format
msgid "close: `%.*s' is not an open file, pipe or co-process"
msgstr ""
"close: `%.*s' nie jest ani otwartym plikiem, ani potokiem, ani procesem"
-#: io.c:956
+#: io.c:1022
msgid "close of redirection that was never opened"
msgstr "zamknięcie przekierowania, które nigdy nie zostało otwarte"
-#: io.c:1053
+#: io.c:1120
#, c-format
msgid "close: redirection `%s' not opened with `|&', second argument ignored"
msgstr ""
"close: przekierowanie `%s' nie zostało otwarte z `|&', drugi argument "
"zignorowany"
-#: io.c:1069
+#: io.c:1137
#, c-format
msgid "failure status (%d) on pipe close of `%s' (%s)"
msgstr "status awarii (%d) podczas zamykania potoku `%s' (%s)"
-#: io.c:1072
+#: io.c:1140
#, c-format
msgid "failure status (%d) on file close of `%s' (%s)"
msgstr "status awarii (%d) podczas zamykania pliku `%s' (%s)"
-#: io.c:1092
+#: io.c:1160
#, c-format
msgid "no explicit close of socket `%s' provided"
msgstr "brak jawnego zamknięcia gniazdka `%s'"
-#: io.c:1095
+#: io.c:1163
#, c-format
msgid "no explicit close of co-process `%s' provided"
msgstr "brak jawnego zamknięcia procesu pomocniczego `%s'"
-#: io.c:1098
+#: io.c:1166
#, c-format
msgid "no explicit close of pipe `%s' provided"
msgstr "brak jawnego zamknięcia potoku `%s'"
-#: io.c:1101
+#: io.c:1169
#, c-format
msgid "no explicit close of file `%s' provided"
msgstr "brak jawnego zamknięcia pliku `%s'"
-#: io.c:1129 io.c:1184 main.c:794 main.c:831
+#: io.c:1197 io.c:1252 main.c:825 main.c:862
#, c-format
msgid "error writing standard output (%s)"
msgstr "błąd podczas zapisu na standardowe wyjście (%s)"
-#: io.c:1133 io.c:1189
+#: io.c:1201 io.c:1257
#, c-format
msgid "error writing standard error (%s)"
msgstr "błąd podczas zapisu na standardowe wyjście diagnostyczne (%s)"
-#: io.c:1141
+#: io.c:1209
#, c-format
msgid "pipe flush of `%s' failed (%s)."
msgstr "opróżnienie potoku `%s' nie powiodło się (%s)."
-#: io.c:1144
+#: io.c:1212
#, c-format
msgid "co-process flush of pipe to `%s' failed (%s)."
msgstr ""
"opróżnienie potoku do `%s' przez proces pomocniczy nie powiodło się (%s)."
-#: io.c:1147
+#: io.c:1215
#, c-format
msgid "file flush of `%s' failed (%s)."
msgstr "opróżnienie pliku `%s' nie powiodło się (%s)."
-#: io.c:1262
+#: io.c:1329
#, c-format
msgid "local port %s invalid in `/inet'"
msgstr "nieprawidłowy lokalny port %s w `/inet'"
-#: io.c:1279
+#: io.c:1347
#, c-format
msgid "remote host and port information (%s, %s) invalid"
msgstr "informacje o zdalnym hoście i porcie są nieprawidłowe (%s, %s)"
-#: io.c:1431
+#: io.c:1499
#, c-format
msgid "no (known) protocol supplied in special filename `%s'"
msgstr "nie dostarczono (znanego) protokołu w specjalnym pliku `%s'"
-#: io.c:1445
+#: io.c:1513
#, c-format
msgid "special file name `%s' is incomplete"
msgstr "specjalna nazwa pliku `%s' jest niekompletna"
-#: io.c:1462
+#: io.c:1530
msgid "must supply a remote hostname to `/inet'"
msgstr "należy dostarczyć nazwę zdalnego hosta do `/inet'"
-#: io.c:1480
+#: io.c:1548
msgid "must supply a remote port to `/inet'"
msgstr "należy dostarczyć numer zdalnego portu do `/inet'"
-#: io.c:1526
+#: io.c:1594
msgid "TCP/IP communications are not supported"
msgstr "Komunikacja TCP/IP nie jest wspierana"
-#: io.c:1693
+#: io.c:1764
#, c-format
msgid "could not open `%s', mode `%s'"
msgstr "nie można otworzyć `%s', tryb `%s'"
-#: io.c:1747
+#: io.c:1814
#, c-format
msgid "close of master pty failed (%s)"
msgstr "zamknięcie nadrzędnego pty nie powiodło się (%s)"
-#: io.c:1749 io.c:1917 io.c:2074
+#: io.c:1816 io.c:1984 io.c:2145
#, c-format
msgid "close of stdout in child failed (%s)"
msgstr ""
"zamknięcie standardowego wyjścia w procesie potomnym nie powiodło się (%s)"
-#: io.c:1752
+#: io.c:1819
#, c-format
msgid "moving slave pty to stdout in child failed (dup: %s)"
msgstr ""
"przesunięcie podległego pty na standardowe wyjście w procesie potomnym nie "
"powiodło się (dup: %s)"
-#: io.c:1754 io.c:1922
+#: io.c:1821 io.c:1989
#, c-format
msgid "close of stdin in child failed (%s)"
msgstr ""
"zamknięcie standardowego wejścia w procesie potomnym nie powiodło się (%s)"
-#: io.c:1757
+#: io.c:1824
#, c-format
msgid "moving slave pty to stdin in child failed (dup: %s)"
msgstr ""
"przesunięcie podległego pty na standardowe wejście w procesie potomnym nie "
"powiodło się (dup: %s)"
-#: io.c:1759 io.c:1780
+#: io.c:1826 io.c:1847
#, c-format
msgid "close of slave pty failed (%s)"
msgstr "zamknięcie podległego pty nie powiodło się (%s)"
-#: io.c:1858 io.c:1920 io.c:2052 io.c:2077
+#: io.c:1925 io.c:1987 io.c:2122 io.c:2148
#, c-format
msgid "moving pipe to stdout in child failed (dup: %s)"
msgstr ""
"przesunięcie potoku na standardowe wyjście w procesie potomnym nie powiodło "
"siÄ™ (dup: %s)"
-#: io.c:1865 io.c:1925
+#: io.c:1932 io.c:1992
#, c-format
msgid "moving pipe to stdin in child failed (dup: %s)"
msgstr ""
"przesunięcie potoku na standardowe wejście w procesie potomnym nie powiodło "
"siÄ™ (dup: %s)"
-#: io.c:1885 io.c:2067
+#: io.c:1952 io.c:2138
msgid "restoring stdout in parent process failed\n"
msgstr ""
"odzyskanie standardowego wyjścia w procesie potomnym nie powiodło się\n"
-#: io.c:1893
+#: io.c:1960
msgid "restoring stdin in parent process failed\n"
msgstr ""
"odzyskanie standardowego wejścia w procesie potomnym nie powiodło się\n"
-#: io.c:1928 io.c:2079 io.c:2093
+#: io.c:1995 io.c:2150 io.c:2164
#, c-format
msgid "close of pipe failed (%s)"
msgstr "zamknięcie potoku nie powiodło się (%s)"
-#: io.c:1973
+#: io.c:2040
msgid "`|&' not supported"
msgstr "`|&' nie jest wspierany"
-#: io.c:2039
+#: io.c:2107
#, c-format
msgid "cannot open pipe `%s' (%s)"
msgstr "nie można otworzyć potoku `%s' (%s)"
-#: io.c:2087
+#: io.c:2158
#, c-format
msgid "cannot create child process for `%s' (fork: %s)"
msgstr "nie można utworzyć procesu potomnego dla `%s' (fork: %s)"
-#: io.c:2520
+#: io.c:2637
#, c-format
msgid "data file `%s' is empty"
msgstr "plik danych `%s' jest pusty"
-#: io.c:2561 io.c:2569
+#: io.c:2678 io.c:2686
msgid "could not allocate more input memory"
msgstr "nie można zarezerwować więcej pamięci wejściowej"
-#: io.c:3127
+#: io.c:3236
msgid "multicharacter value of `RS' is a gawk extension"
msgstr "wieloznakowa wartość `RS' jest rozszerzeniem gawk"
-#: io.c:3232
+#: io.c:3326
msgid "IPv6 communication is not supported"
msgstr "Komunikacja IPv6 nie jest wspierana"
-#: main.c:366
+#: main.c:355
msgid "`-m[fr]' option irrelevant in gawk"
msgstr "nieistotna opcja `-m[fr]' w gawk"
-#: main.c:368
+#: main.c:357
msgid "-m option usage: `-m[fr] nnn'"
msgstr "użycie opcji -m: `-m[fr] nnn'"
-#: main.c:391
+#: main.c:386
msgid "empty argument to `-e/--source' ignored"
msgstr "pusty argument dla opcji `-e/--source' został zignorowany"
-#: main.c:462
+#: main.c:472
#, c-format
msgid "%s: option `-W %s' unrecognized, ignored\n"
msgstr "%s: opcja `-W %s' nierozpoznana i zignorowana\n"
-#: main.c:515
+#: main.c:518
#, c-format
msgid "%s: option requires an argument -- %c\n"
msgstr "%s: opcja musi mieć argument -- %c\n"
-#: main.c:536
+#: main.c:539
msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'"
msgstr ""
"zmienna środowiskowa `POSIXLY_CORRECT' ustawiona: `--posix' został włączony"
-#: main.c:542
+#: main.c:545
msgid "`--posix' overrides `--traditional'"
msgstr "opcja `--posix' zostanie użyta nad `--traditional'"
-#: main.c:553
+#: main.c:556
msgid "`--posix'/`--traditional' overrides `--non-decimal-data'"
msgstr "`--posix'/`--traditional' użyte nad opcją `--non-decimal-data'"
-#: main.c:557
+#: main.c:560
#, c-format
msgid "running %s setuid root may be a security problem"
msgstr ""
"uruchamianie %s setuid root może być problemem pod względem bezpieczeństwa"
-#: main.c:562
+#: main.c:565
msgid "`--posix' overrides `--binary'"
msgstr "opcja `--posix' zostanie użyta nad `--binary'"
-#: main.c:613
+#: main.c:623
#, c-format
msgid "can't set binary mode on stdin (%s)"
msgstr "nie można ustawić trybu binarnego na standardowym wejściu (%s)"
-#: main.c:616
+#: main.c:626
#, c-format
msgid "can't set binary mode on stdout (%s)"
msgstr "nie można ustawić trybu binarnego na standardowym wyjściu (%s)"
-#: main.c:618
+#: main.c:628
#, c-format
msgid "can't set binary mode on stderr (%s)"
msgstr "nie można ustawić trybu binarnego na wyjściu diagnostycznym (%s)"
-#: main.c:657
+#: main.c:679
msgid "no program text at all!"
msgstr "brak tekstu programu!"
-#: main.c:734
+#: main.c:763
#, c-format
msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n"
msgstr ""
"Użycie: %s [styl opcji POSIX lub GNU] -f plik_z_programem [--] plik ...\n"
-#: main.c:736
+#: main.c:765
#, c-format
msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n"
msgstr "Użycie: %s [styl opcji POSIX lub GNU] [--] %cprogram%c plik ...\n"
-#: main.c:741
+#: main.c:770
msgid "POSIX options:\t\tGNU long options: (standard)\n"
msgstr "Opcje POSIX:\t\tDługie opcje GNU (standard):\n"
-#: main.c:742
+#: main.c:771
msgid "\t-f progfile\t\t--file=progfile\n"
msgstr "\t-f program\t\t--file=program\n"
-#: main.c:743
+#: main.c:772
msgid "\t-F fs\t\t\t--field-separator=fs\n"
msgstr "\t-F fs\t\t\t--field-separator=fs\n"
-#: main.c:744
+#: main.c:773
msgid "\t-v var=val\t\t--assign=var=val\n"
msgstr "\t-v zmienna=wartość\t--assign=zmienna=wartość\n"
-#: main.c:745
+#: main.c:774
msgid "Short options:\t\tGNU long options: (extensions)\n"
msgstr "Krótkie opcje:\t\tDługie opcje GNU: (rozszerzenia)\n"
-#: main.c:746
+#: main.c:775
msgid "\t-b\t\t\t--characters-as-bytes\n"
msgstr "\t-b\t\t\t--characters-as-bytes\n"
-#: main.c:747
+#: main.c:776
msgid "\t-c\t\t\t--traditional\n"
msgstr "\t-c\t\t\t--traditional\n"
-#: main.c:748
+#: main.c:777
msgid "\t-C\t\t\t--copyright\n"
msgstr "\t-C\t\t\t--copyright\n"
-#: main.c:749
+#: main.c:778
msgid "\t-d[file]\t\t--dump-variables[=file]\n"
msgstr "\t-d[plik]\t\t--dump-variables[=plik]\n"
-#: main.c:750
+#: main.c:779
+#, fuzzy
+msgid "\t-D[file]\t\t--debug[=file]\n"
+msgstr "\t-p[plik]\t\t--profile[=plik]\n"
+
+#: main.c:780
msgid "\t-e 'program-text'\t--source='program-text'\n"
msgstr "\t-e 'tekst-programu'\t--source='tekst-programu'\n"
-#: main.c:751
+#: main.c:781
msgid "\t-E file\t\t\t--exec=file\n"
msgstr "\t-E plik\t\t\t--exec=plik\n"
-#: main.c:752
+#: main.c:782
msgid "\t-g\t\t\t--gen-pot\n"
msgstr "\t-g\t\t\t--gen-pot\n"
-#: main.c:753
+#: main.c:783
msgid "\t-h\t\t\t--help\n"
msgstr "\t-h\t\t\t--help\n"
-#: main.c:754
+#: main.c:784
+msgid "\t-l library\t\t--load=library\n"
+msgstr ""
+
+#: main.c:785
msgid "\t-L [fatal]\t\t--lint[=fatal]\n"
msgstr "\t-L [fatal]\t\t--lint[=fatal]\n"
-#: main.c:755
+#: main.c:786
msgid "\t-n\t\t\t--non-decimal-data\n"
msgstr "\t-n\t\t\t--non-decimal-data\n"
-#: main.c:756
+#: main.c:787
+#, fuzzy
+msgid "\t-M\t\t\t--bignum\n"
+msgstr "\t-g\t\t\t--gen-pot\n"
+
+#: main.c:788
msgid "\t-N\t\t\t--use-lc-numeric\n"
msgstr "\t-N\t\t\t--use-lc-numeric\n"
-#: main.c:757
+#: main.c:789
+#, fuzzy
+msgid "\t-o[file]\t\t--pretty-print[=file]\n"
+msgstr "\t-p[plik]\t\t--profile[=plik]\n"
+
+#: main.c:790
msgid "\t-O\t\t\t--optimize\n"
msgstr "\t-O\t\t\t--optimize\n"
-#: main.c:758
+#: main.c:791
msgid "\t-p[file]\t\t--profile[=file]\n"
msgstr "\t-p[plik]\t\t--profile[=plik]\n"
-#: main.c:759
+#: main.c:792
msgid "\t-P\t\t\t--posix\n"
msgstr "\t-P\t\t\t--posix\n"
-#: main.c:760
+#: main.c:793
msgid "\t-r\t\t\t--re-interval\n"
msgstr "\t-r\t\t\t--re-interval\n"
-#: main.c:762
-msgid "\t-R file\t\t\t--command=file\n"
-msgstr "\t-R plik\t\t\t--command=plik\n"
-
-#: main.c:763
+#: main.c:794
msgid "\t-S\t\t\t--sandbox\n"
msgstr "\t-S\t\t\t--sandbox\n"
-#: main.c:764
+#: main.c:795
msgid "\t-t\t\t\t--lint-old\n"
msgstr "\t-t\t\t\t--lint-old\n"
-#: main.c:765
+#: main.c:796
msgid "\t-V\t\t\t--version\n"
msgstr "\t-V\t\t\t--version\n"
-#: main.c:767
+#: main.c:798
msgid "\t-W nostalgia\t\t--nostalgia\n"
msgstr "\t-W nostalgia\t\t--nostalgia\n"
-#: main.c:770
+#: main.c:801
msgid "\t-Y\t\t--parsedebug\n"
msgstr "\t-Y\t\t--parsedebug\n"
@@ -1839,7 +1749,7 @@ msgstr "\t-Y\t\t--parsedebug\n"
#. for this application. Please add _another line_ with the
#. address for translation bugs.
#. no-wrap
-#: main.c:779
+#: main.c:810
msgid ""
"\n"
"To report bugs, see node `Bugs' in `gawk.info', which is\n"
@@ -1852,7 +1762,7 @@ msgstr ""
"dokumentacji.\n"
"\n"
-#: main.c:783
+#: main.c:814
msgid ""
"gawk is a pattern scanning and processing language.\n"
"By default it reads standard input and writes standard output.\n"
@@ -1862,7 +1772,7 @@ msgstr ""
"Program domyślnie czyta standardowe wejście i zapisuje standardowe wyjście.\n"
"\n"
-#: main.c:787
+#: main.c:818
msgid ""
"Examples:\n"
"\tgawk '{ sum += $1 }; END { print sum }' file\n"
@@ -1872,7 +1782,7 @@ msgstr ""
"\tgawk '{ suma += $1 }; END { print suma }' plik\n"
"\tgawk -F: '{ print $1 }' /etc/passwd\n"
-#: main.c:807
+#: main.c:838
#, c-format
msgid ""
"Copyright (C) 1989, 1991-%d Free Software Foundation.\n"
@@ -1891,7 +1801,7 @@ msgstr ""
"tej Licencji lub którejś z późniejszych wersji.\n"
"\n"
-#: main.c:815
+#: main.c:846
msgid ""
"This program is distributed in the hope that it will be useful,\n"
"but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
@@ -1906,7 +1816,7 @@ msgstr ""
"PowszechnÄ… LicencjÄ™ PublicznÄ… GNU.\n"
"\n"
-#: main.c:821
+#: main.c:852
msgid ""
"You should have received a copy of the GNU General Public License\n"
"along with this program. If not, see http://www.gnu.org/licenses/.\n"
@@ -1915,16 +1825,16 @@ msgstr ""
"Powszechnej Licencji Publicznej GNU (GNU General Public License);\n"
"jeśli zaś nie - odwiedź stronę http://www.gnu.org/licenses/.\n"
-#: main.c:856
+#: main.c:887
msgid "-Ft does not set FS to tab in POSIX awk"
msgstr "-Ft nie ustawia FS na znak tabulatora w POSIX awk"
-#: main.c:1090
+#: main.c:1133
#, c-format
msgid "unknown value for field spec: %d\n"
msgstr "nieznana wartość dla specyfikacji pola: %d\n"
-#: main.c:1171
+#: main.c:1214
#, c-format
msgid ""
"%s: `%s' argument to `-v' not in `var=value' form\n"
@@ -1933,79 +1843,79 @@ msgstr ""
"%s: argument `%s' dla `-v' nie jest zgodny ze składnią `zmienna=wartość'\n"
"\n"
-#: main.c:1197
+#: main.c:1240
#, c-format
msgid "`%s' is not a legal variable name"
msgstr "`%s' nie jest dozwolonÄ… nazwÄ… zmiennej"
-#: main.c:1200
+#: main.c:1243
#, c-format
msgid "`%s' is not a variable name, looking for file `%s=%s'"
msgstr "`%s' nie jest nazwÄ… zmiennej, szukanie pliku `%s=%s'"
-#: main.c:1204
+#: main.c:1247
#, c-format
msgid "cannot use gawk builtin `%s' as variable name"
msgstr "nie można użyć wbudowanej w gawk `%s' jako nazwy zmiennej"
-#: main.c:1209
+#: main.c:1252
#, c-format
msgid "cannot use function `%s' as variable name"
msgstr "nie można użyć funkcji `%s' jako nazwy zmiennej"
-#: main.c:1262
+#: main.c:1305
msgid "floating point exception"
msgstr "wyjÄ…tek zmiennopozycyjny"
-#: main.c:1269
+#: main.c:1312
msgid "fatal error: internal error"
msgstr "fatalny błąd: wewnętrzny błąd"
-#: main.c:1284
+#: main.c:1327
msgid "fatal error: internal error: segfault"
msgstr "fatalny błąd: wewnętrzny błąd: błąd segmentacji"
-#: main.c:1296
+#: main.c:1339
msgid "fatal error: internal error: stack overflow"
msgstr "fatalny błąd: wewnętrzny błąd: przepełnienie stosu"
-#: main.c:1346
+#: main.c:1393
#, c-format
msgid "no pre-opened fd %d"
msgstr "brak już otwartego fd %d"
-#: main.c:1353
+#: main.c:1400
#, c-format
msgid "could not pre-open /dev/null for fd %d"
msgstr "nie można otworzyć zawczasu /dev/null dla fd %d"
-#: msg.c:63
+#: msg.c:61
#, c-format
msgid "cmd. line:"
msgstr "linia poleceń:"
-#: msg.c:107
+#: msg.c:121
msgid "error: "
msgstr "błąd: "
-#: node.c:406
+#: node.c:436
msgid "backslash at end of string"
msgstr "backslash na końcu łańcucha"
-#: node.c:517
+#: node.c:520
#, c-format
msgid "old awk does not support the `\\%c' escape sequence"
msgstr "stary awk nie wspiera sekwencji ucieczki `\\%c'"
-#: node.c:568
+#: node.c:571
msgid "POSIX does not allow `\\x' escapes"
msgstr "POSIX nie zezwala na sekwencjÄ™ ucieczki `\\x'"
-#: node.c:574
+#: node.c:577
msgid "no hex digits in `\\x' escape sequence"
msgstr "brak liczb szesnastkowych w sekwencji ucieczki `\\x'"
-#: node.c:596
+#: node.c:599
#, c-format
msgid ""
"hex escape \\x%.*s of %d characters probably not interpreted the way you "
@@ -2014,12 +1924,12 @@ msgstr ""
"szesnastkowa sekwencja ucieczki \\x%.*s %d znaków prawdopodobnie nie została "
"zinterpretowana jak tego oczekujesz"
-#: node.c:611
+#: node.c:614
#, c-format
msgid "escape sequence `\\%c' treated as plain `%c'"
msgstr "sekwencja ucieczki `\\%c' potraktowana jako zwykłe `%c'"
-#: node.c:750
+#: node.c:759
msgid ""
"Invalid multibyte data detected. There may be a mismatch between your data "
"and your locale."
@@ -2037,16 +1947,16 @@ msgstr "%s %s `%s': nie można uzyskać flag fd: (fcntl F_GETFD: %s)"
msgid "%s %s `%s': could not set close-on-exec: (fcntl F_SETFD: %s)"
msgstr "%s %s `%s': nie można ustawić close-on-exec: (fcntl F_SETFD: %s)"
-#: profile.c:83
+#: profile.c:69
#, c-format
msgid "could not open `%s' for writing: %s"
msgstr "nie można otworzyć `%s' do zapisu: %s"
-#: profile.c:85
+#: profile.c:71
msgid "sending profile to standard error"
msgstr "wysyłanie profilu na standardowe wyjście diagnostyczne"
-#: profile.c:203
+#: profile.c:187
#, c-format
msgid ""
"\t# %s block(s)\n"
@@ -2055,7 +1965,7 @@ msgstr ""
"\t# %s blok(i)\n"
"\n"
-#: profile.c:208
+#: profile.c:192
#, c-format
msgid ""
"\t# Rule(s)\n"
@@ -2064,17 +1974,22 @@ msgstr ""
"\t# Reguła(i)\n"
"\n"
-#: profile.c:279
+#: profile.c:266
#, c-format
msgid "internal error: %s with null vname"
msgstr "wewnętrzny błąd: %s z zerowym vname"
-#: profile.c:952
+#: profile.c:528
+#, fuzzy
+msgid "internal error: builtin with null fname"
+msgstr "wewnętrzny błąd: %s z zerowym vname"
+
+#: profile.c:943
#, c-format
msgid "\t# gawk profile, created %s\n"
msgstr "\t# profil programu gawk, utworzony %s\n"
-#: profile.c:1331
+#: profile.c:1328
#, c-format
msgid ""
"\n"
@@ -2083,17 +1998,17 @@ msgstr ""
"\n"
"\t# Funkcje, spis alfabetyczny\n"
-#: profile.c:1370
+#: profile.c:1366
#, c-format
msgid "redir2str: unknown redirection type %d"
msgstr "redir2str: nieznany typ przekierowania %d"
-#: re.c:573
+#: re.c:571
#, c-format
msgid "range of the form `[%c-%c]' is locale dependent"
msgstr "zasięg formy `[%c-%c]' jest zależny od lokalizacji"
-#: re.c:600
+#: re.c:598
#, c-format
msgid "regexp component `%.*s' should probably be `[%.*s]'"
msgstr "komponent regexp `%.*s' powinien być prawdopodobnie `[%.*s]'"
@@ -2170,6 +2085,80 @@ msgstr "Niedopasowany znak ) lub \\)"
msgid "No previous regular expression"
msgstr "Brak poprzedniego wyrażenia regularnego"
+#~ msgid "attempt to use function `%s' as an array"
+#~ msgstr "próba użycia funkcji `%s' jako tablicy"
+
+#~ msgid "reference to uninitialized element `%s[\"%.*s\"]'"
+#~ msgstr "odwołanie do niezainicjowanego elementu `%s[\"%.*s\"]'"
+
+#~ msgid "subscript of array `%s' is null string"
+#~ msgstr "indeks tablicy `%s' jest zerowym łańcuchem"
+
+#~ msgid "%s: empty (null)\n"
+#~ msgstr "%s: pusty (null)\n"
+
+#~ msgid "%s: empty (zero)\n"
+#~ msgstr "%s: pusty (zero)\n"
+
+#~ msgid "%s: table_size = %d, array_size = %d\n"
+#~ msgstr "%s: table_size = %d, array_size = %d\n"
+
+#~ msgid "%s: is parameter\n"
+#~ msgstr "%s: jest parametrem\n"
+
+#~ msgid "%s: array_ref to %s\n"
+#~ msgstr "%s: array_ref do %s\n"
+
+#~ msgid "use of non-array as array"
+#~ msgstr "użycie nie-tablicy jako tablicy"
+
+#~ msgid "can't use function name `%s' as variable or array"
+#~ msgstr "nie można użyć nazwy funkcji `%s' jako zmiennej lub tablicy"
+
+#~ msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
+#~ msgstr "próba użycia tablicy `%s[\"%.*s\"]' w kontekście skalaru"
+
+#~ msgid "assignment used in conditional context"
+#~ msgstr "przypisanie użyte w kontekście warunkowym"
+
+#~ msgid "statement has no effect"
+#~ msgstr "instrukcja nie ma żadnego efektu"
+
+#~ msgid ""
+#~ "for loop: array `%s' changed size from %ld to %ld during loop execution"
+#~ msgstr ""
+#~ "pętla for: tablica `%s' zmieniła rozmiar z %ld do %ld podczas wykonywania "
+#~ "pętli"
+
+#~ msgid "function called indirectly through `%s' does not exist"
+#~ msgstr "pośrednio wywołana funkcja poprzez `%s' nie istnieje"
+
+#~ msgid "function `%s' not defined"
+#~ msgstr "funkcja `%s' nie została zdefiniowana"
+
+#~ msgid "non-redirected `getline' invalid inside `%s' rule"
+#~ msgstr ""
+#~ "komenda `getline' bez przekierowania jest nieprawidłowa wewnątrz reguły `"
+#~ "%s'"
+
+#~ msgid "error reading input file `%s': %s"
+#~ msgstr "błąd podczas czytania z pliku `%s': %s"
+
+#~ msgid "`nextfile' cannot be called from a `%s' rule"
+#~ msgstr "instrukcja `nextfile' nie może być wywołana z wnętrza reguły `%s'"
+
+#~ msgid "`exit' cannot be called in the current context"
+#~ msgstr "instrukcja `exit' nie może być wywołana w tym kontekście"
+
+#~ msgid "`next' cannot be called from a `%s' rule"
+#~ msgstr "instrukcja `next' nie może być wywołana z wnętrza reguły `%s'"
+
+#~ msgid "Sorry, don't know how to interpret `%s'"
+#~ msgstr "Niestety nie wiem jak zinterpretować `%s'"
+
+#~ msgid "\t-R file\t\t\t--command=file\n"
+#~ msgstr "\t-R plik\t\t\t--command=plik\n"
+
#~ msgid "could not find groups: %s"
#~ msgstr "nie można znaleźć grup: %s"
diff --git a/po/pt_BR.gmo b/po/pt_BR.gmo
deleted file mode 100644
index 4cbc6792..00000000
--- a/po/pt_BR.gmo
+++ /dev/null
Binary files differ
diff --git a/po/ro.gmo b/po/ro.gmo
deleted file mode 100644
index e3534b89..00000000
--- a/po/ro.gmo
+++ /dev/null
Binary files differ
diff --git a/po/rw.gmo b/po/rw.gmo
deleted file mode 100644
index a08f9183..00000000
--- a/po/rw.gmo
+++ /dev/null
Binary files differ
diff --git a/po/sv.gmo b/po/sv.gmo
index d9a408eb..4b08f753 100644
--- a/po/sv.gmo
+++ b/po/sv.gmo
Binary files differ
diff --git a/po/sv.po b/po/sv.po
index 2fff5a46..84fbf74f 100644
--- a/po/sv.po
+++ b/po/sv.po
@@ -10,7 +10,7 @@ msgid ""
msgstr ""
"Project-Id-Version: gawk 4.0.0h\n"
"Report-Msgid-Bugs-To: arnold@skeeve.com\n"
-"POT-Creation-Date: 2012-03-28 22:03+0200\n"
+"POT-Creation-Date: 2012-04-27 10:06+0300\n"
"PO-Revision-Date: 2012-01-30 12:07+0100\n"
"Last-Translator: Göran Uddeborg <goeran@uddeborg.se>\n"
"Language-Team: Swedish <tp-sv@listor.tp-sv.se>\n"
@@ -19,514 +19,471 @@ msgstr ""
"Content-Type: text/plain; charset=iso-8859-1\n"
"Content-Transfer-Encoding: 8bit\n"
-#: array.c:140
+#: array.c:266
#, c-format
msgid "from %s"
msgstr "från %s"
-#: array.c:248
+#: array.c:366
msgid "attempt to use a scalar value as array"
msgstr "försök att använda ett skalärt värde som vektor"
-#: array.c:251
-#, c-format
-msgid "attempt to use function `%s' as an array"
-msgstr "försök att använda funktionen \"%s\" som vektor"
-
-#: array.c:254
+#: array.c:368
#, c-format
msgid "attempt to use scalar parameter `%s' as an array"
msgstr "försök att använda skalärparametern \"%s\" som en vektor"
-#: array.c:257
+#: array.c:371
#, c-format
msgid "attempt to use scalar `%s' as an array"
msgstr "försök att använda skalären \"%s\" som en vektor"
-#: array.c:302 array.c:707 builtin.c:84 builtin.c:1385 builtin.c:1427
-#: builtin.c:1440 builtin.c:1859 builtin.c:1871 eval.c:1135 eval.c:1139
-#: eval.c:1495 eval.c:1812
+#: array.c:418 array.c:584 builtin.c:85 builtin.c:1560 builtin.c:1602
+#: builtin.c:1615 builtin.c:2041 builtin.c:2053 eval.c:1109 eval.c:1113
+#: eval.c:1508
#, c-format
msgid "attempt to use array `%s' in a scalar context"
msgstr "försök att använda vektorn \"%s\" i skalärsammanhang"
-#: array.c:513
-#, c-format
-msgid "reference to uninitialized element `%s[\"%.*s\"]'"
-msgstr "referens till oinitierat element \"%s[\"%.*s\"]\""
-
-#: array.c:519
-#, c-format
-msgid "subscript of array `%s' is null string"
-msgstr "index i vektorn \"%s\" är en tom sträng"
-
-#: array.c:723
+#: array.c:591
#, c-format
msgid "delete: index `%s' not in array `%s'"
msgstr "delete: index \"%s\" finns inte i vektorn \"%s\""
-#: array.c:734 eval.c:1865
+#: array.c:605
#, c-format
msgid "attempt to use scalar `%s[\"%.*s\"]' as an array"
msgstr "försök att använda skalären \"%s[\"%.*s\"]\" som en vektor"
-#: array.c:910
-#, c-format
-msgid "%s: empty (null)\n"
-msgstr "%s: tom (null)\n"
-
-#: array.c:915
-#, c-format
-msgid "%s: empty (zero)\n"
-msgstr "%s: tom (noll)\n"
-
-#: array.c:919
-#, c-format
-msgid "%s: table_size = %d, array_size = %d\n"
-msgstr "%s: tabellstorlek = %d, vektorstorlek = %d\n"
-
-#: array.c:954
-#, c-format
-msgid "%s: is parameter\n"
-msgstr "%s: är en parameter\n"
-
-#: array.c:958
-#, c-format
-msgid "%s: array_ref to %s\n"
-msgstr "%s: vektorreferens till %s\n"
-
-#: array.c:963
-msgid "adump: argument not an array"
+#: array.c:784
+#, fuzzy
+msgid "adump: first argument not an array"
msgstr "adump: argumentet är inte en vektor"
-#: array.c:1086
+#: array.c:823
msgid "asort: second argument not an array"
msgstr "asort: andra argumentet är inte en vektor"
-#: array.c:1087
+#: array.c:824
msgid "asorti: second argument not an array"
msgstr "asorti: andra argumentet är inte en vektor"
-#: array.c:1094
+#: array.c:831
msgid "asort: first argument not an array"
msgstr "asort: första argumentet är inte en vektor"
-#: array.c:1095
+#: array.c:832
msgid "asorti: first argument not an array"
msgstr "asorti: första argumentet är inte en vektor"
-#: array.c:1102
+#: array.c:839
msgid "asort: cannot use a subarray of first arg for second arg"
msgstr ""
"asort: det går inte att använda en delvektor av första argumentet som andra "
"argument"
-#: array.c:1103
+#: array.c:840
msgid "asorti: cannot use a subarray of first arg for second arg"
msgstr ""
"asorti: det går inte att använda en delvektor av första argumentet som andra "
"argument"
-#: array.c:1108
+#: array.c:845
msgid "asort: cannot use a subarray of second arg for first arg"
msgstr ""
"asort: det går inte att använda en delvektor av andra argumentet som första "
"argument"
-#: array.c:1109
+#: array.c:846
msgid "asorti: cannot use a subarray of second arg for first arg"
msgstr ""
"asorti: det går inte att använda en delvektor av andra argumentet som första "
"argument"
-#: array.c:1655
+#: array.c:1314
#, c-format
msgid "`%s' is invalid as a function name"
msgstr "\"%s\" är ogiltigt som ett funktionsnamn"
-#: array.c:1659
+#: array.c:1318
#, c-format
msgid "sort comparison function `%s' is not defined"
msgstr "jämförelsefunktionen \"%s\" för sortering är inte definierad"
-#: awkgram.y:249
+#: awkgram.y:223
#, c-format
msgid "%s blocks must have an action part"
msgstr "%s-block måste ha en åtgärdsdel"
-#: awkgram.y:252
+#: awkgram.y:226
msgid "each rule must have a pattern or an action part"
msgstr "varje regel måste ha ett mönster eller en åtgärdsdel"
-#: awkgram.y:323 awkgram.y:334
+#: awkgram.y:295 awkgram.y:306
msgid "old awk does not support multiple `BEGIN' or `END' rules"
msgstr "gamla awk stöder inte flera \"BEGIN\"- eller \"END\"-regler"
-#: awkgram.y:371
+#: awkgram.y:343
#, c-format
msgid "`%s' is a built-in function, it cannot be redefined"
msgstr "\"%s\" är en inbyggd funktion, den kan inte definieras om"
-#: awkgram.y:432
+#: awkgram.y:389
msgid "regexp constant `//' looks like a C++ comment, but is not"
msgstr "regexp-konstanten \"//\" ser ut som en C++-kommentar men är inte det"
-#: awkgram.y:436
+#: awkgram.y:393
#, c-format
msgid "regexp constant `/%s/' looks like a C comment, but is not"
msgstr "regexp-konstanten \"/%s/\" ser ut som en C-kommentar men är inte det"
-#: awkgram.y:528
+#: awkgram.y:485
#, c-format
msgid "duplicate case values in switch body: %s"
msgstr "upprepade case-värden i switch-sats: %s"
-#: awkgram.y:549
+#: awkgram.y:506
msgid "duplicate `default' detected in switch body"
msgstr "flera \"default\" upptäcktes i switch-sats"
-#: awkgram.y:809
+#: awkgram.y:766
msgid "`break' is not allowed outside a loop or switch"
msgstr "\"break\" är inte tillåtet utanför en slinga eller switch"
-#: awkgram.y:818
+#: awkgram.y:775
msgid "`continue' is not allowed outside a loop"
msgstr "\"continue\" är inte tillåtet utanför en slinga"
-#: awkgram.y:828
+#: awkgram.y:785
#, c-format
msgid "`next' used in %s action"
msgstr "\"next\" använt i %s-åtgärd"
-#: awkgram.y:836
+#: awkgram.y:793
msgid "`nextfile' is a gawk extension"
msgstr "\"nextfile\" är en gawk-utökning"
-#: awkgram.y:841
+#: awkgram.y:798
#, c-format
msgid "`nextfile' used in %s action"
msgstr "\"nextfile\" använt i %s-åtgärd"
-#: awkgram.y:865
+#: awkgram.y:822
msgid "`return' used outside function context"
msgstr "\"return\" använd utanför funktion"
-#: awkgram.y:925
+#: awkgram.y:896
msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'"
msgstr ""
"ensamt \"print\" i BEGIN eller END-regel bör troligen vara 'print \"\"'"
-#: awkgram.y:995 awkgram.y:999 awkgram.y:1023
+#: awkgram.y:966 awkgram.y:970 awkgram.y:994
msgid "`delete array' is a gawk extension"
msgstr "\"delete array\" är en gawk-utökning"
-#: awkgram.y:1019
+#: awkgram.y:990
msgid "`delete(array)' is a non-portable tawk extension"
msgstr "\"delete(array)\" är en icke portabel tawk-utökning"
-#: awkgram.y:1135
+#: awkgram.y:1108
msgid "multistage two-way pipelines don't work"
msgstr "flerstegs dubbelriktade rör fungerar inte"
-#: awkgram.y:1238
+#: awkgram.y:1211
msgid "regular expression on right of assignment"
msgstr "reguljärt uttryck i högerledet av en tilldelning"
-#: awkgram.y:1249
+#: awkgram.y:1222
msgid "regular expression on left of `~' or `!~' operator"
msgstr "reguljärt uttryck på vänster sida om en \"~\"- eller \"!~\"-operator"
-#: awkgram.y:1265 awkgram.y:1419
+#: awkgram.y:1238 awkgram.y:1389
msgid "old awk does not support the keyword `in' except after `for'"
msgstr "gamla awk stöder inte operatorn \"**\""
-#: awkgram.y:1275
+#: awkgram.y:1248
msgid "regular expression on right of comparison"
msgstr "reguljärt uttryck i högerledet av en jämförelse"
-#: awkgram.y:1394
+#: awkgram.y:1364
#, c-format
msgid "`getline var' invalid inside `%s' rule"
msgstr "\"getline var\" är ogiltigt inuti \"%s\"-regel"
-#: awkgram.y:1397 eval.c:2504
+#: awkgram.y:1367
#, c-format
msgid "`getline' invalid inside `%s' rule"
msgstr "\"getline är ogiltigt inuti \"%s\"-regel"
-#: awkgram.y:1402
+#: awkgram.y:1372
msgid "non-redirected `getline' undefined inside END action"
msgstr "icke omdirigerad \"getline\" odefinierad inuti END-åtgärd"
-#: awkgram.y:1421
+#: awkgram.y:1391
msgid "old awk does not support multidimensional arrays"
msgstr "gamla awk stöder inte flerdimensionella vektorer"
-#: awkgram.y:1517
+#: awkgram.y:1488
msgid "call of `length' without parentheses is not portable"
msgstr "anrop av \"length\" utan parenteser är inte portabelt"
-#: awkgram.y:1580
+#: awkgram.y:1554
msgid "indirect function calls are a gawk extension"
msgstr "indirekta funktionsanrop är en gawk-utökning"
-#: awkgram.y:1593
+#: awkgram.y:1567
#, c-format
msgid "can not use special variable `%s' for indirect function call"
msgstr ""
"det går inte att använda specialvariabeln \"%s\" för indirekta fuktionsanrop"
-#: awkgram.y:1671
+#: awkgram.y:1645
msgid "invalid subscript expression"
msgstr "ogiltig indexuttryck"
-#: awkgram.y:1711
-msgid "use of non-array as array"
-msgstr "icke-vektor används som vektor"
-
-#: awkgram.y:1975 awkgram.y:1995 msg.c:98
+#: awkgram.y:1966 awkgram.y:1986 msg.c:112
msgid "warning: "
msgstr "varning: "
-#: awkgram.y:1993 msg.c:130
+#: awkgram.y:1984 msg.c:144
msgid "fatal: "
msgstr "ödesdigert: "
-#: awkgram.y:2043
+#: awkgram.y:2034
msgid "unexpected newline or end of string"
msgstr "oväntat nyradstecken eller slut på strängen"
-#: awkgram.y:2300 awkgram.y:2358 awkgram.y:2542
+#: awkgram.y:2299 awkgram.y:2357 awkgram.y:2545
#, c-format
msgid "can't open source file `%s' for reading (%s)"
msgstr "kan inte öppna källfilen \"%s\" för läsning (%s)"
-#: awkgram.y:2301 awkgram.y:2359 builtin.c:122
+#: awkgram.y:2300 awkgram.y:2358 builtin.c:124
msgid "reason unknown"
msgstr "okänd anledning"
-#: awkgram.y:2317
+#: awkgram.y:2316
#, c-format
msgid "already included source file `%s'"
msgstr "inkluderade redan källfilen \"%s\""
-#: awkgram.y:2343
+#: awkgram.y:2342
msgid "@include is a gawk extension"
msgstr "@include är en gawk-utökning"
-#: awkgram.y:2349
+#: awkgram.y:2348
msgid "empty filename after @include"
msgstr "tomt filnamn efter @include"
-#: awkgram.y:2494
+#: awkgram.y:2497
msgid "empty program text on command line"
msgstr "tom programtext på kommandoraden"
-#: awkgram.y:2609
+#: awkgram.y:2612
#, c-format
msgid "can't read sourcefile `%s' (%s)"
msgstr "kan inte läsa källfilen \"%s\" (%s)"
-#: awkgram.y:2620
+#: awkgram.y:2623
#, c-format
msgid "source file `%s' is empty"
msgstr "källfilen \"%s\" är tom"
-#: awkgram.y:2797
+#: awkgram.y:2800
msgid "source file does not end in newline"
msgstr "källfilen slutar inte med en ny rad"
-#: awkgram.y:2900
+#: awkgram.y:2905
msgid "unterminated regexp ends with `\\' at end of file"
msgstr "oavslutat reguljärt uttryck slutar med \"\\\" i slutet av filen"
-#: awkgram.y:2924
+#: awkgram.y:2929
#, c-format
msgid "%s: %d: tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr ""
"%s: %d: tawk-modifierare för reguljära uttryck \"/.../%c\" fungerar inte i "
"gawk"
-#: awkgram.y:2928
+#: awkgram.y:2933
#, c-format
msgid "tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr ""
"tawk-modifierare för reguljära uttryck \"/.../%c\" fungerar inte i gawk"
-#: awkgram.y:2935
+#: awkgram.y:2940
msgid "unterminated regexp"
msgstr "oavslutat reguljärt uttryck"
-#: awkgram.y:2939
+#: awkgram.y:2944
msgid "unterminated regexp at end of file"
msgstr "oavslutat reguljärt uttryck i slutet av filen"
-#: awkgram.y:2998
+#: awkgram.y:3003
msgid "use of `\\ #...' line continuation is not portable"
msgstr "Användning av \"\\ #...\" för radfortsättning är inte portabelt"
-#: awkgram.y:3014
+#: awkgram.y:3019
msgid "backslash not last character on line"
msgstr "sista tecknet på raden är inte ett omvänt snedstreck"
-#: awkgram.y:3075
+#: awkgram.y:3080
msgid "POSIX does not allow operator `**='"
msgstr "POSIX tillåter inte operatorn \"**=\""
-#: awkgram.y:3077
+#: awkgram.y:3082
msgid "old awk does not support operator `**='"
msgstr "gamla awk stöder inte operatorn \"**=\""
-#: awkgram.y:3086
+#: awkgram.y:3091
msgid "POSIX does not allow operator `**'"
msgstr "POSIX tillåter inte operatorn \"**\""
-#: awkgram.y:3088
+#: awkgram.y:3093
msgid "old awk does not support operator `**'"
msgstr "gamla awk stöder inte operatorn \"**\""
-#: awkgram.y:3123
+#: awkgram.y:3128
msgid "operator `^=' is not supported in old awk"
msgstr "operatorn \"^=\" stöds inte i gamla awk"
-#: awkgram.y:3131
+#: awkgram.y:3136
msgid "operator `^' is not supported in old awk"
msgstr "operatorn \"^\" stöds inte i gamla awk"
-#: awkgram.y:3224 awkgram.y:3240
+#: awkgram.y:3229 awkgram.y:3245
msgid "unterminated string"
msgstr "oavslutad sträng"
-#: awkgram.y:3436
+#: awkgram.y:3466
#, c-format
msgid "invalid char '%c' in expression"
msgstr "ogiltigt tecken \"%c\" i uttryck"
-#: awkgram.y:3483
+#: awkgram.y:3513
#, c-format
msgid "`%s' is a gawk extension"
msgstr "\"%s\" är en gawk-utökning"
-#: awkgram.y:3488
+#: awkgram.y:3518
#, c-format
msgid "`%s' is a Bell Labs extension"
msgstr "\"%s\" är en Bell Labs-utökning"
-#: awkgram.y:3493
+#: awkgram.y:3523
#, c-format
msgid "POSIX does not allow `%s'"
msgstr "POSIX tillåter inte \"%s\""
-#: awkgram.y:3501
+#: awkgram.y:3531
#, c-format
msgid "`%s' is not supported in old awk"
msgstr "\"%s\" stöds inte i gamla awk"
-#: awkgram.y:3568
+#: awkgram.y:3598
msgid "`goto' considered harmful!\n"
msgstr "\"goto\" anses skadlig!\n"
-#: awkgram.y:3619
+#: awkgram.y:3632
#, c-format
msgid "%d is invalid as number of arguments for %s"
msgstr "%d är ett ogiltigt antal argument för %s"
-#: awkgram.y:3654
+#: awkgram.y:3667
#, c-format
msgid "%s: string literal as last arg of substitute has no effect"
msgstr ""
"%s: bokstavlig sträng som sista argument till ersättning har ingen effekt"
-#: awkgram.y:3659
+#: awkgram.y:3672
#, c-format
msgid "%s third parameter is not a changeable object"
msgstr "%s: tredje argumentet är inte ett ändringsbart objekt"
-#: awkgram.y:3732 awkgram.y:3735
+#: awkgram.y:3751 awkgram.y:3754
msgid "match: third argument is a gawk extension"
msgstr "match: tredje argumentet är en gawk-utökning"
-#: awkgram.y:3789 awkgram.y:3792
+#: awkgram.y:3808 awkgram.y:3811
msgid "close: second argument is a gawk extension"
msgstr "close: andra argumentet är en gawk-utökning"
-#: awkgram.y:3804
+#: awkgram.y:3823
msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore"
msgstr ""
"användandet av dcgettext(_\"...\") är felaktigt: ta bort det inledande "
"understrykningstecknet"
-#: awkgram.y:3819
+#: awkgram.y:3838
msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore"
msgstr ""
"användandet av dcngettext(_\"...\") är felaktigt: ta bort det inledande "
"understrykningstecknet"
-#: awkgram.y:3911
-#, c-format
-msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
-msgstr "funktionen \"%s\": parameter %d, \"%s\", är samma som parameter %d"
-
-#: awkgram.y:3953
+#: awkgram.y:3904
#, c-format
msgid "function `%s': parameter `%s' shadows global variable"
msgstr "funktionen \"%s\": parametern \"%s\" överskuggar en global variabel"
-#: awkgram.y:4111
+#: awkgram.y:3961
#, c-format
msgid "could not open `%s' for writing (%s)"
msgstr "kunde inte öppna \"%s\" för skrivning (%s)"
-#: awkgram.y:4112
+#: awkgram.y:3962
msgid "sending variable list to standard error"
msgstr "skickar variabellista till standard fel"
-#: awkgram.y:4118
+#: awkgram.y:3970
#, c-format
msgid "%s: close failed (%s)"
msgstr "%s: misslyckades att stänga (%s)"
-#: awkgram.y:4170
+#: awkgram.y:3995
msgid "shadow_funcs() called twice!"
msgstr "shadow_funcs() anropad två gånger!"
-#: awkgram.y:4176
+#: awkgram.y:4003
msgid "there were shadowed variables."
msgstr "det fanns överskuggade variabler."
-#: awkgram.y:4206
+#: awkgram.y:4074
+#, c-format
+msgid "function name `%s' previously defined"
+msgstr "funktionsnamnet \"%s\" är definierat sedan tidigare"
+
+#: awkgram.y:4120
#, c-format
msgid "function `%s': can't use function name as parameter name"
msgstr "funktionen \"%s\": kan inte använda funktionsnamn som parameternamn"
-#: awkgram.y:4210
+#: awkgram.y:4123
#, c-format
msgid "function `%s': can't use special variable `%s' as a function parameter"
msgstr ""
"funktionen \"%s\": det går inte att använda specialvariabeln \"%s\" som en "
"funktionsparameter"
-#: awkgram.y:4226
+#: awkgram.y:4131
#, c-format
-msgid "function name `%s' previously defined"
-msgstr "funktionsnamnet \"%s\" är definierat sedan tidigare"
+msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
+msgstr "funktionen \"%s\": parameter %d, \"%s\", är samma som parameter %d"
-#: awkgram.y:4394 awkgram.y:4400
+#: awkgram.y:4210 awkgram.y:4216
#, c-format
msgid "function `%s' called but never defined"
msgstr "funktionen \"%s\" anropad men aldrig definierad"
-#: awkgram.y:4403
+#: awkgram.y:4219
#, c-format
msgid "function `%s' defined but never called directly"
msgstr "funktionen \"%s\" definierad men aldrig anropad direkt"
-#: awkgram.y:4435
+#: awkgram.y:4251
#, c-format
msgid "regexp constant for parameter #%d yields boolean value"
msgstr "konstant reguljärt uttryck för parameter %d ger ett booleskt värde"
-#: awkgram.y:4544
+#: awkgram.y:4297
#, c-format
msgid ""
"function `%s' called with space between name and `(',\n"
@@ -535,229 +492,229 @@ msgstr ""
"funktionen \"%s\" anropad med blanktecken mellan namnet och \"(\",\n"
"eller använd som variabel eller vektor"
-#: awkgram.y:4791 eval.c:2056
+#: awkgram.y:4505
msgid "division by zero attempted"
msgstr "försökte dividera med noll"
-#: awkgram.y:4800 eval.c:2072
+#: awkgram.y:4514
#, c-format
msgid "division by zero attempted in `%%'"
msgstr "försökte dividera med noll i \"%%\""
-#: builtin.c:120
+#: builtin.c:122
#, c-format
msgid "%s to \"%s\" failed (%s)"
msgstr "%s till \"%s\" misslyckades (%s)"
-#: builtin.c:121
+#: builtin.c:123
msgid "standard output"
msgstr "standard ut"
-#: builtin.c:135
+#: builtin.c:137
msgid "exp: received non-numeric argument"
msgstr "exp: fick ett ickenumeriskt argument"
-#: builtin.c:141
+#: builtin.c:143
#, c-format
msgid "exp: argument %g is out of range"
msgstr "exp: argumentet %g är inte inom tillåten gräns"
-#: builtin.c:200
+#: builtin.c:202
#, c-format
msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing"
msgstr ""
"fflush: kan inte spola: röret \"%s\" öppnat för läsning, inte skrivning"
-#: builtin.c:203
+#: builtin.c:205
#, c-format
msgid "fflush: cannot flush: file `%s' opened for reading, not writing"
msgstr ""
"fflush: kan inte spola: filen \"%s\" öppnad för läsning, inte skrivning"
-#: builtin.c:215
+#: builtin.c:217
#, c-format
msgid "fflush: `%s' is not an open file, pipe or co-process"
msgstr "fflush: \"%s\" är inte en öppen fil, rör eller koprocess"
-#: builtin.c:333
+#: builtin.c:335
msgid "index: received non-string first argument"
msgstr "index: första argumentet är inte en sträng"
-#: builtin.c:335
+#: builtin.c:337
msgid "index: received non-string second argument"
msgstr "index: andra argumentet är inte en sträng"
-#: builtin.c:457
+#: builtin.c:461
msgid "int: received non-numeric argument"
msgstr "int: fick ett ickenumeriskt argument"
-#: builtin.c:493
+#: builtin.c:497
msgid "length: received array argument"
msgstr "length: fick ett vektorargument"
-#: builtin.c:496
+#: builtin.c:500
msgid "`length(array)' is a gawk extension"
msgstr "\"length(array)\" är en gawk-utökning"
-#: builtin.c:504
+#: builtin.c:508
msgid "length: received non-string argument"
msgstr "length: fick ett argument som inte är en sträng"
-#: builtin.c:535
+#: builtin.c:539
msgid "log: received non-numeric argument"
msgstr "log: fick ett ickenumeriskt argument"
-#: builtin.c:538
+#: builtin.c:542
#, c-format
msgid "log: received negative argument %g"
msgstr "log: fick ett negativt argumentet %g"
-#: builtin.c:694 builtin.c:699
+#: builtin.c:740 builtin.c:745
msgid "fatal: must use `count$' on all formats or none"
msgstr "ödesdigert: måste använda \"count$\" på alla eller inga format"
-#: builtin.c:762
+#: builtin.c:815
#, c-format
msgid "field width is ignored for `%%' specifier"
msgstr "fältbredd ignoreras för \"%%\"-specificerare"
-#: builtin.c:764
+#: builtin.c:817
#, c-format
msgid "precision is ignored for `%%' specifier"
msgstr "precision ignoreras för \"%%\"-specificerare"
-#: builtin.c:766
+#: builtin.c:819
#, c-format
msgid "field width and precision are ignored for `%%' specifier"
msgstr "fältbredd och precision ignoreras för \"%%\"-specificerare"
-#: builtin.c:817
+#: builtin.c:870
msgid "fatal: `$' is not permitted in awk formats"
msgstr "ödesdigert: \"$\" tillåts inte i awk-format"
-#: builtin.c:826
+#: builtin.c:879
msgid "fatal: arg count with `$' must be > 0"
msgstr "ödesdigert: argumentantalet med \"$\" måste vara > 0"
-#: builtin.c:830
+#: builtin.c:883
#, c-format
msgid "fatal: arg count %ld greater than total number of supplied arguments"
msgstr "ödesdigert: argumentantalet %ld är större än antalet givna argument"
-#: builtin.c:834
+#: builtin.c:887
msgid "fatal: `$' not permitted after period in format"
msgstr "ödesdigert: \"$\" tillåts inte efter en punkt i formatet"
-#: builtin.c:850
+#: builtin.c:903
msgid "fatal: no `$' supplied for positional field width or precision"
msgstr ""
"ödesdigert: inget \"$\" bifogat för positionsangiven fältbredd eller "
"precision"
-#: builtin.c:921
+#: builtin.c:975
msgid "`l' is meaningless in awk formats; ignored"
msgstr "\"l\" är meningslös i awk-format, ignorerad"
-#: builtin.c:925
+#: builtin.c:979
msgid "fatal: `l' is not permitted in POSIX awk formats"
msgstr "ödesdigert: \"l\" tillåts inte i POSIX awk-format"
-#: builtin.c:938
+#: builtin.c:992
msgid "`L' is meaningless in awk formats; ignored"
msgstr "\"L\" är meningslös i awk-format, ignorerad"
-#: builtin.c:942
+#: builtin.c:996
msgid "fatal: `L' is not permitted in POSIX awk formats"
msgstr "ödesdigert: \"L\" tillåts inte i POSIX awk-format"
-#: builtin.c:955
+#: builtin.c:1009
msgid "`h' is meaningless in awk formats; ignored"
msgstr "\"h\" är meningslös i awk-format, ignorerad"
-#: builtin.c:959
+#: builtin.c:1013
msgid "fatal: `h' is not permitted in POSIX awk formats"
msgstr "ödesdigert: \"h\" tillåts inte i POSIX awk-format"
-#: builtin.c:1272
+#: builtin.c:1408
#, c-format
msgid "[s]printf: value %g is out of range for `%%%c' format"
msgstr "[s]printf: värdet %g är utanför \"%%%c\"-formatets giltiga intervall"
-#: builtin.c:1332
+#: builtin.c:1506
#, c-format
msgid "ignoring unknown format specifier character `%c': no argument converted"
msgstr ""
"ignorerar okänt formatspecifikationstecken \"%c\": inget argument konverterat"
-#: builtin.c:1337
+#: builtin.c:1511
msgid "fatal: not enough arguments to satisfy format string"
msgstr "ödesdigert: för få argument för formatsträngen"
-#: builtin.c:1339
+#: builtin.c:1513
msgid "^ ran out for this one"
msgstr "^ tog slut här"
-#: builtin.c:1346
+#: builtin.c:1520
msgid "[s]printf: format specifier does not have control letter"
msgstr "[s]printf: formatspecifieraren har ingen kommandobokstav"
-#: builtin.c:1349
+#: builtin.c:1523
msgid "too many arguments supplied for format string"
msgstr "för många argument för formatsträngen"
-#: builtin.c:1423 builtin.c:1434
+#: builtin.c:1598 builtin.c:1609
msgid "printf: no arguments"
msgstr "printf: inga argument"
-#: builtin.c:1475
+#: builtin.c:1650
msgid "sqrt: received non-numeric argument"
msgstr "sqrt: fick ickenumeriskt argument"
-#: builtin.c:1479
+#: builtin.c:1654
#, c-format
msgid "sqrt: called with negative argument %g"
msgstr "sqrt: anropad med negativt argument %g"
-#: builtin.c:1503
+#: builtin.c:1685
#, c-format
msgid "substr: length %g is not >= 1"
msgstr "substr: längden %g är inte >= 1"
-#: builtin.c:1505
+#: builtin.c:1687
#, c-format
msgid "substr: length %g is not >= 0"
msgstr "substr: längden %g är inte >= 0"
-#: builtin.c:1512
+#: builtin.c:1694
#, c-format
msgid "substr: non-integer length %g will be truncated"
msgstr "substr: längden %g som inte är ett heltal kommer trunkeras"
-#: builtin.c:1517
+#: builtin.c:1699
#, c-format
msgid "substr: length %g too big for string indexing, truncating to %g"
msgstr "substr: längden %g är för stor för strängindexering, trunkeras till %g"
-#: builtin.c:1529
+#: builtin.c:1711
#, c-format
msgid "substr: start index %g is invalid, using 1"
msgstr "substr: startindex %g är ogiltigt, använder 1"
-#: builtin.c:1534
+#: builtin.c:1716
#, c-format
msgid "substr: non-integer start index %g will be truncated"
msgstr "substr: startindex %g som inte är ett heltal kommer trunkeras"
-#: builtin.c:1559
+#: builtin.c:1741
msgid "substr: source string is zero length"
msgstr "substr: källsträngen är tom"
-#: builtin.c:1575
+#: builtin.c:1757
#, c-format
msgid "substr: start index %g is past end of string"
msgstr "substr: startindex %g är bortom strängens slut"
-#: builtin.c:1583
+#: builtin.c:1765
#, c-format
msgid ""
"substr: length %g at start index %g exceeds length of first argument (%lu)"
@@ -765,227 +722,222 @@ msgstr ""
"substr: längden %g vid startindex %g överskrider det första argumentets "
"längd (%lu)"
-#: builtin.c:1657
+#: builtin.c:1839
msgid "strftime: format value in PROCINFO[\"strftime\"] has numeric type"
msgstr "strftime: formatvärde i PROCINFO[\"strftime\"] har numerisk typ"
-#: builtin.c:1680
+#: builtin.c:1862
msgid "strftime: received non-numeric second argument"
msgstr "strftime: fick ett ickenumeriskt andra argument"
-#: builtin.c:1683
+#: builtin.c:1866
msgid "strftime: second argument less than 0 or too big for time_t"
msgstr "strftime: andra argimentet mindre än 0 eller för stort för time_t"
-#: builtin.c:1690
+#: builtin.c:1873
msgid "strftime: received non-string first argument"
msgstr "strftime: fick ett första argument som inte är en sträng"
-#: builtin.c:1696
+#: builtin.c:1880
msgid "strftime: received empty format string"
msgstr "strftime: fick en tom formatsträng"
-#: builtin.c:1762
+#: builtin.c:1946
msgid "mktime: received non-string argument"
msgstr "mktime: fick ett argument som inte är en sträng"
-#: builtin.c:1779
+#: builtin.c:1963
msgid "mktime: at least one of the values is out of the default range"
msgstr "mktime: åtminstone ett av värdena är utanför standardintervallet"
-#: builtin.c:1814
+#: builtin.c:1998
msgid "'system' function not allowed in sandbox mode"
msgstr "funktionen \"system\" är inte tillåten i sandlådeläge"
-#: builtin.c:1819
+#: builtin.c:2003
msgid "system: received non-string argument"
msgstr "system: fick ett argument som inte är en sträng"
-#: builtin.c:1874 eval.c:1159 eval.c:1790 eval.c:1803
-#, c-format
-msgid "reference to uninitialized variable `%s'"
-msgstr "referens till icke initierad variabel \"%s\""
-
-#: builtin.c:1941
+#: builtin.c:2121
#, c-format
msgid "reference to uninitialized field `$%d'"
msgstr "referens till icke initierat fält \"$%d\""
-#: builtin.c:2028
+#: builtin.c:2208
msgid "tolower: received non-string argument"
msgstr "tolower: fick ett argument som inte är en sträng"
-#: builtin.c:2062
+#: builtin.c:2242
msgid "toupper: received non-string argument"
msgstr "toupper: fick ett argument som inte är en sträng"
-#: builtin.c:2098
+#: builtin.c:2278
msgid "atan2: received non-numeric first argument"
msgstr "atan2: fick ett ickenumeriskt första argument"
-#: builtin.c:2100
+#: builtin.c:2280
msgid "atan2: received non-numeric second argument"
msgstr "atan2: fick ett ickenumeriskt andra argument"
-#: builtin.c:2119
+#: builtin.c:2299
msgid "sin: received non-numeric argument"
msgstr "sin: fick ett ickenumeriskt argument"
-#: builtin.c:2135
+#: builtin.c:2315
msgid "cos: received non-numeric argument"
msgstr "cos: fick ett ickenumeriskt argument"
-#: builtin.c:2188
+#: builtin.c:2368
msgid "srand: received non-numeric argument"
msgstr "srand: fick ett ickenumeriskt argument"
-#: builtin.c:2219
+#: builtin.c:2399
msgid "match: third argument is not an array"
msgstr "match: tredje argumentet är inte en vektor"
-#: builtin.c:2483
+#: builtin.c:2664
msgid "gensub: third argument of 0 treated as 1"
msgstr "gensub: nollan i tredje argumentet behandlad som en etta"
-#: builtin.c:2776
+#: builtin.c:2957
msgid "lshift: received non-numeric first argument"
msgstr "lshift: fick ett ickenumeriskt första argument"
-#: builtin.c:2778
+#: builtin.c:2959
msgid "lshift: received non-numeric second argument"
msgstr "lshift: fick ett ickenumeriskt andra argument"
-#: builtin.c:2784
+#: builtin.c:2965
#, c-format
msgid "lshift(%lf, %lf): negative values will give strange results"
msgstr "lshift(%lf, %lf): negativa värden kommer ge konstiga resultat"
-#: builtin.c:2786
+#: builtin.c:2967
#, c-format
msgid "lshift(%lf, %lf): fractional values will be truncated"
msgstr "lshift(%lf, %lf): flyttalsvärden kommer trunkeras"
-#: builtin.c:2788
+#: builtin.c:2969
#, c-format
msgid "lshift(%lf, %lf): too large shift value will give strange results"
msgstr "lshift(%lf, %lf): för stora skiftvärden kommer ge konstiga resultat"
-#: builtin.c:2813
+#: builtin.c:2994
msgid "rshift: received non-numeric first argument"
msgstr "rshift: fick ett ickenumeriskt första argument"
-#: builtin.c:2815
+#: builtin.c:2996
msgid "rshift: received non-numeric second argument"
msgstr "rshift: fick ett ickenumeriskt andra argument"
-#: builtin.c:2821
+#: builtin.c:3002
#, c-format
msgid "rshift(%lf, %lf): negative values will give strange results"
msgstr "rshift(%lf, %lf): negativa värden kommer ge konstiga resultat"
-#: builtin.c:2823
+#: builtin.c:3004
#, c-format
msgid "rshift(%lf, %lf): fractional values will be truncated"
msgstr "rshift(%lf, %lf): flyttalsvärden kommer trunkeras"
-#: builtin.c:2825
+#: builtin.c:3006
#, c-format
msgid "rshift(%lf, %lf): too large shift value will give strange results"
msgstr "rshift(%lf, %lf): för stora skiftvärden kommer ge konstiga resultat"
-#: builtin.c:2850
+#: builtin.c:3031
msgid "and: received non-numeric first argument"
msgstr "and: fick ett ickenumeriskt första argument"
-#: builtin.c:2852
+#: builtin.c:3033
msgid "and: received non-numeric second argument"
msgstr "and: fick ett ickenumeriskt andra argument"
-#: builtin.c:2858
+#: builtin.c:3039
#, c-format
msgid "and(%lf, %lf): negative values will give strange results"
msgstr "and(%lf, %lf): negativa värden kommer ge konstiga resultat"
-#: builtin.c:2860
+#: builtin.c:3041
#, c-format
msgid "and(%lf, %lf): fractional values will be truncated"
msgstr "and(%lf, %lf): flyttalsvärden kommer trunkeras"
-#: builtin.c:2885
+#: builtin.c:3066
msgid "or: received non-numeric first argument"
msgstr "or: fick ett ickenumeriskt första argument"
-#: builtin.c:2887
+#: builtin.c:3068
msgid "or: received non-numeric second argument"
msgstr "or: fick ett ickenumeriskt andra argument"
-#: builtin.c:2893
+#: builtin.c:3074
#, c-format
msgid "or(%lf, %lf): negative values will give strange results"
msgstr "or(%lf, %lf): negativa värden kommer ge konstiga resultat"
-#: builtin.c:2895
+#: builtin.c:3076
#, c-format
msgid "or(%lf, %lf): fractional values will be truncated"
msgstr "or(%lf, %lf): flyttalsvärden kommer trunkeras"
-#: builtin.c:2923
+#: builtin.c:3102
msgid "xor: received non-numeric first argument"
msgstr "xor: fick ett ickenumeriskt första argument"
-#: builtin.c:2925
+#: builtin.c:3104
msgid "xor: received non-numeric second argument"
msgstr "xor: fick ett ickenumeriskt andra argument"
-#: builtin.c:2931
+#: builtin.c:3110
#, c-format
msgid "xor(%lf, %lf): negative values will give strange results"
msgstr "xor(%lf, %lf): negativa värden kommer ge konstiga resultat"
-#: builtin.c:2933
+#: builtin.c:3112
#, c-format
msgid "xor(%lf, %lf): fractional values will be truncated"
msgstr "xor(%lf, %lf): flyttalsvärden kommer trunkeras"
-#: builtin.c:2957 builtin.c:2963
+#: builtin.c:3136
msgid "compl: received non-numeric argument"
msgstr "compl: fick ett ickenumeriskt argument"
-#: builtin.c:2965
+#: builtin.c:3142
#, c-format
msgid "compl(%lf): negative value will give strange results"
msgstr "compl(%lf): negativa värden kommer ge konstiga resultat"
-#: builtin.c:2967
+#: builtin.c:3144
#, c-format
msgid "compl(%lf): fractional value will be truncated"
msgstr "compl(%lf): flyttalsvärden kommer trunkeras"
-#: builtin.c:3136
+#: builtin.c:3313
#, c-format
msgid "dcgettext: `%s' is not a valid locale category"
msgstr "dcgettext: \"%s\" är inte en giltig lokalkategori"
-#: eval.c:412
+#: eval.c:395
#, c-format
msgid "unknown nodetype %d"
msgstr "okänd nodtyp %d"
-#: eval.c:423 eval.c:437
+#: eval.c:406 eval.c:420
#, c-format
msgid "unknown opcode %d"
msgstr "okänd op-kod %d"
-#: eval.c:434
+#: eval.c:417
#, c-format
msgid "opcode %s not an operator or keyword"
msgstr "op-kod %s är inte en operator eller ett nyckelord"
-#: eval.c:488
+#: eval.c:472
msgid "buffer overflow in genflags2str"
msgstr "buffertöverflöd i genflags2str"
-#: eval.c:698
+#: eval.c:675
#, c-format
msgid ""
"\n"
@@ -996,306 +948,250 @@ msgstr ""
"\t# Funktionsanropsstack:\n"
"\n"
-#: eval.c:725
+#: eval.c:704
msgid "`IGNORECASE' is a gawk extension"
msgstr "\"IGNORECASE\" är en gawk-utökning"
-#: eval.c:754
+#: eval.c:736
msgid "`BINMODE' is a gawk extension"
msgstr "\"BINMODE\" är en gawk-utökning"
-#: eval.c:812
+#: eval.c:793
#, c-format
msgid "BINMODE value `%s' is invalid, treated as 3"
msgstr "BINMODE-värde \"%s\" är ogiltigt, behandlas som 3"
-#: eval.c:902
+#: eval.c:885
#, c-format
msgid "bad `%sFMT' specification `%s'"
msgstr "felaktig \"%sFMT\"-specifikation \"%s\""
-#: eval.c:980
+#: eval.c:969
msgid "turning off `--lint' due to assignment to `LINT'"
msgstr "slår av \"--lint\" på grund av en tilldelning till \"LINT\""
-#: eval.c:1127 eval.c:1777
-#, c-format
-msgid "can't use function name `%s' as variable or array"
-msgstr "kan inte använda funktionsnamnet \"%s\" som variabel eller vektor"
-
-#: eval.c:1158 eval.c:1789 eval.c:1802
+#: eval.c:1132
#, c-format
msgid "reference to uninitialized argument `%s'"
msgstr "referens till icke initierat argument \"%s\""
-#: eval.c:1177
+#: eval.c:1133
+#, c-format
+msgid "reference to uninitialized variable `%s'"
+msgstr "referens till icke initierad variabel \"%s\""
+
+#: eval.c:1151
msgid "attempt to field reference from non-numeric value"
msgstr "försök att fältreferera från ickenumeriskt värde"
-#: eval.c:1179
+#: eval.c:1153
msgid "attempt to field reference from null string"
msgstr "försök till fältreferens från en tom sträng"
-#: eval.c:1185
+#: eval.c:1161
#, c-format
msgid "attempt to access field %ld"
msgstr "försök att komma åt fält nummer %ld"
-#: eval.c:1194
+#: eval.c:1170
#, c-format
msgid "reference to uninitialized field `$%ld'"
msgstr "referens till icke initierat fält \"$%ld\""
-#: eval.c:1256
+#: eval.c:1257
#, c-format
msgid "function `%s' called with more arguments than declared"
msgstr "funktionen \"%s\" anropad med fler argument än vad som deklarerats"
-#: eval.c:1437
+#: eval.c:1452
#, c-format
msgid "unwind_stack: unexpected type `%s'"
msgstr "unwind_stack: oväntad typ \"%s\""
-#: eval.c:1532
+#: eval.c:1546
msgid "division by zero attempted in `/='"
msgstr "försökte dividera med noll i \"/=\""
-#: eval.c:1539
+#: eval.c:1553
#, c-format
msgid "division by zero attempted in `%%='"
msgstr "försökte dividera med noll i \"%%=\""
-#: eval.c:1876 eval.c:2122
-#, c-format
-msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
-msgstr "försök att använda vektorn \"%s[\"%.*s\"]\" i skalärsammanhang"
-
-#: eval.c:1907
-msgid "assignment used in conditional context"
-msgstr "tilldelning använt i jämförelsesammanhang"
-
-#: eval.c:1911
-msgid "statement has no effect"
-msgstr "kommandot har ingen effekt"
-
-#: eval.c:2343
-#, c-format
-msgid "for loop: array `%s' changed size from %ld to %ld during loop execution"
-msgstr ""
-"forslinga: vektorn \"%s\" ändrade storlek från %ld till %ld under "
-"slingexekvering"
-
-#: eval.c:2458
-#, c-format
-msgid "function called indirectly through `%s' does not exist"
-msgstr "funktionen anropad indirekt genom \"%s\" finns inte"
-
-#: eval.c:2470
-#, c-format
-msgid "function `%s' not defined"
-msgstr "funktionen \"%s\" är inte definierad"
-
-#: eval.c:2511
-#, c-format
-msgid "non-redirected `getline' invalid inside `%s' rule"
-msgstr "icke omdirigerad \"getline\" odefinierad inuti \"%s\"-regel"
-
-#: eval.c:2600
-#, c-format
-msgid "error reading input file `%s': %s"
-msgstr "fel vid läsning av indatafilen \"%s\": %s"
-
-#: eval.c:2614
-#, c-format
-msgid "`nextfile' cannot be called from a `%s' rule"
-msgstr "\"nextfile\" kan inte anropas från en \"%s\"-regel"
-
-#: eval.c:2661
-msgid "`exit' cannot be called in the current context"
-msgstr "\"exit\" kan inte anropas i det aktuella sammanhanget"
-
-#: eval.c:2700
-#, c-format
-msgid "`next' cannot be called from a `%s' rule"
-msgstr "\"next\" kan inte anropas från en \"%s\"-regel"
-
-#: eval.c:2766
-#, c-format
-msgid "Sorry, don't know how to interpret `%s'"
-msgstr "Tyvärr, vet inte hur \"%s\" skall tolkas"
-
-#: ext.c:54
+#: ext.c:70
msgid "extensions are not allowed in sandbox mode"
msgstr "utökningar är inte tillåtna i sandlådeläge"
-#: ext.c:60 ext.c:65
+#: ext.c:73
msgid "`extension' is a gawk extension"
msgstr "\"extension\" är en gawk-utökning"
-#: ext.c:75
-#, c-format
-msgid "fatal: extension: cannot open `%s' (%s)\n"
+#: ext.c:80
+#, fuzzy, c-format
+msgid "extension: cannot open library `%s' (%s)\n"
msgstr "ödesdigert: extension: kan inte öppna \"%s\" (%s)\n"
-#: ext.c:84
-#, c-format
+#: ext.c:86
+#, fuzzy, c-format
msgid ""
-"fatal: extension: library `%s': does not define "
-"`plugin_is_GPL_compatible' (%s)\n"
+"extension: library `%s': does not define `plugin_is_GPL_compatible' (%s)\n"
msgstr ""
"ödesdigert: extension: biblioteket \"%s\": definierar inte "
"\"plugin_is_GPL_compatible\" (%s)\n"
-#: ext.c:93
-#, c-format
-msgid "fatal: extension: library `%s': cannot call function `%s' (%s)\n"
+#: ext.c:90
+#, fuzzy, c-format
+msgid "extension: library `%s': cannot call function `%s' (%s)\n"
msgstr ""
"ödesdigert: extension: bibliotek \"%s\": kan inte anropa funktionen \"%s"
"\" (%s)\n"
-#: ext.c:127
+#: ext.c:118
msgid "extension: missing function name"
msgstr "extension: saknar funktionsnamn"
-#: ext.c:132
+#: ext.c:123
#, c-format
msgid "extension: illegal character `%c' in function name `%s'"
msgstr "extension: ogiltigt tecken \"%c\" i funktionsnamnet \"%s\""
-#: ext.c:141
+#: ext.c:131
#, c-format
msgid "extension: can't redefine function `%s'"
msgstr "extension: det går inte att definiera om funktionen \"%s\""
-#: ext.c:145
+#: ext.c:135
#, c-format
msgid "extension: function `%s' already defined"
msgstr "extension: funktionen \"%s\" är redan definierad"
-#: ext.c:150
+#: ext.c:139
#, c-format
msgid "extension: function name `%s' previously defined"
msgstr "extension: funktionsnamnet \"%s\" är definierat sedan tidigare"
-#: ext.c:152
+#: ext.c:141
#, c-format
msgid "extension: can't use gawk built-in `%s' as function name"
msgstr ""
"extension: kan inte använda gawks inbyggda \"%s\" som ett funktionsnamn"
-#: ext.c:156
+#: ext.c:144
#, c-format
msgid "make_builtin: negative argument count for function `%s'"
msgstr "make_builtin: negativt argumentantal för funktionen \"%s\""
-#: ext.c:259
+#: ext.c:206
#, c-format
msgid "function `%s' defined to take no more than %d argument(s)"
msgstr "funktionen \"%s\" definierades för att ta maximalt %d argument"
-#: ext.c:262
+#: ext.c:209
#, c-format
msgid "function `%s': missing argument #%d"
msgstr "funktionen \"%s\": argument %d saknas"
-#: ext.c:279
+#: ext.c:226
#, c-format
msgid "function `%s': argument #%d: attempt to use scalar as an array"
msgstr "funktionen \"%s\": argument %d: försök att använda skalär som vektor"
-#: ext.c:283
+#: ext.c:230
#, c-format
msgid "function `%s': argument #%d: attempt to use array as a scalar"
msgstr "funktionen \"%s\": argument %d: försök att använda vektor som skalär"
-#: ext.c:296
+#: ext.c:244
msgid "Operation Not Supported"
msgstr "Operationen stöds inte"
-#: field.c:328
+#: ext.c:256
+msgid "dynamic loading of library not supported"
+msgstr ""
+
+#: field.c:339
msgid "NF set to negative value"
msgstr "NF satt till ett negativt värde"
-#: field.c:951 field.c:958 field.c:962
+#: field.c:962 field.c:969 field.c:973
msgid "split: fourth argument is a gawk extension"
msgstr "split: fjärde argumentet är en gawk-utökning"
-#: field.c:955
+#: field.c:966
msgid "split: fourth argument is not an array"
msgstr "split: fjärde argumentet är inte en vektor"
-#: field.c:969
+#: field.c:980
msgid "split: second argument is not an array"
msgstr "split: andra argumentet är inte en vektor"
-#: field.c:973
+#: field.c:984
msgid "split: cannot use the same array for second and fourth args"
msgstr ""
"split: det går inte att använda samma vektor som andra och fjärde argument"
-#: field.c:978
+#: field.c:989
msgid "split: cannot use a subarray of second arg for fourth arg"
msgstr ""
"split: det går inte att använda en delvektor av andra argumentet som fjärde "
"argument"
-#: field.c:981
+#: field.c:992
msgid "split: cannot use a subarray of fourth arg for second arg"
msgstr ""
"split: det går inte att använda en delvektor av fjärde argumentet som andra "
"argument"
-#: field.c:1010
+#: field.c:1021
msgid "split: null string for third arg is a gawk extension"
msgstr "split: tom sträng som tredje argument är en gawk-utökning"
-#: field.c:1050
+#: field.c:1061
msgid "patsplit: fourth argument is not an array"
msgstr "patsplit: fjärde argumentet är inte en vektor"
-#: field.c:1055
+#: field.c:1066
msgid "patsplit: second argument is not an array"
msgstr "patsplit: andra argumentet är inte en vektor"
-#: field.c:1061
+#: field.c:1072
msgid "patsplit: third argument must be non-null"
msgstr "patsplit: tredje argumentet får inte vara tomt"
-#: field.c:1065
+#: field.c:1076
msgid "patsplit: cannot use the same array for second and fourth args"
msgstr ""
"patsplit: det går inte att använda samma vektor som andra och fjärde argument"
-#: field.c:1070
+#: field.c:1081
msgid "patsplit: cannot use a subarray of second arg for fourth arg"
msgstr ""
"patsplit: det går inte att använda en delvektor av andra argumentet som "
"fjärde argument"
-#: field.c:1073
+#: field.c:1084
msgid "patsplit: cannot use a subarray of fourth arg for second arg"
msgstr ""
"patsplit: det går inte att använda en delvektor av fjärde argumentet som "
"andra argument"
-#: field.c:1110
+#: field.c:1122
msgid "`FIELDWIDTHS' is a gawk extension"
msgstr "\"FIELDWIDTHS\" är en gawk-utökning"
-#: field.c:1173
+#: field.c:1186
#, c-format
msgid "invalid FIELDWIDTHS value, near `%s'"
msgstr "ogiltigt FIELDWITHS-värde i närheten av \"%s\""
-#: field.c:1246
+#: field.c:1259
msgid "null string for `FS' is a gawk extension"
msgstr "tom sträng som \"FS\" är en gawk-utökning"
-#: field.c:1250
+#: field.c:1263
msgid "old awk does not support regexps as value of `FS'"
msgstr "gamla awk stöder inte reguljära uttryck som värden på \"FS\""
-#: field.c:1369
+#: field.c:1382
msgid "`FPAT' is a gawk extension"
msgstr "\"FPAT\" är en gawk-utökning"
@@ -1354,458 +1250,473 @@ msgstr "%s: flaggan \"-W %s\" tillåter inte något argument\n"
msgid "%s: option '-W %s' requires an argument\n"
msgstr "%s: flaggan \"-W %s\" kräver ett argument\n"
-#: io.c:280
+#: io.c:326
#, c-format
msgid "command line argument `%s' is a directory: skipped"
msgstr "kommandoradsargumentet \"%s\" är en katalog: hoppas över"
-#: io.c:283 io.c:385
+#: io.c:329 io.c:438
#, c-format
msgid "cannot open file `%s' for reading (%s)"
msgstr "kan inte öppna filen \"%s\" för läsning (%s)"
-#: io.c:501
+#: io.c:568
#, c-format
msgid "close of fd %d (`%s') failed (%s)"
msgstr "stängning av fd %d (\"%s\") misslyckades (%s)"
-#: io.c:578
+#: io.c:645
msgid "redirection not allowed in sandbox mode"
msgstr "omdirigering är inte tillåten i sandlådeläge"
-#: io.c:612
+#: io.c:679
#, c-format
msgid "expression in `%s' redirection only has numeric value"
msgstr "uttrycket i \"%s\"-omdirigering har bara numeriskt värde"
-#: io.c:618
+#: io.c:685
#, c-format
msgid "expression for `%s' redirection has null string value"
msgstr "uttrycket för \"%s\"-omdirigering har en tom sträng som värde"
-#: io.c:623
+#: io.c:690
#, c-format
msgid "filename `%s' for `%s' redirection may be result of logical expression"
msgstr ""
"filnamnet \"%s\" för \"%s\"-omdirigering kan vara resultatet av ett logiskt "
"uttryck"
-#: io.c:666
+#: io.c:733
#, c-format
msgid "unnecessary mixing of `>' and `>>' for file `%.*s'"
msgstr "onödig blandning av \">\" och \">>\" för filen \"%.*s\""
-#: io.c:719
+#: io.c:786
#, c-format
msgid "can't open pipe `%s' for output (%s)"
msgstr "kan inte öppna röret \"%s\" för utmatning (%s)"
-#: io.c:729
+#: io.c:796
#, c-format
msgid "can't open pipe `%s' for input (%s)"
msgstr "kan inte öppna röret \"%s\" för inmatning (%s)"
-#: io.c:752
+#: io.c:819
#, c-format
msgid "can't open two way pipe `%s' for input/output (%s)"
msgstr "kan inte öppna tvåvägsröret \"%s\" för in-/utmatning (%s)"
-#: io.c:834
+#: io.c:900
#, c-format
msgid "can't redirect from `%s' (%s)"
msgstr "kan inte dirigera om från \"%s\" (%s)"
-#: io.c:837
+#: io.c:903
#, c-format
msgid "can't redirect to `%s' (%s)"
msgstr "kan inte dirigera om till \"%s\" (%s)"
-#: io.c:888
+#: io.c:954
msgid ""
"reached system limit for open files: starting to multiplex file descriptors"
msgstr ""
"nådde systembegränsningen för öppna filer: börjar multiplexa fildeskriptorer"
-#: io.c:904
+#: io.c:970
#, c-format
msgid "close of `%s' failed (%s)."
msgstr "stängning av \"%s\" misslyckades (%s)"
-#: io.c:912
+#: io.c:978
msgid "too many pipes or input files open"
msgstr "för många rör eller indatafiler öppna"
-#: io.c:934
+#: io.c:1000
msgid "close: second argument must be `to' or `from'"
msgstr "close: andra argumentet måste vara \"to\" eller \"from\""
-#: io.c:951
+#: io.c:1017
#, c-format
msgid "close: `%.*s' is not an open file, pipe or co-process"
msgstr "close: \"%.*s\" är inte en öppen fil, rör eller koprocess"
-#: io.c:956
+#: io.c:1022
msgid "close of redirection that was never opened"
msgstr "stängning av omdirigering som aldrig öppnades"
-#: io.c:1053
+#: io.c:1120
#, c-format
msgid "close: redirection `%s' not opened with `|&', second argument ignored"
msgstr ""
"close: omdirigeringen \"%s\" öppnades inte med \"|&\", andra argumentet "
"ignorerat"
-#: io.c:1069
+#: io.c:1137
#, c-format
msgid "failure status (%d) on pipe close of `%s' (%s)"
msgstr "felstatus (%d) från rörstängning av \"%s\" (%s)"
-#: io.c:1072
+#: io.c:1140
#, c-format
msgid "failure status (%d) on file close of `%s' (%s)"
msgstr "felstatus (%d) från filstängning av \"%s\" (%s)"
-#: io.c:1092
+#: io.c:1160
#, c-format
msgid "no explicit close of socket `%s' provided"
msgstr "ingen explicit stängning av uttaget \"%s\" tillhandahållen"
-#: io.c:1095
+#: io.c:1163
#, c-format
msgid "no explicit close of co-process `%s' provided"
msgstr "ingen explicit stängning av koprocessen \"%s\" tillhandahållen"
-#: io.c:1098
+#: io.c:1166
#, c-format
msgid "no explicit close of pipe `%s' provided"
msgstr "ingen explicit stängning av röret \"%s\" tillhandahållen"
-#: io.c:1101
+#: io.c:1169
#, c-format
msgid "no explicit close of file `%s' provided"
msgstr "ingen explicit stängning av filen \"%s\" tillhandahållen"
-#: io.c:1129 io.c:1184 main.c:794 main.c:831
+#: io.c:1197 io.c:1252 main.c:825 main.c:862
#, c-format
msgid "error writing standard output (%s)"
msgstr "fel vid skrivning till standard ut (%s)"
-#: io.c:1133 io.c:1189
+#: io.c:1201 io.c:1257
#, c-format
msgid "error writing standard error (%s)"
msgstr "fel vid skrivning till standard fel (%s)"
-#: io.c:1141
+#: io.c:1209
#, c-format
msgid "pipe flush of `%s' failed (%s)."
msgstr "rörspolning av \"%s\" misslyckades (%s)"
-#: io.c:1144
+#: io.c:1212
#, c-format
msgid "co-process flush of pipe to `%s' failed (%s)."
msgstr "koprocesspolning av röret till \"%s\" misslyckades (%s)"
-#: io.c:1147
+#: io.c:1215
#, c-format
msgid "file flush of `%s' failed (%s)."
msgstr "filspolning av \"%s\" misslyckades (%s)"
-#: io.c:1262
+#: io.c:1329
#, c-format
msgid "local port %s invalid in `/inet'"
msgstr "lokal port %s ogiltig i \"/inet\""
-#: io.c:1279
+#: io.c:1347
#, c-format
msgid "remote host and port information (%s, %s) invalid"
msgstr "ogiltig information (%s, %s) för fjärrvärd och fjärrport"
-#: io.c:1431
+#: io.c:1499
#, c-format
msgid "no (known) protocol supplied in special filename `%s'"
msgstr ""
"inget (känt) protokoll tillhandahållet i det speciella filnamnet \"%s\""
-#: io.c:1445
+#: io.c:1513
#, c-format
msgid "special file name `%s' is incomplete"
msgstr "speciellt filnamn \"%s\" är ofullständigt"
-#: io.c:1462
+#: io.c:1530
msgid "must supply a remote hostname to `/inet'"
msgstr "måste tillhandahålla ett fjärrdatornamn till \"/inet\""
-#: io.c:1480
+#: io.c:1548
msgid "must supply a remote port to `/inet'"
msgstr "måste tillhandahålla en fjärrport till \"/inet\""
-#: io.c:1526
+#: io.c:1594
msgid "TCP/IP communications are not supported"
msgstr "TCP/IP-kommunikation stöds inte"
-#: io.c:1693
+#: io.c:1764
#, c-format
msgid "could not open `%s', mode `%s'"
msgstr "kunde inte öppna \"%s\", läge \"%s\""
-#: io.c:1747
+#: io.c:1814
#, c-format
msgid "close of master pty failed (%s)"
msgstr "stängning av huvudpty misslyckades (%s)"
-#: io.c:1749 io.c:1917 io.c:2074
+#: io.c:1816 io.c:1984 io.c:2145
#, c-format
msgid "close of stdout in child failed (%s)"
msgstr "stängning av standard ut i barnet misslyckades (%s)"
-#: io.c:1752
+#: io.c:1819
#, c-format
msgid "moving slave pty to stdout in child failed (dup: %s)"
msgstr "flyttandet av slavpty till standard ut i barnet misslyckades (dup: %s)"
-#: io.c:1754 io.c:1922
+#: io.c:1821 io.c:1989
#, c-format
msgid "close of stdin in child failed (%s)"
msgstr "stängning av standard in i barnet misslyckades (%s)"
-#: io.c:1757
+#: io.c:1824
#, c-format
msgid "moving slave pty to stdin in child failed (dup: %s)"
msgstr "flyttandet av slavpty till standard in i barnet misslyckades (dup: %s)"
-#: io.c:1759 io.c:1780
+#: io.c:1826 io.c:1847
#, c-format
msgid "close of slave pty failed (%s)"
msgstr "stängning av slavpty misslyckades (%s)"
-#: io.c:1858 io.c:1920 io.c:2052 io.c:2077
+#: io.c:1925 io.c:1987 io.c:2122 io.c:2148
#, c-format
msgid "moving pipe to stdout in child failed (dup: %s)"
msgstr "flyttande av rör till standard ut i barnet misslyckades (dup: %s)"
-#: io.c:1865 io.c:1925
+#: io.c:1932 io.c:1992
#, c-format
msgid "moving pipe to stdin in child failed (dup: %s)"
msgstr "flyttande av rör till standard in i barnet misslyckades (dup: %s)"
-#: io.c:1885 io.c:2067
+#: io.c:1952 io.c:2138
msgid "restoring stdout in parent process failed\n"
msgstr "återställande av standard ut i förälderprocessen misslyckades\n"
-#: io.c:1893
+#: io.c:1960
msgid "restoring stdin in parent process failed\n"
msgstr "återställande av standard in i förälderprocessen misslyckades\n"
-#: io.c:1928 io.c:2079 io.c:2093
+#: io.c:1995 io.c:2150 io.c:2164
#, c-format
msgid "close of pipe failed (%s)"
msgstr "stängning av röret misslyckades (%s)"
-#: io.c:1973
+#: io.c:2040
msgid "`|&' not supported"
msgstr "\"|&\" stöds inte"
-#: io.c:2039
+#: io.c:2107
#, c-format
msgid "cannot open pipe `%s' (%s)"
msgstr "kan inte öppna röret \"%s\" (%s)"
-#: io.c:2087
+#: io.c:2158
#, c-format
msgid "cannot create child process for `%s' (fork: %s)"
msgstr "kan inte skapa barnprocess för \"%s\" (fork: %s)"
-#: io.c:2520
+#: io.c:2637
#, c-format
msgid "data file `%s' is empty"
msgstr "datafilen \"%s\" är tom"
-#: io.c:2561 io.c:2569
+#: io.c:2678 io.c:2686
msgid "could not allocate more input memory"
msgstr "kunde inte allokera mer indataminne"
-#: io.c:3127
+#: io.c:3236
msgid "multicharacter value of `RS' is a gawk extension"
msgstr "flerteckensvärdet av \"RS\" är en gawk-utökning"
-#: io.c:3232
+#: io.c:3326
msgid "IPv6 communication is not supported"
msgstr "IPv6-kommunikation stöds inte"
-#: main.c:366
+#: main.c:355
msgid "`-m[fr]' option irrelevant in gawk"
msgstr "\"-m[fr]\"-flaggan är irrelevant i gawk"
-#: main.c:368
+#: main.c:357
msgid "-m option usage: `-m[fr] nnn'"
msgstr "-m-flaggans användning: \"-m[fr] nnn\""
-#: main.c:391
+#: main.c:386
msgid "empty argument to `-e/--source' ignored"
msgstr "tomt argument till \"-e/--source\" ignorerat"
-#: main.c:462
+#: main.c:472
#, c-format
msgid "%s: option `-W %s' unrecognized, ignored\n"
msgstr "%s: flaggan \"-W %s\" okänd, ignorerad\n"
-#: main.c:515
+#: main.c:518
#, c-format
msgid "%s: option requires an argument -- %c\n"
msgstr "%s: flaggan kräver ett argument -- %c\n"
-#: main.c:536
+#: main.c:539
msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'"
msgstr "miljövariabeln \"POSIXLY_CORRECT\" satt: slår på \"--posix\""
-#: main.c:542
+#: main.c:545
msgid "`--posix' overrides `--traditional'"
msgstr "\"--posix\" åsidosätter \"--traditional\""
-#: main.c:553
+#: main.c:556
msgid "`--posix'/`--traditional' overrides `--non-decimal-data'"
msgstr "\"--posix\"/\"--traditional\" åsidosätter \"--non-decimal-data\""
-#: main.c:557
+#: main.c:560
#, c-format
msgid "running %s setuid root may be a security problem"
msgstr "att köra %s setuid root kan vara ett säkerhetsproblem"
-#: main.c:562
+#: main.c:565
msgid "`--posix' overrides `--binary'"
msgstr "\"--posix\" åsidosätter \"--binary\""
-#: main.c:613
+#: main.c:623
#, c-format
msgid "can't set binary mode on stdin (%s)"
msgstr "kan inte sätta binärläge på standard in (%s)"
-#: main.c:616
+#: main.c:626
#, c-format
msgid "can't set binary mode on stdout (%s)"
msgstr "kan inte sätta binärläge på standard ut (%s)"
-#: main.c:618
+#: main.c:628
#, c-format
msgid "can't set binary mode on stderr (%s)"
msgstr "kan inte sätta binärläge på standard fel (%s)"
-#: main.c:657
+#: main.c:679
msgid "no program text at all!"
msgstr "ingen programtext alls!"
-#: main.c:734
+#: main.c:763
#, c-format
msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n"
msgstr ""
"Användning: %s [POSIX- eller GNU-stilsflaggor] -f progfil [--] fil ...\n"
-#: main.c:736
+#: main.c:765
#, c-format
msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n"
msgstr "Användning: %s [POSIX- eller GNU-stilsflaggor] %cprogram%c fil ...\n"
-#: main.c:741
+#: main.c:770
msgid "POSIX options:\t\tGNU long options: (standard)\n"
msgstr "POSIX-flaggor:\t\tGNU långa flaggor: (standard)\n"
-#: main.c:742
+#: main.c:771
msgid "\t-f progfile\t\t--file=progfile\n"
msgstr "\t-f progfil\t\t--file=progfil\n"
-#: main.c:743
+#: main.c:772
msgid "\t-F fs\t\t\t--field-separator=fs\n"
msgstr "\t-F fs\t\t\t--field-separator=fs\n"
-#: main.c:744
+#: main.c:773
msgid "\t-v var=val\t\t--assign=var=val\n"
msgstr "\t-v var=värde\t\t--assign=var=värde\n"
-#: main.c:745
+#: main.c:774
msgid "Short options:\t\tGNU long options: (extensions)\n"
msgstr "Korta flaggor:\t\tGNU långa flaggor: (utökningar)\n"
-#: main.c:746
+#: main.c:775
msgid "\t-b\t\t\t--characters-as-bytes\n"
msgstr "\t-b\t\t\t--characters-as-bytes\n"
-#: main.c:747
+#: main.c:776
msgid "\t-c\t\t\t--traditional\n"
msgstr "\t-c\t\t\t--traditional\n"
-#: main.c:748
+#: main.c:777
msgid "\t-C\t\t\t--copyright\n"
msgstr "\t-C\t\t\t--copyright\n"
-#: main.c:749
+#: main.c:778
msgid "\t-d[file]\t\t--dump-variables[=file]\n"
msgstr "\t-d[fil]\t\t\t--dump-variables[=fil]\n"
-#: main.c:750
+#: main.c:779
+#, fuzzy
+msgid "\t-D[file]\t\t--debug[=file]\n"
+msgstr "\t-p[fil]\t\t\t--profile[=fil]\n"
+
+#: main.c:780
msgid "\t-e 'program-text'\t--source='program-text'\n"
msgstr "\t-e 'programtext'\t--source='programtext'\n"
-#: main.c:751
+#: main.c:781
msgid "\t-E file\t\t\t--exec=file\n"
msgstr "\t-E fil\t\t\t--exec=fil\n"
-#: main.c:752
+#: main.c:782
msgid "\t-g\t\t\t--gen-pot\n"
msgstr "\t-g\t\t\t--gen-pot\n"
-#: main.c:753
+#: main.c:783
msgid "\t-h\t\t\t--help\n"
msgstr "\t-h\t\t\t--help\n"
-#: main.c:754
+#: main.c:784
+msgid "\t-l library\t\t--load=library\n"
+msgstr ""
+
+#: main.c:785
msgid "\t-L [fatal]\t\t--lint[=fatal]\n"
msgstr "\t-L [fatal]\t\t--lint[=fatal]\n"
-#: main.c:755
+#: main.c:786
msgid "\t-n\t\t\t--non-decimal-data\n"
msgstr "\t-n\t\t\t--non-decimal-data\n"
-#: main.c:756
+#: main.c:787
+#, fuzzy
+msgid "\t-M\t\t\t--bignum\n"
+msgstr "\t-g\t\t\t--gen-pot\n"
+
+#: main.c:788
msgid "\t-N\t\t\t--use-lc-numeric\n"
msgstr "\t-N\t\t\t--use-lc-numeric\n"
-#: main.c:757
+#: main.c:789
+#, fuzzy
+msgid "\t-o[file]\t\t--pretty-print[=file]\n"
+msgstr "\t-p[fil]\t\t\t--profile[=fil]\n"
+
+#: main.c:790
msgid "\t-O\t\t\t--optimize\n"
msgstr "\t-O\t\t\t--optimize\n"
-#: main.c:758
+#: main.c:791
msgid "\t-p[file]\t\t--profile[=file]\n"
msgstr "\t-p[fil]\t\t\t--profile[=fil]\n"
-#: main.c:759
+#: main.c:792
msgid "\t-P\t\t\t--posix\n"
msgstr "\t-P\t\t\t--posix\n"
-#: main.c:760
+#: main.c:793
msgid "\t-r\t\t\t--re-interval\n"
msgstr "\t-r\t\t\t--re-interval\n"
-#: main.c:762
-msgid "\t-R file\t\t\t--command=file\n"
-msgstr "\t-R file\t\t\t--command=file\n"
-
-#: main.c:763
+#: main.c:794
msgid "\t-S\t\t\t--sandbox\n"
msgstr "\t-S\t\t\t--sandbox\n"
-#: main.c:764
+#: main.c:795
msgid "\t-t\t\t\t--lint-old\n"
msgstr "\t-t\t\t\t--lint-old\n"
-#: main.c:765
+#: main.c:796
msgid "\t-V\t\t\t--version\n"
msgstr "\t-V\t\t\t--version\n"
-#: main.c:767
+#: main.c:798
msgid "\t-W nostalgia\t\t--nostalgia\n"
msgstr "\t-W nostalgia\t\t--nostalgia\n"
-#: main.c:770
+#: main.c:801
msgid "\t-Y\t\t--parsedebug\n"
msgstr "\t-Y\t\t--parsedebug\n"
@@ -1814,7 +1725,7 @@ msgstr "\t-Y\t\t--parsedebug\n"
#. for this application. Please add _another line_ with the
#. address for translation bugs.
#. no-wrap
-#: main.c:779
+#: main.c:810
msgid ""
"\n"
"To report bugs, see node `Bugs' in `gawk.info', which is\n"
@@ -1828,7 +1739,7 @@ msgstr ""
"Rapportera synpunkter på översättningen till <tp-sv@listor.tp-sv.se>.\n"
"\n"
-#: main.c:783
+#: main.c:814
msgid ""
"gawk is a pattern scanning and processing language.\n"
"By default it reads standard input and writes standard output.\n"
@@ -1838,7 +1749,7 @@ msgstr ""
"Normalt läser det från standard in och skriver till standard ut.\n"
"\n"
-#: main.c:787
+#: main.c:818
msgid ""
"Examples:\n"
"\tgawk '{ sum += $1 }; END { print sum }' file\n"
@@ -1848,7 +1759,7 @@ msgstr ""
"\tgawk '{ sum += $1 }; END { print sum }' fil\n"
"\tgawk -F: '{ print $1 }' /etc/passwd\n"
-#: main.c:807
+#: main.c:838
#, c-format
msgid ""
"Copyright (C) 1989, 1991-%d Free Software Foundation.\n"
@@ -1867,7 +1778,7 @@ msgstr ""
"någon senare version.\n"
"\n"
-#: main.c:815
+#: main.c:846
msgid ""
"This program is distributed in the hope that it will be useful,\n"
"but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
@@ -1881,7 +1792,7 @@ msgstr ""
"General Public License för ytterligare information.\n"
"\n"
-#: main.c:821
+#: main.c:852
msgid ""
"You should have received a copy of the GNU General Public License\n"
"along with this program. If not, see http://www.gnu.org/licenses/.\n"
@@ -1889,95 +1800,95 @@ msgstr ""
"Du bör ha fått en kopia av GNU General Public License tillsammans\n"
"med detta program. Om inte, se http//www.gnu.org/liceences/.\n"
-#: main.c:856
+#: main.c:887
msgid "-Ft does not set FS to tab in POSIX awk"
msgstr "-Ft sätter inte FS till tab i POSIX-awk"
-#: main.c:1090
+#: main.c:1133
#, c-format
msgid "unknown value for field spec: %d\n"
msgstr "okänt värde till fältspecifikation: %d\n"
-#: main.c:1171
+#: main.c:1214
#, c-format
msgid ""
"%s: `%s' argument to `-v' not in `var=value' form\n"
"\n"
msgstr "%s: Argumentet \"%s\" till \"-v\" är inte på formatet \"var=värde\"\n"
-#: main.c:1197
+#: main.c:1240
#, c-format
msgid "`%s' is not a legal variable name"
msgstr "\"%s\" är inte ett giltigt variabelnamn"
-#: main.c:1200
+#: main.c:1243
#, c-format
msgid "`%s' is not a variable name, looking for file `%s=%s'"
msgstr "\"%s\" är inte ett variabelnamn, letar efter filen \"%s=%s\""
-#: main.c:1204
+#: main.c:1247
#, c-format
msgid "cannot use gawk builtin `%s' as variable name"
msgstr "kan inte använda gawks inbyggda \"%s\" som ett funktionsnamn"
-#: main.c:1209
+#: main.c:1252
#, c-format
msgid "cannot use function `%s' as variable name"
msgstr "kan inte använda funktionen \"%s\" som variabelnamn"
-#: main.c:1262
+#: main.c:1305
msgid "floating point exception"
msgstr "flyttalsundantag"
-#: main.c:1269
+#: main.c:1312
msgid "fatal error: internal error"
msgstr "ödesdigert fel: internt fel"
-#: main.c:1284
+#: main.c:1327
msgid "fatal error: internal error: segfault"
msgstr "ödesdigert fel: internt fel: segmenteringsfel"
-#: main.c:1296
+#: main.c:1339
msgid "fatal error: internal error: stack overflow"
msgstr "ödesdigert fel: internt fel: stackspill"
-#: main.c:1346
+#: main.c:1393
#, c-format
msgid "no pre-opened fd %d"
msgstr "ingen föröppnad fd %d"
-#: main.c:1353
+#: main.c:1400
#, c-format
msgid "could not pre-open /dev/null for fd %d"
msgstr "kunde inte föröppna /dev/null för fd %d"
-#: msg.c:63
+#: msg.c:61
#, c-format
msgid "cmd. line:"
msgstr "kommandorad:"
-#: msg.c:107
+#: msg.c:121
msgid "error: "
msgstr "fel: "
-#: node.c:406
+#: node.c:436
msgid "backslash at end of string"
msgstr "omvänt snedstreck i slutet av strängen"
-#: node.c:517
+#: node.c:520
#, c-format
msgid "old awk does not support the `\\%c' escape sequence"
msgstr "gamla awk stöder inte kontrollsekvensen \"\\%c\""
-#: node.c:568
+#: node.c:571
msgid "POSIX does not allow `\\x' escapes"
msgstr "POSIX tillåter inte \"\\x\"-kontrollsekvenser"
-#: node.c:574
+#: node.c:577
msgid "no hex digits in `\\x' escape sequence"
msgstr "inga hexadecimala siffror i \"\\x\"-kontrollsekvenser"
-#: node.c:596
+#: node.c:599
#, c-format
msgid ""
"hex escape \\x%.*s of %d characters probably not interpreted the way you "
@@ -1986,12 +1897,12 @@ msgstr ""
"hexkod \\x%.*s med %d tecken tolkas förmodligen inte på det sätt du "
"förväntar dig"
-#: node.c:611
+#: node.c:614
#, c-format
msgid "escape sequence `\\%c' treated as plain `%c'"
msgstr "kontrollsekvensen \"\\%c\" behandlad som bara \"%c\""
-#: node.c:750
+#: node.c:759
msgid ""
"Invalid multibyte data detected. There may be a mismatch between your data "
"and your locale."
@@ -2009,16 +1920,16 @@ msgstr "%s %s \"%s\": kunde inte hämta fb-flaggor: (fcntl F_GETFD: %s)"
msgid "%s %s `%s': could not set close-on-exec: (fcntl F_SETFD: %s)"
msgstr "%s %s \"%s\": kunde inte sätta stäng-vid-exec (fcntl F_SETFD: %s)"
-#: profile.c:83
+#: profile.c:69
#, c-format
msgid "could not open `%s' for writing: %s"
msgstr "kunde inte öppna \"%s\" för skrivning: %s"
-#: profile.c:85
+#: profile.c:71
msgid "sending profile to standard error"
msgstr "skickar profilen till standard fel"
-#: profile.c:203
+#: profile.c:187
#, c-format
msgid ""
"\t# %s block(s)\n"
@@ -2027,7 +1938,7 @@ msgstr ""
"\t# %s-block\n"
"\n"
-#: profile.c:208
+#: profile.c:192
#, c-format
msgid ""
"\t# Rule(s)\n"
@@ -2036,17 +1947,22 @@ msgstr ""
"\t# Regel/regler\n"
"\n"
-#: profile.c:279
+#: profile.c:266
#, c-format
msgid "internal error: %s with null vname"
msgstr "internt fel: %s med null vname"
-#: profile.c:952
+#: profile.c:528
+#, fuzzy
+msgid "internal error: builtin with null fname"
+msgstr "internt fel: %s med null vname"
+
+#: profile.c:943
#, c-format
msgid "\t# gawk profile, created %s\n"
msgstr "\t# gawkprofil, skapad %s\n"
-#: profile.c:1331
+#: profile.c:1328
#, c-format
msgid ""
"\n"
@@ -2055,17 +1971,17 @@ msgstr ""
"\n"
"\t# Funktioner, listade alfabetiskt\n"
-#: profile.c:1370
+#: profile.c:1366
#, c-format
msgid "redir2str: unknown redirection type %d"
msgstr "redir2str: okänd omdirigeringstyp %d"
-#: re.c:573
+#: re.c:571
#, c-format
msgid "range of the form `[%c-%c]' is locale dependent"
msgstr "intervall på formen \"[%c-%c]\" är lokalberoende"
-#: re.c:600
+#: re.c:598
#, c-format
msgid "regexp component `%.*s' should probably be `[%.*s]'"
msgstr ""
@@ -2143,5 +2059,77 @@ msgstr "Obalanserad ) eller \\)"
msgid "No previous regular expression"
msgstr "Inget föregående reguljärt uttryck"
+#~ msgid "attempt to use function `%s' as an array"
+#~ msgstr "försök att använda funktionen \"%s\" som vektor"
+
+#~ msgid "reference to uninitialized element `%s[\"%.*s\"]'"
+#~ msgstr "referens till oinitierat element \"%s[\"%.*s\"]\""
+
+#~ msgid "subscript of array `%s' is null string"
+#~ msgstr "index i vektorn \"%s\" är en tom sträng"
+
+#~ msgid "%s: empty (null)\n"
+#~ msgstr "%s: tom (null)\n"
+
+#~ msgid "%s: empty (zero)\n"
+#~ msgstr "%s: tom (noll)\n"
+
+#~ msgid "%s: table_size = %d, array_size = %d\n"
+#~ msgstr "%s: tabellstorlek = %d, vektorstorlek = %d\n"
+
+#~ msgid "%s: is parameter\n"
+#~ msgstr "%s: är en parameter\n"
+
+#~ msgid "%s: array_ref to %s\n"
+#~ msgstr "%s: vektorreferens till %s\n"
+
+#~ msgid "use of non-array as array"
+#~ msgstr "icke-vektor används som vektor"
+
+#~ msgid "can't use function name `%s' as variable or array"
+#~ msgstr "kan inte använda funktionsnamnet \"%s\" som variabel eller vektor"
+
+#~ msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
+#~ msgstr "försök att använda vektorn \"%s[\"%.*s\"]\" i skalärsammanhang"
+
+#~ msgid "assignment used in conditional context"
+#~ msgstr "tilldelning använt i jämförelsesammanhang"
+
+#~ msgid "statement has no effect"
+#~ msgstr "kommandot har ingen effekt"
+
+#~ msgid ""
+#~ "for loop: array `%s' changed size from %ld to %ld during loop execution"
+#~ msgstr ""
+#~ "forslinga: vektorn \"%s\" ändrade storlek från %ld till %ld under "
+#~ "slingexekvering"
+
+#~ msgid "function called indirectly through `%s' does not exist"
+#~ msgstr "funktionen anropad indirekt genom \"%s\" finns inte"
+
+#~ msgid "function `%s' not defined"
+#~ msgstr "funktionen \"%s\" är inte definierad"
+
+#~ msgid "non-redirected `getline' invalid inside `%s' rule"
+#~ msgstr "icke omdirigerad \"getline\" odefinierad inuti \"%s\"-regel"
+
+#~ msgid "error reading input file `%s': %s"
+#~ msgstr "fel vid läsning av indatafilen \"%s\": %s"
+
+#~ msgid "`nextfile' cannot be called from a `%s' rule"
+#~ msgstr "\"nextfile\" kan inte anropas från en \"%s\"-regel"
+
+#~ msgid "`exit' cannot be called in the current context"
+#~ msgstr "\"exit\" kan inte anropas i det aktuella sammanhanget"
+
+#~ msgid "`next' cannot be called from a `%s' rule"
+#~ msgstr "\"next\" kan inte anropas från en \"%s\"-regel"
+
+#~ msgid "Sorry, don't know how to interpret `%s'"
+#~ msgstr "Tyvärr, vet inte hur \"%s\" skall tolkas"
+
+#~ msgid "\t-R file\t\t\t--command=file\n"
+#~ msgstr "\t-R file\t\t\t--command=file\n"
+
#~ msgid "could not find groups: %s"
#~ msgstr "kunde inte hitta grupper: %s"
diff --git a/po/tr.gmo b/po/tr.gmo
deleted file mode 100644
index 146da41d..00000000
--- a/po/tr.gmo
+++ /dev/null
Binary files differ
diff --git a/po/vi.gmo b/po/vi.gmo
index 15712d6f..bf8cc497 100644
--- a/po/vi.gmo
+++ b/po/vi.gmo
Binary files differ
diff --git a/po/vi.po b/po/vi.po
index 686fe7d8..4cc35ef1 100644
--- a/po/vi.po
+++ b/po/vi.po
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: gawk-4.0.0h\n"
"Report-Msgid-Bugs-To: arnold@skeeve.com\n"
-"POT-Creation-Date: 2012-03-28 22:03+0200\n"
+"POT-Creation-Date: 2012-04-27 10:06+0300\n"
"PO-Revision-Date: 2012-04-04 08:01+0700\n"
"Last-Translator: Trần Ngá»c Quân <vnwildman@gmail.com>\n"
"Language-Team: Vietnamese <vi-VN@googlegroups.com>\n"
@@ -22,521 +22,478 @@ msgstr ""
"X-Poedit-Country: VIET NAM\n"
"X-Poedit-SourceCharset: utf-8\n"
-#: array.c:140
+#: array.c:266
#, c-format
msgid "from %s"
msgstr "từ %s"
-#: array.c:248
+#: array.c:366
msgid "attempt to use a scalar value as array"
msgstr "cố sử dụng giá trị vô hướng như là một mảng"
-#: array.c:251
-#, c-format
-msgid "attempt to use function `%s' as an array"
-msgstr "cố gắng dùng hàm « %s » như mảng"
-
-#: array.c:254
+#: array.c:368
#, c-format
msgid "attempt to use scalar parameter `%s' as an array"
msgstr "cố gắng dùng tham số vô hướng « %s » như là mảng"
-#: array.c:257
+#: array.c:371
#, c-format
msgid "attempt to use scalar `%s' as an array"
msgstr "cố dùng «%s» vô hướng như là mảng"
-#: array.c:302 array.c:707 builtin.c:84 builtin.c:1385 builtin.c:1427
-#: builtin.c:1440 builtin.c:1859 builtin.c:1871 eval.c:1135 eval.c:1139
-#: eval.c:1495 eval.c:1812
+#: array.c:418 array.c:584 builtin.c:85 builtin.c:1560 builtin.c:1602
+#: builtin.c:1615 builtin.c:2041 builtin.c:2053 eval.c:1109 eval.c:1113
+#: eval.c:1508
#, c-format
msgid "attempt to use array `%s' in a scalar context"
msgstr "cố gắng dùng mảng « %s » trong một ngữ cảnh vô hướng"
-#: array.c:513
-#, c-format
-msgid "reference to uninitialized element `%s[\"%.*s\"]'"
-msgstr "tham chiếu đến phần tử chưa sở khởi « %s[\"%.*s\"] »"
-
-#: array.c:519
-#, c-format
-msgid "subscript of array `%s' is null string"
-msgstr "chữ in dưới mảng « %s » là chuỗi rỗng"
-
-#: array.c:723
+#: array.c:591
#, c-format
msgid "delete: index `%s' not in array `%s'"
msgstr "delete: (xoá) số mũ « %s » không phải nằm trong mảng « %s »"
-#: array.c:734 eval.c:1865
+#: array.c:605
#, c-format
msgid "attempt to use scalar `%s[\"%.*s\"]' as an array"
msgstr "cố dùng «%s[\"%.*s\"]» vô hướng như là mảng"
-#: array.c:910
-#, c-format
-msgid "%s: empty (null)\n"
-msgstr "%s: rỗng (vô giá trị)\n"
-
-#: array.c:915
-#, c-format
-msgid "%s: empty (zero)\n"
-msgstr "%s: rỗng (số không)\n"
-
-#: array.c:919
-#, c-format
-msgid "%s: table_size = %d, array_size = %d\n"
-msgstr "%s: cỡ_bảng = %d, cỡ_mảng = %d\n"
-
-#: array.c:954
-#, c-format
-msgid "%s: is parameter\n"
-msgstr "%s: là tham số\n"
-
-#: array.c:958
-#, c-format
-msgid "%s: array_ref to %s\n"
-msgstr "%s: « array_ref » (mảng tham chiếu) đến « %s »\n"
-
-#: array.c:963
-msgid "adump: argument not an array"
+#: array.c:784
+#, fuzzy
+msgid "adump: first argument not an array"
msgstr "adump: đối số không phải là một mảng"
-#: array.c:1086
+#: array.c:823
msgid "asort: second argument not an array"
msgstr "asort: đối số thứ hai không phải là một mảng"
-#: array.c:1087
+#: array.c:824
msgid "asorti: second argument not an array"
msgstr "asorti: đối số thứ hai không phải là một mảng"
-#: array.c:1094
+#: array.c:831
msgid "asort: first argument not an array"
msgstr "asort: đối số thứ nhất không phải là một mảng"
-#: array.c:1095
+#: array.c:832
msgid "asorti: first argument not an array"
msgstr "asorti: đối số thứ nhất không phải là một mảng"
-#: array.c:1102
+#: array.c:839
msgid "asort: cannot use a subarray of first arg for second arg"
msgstr ""
"asort (một chương trính xắp xếp thứ tự): không thể sử dụng mảng con của tham "
"số thứ nhất cho tham số thứ hai"
-#: array.c:1103
+#: array.c:840
msgid "asorti: cannot use a subarray of first arg for second arg"
msgstr ""
"asorti (một chương trính xắp xếp thứ tự): không thể sử dụng mảng con của "
"tham số thứ nhất cho tham số thứ hai"
-#: array.c:1108
+#: array.c:845
msgid "asort: cannot use a subarray of second arg for first arg"
msgstr ""
"asort (một chương trính xắp xếp thứ tự): không thể sử dụng mảng con của tham "
"số thứ hai cho tham số thứ nhất"
-#: array.c:1109
+#: array.c:846
msgid "asorti: cannot use a subarray of second arg for first arg"
msgstr ""
"asorti (một chương trính xắp xếp thứ tự): không thể sử dụng mảng con của "
"tham số thứ hai cho tham số thứ nhất"
-#: array.c:1655
+#: array.c:1314
#, c-format
msgid "`%s' is invalid as a function name"
msgstr "`%s' không phải là tên hàm hợp lệ"
-#: array.c:1659
+#: array.c:1318
#, c-format
msgid "sort comparison function `%s' is not defined"
msgstr "chưa định nghĩa hàm so sánh xắp xếp « %s »"
-#: awkgram.y:249
+#: awkgram.y:223
#, c-format
msgid "%s blocks must have an action part"
msgstr "Má»i khối %s phải có má»™t phần kiểu hành động"
-#: awkgram.y:252
+#: awkgram.y:226
msgid "each rule must have a pattern or an action part"
msgstr "Má»i quy tắc phải có má»™t mẫu hay phần kiểu hành động"
-#: awkgram.y:323 awkgram.y:334
+#: awkgram.y:295 awkgram.y:306
msgid "old awk does not support multiple `BEGIN' or `END' rules"
msgstr ""
"awk cÅ© không há»— trợ nhiá»u quy tắc kiểu « BEGIN » (bắt đầu) hay « END » (kết "
"thúc)"
-#: awkgram.y:371
+#: awkgram.y:343
#, c-format
msgid "`%s' is a built-in function, it cannot be redefined"
msgstr "« %s » là một hàm có sẵn nên nó không thể được định nghĩa lái."
-#: awkgram.y:432
+#: awkgram.y:389
msgid "regexp constant `//' looks like a C++ comment, but is not"
msgstr ""
"hằng biểu thức chính quy « // » hình như một chú thích C, nhưng mà không phải"
-#: awkgram.y:436
+#: awkgram.y:393
#, c-format
msgid "regexp constant `/%s/' looks like a C comment, but is not"
msgstr ""
"hằng biểu thức chính quy « /%s/ » hình như một chú thích C, nhưng mà không "
"phải"
-#: awkgram.y:528
+#: awkgram.y:485
#, c-format
msgid "duplicate case values in switch body: %s"
msgstr "gặp giá trị case trùng trong thân chuyển đổi (switch body): %s"
-#: awkgram.y:549
+#: awkgram.y:506
msgid "duplicate `default' detected in switch body"
msgstr ""
"đã phát hiện trùng `default' trong thân cấu trúc Ä‘iá»u khiển chá»n lá»±a (switch)"
-#: awkgram.y:809
+#: awkgram.y:766
msgid "`break' is not allowed outside a loop or switch"
msgstr ""
"không cho phép « break » (ngắt) nằm ở ngoại vòng lặp hay cấu trúc chá»n lá»±a"
-#: awkgram.y:818
+#: awkgram.y:775
msgid "`continue' is not allowed outside a loop"
msgstr "không cho phép «continue» (tiếp tục) ở ngoài một vòng lặp"
-#: awkgram.y:828
+#: awkgram.y:785
#, c-format
msgid "`next' used in %s action"
msgstr "« next » (kế tiếp) được dùng trong hành động %s"
-#: awkgram.y:836
+#: awkgram.y:793
msgid "`nextfile' is a gawk extension"
msgstr "« nextfile » (tập tin kế tiếp) là một phần mở rộng gawk"
-#: awkgram.y:841
+#: awkgram.y:798
#, c-format
msgid "`nextfile' used in %s action"
msgstr "« nextfile » (tệp tin kế tiếp) được dùng trong hành động %s"
-#: awkgram.y:865
+#: awkgram.y:822
msgid "`return' used outside function context"
msgstr "« return » (trở vá») được dùng ở ngoại ngữ cảnh hàm"
-#: awkgram.y:925
+#: awkgram.y:896
msgid "plain `print' in BEGIN or END rule should probably be `print \"\"'"
msgstr ""
"« print » (in) thưá»ng trong quy tắc « BEGIN » (bắt đầu) hay « END » (kết "
"thúc) hầu như chắc chắn nên là « print\"\" »"
-#: awkgram.y:995 awkgram.y:999 awkgram.y:1023
+#: awkgram.y:966 awkgram.y:970 awkgram.y:994
msgid "`delete array' is a gawk extension"
msgstr "« delete array » (xoá mảng) là một phần mở rộng gawk"
-#: awkgram.y:1019
+#: awkgram.y:990
msgid "`delete(array)' is a non-portable tawk extension"
msgstr "« delete array » (xoá mảng) là phần mở rộng gawk không khả chuyển"
-#: awkgram.y:1135
+#: awkgram.y:1108
msgid "multistage two-way pipelines don't work"
msgstr "đưá»ng ống dẫn hai chiếu Ä‘a giai Ä‘oạn không phải hoạt động được"
-#: awkgram.y:1238
+#: awkgram.y:1211
msgid "regular expression on right of assignment"
msgstr "biểu thức chính quy nằm bên phải Ä‘iá»u gán"
-#: awkgram.y:1249
+#: awkgram.y:1222
msgid "regular expression on left of `~' or `!~' operator"
msgstr "biểu thức chính quy nằm bên trái toán tử « ~ » hay « !~ »"
-#: awkgram.y:1265 awkgram.y:1419
+#: awkgram.y:1238 awkgram.y:1389
msgid "old awk does not support the keyword `in' except after `for'"
msgstr "awk cũ không hỗ trợ từ khoá « in », trừ khi nằm sau « for »"
-#: awkgram.y:1275
+#: awkgram.y:1248
msgid "regular expression on right of comparison"
msgstr "biểu thức chính quy nằm bên phải sự so sánh"
-#: awkgram.y:1394
+#: awkgram.y:1364
#, c-format
msgid "`getline var' invalid inside `%s' rule"
msgstr "`getline var' không hợp lệ bên trong quy tắc `%s'"
-#: awkgram.y:1397 eval.c:2504
+#: awkgram.y:1367
#, c-format
msgid "`getline' invalid inside `%s' rule"
msgstr "`getline' không hợp lệ trong quy tắc `%s'"
-#: awkgram.y:1402
+#: awkgram.y:1372
msgid "non-redirected `getline' undefined inside END action"
msgstr ""
"trong hành động « END » (kết thúc) có « getline » (lấy dòng) không được "
"chuyển hướng lại và chưa được xác định."
-#: awkgram.y:1421
+#: awkgram.y:1391
msgid "old awk does not support multidimensional arrays"
msgstr "awk cÅ© không há»— trợ mảng Ä‘a chiá»u"
-#: awkgram.y:1517
+#: awkgram.y:1488
msgid "call of `length' without parentheses is not portable"
msgstr "không thể mang lá»i gá»i « length » (độ dài) không có dấu ngoặc"
-#: awkgram.y:1580
+#: awkgram.y:1554
msgid "indirect function calls are a gawk extension"
msgstr "cuá»™c gá»i hàm gián tiếp là má»™t phần mở rá»™ng gawk"
-#: awkgram.y:1593
+#: awkgram.y:1567
#, c-format
msgid "can not use special variable `%s' for indirect function call"
msgstr "không thể dùng biến đặc biệt « %s » cho cú gá»i hàm gián tiếp"
-#: awkgram.y:1671
+#: awkgram.y:1645
msgid "invalid subscript expression"
msgstr "biểu thức in thấp không hợp lệ"
-#: awkgram.y:1711
-msgid "use of non-array as array"
-msgstr "việc dùng cái khác mảng như là mảng"
-
-#: awkgram.y:1975 awkgram.y:1995 msg.c:98
+#: awkgram.y:1966 awkgram.y:1986 msg.c:112
msgid "warning: "
msgstr "cảnh báo : "
-#: awkgram.y:1993 msg.c:130
+#: awkgram.y:1984 msg.c:144
msgid "fatal: "
msgstr "nghiêm trá»ng: "
-#: awkgram.y:2043
+#: awkgram.y:2034
msgid "unexpected newline or end of string"
msgstr "gặp dòng mới bất ngỠhay kết thúc của chuỗi"
-#: awkgram.y:2300 awkgram.y:2358 awkgram.y:2542
+#: awkgram.y:2299 awkgram.y:2357 awkgram.y:2545
#, c-format
msgid "can't open source file `%s' for reading (%s)"
msgstr "không thể mở tập tin nguồn « %s » để Ä‘á»c (%s)"
-#: awkgram.y:2301 awkgram.y:2359 builtin.c:122
+#: awkgram.y:2300 awkgram.y:2358 builtin.c:124
msgid "reason unknown"
msgstr "không biết sao"
-#: awkgram.y:2317
+#: awkgram.y:2316
#, c-format
msgid "already included source file `%s'"
msgstr "đã sẵn bao gồm tập tin nguồn `%s'"
-#: awkgram.y:2343
+#: awkgram.y:2342
msgid "@include is a gawk extension"
msgstr "@include là phần mở rộng của gawk"
-#: awkgram.y:2349
+#: awkgram.y:2348
msgid "empty filename after @include"
msgstr "tệp tin rống sau @include"
-#: awkgram.y:2494
+#: awkgram.y:2497
msgid "empty program text on command line"
msgstr "gặp đoạn chữ chương trình rỗng nằm trên dòng lệnh"
-#: awkgram.y:2609
+#: awkgram.y:2612
#, c-format
msgid "can't read sourcefile `%s' (%s)"
msgstr "không thể Ä‘á»c tập tin nguồn « %s » (%s)"
-#: awkgram.y:2620
+#: awkgram.y:2623
#, c-format
msgid "source file `%s' is empty"
msgstr "tập tin nguồn « %s » là rỗng"
-#: awkgram.y:2797
+#: awkgram.y:2800
msgid "source file does not end in newline"
msgstr "tập tin nguồn không kết thúc với một dòng mới"
-#: awkgram.y:2900
+#: awkgram.y:2905
msgid "unterminated regexp ends with `\\' at end of file"
msgstr ""
"biểu thức chính quy chưa được chấm dứt kết thúc với « \\ » tại kết thúc của "
"tập tin"
-#: awkgram.y:2924
+#: awkgram.y:2929
#, c-format
msgid "%s: %d: tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr ""
"%s: %d: bộ sửa đổi biểu thức chính quy tawk « /.../%c » không hoạt động được "
"trong gawk"
-#: awkgram.y:2928
+#: awkgram.y:2933
#, c-format
msgid "tawk regex modifier `/.../%c' doesn't work in gawk"
msgstr ""
"bộ sửa đổi biểu thức chính quy tawk « /.../%c » không hoạt động được trong "
"gawk"
-#: awkgram.y:2935
+#: awkgram.y:2940
msgid "unterminated regexp"
msgstr "biểu thức chính quy chưa được chấm dứt"
-#: awkgram.y:2939
+#: awkgram.y:2944
msgid "unterminated regexp at end of file"
msgstr "biểu thức chính quy chưa được chấm dứt nằm tại kết thúc của tập tin"
-#: awkgram.y:2998
+#: awkgram.y:3003
msgid "use of `\\ #...' line continuation is not portable"
msgstr "không thể mang khả năng dùng « \\#... » để tiếp tục dòng"
-#: awkgram.y:3014
+#: awkgram.y:3019
msgid "backslash not last character on line"
msgstr "xuyệc ngược không phải là ký tự cuối cùng nằm trên dòng"
-#: awkgram.y:3075
+#: awkgram.y:3080
msgid "POSIX does not allow operator `**='"
msgstr "POSIX không cho phép toán tử « **= »"
-#: awkgram.y:3077
+#: awkgram.y:3082
msgid "old awk does not support operator `**='"
msgstr "awk cũ không hỗ trợ toán tử « **= »"
-#: awkgram.y:3086
+#: awkgram.y:3091
msgid "POSIX does not allow operator `**'"
msgstr "POSIX không cho phép toán tử « ** »"
-#: awkgram.y:3088
+#: awkgram.y:3093
msgid "old awk does not support operator `**'"
msgstr "awk cũ không hỗ trợ toán tử « ** »"
-#: awkgram.y:3123
+#: awkgram.y:3128
msgid "operator `^=' is not supported in old awk"
msgstr "awk cũ không hỗ trợ toán tử « ^= »"
-#: awkgram.y:3131
+#: awkgram.y:3136
msgid "operator `^' is not supported in old awk"
msgstr "awk cũ không hỗ trợ toán tử « ^ »"
-#: awkgram.y:3224 awkgram.y:3240
+#: awkgram.y:3229 awkgram.y:3245
msgid "unterminated string"
msgstr "chuỗi không được chấm dứt"
-#: awkgram.y:3436
+#: awkgram.y:3466
#, c-format
msgid "invalid char '%c' in expression"
msgstr "biểu thức một ký tự không hợp lệ « %c » nằm trong biểu thức"
-#: awkgram.y:3483
+#: awkgram.y:3513
#, c-format
msgid "`%s' is a gawk extension"
msgstr "« %s » là một phần mở rộng gawk"
-#: awkgram.y:3488
+#: awkgram.y:3518
#, c-format
msgid "`%s' is a Bell Labs extension"
msgstr "« %s » là một phần mở rộng của Bell Labs (Phòng thí nghiệm Bell)"
-#: awkgram.y:3493
+#: awkgram.y:3523
#, c-format
msgid "POSIX does not allow `%s'"
msgstr "POSIX không cho phép « %s »"
-#: awkgram.y:3501
+#: awkgram.y:3531
#, c-format
msgid "`%s' is not supported in old awk"
msgstr "awk kiểu cũ không hỗ trợ « %s »"
-#: awkgram.y:3568
+#: awkgram.y:3598
msgid "`goto' considered harmful!\n"
msgstr "« goto » được xem là gây tai hại!\n"
-#: awkgram.y:3619
+#: awkgram.y:3632
#, c-format
msgid "%d is invalid as number of arguments for %s"
msgstr "« %d » không hợp lệ khi là số đối số cho « %s »"
-#: awkgram.y:3654
+#: awkgram.y:3667
#, c-format
msgid "%s: string literal as last arg of substitute has no effect"
msgstr ""
"%s: khi đối số cuối cùng của sự thay thế, hằng mã nguồn chuỗi không có tác "
"dụng"
-#: awkgram.y:3659
+#: awkgram.y:3672
#, c-format
msgid "%s third parameter is not a changeable object"
msgstr "tham số thứ ba %s không phải là một đối tượng có thể thay đổi"
-#: awkgram.y:3732 awkgram.y:3735
+#: awkgram.y:3751 awkgram.y:3754
msgid "match: third argument is a gawk extension"
msgstr "match: (khớp) đối số thứ ba là phần mở rộng gawk"
-#: awkgram.y:3789 awkgram.y:3792
+#: awkgram.y:3808 awkgram.y:3811
msgid "close: second argument is a gawk extension"
msgstr "close: (đóng) đối số thứ hai là phần mở rộng gawk"
-#: awkgram.y:3804
+#: awkgram.y:3823
msgid "use of dcgettext(_\"...\") is incorrect: remove leading underscore"
msgstr "dùng « dcgettext(_\"...\") » không đúng: hãy gỡ bỠgạch dưới nằm trước"
-#: awkgram.y:3819
+#: awkgram.y:3838
msgid "use of dcngettext(_\"...\") is incorrect: remove leading underscore"
msgstr "dùng « dcgettext(_\"...\") » không đúng: hãy gỡ bỠgạch dưới nằm trước"
-#: awkgram.y:3911
-#, c-format
-msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
-msgstr "hàm « %s »: tham số « #%d », « %s », nhân đôi tham số « #%d »"
-
-#: awkgram.y:3953
+#: awkgram.y:3904
#, c-format
msgid "function `%s': parameter `%s' shadows global variable"
msgstr "hàm « %s »: tham số « %s » che biến toàn cục"
-#: awkgram.y:4111
+#: awkgram.y:3961
#, c-format
msgid "could not open `%s' for writing (%s)"
msgstr "không mở được « %s » để ghi (%s)"
-#: awkgram.y:4112
+#: awkgram.y:3962
msgid "sending variable list to standard error"
msgstr "đang gởi danh sách biến tới thiết bị lỗi chuẩn"
-#: awkgram.y:4118
+#: awkgram.y:3970
#, c-format
msgid "%s: close failed (%s)"
msgstr "%s: lỗi đóng (%s)"
-#: awkgram.y:4170
+#: awkgram.y:3995
msgid "shadow_funcs() called twice!"
msgstr "shadow_funcs() (hàm bóng) được gá»i hai lần !"
-#: awkgram.y:4176
+#: awkgram.y:4003
msgid "there were shadowed variables."
msgstr "có biến bị bóng."
-#: awkgram.y:4206
+#: awkgram.y:4074
+#, c-format
+msgid "function name `%s' previously defined"
+msgstr "tên hàm « %s » trước đây đã được định nghĩa rồi"
+
+#: awkgram.y:4120
#, c-format
msgid "function `%s': can't use function name as parameter name"
msgstr "hàm « %s »: không thể dùng tên hàm như là tên tham số"
-#: awkgram.y:4210
+#: awkgram.y:4123
#, c-format
msgid "function `%s': can't use special variable `%s' as a function parameter"
msgstr "hàm « %s »: không thể dùng biến đặc biệt « %s » như là tham số hàm"
-#: awkgram.y:4226
+#: awkgram.y:4131
#, c-format
-msgid "function name `%s' previously defined"
-msgstr "tên hàm « %s » trước đây đã được định nghĩa rồi"
+msgid "function `%s': parameter #%d, `%s', duplicates parameter #%d"
+msgstr "hàm « %s »: tham số « #%d », « %s », nhân đôi tham số « #%d »"
-#: awkgram.y:4394 awkgram.y:4400
+#: awkgram.y:4210 awkgram.y:4216
#, c-format
msgid "function `%s' called but never defined"
msgstr "hàm « %s » được gá»i nhưng mà chưa xác định"
-#: awkgram.y:4403
+#: awkgram.y:4219
#, c-format
msgid "function `%s' defined but never called directly"
msgstr "hàm « %s » được định nghÄ©a nhưng mà chưa được gá»i trá»±c tiếp bao giá»"
-#: awkgram.y:4435
+#: awkgram.y:4251
#, c-format
msgid "regexp constant for parameter #%d yields boolean value"
msgstr "hằng biểu thức chính quy cho tham số « #%d » làm giá trị luận lý (bun)"
-#: awkgram.y:4544
+#: awkgram.y:4297
#, c-format
msgid ""
"function `%s' called with space between name and `(',\n"
@@ -545,232 +502,232 @@ msgstr ""
"hàm « %s » được gá»i vá»›i dấu cách nằm giữa tên và « ( »\n"
"hoặc được dùng như là biến hay mảng"
-#: awkgram.y:4791 eval.c:2056
+#: awkgram.y:4505
msgid "division by zero attempted"
msgstr "cố gắng chia cho số không"
-#: awkgram.y:4800 eval.c:2072
+#: awkgram.y:4514
#, c-format
msgid "division by zero attempted in `%%'"
msgstr "thử chia cho không trong « %% »"
-#: builtin.c:120
+#: builtin.c:122
#, c-format
msgid "%s to \"%s\" failed (%s)"
msgstr "%s tới « %s » bị lỗi (%s)"
-#: builtin.c:121
+#: builtin.c:123
msgid "standard output"
msgstr "thiết bị xuất chuẩn"
-#: builtin.c:135
+#: builtin.c:137
msgid "exp: received non-numeric argument"
msgstr "exp: đã nhận đối số không phải thuộc số"
-#: builtin.c:141
+#: builtin.c:143
#, c-format
msgid "exp: argument %g is out of range"
msgstr "exp: đối số « %g » ở ngoại phạm vị"
-#: builtin.c:200
+#: builtin.c:202
#, c-format
msgid "fflush: cannot flush: pipe `%s' opened for reading, not writing"
msgstr ""
"fflush: không thể xoá sạch: ống dẫn « %s » được mở để Ä‘á»c, không phải để ghi"
-#: builtin.c:203
+#: builtin.c:205
#, c-format
msgid "fflush: cannot flush: file `%s' opened for reading, not writing"
msgstr ""
"fflush: không thể xoá sạch: tập tin « %s » được mở để Ä‘á»c, không phải để ghi"
-#: builtin.c:215
+#: builtin.c:217
#, c-format
msgid "fflush: `%s' is not an open file, pipe or co-process"
msgstr ""
"fflush: « %s » không phải là tập tin đã mở, ống dẫn hay đồng tiến trình"
-#: builtin.c:333
+#: builtin.c:335
msgid "index: received non-string first argument"
msgstr "index: (chỉ mục) đã nhận đối số thứ nhất không phải là chuỗi"
-#: builtin.c:335
+#: builtin.c:337
msgid "index: received non-string second argument"
msgstr "index: (chỉ mục) đã nhận đối số thứ hai không phải là chuỗi"
-#: builtin.c:457
+#: builtin.c:461
msgid "int: received non-numeric argument"
msgstr "int: (số nguyên?) đã nhận đối số không phải thuộc số"
-#: builtin.c:493
+#: builtin.c:497
msgid "length: received array argument"
msgstr "length: (chiá»u dài) đã nhận mảng đối số"
-#: builtin.c:496
+#: builtin.c:500
msgid "`length(array)' is a gawk extension"
msgstr "« length(array) » (độ dài mảng) là một phần mở rộng gawk"
-#: builtin.c:504
+#: builtin.c:508
msgid "length: received non-string argument"
msgstr "length: (chiá»u dài) đã nhận đối số không phải chuá»—i"
-#: builtin.c:535
+#: builtin.c:539
msgid "log: received non-numeric argument"
msgstr "log: (bản ghi) đã nhận đối số không phải thuộc số"
-#: builtin.c:538
+#: builtin.c:542
#, c-format
msgid "log: received negative argument %g"
msgstr "log: (bản ghi) đã nhận đối số âm « %g »"
-#: builtin.c:694 builtin.c:699
+#: builtin.c:740 builtin.c:745
msgid "fatal: must use `count$' on all formats or none"
msgstr "nghiêm trá»ng: phải dùng « count$ » vá»›i má»i dạng thức hay không gì cả"
-#: builtin.c:762
+#: builtin.c:815
#, c-format
msgid "field width is ignored for `%%' specifier"
msgstr "chiá»u rá»™ng trưá»ng bị bá» qua đối vá»›i bá»™ chỉ định `%%'"
-#: builtin.c:764
+#: builtin.c:817
#, c-format
msgid "precision is ignored for `%%' specifier"
msgstr "độ chính xác bị bỠqua đối với bộ chỉ định `%%'"
-#: builtin.c:766
+#: builtin.c:819
#, c-format
msgid "field width and precision are ignored for `%%' specifier"
msgstr "chiá»u rá»™ng trưá»ng và độ chính xác bị bá» qua đối vá»›i bá»™ chỉ định `%%'"
-#: builtin.c:817
+#: builtin.c:870
msgid "fatal: `$' is not permitted in awk formats"
msgstr "nghiêm trá»ng: không cho phép `$' trong định dạng awk"
-#: builtin.c:826
+#: builtin.c:879
msgid "fatal: arg count with `$' must be > 0"
msgstr "nghiêm trá»ng: số lượng đối số vá»›i « $ » phải >0"
-#: builtin.c:830
+#: builtin.c:883
#, c-format
msgid "fatal: arg count %ld greater than total number of supplied arguments"
msgstr "nghiêm trá»ng: số lượng đối số %ld lá»›n hÆ¡n tổng số đối số được cung cấp"
-#: builtin.c:834
+#: builtin.c:887
msgid "fatal: `$' not permitted after period in format"
msgstr "nghiêm trá»ng: không cho phép « $ » nằm sau dấu chấm trong định dạng"
-#: builtin.c:850
+#: builtin.c:903
msgid "fatal: no `$' supplied for positional field width or precision"
msgstr ""
"nghiêm trá»ng: chưa cung cấp « $ » cho độ rá»™ng trưá»ng thuá»™c vị trí hay cho độ "
"chính xác"
-#: builtin.c:921
+#: builtin.c:975
msgid "`l' is meaningless in awk formats; ignored"
msgstr "chữ « l » không có nghĩa trong định dạng awk nên bị bỠqua"
-#: builtin.c:925
+#: builtin.c:979
msgid "fatal: `l' is not permitted in POSIX awk formats"
msgstr "nghiêm trá»ng: không cho phép chữ « l » nằm trong định dạng awk POSIX"
-#: builtin.c:938
+#: builtin.c:992
msgid "`L' is meaningless in awk formats; ignored"
msgstr "chữ « L » không có nghĩa trong định dạng awk nên bị bỠqua"
-#: builtin.c:942
+#: builtin.c:996
msgid "fatal: `L' is not permitted in POSIX awk formats"
msgstr "nghiêm trá»ng: không cho phép chữ « L » nằm trong định dạng awk POSIX"
-#: builtin.c:955
+#: builtin.c:1009
msgid "`h' is meaningless in awk formats; ignored"
msgstr "chữ « h » không có nghĩa trong định dạng awk nên bị bỠqua"
-#: builtin.c:959
+#: builtin.c:1013
msgid "fatal: `h' is not permitted in POSIX awk formats"
msgstr "nghiêm trá»ng: không cho phép chữ « h » nằm trong định dạng awk POSIX"
-#: builtin.c:1272
+#: builtin.c:1408
#, c-format
msgid "[s]printf: value %g is out of range for `%%%c' format"
msgstr "[s]printf: giá trị %g ở ngoại phạm vị cho dạng thức « %%%c »"
-#: builtin.c:1332
+#: builtin.c:1506
#, c-format
msgid "ignoring unknown format specifier character `%c': no argument converted"
msgstr ""
"đang bỠqua ký tự ghi rõ định dạng không rõ « %c »: không có đối số được "
"chuyển đổi"
-#: builtin.c:1337
+#: builtin.c:1511
msgid "fatal: not enough arguments to satisfy format string"
msgstr "nghiêm trá»ng: chưa có đủ đối số để đáp ứng chuá»—i định dạng"
-#: builtin.c:1339
+#: builtin.c:1513
msgid "^ ran out for this one"
msgstr "bị hết « ^ » cho Ä‘iá»u này"
-#: builtin.c:1346
+#: builtin.c:1520
msgid "[s]printf: format specifier does not have control letter"
msgstr "[s]printf: Ä‘iá»u ghi rõ định dạng không có chữ Ä‘iá»u khiển"
-#: builtin.c:1349
+#: builtin.c:1523
msgid "too many arguments supplied for format string"
msgstr "quá nhiá»u đối số được cung cấp cho chuá»—i định dạng"
-#: builtin.c:1423 builtin.c:1434
+#: builtin.c:1598 builtin.c:1609
msgid "printf: no arguments"
msgstr "printf: không có đối số"
-#: builtin.c:1475
+#: builtin.c:1650
msgid "sqrt: received non-numeric argument"
msgstr "sqrt: (căn bậc hai) đã nhận đối số không phải thuộc số"
-#: builtin.c:1479
+#: builtin.c:1654
#, c-format
msgid "sqrt: called with negative argument %g"
msgstr "sqrt: (căn bậc hai) đã gá»i vá»›i đối số âm « %g »"
-#: builtin.c:1503
+#: builtin.c:1685
#, c-format
msgid "substr: length %g is not >= 1"
msgstr "substr: (chuỗi phụ) độ dài %g không phải ≥1"
-#: builtin.c:1505
+#: builtin.c:1687
#, c-format
msgid "substr: length %g is not >= 0"
msgstr "substr: (chuỗi phụ) độ dài %g không phải ≥0"
-#: builtin.c:1512
+#: builtin.c:1694
#, c-format
msgid "substr: non-integer length %g will be truncated"
msgstr "substr: (chuỗi phụ) sẽ cắt xén độ dài không phải số nguyên « %g »"
-#: builtin.c:1517
+#: builtin.c:1699
#, c-format
msgid "substr: length %g too big for string indexing, truncating to %g"
msgstr "substr: độ dài %g quá lớn để chỉ mục chuỗi nên xén ngắn thành %g"
-#: builtin.c:1529
+#: builtin.c:1711
#, c-format
msgid "substr: start index %g is invalid, using 1"
msgstr "substr: (chuỗi phụ) số chỉ mục đầu « %g » không hợp lệ nên dùng 1"
-#: builtin.c:1534
+#: builtin.c:1716
#, c-format
msgid "substr: non-integer start index %g will be truncated"
msgstr ""
"substr: (chuỗi phụ) số chỉ mục đầu không phải số nguyên « %g » sẽ bị cắt ngắn"
-#: builtin.c:1559
+#: builtin.c:1741
msgid "substr: source string is zero length"
msgstr "substr: (chuỗi con) chuỗi nguồn có độ dài số không"
-#: builtin.c:1575
+#: builtin.c:1757
#, c-format
msgid "substr: start index %g is past end of string"
msgstr "substr: (chuỗi phụ) số chỉ mục đầu %g nằm sau kết thúc của chuỗi"
-#: builtin.c:1583
+#: builtin.c:1765
#, c-format
msgid ""
"substr: length %g at start index %g exceeds length of first argument (%lu)"
@@ -778,228 +735,223 @@ msgstr ""
"substr: (chuỗi phụ) độ dài %g tại số chỉ mục đầu %g vượt quá độ dài của đối "
"số đầu (%lu)"
-#: builtin.c:1657
+#: builtin.c:1839
msgid "strftime: format value in PROCINFO[\"strftime\"] has numeric type"
msgstr ""
"strftime: giá trị định dạng trong PROCINFO[\"strftime\"] phải thuộc kiểu số"
-#: builtin.c:1680
+#: builtin.c:1862
msgid "strftime: received non-numeric second argument"
msgstr "strftime: đã nhận đối số thứ hai khác thuộc số"
-#: builtin.c:1683
+#: builtin.c:1866
msgid "strftime: second argument less than 0 or too big for time_t"
msgstr "strftime: tham số thứ hai nhỠhơn 0 hay quá lớn dành cho time_t"
-#: builtin.c:1690
+#: builtin.c:1873
msgid "strftime: received non-string first argument"
msgstr "strftime: đã nhận đối số thứ nhất khác chuỗi"
-#: builtin.c:1696
+#: builtin.c:1880
msgid "strftime: received empty format string"
msgstr "strftime: đã nhận chuỗi định dạng rỗng"
-#: builtin.c:1762
+#: builtin.c:1946
msgid "mktime: received non-string argument"
msgstr "mktime: đã nhận đối số khác chuỗi"
-#: builtin.c:1779
+#: builtin.c:1963
msgid "mktime: at least one of the values is out of the default range"
msgstr "mktime: ít nhất một của những giá trị nằm ở ngoại phạm vi mặc định"
-#: builtin.c:1814
+#: builtin.c:1998
msgid "'system' function not allowed in sandbox mode"
msgstr "hàm 'system' không cho phép ở chế độ khuôn đúc"
-#: builtin.c:1819
+#: builtin.c:2003
msgid "system: received non-string argument"
msgstr "system: (hệ thống) đã nhận đối số khác chuỗi"
-#: builtin.c:1874 eval.c:1159 eval.c:1790 eval.c:1803
-#, c-format
-msgid "reference to uninitialized variable `%s'"
-msgstr "gặp tham chiếu đến biến chưa được sở khởi « %s »"
-
-#: builtin.c:1941
+#: builtin.c:2121
#, c-format
msgid "reference to uninitialized field `$%d'"
msgstr "gặp tham chiếu đến trưá»ng chưa được sở khởi « $%d »"
-#: builtin.c:2028
+#: builtin.c:2208
msgid "tolower: received non-string argument"
msgstr "tolower: (đến thấp hơn) đã nhận đối số khác chuỗi"
-#: builtin.c:2062
+#: builtin.c:2242
msgid "toupper: received non-string argument"
msgstr "toupper: (đến cao hơn) đã nhận đối số khác chuỗi"
-#: builtin.c:2098
+#: builtin.c:2278
msgid "atan2: received non-numeric first argument"
msgstr "atan2: đã nhận đối số thứ nhất khác thuộc số"
-#: builtin.c:2100
+#: builtin.c:2280
msgid "atan2: received non-numeric second argument"
msgstr "atan2: đã nhận đối số thứ hai khác thuộc số"
-#: builtin.c:2119
+#: builtin.c:2299
msgid "sin: received non-numeric argument"
msgstr "sin: đã nhận đối số không phải thuộc số"
-#: builtin.c:2135
+#: builtin.c:2315
msgid "cos: received non-numeric argument"
msgstr "cos: đã nhận đối số không phải thuộc số"
-#: builtin.c:2188
+#: builtin.c:2368
msgid "srand: received non-numeric argument"
msgstr "srand: đã nhận đối số không phải thuộc số"
-#: builtin.c:2219
+#: builtin.c:2399
msgid "match: third argument is not an array"
msgstr "match: (khớp) đối số thứ ba không phải là mảng"
-#: builtin.c:2483
+#: builtin.c:2664
msgid "gensub: third argument of 0 treated as 1"
msgstr "gensub: đối số thứ ba 0 được xử lý như 1"
-#: builtin.c:2776
+#: builtin.c:2957
msgid "lshift: received non-numeric first argument"
msgstr "lshift: đã nhận đối số đầu không phải thuộc số"
-#: builtin.c:2778
+#: builtin.c:2959
msgid "lshift: received non-numeric second argument"
msgstr "lshift: (dịch bên trái) đã nhận đối số thứ hai khác thuộc số"
-#: builtin.c:2784
+#: builtin.c:2965
#, c-format
msgid "lshift(%lf, %lf): negative values will give strange results"
msgstr "lshift(%lf, %lf): giá trị âm sẽ gây ra kết quả lạ"
-#: builtin.c:2786
+#: builtin.c:2967
#, c-format
msgid "lshift(%lf, %lf): fractional values will be truncated"
msgstr "lshift(%lf, %lf): giá trị thuộc phân số sẽ bị xén ngắn"
-#: builtin.c:2788
+#: builtin.c:2969
#, c-format
msgid "lshift(%lf, %lf): too large shift value will give strange results"
msgstr "lshift(%lf, %lf): giá trị dịch quá lớn sẽ gây ra kết quả lạ"
-#: builtin.c:2813
+#: builtin.c:2994
msgid "rshift: received non-numeric first argument"
msgstr "rshift: đã nhận đối số thứ nhất khác thuộc số"
-#: builtin.c:2815
+#: builtin.c:2996
msgid "rshift: received non-numeric second argument"
msgstr "rshift: (dịch bên phải) đã nhận đối số thứ hai khác thuộc số"
-#: builtin.c:2821
+#: builtin.c:3002
#, c-format
msgid "rshift(%lf, %lf): negative values will give strange results"
msgstr "rshift(%lf, %lf): giá trị âm sẽ gây ra kết quả lạ"
-#: builtin.c:2823
+#: builtin.c:3004
#, c-format
msgid "rshift(%lf, %lf): fractional values will be truncated"
msgstr "rshift(%lf, %lf): giá trị thuộc phân số sẽ bị xén ngắn"
-#: builtin.c:2825
+#: builtin.c:3006
#, c-format
msgid "rshift(%lf, %lf): too large shift value will give strange results"
msgstr "rshift(%lf, %lf): giá trị dịch quá lớn sẽ gây ra kết quả lạ"
-#: builtin.c:2850
+#: builtin.c:3031
msgid "and: received non-numeric first argument"
msgstr "and: (và) đã nhận đối số đầu không phải thuộc số"
-#: builtin.c:2852
+#: builtin.c:3033
msgid "and: received non-numeric second argument"
msgstr "and: (và) đã nhận đối số thứ hai khác thuộc số"
-#: builtin.c:2858
+#: builtin.c:3039
#, c-format
msgid "and(%lf, %lf): negative values will give strange results"
msgstr "and(%lf, %lf): (và) giá trị âm sẽ gây ra kết quả lạ"
-#: builtin.c:2860
+#: builtin.c:3041
#, c-format
msgid "and(%lf, %lf): fractional values will be truncated"
msgstr "and(%lf, %lf): (và) giá trị thuộc phân số sẽ bị xén ngắn"
-#: builtin.c:2885
+#: builtin.c:3066
msgid "or: received non-numeric first argument"
msgstr "or: (hoặc) đã nhận đối số đầu không phải thuộc số"
-#: builtin.c:2887
+#: builtin.c:3068
msgid "or: received non-numeric second argument"
msgstr "or: (hoặc) đã nhận đối số thứ hai khác thuộc số"
-#: builtin.c:2893
+#: builtin.c:3074
#, c-format
msgid "or(%lf, %lf): negative values will give strange results"
msgstr "or(%lf, %lf): (hoặc) giá trị âm sẽ gây ra kết quả lạ"
-#: builtin.c:2895
+#: builtin.c:3076
#, c-format
msgid "or(%lf, %lf): fractional values will be truncated"
msgstr "or(%lf, %lf): (hoặc) giá trị thuộc phân số sẽ bị xén ngắn"
-#: builtin.c:2923
+#: builtin.c:3102
msgid "xor: received non-numeric first argument"
msgstr "xor: (không hoặc) đã nhận đối số thứ nhất khác thuộc số"
-#: builtin.c:2925
+#: builtin.c:3104
msgid "xor: received non-numeric second argument"
msgstr "xor: đã nhận đối số thứ hai khác thuộc số"
-#: builtin.c:2931
+#: builtin.c:3110
#, c-format
msgid "xor(%lf, %lf): negative values will give strange results"
msgstr "xor(%lf, %lf): (không hoặc) giá trị âm sẽ gây ra kết quả lạ"
-#: builtin.c:2933
+#: builtin.c:3112
#, c-format
msgid "xor(%lf, %lf): fractional values will be truncated"
msgstr "xor(%lf, %lf): (không hoặc) giá trị thuộc phân số sẽ bị xén ngắn"
-#: builtin.c:2957 builtin.c:2963
+#: builtin.c:3136
msgid "compl: received non-numeric argument"
msgstr "compl: (biên dịch) đã nhận đối số khác thuộc số"
-#: builtin.c:2965
+#: builtin.c:3142
#, c-format
msgid "compl(%lf): negative value will give strange results"
msgstr "compl(%lf): (biên dịch) giá trị âm sẽ gây ra kết quả lạ"
-#: builtin.c:2967
+#: builtin.c:3144
#, c-format
msgid "compl(%lf): fractional value will be truncated"
msgstr "compl(%lf): (biên dịch) giá trị thuộc phân số se bị xén ngắn"
-#: builtin.c:3136
+#: builtin.c:3313
#, c-format
msgid "dcgettext: `%s' is not a valid locale category"
msgstr "dcgettext: « %s » không phải là má»™t phân loại miá»n địa phương hợp lệ"
-#: eval.c:412
+#: eval.c:395
#, c-format
msgid "unknown nodetype %d"
msgstr "không biết kiểu nút %d"
-#: eval.c:423 eval.c:437
+#: eval.c:406 eval.c:420
#, c-format
msgid "unknown opcode %d"
msgstr "gặp opcode (mã thao tác) không rõ %d"
-#: eval.c:434
+#: eval.c:417
#, c-format
msgid "opcode %s not an operator or keyword"
msgstr "mã lệnh %s không phải là một toán tử hoặc từ khoá"
-#: eval.c:488
+#: eval.c:472
msgid "buffer overflow in genflags2str"
msgstr "tràn bộ đệm trong « genflags2str » (tạo ra cỠđến chuỗi)"
-#: eval.c:698
+#: eval.c:675
#, c-format
msgid ""
"\n"
@@ -1010,311 +962,255 @@ msgstr ""
"\t# Äống gá»i hàm:\n"
"\n"
-#: eval.c:725
+#: eval.c:704
msgid "`IGNORECASE' is a gawk extension"
msgstr "« IGNORECASE » (bá» qua chữ hoa/thưá»ng) là phần mở rá»™ng gawk"
-#: eval.c:754
+#: eval.c:736
msgid "`BINMODE' is a gawk extension"
msgstr "« BINMODE » (chế độ nhị phân) là phần mở rộng gawk"
-#: eval.c:812
+#: eval.c:793
#, c-format
msgid "BINMODE value `%s' is invalid, treated as 3"
msgstr "Giá trị BINMODE (chế độ nhị phân) « %s » không hợp lệ nên thấy là 3"
-#: eval.c:902
+#: eval.c:885
#, c-format
msgid "bad `%sFMT' specification `%s'"
msgstr "đặc tả « %sFMT » sai « %s »"
-#: eval.c:980
+#: eval.c:969
msgid "turning off `--lint' due to assignment to `LINT'"
msgstr "đang tắt « --lint » do việc gán cho « LINT »"
-#: eval.c:1127 eval.c:1777
-#, c-format
-msgid "can't use function name `%s' as variable or array"
-msgstr "không thể dùng tên hàm « %s » như là biến hay mảng"
-
-#: eval.c:1158 eval.c:1789 eval.c:1802
+#: eval.c:1132
#, c-format
msgid "reference to uninitialized argument `%s'"
msgstr "gặp tham chiếu đến đối số chưa được sở khởi « %s »"
-#: eval.c:1177
+#: eval.c:1133
+#, c-format
+msgid "reference to uninitialized variable `%s'"
+msgstr "gặp tham chiếu đến biến chưa được sở khởi « %s »"
+
+#: eval.c:1151
msgid "attempt to field reference from non-numeric value"
msgstr "cố gắng tham chiếu trưá»ng từ giá trị khác thuá»™c số"
-#: eval.c:1179
+#: eval.c:1153
msgid "attempt to field reference from null string"
msgstr "cố gắng tham chiếu trưá»ng từ chá»—i trống rá»—ng"
-#: eval.c:1185
+#: eval.c:1161
#, c-format
msgid "attempt to access field %ld"
msgstr "cố gắng để truy cập trưá»ng %ld"
-#: eval.c:1194
+#: eval.c:1170
#, c-format
msgid "reference to uninitialized field `$%ld'"
msgstr "tham chiếu đến trưá»ng chưa được khởi tạo « $%ld »"
-#: eval.c:1256
+#: eval.c:1257
#, c-format
msgid "function `%s' called with more arguments than declared"
msgstr "hàm « %s » được gá»i vá»›i số đối số hÆ¡n số được tuyên bố"
-#: eval.c:1437
+#: eval.c:1452
#, c-format
msgid "unwind_stack: unexpected type `%s'"
msgstr "unwind_stack: không mong đợi kiểu `%s'"
-#: eval.c:1532
+#: eval.c:1546
msgid "division by zero attempted in `/='"
msgstr "cố gắng chia cho số không trong « /= »"
-#: eval.c:1539
+#: eval.c:1553
#, c-format
msgid "division by zero attempted in `%%='"
msgstr "cố gắng chia cho số không trong « %%= »"
-#: eval.c:1876 eval.c:2122
-#, c-format
-msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
-msgstr "cố gắng dùng mảng `%s[\"%.*s\"]' trong một ngữ cảnh vô hướng"
-
-#: eval.c:1907
-msgid "assignment used in conditional context"
-msgstr "Ä‘iá»u gán được dùng trong ngữ cảnh Ä‘iá»u kiện"
-
-#: eval.c:1911
-msgid "statement has no effect"
-msgstr "câu không có tác dụng"
-
-#: eval.c:2343
-#, c-format
-msgid "for loop: array `%s' changed size from %ld to %ld during loop execution"
-msgstr ""
-"cho loop: (cho vòng lặp) mảng « %s » đã thay đổi kích thước từ %ld đến %ld "
-"trong khi thực hiện vòng lặp"
-
-#: eval.c:2458
-#, c-format
-msgid "function called indirectly through `%s' does not exist"
-msgstr "hàm được gá»i gián tiếp thông qua `%s' không tồn tại"
-
-#: eval.c:2470
-#, c-format
-msgid "function `%s' not defined"
-msgstr "chưa xác định hàm « %s »"
-
-#: eval.c:2511
-#, c-format
-msgid "non-redirected `getline' invalid inside `%s' rule"
-msgstr "`getline' không-gửi-lại không hợp lệ bên trong quy tắc `%s'"
-
-#: eval.c:2600
-#, c-format
-msgid "error reading input file `%s': %s"
-msgstr "gặp lá»—i khi Ä‘á»c tập tin nhập « %s »: %s"
-
-#: eval.c:2614
-#, c-format
-msgid "`nextfile' cannot be called from a `%s' rule"
-msgstr "«nextfile» (tập tin kế tiếp) không thể được gá»i từ má»™t quy tắc `%s'"
-
-#: eval.c:2661
-msgid "`exit' cannot be called in the current context"
-msgstr "`exit' (thoát) không thể được gá»i trong ngữ cảnh hiện hành"
-
-#: eval.c:2700
-#, c-format
-msgid "`next' cannot be called from a `%s' rule"
-msgstr "«next» (kế tiếp) không thể được gá»i từ má»™t quy tắc `%s'"
-
-#: eval.c:2766
-#, c-format
-msgid "Sorry, don't know how to interpret `%s'"
-msgstr "Rất tiếc, không biết làm cách nào để phiên dịch được `%s'"
-
-#: ext.c:54
+#: ext.c:70
msgid "extensions are not allowed in sandbox mode"
msgstr "phần mở rộng không cho phép ở chế độ khuôn đúc"
-#: ext.c:60 ext.c:65
+#: ext.c:73
msgid "`extension' is a gawk extension"
msgstr "« extension » là một phần mở rộng gawk"
-#: ext.c:75
-#, c-format
-msgid "fatal: extension: cannot open `%s' (%s)\n"
+#: ext.c:80
+#, fuzzy, c-format
+msgid "extension: cannot open library `%s' (%s)\n"
msgstr "nghiêm trá»ng: phần mở rá»™ng: không thể mở `%s' (%s)\n"
-#: ext.c:84
-#, c-format
+#: ext.c:86
+#, fuzzy, c-format
msgid ""
-"fatal: extension: library `%s': does not define "
-"`plugin_is_GPL_compatible' (%s)\n"
+"extension: library `%s': does not define `plugin_is_GPL_compatible' (%s)\n"
msgstr ""
"nghiêm trá»ng: extension (phần mở rá»™ng): thư viện « %s »: không thể định "
"nghĩa `plugin_is_GPL_compatible' (tương thích cắm là dùng GPL) (%s)\n"
-#: ext.c:93
-#, c-format
-msgid "fatal: extension: library `%s': cannot call function `%s' (%s)\n"
+#: ext.c:90
+#, fuzzy, c-format
+msgid "extension: library `%s': cannot call function `%s' (%s)\n"
msgstr ""
"nghiêm trá»ng: extension (phần mở rá»™ng): thư viện « %s »: không thể gá»i hàm « "
"%s » (%s)\n"
-#: ext.c:127
+#: ext.c:118
msgid "extension: missing function name"
msgstr "extension: (phần mở rộng) tên hàm còn thiếu"
-#: ext.c:132
+#: ext.c:123
#, c-format
msgid "extension: illegal character `%c' in function name `%s'"
msgstr ""
"extension: (phần mở rộng) gặp ký tự cấm « %c » nằm trong tên hàm « %s »"
-#: ext.c:141
+#: ext.c:131
#, c-format
msgid "extension: can't redefine function `%s'"
msgstr "extension: (phần mở rộng) không thể xác định lại hàm « %s »"
-#: ext.c:145
+#: ext.c:135
#, c-format
msgid "extension: function `%s' already defined"
msgstr "extension: (phần mở rộng) hàm « %s » đã được xác định"
-#: ext.c:150
+#: ext.c:139
#, c-format
msgid "extension: function name `%s' previously defined"
msgstr "tên hàm « %s » đã được xác định trước"
-#: ext.c:152
+#: ext.c:141
#, c-format
msgid "extension: can't use gawk built-in `%s' as function name"
msgstr ""
"extension: (phần mở rá»™ng) không thể dùng Ä‘iá»u có sẵn cá»§a gawk « %s » như là "
"tên hàm"
-#: ext.c:156
+#: ext.c:144
#, c-format
msgid "make_builtin: negative argument count for function `%s'"
msgstr "make_builtin: đối số dành cho số đếm bị âm cho hàm `%s'"
-#: ext.c:259
+#: ext.c:206
#, c-format
msgid "function `%s' defined to take no more than %d argument(s)"
msgstr "hàm « %s » được xác định để chấp nhấn %d đối số tối đa"
-#: ext.c:262
+#: ext.c:209
#, c-format
msgid "function `%s': missing argument #%d"
msgstr "hàm « %s » còn thiếu đối số thứ %d"
-#: ext.c:279
+#: ext.c:226
#, c-format
msgid "function `%s': argument #%d: attempt to use scalar as an array"
msgstr "hàm « %s »: đối số thứ %d: cố gắng dùng Ä‘iá»u vô hướng như là mảng"
-#: ext.c:283
+#: ext.c:230
#, c-format
msgid "function `%s': argument #%d: attempt to use array as a scalar"
msgstr "hàm « %s »: đối số thứ %d: cố gắng dùng mảng như là Ä‘iá»u vô hướng"
-#: ext.c:296
+#: ext.c:244
msgid "Operation Not Supported"
msgstr "Thao tác không được hỗ trợ"
-#: field.c:328
+#: ext.c:256
+msgid "dynamic loading of library not supported"
+msgstr ""
+
+#: field.c:339
msgid "NF set to negative value"
msgstr "« NF » được đặt thành giá trị âm"
-#: field.c:951 field.c:958 field.c:962
+#: field.c:962 field.c:969 field.c:973
msgid "split: fourth argument is a gawk extension"
msgstr "split (chia tách): đối số thứ tư là phần mở rộng gawk"
-#: field.c:955
+#: field.c:966
msgid "split: fourth argument is not an array"
msgstr "split (chia tách): đối số thứ tư không phải là mảng"
-#: field.c:969
+#: field.c:980
msgid "split: second argument is not an array"
msgstr "split: (chia tách) đối số thứ hai không phải là mảng"
-#: field.c:973
+#: field.c:984
msgid "split: cannot use the same array for second and fourth args"
msgstr ""
"split (chia tách): không thể sử dụng cùng một mảng có cả đối số thứ hai và "
"thứ tư"
-#: field.c:978
+#: field.c:989
msgid "split: cannot use a subarray of second arg for fourth arg"
msgstr ""
"split (phân tách): không thể sử dụng mảng con của tham số thứ hai cho tham "
"số thứ tư"
-#: field.c:981
+#: field.c:992
msgid "split: cannot use a subarray of fourth arg for second arg"
msgstr ""
"split (phân tách): không thể sử dụng mảng con của tham số thứ tư cho tham số "
"thứ hai"
-#: field.c:1010
+#: field.c:1021
msgid "split: null string for third arg is a gawk extension"
msgstr ""
"split: (chia tách) chuỗi vô giá trị cho đối số thứ ba là phần mở rộng gawk"
-#: field.c:1050
+#: field.c:1061
msgid "patsplit: fourth argument is not an array"
msgstr "patsplit: đối số thứ tư không phải là mảng"
-#: field.c:1055
+#: field.c:1066
msgid "patsplit: second argument is not an array"
msgstr "patsplit: đối số thứ hai không phải là mảng"
-#: field.c:1061
+#: field.c:1072
msgid "patsplit: third argument must be non-null"
msgstr "patsplit: đối số thứ ba không phải không rỗng"
-#: field.c:1065
+#: field.c:1076
msgid "patsplit: cannot use the same array for second and fourth args"
msgstr ""
"patsplit (chương trình chia tách): không thể sử dụng cùng một mảng cho cả "
"hai đối số thứ hai và thứ tư"
-#: field.c:1070
+#: field.c:1081
msgid "patsplit: cannot use a subarray of second arg for fourth arg"
msgstr ""
"patsplit (chương trình phân tách): không thể sử dụng mảng con của tham số "
"thứ hai cho tham số thứ tư"
-#: field.c:1073
+#: field.c:1084
msgid "patsplit: cannot use a subarray of fourth arg for second arg"
msgstr ""
"patsplit (chương trình phân tách): không thể sử dụng mảng con của tham số "
"thứ tư cho tham số thứ hai"
-#: field.c:1110
+#: field.c:1122
msgid "`FIELDWIDTHS' is a gawk extension"
msgstr "« FIELDWIDTHS » (độ rá»™ng trưá»ng) là phần mở rá»™ng gawk"
-#: field.c:1173
+#: field.c:1186
#, c-format
msgid "invalid FIELDWIDTHS value, near `%s'"
msgstr "giá trị FIELDWIDTHS (độ rá»™ng trưá»ng) không hợp lệ, gần « %s »"
-#: field.c:1246
+#: field.c:1259
msgid "null string for `FS' is a gawk extension"
msgstr "chuỗi vô giá trị cho « FS » là phần mở rộng gawk"
-#: field.c:1250
+#: field.c:1263
msgid "old awk does not support regexps as value of `FS'"
msgstr "awk cũ không hỗ trợ biểu thức chính quy làm giá trị của « FS »"
-#: field.c:1369
+#: field.c:1382
msgid "`FPAT' is a gawk extension"
msgstr "`FPAT' là phần mở rộng của gawk"
@@ -1373,480 +1269,495 @@ msgstr "%s: tùy chá»n « -W %s » không cho phép đối số\n"
msgid "%s: option '-W %s' requires an argument\n"
msgstr "%s: tùy chá»n « -W %s » yêu cầu má»™t đối số\n"
-#: io.c:280
+#: io.c:326
#, c-format
msgid "command line argument `%s' is a directory: skipped"
msgstr "tham số dòng lệnh `%s' là một thư mục: đã bị bỠqua"
-#: io.c:283 io.c:385
+#: io.c:329 io.c:438
#, c-format
msgid "cannot open file `%s' for reading (%s)"
msgstr "không mở được tập tin « %s » để Ä‘á»c (%s)"
-#: io.c:501
+#: io.c:568
#, c-format
msgid "close of fd %d (`%s') failed (%s)"
msgstr "lỗi đóng fd %d (« %s ») (%s)"
-#: io.c:578
+#: io.c:645
msgid "redirection not allowed in sandbox mode"
msgstr "chuyển hướng không cho phép ở chế độ khuôn đúc"
-#: io.c:612
+#: io.c:679
#, c-format
msgid "expression in `%s' redirection only has numeric value"
msgstr "biểu thức trong Ä‘iá»u chuyển hướng « %s » chỉ có giá trị thuá»™c số"
-#: io.c:618
+#: io.c:685
#, c-format
msgid "expression for `%s' redirection has null string value"
msgstr "biểu thức cho Ä‘iá»u chuyển hướng « %s » có giá trị chuá»—i vô giá trị"
-#: io.c:623
+#: io.c:690
#, c-format
msgid "filename `%s' for `%s' redirection may be result of logical expression"
msgstr ""
"tên tập tin « %s » cho Ä‘iá»u chuyển hướng « %s » có lẽ là kết quả cá»§a biểu "
"thức luận lý"
-#: io.c:666
+#: io.c:733
#, c-format
msgid "unnecessary mixing of `>' and `>>' for file `%.*s'"
msgstr "không cần hợp « > » và « >> » cho tập tin « %.*s »"
-#: io.c:719
+#: io.c:786
#, c-format
msgid "can't open pipe `%s' for output (%s)"
msgstr "không thể mở ống dẫn « %s » để xuất (%s)"
-#: io.c:729
+#: io.c:796
#, c-format
msgid "can't open pipe `%s' for input (%s)"
msgstr "không thể mở ống dẫn « %s » để nhập (%s)"
-#: io.c:752
+#: io.c:819
#, c-format
msgid "can't open two way pipe `%s' for input/output (%s)"
msgstr "không thể mở ống dẫn hai chiá»u « %s » để nhập/xuất (%s)"
-#: io.c:834
+#: io.c:900
#, c-format
msgid "can't redirect from `%s' (%s)"
msgstr "không thể chuyển hướng từ « %s » (%s)"
-#: io.c:837
+#: io.c:903
#, c-format
msgid "can't redirect to `%s' (%s)"
msgstr "không thể chuyển hướng đến « %s » (%s)"
-#: io.c:888
+#: io.c:954
msgid ""
"reached system limit for open files: starting to multiplex file descriptors"
msgstr ""
"đã tá»›i giá»›i hạn hệ thống vá» tập tin được mở nên bắt đầu phối hợp nhiá»u dòng "
"Ä‘iá»u mô tả tập tin"
-#: io.c:904
+#: io.c:970
#, c-format
msgid "close of `%s' failed (%s)."
msgstr "lỗi đóng « %s » (%s)"
-#: io.c:912
+#: io.c:978
msgid "too many pipes or input files open"
msgstr "quá nhiá»u ống dẫn hay tập tin nhập được mở"
-#: io.c:934
+#: io.c:1000
msgid "close: second argument must be `to' or `from'"
msgstr "close: (đóng) đối số thứ hai phải là « to » (đến) hay « from » (từ)"
-#: io.c:951
+#: io.c:1017
#, c-format
msgid "close: `%.*s' is not an open file, pipe or co-process"
msgstr ""
"close: (đóng) « %.*s » không phải là tập tin được mở, ống dẫn hay tiến trình "
"vá»›i nhau"
-#: io.c:956
+#: io.c:1022
msgid "close of redirection that was never opened"
msgstr "việc đóng Ä‘iá»u chuyển hướng chưa mở"
-#: io.c:1053
+#: io.c:1120
#, c-format
msgid "close: redirection `%s' not opened with `|&', second argument ignored"
msgstr ""
"close: (đóng) Ä‘iá»u chuyển hướng « %s » không được mở bởi « |& » nên đối số "
"thứ hai bị bỠqua"
-#: io.c:1069
+#: io.c:1137
#, c-format
msgid "failure status (%d) on pipe close of `%s' (%s)"
msgstr "trạng thái thất bại (%d) khi đóng ống dẫn « %s » (%s)"
-#: io.c:1072
+#: io.c:1140
#, c-format
msgid "failure status (%d) on file close of `%s' (%s)"
msgstr "trạng thái thất bại (%d) khi đóng tập tin « %s » (%s)"
-#: io.c:1092
+#: io.c:1160
#, c-format
msgid "no explicit close of socket `%s' provided"
msgstr "không có việc đóng dứt khoát ổ cắm « %s » được cung cấp"
-#: io.c:1095
+#: io.c:1163
#, c-format
msgid "no explicit close of co-process `%s' provided"
msgstr "không có việc đóng dứt khoát đồng tiến trình « %s » được cung cấp"
-#: io.c:1098
+#: io.c:1166
#, c-format
msgid "no explicit close of pipe `%s' provided"
msgstr "không có việc đóng dứt khoát ống dẫn « %s » được cung cấp"
-#: io.c:1101
+#: io.c:1169
#, c-format
msgid "no explicit close of file `%s' provided"
msgstr "không có việc đóng dứt khoát tập tin « %s » được cung cấp"
-#: io.c:1129 io.c:1184 main.c:794 main.c:831
+#: io.c:1197 io.c:1252 main.c:825 main.c:862
#, c-format
msgid "error writing standard output (%s)"
msgstr "gặp lỗi khi ghi thiết bị xụất chuẩn (%s)"
-#: io.c:1133 io.c:1189
+#: io.c:1201 io.c:1257
#, c-format
msgid "error writing standard error (%s)"
msgstr "gặp lỗi khi ghi thiết bị lỗi chuẩn (%s)"
-#: io.c:1141
+#: io.c:1209
#, c-format
msgid "pipe flush of `%s' failed (%s)."
msgstr "lỗi xoá sạch ống dẫn « %s » (%s)"
-#: io.c:1144
+#: io.c:1212
#, c-format
msgid "co-process flush of pipe to `%s' failed (%s)."
msgstr "lỗi xoá sạch ống dẫn đồng tiến trình đến « %s » (%s)"
-#: io.c:1147
+#: io.c:1215
#, c-format
msgid "file flush of `%s' failed (%s)."
msgstr "lỗi xoá sạch tập tin « %s » (%s)"
-#: io.c:1262
+#: io.c:1329
#, c-format
msgid "local port %s invalid in `/inet'"
msgstr "cổng cục bộ %s không hợp lệ trong « /inet »"
-#: io.c:1279
+#: io.c:1347
#, c-format
msgid "remote host and port information (%s, %s) invalid"
msgstr "thông tin vỠmáy/cổng ở xa (%s, %s) không phải hợp lệ"
-#: io.c:1431
+#: io.c:1499
#, c-format
msgid "no (known) protocol supplied in special filename `%s'"
msgstr ""
"trong tên tập tin đặc biệt « %s » không cung cấp giao thức (đã biết) nào"
-#: io.c:1445
+#: io.c:1513
#, c-format
msgid "special file name `%s' is incomplete"
msgstr "tên tập tin đặc biệt « %s » chưa xong"
-#: io.c:1462
+#: io.c:1530
msgid "must supply a remote hostname to `/inet'"
msgstr "phải cung cấp một tên máy từ xa cho </inet>"
-#: io.c:1480
+#: io.c:1548
msgid "must supply a remote port to `/inet'"
msgstr "phải cung cấp một cổng từ xa cho </inet>"
-#: io.c:1526
+#: io.c:1594
msgid "TCP/IP communications are not supported"
msgstr "truyá»n thông TCP/IP không được há»— trợ"
-#: io.c:1693
+#: io.c:1764
#, c-format
msgid "could not open `%s', mode `%s'"
msgstr "không mở được « %s », chế độ « %s »"
-#: io.c:1747
+#: io.c:1814
#, c-format
msgid "close of master pty failed (%s)"
msgstr "lỗi đóng pty (tài sản?) chính (%s)"
-#: io.c:1749 io.c:1917 io.c:2074
+#: io.c:1816 io.c:1984 io.c:2145
#, c-format
msgid "close of stdout in child failed (%s)"
msgstr "lỗi đóng thiết bị xuất chuẩn trong tiến trình con (%s)"
-#: io.c:1752
+#: io.c:1819
#, c-format
msgid "moving slave pty to stdout in child failed (dup: %s)"
msgstr ""
"lá»—i di chuyển pty (tài sản?) phụ tá»›i thiết bị xuất chuẩn trong Ä‘iá»u con "
"(nhân đôi: %s)"
-#: io.c:1754 io.c:1922
+#: io.c:1821 io.c:1989
#, c-format
msgid "close of stdin in child failed (%s)"
msgstr "lỗi đóng thiết bị nhập chuẩn trong tiến trình con (%s)"
-#: io.c:1757
+#: io.c:1824
#, c-format
msgid "moving slave pty to stdin in child failed (dup: %s)"
msgstr ""
"lá»—i di chuyển pty (tài sản?) phụ tá»›i thiết bị nhập chuẩn trong Ä‘iá»u con "
"(nhân đôi: %s)"
-#: io.c:1759 io.c:1780
+#: io.c:1826 io.c:1847
#, c-format
msgid "close of slave pty failed (%s)"
msgstr "lỗi đóng pty (tài sản?) phụ (%s)"
-#: io.c:1858 io.c:1920 io.c:2052 io.c:2077
+#: io.c:1925 io.c:1987 io.c:2122 io.c:2148
#, c-format
msgid "moving pipe to stdout in child failed (dup: %s)"
msgstr ""
"lỗi di chuyển ống dẫn đến thiết bị xuất chuẩn trong tiến trình con (dup: %s) "
"(nhân đôi)"
-#: io.c:1865 io.c:1925
+#: io.c:1932 io.c:1992
#, c-format
msgid "moving pipe to stdin in child failed (dup: %s)"
msgstr ""
"lỗi di chuyển ống dẫn đến thiết bị nhập chuẩn trong tiến trình con (dup: %s) "
"(nhân đôi)"
-#: io.c:1885 io.c:2067
+#: io.c:1952 io.c:2138
msgid "restoring stdout in parent process failed\n"
msgstr "lỗi phục hồi thiết bị xuất chuẩn trong tiến trình mẹ\n"
-#: io.c:1893
+#: io.c:1960
msgid "restoring stdin in parent process failed\n"
msgstr "lỗi phục hồi thiết bị nhập chuẩn trong tiến trình mẹ\n"
-#: io.c:1928 io.c:2079 io.c:2093
+#: io.c:1995 io.c:2150 io.c:2164
#, c-format
msgid "close of pipe failed (%s)"
msgstr "lỗi đóng ống dẫn (%s)"
-#: io.c:1973
+#: io.c:2040
msgid "`|&' not supported"
msgstr "« |& » không được hỗ trợ"
-#: io.c:2039
+#: io.c:2107
#, c-format
msgid "cannot open pipe `%s' (%s)"
msgstr "không thể mở ống dẫn « %s » (%s)"
-#: io.c:2087
+#: io.c:2158
#, c-format
msgid "cannot create child process for `%s' (fork: %s)"
msgstr "không thể tạo tiến trình con cho « %s » (fork: %s)"
-#: io.c:2520
+#: io.c:2637
#, c-format
msgid "data file `%s' is empty"
msgstr "tập tin dữ liệu « %s » là rỗng"
-#: io.c:2561 io.c:2569
+#: io.c:2678 io.c:2686
msgid "could not allocate more input memory"
msgstr "không thể cấp phát bộ nhớ nhập thêm nữa"
-#: io.c:3127
+#: io.c:3236
msgid "multicharacter value of `RS' is a gawk extension"
msgstr "giá trị đa ký tự của « RS » là phần mở rộng gawk"
-#: io.c:3232
+#: io.c:3326
msgid "IPv6 communication is not supported"
msgstr "Truyá»n thông trên IPv6 không được há»— trợ"
-#: main.c:366
+#: main.c:355
msgid "`-m[fr]' option irrelevant in gawk"
msgstr "tùy chá»n « -m[fr] » không thích Ä‘ang trong gawk"
-#: main.c:368
+#: main.c:357
msgid "-m option usage: `-m[fr] nnn'"
msgstr "cách sá»­ dụng tùy chá»n « -m »: « -m[fr] nnn »"
-#: main.c:391
+#: main.c:386
msgid "empty argument to `-e/--source' ignored"
msgstr "đối số rá»—ng cho tuỳ chá»n `-e/--source' bị bá» qua"
-#: main.c:462
+#: main.c:472
#, c-format
msgid "%s: option `-W %s' unrecognized, ignored\n"
msgstr "%s: tùy chá»n « -W %s » không được nhận diện nên bị bá» qua\n"
-#: main.c:515
+#: main.c:518
#, c-format
msgid "%s: option requires an argument -- %c\n"
msgstr "%s: tùy chá»n cần đến đối số « -- %c »\n"
-#: main.c:536
+#: main.c:539
msgid "environment variable `POSIXLY_CORRECT' set: turning on `--posix'"
msgstr ""
"biến môi trưá»ng « POSIXLY_CORRECT » (đúng kiểu POSIX) đã được đặt; Ä‘ang bật "
"tùy chá»n « --posix »"
-#: main.c:542
+#: main.c:545
msgid "`--posix' overrides `--traditional'"
msgstr "tùy chá»n « --posix » có quyá»n cao hÆ¡n « --traditional » (truyá»n thống)"
-#: main.c:553
+#: main.c:556
msgid "`--posix'/`--traditional' overrides `--non-decimal-data'"
msgstr ""
"« --posix »/« --traditional » (truyá»n thống) có quyá»n cao hÆ¡n « --non-"
"decimal-data » (dữ liệu khác thập phân)"
-#: main.c:557
+#: main.c:560
#, c-format
msgid "running %s setuid root may be a security problem"
msgstr "việc chạy %s với tư cách « setuid root » có thể rủi rỠbảo mật"
-#: main.c:562
+#: main.c:565
msgid "`--posix' overrides `--binary'"
msgstr "`--posix' đè lên `--binary'"
-#: main.c:613
+#: main.c:623
#, c-format
msgid "can't set binary mode on stdin (%s)"
msgstr "không thể đặt chế độ nhị phân trên thiết bị nhập chuẩn (%s)"
-#: main.c:616
+#: main.c:626
#, c-format
msgid "can't set binary mode on stdout (%s)"
msgstr "không thể đặt chế độ nhị phân trên thiết bị xuất chuẩn (%s)"
-#: main.c:618
+#: main.c:628
#, c-format
msgid "can't set binary mode on stderr (%s)"
msgstr "không thể đặt chế độ nhị phân trên thiết bị lỗi chuẩn (%s)"
-#: main.c:657
+#: main.c:679
msgid "no program text at all!"
msgstr "không có đoạn chữ chương trình nào cả !"
-#: main.c:734
+#: main.c:763
#, c-format
msgid "Usage: %s [POSIX or GNU style options] -f progfile [--] file ...\n"
msgstr ""
"Cách sá»­ dụng: %s [tùy chá»n kiểu POSIX hay GNU] -f tập_tin_chương_trình [--] "
"tập_tin ...\n"
-#: main.c:736
+#: main.c:765
#, c-format
msgid "Usage: %s [POSIX or GNU style options] [--] %cprogram%c file ...\n"
msgstr ""
"Cách sá»­ dụng: %s [tùy chá»n kiểu POSIX hay GNU] [--] %cchương_trình%c "
"tập_tin ...\n"
-#: main.c:741
+#: main.c:770
msgid "POSIX options:\t\tGNU long options: (standard)\n"
msgstr "Tùy chá»n POSIX:\t\tTùy chá»n dài GNU: (theo tiêu chuẩn)\n"
-#: main.c:742
+#: main.c:771
msgid "\t-f progfile\t\t--file=progfile\n"
msgstr "\t-f tập_tin_chương_trình\t\t--file=tập_tin_chương_trình\n"
-#: main.c:743
+#: main.c:772
msgid "\t-F fs\t\t\t--field-separator=fs\n"
msgstr "\t-F fs\t\t\t--field-separator=Ä‘iá»u phân cách trưá»ng\n"
-#: main.c:744
+#: main.c:773
msgid "\t-v var=val\t\t--assign=var=val\n"
msgstr ""
"\t-v var=giá trị\t\t--assign=biến=giá_trị\n"
"(assign: gán)\n"
-#: main.c:745
+#: main.c:774
msgid "Short options:\t\tGNU long options: (extensions)\n"
msgstr "Tuỳ chá»n ngắn:\t\tTuỳ chá»n GNU dạng dài: (phần mở rá»™ng)\n"
-#: main.c:746
+#: main.c:775
msgid "\t-b\t\t\t--characters-as-bytes\n"
msgstr "\t-b\t\t\t--characters-as-bytes\n"
-#: main.c:747
+#: main.c:776
msgid "\t-c\t\t\t--traditional\n"
msgstr "\t-c\t\t\t--traditional\n"
-#: main.c:748
+#: main.c:777
msgid "\t-C\t\t\t--copyright\n"
msgstr "\t-C\t\t\t--copyright\n"
-#: main.c:749
+#: main.c:778
msgid "\t-d[file]\t\t--dump-variables[=file]\n"
msgstr "\t-d[tệp_tin]\t\t--dump-variables[=tệp_tin]\n"
-#: main.c:750
+#: main.c:779
+#, fuzzy
+msgid "\t-D[file]\t\t--debug[=file]\n"
+msgstr "\t-p[file]\t\t--profile[=file]\n"
+
+#: main.c:780
msgid "\t-e 'program-text'\t--source='program-text'\n"
msgstr "\t-e 'program-text'\t--source='program-text'\n"
-#: main.c:751
+#: main.c:781
msgid "\t-E file\t\t\t--exec=file\n"
msgstr "\t-E file\t\t\t--exec=tệp_tin\n"
-#: main.c:752
+#: main.c:782
msgid "\t-g\t\t\t--gen-pot\n"
msgstr "\t-g\t\t\t--gen-pot\n"
-#: main.c:753
+#: main.c:783
msgid "\t-h\t\t\t--help\n"
msgstr "\t-h\t\t\t--help\n"
-#: main.c:754
+#: main.c:784
+msgid "\t-l library\t\t--load=library\n"
+msgstr ""
+
+#: main.c:785
msgid "\t-L [fatal]\t\t--lint[=fatal]\n"
msgstr "\t-L [fatal]\t\t--lint[=fatal]\n"
-#: main.c:755
+#: main.c:786
msgid "\t-n\t\t\t--non-decimal-data\n"
msgstr "\t-n\t\t\t--non-decimal-data\n"
-#: main.c:756
+#: main.c:787
+#, fuzzy
+msgid "\t-M\t\t\t--bignum\n"
+msgstr "\t-g\t\t\t--gen-pot\n"
+
+#: main.c:788
msgid "\t-N\t\t\t--use-lc-numeric\n"
msgstr "\t-N\t\t\t--use-lc-numeric\n"
-#: main.c:757
+#: main.c:789
+#, fuzzy
+msgid "\t-o[file]\t\t--pretty-print[=file]\n"
+msgstr "\t-p[file]\t\t--profile[=file]\n"
+
+#: main.c:790
msgid "\t-O\t\t\t--optimize\n"
msgstr "\t-O\t\t\t--optimize\ttối ưu hoá\n"
-#: main.c:758
+#: main.c:791
msgid "\t-p[file]\t\t--profile[=file]\n"
msgstr "\t-p[file]\t\t--profile[=file]\n"
-#: main.c:759
+#: main.c:792
msgid "\t-P\t\t\t--posix\n"
msgstr "\t-P\t\t\t--posix\n"
-#: main.c:760
+#: main.c:793
msgid "\t-r\t\t\t--re-interval\n"
msgstr "\t-r\t\t\t--re-interval\n"
-#: main.c:762
-msgid "\t-R file\t\t\t--command=file\n"
-msgstr "\t-R file\t\t\t--command=tệp_tin\n"
-
-#: main.c:763
+#: main.c:794
msgid "\t-S\t\t\t--sandbox\n"
msgstr "\t-S\t\t\t--sandbox\n"
-#: main.c:764
+#: main.c:795
msgid "\t-t\t\t\t--lint-old\n"
msgstr "\t-t\t\t\t--lint-old\n"
-#: main.c:765
+#: main.c:796
msgid "\t-V\t\t\t--version\n"
msgstr "\t-V\t\t\t--version\n"
-#: main.c:767
+#: main.c:798
msgid "\t-W nostalgia\t\t--nostalgia\n"
msgstr ""
"\t-W nostalgia\t\t--nostalgia\n"
"(nỗi luyến tiếc quá khứ)\n"
-#: main.c:770
+#: main.c:801
msgid "\t-Y\t\t--parsedebug\n"
msgstr "\t-Y\t\t--parsedebug\n"
@@ -1855,7 +1766,7 @@ msgstr "\t-Y\t\t--parsedebug\n"
#. for this application. Please add _another line_ with the
#. address for translation bugs.
#. no-wrap
-#: main.c:779
+#: main.c:810
msgid ""
"\n"
"To report bugs, see node `Bugs' in `gawk.info', which is\n"
@@ -1869,7 +1780,7 @@ msgstr ""
"trong bản in.\n"
"\n"
-#: main.c:783
+#: main.c:814
msgid ""
"gawk is a pattern scanning and processing language.\n"
"By default it reads standard input and writes standard output.\n"
@@ -1879,7 +1790,7 @@ msgstr ""
"Mặc định là nó Ä‘á»c thiết bị nhập chuẩn và ghi ra thiết bị xuất chuẩn.\n"
"\n"
-#: main.c:787
+#: main.c:818
msgid ""
"Examples:\n"
"\tgawk '{ sum += $1 }; END { print sum }' file\n"
@@ -1889,7 +1800,7 @@ msgstr ""
"\tgawk '{ sum += $1 }; END { print sum }' file\n"
"\tgawk -F: '{ print $1 }' /etc/passwd\n"
-#: main.c:807
+#: main.c:838
#, c-format
msgid ""
"Copyright (C) 1989, 1991-%d Free Software Foundation.\n"
@@ -1908,7 +1819,7 @@ msgstr ""
"kỳ phiên bản sau nào.\n"
"\n"
-#: main.c:815
+#: main.c:846
msgid ""
"This program is distributed in the hope that it will be useful,\n"
"but WITHOUT ANY WARRANTY; without even the implied warranty of\n"
@@ -1922,7 +1833,7 @@ msgstr ""
"Hãy xem Bản Quyá»n Công Chung GNU (GPL) để tìm chi tiết.\n"
"\n"
-#: main.c:821
+#: main.c:852
msgid ""
"You should have received a copy of the GNU General Public License\n"
"along with this program. If not, see http://www.gnu.org/licenses/.\n"
@@ -1931,16 +1842,16 @@ msgstr ""
"cùng với chương trình này. Không thì xem địa chỉ « http://www.gnu.org/"
"licenses/ ».\n"
-#: main.c:856
+#: main.c:887
msgid "-Ft does not set FS to tab in POSIX awk"
msgstr "-Ft không đặt FS (hệ thống tập tin?) là tab trong awk POSIX"
-#: main.c:1090
+#: main.c:1133
#, c-format
msgid "unknown value for field spec: %d\n"
msgstr "không hiểu giá trị dành cho đặc tính trưá»ng: %d\n"
-#: main.c:1171
+#: main.c:1214
#, c-format
msgid ""
"%s: `%s' argument to `-v' not in `var=value' form\n"
@@ -1949,79 +1860,79 @@ msgstr ""
"%s: đối số « %s » đối với « -v » không phải có dạng « biến=giá_trị »\n"
"\n"
-#: main.c:1197
+#: main.c:1240
#, c-format
msgid "`%s' is not a legal variable name"
msgstr "« %s » không phải là tên biến hợp lệ"
-#: main.c:1200
+#: main.c:1243
#, c-format
msgid "`%s' is not a variable name, looking for file `%s=%s'"
msgstr "« %s » không phải là tên biến; đang tìm tập tin « %s=%s »"
-#: main.c:1204
+#: main.c:1247
#, c-format
msgid "cannot use gawk builtin `%s' as variable name"
msgstr "không thể dùng builtin (dựng sẵn) của gawk « %s » như là tên biến"
-#: main.c:1209
+#: main.c:1252
#, c-format
msgid "cannot use function `%s' as variable name"
msgstr "không thể dùng hàm « %s » như là tên biến"
-#: main.c:1262
+#: main.c:1305
msgid "floating point exception"
msgstr "ngoại lệ điểm phù động"
-#: main.c:1269
+#: main.c:1312
msgid "fatal error: internal error"
msgstr "lá»—i nghiêm trá»ng: lá»—i ná»™i bá»™"
-#: main.c:1284
+#: main.c:1327
msgid "fatal error: internal error: segfault"
msgstr "lá»—i nghiêm trá»ng: lá»—i ná»™i bá»™ : lá»—i chia ra từng Ä‘oạn"
-#: main.c:1296
+#: main.c:1339
msgid "fatal error: internal error: stack overflow"
msgstr "lá»—i nghiêm trá»ng: lá»—i ná»™i bá»™ : tràn đống"
-#: main.c:1346
+#: main.c:1393
#, c-format
msgid "no pre-opened fd %d"
msgstr "không có fd (chỉ thị tập tin?) %d đã mở trước"
-#: main.c:1353
+#: main.c:1400
#, c-format
msgid "could not pre-open /dev/null for fd %d"
msgstr "không thể mở sẵn « /dev/null » cho fd %d"
-#: msg.c:63
+#: msg.c:61
#, c-format
msgid "cmd. line:"
msgstr "dòng lệnh:"
-#: msg.c:107
+#: msg.c:121
msgid "error: "
msgstr "lá»—i: "
-#: node.c:406
+#: node.c:436
msgid "backslash at end of string"
msgstr "gặp xuyệc ngoặc tại kết thúc của chuỗi"
-#: node.c:517
+#: node.c:520
#, c-format
msgid "old awk does not support the `\\%c' escape sequence"
msgstr "awk cũ không hỗ trợ dãy thoát « \\%c »"
-#: node.c:568
+#: node.c:571
msgid "POSIX does not allow `\\x' escapes"
msgstr "POSIX không cho phép Ä‘iá»u thoát « \\x »"
-#: node.c:574
+#: node.c:577
msgid "no hex digits in `\\x' escape sequence"
msgstr "không có số thập lúc nằm trong dây thoát « \\x »"
-#: node.c:596
+#: node.c:599
#, c-format
msgid ""
"hex escape \\x%.*s of %d characters probably not interpreted the way you "
@@ -2030,12 +1941,12 @@ msgstr ""
"dây thoát thập lục \\x%.*s chứa %d ký tá»± mà rất có thể không phải được Ä‘á»c "
"bằng cách dự định"
-#: node.c:611
+#: node.c:614
#, c-format
msgid "escape sequence `\\%c' treated as plain `%c'"
msgstr "dây thoát « \\%c » được xử lý như là « %c » chuẩn"
-#: node.c:750
+#: node.c:759
msgid ""
"Invalid multibyte data detected. There may be a mismatch between your data "
"and your locale."
@@ -2055,16 +1966,16 @@ msgstr ""
"%s %s « %s »: không thể đặt « close-on-exec » (đóng một khi thực hiện): "
"(fcntl F_SETFD: %s)"
-#: profile.c:83
+#: profile.c:69
#, c-format
msgid "could not open `%s' for writing: %s"
msgstr "không thể mở « %s » để ghi: %s"
-#: profile.c:85
+#: profile.c:71
msgid "sending profile to standard error"
msgstr "đang gởi hồ sơ cho thiết bị lỗi chuẩn"
-#: profile.c:203
+#: profile.c:187
#, c-format
msgid ""
"\t# %s block(s)\n"
@@ -2073,7 +1984,7 @@ msgstr ""
"\t# %s khối\n"
"\n"
-#: profile.c:208
+#: profile.c:192
#, c-format
msgid ""
"\t# Rule(s)\n"
@@ -2082,17 +1993,22 @@ msgstr ""
"\t# Quy tắc\n"
"\n"
-#: profile.c:279
+#: profile.c:266
#, c-format
msgid "internal error: %s with null vname"
msgstr "lỗi nội bộ: %s với vname (tên biến?) vô giá trị"
-#: profile.c:952
+#: profile.c:528
+#, fuzzy
+msgid "internal error: builtin with null fname"
+msgstr "lỗi nội bộ: %s với vname (tên biến?) vô giá trị"
+
+#: profile.c:943
#, c-format
msgid "\t# gawk profile, created %s\n"
msgstr "\t# hồ sơ gawk, được tạo %s\n"
-#: profile.c:1331
+#: profile.c:1328
#, c-format
msgid ""
"\n"
@@ -2101,17 +2017,17 @@ msgstr ""
"\n"
"\t# Danh sách các hàm theo thứ tự abc\n"
-#: profile.c:1370
+#: profile.c:1366
#, c-format
msgid "redir2str: unknown redirection type %d"
msgstr "redir2str: không hiểu kiểu chuyển hướng %d"
-#: re.c:573
+#: re.c:571
#, c-format
msgid "range of the form `[%c-%c]' is locale dependent"
msgstr "dạng thức vùng `[%c-%c]' thì phụ thuộc vị trí"
-#: re.c:600
+#: re.c:598
#, c-format
msgid "regexp component `%.*s' should probably be `[%.*s]'"
msgstr ""
@@ -2190,6 +2106,78 @@ msgstr "Chưa khớp « ) » hay « \\) »"
msgid "No previous regular expression"
msgstr "Không có biểu thức chính quy nằm trước"
+#~ msgid "attempt to use function `%s' as an array"
+#~ msgstr "cố gắng dùng hàm « %s » như mảng"
+
+#~ msgid "reference to uninitialized element `%s[\"%.*s\"]'"
+#~ msgstr "tham chiếu đến phần tử chưa sở khởi « %s[\"%.*s\"] »"
+
+#~ msgid "subscript of array `%s' is null string"
+#~ msgstr "chữ in dưới mảng « %s » là chuỗi rỗng"
+
+#~ msgid "%s: empty (null)\n"
+#~ msgstr "%s: rỗng (vô giá trị)\n"
+
+#~ msgid "%s: empty (zero)\n"
+#~ msgstr "%s: rỗng (số không)\n"
+
+#~ msgid "%s: table_size = %d, array_size = %d\n"
+#~ msgstr "%s: cỡ_bảng = %d, cỡ_mảng = %d\n"
+
+#~ msgid "%s: is parameter\n"
+#~ msgstr "%s: là tham số\n"
+
+#~ msgid "%s: array_ref to %s\n"
+#~ msgstr "%s: « array_ref » (mảng tham chiếu) đến « %s »\n"
+
+#~ msgid "use of non-array as array"
+#~ msgstr "việc dùng cái khác mảng như là mảng"
+
+#~ msgid "can't use function name `%s' as variable or array"
+#~ msgstr "không thể dùng tên hàm « %s » như là biến hay mảng"
+
+#~ msgid "attempt to use array `%s[\"%.*s\"]' in a scalar context"
+#~ msgstr "cố gắng dùng mảng `%s[\"%.*s\"]' trong một ngữ cảnh vô hướng"
+
+#~ msgid "assignment used in conditional context"
+#~ msgstr "Ä‘iá»u gán được dùng trong ngữ cảnh Ä‘iá»u kiện"
+
+#~ msgid "statement has no effect"
+#~ msgstr "câu không có tác dụng"
+
+#~ msgid ""
+#~ "for loop: array `%s' changed size from %ld to %ld during loop execution"
+#~ msgstr ""
+#~ "cho loop: (cho vòng lặp) mảng « %s » đã thay đổi kích thước từ %ld đến "
+#~ "%ld trong khi thực hiện vòng lặp"
+
+#~ msgid "function called indirectly through `%s' does not exist"
+#~ msgstr "hàm được gá»i gián tiếp thông qua `%s' không tồn tại"
+
+#~ msgid "function `%s' not defined"
+#~ msgstr "chưa xác định hàm « %s »"
+
+#~ msgid "non-redirected `getline' invalid inside `%s' rule"
+#~ msgstr "`getline' không-gửi-lại không hợp lệ bên trong quy tắc `%s'"
+
+#~ msgid "error reading input file `%s': %s"
+#~ msgstr "gặp lá»—i khi Ä‘á»c tập tin nhập « %s »: %s"
+
+#~ msgid "`nextfile' cannot be called from a `%s' rule"
+#~ msgstr "«nextfile» (tập tin kế tiếp) không thể được gá»i từ má»™t quy tắc `%s'"
+
+#~ msgid "`exit' cannot be called in the current context"
+#~ msgstr "`exit' (thoát) không thể được gá»i trong ngữ cảnh hiện hành"
+
+#~ msgid "`next' cannot be called from a `%s' rule"
+#~ msgstr "«next» (kế tiếp) không thể được gá»i từ má»™t quy tắc `%s'"
+
+#~ msgid "Sorry, don't know how to interpret `%s'"
+#~ msgstr "Rất tiếc, không biết làm cách nào để phiên dịch được `%s'"
+
+#~ msgid "\t-R file\t\t\t--command=file\n"
+#~ msgstr "\t-R file\t\t\t--command=tệp_tin\n"
+
#~ msgid "could not find groups: %s"
#~ msgstr "không tìm thấy nhóm: %s"
diff --git a/po/zh_CN.gmo b/po/zh_CN.gmo
deleted file mode 100644
index 7ed096c3..00000000
--- a/po/zh_CN.gmo
+++ /dev/null
Binary files differ
diff --git a/profile.c b/profile.c
index eb788377..181395d9 100644
--- a/profile.c
+++ b/profile.c
@@ -43,15 +43,14 @@ const char *redir2str(int redirtype);
#define DONT_FREE 1
#define CAN_FREE 2
-#ifdef PROFILING
+
static RETSIGTYPE dump_and_exit(int signum) ATTRIBUTE_NORETURN;
static RETSIGTYPE just_dump(int signum);
-#endif
/* pretty printing related functions and variables */
static NODE *pp_stack = NULL;
-static char **fparms; /* function parameter names */
+static NODE *func_params; /* function parameters */
static FILE *prof_fp; /* where to send the profile */
static long indent_level = 0;
@@ -59,20 +58,7 @@ static long indent_level = 0;
#define SPACEOVER 0
-/* init_profiling --- do needed initializations, see also main.c */
-
-void
-init_profiling(int *flag ATTRIBUTE_UNUSED, const char *def_file ATTRIBUTE_UNUSED)
-{
-#ifdef PROFILING
- if (*flag == FALSE) {
- *flag = TRUE;
- set_prof_file(def_file);
- }
-#endif
-}
-
-/* set_prof_file --- set the output file for profiling */
+/* set_prof_file --- set the output file for profiling or pretty-printing */
void
set_prof_file(const char *file)
@@ -87,12 +73,11 @@ set_prof_file(const char *file)
}
}
-/* init_profiling_signals --- set up signal handling for pgawk */
+/* init_profiling_signals --- set up signal handling for gawk --profile */
void
init_profiling_signals()
{
-#ifdef PROFILING
#ifdef __DJGPP__
signal(SIGINT, dump_and_exit);
signal(SIGQUIT, just_dump);
@@ -104,7 +89,6 @@ init_profiling_signals()
signal(SIGUSR1, just_dump);
#endif
#endif /* !__DJGPP__ */
-#endif /* PROFILING */
}
/* indent --- print out enough tabs */
@@ -214,10 +198,10 @@ pprint(INSTRUCTION *startp, INSTRUCTION *endp, int in_for_header)
fprintf(prof_fp, "%s {", t1->pp_str);
pp_free(t1);
ip = (pc + 1)->firsti;
-#ifdef PROFILING
- if (ip->exec_count > 0)
+
+ if (do_profile && ip->exec_count > 0)
fprintf(prof_fp, " # %ld", ip->exec_count);
-#endif
+
fprintf(prof_fp, "\n");
} else {
fprintf(prof_fp, "{\n");
@@ -244,7 +228,7 @@ pprint(INSTRUCTION *startp, INSTRUCTION *endp, int in_for_header)
if (m == Nnull_string) /* optional return or exit value; don't print 0 or "" */
pp_push(pc->opcode, m->stptr, DONT_FREE);
else if ((m->flags & NUMBER) != 0)
- pp_push(pc->opcode, pp_number(m->numbr), CAN_FREE);
+ pp_push(pc->opcode, pp_number(m), CAN_FREE);
else {
str = pp_string(m->stptr, m->stlen, '"');
if ((m->flags & INTLSTR) != 0) {
@@ -257,6 +241,9 @@ pprint(INSTRUCTION *startp, INSTRUCTION *endp, int in_for_header)
break;
case Op_store_var:
+ if (pc->initval != NULL)
+ pp_push(Op_push_i, pp_node(pc->initval), CAN_FREE);
+ /* fall through */
case Op_store_sub:
case Op_assign_concat:
case Op_push_lhs:
@@ -267,7 +254,7 @@ pprint(INSTRUCTION *startp, INSTRUCTION *endp, int in_for_header)
m = pc->memory;
switch (m->type) {
case Node_param_list:
- pp_push(pc->opcode, fparms[m->param_cnt], DONT_FREE);
+ pp_push(pc->opcode, func_params[m->param_cnt].param, DONT_FREE);
break;
case Node_var:
@@ -354,7 +341,7 @@ cleanup:
&& is_binary(t1->type)) /* (a - b) * 1 */
pp_parenthesize(t1);
if ((m->flags & NUMBER) != 0)
- tmp = pp_number(m->numbr);
+ tmp = pp_number(m);
else
tmp = pp_string(m->stptr, m->stlen, '"');
str = pp_concat(t1->pp_str, op2str(pc->opcode), tmp);
@@ -522,9 +509,13 @@ cleanup:
break;
case Op_builtin:
+ case Op_ext_builtin:
{
- static char *ext_func = "extension_function()";
- const char *fname = getfname(pc->builtin);
+ const char *fname;
+ if (pc->opcode == Op_builtin)
+ fname = getfname(pc->builtin);
+ else
+ fname = (pc + 1)->func_name;
if (fname != NULL) {
if (pc->expr_count > 0) {
tmp = pp_list(pc->expr_count, "()", ", ");
@@ -534,10 +525,10 @@ cleanup:
str = pp_concat(fname, "()", "");
pp_push(Op_builtin, str, CAN_FREE);
} else
- pp_push(Op_builtin, ext_func, DONT_FREE);
+ fatal(_("internal error: builtin with null fname"));
}
break;
-
+
case Op_K_print:
case Op_K_printf:
case Op_K_print_rec:
@@ -756,14 +747,15 @@ cleanup:
case Op_K_arrayfor:
{
- char *array, *item;
+ char *array;
+ const char *item;
ip = pc + 1;
t1 = pp_pop();
array = t1->pp_str;
m = ip->forloop_cond->array_var;
if (m->type == Node_param_list)
- item = fparms[m->param_cnt];
+ item = func_params[m->param_cnt].param;
else
item = m->vname;
indent(ip->forloop_body->exec_count);
@@ -909,7 +901,7 @@ pp_string_fp(Func_print print_func, FILE *fp, const char *in_str,
efree(s);
}
-#ifdef PROFILING
+
/* just_dump --- dump the profile and function stack and keep going */
static RETSIGTYPE
@@ -933,7 +925,6 @@ dump_and_exit(int signum)
exit(EXIT_FAILURE);
}
-#endif
/* dump_prog --- dump the program */
@@ -1211,13 +1202,20 @@ pp_string(const char *in_str, size_t len, int delim)
/* pp_number --- pretty format a number */
char *
-pp_number(AWKNUM d)
+pp_number(NODE *n)
{
#define PP_PRECISION 6
char *str;
emalloc(str, char *, PP_PRECISION + 10, "pp_number");
- sprintf(str, "%0.*g", PP_PRECISION, d);
+#ifdef HAVE_MPFR
+ if (is_mpg_float(n))
+ mpfr_sprintf(str, "%0.*R*g", PP_PRECISION, ROUND_MODE, n->mpg_numbr);
+ else if (is_mpg_integer(n))
+ mpfr_sprintf(str, "%Zd", n->mpg_i);
+ else
+#endif
+ sprintf(str, "%0.*g", PP_PRECISION, n->numbr);
return str;
#undef PP_PRECISION
}
@@ -1228,7 +1226,7 @@ char *
pp_node(NODE *n)
{
if ((n->flags & NUMBER) != 0)
- return pp_number(n->numbr);
+ return pp_number(n);
return pp_string(n->stptr, n->stlen, '"');
}
@@ -1321,9 +1319,8 @@ int
pp_func(INSTRUCTION *pc, void *data ATTRIBUTE_UNUSED)
{
int j;
- char **pnames;
- NODE *f;
static int first = TRUE;
+ NODE *func;
int pcount;
if (first) {
@@ -1331,15 +1328,14 @@ pp_func(INSTRUCTION *pc, void *data ATTRIBUTE_UNUSED)
fprintf(prof_fp, _("\n\t# Functions, listed alphabetically\n"));
}
- f = pc->func_body;
+ func = pc->func_body;
fprintf(prof_fp, "\n");
indent(pc->nexti->exec_count);
- fprintf(prof_fp, "%s %s(", op2str(Op_K_function), f->lnode->param);
- pnames = f->parmlist;
- fparms = pnames;
- pcount = f->lnode->param_cnt;
+ fprintf(prof_fp, "%s %s(", op2str(Op_K_function), func->vname);
+ pcount = func->param_cnt;
+ func_params = func->fparms;
for (j = 0; j < pcount; j++) {
- fprintf(prof_fp, "%s", pnames[j]);
+ fprintf(prof_fp, "%s", func_params[j].param);
if (j < pcount - 1)
fprintf(prof_fp, ", ");
}
diff --git a/profile_p.c b/profile_p.c
deleted file mode 100644
index 97edd367..00000000
--- a/profile_p.c
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * profile_p.c - compile profile.c with profiling turned on.
- */
-
-/*
- * Copyright (C) 2001 the Free Software Foundation, Inc.
- *
- * This file is part of GAWK, the GNU implementation of the
- * AWK Programming Language.
- *
- * GAWK is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 3 of the License, or
- * (at your option) any later version.
- *
- * GAWK is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
- */
-
-#define PROFILING 1
-#include "profile.c"
diff --git a/re.c b/re.c
index 9be46d96..f3256a1c 100644
--- a/re.c
+++ b/re.c
@@ -33,6 +33,7 @@ static void check_bracket_exp(char *s, size_t len);
Regexp *
make_regexp(const char *s, size_t len, int ignorecase, int dfa, int canfatal)
{
+ static char metas[] = ".*+(){}[]|?^$\\";
Regexp *rp;
const char *rerr;
const char *src = s;
@@ -46,6 +47,7 @@ make_regexp(const char *s, size_t len, int ignorecase, int dfa, int canfatal)
int has_anchor = FALSE;
int may_have_range = 0;
reg_syntax_t dfa_syn;
+ int i;
/*
* The number of bytes in the current multibyte character.
@@ -90,11 +92,11 @@ make_regexp(const char *s, size_t len, int ignorecase, int dfa, int canfatal)
/* The previous byte is a singlebyte character, or last byte
of a multibyte character. We check the next character. */
is_multibyte = mbrlen(src, end - src, &mbs);
- if ( (is_multibyte == 1)
- || (is_multibyte == (size_t) -1)
- || (is_multibyte == (size_t) -2
- || (is_multibyte == 0))) {
- /* We treat it as a singlebyte character. */
+ if ( is_multibyte == 1
+ || is_multibyte == (size_t) -1
+ || is_multibyte == (size_t) -2
+ || is_multibyte == 0) {
+ /* We treat it as a single-byte character. */
is_multibyte = 0;
}
}
@@ -233,6 +235,21 @@ make_regexp(const char *s, size_t len, int ignorecase, int dfa, int canfatal)
} else
rp->dfa = FALSE;
rp->has_anchor = has_anchor;
+
+ /* Additional flags that help with RS as regexp. */
+ for (i = 0; i < len; i++) {
+ if (strchr(metas, buf[i]) != NULL) {
+ rp->has_meta = TRUE;
+ break;
+ }
+ }
+
+ for (i = len - 1; i >= 0; i--) {
+ if (strchr("*+|?", buf[i]) != NULL) {
+ rp->maybe_long = TRUE;
+ break;
+ }
+ }
return rp;
}
@@ -422,17 +439,12 @@ avoid_dfa(NODE *re, char *str, size_t len)
int
reisstring(const char *text, size_t len, Regexp *re, const char *buf)
{
- static char metas[] = ".*+(){}[]|?^$\\";
- int i;
int res;
const char *matched;
- /* simple checking for has meta characters in re */
- for (i = 0; i < len; i++) {
- if (strchr(metas, text[i]) != NULL) {
- return FALSE; /* give up early, can't be string match */
- }
- }
+ /* simple checking for meta characters in re */
+ if (re->has_meta)
+ return FALSE; /* give up early, can't be string match */
/* make accessable to gdb */
matched = &buf[RESTART(re, buf)];
@@ -442,20 +454,6 @@ reisstring(const char *text, size_t len, Regexp *re, const char *buf)
return res;
}
-/* remaybelong --- return TRUE if the RE contains * ? | + */
-
-int
-remaybelong(const char *text, size_t len)
-{
- while (len--) {
- if (strchr("*+|?", *text++) != NULL) {
- return TRUE;
- }
- }
-
- return FALSE;
-}
-
/* reflags2str --- make a regex flags value readable */
const char *
diff --git a/str_array.c b/str_array.c
new file mode 100644
index 00000000..1b3a33f1
--- /dev/null
+++ b/str_array.c
@@ -0,0 +1,731 @@
+/*
+ * str_array.c - routines for associative arrays of string indices.
+ */
+
+/*
+ * Copyright (C) 1986, 1988, 1989, 1991-2011 the Free Software Foundation, Inc.
+ *
+ * This file is part of GAWK, the GNU implementation of the
+ * AWK Programming Language.
+ *
+ * GAWK is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * GAWK is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
+ */
+
+#include "awk.h"
+
+/*
+ * Tree walks (``for (iggy in foo)'') and array deletions use expensive
+ * linear searching. So what we do is start out with small arrays and
+ * grow them as needed, so that our arrays are hopefully small enough,
+ * most of the time, that they're pretty full and we're not looking at
+ * wasted space.
+ *
+ * The decision is made to grow the array if the average chain length is
+ * ``too big''. This is defined as the total number of entries in the table
+ * divided by the size of the array being greater than some constant.
+ *
+ * 11/2002: We make the constant a variable, so that it can be tweaked
+ * via environment variable.
+ * 11/2002: Modern machines are bigger, cut this down from 10.
+ */
+
+static size_t STR_CHAIN_MAX = 2;
+
+extern FILE *output_fp;
+extern void indent(int indent_level);
+
+static NODE **str_array_init(NODE *symbol, NODE *subs);
+static NODE **str_lookup(NODE *symbol, NODE *subs);
+static NODE **str_exists(NODE *symbol, NODE *subs);
+static NODE **str_clear(NODE *symbol, NODE *subs);
+static NODE **str_remove(NODE *symbol, NODE *subs);
+static NODE **str_list(NODE *symbol, NODE *subs);
+static NODE **str_copy(NODE *symbol, NODE *newsymb);
+static NODE **str_dump(NODE *symbol, NODE *ndump);
+
+array_ptr str_array_func[] = {
+ str_array_init,
+ (array_ptr) 0,
+ str_lookup,
+ str_exists,
+ str_clear,
+ str_remove,
+ str_list,
+ str_copy,
+ str_dump,
+};
+
+static inline NODE **str_find(NODE *symbol, NODE *s1, size_t code1, unsigned long hash1);
+static void grow_table(NODE *symbol);
+
+static unsigned long gst_hash_string(const char *str, size_t len, unsigned long hsize, size_t *code);
+static unsigned long scramble(unsigned long x);
+static unsigned long awk_hash(const char *s, size_t len, unsigned long hsize, size_t *code);
+
+unsigned long (*hash)(const char *s, size_t len, unsigned long hsize, size_t *code) = awk_hash;
+
+
+/* str_array_init --- check relevant environment variables */
+
+static NODE **
+str_array_init(NODE *symbol ATTRIBUTE_UNUSED, NODE *subs ATTRIBUTE_UNUSED)
+{
+ long newval;
+ const char *val;
+
+ if ((newval = getenv_long("STR_CHAIN_MAX")) > 0)
+ STR_CHAIN_MAX = newval;
+ if ((val = getenv("AWK_HASH")) != NULL && strcmp(val, "gst") == 0)
+ hash = gst_hash_string;
+ return (NODE **) ! NULL;
+}
+
+
+/*
+ * assoc_lookup:
+ * Find SYMBOL[SUBS] in the assoc array. Install it with value "" if it
+ * isn't there. Returns a pointer ala get_lhs to where its value is stored.
+ *
+ * SYMBOL is the address of the node (or other pointer) being dereferenced.
+ * SUBS is a number or string used as the subscript.
+ */
+
+static NODE **
+str_lookup(NODE *symbol, NODE *subs)
+{
+ unsigned long hash1;
+ NODE **lhs;
+ BUCKET *b;
+ size_t code1;
+
+ subs = force_string(subs);
+
+ if (symbol->buckets == NULL)
+ grow_table(symbol);
+ hash1 = hash(subs->stptr, subs->stlen,
+ (unsigned long) symbol->array_size, & code1);
+ if ((lhs = str_find(symbol, subs, code1, hash1)) != NULL)
+ return lhs;
+
+ /* It's not there, install it. */
+ /* first see if we would need to grow the array, before installing */
+
+ symbol->table_size++;
+ if ((symbol->flags & ARRAYMAXED) == 0
+ && (symbol->table_size / symbol->array_size) > STR_CHAIN_MAX) {
+ grow_table(symbol);
+ /* have to recompute hash value for new size */
+ hash1 = code1 % (unsigned long) symbol->array_size;
+ }
+
+ if (subs->stfmt != -1) {
+ NODE *tmp;
+
+ /*
+ * Need to freeze this string value --- it must never
+ * change, no matter what happens to the value
+ * that created it or to CONVFMT, etc.; So, get
+ * a private copy.
+ */
+
+ tmp = make_string(subs->stptr, subs->stlen);
+
+ /*
+ * Set the numeric value for the index if it's available. Useful
+ * for numeric sorting by index. Do this only if the numeric
+ * value is available, instead of all the time, since doing it
+ * all the time is a big performance hit for something that may
+ * never be used.
+ */
+
+ if ((subs->flags & (MPFN|MPZN|NUMCUR)) == NUMCUR) {
+ tmp->numbr = subs->numbr;
+ tmp->flags |= NUMCUR;
+ }
+ subs = tmp;
+ } else {
+ /* string value already "frozen" */
+
+ subs = dupnode(subs);
+ }
+
+ getbucket(b);
+ b->ahnext = symbol->buckets[hash1];
+ symbol->buckets[hash1] = b;
+ b->ahname = subs;
+ b->ahname_str = subs->stptr;
+ b->ahname_len = subs->stlen;
+ b->ahvalue = dupnode(Nnull_string);
+ b->ahcode = code1;
+ return & (b->ahvalue);
+}
+
+/* str_exists --- test whether the array element symbol[subs] exists or not,
+ * return pointer to value if it does.
+ */
+
+static NODE **
+str_exists(NODE *symbol, NODE *subs)
+{
+ unsigned long hash1;
+ size_t code1;
+
+ if (symbol->table_size == 0)
+ return NULL;
+
+ subs = force_string(subs);
+ hash1 = hash(subs->stptr, subs->stlen, (unsigned long) symbol->array_size, & code1);
+ return str_find(symbol, subs, code1, hash1);
+}
+
+/* str_clear --- flush all the values in symbol[] */
+
+static NODE **
+str_clear(NODE *symbol, NODE *subs ATTRIBUTE_UNUSED)
+{
+ unsigned long i;
+ BUCKET *b, *next;
+ NODE *r;
+
+ for (i = 0; i < symbol->array_size; i++) {
+ for (b = symbol->buckets[i]; b != NULL; b = next) {
+ next = b->ahnext;
+ r = b->ahvalue;
+ if (r->type == Node_var_array) {
+ assoc_clear(r); /* recursively clear all sub-arrays */
+ efree(r->vname);
+ freenode(r);
+ } else
+ unref(r);
+ unref(b->ahname);
+ freebucket(b);
+ }
+ symbol->buckets[i] = NULL;
+ }
+
+ if (symbol->buckets != NULL)
+ efree(symbol->buckets);
+ init_array(symbol); /* re-initialize symbol */
+ symbol->flags &= ~ARRAYMAXED;
+ return NULL;
+}
+
+
+/* str_remove --- If SUBS is already in the table, remove it. */
+
+static NODE **
+str_remove(NODE *symbol, NODE *subs)
+{
+ unsigned long hash1;
+ BUCKET *b, *prev;
+ NODE *s2;
+ size_t s1_len;
+
+ if (symbol->table_size == 0)
+ return NULL;
+
+ s2 = force_string(subs);
+ hash1 = hash(s2->stptr, s2->stlen, (unsigned long) symbol->array_size, NULL);
+
+ for (b = symbol->buckets[hash1], prev = NULL; b != NULL;
+ prev = b, b = b->ahnext) {
+
+ /* Array indexes are strings; compare as such, always! */
+ s1_len = b->ahname_len;
+
+ if (s1_len != s2->stlen)
+ continue;
+ if (s1_len == 0 /* "" is a valid index */
+ || memcmp(b->ahname_str, s2->stptr, s1_len) == 0) {
+ /* item found */
+
+ unref(b->ahname);
+ if (prev != NULL)
+ prev->ahnext = b->ahnext;
+ else
+ symbol->buckets[hash1] = b->ahnext;
+
+ /* delete bucket */
+ freebucket(b);
+
+ /* one less element in array */
+ if (--symbol->table_size == 0) {
+ if (symbol->buckets != NULL)
+ efree(symbol->buckets);
+ init_array(symbol); /* re-initialize symbol */
+ symbol->flags &= ~ARRAYMAXED;
+ }
+
+ return (NODE **) ! NULL; /* return success */
+ }
+ }
+
+ return NULL;
+}
+
+
+/* str_copy --- duplicate input array "symbol" */
+
+static NODE **
+str_copy(NODE *symbol, NODE *newsymb)
+{
+ BUCKET **old, **new, **pnew;
+ BUCKET *chain, *newchain;
+ unsigned long cursize, i;
+
+ assert(symbol->table_size > 0);
+
+ /* find the current hash size */
+ cursize = symbol->array_size;
+
+ /* allocate new table */
+ emalloc(new, BUCKET **, cursize * sizeof(BUCKET *), "str_copy");
+ memset(new, '\0', cursize * sizeof(BUCKET *));
+
+ old = symbol->buckets;
+
+ for (i = 0; i < cursize; i++) {
+ for (chain = old[i], pnew = & new[i]; chain != NULL;
+ chain = chain->ahnext
+ ) {
+ NODE *oldval, *newsubs;
+
+ getbucket(newchain);
+
+ /*
+ * copy the corresponding name and
+ * value from the original input list
+ */
+
+ newsubs = newchain->ahname = dupnode(chain->ahname);
+ newchain->ahname_str = newsubs->stptr;
+ newchain->ahname_len = newsubs->stlen;
+
+ oldval = chain->ahvalue;
+ if (oldval->type == Node_val)
+ newchain->ahvalue = dupnode(oldval);
+ else {
+ NODE *r;
+
+ r = make_array();
+ r->vname = estrdup(oldval->vname, strlen(oldval->vname));
+ r->parent_array = newsymb;
+ newchain->ahvalue = assoc_copy(oldval, r);
+ }
+ newchain->ahcode = chain->ahcode;
+
+ *pnew = newchain;
+ pnew = & newchain->ahnext;
+ }
+ }
+
+ newsymb->table_size = symbol->table_size;
+ newsymb->buckets = new;
+ newsymb->array_size = cursize;
+ newsymb->flags = symbol->flags;
+ return NULL;
+}
+
+
+/* str_list --- return a list of array items */
+
+static NODE**
+str_list(NODE *symbol, NODE *t)
+{
+ NODE **list;
+ NODE *subs, *val;
+ BUCKET *b;
+ unsigned long num_elems, list_size, i, k = 0;
+ int elem_size = 1;
+
+ if (symbol->table_size == 0)
+ return NULL;
+
+ if ((t->flags & (AINDEX|AVALUE)) == (AINDEX|AVALUE))
+ elem_size = 2;
+
+ /* allocate space for array */
+ num_elems = symbol->table_size;
+ if ((t->flags & (AINDEX|AVALUE|ADELETE)) == (AINDEX|ADELETE))
+ num_elems = 1;
+ list_size = elem_size * num_elems;
+
+ emalloc(list, NODE **, list_size * sizeof(NODE *), "str_list");
+
+ /* populate it */
+
+ for (i = 0; i < symbol->array_size; i++) {
+ for (b = symbol->buckets[i]; b != NULL; b = b->ahnext) {
+ /* index */
+ subs = b->ahname;
+ if (t->flags & AINUM)
+ (void) force_number(subs);
+ list[k++] = dupnode(subs);
+
+ /* value */
+ if (t->flags & AVALUE) {
+ val = b->ahvalue;
+ if (val->type == Node_val) {
+ if ((t->flags & AVNUM) != 0)
+ (void) force_number(val);
+ else if ((t->flags & AVSTR) != 0)
+ val = force_string(val);
+ }
+ list[k++] = val;
+ }
+ if (k >= list_size)
+ return list;
+ }
+ }
+ return list;
+}
+
+
+/* str_kilobytes --- calculate memory consumption of the assoc array */
+
+AWKNUM
+str_kilobytes(NODE *symbol)
+{
+ unsigned long bucket_cnt;
+ AWKNUM kb;
+
+ bucket_cnt = symbol->table_size;
+
+ /* This does not include extra memory for indices with stfmt != -1 */
+ kb = (((AWKNUM) bucket_cnt) * sizeof (BUCKET) +
+ ((AWKNUM) symbol->array_size) * sizeof (BUCKET *)) / 1024.0;
+ return kb;
+}
+
+
+/* str_dump --- dump array info */
+
+static NODE **
+str_dump(NODE *symbol, NODE *ndump)
+{
+#define HCNT 31
+
+ int indent_level;
+ unsigned long i, bucket_cnt;
+ BUCKET *b;
+ static size_t hash_dist[HCNT + 1];
+
+ indent_level = ndump->alevel;
+
+ if ((symbol->flags & XARRAY) == 0)
+ fprintf(output_fp, "%s `%s'\n",
+ (symbol->parent_array == NULL) ? "array" : "sub-array",
+ array_vname(symbol));
+ indent_level++;
+ indent(indent_level);
+ fprintf(output_fp, "array_func: str_array_func\n");
+ if (symbol->flags != 0) {
+ indent(indent_level);
+ fprintf(output_fp, "flags: %s\n", flags2str(symbol->flags));
+ }
+ indent(indent_level);
+ fprintf(output_fp, "STR_CHAIN_MAX: %lu\n", (unsigned long) STR_CHAIN_MAX);
+ indent(indent_level);
+ fprintf(output_fp, "array_size: %lu\n", (unsigned long) symbol->array_size);
+ indent(indent_level);
+ fprintf(output_fp, "table_size: %lu\n", (unsigned long) symbol->table_size);
+ indent(indent_level);
+ fprintf(output_fp, "Avg # of items per chain: %.2g\n",
+ ((AWKNUM) symbol->table_size) / symbol->array_size);
+
+ indent(indent_level);
+ fprintf(output_fp, "memory: %.2g kB\n", str_kilobytes(symbol));
+
+ /* hash value distribution */
+
+ memset(hash_dist, '\0', (HCNT + 1) * sizeof(size_t));
+ for (i = 0; i < symbol->array_size; i++) {
+ bucket_cnt = 0;
+ for (b = symbol->buckets[i]; b != NULL; b = b->ahnext)
+ bucket_cnt++;
+ if (bucket_cnt >= HCNT)
+ bucket_cnt = HCNT;
+ hash_dist[bucket_cnt]++;
+ }
+
+ indent(indent_level);
+ fprintf(output_fp, "Hash distribution:\n");
+ indent_level++;
+ for (i = 0; i <= HCNT; i++) {
+ if (hash_dist[i] > 0) {
+ indent(indent_level);
+ if (i == HCNT)
+ fprintf(output_fp, "[>=%lu]:%lu\n",
+ (unsigned long) HCNT, (unsigned long) hash_dist[i]);
+ else
+ fprintf(output_fp, "[%lu]:%lu\n",
+ (unsigned long) i, (unsigned long) hash_dist[i]);
+ }
+ }
+ indent_level--;
+
+ /* dump elements */
+
+ if (ndump->adepth >= 0) {
+ const char *aname;
+
+ fprintf(output_fp, "\n");
+ aname = make_aname(symbol);
+ for (i = 0; i < symbol->array_size; i++) {
+ for (b = symbol->buckets[i]; b != NULL; b = b->ahnext)
+ assoc_info(b->ahname, b->ahvalue, ndump, aname);
+ }
+ }
+
+ return NULL;
+
+#undef HCNT
+}
+
+
+/* awk_hash --- calculate the hash function of the string in subs */
+
+static unsigned long
+awk_hash(const char *s, size_t len, unsigned long hsize, size_t *code)
+{
+ unsigned long h = 0;
+ unsigned long htmp;
+
+ /*
+ * Ozan Yigit's original sdbm hash, copied from Margo Seltzers
+ * db package.
+ *
+ * This is INCREDIBLY ugly, but fast. We break the string up into
+ * 8 byte units. On the first time through the loop we get the
+ * "leftover bytes" (strlen % 8). On every other iteration, we
+ * perform 8 HASHC's so we handle all 8 bytes. Essentially, this
+ * saves us 7 cmp & branch instructions. If this routine is
+ * heavily used enough, it's worth the ugly coding.
+ */
+
+ /*
+ * Even more speed:
+ * #define HASHC h = *s++ + 65599 * h
+ * Because 65599 = pow(2, 6) + pow(2, 16) - 1 we multiply by shifts
+ *
+ * 4/2011: Force the results to 32 bits, to get the same
+ * result on both 32- and 64-bit systems. This may be a
+ * bad idea.
+ */
+#define HASHC htmp = (h << 6); \
+ h = *s++ + htmp + (htmp << 10) - h ; \
+ htmp &= 0xFFFFFFFF; \
+ h &= 0xFFFFFFFF
+
+ h = 0;
+
+ /* "Duff's Device" */
+ if (len > 0) {
+ size_t loop = (len + 8 - 1) >> 3;
+
+ switch (len & (8 - 1)) {
+ case 0:
+ do { /* All fall throughs */
+ HASHC;
+ case 7: HASHC;
+ case 6: HASHC;
+ case 5: HASHC;
+ case 4: HASHC;
+ case 3: HASHC;
+ case 2: HASHC;
+ case 1: HASHC;
+ } while (--loop);
+ }
+ }
+
+ if (code != NULL)
+ *code = h;
+
+ if (h >= hsize)
+ h %= hsize;
+ return h;
+}
+
+
+/* str_find --- locate symbol[subs] */
+
+static inline NODE **
+str_find(NODE *symbol, NODE *s1, size_t code1, unsigned long hash1)
+{
+ BUCKET *b;
+ size_t s2_len;
+
+ for (b = symbol->buckets[hash1]; b != NULL; b = b->ahnext) {
+ /*
+ * This used to use cmp_nodes() here. That's wrong.
+ * Array indexes are strings; compare as such, always!
+ */
+ s2_len = b->ahname_len;
+
+ if (code1 == b->ahcode
+ && s1->stlen == s2_len
+ && (s2_len == 0 /* "" is a valid index */
+ || memcmp(s1->stptr, b->ahname_str, s2_len) == 0)
+ )
+ return & (b->ahvalue);
+ }
+ return NULL;
+}
+
+
+/* grow_table --- grow a hash table */
+
+static void
+grow_table(NODE *symbol)
+{
+ BUCKET **old, **new;
+ BUCKET *chain, *next;
+ int i, j;
+ unsigned long oldsize, newsize, k;
+ unsigned long hash1;
+
+ /*
+ * This is an array of primes. We grow the table by an order of
+ * magnitude each time (not just doubling) so that growing is a
+ * rare operation. We expect, on average, that it won't happen
+ * more than twice. The final size is also chosen to be small
+ * enough so that MS-DOG mallocs can handle it. When things are
+ * very large (> 8K), we just double more or less, instead of
+ * just jumping from 8K to 64K.
+ */
+
+ static const unsigned long sizes[] = {
+ 13, 127, 1021, 8191, 16381, 32749, 65497,
+ 131101, 262147, 524309, 1048583, 2097169,
+ 4194319, 8388617, 16777259, 33554467,
+ 67108879, 134217757, 268435459, 536870923,
+ 1073741827
+ };
+
+ /* find next biggest hash size */
+ newsize = oldsize = symbol->array_size;
+
+ for (i = 0, j = sizeof(sizes)/sizeof(sizes[0]); i < j; i++) {
+ if (oldsize < sizes[i]) {
+ newsize = sizes[i];
+ break;
+ }
+ }
+ if (newsize == oldsize) { /* table already at max (!) */
+ symbol->flags |= ARRAYMAXED;
+ return;
+ }
+
+ /* allocate new table */
+ emalloc(new, BUCKET **, newsize * sizeof(BUCKET *), "grow_table");
+ memset(new, '\0', newsize * sizeof(BUCKET *));
+
+ old = symbol->buckets;
+ symbol->buckets = new;
+ symbol->array_size = newsize;
+
+ /* brand new hash table, set things up and return */
+ if (old == NULL) {
+ symbol->table_size = 0;
+ return;
+ }
+
+ /* old hash table there, move stuff to new, free old */
+
+ /*
+ * note that symbol->table_size does not change if an old array,
+ * and is explicitly set to 0 if a new one.
+ */
+
+ for (k = 0; k < oldsize; k++) {
+ for (chain = old[k]; chain != NULL; chain = next) {
+ next = chain->ahnext;
+ hash1 = chain->ahcode % newsize;
+
+ /* remove from old list, add to new */
+ chain->ahnext = new[hash1];
+ new[hash1] = chain;
+ }
+ }
+ efree(old);
+}
+
+
+
+/*
+From bonzini@gnu.org Mon Oct 28 16:05:26 2002
+Date: Mon, 28 Oct 2002 13:33:03 +0100
+From: Paolo Bonzini <bonzini@gnu.org>
+To: arnold@skeeve.com
+Subject: Hash function
+Message-ID: <20021028123303.GA6832@biancaneve>
+
+Here is the hash function I'm using in GNU Smalltalk. The scrambling is
+needed if you use powers of two as the table sizes. If you use primes it
+is not needed.
+
+To use double-hashing with power-of-two size, you should use the
+_gst_hash_string(str, len) as the primary hash and
+scramble(_gst_hash_string (str, len)) | 1 as the secondary hash.
+
+Paolo
+
+*/
+/*
+ * ADR: Slightly modified to work w/in the context of gawk.
+ */
+
+static unsigned long
+gst_hash_string(const char *str, size_t len, unsigned long hsize, size_t *code)
+{
+ unsigned long hashVal = 1497032417; /* arbitrary value */
+ unsigned long ret;
+
+ while (len--) {
+ hashVal += *str++;
+ hashVal += (hashVal << 10);
+ hashVal ^= (hashVal >> 6);
+ }
+
+ ret = scramble(hashVal);
+
+ if (code != NULL)
+ *code = ret;
+
+ if (ret >= hsize)
+ ret %= hsize;
+
+ return ret;
+}
+
+static unsigned long
+scramble(unsigned long x)
+{
+ if (sizeof(long) == 4) {
+ int y = ~x;
+
+ x += (y << 10) | (y >> 22);
+ x += (x << 6) | (x >> 26);
+ x -= (x << 16) | (x >> 16);
+ } else {
+ x ^= (~x) >> 31;
+ x += (x << 21) | (x >> 11);
+ x += (x << 5) | (x >> 27);
+ x += (x << 27) | (x >> 5);
+ x += (x << 31);
+ }
+
+ return x;
+}
diff --git a/symbol.c b/symbol.c
new file mode 100644
index 00000000..57ca7be0
--- /dev/null
+++ b/symbol.c
@@ -0,0 +1,718 @@
+/*
+ * symbol.c - routines for symbol table management and code allocation
+ */
+
+/*
+ * Copyright (C) 1986, 1988, 1989, 1991-2011 the Free Software Foundation, Inc.
+ *
+ * This file is part of GAWK, the GNU implementation of the
+ * AWK Programming Language.
+ *
+ * GAWK is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * GAWK is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
+ */
+
+#include "awk.h"
+
+extern SRCFILE *srcfiles;
+extern INSTRUCTION *rule_list;
+
+#define HASHSIZE 1021
+
+static NODE *variables[HASHSIZE];
+static int func_count; /* total number of functions */
+static int var_count; /* total number of global variables and functions */
+
+static NODE *symbol_list;
+static void (*install_func)(NODE *) = NULL;
+static NODE *make_symbol(char *name, NODETYPE type);
+static NODE *install(char *name, NODE *hp, NODETYPE type);
+static void free_bcpool(INSTRUCTION *pl);
+
+static AWK_CONTEXT *curr_ctxt = NULL;
+static int ctxt_level;
+
+
+/*
+ * install_symbol:
+ * Install a global name in the symbol table, even if it is already there.
+ * Caller must check against redefinition if that is desired.
+ */
+
+NODE *
+install_symbol(char *name, NODETYPE type)
+{
+ return install(name, NULL, type);
+}
+
+
+/* lookup --- find the most recent global or param node for name
+ * installed by install_symbol
+ */
+
+NODE *
+lookup(const char *name)
+{
+ NODE *hp;
+ size_t len;
+ int hash1;
+
+ len = strlen(name);
+ hash1 = hash(name, len, (unsigned long) HASHSIZE, NULL);
+ for (hp = variables[hash1]; hp != NULL; hp = hp->hnext) {
+ if (hp->hlength == len && strncmp(hp->hname, name, len) == 0)
+ return hp->hvalue;
+ }
+ return NULL;
+}
+
+/* make_params --- allocate function parameters for the symbol table */
+
+NODE *
+make_params(char **pnames, int pcount)
+{
+ NODE *hp, *parms;
+ int i;
+
+ if (pcount <= 0 || pnames == NULL)
+ return NULL;
+
+ emalloc(parms, NODE *, pcount * sizeof(NODE), "make_params");
+ memset(parms, '\0', pcount * sizeof(NODE));
+
+ for (i = 0, hp = parms; i < pcount; i++, hp++) {
+ hp->type = Node_param_list;
+ hp->hname = pnames[i]; /* shadows pname and vname */
+ hp->hlength = strlen(pnames[i]);
+ hp->param_cnt = i;
+ hp->hvalue = hp; /* points to itself */
+ }
+
+ return parms;
+}
+
+/* install_params --- install function parameters into the symbol table */
+
+void
+install_params(NODE *func)
+{
+ int i, pcount;
+ NODE *parms;
+
+ if (func == NULL)
+ return;
+ assert(func->type == Node_func);
+ if ((pcount = func->param_cnt) <= 0
+ || (parms = func->fparms) == NULL
+ )
+ return;
+ for (i = 0; i < pcount; i++)
+ (void) install(NULL, parms + i, Node_param_list);
+}
+
+
+/*
+ * remove_params --- remove function parameters out of the symbol table.
+ */
+
+void
+remove_params(NODE *func)
+{
+ NODE *parms, *p, *prev, *n;
+ int i, pcount, hash1;
+
+ if (func == NULL)
+ return;
+ assert(func->type == Node_func);
+ if ((pcount = func->param_cnt) <= 0
+ || (parms = func->fparms) == NULL
+ )
+ return;
+
+ for (i = pcount - 1; i >= 0; i--) {
+ p = parms + i;
+ hash1 = p->hcode;
+ if (hash1 < 0 || hash1 >= HASHSIZE)
+ continue;
+ for (prev = NULL, n = variables[hash1]; n != NULL;
+ prev = n, n = n->hnext) {
+ if (n == p)
+ break;
+ }
+ if (n == NULL)
+ continue;
+ if (prev == NULL)
+ variables[hash1] = n->hnext; /* param at the head of the chain */
+ else
+ prev->hnext = n->hnext; /* param not at the head */
+ }
+}
+
+
+/* remove_symbol --- remove a symbol from the symbol table */
+
+NODE *
+remove_symbol(NODE *r)
+{
+ NODE *prev, *hp;
+ int hash1;
+
+ hash1 = hash(r->vname, strlen(r->vname), (unsigned long) HASHSIZE, NULL);
+ for (prev = NULL, hp = variables[hash1]; hp != NULL;
+ prev = hp, hp = hp->hnext) {
+ if (hp->hvalue == r)
+ break;
+ }
+
+ if (hp == NULL)
+ return NULL;
+ assert(hp->hcode == hash1);
+
+ if (prev == NULL)
+ variables[hash1] = hp->hnext; /* symbol at the head of chain */
+ else
+ prev->hnext = hp->hnext; /* symbol not at the head */
+
+ if (r->type == Node_param_list)
+ return r; /* r == hp */
+ if (r->type == Node_func)
+ func_count--;
+ if (r->type != Node_ext_func)
+ var_count--;
+ freenode(hp);
+ return r;
+}
+
+
+/* destroy_symbol --- remove a symbol from symbol table
+* and free all associated memory.
+*/
+
+void
+destroy_symbol(NODE *r)
+{
+ r = remove_symbol(r);
+ if (r == NULL)
+ return;
+
+ switch (r->type) {
+ case Node_func:
+ if (r->param_cnt > 0) {
+ NODE *n;
+ int i;
+ int pcount = r->param_cnt;
+
+ /* function parameters of type Node_param_list */
+ for (i = 0; i < pcount; i++) {
+ n = r->fparms + i;
+ efree(n->param);
+ }
+ efree(r->fparms);
+ }
+ break;
+
+ case Node_ext_func:
+ bcfree(r->code_ptr);
+ break;
+
+ case Node_var_array:
+ assoc_clear(r);
+ break;
+
+ case Node_var:
+ unref(r->var_value);
+ break;
+
+ default:
+ /* Node_param_list -- YYABORT */
+ return;
+ }
+
+ efree(r->vname);
+ freenode(r);
+}
+
+
+/* make_symbol --- allocates a global symbol for the symbol table. */
+
+static NODE *
+make_symbol(char *name, NODETYPE type)
+{
+ NODE *hp, *r;
+
+ getnode(hp);
+ hp->type = Node_hashnode;
+ hp->hlength = strlen(name);
+ hp->hname = name;
+ getnode(r);
+ memset(r, '\0', sizeof(NODE));
+ hp->hvalue = r;
+ if (type == Node_var_array)
+ init_array(r);
+ else if (type == Node_var)
+ r->var_value = dupnode(Nnull_string);
+ r->vname = name;
+ r->type = type;
+ return hp;
+}
+
+/* install --- install a global name or function parameter in the symbol table */
+
+static NODE *
+install(char *name, NODE *hp, NODETYPE type)
+{
+ int hash1;
+ NODE *r;
+
+ if (hp == NULL) {
+ /* global symbol */
+ hp = make_symbol(name, type);
+ if (type == Node_func)
+ func_count++;
+ if (type != Node_ext_func)
+ var_count++; /* total, includes Node_func */
+ }
+
+ r = hp->hvalue;
+ hash1 = hash(hp->hname, hp->hlength, (unsigned long) HASHSIZE, NULL);
+ hp->hcode = hash1;
+ hp->hnext = variables[hash1];
+ variables[hash1] = hp;
+
+ if (install_func)
+ (*install_func)(r);
+
+ return r;
+}
+
+
+/* comp_symbol --- compare two (variable or function) names */
+
+static int
+comp_symbol(const void *v1, const void *v2)
+{
+ const NODE *const *npp1, *const *npp2;
+ const NODE *n1, *n2;
+
+ npp1 = (const NODE *const *) v1;
+ npp2 = (const NODE *const *) v2;
+ n1 = *npp1;
+ n2 = *npp2;
+
+ return strcmp(n1->vname, n2->vname);
+}
+
+
+typedef enum { FUNCTION = 1, VARIABLE } SYMBOL_TYPE;
+
+/* get_symbols --- return a list of optionally sorted symbols */
+
+static NODE **
+get_symbols(SYMBOL_TYPE what, int sort)
+{
+ int i;
+ NODE **table;
+ NODE *hp, *r;
+ long j, count = 0;
+
+ if (what == FUNCTION)
+ count = func_count;
+ else /* if (what == VARIABLE) */
+ count = var_count;
+
+ emalloc(table, NODE **, (count + 1) * sizeof(NODE *), "symbol_list");
+ if (what == VARIABLE)
+ update_global_values();
+
+ for (i = j = 0; i < HASHSIZE; i++)
+ for (hp = variables[i]; hp != NULL; hp = hp->hnext) {
+ if (hp->type != Node_hashnode)
+ continue;
+ r = hp->hvalue;
+ if (r->type == Node_ext_func)
+ continue;
+ if (what == FUNCTION && r->type == Node_func)
+ table[j++] = r;
+ else if (what == VARIABLE)
+ table[j++] = r;
+ }
+
+ if (sort && count > 1)
+ qsort(table, count, sizeof(NODE *), comp_symbol); /* Shazzam! */
+ table[count] = NULL; /* null terminate the list */
+ return table;
+}
+
+
+/* variable_list --- list of global variables */
+
+NODE **
+variable_list()
+{
+ return get_symbols(VARIABLE, TRUE);
+}
+
+/* function_list --- list of functions */
+
+NODE **
+function_list(int sort)
+{
+ return get_symbols(FUNCTION, sort);
+}
+
+/* print_vars --- print names and values of global variables */
+
+void
+print_vars(NODE **table, int (*print_func)(FILE *, const char *, ...), FILE *fp)
+{
+ int i;
+ NODE *r;
+
+ assert(table != NULL);
+
+ for (i = 0; (r = table[i]) != NULL; i++) {
+ if (r->type == Node_func || r->type == Node_ext_func)
+ continue;
+ print_func(fp, "%s: ", r->vname);
+ if (r->type == Node_var_array)
+ print_func(fp, "array, %ld elements\n", r->table_size);
+ else if (r->type == Node_var_new)
+ print_func(fp, "untyped variable\n");
+ else if (r->type == Node_var)
+ valinfo(r->var_value, print_func, fp);
+ }
+}
+
+
+/* foreach_func --- execute given function for each awk function in table. */
+
+int
+foreach_func(NODE **table, int (*pfunc)(INSTRUCTION *, void *), void *data)
+{
+ int i;
+ NODE *r;
+ int ret = 0;
+
+ assert(table != NULL);
+
+ for (i = 0; (r = table[i]) != NULL; i++) {
+ if ((ret = pfunc(r->code_ptr, data)) != 0)
+ break;
+ }
+ return ret;
+}
+
+/* release_all_vars --- free all variable memory */
+
+void
+release_all_vars()
+{
+ int i;
+ NODE *hp, *r, *next;
+
+ for (i = 0; i < HASHSIZE; i++)
+ for (hp = variables[i]; hp != NULL; hp = next) {
+ next = hp->hnext;
+ if (hp->type != Node_hashnode)
+ continue;
+ r = hp->hvalue;
+ if (r->type == Node_func || r->type == Node_ext_func)
+ continue;
+ if (r->type == Node_var_array)
+ assoc_clear(r);
+ else if (r->type == Node_var)
+ unref(r->var_value);
+ efree(r->vname);
+ freenode(r);
+ freenode(hp);
+ }
+}
+
+
+/* append_symbol --- append symbol to the list of symbols
+ * installed in the symbol table.
+ */
+
+void
+append_symbol(NODE *r)
+{
+ NODE *hp;
+
+ getnode(hp);
+ hp->lnode = r;
+ hp->rnode = symbol_list->rnode;
+ symbol_list->rnode = hp;
+}
+
+/* release_symbol --- free symbol list and optionally remove symbol from symbol table */
+
+void
+release_symbols(NODE *symlist, int keep_globals)
+{
+ NODE *hp, *next;
+
+ for (hp = symlist->rnode; hp != NULL; hp = next) {
+ if (! keep_globals) {
+ /* destroys globals, function, and params
+ * if still in symbol table
+ */
+ destroy_symbol(hp->lnode);
+ }
+ next = hp->rnode;
+ freenode(hp);
+ }
+ symlist->rnode = NULL;
+}
+
+#define pool_size d.dl
+#define freei x.xi
+static INSTRUCTION *pool_list;
+
+/* INSTR_CHUNK must be > largest code size (3) */
+#define INSTR_CHUNK 127
+
+/* bcfree --- deallocate instruction */
+
+void
+bcfree(INSTRUCTION *cp)
+{
+ cp->opcode = 0;
+ cp->nexti = pool_list->freei;
+ pool_list->freei = cp;
+}
+
+/* bcalloc --- allocate a new instruction */
+
+INSTRUCTION *
+bcalloc(OPCODE op, int size, int srcline)
+{
+ INSTRUCTION *cp;
+
+ if (size > 1) {
+ /* wide instructions Op_rule, Op_func_call .. */
+ emalloc(cp, INSTRUCTION *, (size + 1) * sizeof(INSTRUCTION), "bcalloc");
+ cp->pool_size = size;
+ cp->nexti = pool_list->nexti;
+ pool_list->nexti = cp++;
+ } else {
+ INSTRUCTION *pool;
+
+ pool = pool_list->freei;
+ if (pool == NULL) {
+ INSTRUCTION *last;
+ emalloc(cp, INSTRUCTION *, (INSTR_CHUNK + 1) * sizeof(INSTRUCTION), "bcalloc");
+
+ cp->pool_size = INSTR_CHUNK;
+ cp->nexti = pool_list->nexti;
+ pool_list->nexti = cp;
+ pool = ++cp;
+ last = &pool[INSTR_CHUNK - 1];
+ for (; cp <= last; cp++) {
+ cp->opcode = 0;
+ cp->nexti = cp + 1;
+ }
+ --cp;
+ cp->nexti = NULL;
+ }
+ cp = pool;
+ pool_list->freei = cp->nexti;
+ }
+
+ memset(cp, 0, size * sizeof(INSTRUCTION));
+ cp->opcode = op;
+ cp->source_line = srcline;
+ return cp;
+}
+
+/* new_context --- create a new execution context. */
+
+AWK_CONTEXT *
+new_context()
+{
+ AWK_CONTEXT *ctxt;
+
+ emalloc(ctxt, AWK_CONTEXT *, sizeof(AWK_CONTEXT), "new_context");
+ memset(ctxt, 0, sizeof(AWK_CONTEXT));
+ ctxt->srcfiles.next = ctxt->srcfiles.prev = & ctxt->srcfiles;
+ ctxt->rule_list.opcode = Op_list;
+ ctxt->rule_list.lasti = & ctxt->rule_list;
+ return ctxt;
+}
+
+/* set_context --- change current execution context. */
+
+static void
+set_context(AWK_CONTEXT *ctxt)
+{
+ pool_list = & ctxt->pools;
+ symbol_list = & ctxt->symbols;
+ srcfiles = & ctxt->srcfiles;
+ rule_list = & ctxt->rule_list;
+ install_func = ctxt->install_func;
+ curr_ctxt = ctxt;
+}
+
+/*
+ * push_context:
+ *
+ * Switch to the given context after saving the current one. The set
+ * of active execution contexts forms a stack; the global or main context
+ * is at the bottom of the stack.
+ */
+
+void
+push_context(AWK_CONTEXT *ctxt)
+{
+ ctxt->prev = curr_ctxt;
+ /* save current source and sourceline */
+ if (curr_ctxt != NULL) {
+ curr_ctxt->sourceline = sourceline;
+ curr_ctxt->source = source;
+ }
+ sourceline = 0;
+ source = NULL;
+ set_context(ctxt);
+ ctxt_level++;
+}
+
+/* pop_context --- switch to previous execution context. */
+
+void
+pop_context()
+{
+ AWK_CONTEXT *ctxt;
+
+ assert(curr_ctxt != NULL);
+ if (curr_ctxt->prev == NULL)
+ fatal(_("can not pop main context"));
+ ctxt = curr_ctxt->prev;
+ /* restore source and sourceline */
+ sourceline = ctxt->sourceline;
+ source = ctxt->source;
+ set_context(ctxt);
+ ctxt_level--;
+}
+
+/* in_main_context --- are we in the main context ? */
+
+int
+in_main_context()
+{
+ assert(ctxt_level > 0);
+ return (ctxt_level == 1);
+}
+
+/* free_context --- free context structure and related data. */
+
+void
+free_context(AWK_CONTEXT *ctxt, int keep_globals)
+{
+ SRCFILE *s, *sn;
+
+ if (ctxt == NULL)
+ return;
+
+ assert(curr_ctxt != ctxt);
+
+ /* free all code including function codes */
+
+ free_bcpool(& ctxt->pools);
+
+ /* free symbols */
+
+ release_symbols(& ctxt->symbols, keep_globals);
+
+ /* free srcfiles */
+
+ for (s = & ctxt->srcfiles; s != & ctxt->srcfiles; s = sn) {
+ sn = s->next;
+ if (s->stype != SRC_CMDLINE && s->stype != SRC_STDIN)
+ efree(s->fullpath);
+ efree(s->src);
+ efree(s);
+ }
+
+ efree(ctxt);
+}
+
+/* free_bc_internal --- free internal memory of an instruction. */
+
+static void
+free_bc_internal(INSTRUCTION *cp)
+{
+ NODE *m;
+
+ switch(cp->opcode) {
+ case Op_func_call:
+ if (cp->func_name != NULL)
+ efree(cp->func_name);
+ break;
+ case Op_push_re:
+ case Op_match_rec:
+ case Op_match:
+ case Op_nomatch:
+ m = cp->memory;
+ if (m->re_reg != NULL)
+ refree(m->re_reg);
+ if (m->re_exp != NULL)
+ unref(m->re_exp);
+ if (m->re_text != NULL)
+ unref(m->re_text);
+ freenode(m);
+ break;
+ case Op_token:
+ /* token lost during error recovery in yyparse */
+ if (cp->lextok != NULL)
+ efree(cp->lextok);
+ break;
+ case Op_push_i:
+ m = cp->memory;
+ unref(m);
+ break;
+ case Op_store_var:
+ m = cp->initval;
+ if (m != NULL)
+ unref(m);
+ break;
+ case Op_illegal:
+ cant_happen();
+ default:
+ break;
+ }
+}
+
+/* free_bcpool --- free list of instruction memory pools */
+
+static void
+free_bcpool(INSTRUCTION *pl)
+{
+ INSTRUCTION *pool, *tmp;
+
+ for (pool = pl->nexti; pool != NULL; pool = tmp) {
+ INSTRUCTION *cp, *last;
+ long psiz;
+ psiz = pool->pool_size;
+ if (psiz == INSTR_CHUNK)
+ last = pool + psiz;
+ else
+ last = pool + 1;
+ for (cp = pool + 1; cp <= last ; cp++) {
+ if (cp->opcode != 0)
+ free_bc_internal(cp);
+ }
+ tmp = pool->nexti;
+ efree(pool);
+ }
+ memset(pl, 0, sizeof(INSTRUCTION));
+}
diff --git a/test/ChangeLog b/test/ChangeLog
index 535cb9e1..4a2c7b2b 100644
--- a/test/ChangeLog
+++ b/test/ChangeLog
@@ -1,3 +1,27 @@
+2012-04-01 John Haque <j.eh@mchsi.com>
+
+ * Makefile.am (mpfr-test): Add target for manual testing of MPFR
+ and GMP numbers.
+ * mpfrbigint.awk, mpfrexprange.awk, mpfrieee.awk, mpfrnr.awk,
+ mpfrrnd.awk, mpfrsort.awk: New tests.
+ (MPFR_TESTS): Add the new tests.
+ * mpfrnr.in, mpfrbigint.ok, mpfrexprange.ok, mpfrieee.ok, mpfrnr.ok,
+ mpfrrnd.ok, mpfrsort.ok: New files.
+ (AWK): Add AWKFLAGS; useful for testing with 'gawk -M' invocation.
+
+2012-02-28 Arnold D. Robbins <arnold@skeeve.com>
+
+ * fmtspcl-mpfr.ok, fnarydel-mpfr.ok, fnparydl-mpfr.ok,
+ rand-mpfr.ok: New files.
+ * Makefile.am (EXTRA_DIST): Add them.
+ (CHECK_MPFR): New list of files that have MPFR variant .ok file.
+ * Gentests: Deal with MPFR files by modifying the generated
+ comparison command.
+
+2011-12-26 John Haque <j.eh@mchsi.com>
+
+ * badargs.ok: Adjust for new and changed command line options.
+
2012-03-28 Arnold D. Robbins <arnold@skeeve.com>
* 4.0.1: Release tar ball made.
diff --git a/test/Gentests b/test/Gentests
index fc779f00..ae56b8cc 100755
--- a/test/Gentests
+++ b/test/Gentests
@@ -45,6 +45,13 @@ BEGIN {
next
}
+/^CHECK_MPFR *=/,/[^\\]$/ {
+ gsub(/(^CHECK_MPFR *=|\\$)/,"")
+ for (i = 1; i <= NF; i++)
+ mpfr[$i]
+ next
+}
+
/^[[:alpha:]_][[:alnum:]_]*:/ {
# remember all targets from Makefile.am
sub(/:.*/,"")
@@ -91,9 +98,17 @@ function generate(x, s)
delete files[x".in"]
}
- printf "\t@echo %s\n", x
+ printf "\t@echo $@\n"
printf "\t@AWKPATH=$(srcdir) $(AWK) -f $@.awk %s >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@\n", s
- printf "\t@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@\n\n"
+
+ if (x in mpfr) {
+ delete mpfr[x]
+ printf "\t@-if test -z \"$$AWKFLAGS\" ; then $(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ ; else \\\n"
+ printf "\t$(CMP) $(srcdir)/$@-mpfr.ok _$@ && rm -f _$@ ; \\\n"
+ printf "\tfi\n\n"
+ } else {
+ printf "\t@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@\n\n"
+ }
}
END {
diff --git a/test/Makefile.am b/test/Makefile.am
index 911d8dce..54d48397 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -209,6 +209,7 @@ EXTRA_DIST = \
fldchgnf.ok \
fmtspcl.awk \
fmtspcl.tok \
+ fmtspcl-mpfr.ok \
fmttest.awk \
fmttest.ok \
fnamedat.awk \
@@ -217,9 +218,11 @@ EXTRA_DIST = \
fnarray.awk \
fnarray.ok \
fnarray2.awk \
+ fnarray2.in \
fnarray2.ok \
fnarydel.awk \
fnarydel.ok \
+ fnarydel-mpfr.ok \
fnaryscl.awk \
fnaryscl.ok \
fnasgnm.awk \
@@ -229,6 +232,7 @@ EXTRA_DIST = \
fnmisc.ok \
fnparydl.awk \
fnparydl.ok \
+ fnparydl-mpfr.ok \
fpat1.awk \
fpat1.in \
fpat1.ok \
@@ -591,6 +595,7 @@ EXTRA_DIST = \
pty1.ok \
rand.awk \
rand.ok \
+ rand-mpfr.ok \
range1.awk \
range1.in \
range1.ok \
@@ -849,6 +854,8 @@ INET_TESTS = inetdayu inetdayt inetechu inetecht
MACHINE_TESTS = double1 double2 fmtspcl intformat
+MPFR_TESTS = mpfrnr mpfrrnd mpfrieee mpfrexprange mpfrsort mpfrbigint
+
LOCALE_CHARSET_TESTS = \
asort asorti fmttest fnarydel fnparydl lc_num1 mbfw1 \
mbprintf1 mbprintf2 mbprintf3 rebt8b2 rtlenmb sort1 sprintfc
@@ -865,20 +872,23 @@ NEED_LINT_OLD = lintold
FAIL_CODE1 = \
fnarray2 fnmisc gsubasgn mixed1 noparms paramdup synerr1 synerr2 unterm
+# List of files which have .ok versions for MPFR
+CHECK_MPFR = \
+ rand fnarydel fnparydl
+
# List of the files that appear in manual tests or are for reserve testing:
GENTESTS_UNUSED = Makefile.in gtlnbufv.awk printfloat.awk
CMP = cmp
AWKPROG = ../gawk$(EXEEXT)
-PGAWKPROG = ../pgawk$(EXEEXT)
# This business forces the locale to be C for running the tests,
# unless we override it to something else for testing.
#
# This can also be done in individual tests where we wish to
# check things specifically not in the C locale.
-AWK = LC_ALL=$${GAWKLOCALE:-C} LANG=$${GAWKLOCALE:-C} $(AWKPROG)
-PGAWK = LC_ALL=$${GAWKLOCALE:-C} LANG=$${GAWKLOCALE:-C} $(PGAWKPROG)
+AWK = LC_ALL=$${GAWKLOCALE:-C} LANG=$${GAWKLOCALE:-C} $(AWKPROG) $(AWKFLAGS)
+
# Message stuff is to make it a little easier to follow.
# Make the pass-fail last and dependent on others to avoid
@@ -906,6 +916,8 @@ inet: inetmesg $(INET_TESTS)
machine-tests: $(MACHINE_TESTS)
+mpfr-tests: $(MPFR_TESTS)
+
msg::
@echo ''
@echo 'Any output from "cmp" is bad news, although some differences'
@@ -1106,9 +1118,11 @@ fmtspcl.ok: fmtspcl.tok Makefile
@$(AWK) -v "sd=$(srcdir)" 'BEGIN {pnan = sprintf("%g",sqrt(-1)); nnan = sprintf("%g",-sqrt(-1)); pinf = sprintf("%g",-log(0)); ninf = sprintf("%g",log(0))} {sub(/positive_nan/,pnan); sub(/negative_nan/,nnan); sub(/positive_infinity/,pinf); sub(/negative_infinity/,ninf); sub(/fmtspcl/,(sd"/fmtspcl")); print}' < $(srcdir)/fmtspcl.tok > $@ 2>/dev/null
fmtspcl: fmtspcl.ok
- @echo fmtspcl
+ @echo $@
@$(AWK) -f $(srcdir)/fmtspcl.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
- @-$(CMP) $@.ok _$@ && rm -f _$@
+ @-if test -z "$$AWKFLAGS" ; then $(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ ; else \
+ $(CMP) $(srcdir)/$@-mpfr.ok _$@ && rm -f _$@ ; \
+ fi
reint::
@echo $@
@@ -1414,19 +1428,19 @@ dumpvars::
profile1:
@echo $@
- @$(AWK) --profile=ap-$@.out -f $(srcdir)/xref.awk $(srcdir)/dtdgport.awk > _$@.out1
+ @$(AWK) --pretty-print=ap-$@.out -f $(srcdir)/xref.awk $(srcdir)/dtdgport.awk > _$@.out1
@$(AWK) -f ap-$@.out $(srcdir)/dtdgport.awk > _$@.out2 ; rm ap-$@.out
@cmp _$@.out1 _$@.out2 && rm _$@.out[12] || echo EXIT CODE: $$? >>_$@
profile2:
@echo $@
- @$(PGAWK) --profile=ap-$@.out -v sortcmd=sort -f $(srcdir)/xref.awk $(srcdir)/dtdgport.awk > /dev/null
+ @$(AWK) --profile=ap-$@.out -v sortcmd=sort -f $(srcdir)/xref.awk $(srcdir)/dtdgport.awk > /dev/null
@sed 1,2d < ap-$@.out > _$@; rm ap-$@.out
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
profile3:
@echo $@
- @$(PGAWK) --profile=ap-$@.out -f $(srcdir)/$@.awk > /dev/null
+ @$(AWK) --profile=ap-$@.out -f $(srcdir)/$@.awk > /dev/null
@sed 1,2d < ap-$@.out > _$@; rm ap-$@.out
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
@@ -1451,6 +1465,43 @@ rri1::
AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+rand:
+ @echo $@
+ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
+ @-if test -z "$$AWKFLAGS" ; then $(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ ; else \
+ ($(CMP) $(srcdir)/$@-mpfr.ok _$@ || $(CMP) $(srcdir)/$@-mpfr1.ok _$@) && rm -f _$@ ; \
+ fi
+
+mpfrieee:
+ @echo $@
+ @$(AWK) -M -vPREC=double -f $(srcdir)/$@.awk > _$@ 2>&1
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
+mpfrexprange:
+ @echo $@
+ @$(AWK) -M -vPREC=53 -f $(srcdir)/$@.awk > _$@ 2>&1
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
+mpfrrnd:
+ @echo $@
+ @$(AWK) -M -vPREC=53 -f $(srcdir)/$@.awk > _$@ 2>&1
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
+mpfrnr:
+ @echo $@
+ @$(AWK) -M -vPREC=113 -f $(srcdir)/$@.awk $(srcdir)/$@.in > _$@
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
+mpfrsort:
+ @echo $@
+ @$(AWK) -M -vPREC=53 -f $(srcdir)/$@.awk > _$@ 2>&1
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
+mpfrbigint:
+ @echo $@
+ @$(AWK) -M -f $(srcdir)/$@.awk > _$@ 2>&1
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
# Targets generated for other tests:
include Maketests
diff --git a/test/Makefile.in b/test/Makefile.in
index bdf30e4c..50dff8b2 100644
--- a/test/Makefile.in
+++ b/test/Makefile.in
@@ -83,11 +83,11 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/arch.m4 \
$(top_srcdir)/m4/isc-posix.m4 $(top_srcdir)/m4/lcmessage.m4 \
$(top_srcdir)/m4/lib-ld.m4 $(top_srcdir)/m4/lib-link.m4 \
$(top_srcdir)/m4/lib-prefix.m4 $(top_srcdir)/m4/libsigsegv.m4 \
- $(top_srcdir)/m4/longlong.m4 $(top_srcdir)/m4/nls.m4 \
- $(top_srcdir)/m4/noreturn.m4 $(top_srcdir)/m4/po.m4 \
- $(top_srcdir)/m4/progtest.m4 $(top_srcdir)/m4/readline.m4 \
- $(top_srcdir)/m4/socket.m4 $(top_srcdir)/m4/ulonglong.m4 \
- $(top_srcdir)/configure.ac
+ $(top_srcdir)/m4/longlong.m4 $(top_srcdir)/m4/mpfr.m4 \
+ $(top_srcdir)/m4/nls.m4 $(top_srcdir)/m4/noreturn.m4 \
+ $(top_srcdir)/m4/po.m4 $(top_srcdir)/m4/progtest.m4 \
+ $(top_srcdir)/m4/readline.m4 $(top_srcdir)/m4/socket.m4 \
+ $(top_srcdir)/m4/ulonglong.m4 $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
@@ -113,7 +113,7 @@ AUTOMAKE = @AUTOMAKE@
#
# This can also be done in individual tests where we wish to
# check things specifically not in the C locale.
-AWK = LC_ALL=$${GAWKLOCALE:-C} LANG=$${GAWKLOCALE:-C} $(AWKPROG)
+AWK = LC_ALL=$${GAWKLOCALE:-C} LANG=$${GAWKLOCALE:-C} $(AWKPROG) $(AWKFLAGS)
CC = @CC@
CCDEPMODE = @CCDEPMODE@
CFLAGS = @CFLAGS@
@@ -142,6 +142,7 @@ INTL_MACOSX_LIBS = @INTL_MACOSX_LIBS@
LDFLAGS = @LDFLAGS@
LIBICONV = @LIBICONV@
LIBINTL = @LIBINTL@
+LIBMPFR = @LIBMPFR@
LIBOBJS = @LIBOBJS@
LIBREADLINE = @LIBREADLINE@
LIBS = @LIBS@
@@ -414,6 +415,7 @@ EXTRA_DIST = \
fldchgnf.ok \
fmtspcl.awk \
fmtspcl.tok \
+ fmtspcl-mpfr.ok \
fmttest.awk \
fmttest.ok \
fnamedat.awk \
@@ -422,9 +424,11 @@ EXTRA_DIST = \
fnarray.awk \
fnarray.ok \
fnarray2.awk \
+ fnarray2.in \
fnarray2.ok \
fnarydel.awk \
fnarydel.ok \
+ fnarydel-mpfr.ok \
fnaryscl.awk \
fnaryscl.ok \
fnasgnm.awk \
@@ -434,6 +438,7 @@ EXTRA_DIST = \
fnmisc.ok \
fnparydl.awk \
fnparydl.ok \
+ fnparydl-mpfr.ok \
fpat1.awk \
fpat1.in \
fpat1.ok \
@@ -796,6 +801,7 @@ EXTRA_DIST = \
pty1.ok \
rand.awk \
rand.ok \
+ rand-mpfr.ok \
range1.awk \
range1.in \
range1.ok \
@@ -1051,6 +1057,7 @@ GAWK_EXT_TESTS = \
EXTRA_TESTS = inftest regtest
INET_TESTS = inetdayu inetdayt inetechu inetecht
MACHINE_TESTS = double1 double2 fmtspcl intformat
+MPFR_TESTS = mpfrnr mpfrrnd mpfrieee mpfrexprange mpfrsort mpfrbigint
LOCALE_CHARSET_TESTS = \
asort asorti fmttest fnarydel fnparydl lc_num1 mbfw1 \
mbprintf1 mbprintf2 mbprintf3 rebt8b2 rtlenmb sort1 sprintfc
@@ -1070,12 +1077,15 @@ FAIL_CODE1 = \
fnarray2 fnmisc gsubasgn mixed1 noparms paramdup synerr1 synerr2 unterm
+# List of files which have .ok versions for MPFR
+CHECK_MPFR = \
+ rand fnarydel fnparydl
+
+
# List of the files that appear in manual tests or are for reserve testing:
GENTESTS_UNUSED = Makefile.in gtlnbufv.awk printfloat.awk
CMP = cmp
AWKPROG = ../gawk$(EXEEXT)
-PGAWKPROG = ../pgawk$(EXEEXT)
-PGAWK = LC_ALL=$${GAWKLOCALE:-C} LANG=$${GAWKLOCALE:-C} $(PGAWKPROG)
all: all-am
.SUFFIXES:
@@ -1286,6 +1296,8 @@ inet: inetmesg $(INET_TESTS)
machine-tests: $(MACHINE_TESTS)
+mpfr-tests: $(MPFR_TESTS)
+
msg::
@echo ''
@echo 'Any output from "cmp" is bad news, although some differences'
@@ -1484,9 +1496,11 @@ fmtspcl.ok: fmtspcl.tok Makefile
@$(AWK) -v "sd=$(srcdir)" 'BEGIN {pnan = sprintf("%g",sqrt(-1)); nnan = sprintf("%g",-sqrt(-1)); pinf = sprintf("%g",-log(0)); ninf = sprintf("%g",log(0))} {sub(/positive_nan/,pnan); sub(/negative_nan/,nnan); sub(/positive_infinity/,pinf); sub(/negative_infinity/,ninf); sub(/fmtspcl/,(sd"/fmtspcl")); print}' < $(srcdir)/fmtspcl.tok > $@ 2>/dev/null
fmtspcl: fmtspcl.ok
- @echo fmtspcl
+ @echo $@
@$(AWK) -f $(srcdir)/fmtspcl.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
- @-$(CMP) $@.ok _$@ && rm -f _$@
+ @-if test -z "$$AWKFLAGS" ; then $(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ ; else \
+ $(CMP) $(srcdir)/$@-mpfr.ok _$@ && rm -f _$@ ; \
+ fi
reint::
@echo $@
@@ -1792,19 +1806,19 @@ dumpvars::
profile1:
@echo $@
- @$(AWK) --profile=ap-$@.out -f $(srcdir)/xref.awk $(srcdir)/dtdgport.awk > _$@.out1
+ @$(AWK) --pretty-print=ap-$@.out -f $(srcdir)/xref.awk $(srcdir)/dtdgport.awk > _$@.out1
@$(AWK) -f ap-$@.out $(srcdir)/dtdgport.awk > _$@.out2 ; rm ap-$@.out
@cmp _$@.out1 _$@.out2 && rm _$@.out[12] || echo EXIT CODE: $$? >>_$@
profile2:
@echo $@
- @$(PGAWK) --profile=ap-$@.out -v sortcmd=sort -f $(srcdir)/xref.awk $(srcdir)/dtdgport.awk > /dev/null
+ @$(AWK) --profile=ap-$@.out -v sortcmd=sort -f $(srcdir)/xref.awk $(srcdir)/dtdgport.awk > /dev/null
@sed 1,2d < ap-$@.out > _$@; rm ap-$@.out
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
profile3:
@echo $@
- @$(PGAWK) --profile=ap-$@.out -f $(srcdir)/$@.awk > /dev/null
+ @$(AWK) --profile=ap-$@.out -f $(srcdir)/$@.awk > /dev/null
@sed 1,2d < ap-$@.out > _$@; rm ap-$@.out
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
@@ -1828,1085 +1842,1117 @@ rri1::
@[ -z "$$GAWKLOCALE" ] && GAWKLOCALE=en_US.UTF-8; \
AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
+rand:
+ @echo $@
+ @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
+ @-if test -z "$$AWKFLAGS" ; then $(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ ; else \
+ ($(CMP) $(srcdir)/$@-mpfr.ok _$@ || $(CMP) $(srcdir)/$@-mpfr1.ok _$@) && rm -f _$@ ; \
+ fi
+
+mpfrieee:
+ @echo $@
+ @$(AWK) -M -vPREC=double -f $(srcdir)/$@.awk > _$@ 2>&1
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
+mpfrexprange:
+ @echo $@
+ @$(AWK) -M -vPREC=53 -f $(srcdir)/$@.awk > _$@ 2>&1
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
+mpfrrnd:
+ @echo $@
+ @$(AWK) -M -vPREC=53 -f $(srcdir)/$@.awk > _$@ 2>&1
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
+mpfrnr:
+ @echo $@
+ @$(AWK) -M -vPREC=113 -f $(srcdir)/$@.awk $(srcdir)/$@.in > _$@
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
+mpfrsort:
+ @echo $@
+ @$(AWK) -M -vPREC=53 -f $(srcdir)/$@.awk > _$@ 2>&1
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+
+mpfrbigint:
+ @echo $@
+ @$(AWK) -M -f $(srcdir)/$@.awk > _$@ 2>&1
+ @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
Gt-dummy:
# file Maketests, generated from Makefile.am by the Gentests program
addcomma:
- @echo addcomma
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
anchgsub:
- @echo anchgsub
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arrayparm:
- @echo arrayparm
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arrayprm2:
- @echo arrayprm2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arrayprm3:
- @echo arrayprm3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arrayref:
- @echo arrayref
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arrymem1:
- @echo arrymem1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arryref2:
- @echo arryref2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arryref3:
- @echo arryref3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arryref4:
- @echo arryref4
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arryref5:
- @echo arryref5
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arynasty:
- @echo arynasty
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aryprm1:
- @echo aryprm1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aryprm2:
- @echo aryprm2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aryprm3:
- @echo aryprm3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aryprm4:
- @echo aryprm4
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aryprm5:
- @echo aryprm5
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aryprm6:
- @echo aryprm6
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aryprm7:
- @echo aryprm7
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aryprm8:
- @echo aryprm8
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arysubnm:
- @echo arysubnm
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
asgext:
- @echo asgext
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
back89:
- @echo back89
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
backgsub:
- @echo backgsub
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
childin:
- @echo childin
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
closebad:
- @echo closebad
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
clsflnam:
- @echo clsflnam
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
compare2:
- @echo compare2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
concat1:
- @echo concat1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
concat2:
- @echo concat2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
concat3:
- @echo concat3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
convfmt:
- @echo convfmt
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
datanonl:
- @echo datanonl
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
defref:
- @echo defref
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
delargv:
- @echo delargv
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
delarpm2:
- @echo delarpm2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
delarprm:
- @echo delarprm
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
delfunc:
- @echo delfunc
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
dfastress:
- @echo dfastress
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
dynlj:
- @echo dynlj
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
eofsplit:
- @echo eofsplit
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
exitval2:
- @echo exitval2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fcall_exit:
- @echo fcall_exit
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fcall_exit2:
- @echo fcall_exit2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fldchg:
- @echo fldchg
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fldchgnf:
- @echo fldchgnf
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fnamedat:
- @echo fnamedat
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fnarray:
- @echo fnarray
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fnarray2:
- @echo fnarray2
- @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
+ @echo $@
+ @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fnaryscl:
- @echo fnaryscl
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fnasgnm:
- @echo fnasgnm
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fnmisc:
- @echo fnmisc
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fordel:
- @echo fordel
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
forref:
- @echo forref
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
forsimp:
- @echo forsimp
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fsbs:
- @echo fsbs
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fsrs:
- @echo fsrs
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fstabplus:
- @echo fstabplus
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
funsemnl:
- @echo funsemnl
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
funsmnam:
- @echo funsmnam
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
funstack:
- @echo funstack
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
getline:
- @echo getline
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
getline3:
- @echo getline3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
getline4:
- @echo getline4
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
getnr2tb:
- @echo getnr2tb
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
getnr2tm:
- @echo getnr2tm
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gsubasgn:
- @echo gsubasgn
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gsubtest:
- @echo gsubtest
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gsubtst2:
- @echo gsubtst2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gsubtst4:
- @echo gsubtst4
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gsubtst5:
- @echo gsubtst5
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gsubtst7:
- @echo gsubtst7
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gsubtst8:
- @echo gsubtst8
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
hex:
- @echo hex
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
hsprint:
- @echo hsprint
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
inputred:
- @echo inputred
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
intest:
- @echo intest
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
intprec:
- @echo intprec
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
iobug1:
- @echo iobug1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
leadnl:
- @echo leadnl
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
longsub:
- @echo longsub
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
longwrds:
- @echo longwrds
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
manglprm:
- @echo manglprm
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
math:
- @echo math
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
membug1:
- @echo membug1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
minusstr:
- @echo minusstr
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nasty:
- @echo nasty
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nasty2:
- @echo nasty2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
negexp:
- @echo negexp
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
negrange:
- @echo negrange
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nested:
- @echo nested
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nfldstr:
- @echo nfldstr
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nfneg:
- @echo nfneg
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nfset:
- @echo nfset
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nlfldsep:
- @echo nlfldsep
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nlinstr:
- @echo nlinstr
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nlstrina:
- @echo nlstrina
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
noeffect:
- @echo noeffect
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nofmtch:
- @echo nofmtch
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
noloop1:
- @echo noloop1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
noloop2:
- @echo noloop2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
noparms:
- @echo noparms
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nulrsend:
- @echo nulrsend
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
numindex:
- @echo numindex
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
numsubstr:
- @echo numsubstr
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
octsub:
- @echo octsub
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
ofmt:
- @echo ofmt
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
ofmta:
- @echo ofmta
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
ofmtbig:
- @echo ofmtbig
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
ofmtfidl:
- @echo ofmtfidl
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
ofmts:
- @echo ofmts
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
onlynl:
- @echo onlynl
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
opasnidx:
- @echo opasnidx
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
opasnslf:
- @echo opasnslf
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
paramdup:
- @echo paramdup
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
paramres:
- @echo paramres
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
paramtyp:
- @echo paramtyp
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
parse1:
- @echo parse1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
parsefld:
- @echo parsefld
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
parseme:
- @echo parseme
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
pcntplus:
- @echo pcntplus
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
prdupval:
- @echo prdupval
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
prec:
- @echo prec
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
printf1:
- @echo printf1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
prmarscl:
- @echo prmarscl
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
prmreuse:
- @echo prmreuse
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
prt1eval:
- @echo prt1eval
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
prtoeval:
- @echo prtoeval
- @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
- @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
-
-rand:
- @echo rand
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
range1:
- @echo range1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rebt8b1:
- @echo rebt8b1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
regeq:
- @echo regeq
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
regrange:
- @echo regrange
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
reindops:
- @echo reindops
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
reparse:
- @echo reparse
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
resplit:
- @echo resplit
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rs:
- @echo rs
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rsnul1nl:
- @echo rsnul1nl
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rstest1:
- @echo rstest1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rstest2:
- @echo rstest2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rstest3:
- @echo rstest3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rstest4:
- @echo rstest4
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rstest5:
- @echo rstest5
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rswhite:
- @echo rswhite
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
scalar:
- @echo scalar
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
sclforin:
- @echo sclforin
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
sclifin:
- @echo sclifin
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
sortempty:
- @echo sortempty
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
splitargv:
- @echo splitargv
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
splitarr:
- @echo splitarr
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
splitdef:
- @echo splitdef
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
splitvar:
- @echo splitvar
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
splitwht:
- @echo splitwht
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
strcat1:
- @echo strcat1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
strnum1:
- @echo strnum1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
strtod:
- @echo strtod
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
subsepnm:
- @echo subsepnm
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
subslash:
- @echo subslash
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
substr:
- @echo substr
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
swaplns:
- @echo swaplns
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
synerr1:
- @echo synerr1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
synerr2:
- @echo synerr2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
uninit2:
- @echo uninit2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
uninit3:
- @echo uninit3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
uninit4:
- @echo uninit4
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
uninit5:
- @echo uninit5
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
uninitialized:
- @echo uninitialized
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
unterm:
- @echo unterm
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
uparrfs:
- @echo uparrfs
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
wjposer1:
- @echo wjposer1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
zero2:
- @echo zero2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
zeroe0:
- @echo zeroe0
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
zeroflag:
- @echo zeroflag
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
getlnhd:
- @echo getlnhd
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aadelete1:
- @echo aadelete1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aadelete2:
- @echo aadelete2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aarray1:
- @echo aarray1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aasort:
- @echo aasort
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aasorti:
- @echo aasorti
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arraysort:
- @echo arraysort
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
backw:
- @echo backw
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
clos1way:
- @echo clos1way
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
delsub:
- @echo delsub
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fieldwdth:
- @echo fieldwdth
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fpat1:
- @echo fpat1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fpat2:
- @echo fpat2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fpat3:
- @echo fpat3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fpatnull:
- @echo fpatnull
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fsfwfs:
- @echo fsfwfs
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
funlen:
- @echo funlen
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fwtest:
- @echo fwtest
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fwtest2:
- @echo fwtest2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fwtest3:
- @echo fwtest3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gensub:
- @echo gensub
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gensub2:
- @echo gensub2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
getlndir:
- @echo getlndir
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gnuops2:
- @echo gnuops2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gnuops3:
- @echo gnuops3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gnureops:
- @echo gnureops
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
icasefs:
- @echo icasefs
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
icasers:
- @echo icasers
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
igncdym:
- @echo igncdym
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
igncfs:
- @echo igncfs
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
ignrcase:
- @echo ignrcase
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
indirectcall:
- @echo indirectcall
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
lint:
- @echo lint
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
lintold:
- @echo lintold
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint-old < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
lintwarn:
- @echo lintwarn
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
match1:
- @echo match1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
match2:
- @echo match2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
match3:
- @echo match3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nastyparm:
- @echo nastyparm
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nondec:
- @echo nondec
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
patsplit:
- @echo patsplit
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
posix:
- @echo posix
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
printfbad1:
- @echo printfbad1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
@@ -2916,112 +2962,116 @@ printfbad3:
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
procinfs:
- @echo procinfs
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
pty1:
- @echo pty1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rebuf:
- @echo rebuf
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
regx8bit:
- @echo regx8bit
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rstest6:
- @echo rstest6
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
shadow:
- @echo shadow
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
sortfor:
- @echo sortfor
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
sortu:
- @echo sortu
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
splitarg4:
- @echo splitarg4
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
strtonum:
- @echo strtonum
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
switch2:
- @echo switch2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
double1:
- @echo double1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
double2:
- @echo double2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
intformat:
- @echo intformat
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
asort:
- @echo asort
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
asorti:
- @echo asorti
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fmttest:
- @echo fmttest
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fnarydel:
- @echo fnarydel
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
- @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+ @-if test -z "$$AWKFLAGS" ; then $(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ ; else \
+ $(CMP) $(srcdir)/$@-mpfr.ok _$@ && rm -f _$@ ; \
+ fi
fnparydl:
- @echo fnparydl
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
- @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+ @-if test -z "$$AWKFLAGS" ; then $(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ ; else \
+ $(CMP) $(srcdir)/$@-mpfr.ok _$@ && rm -f _$@ ; \
+ fi
rebt8b2:
- @echo rebt8b2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
sort1:
- @echo sort1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
sprintfc:
- @echo sprintfc
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
diff --git a/test/Maketests b/test/Maketests
index 34a0aaa6..96825721 100644
--- a/test/Maketests
+++ b/test/Maketests
@@ -1,1082 +1,1077 @@
Gt-dummy:
# file Maketests, generated from Makefile.am by the Gentests program
addcomma:
- @echo addcomma
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
anchgsub:
- @echo anchgsub
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arrayparm:
- @echo arrayparm
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arrayprm2:
- @echo arrayprm2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arrayprm3:
- @echo arrayprm3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arrayref:
- @echo arrayref
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arrymem1:
- @echo arrymem1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arryref2:
- @echo arryref2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arryref3:
- @echo arryref3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arryref4:
- @echo arryref4
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arryref5:
- @echo arryref5
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arynasty:
- @echo arynasty
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aryprm1:
- @echo aryprm1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aryprm2:
- @echo aryprm2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aryprm3:
- @echo aryprm3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aryprm4:
- @echo aryprm4
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aryprm5:
- @echo aryprm5
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aryprm6:
- @echo aryprm6
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aryprm7:
- @echo aryprm7
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aryprm8:
- @echo aryprm8
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arysubnm:
- @echo arysubnm
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
asgext:
- @echo asgext
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
back89:
- @echo back89
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
backgsub:
- @echo backgsub
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
childin:
- @echo childin
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
closebad:
- @echo closebad
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
clsflnam:
- @echo clsflnam
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
compare2:
- @echo compare2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
concat1:
- @echo concat1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
concat2:
- @echo concat2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
concat3:
- @echo concat3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
convfmt:
- @echo convfmt
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
datanonl:
- @echo datanonl
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
defref:
- @echo defref
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
delargv:
- @echo delargv
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
delarpm2:
- @echo delarpm2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
delarprm:
- @echo delarprm
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
delfunc:
- @echo delfunc
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
dfastress:
- @echo dfastress
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
dynlj:
- @echo dynlj
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
eofsplit:
- @echo eofsplit
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
exitval2:
- @echo exitval2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fcall_exit:
- @echo fcall_exit
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fcall_exit2:
- @echo fcall_exit2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fldchg:
- @echo fldchg
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fldchgnf:
- @echo fldchgnf
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fnamedat:
- @echo fnamedat
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fnarray:
- @echo fnarray
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fnarray2:
- @echo fnarray2
- @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
+ @echo $@
+ @AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fnaryscl:
- @echo fnaryscl
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fnasgnm:
- @echo fnasgnm
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fnmisc:
- @echo fnmisc
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fordel:
- @echo fordel
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
forref:
- @echo forref
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
forsimp:
- @echo forsimp
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fsbs:
- @echo fsbs
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fsrs:
- @echo fsrs
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fstabplus:
- @echo fstabplus
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
funsemnl:
- @echo funsemnl
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
funsmnam:
- @echo funsmnam
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
funstack:
- @echo funstack
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
getline:
- @echo getline
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
getline3:
- @echo getline3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
getline4:
- @echo getline4
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
getnr2tb:
- @echo getnr2tb
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
getnr2tm:
- @echo getnr2tm
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gsubasgn:
- @echo gsubasgn
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gsubtest:
- @echo gsubtest
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gsubtst2:
- @echo gsubtst2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gsubtst4:
- @echo gsubtst4
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gsubtst5:
- @echo gsubtst5
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gsubtst7:
- @echo gsubtst7
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gsubtst8:
- @echo gsubtst8
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
hex:
- @echo hex
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
hsprint:
- @echo hsprint
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
inputred:
- @echo inputred
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
intest:
- @echo intest
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
intprec:
- @echo intprec
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
iobug1:
- @echo iobug1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
leadnl:
- @echo leadnl
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
longsub:
- @echo longsub
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
longwrds:
- @echo longwrds
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
manglprm:
- @echo manglprm
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
math:
- @echo math
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
membug1:
- @echo membug1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
minusstr:
- @echo minusstr
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nasty:
- @echo nasty
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nasty2:
- @echo nasty2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
negexp:
- @echo negexp
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
negrange:
- @echo negrange
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nested:
- @echo nested
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nfldstr:
- @echo nfldstr
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nfneg:
- @echo nfneg
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nfset:
- @echo nfset
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nlfldsep:
- @echo nlfldsep
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nlinstr:
- @echo nlinstr
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nlstrina:
- @echo nlstrina
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
noeffect:
- @echo noeffect
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nofmtch:
- @echo nofmtch
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
noloop1:
- @echo noloop1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
noloop2:
- @echo noloop2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
noparms:
- @echo noparms
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nulrsend:
- @echo nulrsend
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
numindex:
- @echo numindex
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
numsubstr:
- @echo numsubstr
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
octsub:
- @echo octsub
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
ofmt:
- @echo ofmt
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
ofmta:
- @echo ofmta
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
ofmtbig:
- @echo ofmtbig
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
ofmtfidl:
- @echo ofmtfidl
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
ofmts:
- @echo ofmts
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
onlynl:
- @echo onlynl
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
opasnidx:
- @echo opasnidx
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
opasnslf:
- @echo opasnslf
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
paramdup:
- @echo paramdup
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
paramres:
- @echo paramres
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
paramtyp:
- @echo paramtyp
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
parse1:
- @echo parse1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
parsefld:
- @echo parsefld
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
parseme:
- @echo parseme
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
pcntplus:
- @echo pcntplus
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
prdupval:
- @echo prdupval
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
prec:
- @echo prec
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
printf1:
- @echo printf1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
prmarscl:
- @echo prmarscl
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
prmreuse:
- @echo prmreuse
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
prt1eval:
- @echo prt1eval
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
prtoeval:
- @echo prtoeval
- @AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
- @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
-
-rand:
- @echo rand
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
range1:
- @echo range1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rebt8b1:
- @echo rebt8b1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
regeq:
- @echo regeq
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
regrange:
- @echo regrange
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
reindops:
- @echo reindops
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
reparse:
- @echo reparse
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
resplit:
- @echo resplit
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rs:
- @echo rs
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rsnul1nl:
- @echo rsnul1nl
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rstest1:
- @echo rstest1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rstest2:
- @echo rstest2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rstest3:
- @echo rstest3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rstest4:
- @echo rstest4
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rstest5:
- @echo rstest5
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rswhite:
- @echo rswhite
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
scalar:
- @echo scalar
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
sclforin:
- @echo sclforin
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
sclifin:
- @echo sclifin
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
sortempty:
- @echo sortempty
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
splitargv:
- @echo splitargv
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
splitarr:
- @echo splitarr
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
splitdef:
- @echo splitdef
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
splitvar:
- @echo splitvar
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
splitwht:
- @echo splitwht
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
strcat1:
- @echo strcat1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
strnum1:
- @echo strnum1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
strtod:
- @echo strtod
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
subsepnm:
- @echo subsepnm
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
subslash:
- @echo subslash
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
substr:
- @echo substr
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
swaplns:
- @echo swaplns
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
synerr1:
- @echo synerr1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
synerr2:
- @echo synerr2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
uninit2:
- @echo uninit2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
uninit3:
- @echo uninit3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
uninit4:
- @echo uninit4
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
uninit5:
- @echo uninit5
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
uninitialized:
- @echo uninitialized
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
unterm:
- @echo unterm
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
uparrfs:
- @echo uparrfs
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
wjposer1:
- @echo wjposer1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
zero2:
- @echo zero2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
zeroe0:
- @echo zeroe0
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
zeroflag:
- @echo zeroflag
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
getlnhd:
- @echo getlnhd
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aadelete1:
- @echo aadelete1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aadelete2:
- @echo aadelete2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aarray1:
- @echo aarray1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aasort:
- @echo aasort
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
aasorti:
- @echo aasorti
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
arraysort:
- @echo arraysort
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
backw:
- @echo backw
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
clos1way:
- @echo clos1way
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
delsub:
- @echo delsub
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fieldwdth:
- @echo fieldwdth
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fpat1:
- @echo fpat1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fpat2:
- @echo fpat2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fpat3:
- @echo fpat3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fpatnull:
- @echo fpatnull
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fsfwfs:
- @echo fsfwfs
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
funlen:
- @echo funlen
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fwtest:
- @echo fwtest
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fwtest2:
- @echo fwtest2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fwtest3:
- @echo fwtest3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gensub:
- @echo gensub
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gensub2:
- @echo gensub2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
getlndir:
- @echo getlndir
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gnuops2:
- @echo gnuops2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gnuops3:
- @echo gnuops3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
gnureops:
- @echo gnureops
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
icasefs:
- @echo icasefs
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
icasers:
- @echo icasers
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
igncdym:
- @echo igncdym
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
igncfs:
- @echo igncfs
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
ignrcase:
- @echo ignrcase
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
indirectcall:
- @echo indirectcall
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
lint:
- @echo lint
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
lintold:
- @echo lintold
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint-old < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
lintwarn:
- @echo lintwarn
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
match1:
- @echo match1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
match2:
- @echo match2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
match3:
- @echo match3
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nastyparm:
- @echo nastyparm
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
nondec:
- @echo nondec
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
patsplit:
- @echo patsplit
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
posix:
- @echo posix
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
printfbad1:
- @echo printfbad1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
@@ -1086,112 +1081,116 @@ printfbad3:
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
procinfs:
- @echo procinfs
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
pty1:
- @echo pty1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rebuf:
- @echo rebuf
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
regx8bit:
- @echo regx8bit
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
rstest6:
- @echo rstest6
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
shadow:
- @echo shadow
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk --lint >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
sortfor:
- @echo sortfor
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
sortu:
- @echo sortu
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
splitarg4:
- @echo splitarg4
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
strtonum:
- @echo strtonum
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
switch2:
- @echo switch2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
double1:
- @echo double1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
double2:
- @echo double2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
intformat:
- @echo intformat
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
asort:
- @echo asort
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
asorti:
- @echo asorti
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fmttest:
- @echo fmttest
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
fnarydel:
- @echo fnarydel
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
- @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+ @-if test -z "$$AWKFLAGS" ; then $(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ ; else \
+ $(CMP) $(srcdir)/$@-mpfr.ok _$@ && rm -f _$@ ; \
+ fi
fnparydl:
- @echo fnparydl
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
- @-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
+ @-if test -z "$$AWKFLAGS" ; then $(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@ ; else \
+ $(CMP) $(srcdir)/$@-mpfr.ok _$@ && rm -f _$@ ; \
+ fi
rebt8b2:
- @echo rebt8b2
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
sort1:
- @echo sort1
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
sprintfc:
- @echo sprintfc
+ @echo $@
@AWKPATH=$(srcdir) $(AWK) -f $@.awk < $(srcdir)/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) $(srcdir)/$@.ok _$@ && rm -f _$@
diff --git a/test/badargs.ok b/test/badargs.ok
index 66e67b03..35c7d027 100644
--- a/test/badargs.ok
+++ b/test/badargs.ok
@@ -10,13 +10,17 @@ Short options: GNU long options: (extensions)
-c --traditional
-C --copyright
-d[file] --dump-variables[=file]
+ -D[file] --debug[=file]
-e 'program-text' --source='program-text'
-E file --exec=file
-g --gen-pot
-h --help
+ -l library --load=library
-L [fatal] --lint[=fatal]
-n --non-decimal-data
+ -M --bignum
-N --use-lc-numeric
+ -o[file] --pretty-print[=file]
-O --optimize
-p[file] --profile[=file]
-P --posix
diff --git a/test/delfunc.ok b/test/delfunc.ok
index d12f0bc9..29a7450d 100644
--- a/test/delfunc.ok
+++ b/test/delfunc.ok
@@ -1,2 +1,3 @@
-gawk: delfunc.awk:4: fatal: attempt to use function `f' as an array
-EXIT CODE: 2
+gawk: delfunc.awk:4: error: function `f' called with space between name and `(',
+or used as a variable or an array
+EXIT CODE: 1
diff --git a/test/dumpvars.ok b/test/dumpvars.ok
index 01d5fb78..73d3d306 100644
--- a/test/dumpvars.ok
+++ b/test/dumpvars.ok
@@ -16,7 +16,9 @@ NR: 3
OFMT: "%.6g"
OFS: " "
ORS: "\n"
+PREC: 53
RLENGTH: 0
+ROUNDMODE: "N"
RS: "\n"
RSTART: 0
RT: "\n"
diff --git a/test/fmtspcl-mpfr.ok b/test/fmtspcl-mpfr.ok
new file mode 100644
index 00000000..e69de29b
--- /dev/null
+++ b/test/fmtspcl-mpfr.ok
diff --git a/test/fnamedat.ok b/test/fnamedat.ok
index d32acff4..d7b71c41 100644
--- a/test/fnamedat.ok
+++ b/test/fnamedat.ok
@@ -1,2 +1,3 @@
-gawk: fnamedat.awk:1: (FILENAME=- FNR=1) fatal: can't use function name `foo' as variable or array
-EXIT CODE: 2
+gawk: fnamedat.awk:1: error: function `foo' called with space between name and `(',
+or used as a variable or an array
+EXIT CODE: 1
diff --git a/test/fnarray.ok b/test/fnarray.ok
index 04260b0f..6cab9134 100644
--- a/test/fnarray.ok
+++ b/test/fnarray.ok
@@ -1,5 +1,3 @@
-gawk: fnarray.awk:5: Num = foo[c]
-gawk: fnarray.awk:5: ^ use of non-array as array
gawk: fnarray.awk:5: error: function `foo' called with space between name and `(',
or used as a variable or an array
EXIT CODE: 1
diff --git a/test/fnarray2.in b/test/fnarray2.in
new file mode 100644
index 00000000..587be6b4
--- /dev/null
+++ b/test/fnarray2.in
@@ -0,0 +1 @@
+x
diff --git a/test/fnarray2.ok b/test/fnarray2.ok
index 243e4cc3..82815055 100644
--- a/test/fnarray2.ok
+++ b/test/fnarray2.ok
@@ -1,3 +1,3 @@
-gawk: fnarray2.awk:3: r = ++pile[c]
-gawk: fnarray2.awk:3: ^ use of non-array as array
+gawk: fnarray2.awk:3: error: function `pile' called with space between name and `(',
+or used as a variable or an array
EXIT CODE: 1
diff --git a/test/fnarydel-mpfr.ok b/test/fnarydel-mpfr.ok
new file mode 100644
index 00000000..7f3e4531
--- /dev/null
+++ b/test/fnarydel-mpfr.ok
@@ -0,0 +1,27 @@
+first loop
+4
+5
+6
+7
+8
+9
+1
+2
+3
+second loop
+third loop
+4
+5
+6
+7
+8
+9
+1
+2
+3
+call func
+fourth loop
+You should just see: 4 4
+4 4
+You should see nothing between this line
+And this one
diff --git a/test/fnarydel.ok b/test/fnarydel.ok
index 7f3e4531..7078c015 100644
--- a/test/fnarydel.ok
+++ b/test/fnarydel.ok
@@ -1,24 +1,24 @@
first loop
+1
+2
+3
4
5
6
7
8
9
+second loop
+third loop
1
2
3
-second loop
-third loop
4
5
6
7
8
9
-1
-2
-3
call func
fourth loop
You should just see: 4 4
diff --git a/test/fnasgnm.ok b/test/fnasgnm.ok
index 0db5c6d8..5cacff27 100644
--- a/test/fnasgnm.ok
+++ b/test/fnasgnm.ok
@@ -1,2 +1,3 @@
-gawk: fnasgnm.awk:14: (FILENAME=- FNR=1) fatal: can't use function name `ShowMe' as variable or array
-EXIT CODE: 2
+gawk: fnasgnm.awk:14: error: function `ShowMe' called with space between name and `(',
+or used as a variable or an array
+EXIT CODE: 1
diff --git a/test/fnparydl-mpfr.ok b/test/fnparydl-mpfr.ok
new file mode 100644
index 00000000..26a5c390
--- /dev/null
+++ b/test/fnparydl-mpfr.ok
@@ -0,0 +1,10 @@
+BEFORE LOOP
+DELETING KEY 4
+DELETING KEY 5
+DELETING KEY 6
+DELETING KEY 7
+DELETING KEY 1
+DELETING KEY 2
+DELETING KEY 3
+AFTER LOOP
+0 elements still in q[]
diff --git a/test/fnparydl.ok b/test/fnparydl.ok
index 26a5c390..9f798224 100644
--- a/test/fnparydl.ok
+++ b/test/fnparydl.ok
@@ -1,10 +1,10 @@
BEFORE LOOP
+DELETING KEY 1
+DELETING KEY 2
+DELETING KEY 3
DELETING KEY 4
DELETING KEY 5
DELETING KEY 6
DELETING KEY 7
-DELETING KEY 1
-DELETING KEY 2
-DELETING KEY 3
AFTER LOOP
0 elements still in q[]
diff --git a/test/funsmnam.ok b/test/funsmnam.ok
index e4f2174a..cce0d275 100644
--- a/test/funsmnam.ok
+++ b/test/funsmnam.ok
@@ -1,2 +1,2 @@
-gawk: funsmnam.awk:1: error: function `foo': can't use function name as parameter name
+gawk: funsmnam.awk:2: error: function `foo': can't use function name as parameter name
EXIT CODE: 1
diff --git a/test/gsubasgn.ok b/test/gsubasgn.ok
index 8817c36d..8a309c7c 100644
--- a/test/gsubasgn.ok
+++ b/test/gsubasgn.ok
@@ -1,5 +1,5 @@
-gawk: gsubasgn.awk:4: function test1 (r) { gsub(r, "x", test1) }
-gawk: gsubasgn.awk:4: ^ gsub third parameter is not a changeable object
-gawk: gsubasgn.awk:8: function test2 () { gsub(/a/, "x", test2) }
-gawk: gsubasgn.awk:8: ^ gsub third parameter is not a changeable object
+gawk: gsubasgn.awk:4: error: function `test1' called with space between name and `(',
+or used as a variable or an array
+gawk: gsubasgn.awk:8: error: function `test2' called with space between name and `(',
+or used as a variable or an array
EXIT CODE: 1
diff --git a/test/match2.ok b/test/match2.ok
index a4a91e85..ad2e324c 100644
--- a/test/match2.ok
+++ b/test/match2.ok
@@ -1,2 +1,3 @@
-gawk: match2.awk:3: fatal: match: third argument is not an array
-EXIT CODE: 2
+gawk: match2.awk:3: error: function `f' called with space between name and `(',
+or used as a variable or an array
+EXIT CODE: 1
diff --git a/test/mpfrbigint.awk b/test/mpfrbigint.awk
new file mode 100644
index 00000000..bfdd871a
--- /dev/null
+++ b/test/mpfrbigint.awk
@@ -0,0 +1,11 @@
+BEGIN {
+ x = 5^4^3^2
+ print "# of digits =", length(x)
+ print substr(x, 1, 20), "...", substr(x, length(x) - 19, 20)
+
+ PREC = 1 + 3.321928095 * length(x); # 1 + digits * log2(10)
+ print "floating-point computation with precision =", PREC
+ y = 5.0^4.0^3.0^2.0
+ print "# of digits =", length(y)
+ print substr(y, 1, 20), "...", substr(y, length(y) - 19, 20)
+}
diff --git a/test/mpfrbigint.ok b/test/mpfrbigint.ok
new file mode 100644
index 00000000..670d4e07
--- /dev/null
+++ b/test/mpfrbigint.ok
@@ -0,0 +1,5 @@
+# of digits = 183231
+62060698786608744707 ... 92256259918212890625
+floating-point computation with precision = 608681
+# of digits = 183231
+62060698786608744707 ... 92256259918212890625
diff --git a/test/mpfrexprange.awk b/test/mpfrexprange.awk
new file mode 100644
index 00000000..68e95a39
--- /dev/null
+++ b/test/mpfrexprange.awk
@@ -0,0 +1,7 @@
+# test change of allowed exponent range
+BEGIN {
+ x=1.0e-10000
+ print x+0
+ PREC="double"
+ print x+0
+}
diff --git a/test/mpfrexprange.ok b/test/mpfrexprange.ok
new file mode 100644
index 00000000..4700ee22
--- /dev/null
+++ b/test/mpfrexprange.ok
@@ -0,0 +1,2 @@
+1e-10000
+0
diff --git a/test/mpfrieee.awk b/test/mpfrieee.awk
new file mode 100644
index 00000000..dc6e120d
--- /dev/null
+++ b/test/mpfrieee.awk
@@ -0,0 +1,13 @@
+# Test IEEE-754 binary double format
+BEGIN {
+ x = 1.0e-320
+ i = 0
+ while (x > 0) {
+ printf("%.15e\n", x)
+ x /= 2
+
+ # terminate early when the test is going to fail.
+ if (++i > 50)
+ break
+ }
+}
diff --git a/test/mpfrieee.ok b/test/mpfrieee.ok
new file mode 100644
index 00000000..e88f5c79
--- /dev/null
+++ b/test/mpfrieee.ok
@@ -0,0 +1,12 @@
+9.999888671826830e-321
+4.999944335913415e-321
+2.499972167956708e-321
+1.249986083978354e-321
+6.225227137599706e-322
+3.112613568799853e-322
+1.581010066691989e-322
+7.905050333459945e-323
+3.952525166729972e-323
+1.976262583364986e-323
+9.881312916824931e-324
+4.940656458412465e-324
diff --git a/test/mpfrnr.awk b/test/mpfrnr.awk
new file mode 100644
index 00000000..1a3b753a
--- /dev/null
+++ b/test/mpfrnr.awk
@@ -0,0 +1,10 @@
+# Test NR and FNR for file(s) with records > LONG_MAX
+BEGIN {
+ NR = 0x7FFFFFFF
+}
+BEGINFILE {
+ FNR = 0x7fffffffffffffff
+}
+END {
+ print NR, NR-0x7FFFFFFF, FNR, FNR-0x7fffffffffffffff
+}
diff --git a/test/mpfrnr.in b/test/mpfrnr.in
new file mode 100644
index 00000000..6ad36e52
--- /dev/null
+++ b/test/mpfrnr.in
@@ -0,0 +1,3 @@
+Line 1
+Line 2
+Line 3
diff --git a/test/mpfrnr.ok b/test/mpfrnr.ok
new file mode 100644
index 00000000..e472f8bf
--- /dev/null
+++ b/test/mpfrnr.ok
@@ -0,0 +1 @@
+2147483650 3 9223372036854775810 3
diff --git a/test/mpfrrnd.awk b/test/mpfrrnd.awk
new file mode 100644
index 00000000..508ac26b
--- /dev/null
+++ b/test/mpfrrnd.awk
@@ -0,0 +1,15 @@
+BEGIN {
+ N = 22/7
+ printf(" %.15f\n", N)
+
+ printf("* %.10f\n", N) # default
+ ROUNDMODE="N"; printf("N %.10f\n", N)
+ ROUNDMODE="U"; printf("U %.10f\n", N)
+ ROUNDMODE="D"; printf("D %.10f\n", N)
+ ROUNDMODE="Z"; printf("Z %.10f\n", N)
+ N = -N
+ ROUNDMODE="N"; printf("N %.10f\n", N)
+ ROUNDMODE="U"; printf("U %.10f\n", N)
+ ROUNDMODE="D"; printf("D %.10f\n", N)
+ ROUNDMODE="Z"; printf("Z %.10f\n", N)
+}
diff --git a/test/mpfrrnd.ok b/test/mpfrrnd.ok
new file mode 100644
index 00000000..fceb937b
--- /dev/null
+++ b/test/mpfrrnd.ok
@@ -0,0 +1,10 @@
+ 3.142857142857143
+* 3.1428571429
+N 3.1428571429
+U 3.1428571429
+D 3.1428571428
+Z 3.1428571428
+N -3.1428571429
+U -3.1428571428
+D -3.1428571429
+Z -3.1428571428
diff --git a/test/mpfrsort.awk b/test/mpfrsort.awk
new file mode 100644
index 00000000..6f7fa65c
--- /dev/null
+++ b/test/mpfrsort.awk
@@ -0,0 +1,8 @@
+BEGIN {
+# s = "1.0 +nan 0.0 -1 +inf -0.0 1 nan 1.0 -nan -inf 2.0"
+ s = "1.0 +nan 0.0 -1 +inf -0.0 1 1.0 -nan -inf 2.0"
+ split(s, a)
+ PROCINFO["sorted_in"] = "@val_num_asc"
+ for (i in a)
+ print a[i]
+}
diff --git a/test/mpfrsort.ok b/test/mpfrsort.ok
new file mode 100644
index 00000000..77a51ecf
--- /dev/null
+++ b/test/mpfrsort.ok
@@ -0,0 +1,11 @@
+-inf
+-1
+-0.0
+0.0
+1
+1.0
+1.0
+2.0
++inf
++nan
+-nan
diff --git a/test/rand-mpfr.ok b/test/rand-mpfr.ok
new file mode 100644
index 00000000..76ab51b4
--- /dev/null
+++ b/test/rand-mpfr.ok
@@ -0,0 +1 @@
+ 27 89 11 47 77 49 13 34 78 93 76 96 91 53 3 94 25 51 10
diff --git a/test/rand-mpfr1.ok b/test/rand-mpfr1.ok
new file mode 100644
index 00000000..448f4032
--- /dev/null
+++ b/test/rand-mpfr1.ok
@@ -0,0 +1 @@
+ 25 42 47 49 80 5 4 92 59 96 8 63 92 28 41 37 80 51 48
diff --git a/version.c b/version.c
index c1ecb4f1..4c1b6402 100644
--- a/version.c
+++ b/version.c
@@ -1,3 +1,3 @@
#include "config.h"
-const char *version_string = "GNU Awk 4.0.1a";
+const char *version_string = "GNU Awk 4.0.70";