camfort / fortran-src

Fortran parsing and static analysis infrastructure
https://hackage.haskell.org/package/fortran-src
Other
48 stars 20 forks source link

Parse `.f` files as lenient `Fortran77Legacy` by default #259

Closed raehik closed 1 year ago

raehik commented 1 year ago

As suggested by @RaoulHC in #256 , with most compilers being lenient on F77 extensions, users are expecting the same from fortran-src -- and it does support lots of extensions, but they're "hidden" behind a --version Fortran version parsing flag. (This also goes for the library via Language.Fortran.Version.selectFortranVersion).

Why not default to Fortran77Legacy to work with more code? It's only convenience anyway, since you can always request to parse any code/file with any Fortran version.

raehik commented 1 year ago

We had a quick discussion on this and decided it made sense to do. I'll make sure that the default version is made obvious in the relevant places (the CLI help should certainly mention it).