[Toybox] awk (Re: ps down, top to go)
Andy Chu
andychup at gmail.com
Sun May 8 21:06:50 PDT 2016
> Hi, Dennis --
>
> IANAL, of course, but I certainly would have no objection, and I
> suspect there is no one left at Lucent (now Alcatel now Nokia)
> who would even know this program existed, let alone care. Whether
> it's the best code is an entirely different issue -- it's pretty
> grimy inside. The main merit is that it isn't very big (but neither
> was the busybox version if I recall).
> </quote>
>
> *He* certainly wouldn't mind. :-)
I think he's being a characteristically modest... I wouldn't call it
grimy. There are a lot more globals than I would like, but that's
typical for C code especially of that era. The grammar looks nice and
clean.
The fact that busybox can get it done in 3300 LOC is interesting
though. I'm pretty surprised because I can't see where they're hiding
the equivalent of Kernighan's parser (awkgram.y). I wonder if it
really implements awk or it's just the subset that people happen to
use. There are some huge awk programs out there, but perhaps they're
just rare.
Andy
More information about the Toybox
mailing list