Open w6ws opened 1 week ago
Double precision functions get an incorrect "::" added to the function declaration, and "END PROGRAM" instead of "END FUNCTION" at the end:
double precision function dpfunc (x) real x dpfunc = x end
Gets translated to:
double precision :: function dpfunc (x) real :: x dpfunc = x END PROGRAM
With the following mod, it produces correct code:
415a416,420
} else { if (s/^double precision (function [\w_\d]*)/double precision $1/i) { $subname = $1; last cblock; }
Produces:
double precision function dpfunc (x) real :: x dpfunc = x end function dpfunc
(I've found several other bugs in f2f.pl as well. Details, and perhaps fixes, will be added as separate issues.)
It’s just a mirror so it’s not really maintained, but if you make a PR I can approve
Ok - I can't do the PR today. Hopefully in the next few days.
Double precision functions get an incorrect "::" added to the function declaration, and "END PROGRAM" instead of "END FUNCTION" at the end:
Gets translated to:
With the following mod, it produces correct code:
415a416,420
Produces:
(I've found several other bugs in f2f.pl as well. Details, and perhaps fixes, will be added as separate issues.)