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. 886be6b488e3fa72f78979c


From: Andrew J. Schorr
Subject: [gawk-diffs] [SCM] gawk branch, master, updated. 886be6b488e3fa72f78979c3a2cd7d31a3bc6a85
Date: Tue, 18 Dec 2012 21:38:14 +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, master has been updated
       via  886be6b488e3fa72f78979c3a2cd7d31a3bc6a85 (commit)
      from  320d5302c4a39ea7936950b2e663e37683b39fe0 (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=886be6b488e3fa72f78979c3a2cd7d31a3bc6a85

commit 886be6b488e3fa72f78979c3a2cd7d31a3bc6a85
Author: Andrew J. Schorr <address@hidden>
Date:   Tue Dec 18 16:37:19 2012 -0500

    Fix API to update the node type to Node_var when setting an undefined 
variable.

diff --git a/ChangeLog b/ChangeLog
index 73cf022..ae49f56 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2012-12-18         Andrew J. Schorr     <address@hidden>
+
+       * gawkapi.c (sym_update_real): If setting a scalar variable that exists
+       already in an undefined state with type set to Node_var_new, we must
+       update the type to Node_var if the new value is not undefined.
+
 2012-12-18         Arnold D. Robbins     <address@hidden>
 
        * awkgram.y (tokentab): "extension" needs to be inside ifdef DYNAMIC.
diff --git a/gawkapi.c b/gawkapi.c
index b67275c..cd09cdd 100644
--- a/gawkapi.c
+++ b/gawkapi.c
@@ -603,6 +603,9 @@ sym_update_real(awk_ext_id_t id,
            && (node->type == Node_var || node->type == Node_var_new)) {
                unref(node->var_value);
                node->var_value = awk_value_to_node(value);
+               if (node->type == Node_var_new && value->val_type != 
AWK_UNDEFINED)
+                       node->type = Node_var;
+
                /* let the extension change its own variable */
                if (is_const)
                        node->var_assign = set_constant;

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

Summary of changes:
 ChangeLog |    6 ++++++
 gawkapi.c |    3 +++
 2 files changed, 9 insertions(+), 0 deletions(-)


hooks/post-receive
-- 
gawk



reply via email to

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