gawk-diffs
[Top][All Lists]
Advanced

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

[gawk-diffs] [SCM] gawk branch, master, updated. gawk-4.1.0-3556-g8f20ce


From: Arnold Robbins
Subject: [gawk-diffs] [SCM] gawk branch, master, updated. gawk-4.1.0-3556-g8f20ce9
Date: Sun, 2 Dec 2018 14:01:39 -0500 (EST)

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, master has been updated
       via  8f20ce9c6198e6c2f4705e4d53084fd48cd30a75 (commit)
      from  ee2f450c7cf2550ca68fb205c5df22eca13e5b74 (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=8f20ce9c6198e6c2f4705e4d53084fd48cd30a75

commit 8f20ce9c6198e6c2f4705e4d53084fd48cd30a75
Author: Arnold D. Robbins <address@hidden>
Date:   Sun Dec 2 21:01:21 2018 +0200

    Additional commenting fix.

diff --git a/ChangeLog b/ChangeLog
index a96b8e6..1506190 100755
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2018-12-02         Arnold D. Robbins     <address@hidden>
+
+       * awkgram.y (mk_program): Add in leading and trailing comments
+       when program block is empty.
+
 2018-11-29         Arnold D. Robbins     <address@hidden>
 
        * awkgram.y (first_rule, func_first): Remove unused variables.
diff --git a/awkgram.c b/awkgram.c
index d467eb1..3695507 100644
--- a/awkgram.c
+++ b/awkgram.c
@@ -5075,6 +5075,16 @@ mk_program()
                        (void) list_merge(cp, beginfile_block);
                        (void) list_merge(cp, endfile_block);
 
+                       if (outer_comment != NULL) {
+                               cp = list_merge(list_create(outer_comment), cp);
+                               outer_comment = NULL;
+                       }
+
+                       if (interblock_comment != NULL) {
+                               (void) list_append(cp, interblock_comment);
+                               interblock_comment = NULL;
+                       }
+
                        goto out;
 
                } else {
diff --git a/awkgram.y b/awkgram.y
index 4187630..d925e75 100644
--- a/awkgram.y
+++ b/awkgram.y
@@ -2610,6 +2610,16 @@ mk_program()
                        (void) list_merge(cp, beginfile_block);
                        (void) list_merge(cp, endfile_block);
 
+                       if (outer_comment != NULL) {
+                               cp = list_merge(list_create(outer_comment), cp);
+                               outer_comment = NULL;
+                       }
+
+                       if (interblock_comment != NULL) {
+                               (void) list_append(cp, interblock_comment);
+                               interblock_comment = NULL;
+                       }
+
                        goto out;
 
                } else {

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

Summary of changes:
 ChangeLog |  5 +++++
 awkgram.c | 10 ++++++++++
 awkgram.y | 10 ++++++++++
 3 files changed, 25 insertions(+)


hooks/post-receive
-- 
gawk



reply via email to

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