An identical technique could be used for yacc or protobufs.
[1]: https://github.com/docopt/docopt.rs
Reply on news.ycombinator.com