Skip to content

Releases: benhoyt/goawk

Version 1.23.1

18 May 05:52
230d423
Compare
Choose a tag to compare

This is a patch release that fixes a bug in 1.23.0 -- there was a bug that caused a panic in the resolver step with code like function f1(A) {} function f2(x, A) { x[0]; f1(a); f2(a) }. Fixed in #178.

While we're at it, also fix a panic with certain obscure regexes (#179) and limit ARGC to a reasonable maximum (#180).

All three of these issues were found by fuzzing: go test ./interp -fuzz=FuzzSource

Version 1.23.0

12 May 22:25
d83e537
Compare
Choose a tag to compare

This release adds a single new feature: support for length(array) in addition to length(string) (#176). Calling length() on an array is quite useful and is supported by all other awk versions (onetrueawk, Gawk, mawk, busybox awk, frawk). In addition, it's been accepted for inclusion into POSIX, though not yet added to the main spec (which seems to take forever).

This release also includes a complete rewrite of the type resolver (#175). Before the code was quite messy and hard to read, now with the two passes I think it's easier to understand and work with. It was certainly easier to add the length(array) feature with the rewritten resolver than before.

Version 1.22.0

07 Apr 18:51
Compare
Choose a tag to compare

A fairly minor release, fixing some edge cases and adding support for nextfile:

  • Make constructs like $++lvalue not an error (#168)
  • Optimize constant integer array indexes to avoid toString() at runtime (#169)
  • Allow parsing of cond && var=value and similar expressions (#170)
  • Add GroupingExpr to fix (a)++b parsing issue; pretty-print precedence (#172)
  • Add support for nextfile (#173)

See full list of commits.

Version 1.21.0

27 Nov 02:14
Compare
Choose a tag to compare

Significant changes in this release:

Version 1.20.0

17 Jul 21:39
Compare
Choose a tag to compare

Version 1.19.0

06 Jun 04:13
Compare
Choose a tag to compare

Notable changes in this release:

In other news, check out awk-demo, an amazing "old skool demo" written in AWK by @patsie75. It now works under GoAWK, at least on Linux. Clone that repo and run it with awk=goawk ./demo.sh!

Thanks to @ko1nksm for several bug reports.

See full list of commits since v1.18.0.

Version 1.18.0

20 May 23:14
Compare
Choose a tag to compare

Relatively minor release with the following changes:

See the list of commits.

Version 1.17.1

11 May 05:55
Compare
Choose a tag to compare

Version 1.17.0

09 May 05:37
Compare
Choose a tag to compare

Now with proper CSV input and output support! For example, a simple example showing CSV input parsing and the new @"named-field" syntax:

$ goawk -i csv -H '{ print @"Abbreviation" }' testdata/csv/states.csv
AL
AK
AZ
...

Read the full documentation.

This feature was sponsored by the library of the University of Antwerp -- many thanks!

Version 1.16.0

19 Feb 03:06
Compare
Choose a tag to compare
  • Add interp.New ... Execute API to speed up and reduce allocations when executing the same program multiple times. #100
  • Add ExecuteContext API to support timeout and cancellation. #103
  • Optimized string concatenation when concatenating more than two strings, for example x = "a" "," "b". #99
  • Reduce allocations in a few other places, such as print, printf, sprintf(), and field parsing. #102
  • Add proper Go 1.18 fuzzing support for fuzzing the AWK source and input. #103