camfort / fortran-src

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

Make sure non literals have parens where needed #233

Closed RaoulHC closed 2 years ago

RaoulHC commented 2 years ago

Otherwise pretty printing declarations results in invalid fortran such as foo** rather than foo*(*).

raehik commented 2 years ago

Thanks Raoul, nice catch. I noted noParensLit was used in multiple places, so I pulled it out to top level (and did some other half-related tweaks I remembered). I'm happy to merge if you are.

RaoulHC commented 2 years ago

LGTM, can be merged once CI's passed.