-
Notifications
You must be signed in to change notification settings - Fork 2
Add fixed-form support #2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
When there is no whitespace between a literal integer and the `.eq.` operator, it was getting parsed as a malformed float literal
Multiple symbol definition link-time errors when both free- and fixed-form Fortran parsers are included in `py-tree-sitter-languages`
Hmm, I've copied the github workflows across, but they don't seem to have been picked up |
@stadelmanma I sorted out my issues with This is now updated to the latest |
Replaces #1
Updated to tree-sitter 0.23 and the latest (0.2.0) tree-sitter-fortran grammar.
Parses 100% of LAPACK.
It's a bit harder to check the wider corpus as lots of projects compile
.f
files in free-form mode, and so aren't valid fixed-form. There's also a surprising number of fixed-form files with tabs out there too, which obviously makes parsing them tricky when we're looking for any character in column 6 for a line continuation.I've tried a couple of things for handling tabs, but not managed to get one to work. I think probably a sensible approach would be to basically not try to handle line continuations if we've seen a tab already on a given line.
@stadelmanma I've been having to do some manual futzing in order to update against the free-form grammar. Basically
npm update
doesn't seem to work locally for me, and I have to runnode-gyp build
intree-sitter-fortran
manually and copy some files across tonode_modules
in this project. This might be easier if we can publish the npm package fortree-sitter-fortran
?