diff options
-rw-r--r-- | ChangeLog | 28 | ||||
-rw-r--r-- | ChangeLog.0 | 2 | ||||
-rw-r--r-- | NEWS | 10 | ||||
-rw-r--r-- | awk.h | 12 | ||||
-rw-r--r-- | awkgram.c | 31 | ||||
-rw-r--r-- | awkgram.y | 31 | ||||
-rw-r--r-- | configh.in | 12 | ||||
-rwxr-xr-x | configure | 54 | ||||
-rw-r--r-- | configure.ac | 22 | ||||
-rw-r--r-- | custom.h | 5 | ||||
-rw-r--r-- | doc/ChangeLog | 7 | ||||
-rw-r--r-- | doc/gawk.info | 114 | ||||
-rw-r--r-- | doc/gawk.texi | 5 | ||||
-rw-r--r-- | doc/gawktexi.in | 5 | ||||
-rw-r--r-- | doc/it/ChangeLog | 4 | ||||
-rw-r--r-- | doc/it/gawktexi.in | 81 | ||||
-rw-r--r-- | missing_d/ChangeLog | 4 | ||||
-rw-r--r-- | missing_d/gawkbool.h | 40 | ||||
-rw-r--r-- | pc/config.h | 6 | ||||
-rw-r--r-- | support/ChangeLog | 2 | ||||
-rw-r--r-- | support/dfa.h | 4 | ||||
-rw-r--r-- | support/regex.c | 3 | ||||
-rw-r--r-- | test/ChangeLog | 5 | ||||
-rw-r--r-- | test/Makefile.am | 4 | ||||
-rw-r--r-- | test/Makefile.in | 9 | ||||
-rw-r--r-- | test/Maketests | 5 | ||||
-rw-r--r-- | test/numstr1.awk | 7 | ||||
-rw-r--r-- | test/numstr1.ok | 2 |
28 files changed, 242 insertions, 272 deletions
@@ -103,6 +103,25 @@ * field.c (do_split): Simplify the lint warnings. Based on suggested code by Eric Pruitt <eric.pruitt@gmail.com>. + Unrelated: + + * awkgram.y (check_funcs): Remove the REALLYMEAN ifdef and + simplify the lint checking code for function defined but not + called or called but not defined. + +2017-10-13 Arnold D. Robbins <arnold@skeeve.com> + + Assume a more C99 environment: + + * awk.h: Assume we have limits.h, stdarg.h and stdbool.h. + * configure.ac: Remove checks for limits.h and stdarg.h. + +2017-10-10 Arnold D. Robbins <arnold@skeeve.com> + + * configure.ac: Remove --with-whiny-user-strftime option. + * NEWS: Updated. + * ChangeLog.0: Fix a typo. :-) + 2017-10-08 Arnold D. Robbins <arnold@skeeve.com> * command.y: Fix the FSF's address. @@ -122,6 +141,14 @@ 2017-10-02 Arnold D. Robbins <arnold@skeeve.com> + Undo change of 2014-09-07: + + * configure.ac: Remove the undocumented option to enable locale + letters in identifiers. + * awkgram.y (is_alpha): Remove related code. + +2017-10-02 Arnold D. Robbins <arnold@skeeve.com> + * config.guess, config.sub: Updated. 2017-09-28 Arnold D. Robbins <arnold@skeeve.com> @@ -3810,6 +3837,7 @@ * configure.ac: Add an option to enable locale letters in identifiers. Undocumented and subject to being rescinded at any time in the future. + * awkgram.y (is_alpha): Actual code is here. * NEWS: Mention to look at configure --help. Unrelated: diff --git a/ChangeLog.0 b/ChangeLog.0 index af6bd99f..595442d4 100644 --- a/ChangeLog.0 +++ b/ChangeLog.0 @@ -7020,7 +7020,7 @@ Tue Dec 4 17:54:30 2001 Arnold D. Robbins <arnold@skeeve.com> * configure.in (AC_ARG_WITH): Add appropriate code for autoconf. * accondig.h (USE_INCLUDED_STRFTIME): Add #undef for it. - * custom.h (USE_INCLUDED_STRFTIME): Set things up write. + * custom.h (USE_INCLUDED_STRFTIME): Set things up right. Tue Dec 4 16:44:07 2001 Andreas Buening <andreas.buening@nexgo.de> @@ -5,6 +5,16 @@ are permitted in any medium without royalty provided the copyright notice and this notice are preserved. +Changes from 4.2.x to 5.0.0 +--------------------------- + +1. The undocumented configure option and code that enabled the use of + non-English "letters" in identifiers is now gone. + +2. The `--with-whiny-user-strftime' configuration option is now gone. + +3. The code now makes some stronger assumptions about a C99 environment. + Changes from 4.2.0 to 4.2.1 --------------------------- @@ -53,9 +53,7 @@ #include <stdio.h> #include <assert.h> -#ifdef HAVE_LIMITS_H #include <limits.h> -#endif /* HAVE_LIMITS_H */ #include <ctype.h> #include <setjmp.h> @@ -73,11 +71,8 @@ #error "gawk no longer supports non-C89 environments (no __STDC__ or __STDC__ < 1)" #endif -#if defined(HAVE_STDARG_H) #include <stdarg.h> -#else -#error "gawk no longer supports <varargs.h>. Please update your compiler and runtime" -#endif +#include <stdbool.h> #include <signal.h> #include <time.h> #include <errno.h> @@ -89,11 +84,6 @@ extern int errno; #include <stdlib.h> #endif /* not STDC_HEADERS */ -#ifdef HAVE_STDBOOL_H -#include <stdbool.h> -#else -#include "missing_d/gawkbool.h" -#endif /* We can handle multibyte strings. */ #include <wchar.h> @@ -7358,22 +7358,19 @@ check_funcs() for (i = 0; i < HASHSIZE; i++) { for (fp = ftable[i]; fp != NULL; fp = fp->next) { -#ifdef REALLYMEAN - /* making this the default breaks old code. sigh. */ - if (fp->defined == 0 && ! fp->extension) { - error( - _("function `%s' called but never defined"), fp->name); - errcount++; - } -#else - if (do_lint && fp->defined == 0 && ! fp->extension) - lintwarn( - _("function `%s' called but never defined"), fp->name); -#endif + if (do_lint && ! fp->extension) { + /* + * Making this not a lint check and + * incrementing * errcount breaks old code. + * Sigh. + */ + if (fp->defined == 0) + lintwarn(_("function `%s' called but never defined"), + fp->name); - if (do_lint && fp->used == 0 && ! fp->extension) { - lintwarn(_("function `%s' defined but never called directly"), - fp->name); + if (fp->used == 0) + lintwarn(_("function `%s' defined but never called directly"), + fp->name); } } } @@ -8703,9 +8700,6 @@ install_builtins(void) bool is_alpha(int c) { -#ifdef I_DONT_KNOW_WHAT_IM_DOING - return isalpha(c); -#else /* ! I_DONT_KNOW_WHAT_IM_DOING */ switch (c) { case 'a': case 'b': case 'c': case 'd': case 'e': case 'f': case 'g': case 'h': case 'i': case 'j': case 'k': case 'l': @@ -8720,7 +8714,6 @@ is_alpha(int c) return true; } return false; -#endif /* ! I_DONT_KNOW_WHAT_IM_DOING */ } /* is_alnum --- return true for alphanumeric, English only letters */ @@ -4938,22 +4938,19 @@ check_funcs() for (i = 0; i < HASHSIZE; i++) { for (fp = ftable[i]; fp != NULL; fp = fp->next) { -#ifdef REALLYMEAN - /* making this the default breaks old code. sigh. */ - if (fp->defined == 0 && ! fp->extension) { - error( - _("function `%s' called but never defined"), fp->name); - errcount++; - } -#else - if (do_lint && fp->defined == 0 && ! fp->extension) - lintwarn( - _("function `%s' called but never defined"), fp->name); -#endif + if (do_lint && ! fp->extension) { + /* + * Making this not a lint check and + * incrementing * errcount breaks old code. + * Sigh. + */ + if (fp->defined == 0) + lintwarn(_("function `%s' called but never defined"), + fp->name); - if (do_lint && fp->used == 0 && ! fp->extension) { - lintwarn(_("function `%s' defined but never called directly"), - fp->name); + if (fp->used == 0) + lintwarn(_("function `%s' defined but never called directly"), + fp->name); } } } @@ -6283,9 +6280,6 @@ install_builtins(void) bool is_alpha(int c) { -#ifdef I_DONT_KNOW_WHAT_IM_DOING - return isalpha(c); -#else /* ! I_DONT_KNOW_WHAT_IM_DOING */ switch (c) { case 'a': case 'b': case 'c': case 'd': case 'e': case 'f': case 'g': case 'h': case 'i': case 'j': case 'k': case 'l': @@ -6300,7 +6294,6 @@ is_alpha(int c) return true; } return false; -#endif /* ! I_DONT_KNOW_WHAT_IM_DOING */ } /* is_alnum --- return true for alphanumeric, English only letters */ @@ -108,9 +108,6 @@ /* Define if you have the libsigsegv library. */ #undef HAVE_LIBSIGSEGV -/* Define to 1 if you have the <limits.h> header file. */ -#undef HAVE_LIMITS_H - /* Define to 1 if you have the <locale.h> header file. */ #undef HAVE_LOCALE_H @@ -186,9 +183,6 @@ /* we have sockets on this system */ #undef HAVE_SOCKETS -/* Define to 1 if you have the <stdarg.h> header file. */ -#undef HAVE_STDARG_H - /* Define to 1 if stdbool.h conforms to C99. */ #undef HAVE_STDBOOL_H @@ -341,9 +335,6 @@ /* Define to 1 if you have the `__etoa_l' function. */ #undef HAVE___ETOA_L -/* enable severe portability problems */ -#undef I_DONT_KNOW_WHAT_IM_DOING - /* disable lint checks */ #undef NO_LINT @@ -395,9 +386,6 @@ /* Define to 1 if the character set is EBCDIC */ #undef USE_EBCDIC -/* force use of our version of strftime */ -#undef USE_INCLUDED_STRFTIME - /* Enable extensions on AIX 3, Interix. */ #ifndef _ALL_SOURCE # undef _ALL_SOURCE @@ -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.2.0b. +# Generated by GNU Autoconf 2.69 for GNU Awk 4.2.60. # # 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.2.0b' -PACKAGE_STRING='GNU Awk 4.2.0b' +PACKAGE_VERSION='4.2.60' +PACKAGE_STRING='GNU Awk 4.2.60' PACKAGE_BUGREPORT='bug-gawk@gnu.org' PACKAGE_URL='http://www.gnu.org/software/gawk/' @@ -763,9 +763,7 @@ ac_subst_files='' ac_user_opts=' enable_option_checking enable_silent_rules -with_whiny_user_strftime enable_lint -enable_severe_portability_problems enable_builtin_intdiv0 enable_mpfr enable_versioned_extension_dir @@ -1332,7 +1330,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.2.0b to adapt to many kinds of systems. +\`configure' configures GNU Awk 4.2.60 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1402,7 +1400,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of GNU Awk 4.2.0b:";; + short | recursive ) echo "Configuration of GNU Awk 4.2.60:";; esac cat <<\_ACEOF @@ -1413,8 +1411,6 @@ Optional Features: --enable-silent-rules less verbose build output (undo: "make V=1") --disable-silent-rules verbose build output (undo: "make V=0") --disable-lint do not compile in gawk lint checking - --enable-severe-portability-problems - allow really nasty portability problems --enable-builtin-intdiv0 enable built-in intdiv0 function --disable-mpfr do not check for MPFR @@ -1432,9 +1428,6 @@ Optional Features: Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) - --with-whiny-user-strftime - force use of included version of strftime for - deficient systems --with-gnu-ld assume the C compiler uses GNU ld [default=no] --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib --without-libiconv-prefix don't search for libiconv in includedir and libdir @@ -1529,7 +1522,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -GNU Awk configure 4.2.0b +GNU Awk configure 4.2.60 generated by GNU Autoconf 2.69 Copyright (C) 2012 Free Software Foundation, Inc. @@ -2238,7 +2231,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.2.0b, which was +It was created by GNU Awk $as_me 4.2.60, which was generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ @@ -3121,7 +3114,7 @@ fi # Define the identity of the package. PACKAGE='gawk' - VERSION='4.2.0b' + VERSION='4.2.60' cat >>confdefs.h <<_ACEOF @@ -3217,18 +3210,6 @@ fi - -# Check whether --with-whiny-user-strftime was given. -if test "${with_whiny_user_strftime+set}" = set; then : - withval=$with_whiny_user_strftime; if test "$withval" = yes - then - -$as_echo "#define USE_INCLUDED_STRFTIME 1" >>confdefs.h - - fi - -fi - # Check whether --enable-lint was given. if test "${enable_lint+set}" = set; then : enableval=$enable_lint; if test "$enableval" = no @@ -3240,17 +3221,6 @@ $as_echo "#define NO_LINT 1" >>confdefs.h fi -# Check whether --enable-severe-portability-problems was given. -if test "${enable_severe_portability_problems+set}" = set; then : - enableval=$enable_severe_portability_problems; if test "$enableval" = yes - then - -$as_echo "#define I_DONT_KNOW_WHAT_IM_DOING 1" >>confdefs.h - - fi - -fi - # Check whether --enable-builtin-intdiv0 was given. if test "${enable_builtin_intdiv0+set}" = set; then : enableval=$enable_builtin_intdiv0; if test "$enableval" = yes @@ -8048,8 +8018,8 @@ $as_echo "#define HAVE_LC_MESSAGES 1" >>confdefs.h fi -for ac_header in arpa/inet.h fcntl.h limits.h locale.h libintl.h mcheck.h \ - netdb.h netinet/in.h stdarg.h stddef.h string.h \ +for ac_header in arpa/inet.h fcntl.h locale.h libintl.h mcheck.h \ + netdb.h netinet/in.h stddef.h string.h \ sys/ioctl.h sys/param.h sys/select.h sys/socket.h sys/time.h unistd.h \ termios.h stropts.h wchar.h wctype.h do : @@ -11573,7 +11543,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.2.0b, which was +This file was extended by GNU Awk $as_me 4.2.60, which was generated by GNU Autoconf 2.69. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -11641,7 +11611,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.2.0b +GNU Awk config.status 4.2.60 configured by $0, generated by GNU Autoconf 2.69, with options \\"\$ac_cs_config\\" diff --git a/configure.ac b/configure.ac index 8ef3826d..fd7b73ae 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.2.0b],[bug-gawk@gnu.org],[gawk]) +AC_INIT([GNU Awk],[4.2.60],[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. @@ -44,15 +44,6 @@ AM_INIT_AUTOMAKE([1.15 dist-xz dist-lzip]) AC_CONFIG_MACRO_DIR([m4]) -dnl Additional argument stuff -AC_ARG_WITH(whiny-user-strftime, - [AS_HELP_STRING([--with-whiny-user-strftime], [force use of included version of strftime for deficient systems])], - if test "$withval" = yes - then - AC_DEFINE(USE_INCLUDED_STRFTIME, 1, - [force use of our version of strftime]) - fi -) AC_ARG_ENABLE([lint], [AS_HELP_STRING([--disable-lint],[do not compile in gawk lint checking])], if test "$enableval" = no @@ -60,13 +51,6 @@ AC_ARG_ENABLE([lint], AC_DEFINE(NO_LINT, 1, [disable lint checks]) fi ) -AC_ARG_ENABLE([severe-portability-problems], - [AS_HELP_STRING([--enable-severe-portability-problems],[allow really nasty portability problems])], - if test "$enableval" = yes - then - AC_DEFINE(I_DONT_KNOW_WHAT_IM_DOING, 1, [enable severe portability problems]) - fi -) AC_ARG_ENABLE([builtin-intdiv0], [AS_HELP_STRING([--enable-builtin-intdiv0],[enable built-in intdiv0 function])], if test "$enableval" = yes @@ -172,8 +156,8 @@ AM_LANGINFO_CODESET gt_LC_MESSAGES dnl checks for header files -AC_CHECK_HEADERS(arpa/inet.h fcntl.h limits.h locale.h libintl.h mcheck.h \ - netdb.h netinet/in.h stdarg.h stddef.h string.h \ +AC_CHECK_HEADERS(arpa/inet.h fcntl.h locale.h libintl.h mcheck.h \ + netdb.h netinet/in.h stddef.h string.h \ sys/ioctl.h sys/param.h sys/select.h sys/socket.h sys/time.h unistd.h \ termios.h stropts.h wchar.h wctype.h) AC_HEADER_STDC @@ -48,11 +48,6 @@ #define HAVE_MKTIME 1 #endif -/* For whiny users */ -#ifdef USE_INCLUDED_STRFTIME -#undef HAVE_STRFTIME -#endif - /* For HP/UX with gcc */ #if defined(hpux) || defined(_HPUX_SOURCE) #undef HAVE_TZSET diff --git a/doc/ChangeLog b/doc/ChangeLog index c675db61..b19a57b6 100644 --- a/doc/ChangeLog +++ b/doc/ChangeLog @@ -85,7 +85,12 @@ function to be syntactically and semantically correct. Thanks to Jaromir Obr <jaromir.obr@gmail.com> for the report. (POSIX String Comparison): Add some URL references in @ignore. - + + Unrelated: + + * gawktexi.in: Remove description of --with-whiny-user-strftime + configuration option. + 2017-10-08 Andrew J. Schorr <aschorr@telemetry-investments.com> * gawktexi.in: Fix discussion of AWKPATH in section on @include. diff --git a/doc/gawk.info b/doc/gawk.info index 68aa1848..c3c4e8e7 100644 --- a/doc/gawk.info +++ b/doc/gawk.info @@ -28985,10 +28985,6 @@ command line when compiling 'gawk' from scratch, including: possible to keep extensions for different API versions on the same system without their conflicting with one another. -'--with-whiny-user-strftime' - Force use of the included version of the C 'strftime()' function - for deficient systems. - Use the command './configure --help' to see the full list of options supplied by 'configure'. @@ -32929,8 +32925,6 @@ Index * --traditional option, --posix option and: Options. (line 286) * --use-lc-numeric option: Options. (line 232) * --version option: Options. (line 318) -* --with-whiny-user-strftime configuration option: Additional Configuration Options. - (line 48) * -b option: Options. (line 69) * -c option: Options. (line 82) * -C option: Options. (line 89) @@ -33637,8 +33631,6 @@ Index (line 37) * configuration option, --enable-versioned-extension-dir: Additional Configuration Options. (line 42) -* configuration option, --with-whiny-user-strftime: Additional Configuration Options. - (line 48) * configuration options, gawk: Additional Configuration Options. (line 6) * constant regexps: Regexp Usage. (line 57) @@ -36477,58 +36469,58 @@ Node: Unix Installation1163598 Node: Quick Installation1164280 Node: Shell Startup Files1166694 Node: Additional Configuration Options1167783 -Node: Configuration Philosophy1170076 -Node: Non-Unix Installation1172445 -Node: PC Installation1172905 -Node: PC Binary Installation1173743 -Node: PC Compiling1174178 -Node: PC Using1175295 -Node: Cygwin1178340 -Node: MSYS1179110 -Node: VMS Installation1179611 -Node: VMS Compilation1180402 -Ref: VMS Compilation-Footnote-11181631 -Node: VMS Dynamic Extensions1181689 -Node: VMS Installation Details1183374 -Node: VMS Running1185627 -Node: VMS GNV1189906 -Node: VMS Old Gawk1190641 -Node: Bugs1191112 -Node: Bug address1191775 -Node: Usenet1194567 -Node: Maintainers1195344 -Node: Other Versions1196605 -Node: Installation summary1203367 -Node: Notes1204569 -Node: Compatibility Mode1205434 -Node: Additions1206216 -Node: Accessing The Source1207141 -Node: Adding Code1208578 -Node: New Ports1214797 -Node: Derived Files1219285 -Ref: Derived Files-Footnote-11224931 -Ref: Derived Files-Footnote-21224966 -Ref: Derived Files-Footnote-31225564 -Node: Future Extensions1225678 -Node: Implementation Limitations1226336 -Node: Extension Design1227519 -Node: Old Extension Problems1228673 -Ref: Old Extension Problems-Footnote-11230191 -Node: Extension New Mechanism Goals1230248 -Ref: Extension New Mechanism Goals-Footnote-11233612 -Node: Extension Other Design Decisions1233801 -Node: Extension Future Growth1235914 -Node: Old Extension Mechanism1236750 -Node: Notes summary1238513 -Node: Basic Concepts1239695 -Node: Basic High Level1240376 -Ref: figure-general-flow1240658 -Ref: figure-process-flow1241343 -Ref: Basic High Level-Footnote-11244644 -Node: Basic Data Typing1244829 -Node: Glossary1248157 -Node: Copying1279995 -Node: GNU Free Documentation License1317534 -Node: Index1342652 +Node: Configuration Philosophy1169948 +Node: Non-Unix Installation1172317 +Node: PC Installation1172777 +Node: PC Binary Installation1173615 +Node: PC Compiling1174050 +Node: PC Using1175167 +Node: Cygwin1178212 +Node: MSYS1178982 +Node: VMS Installation1179483 +Node: VMS Compilation1180274 +Ref: VMS Compilation-Footnote-11181503 +Node: VMS Dynamic Extensions1181561 +Node: VMS Installation Details1183246 +Node: VMS Running1185499 +Node: VMS GNV1189778 +Node: VMS Old Gawk1190513 +Node: Bugs1190984 +Node: Bug address1191647 +Node: Usenet1194439 +Node: Maintainers1195216 +Node: Other Versions1196477 +Node: Installation summary1203239 +Node: Notes1204441 +Node: Compatibility Mode1205306 +Node: Additions1206088 +Node: Accessing The Source1207013 +Node: Adding Code1208450 +Node: New Ports1214669 +Node: Derived Files1219157 +Ref: Derived Files-Footnote-11224803 +Ref: Derived Files-Footnote-21224838 +Ref: Derived Files-Footnote-31225436 +Node: Future Extensions1225550 +Node: Implementation Limitations1226208 +Node: Extension Design1227391 +Node: Old Extension Problems1228545 +Ref: Old Extension Problems-Footnote-11230063 +Node: Extension New Mechanism Goals1230120 +Ref: Extension New Mechanism Goals-Footnote-11233484 +Node: Extension Other Design Decisions1233673 +Node: Extension Future Growth1235786 +Node: Old Extension Mechanism1236622 +Node: Notes summary1238385 +Node: Basic Concepts1239567 +Node: Basic High Level1240248 +Ref: figure-general-flow1240530 +Ref: figure-process-flow1241215 +Ref: Basic High Level-Footnote-11244516 +Node: Basic Data Typing1244701 +Node: Glossary1248029 +Node: Copying1279867 +Node: GNU Free Documentation License1317406 +Node: Index1342524 End Tag Table diff --git a/doc/gawk.texi b/doc/gawk.texi index f0a0c26d..ba042aae 100644 --- a/doc/gawk.texi +++ b/doc/gawk.texi @@ -39541,11 +39541,6 @@ include the major and minor API versions in it. This makes it possible to keep extensions for different API versions on the same system without their conflicting with one another. -@cindex @option{--with-whiny-user-strftime} configuration option -@cindex configuration option, @code{--with-whiny-user-strftime} -@item --with-whiny-user-strftime -Force use of the included version of the C @code{strftime()} -function for deficient systems. @end table Use the command @samp{./configure --help} to see the full list of diff --git a/doc/gawktexi.in b/doc/gawktexi.in index a7406d62..dab833d4 100644 --- a/doc/gawktexi.in +++ b/doc/gawktexi.in @@ -38554,11 +38554,6 @@ include the major and minor API versions in it. This makes it possible to keep extensions for different API versions on the same system without their conflicting with one another. -@cindex @option{--with-whiny-user-strftime} configuration option -@cindex configuration option, @code{--with-whiny-user-strftime} -@item --with-whiny-user-strftime -Force use of the included version of the C @code{strftime()} -function for deficient systems. @end table Use the command @samp{./configure --help} to see the full list of diff --git a/doc/it/ChangeLog b/doc/it/ChangeLog index d38f9860..7cfe6a07 100644 --- a/doc/it/ChangeLog +++ b/doc/it/ChangeLog @@ -2,6 +2,10 @@ * gawk.1: New file. (Italian translation of the man page.) +2017-12-05 Antonio Giovanni Colombo <azc100@gmail.com> + + * gawktexi.in: Italian translation updated. + 2017-10-19 Arnold D. Robbins <arnold@skeeve.com> * 4.2.0: Release tar ball made. diff --git a/doc/it/gawktexi.in b/doc/it/gawktexi.in index aa99d614..c3cd68f3 100644 --- a/doc/it/gawktexi.in +++ b/doc/it/gawktexi.in @@ -14916,8 +14916,8 @@ awk ' @end example @noindent -Questo programma stampa i primi tre campi di ogni record in input, mettendo -un campo su ogni riga. +Questo programma stampa i primi tre campi di ogni record in input, +mettendo un unico campo in una riga in output. Non @`e possibile impostare pi@`u di una variabile nella parte di @@ -33385,14 +33385,15 @@ La corrispondenza tra @code{ROUNDMODE} e le modalit@`a di arrotondamento IEEE @item Arrotonda verso infinito @tab @code{roundTowardPositive} @tab @code{"U"} o @code{"u"} @item Arrotonda verso meno infinito @tab @code{roundTowardNegative} @tab @code{"D"} o @code{"d"} @item Arrotonda verso zero (troncamento) @tab @code{roundTowardZero} @tab @code{"Z"} o @code{"z"} -@item Arrotonda al pi@`u vicino, o per eccesso @tab @code{roundTiesToAway} @tab @code{"A"} o @code{"a"} +@item Arrotonda lontano da zero (per eccesso) @tab @tab @code{"A"} o @code{"a"} @end multitable @end float @code{ROUNDMODE} ha @code{"N"} come valore di default, ovvero si usa la modalit@`a di arrotondamento IEEE 754 @code{roundTiesToEven}. In @ref{table-gawk-rounding-modes}, il valore @code{"A"} seleziona -@code{roundTiesToAway}. Questo @`e applicabile solo se la versione in uso +l'arrotondamento lontano da zero (per eccesso). +Questo @`e applicabile solo se la versione in uso della libreria MPFR lo supporta; altrimenti, l'impostazione di @code{ROUNDMODE} ad @code{"A"} non ha alcun effetto. @@ -33455,9 +33456,8 @@ intervalli, dove si adotta questa modalit@`a di arrotondamento per calcolare i limiti superiore e inferiore per l'intervallo di valori in uscita. La modalit@`a @code{roundTowardZero} pu@`o essere usata per convertire numeri a virgola mobile -in numeri interi. La modalit@`a di arrotondamento @code{roundTiesToAway} -arrotonda il risultato al numero pi@`u vicino, e in caso di equidistanza -arrotonda per eccesso. +in numeri interi. Quando si arrotonda lontano da zero (per eccesso), viene +scelto il numero pi@`u vicino di grandezza maggiore o uguale al valore. Qualche esperto di analisi numerica dir@`a che la scelta dello stile di arrotondamento ha un grandissimo impatto sul risultato finale, e consiglier@`a @@ -34524,13 +34524,19 @@ e ogni campo @`e del tipo appropriato. L'uso di queste macro rende pi@`u facile da seguire l'accesso ai campi di @code{awk_value_t}. +@item enum AWK_NUMBER_TYPE @{ +@itemx @ @ @ @ AWK_NUMBER_TYPE_DOUBLE, +@itemx @ @ @ @ AWK_NUMBER_TYPE_MPFR, +@itemx @ @ @ @ AWK_NUMBER_TYPE_MPZ +@itemx @}; +La lista @code{enum} @`e usata nella struttura seguente per definire +il tipo di valore numerico con cui si ha a che fare. Va dichiarata al +livello pi@`u alto del file, in modo da poter essere usata sia con il +linguaggio C++ che con il C. + @item typedef struct awk_number @{ @itemx @ @ @ @ double d; -@itemx @ @ @ @ enum AWK_NUMBER_TYPE @{ -@itemx @ @ @ @ @ @ @ @ AWK_NUMBER_TYPE_DOUBLE, -@itemx @ @ @ @ @ @ @ @ AWK_NUMBER_TYPE_MPFR, -@itemx @ @ @ @ @ @ @ @ AWK_NUMBER_TYPE_MPZ -@itemx @ @ @ @ @} type; +@itemx @ @ @ @ enum AWK_NUMBER_TYPE type; @itemx @ @ @ @ void *ptr; @itemx @} awk_number_t; Questo rappresenta un valore numerico. Internamente, @command{gawk} @@ -34547,7 +34553,6 @@ da @code{ptr} sia un numero intero GMP (tipo @code{mpz_ptr}), o un numero MPFR a virgola mobile (tipo @code{mpfr_ptr_t}), e trasformarlo a seconda delle necessit@`a. - @item typedef void *awk_scalar_t; La variabili scalari possono essere rappresentate da un tipo opaco. Questi valori sono ottenuti da @command{gawk} e in seguito gli vengono restituiti. @@ -37236,6 +37241,49 @@ compilazione, l'API rimane compatibile a livello di codice sorgente con la precedente versione API. Le differenze pi@`u rilevanti sono gli ulteriori campi nella struttura @code{awk_ext_func_t}, e l'aggiunta del terzo argomento nella funzione di implementazione in linguaggio C. +(@pxref{Funzioni di estensione}). + +Quella che segue @`e una lista di singole funzionalit@`a che sono +state modificate nella versione 2 rispetto alla versione 1 dell'API: + +@itemize @bullet + +@item +I valori numerici possono ora essere anche di tipo MPFR/MPZ +(@pxref{Tipi di dati generali}). + +@item +Ci sono nuovi tipi di stringa: @code{AWK_REGEX} e @code{AWK_STRNUM} +(@pxref{Tipi di dati generali}). + +@item +@`E disponibile la nuova macro @code{ezalloc()} +(@pxref{Funzioni di allocazione memoria}). + +@item +La struttura @code{awk_ext_func_t} @`e stata modificata. Invece del +parametro @code{num_expected_args}, ha ora i due parametri +@code{max_expected} e @code{min_required} +(@pxref{Funzioni di estensione}). + +@item +In @code{get_record()}, un analizzatore di input pu@`o ora specificare +l'ampiezza dei campi +(@pxref{Analizzatori di input}). + +@item +Le estensioni possono ora inviare messaggi di errore non fatali +(@pxref{Stampare messaggi}). + +@item +Quando di appiattisce un vettore, si pu@`o ora specificare il tipo +dell'indice e quello dei valori +(@pxref{Funzioni per i vettori}). + +@item +C'@`e una nuova API, @code{get_file()} +(@pxref{Ridirezione API}). +@end itemize @node Trovare le estensioni @section Come @command{gawk} trova le estensioni compilate @@ -41603,13 +41651,6 @@ il supporto MPFR non sia disponibile. Non attiva la traduzione automatica dei messaggi. Ci@`o normalmente non @`e consigliabile, ma pu@`o apportare qualche lieve miglioramento nei tempi di esecuzione di un programma. - -@cindex @option{--with-whiny-user-strftime}, opzione di configurazione -@cindex opzione di configurazione @code{--with-whiny-user-strftime} -@item --with-whiny-user-strftime -Forza l'uso della versione della funzione C @code{strftime()} inclusa nella -distribuzione di @command{gawk}, per i sistemi in cui la funzione stessa -non sia disponibile. @end table Si usi il comando @samp{./configure --help} per ottenere la lista completa diff --git a/missing_d/ChangeLog b/missing_d/ChangeLog index 871f5e50..8043677a 100644 --- a/missing_d/ChangeLog +++ b/missing_d/ChangeLog @@ -6,6 +6,10 @@ * 4.2.0: Release tar ball made. +2017-10-13 Arnold D. Robbins <arnold@skeeve.com> + + * gawkbool.h: Removed. + 2017-10-08 Arnold D. Robbins <arnold@skeeve.com> * strncasecmp.c: Fix FSF's address. diff --git a/missing_d/gawkbool.h b/missing_d/gawkbool.h deleted file mode 100644 index c75a5a10..00000000 --- a/missing_d/gawkbool.h +++ /dev/null @@ -1,40 +0,0 @@ -/* - * gawkbool.h -- replacement definitions for bool. - */ - -/* - * 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 - */ - -/* This stuff largely taken from the Autoconf doc. */ - -#ifndef __bool_true_false_are_defined -# ifndef HAVE__BOOL -# ifdef __cplusplus -typedef bool _Bool; -# else -# define _Bool signed char -# endif -# endif -# define bool _Bool -# define false 0 -# define true 1 -# define __bool_true_false_are_defined 1 -#endif diff --git a/pc/config.h b/pc/config.h index 28908ef9..17c2c18a 100644 --- a/pc/config.h +++ b/pc/config.h @@ -462,7 +462,7 @@ #define PACKAGE_NAME "GNU Awk" /* Define to the full name and version of this package. */ -#define PACKAGE_STRING "GNU Awk 4.2.0b" +#define PACKAGE_STRING "GNU Awk 4.2.60" /* Define to the one symbol short name of this package. */ #define PACKAGE_TARNAME "gawk" @@ -471,7 +471,7 @@ #define PACKAGE_URL "http://www.gnu.org/software/gawk/" /* Define to the version of this package. */ -#define PACKAGE_VERSION "4.2.0b" +#define PACKAGE_VERSION "4.2.60" /* Define to 1 if *printf supports %F format */ #ifdef __DJGPP__ @@ -528,7 +528,7 @@ /* Version number of package */ -#define VERSION "4.2.0b" +#define VERSION "4.2.60" /* Enable large inode numbers on Mac OS X 10.5. */ #ifndef _DARWIN_USE_64_BIT_INODE diff --git a/support/ChangeLog b/support/ChangeLog index 9756b4a2..58669a5c 100644 --- a/support/ChangeLog +++ b/support/ChangeLog @@ -33,6 +33,8 @@ * intprops.h: Sync with GNULIB. * regcomp.c (init_word): Move general_case label inside ifdef. * regex.h: Don't define __USE_GNU. Brings closer to GLIBC regex. + * regex.c: Don't include gawkbool.h, we don't use it anymore. + * dfa.h: Ditto. 2017-11-26 Arnold D. Robbins <arnold@skeeve.com> diff --git a/support/dfa.h b/support/dfa.h index 7d11f05d..79ada1e2 100644 --- a/support/dfa.h +++ b/support/dfa.h @@ -19,11 +19,7 @@ /* Written June, 1988 by Mike Haertel */ #include <regex.h> -#ifdef HAVE_STDBOOL_H #include <stdbool.h> -#else -#include "missing_d/gawkbool.h" -#endif /* HAVE_STDBOOL_H */ #include <stddef.h> #if 3 <= __GNUC__ diff --git a/support/regex.c b/support/regex.c index d3a44851..dc8caf69 100644 --- a/support/regex.c +++ b/support/regex.c @@ -69,9 +69,6 @@ #include "regex_internal.h" #include "regex_internal.c" -#ifndef HAVE_STDBOOL_H -#include "missing_d/gawkbool.h" -#endif #include "regcomp.c" #include "regexec.c" diff --git a/test/ChangeLog b/test/ChangeLog index 1e1cf7ea..26fd2d48 100644 --- a/test/ChangeLog +++ b/test/ChangeLog @@ -1,3 +1,8 @@ +2017-12-28 Arnold D. Robbins <arnold@skeeve.com> + + * Makefile.am (EXTRA_DIST): Add numstr1 files. + * numstr1.awk, numstr1.ok: New files. + 2017-11-14 Andrew J. Schorr <aschorr@telemetry-investments.com> * Makefile.am (EXTRA_DIST): Add new tests setrec0 and setrec1. diff --git a/test/Makefile.am b/test/Makefile.am index 1438e083..0fa74b2c 100644 --- a/test/Makefile.am +++ b/test/Makefile.am @@ -747,6 +747,8 @@ EXTRA_DIST = \ numindex.awk \ numindex.in \ numindex.ok \ + numstr1.awk \ + numstr1.ok \ numsubstr.awk \ numsubstr.in \ numsubstr.ok \ @@ -1224,7 +1226,7 @@ BASIC_TESTS = \ manglprm math membug1 memleak messages minusstr mmap8k mtchi18n \ nasty nasty2 negexp negrange nested nfldstr nfloop nfneg nfset nlfldsep \ nlinstr nlstrina noeffect nofile nofmtch noloop1 noloop2 nonl noparms \ - nors nulinsrc nulrsend numindex numsubstr \ + nors nulinsrc nulrsend numindex numstr1 numsubstr \ octsub ofmt ofmta ofmtbig ofmtfidl ofmts ofmtstrnum ofs1 onlynl \ opasnidx opasnslf \ paramasfunc1 paramasfunc2 paramdup paramres paramtyp paramuninitglobal \ diff --git a/test/Makefile.in b/test/Makefile.in index 5a190d7a..493bf9fa 100644 --- a/test/Makefile.in +++ b/test/Makefile.in @@ -1005,6 +1005,8 @@ EXTRA_DIST = \ numindex.awk \ numindex.in \ numindex.ok \ + numstr1.awk \ + numstr1.ok \ numsubstr.awk \ numsubstr.in \ numsubstr.ok \ @@ -1481,7 +1483,7 @@ BASIC_TESTS = \ manglprm math membug1 memleak messages minusstr mmap8k mtchi18n \ nasty nasty2 negexp negrange nested nfldstr nfloop nfneg nfset nlfldsep \ nlinstr nlstrina noeffect nofile nofmtch noloop1 noloop2 nonl noparms \ - nors nulinsrc nulrsend numindex numsubstr \ + nors nulinsrc nulrsend numindex numstr1 numsubstr \ octsub ofmt ofmta ofmtbig ofmtfidl ofmts ofmtstrnum ofs1 onlynl \ opasnidx opasnslf \ paramasfunc1 paramasfunc2 paramdup paramres paramtyp paramuninitglobal \ @@ -3494,6 +3496,11 @@ numindex: @AWKPATH="$(srcdir)" $(AWK) -f $@.awk < "$(srcdir)"/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) "$(srcdir)"/$@.ok _$@ && rm -f _$@ +numstr1: + @echo $@ + @AWKPATH="$(srcdir)" $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) "$(srcdir)"/$@.ok _$@ && rm -f _$@ + numsubstr: @echo $@ @AWKPATH="$(srcdir)" $(AWK) -f $@.awk < "$(srcdir)"/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ diff --git a/test/Maketests b/test/Maketests index f64b8640..6a685101 100644 --- a/test/Maketests +++ b/test/Maketests @@ -620,6 +620,11 @@ numindex: @AWKPATH="$(srcdir)" $(AWK) -f $@.awk < "$(srcdir)"/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ @-$(CMP) "$(srcdir)"/$@.ok _$@ && rm -f _$@ +numstr1: + @echo $@ + @AWKPATH="$(srcdir)" $(AWK) -f $@.awk >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ + @-$(CMP) "$(srcdir)"/$@.ok _$@ && rm -f _$@ + numsubstr: @echo $@ @AWKPATH="$(srcdir)" $(AWK) -f $@.awk < "$(srcdir)"/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@ diff --git a/test/numstr1.awk b/test/numstr1.awk new file mode 100644 index 00000000..e58404fc --- /dev/null +++ b/test/numstr1.awk @@ -0,0 +1,7 @@ +BEGIN { + split("1.234", f) + OFMT = "%.1f" + print f[1] + x = f[1]+0 + print f[1] +} diff --git a/test/numstr1.ok b/test/numstr1.ok new file mode 100644 index 00000000..434a231c --- /dev/null +++ b/test/numstr1.ok @@ -0,0 +1,2 @@ +1.234 +1.234 |