[BUGFIX] Ensure that rule refs can be reused when inlining grammars

WIP

* [ ] Generators and specs for builtin grammar types
* [ ] Support for caching of built-in grammars (does this go here or in Punchblock's recognizer?)