4 ms·
Lua and AWK. I'm inspired! I'm going to rewrite the Perl 5 interpreter in Go. Take that Larry. Just kidding. I'm all for scratching an itch, but why rewrite al
by jim_bailie 8y ago
Lua and AWK. I'm inspired! I'm going to rewrite the Perl 5 interpreter in Go. Take that Larry. Just kidding.
I'm all for scratching an itch, but why rewrite all these well established tools?
- stevekemp 8y agoI extended somebody elses programming language recently, then wrote a BASIC. Mostly to make sure that I understood lexing, parsing, and AST stuff. While you're right this is reinventing the wheel it can make sense to reimplement old tools to improve safety, security, and to allow them to be embedded in new environments. Have you ever run a fuzz-tester against (GNU) awk? I have. Even now you can segfault awk with bogus programs, for example: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=816277 https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=816277 No doubt this new implementation won't be perfect, but segfaults should be ruled out via rust/go/ML implementations..
- jim_bailie 8y agoHa! My interaction with AWK throughout the years has been a fuzz test in progress. Very interesting link though. On the other hand, I think what you're saying about expanding a well known tool's range of use in new environments makes sense.
- _ZeD_ 8y agowhy not?
- benhoyt 8y agoI can't tell you what motivates others, but I know what motivated me with GoAWK: intellectual curiosity, and the desire to learn how to use Go's profiling tools on a non-trivial project.
- jim_bailie 8y agoI suppose I'm jaded. I've been writing software for so long and have been so underpaid for it, maybe I'm envious of your ability to follow through on your intellectually curiosity with such flourish. Anyway, great work. Looks good!
- koffiezet 8y agoOne of the cool things about Go is that pretty much everything is being developed as a library. This means you can integrate this in your app without external dependencies, portable to any platform Go supports, since it depends only on the stdlib.