gawk-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[gawk-diffs] [SCM] gawk branch, gawk-4.1-stable, updated. gawk-4.1.0-876


From: Arnold Robbins
Subject: [gawk-diffs] [SCM] gawk branch, gawk-4.1-stable, updated. gawk-4.1.0-876-gab74a66
Date: Wed, 27 Apr 2016 15:16:54 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "gawk".

The branch, gawk-4.1-stable has been updated
       via  ab74a66c1b92c3d84ce39d764794225acc630a62 (commit)
      from  e81b0ee3ba90939adf124905d82856f7ea981af4 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://git.sv.gnu.org/cgit/gawk.git/commit/?id=ab74a66c1b92c3d84ce39d764794225acc630a62

commit ab74a66c1b92c3d84ce39d764794225acc630a62
Author: Arnold D. Robbins <address@hidden>
Date:   Wed Apr 27 18:16:28 2016 +0300

    Fix multicharacter RS in traditional/posix modes.

diff --git a/ChangeLog b/ChangeLog
index bb61054..ab7e735 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2016-04-27         Arnold D. Robbins     <address@hidden>
+
+       * io.c (set_RS): Use rs1scan if do_traditional, even if length
+       of RS is > 1.
+
 2016-04-24         Arnold D. Robbins     <address@hidden>
 
        * dfa.c: Sync with GNU grep.
diff --git a/io.c b/io.c
index 3a5748b..ca5545e 100644
--- a/io.c
+++ b/io.c
@@ -3668,7 +3668,7 @@ set_RS()
        if (RS->stlen == 0) {
                RS_is_null = true;
                matchrec = rsnullscan;
-       } else if (RS->stlen > 1) {
+       } else if (RS->stlen > 1 && ! do_traditional) {
                static bool warned = false;
 
                RS_re_yes_case = make_regexp(RS->stptr, RS->stlen, false, true, 
true);
diff --git a/test/ChangeLog b/test/ChangeLog
index be9eb7d..11908b4 100644
--- a/test/ChangeLog
+++ b/test/ChangeLog
@@ -1,3 +1,8 @@
+2016-04-27         Arnold D. Robbins     <address@hidden>
+
+       * Makefile.am (rscompat): New test.
+       * rscompat.awk, rscompat.in, rscompat.ok: New files.
+
 2016-04-24         Arnold D. Robbins     <address@hidden>
 
        * Makefile.am (pty1): Ignore errors.
diff --git a/test/Makefile.am b/test/Makefile.am
index be25403..844c87f 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -841,6 +841,9 @@ EXTRA_DIST = \
        rs.awk \
        rs.in \
        rs.ok \
+       rscompat.awk \
+       rscompat.in \
+       rscompat.ok \
        rsgetline.awk \
        rsgetline.in \
        rsgetline.ok \
@@ -1068,7 +1071,7 @@ BASIC_TESTS = \
        rand range1 readbuf rebrackloc rebt8b1 redfilnm \
        regeq regexpbrack regexpbrack2 \
        regexprange regrange reindops \
-       reparse resplit rri1 rs rsnul1nl rsnulbig rsnulbig2 rstest1 rstest2 \
+       reparse resplit rri1 rs rscompat rsnul1nl rsnulbig rsnulbig2 rstest1 
rstest2 \
        rstest3 rstest4 rstest5 rswhite \
        scalar sclforin sclifin sortempty sortglos splitargv splitarr splitdef \
        splitvar splitwht strcat1 strnum1 strtod subamp subi18n \
@@ -2140,6 +2143,11 @@ pty1:
        $(CMP) "$(srcdir)"/address@hidden _$@ && rm -f _$@ ;; \
        esac
 
+rscompat:
+       @echo $@
+       @AWKPATH="$(srcdir)" $(AWK) --traditional -f address@hidden 
"$(srcdir)/address@hidden" >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
+       @-$(CMP) "$(srcdir)"/address@hidden _$@ && rm -f _$@
+
 # Targets generated for other tests:
 include Maketests
 
diff --git a/test/Makefile.in b/test/Makefile.in
index 9346064..5e55b1b 100644
--- a/test/Makefile.in
+++ b/test/Makefile.in
@@ -1098,6 +1098,9 @@ EXTRA_DIST = \
        rs.awk \
        rs.in \
        rs.ok \
+       rscompat.awk \
+       rscompat.in \
+       rscompat.ok \
        rsgetline.awk \
        rsgetline.in \
        rsgetline.ok \
@@ -1324,7 +1327,7 @@ BASIC_TESTS = \
        rand range1 readbuf rebrackloc rebt8b1 redfilnm \
        regeq regexpbrack regexpbrack2 \
        regexprange regrange reindops \
-       reparse resplit rri1 rs rsnul1nl rsnulbig rsnulbig2 rstest1 rstest2 \
+       reparse resplit rri1 rs rscompat rsnul1nl rsnulbig rsnulbig2 rstest1 
rstest2 \
        rstest3 rstest4 rstest5 rswhite \
        scalar sclforin sclifin sortempty sortglos splitargv splitarr splitdef \
        splitvar splitwht strcat1 strnum1 strtod subamp subi18n \
@@ -2578,6 +2581,11 @@ pty1:
        *) AWKPATH="$(srcdir)" $(AWK) -f address@hidden  >_$@ 2>&1 || echo EXIT 
CODE: $$? >>_$@ ; \
        $(CMP) "$(srcdir)"/address@hidden _$@ && rm -f _$@ ;; \
        esac
+
+rscompat:
+       @echo $@
+       @AWKPATH="$(srcdir)" $(AWK) --traditional -f address@hidden 
"$(srcdir)/address@hidden" >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
+       @-$(CMP) "$(srcdir)"/address@hidden _$@ && rm -f _$@
 Gt-dummy:
 # file Maketests, generated from Makefile.am by the Gentests program
 addcomma:
diff --git a/test/rscompat.awk b/test/rscompat.awk
new file mode 100644
index 0000000..9415c70
--- /dev/null
+++ b/test/rscompat.awk
@@ -0,0 +1,2 @@
+BEGIN { RS = "bar" }
+{ print $1, $2 }
diff --git a/test/rscompat.in b/test/rscompat.in
new file mode 100644
index 0000000..eb337e5
--- /dev/null
+++ b/test/rscompat.in
@@ -0,0 +1,2 @@
+0foobar0faz
+1foobar1faz
diff --git a/test/rscompat.ok b/test/rscompat.ok
new file mode 100644
index 0000000..19cd9fb
--- /dev/null
+++ b/test/rscompat.ok
@@ -0,0 +1,3 @@
+0foo 
+ar0faz 1foo
+ar1faz 

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog         |    5 +++++
 io.c              |    2 +-
 test/ChangeLog    |    5 +++++
 test/Makefile.am  |   10 +++++++++-
 test/Makefile.in  |   10 +++++++++-
 test/rscompat.awk |    2 ++
 test/rscompat.in  |    2 ++
 test/rscompat.ok  |    3 +++
 8 files changed, 36 insertions(+), 3 deletions(-)
 create mode 100644 test/rscompat.awk
 create mode 100644 test/rscompat.in
 create mode 100644 test/rscompat.ok


hooks/post-receive
-- 
gawk



reply via email to

[Prev in Thread] Current Thread [Next in Thread]