Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

An interesting exercise would be to actually maintain both versions: e.g. make utf-8 friendly; add error handling. I think McIlroy's version would still come out on top but not by as much. Nice, informative error handling is one of the things most lacking in shell scripts.


It was fixed in Plan9, where programs return error strings, not numbers, the shell (rc) is better and errors are not lost in pipelines.

And UTF-8 was invented by Ken Thompson and Rob Pike while working on Plan9.


Yes, I'm aware of plan9. The 'what constitutes a word' and the error handling were and are the more interesting improvements.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: