Replacing AWK with Python in GCC?
Replacing AWK with Python in GCC?
Posted Jul 29, 2018 18:23 UTC (Sun) by ofranja (subscriber, #11084)Parent article: Replacing AWK with Python in GCC?
IMHO, the awk version easier to read. Sure, it has more duplication, but one can easily abstract awk code (hint: it supports functions and there are ways to encapsulate data in arrays). Bad/redundant code can be written in any language. The python version has tons of details that require a deeper knowledge of python as well and is not necessarily easier to work with.
Also, not everyone can (or want to) afford extra ~130MB of storage just to process some text.
In my opinion, putting some effort to improve the awk version would probably be a better solution in the long term.
