Support parser rule includes/modules
- Dominant language
- Haskell
- Stars
- 322
- Forks
- 86
- PR merge metrics
- No merged PRs in 30d
Description
I'm working on some projects where we have [multiple large Happy parsers](https://github.com/camfort/fortran-src/tree/29d3bfba6b54be6233f57f79a81225ee64ca67b1/src/Language/Fortran/Parser), many of which reuse snippets or entire blocks of rules. We'd like to split some rules off into include-able files while staying platform-agnostic (I could easily solve it with some Bash, but then Windows will need its own solution, etc...). Having a Happy feature to allow "sharing" rules between parsers would help in refactoring larger parsers.
I've searched the internet and Happy code/docs and asked #haskell on Libera, but I'm not sure if there's any solution or precedent for this currently.
Contributor guide
Assessment
This issue has not been assessed yet.