1 2019-01-26 Arnold D. Robbins <arnold (a] skeeve.com> 2 3 * main.c (version): Updated. 4 5 2019-01-25 Arnold D. Robbins <arnold (a] skeeve.com> 6 7 * run.c (awkgetline): Check for numeric value in all getline 8 variants. See the numeric-getline.* files in bugs-fixed directory. 9 10 2018-08-29 Arnold D. Robbins <arnold (a] skeeve.com> 11 12 * REGRESS: Check for existence of a.out. If not there, run 13 make. Enable core dumps for T.arnold system status test 14 to work on MacOS X. 15 16 2018-08-22 Arnold D. Robbins <arnold (a] skeeve.com> 17 18 * awktest.tar (testdir/T.expr): Fix test for unary plus. 19 20 2018-08-22 Arnold D. Robbins <arnold (a] skeeve.com> 21 22 * REGRESS: Extract tests if necessary, set PATH to include '.'. 23 * regdir/beebe.tar (Makefile): Fix longwrds test to prefix 24 sort with LC_ALL=C. 25 * awktest.tar: Updated from fixed test suite, directory 26 it extracts is now called 'testdir' to match what's in top-level 27 REGRESS script. 28 * regdir: Removed, as Brian wants to keep the test suite in 29 the tar file. 30 31 2018-08-22 Arnold D. Robbins <arnold (a] skeeve.com> 32 33 * FIXES, lib.c, run.c, makefile, main.c: Merge from Brian's tree. 34 * REGRESS: New file, from Brian. 35 * awktest.tar: Restored from Brian's tree. 36 37 2018-08-22 Arnold D. Robbins <arnold (a] skeeve.com> 38 39 * awkgram.y (UPLUS): New token. In the grammar, call op1() 40 with it. 41 * maketab.c (proc): Add entry for UPLUS. 42 * run.c (arith): Handle UPLUS. 43 * main.c (version): Updated. 44 * bugs-fixed/unary-plus.awk, bugs-fixed/unary-plus.bad, 45 bugs-fixed/unary-plus.ok: New files. 46 47 2018-08-10 Arnold D. Robbins <arnold (a] skeeve.com> 48 49 * TODO: Updated. 50 * awk.1: Improve use of macros, add some additional explanation 51 in a few places, alphabetize list of variables. 52 53 2018-08-08 Arnold D. Robbins <arnold (a] skeeve.com> 54 55 * awk.h (Cell): Add new field `fmt' to track xFMT value used 56 for a string conversion. 57 [CONVC, CONVO]: New flag macros. 58 * bugs-fixed/README: Updated. 59 * bugs-fixed/string-conv.awk, bugs-fixed/string-conv.bad, 60 bugs-fixed/string-conv.ok: New files. 61 * main.c (version): Updated. 62 * proto.h (flags2str): Add declaration. 63 * tran.c (setfval): Clear CONVC and CONVO flags and set vp->fmt 64 to NULL. 65 (setsval): Ditto. Add large comment and new code to manage 66 correct conversion of number to string based on various flags 67 and the value of vp->fmt. The idea is to not convert again 68 if xFMT is the same as before and we're doing the same conversion. 69 Otherwise, clear the old flags, set the new, and reconvert. 70 (flags2str): New function. For debug prints and for use from a debugger. 71 72 2018-08-05 Arnold D. Robbins <arnold (a] skeeve.com> 73 74 Fix filename conflicts in regdir where the only difference was 75 in letter case. This caused problems on Windows systems. 76 77 * regdir/Compare.T1: Renamed from regdir/Compare.T. 78 * regdir/t.delete0: Renamed from regdir/t.delete. 79 * regdir/t.getline1: Renamed from regdir/t.getline. 80 * regdir/t.redir1: Renamed from regdir/t.redir. 81 * regdir/t.split1: Renamed from regdir/t.split. 82 * regdir/t.sub0: Renamed from regdir/t.sub. 83 * regdir/REGRESS: Adjusted. 84 85 2018-08-04 Arnold D. Robbins <arnold (a] skeeve.com> 86 87 With scalpel, tweasers, magnifying glass and bated breath, 88 borrow code from the NetBSD version of nawk to fix the years-old 89 bug whereby decrementing the value of NF did not change the 90 record. 91 92 * lib.c (fldbld): Set donerec to 1 when done. 93 (setlastfld): New function. 94 * proto.h (setlastfld): Add declaration. 95 * run.c (copycell): Make code smarter about flags (from NetBSD code). 96 * tran.c (setfree): New function. 97 * tran.c (setfval): Normalize negative zero to positive zero. 98 If setting NF, clear donerec and call setlastfld(). 99 (setsval): Remove call to save_old_OFS(). If setting OFS, call 100 recbld(). If setting NF, clear donerec and call setlastfld(). 101 102 As part of the process, revert OFS-related changes of 2018-05-22: 103 104 * awk.h (saveOFS, saveOFSlen, save_old_OFS): Remove declarations. 105 * lib.c (recbld): Use *OFS instead of saveOFS. 106 * run.c (saveOFS, saveOFSlen, save_old_OFS): Remove. 107 * tran.c (syminit): Remove initialization of saveOFS and saveOFSlen. 108 109 General stuff that goes along with all this: 110 111 * bugs-fixed/README: Updated. 112 * bugs-fixed/decr-NF.awk, bugs-fixed/decr-NF.bad, 113 bugs-fixed/decr-NF.ok: New files. 114 * main.c (version): Updated. 115 * regdir/README.TESTS: Fix awk book title. 116 * regdir/T.misc: Revise test to match fixed code. 117 * run.c (format): Increase size of buffer used for %a test. (Unrelated 118 to NF or OFS, but fixes a compiler complaint.) 119 120 2018-06-07 Arnold D. Robbins <arnold (a] skeeve.com> 121 122 * regdir/beebe.tar: Fix longwrds.ok so that the test will pass. 123 The file was incorrectly sorted. 124 125 2018-06-06 Arnold D. Robbins <arnold (a] skeeve.com> 126 127 * regdir/T.lilly: Fix the bug again in the second instance 128 of the code. Thanks to BWK for pointing this out. 129 130 2018-05-31 Arnold D. Robbins <arnold (a] skeeve.com> 131 132 * regdir/T.lilly: Fix a syntax error and ordering bug 133 in creating the 'foo' file. 134 135 2018-05-23 Arnold D. Robbins <arnold (a] skeeve.com> 136 137 * awk.1: Remove standalone 'awk' at the top of file, it messed up 138 the formatting. Arrange built-in variable list in alphabetical 139 order. 140 141 2018-05-23 Arnold D. Robbins <arnold (a] skeeve.com> 142 143 * main.c (version): Add my email address and a date so that 144 users can tell this isn't straight BWK awk. 145 * README.md: Minor updates. 146 * TODO: Updated. 147 148 2018-05-22 Arnold D. Robbins <arnold (a] skeeve.com> 149 150 Add POSIX-required formats %a and %A. 151 152 * run.c (format): Check for %a support in C library. If there, 153 allow %a and %A as valid formats. 154 * TODO: Updated. 155 * bugs-fixed/README: Updated. 156 * bugs-fixed/a-format.awk, bugs-fixed/a-format.bad, 157 bugs-fixed/a-format.ok: New files. 158 159 2018-05-22 Arnold D. Robbins <arnold (a] skeeve.com> 160 161 * FIXES: Restored a line from a much earlier version that 162 apparently got lost when the dates were reordered. 163 * TODO: Updated. 164 165 2018-05-22 Arnold D. Robbins <arnold (a] skeeve.com> 166 167 * README.md: New file. 168 169 2018-05-22 Arnold D. Robbins <arnold (a] skeeve.com> 170 171 * regdir/echo.c, regdir/time.c: Minor fixes to compile without 172 warning on current GCC / Linux. 173 174 2018-05-22 Arnold D. Robbins <arnold (a] skeeve.com> 175 176 * TODO: New file. 177 178 2018-05-22 Arnold D. Robbins <arnold (a] skeeve.com> 179 180 * makefile (gitadd, gitpush): Remove these targets. They 181 should not be automated and were incorrect for things that 182 would be done regularly. 183 184 2018-05-22 Arnold D. Robbins <arnold (a] skeeve.com> 185 186 Fix nawk so that [[:blank:]] only matches space and tab instead 187 of any whitespace character, originally made May 10, 2018. 188 See bugs-fixed/space.awk. 189 190 This appears to have been a thinko on Brian's part. 191 192 * b.c (charclasses): Use xisblank() function for [[:blank:]]. 193 * bugs-fixed/README: Updated. 194 * bugs-fixed/space.awk, bugs-fixed/space.bad, 195 bugs-fixed/space.ok: New files. 196 197 2018-05-22 Arnold D. Robbins <arnold (a] skeeve.com> 198 199 * .gitignore: New file. 200 201 2018-05-22 Arnold D. Robbins <arnold (a] skeeve.com> 202 203 Fix nawk to provide reasonable exit status for system(), 204 a la gawk, originally made March 12, 2016. See 205 bugs-fixed/system-status.awk. 206 207 * run.c (bltin): For FSYSTEM, use the macros defined for wait(2) 208 to produce a reasonable exit value, instead of doing a floating-point 209 division by 256. 210 * awk.1: Document the return status values. 211 * bugs-fixed/README: Updated. 212 * bugs-fixed/system-status.awk, bugs-fixed/system-status.bad, 213 bugs-fixed/system-status.ok: New files. 214 215 2018-05-22 Arnold D. Robbins <arnold (a] skeeve.com> 216 217 Bug fix with respect to rebuilding a record, originally 218 made August 19, 2014. See bugs-fixed/ofs-rebuild.awk. 219 220 * awk.h (saveOFS, saveOFSlen): Declare new variables. 221 * lib.c (recbld): Use them when rebuilding the record. 222 * run.c (saveOFS, saveOFSlen): Define new variables. 223 (save_old_OFS): New function to save OFS aside. 224 * tran.c (syminit): Initialize saveOFS and saveOFSlen. 225 (setsval): If setting a field, call save_old_OFS(). 226 * bugs-fixed/README, bugs-fixed/ofs-rebuild.awk, 227 bugs-fixed/ofs-rebuild.bad, bugs-fixed/ofs-rebuild.ok: New files. 228 229 2018-05-22 Arnold D. Robbins <arnold (a] skeeve.com> 230 231 * makefile (YACC): Use bison. 232 233 2018-05-22 Arnold D. Robbins <arnold (a] skeeve.com> 234 235 * ChangeLog: Created. 236 * regdir: Created. Based on contents of awktest.a. 237 * .gitattributes: Created, to preserve CR LF in regdir/t.crlf. 238 * awktest.a: Removed. 239 * regdir/T.gawk, regdir/T.latin1: Updated from awktest.tar. 240 * awktest.tar: Removed. 241