Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

Fortran Extensions

JohnNichols
Valued Contributor II
322 Views

So for many years I used just .for, and then I got used to .f90.   Why does the .f extension default to .for and what other extensions are actually supported by Intel Fortran?  

I read Arjun's article on this matter, so I understand, but who decides this? 

 

Just curious. 

0 Kudos
3 Replies
Steve_Lionel
Black Belt Retired Employee
265 Views

Doctor Fortran in "Source Form Just Wants to be Free" - Doctor Fortran (stevelionel.com)

 

The Intel documentation lists the supported file types. .for was DEC's preferred type, .f was popular in the UNIX/Linux world - Intel Fortran supports both of those for fixed-form source. For free-form source, only .f90 is supported. (You can see my view on this in the post linked above.)

I have seen some argue that .f should be "reclaimed" for free-form source, but that would be disastrous for zillions of existing builds. I'd be happier to see a new file type, such as .ffr, be adopted for free-form, but I doubt that's going to happen.

JohnNichols
Valued Contributor II
259 Views

Thanks, so using a .f is ok.  

Steve_Lionel
Black Belt Retired Employee
193 Views

.ftn is also accepted as fixed-form. For more details, see Understanding File Extensions (intel.com)

Reply