fprettify
fprettify copied to clipboard
auto-formatter for modern fortran source code
Thanks for the great tool! I'm using it on a few projects, and one thing that's bugging me is the very noisy output when `fprettify` encounters a long line: ```...
As explained in #110, the `exclude` option given via the config file did not work. Here's the fix, a bit of a refactor, and a bunch of new tests. If...
A couple of fixes: * `else` and `else if` statements can have a construct name at the end, just like `end if` (http://www.lahey.com/docs/lfprohelp/F95ARIFConst.htm) * Apparently initial indent (e.g. from fixed-format...
I tried to format code which has a variable called `ne` used in the following way: ```fortran if (skipreference .and. ne .gt. 0) then write (*,*) 'something' end if ```...
for example: ```fortran INTEGER :: ZIP, Mean, Total ``` ```fortran INTEGER :: ZIP INTEGER :: Mean INTEGER :: Total ```
Greedily matching numbers in `F90_CONSTANTS_TYPES_RE` is super slow for numbers with many digits. https://github.com/pseewald/fprettify/blob/cb254022c2034ad3b8f744f4dad1bf5b7438815d/fprettify/__init__.py#L475 Kudos to @Jellby and @zaikunzhang for independently discovering this and fixing it as part of their...
Setting an exclude pattern in the config file currently does not work since the config file is read after the list of files has already been determined. I'll open a...
Without the fix, the search starts one directory above the current directory.
When `fprettify` is invoked with input from stdin, the config file in the current working directory is ignored. There's an open PR with a fix, #98, it would be great...
`-i 2 --case 1 1 1 1` before: ```fortran module myModule implicit none private contains subroutine MySubroutine(int) implicit none integer(4), INTENT(IN) :: int end subroutine MySubroutine end module myModule ```...