3 ms·
awk can do much more than sed. And, with patience, you could even write a Z-machine interpreter on it as some guy did with postscript. You might have to convert
by anthk 3y ago
awk can do much more than sed. And, with patience, you could even write a Z-machine interpreter on it as some guy did with postscript. You might have to convert the binary input to hex first with xxd/od in order to parse the opcodes in a nice way, but everything else would be simulated from awk.
- tyingq 3y ago> You might have to convert the binary input to hex first If you're okay with gawk, most implementations ship with gawkextlib, which has readfile(), and you also have FIELDWIDTHS.