briot / tree-sitter-ada

Ada grammar for tree-sitter
MIT License
21 stars 5 forks source link

Improve parser based on GNATprove and its testsuite #9

Closed ptroja closed 9 months ago

ptroja commented 9 months ago

Thanks for accepting my previous pull requests! Here are few more patches, which allows tree-sitter-ada to parse almost all of the GNATprove source code and its testsuite. Notable exceptions are attribute Update (specific to GNAT), delta_aggregate (Ada 2022) and various uses of GNATprep. Most likely they are tricker but also rather uncommon.

briot commented 9 months ago

Hello, thanks for this series of patches (took a bit longer to check and integrate them...). I made only one change to them: I regenerated the parser with the last stable release of tree-sitter (0.20.6), instead of 0.20.7 as you did, just so that people could regenerate and get to the same result more easily. Since everything passes with 0.20.6, you are not depending on new features of 0.20.7 apparently. This likely also makes it easier for other projects to pick up (neovim, Emacs,...), though not sure.