diff options
author | Arnold D. Robbins <arnold@skeeve.com> | 2016-07-01 10:09:25 +0300 |
---|---|---|
committer | Arnold D. Robbins <arnold@skeeve.com> | 2016-07-01 10:09:25 +0300 |
commit | d8de6a38b2e4f2481a3c72477495f7a2b79da743 (patch) | |
tree | c10fbd3af1c1a31b8a5aba5827566f31223430bf | |
parent | a4cbdf37b98a56f688f8e1be96666a6f109c0e38 (diff) | |
parent | ce41ffb80b068139b4e04e3cff1d5dc2ee0ccc78 (diff) | |
download | egawk-d8de6a38b2e4f2481a3c72477495f7a2b79da743.tar.gz egawk-d8de6a38b2e4f2481a3c72477495f7a2b79da743.tar.bz2 egawk-d8de6a38b2e4f2481a3c72477495f7a2b79da743.zip |
Merge branch 'master' into feature/fixtype
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | symbol.c | 6 | ||||
-rw-r--r-- | test/ChangeLog | 1 | ||||
-rw-r--r-- | test/dumpvars.ok | 2 | ||||
-rw-r--r-- | test/symtab6.ok | 2 | ||||
-rw-r--r-- | test/symtab8.ok | 2 |
6 files changed, 17 insertions, 1 deletions
@@ -11,6 +11,11 @@ * gawkapi.c (api_warning): Fix the comment header. (api_lintwarn): Factor out the call to va_end to after the if. + Unrelated: + + * symbol.c (get_symbols): Add FUNCTAB and SYMTAB to the list + for the -d option. Thanks to Hermann Peifer for the report. + 2016-06-30 Arnold D. Robbins <arnold@skeeve.com> * node.c (r_force_number): Coding style change. @@ -409,7 +409,8 @@ get_symbols(SYMBOL_TYPE what, bool sort) max = the_table->table_size * 2; list = assoc_list(the_table, "@unsorted", ASORTI); - emalloc(table, NODE **, (var_count + 1) * sizeof(NODE *), "get_symbols"); + /* add three: one for FUNCTAB, one for SYMTAB, and one for a final NULL */ + emalloc(table, NODE **, (var_count + 1 + 1 + 1) * sizeof(NODE *), "get_symbols"); for (i = count = 0; i < max; i += 2) { r = list[i+1]; @@ -417,6 +418,9 @@ get_symbols(SYMBOL_TYPE what, bool sort) continue; table[count++] = r; } + + table[count++] = func_table; + table[count++] = symbol_table; } efree(list); diff --git a/test/ChangeLog b/test/ChangeLog index f0f346ee..d495e573 100644 --- a/test/ChangeLog +++ b/test/ChangeLog @@ -2,6 +2,7 @@ * arrayind1.awk, arrayind1.ok: Comment out prints to stderr to avoid buffer flushing on obscure systems. + * dumpvars.ok, symtab6.ok, symtab8.ok: Update after code changes. 2016-06-26 Andrew J. Schorr <aschorr@telemetry-investments.com> diff --git a/test/dumpvars.ok b/test/dumpvars.ok index 73d3d306..7caecd35 100644 --- a/test/dumpvars.ok +++ b/test/dumpvars.ok @@ -9,6 +9,7 @@ FILENAME: "-" FNR: 3 FPAT: "[^[:space:]]+" FS: " " +FUNCTAB: array, 42 elements IGNORECASE: 0 LINT: 0 NF: 1 @@ -23,4 +24,5 @@ RS: "\n" RSTART: 0 RT: "\n" SUBSEP: "\034" +SYMTAB: array, 28 elements TEXTDOMAIN: "messages" diff --git a/test/symtab6.ok b/test/symtab6.ok index 91f27e75..34c10636 100644 --- a/test/symtab6.ok +++ b/test/symtab6.ok @@ -9,6 +9,7 @@ FILENAME: "" FNR: 0 FPAT: "[^[:space:]]+" FS: " " +FUNCTAB: array, 42 elements IGNORECASE: 0 LINT: 0 NF: 0 @@ -23,4 +24,5 @@ RS: "\n" RSTART: 0 RT: "" SUBSEP: "\034" +SYMTAB: array, 29 elements TEXTDOMAIN: "messages" diff --git a/test/symtab8.ok b/test/symtab8.ok index 724f374b..0cf40fe9 100644 --- a/test/symtab8.ok +++ b/test/symtab8.ok @@ -9,6 +9,7 @@ FIELDWIDTHS: "" FNR: 1 FPAT: "[^[:space:]]+" FS: " " +FUNCTAB: array, 42 elements IGNORECASE: 0 LINT: 0 NF: 1 @@ -23,5 +24,6 @@ RS: "\n" RSTART: 0 RT: "\n" SUBSEP: "\034" +SYMTAB: array, 29 elements TEXTDOMAIN: "messages" test: 1 |