Here is the problem with this kind of approach. Do a google search for some well known fortran file. There are probably thousands of such files to choose from, but dgels.f
is an example from the lapack library. This is a driver routine to solve various types of linear equations. It is, of course, fixed form fortran.
So imagine a “new user” who does such a search, finds and downloads the source code, and then attempts to compile it with the above conventions. The compile step will result in various errors because he is trying to compile a fixed form file with free form conventions. What kind of experience will that be for that new user?
My point is that one cannot simply change what is now a de facto standard, one that has existed for several decades, without consequences. No matter what you do locally with Makefile conventions, and compiler defaults, all of those fixed source *.f
files still exist, and they will forever be in conflict with anyone trying to simply redefine what the .f
extension means.
An experienced programmer can do this. He would know the difference in the source code forms, he knows how to configure his build system appropriately, and there is no problem at any step of the process. But this discussion keeps going back to “new users”, trying to simplify and make their life easier with less confusion. Ignoring that the .f
extension is a de facto standard for fixed source form does not make things easier for this proverbial “new user”.
Regarding the .f90 extension, it is also a de facto standard for free form source file. Again, nothing can be done about the past three decades of code that have used that convention, so it should not be ignored either. However, that does not mean that a better convention could not be adopted in the future. Others have suggested .fx
and .FX
for this. One problem I see with this is that .fx
could be thought of as “fortran extended” or it could be thought of as “fixed”, so it appears somewhat ambiguous. Maybe that ambiguity is insignificant? I don’t know. Of course, it is unfortunate in the first place that both “free” and “fixed” start with the same letter.