Developer forums (C::B DEVELOPMENT STRICTLY!) > Development
Suggest to change the fortran wizard file extension
ollydbg:
Hi, my friend xunxun1982 has give some suggestion on change the FORTRAN file extension.
1. rename the main.f95 to main.f90.
because .f95 is not widely supported, such as Compa Visual Fortran, this compiler only support Fortran90 standard and the .f90 extension file. But .f90 is widely supported by all the fortran compiler like Fortran95 2003 2008 standard.
2. change the content of main.f90
original content
--- Code: --- program main
implicit none
integer re_i
write(*,*) "Hello World!"
re_i = system("pause")
end
--- End code ---
reason:
--- Code: ---re_i = system("pause")
--- End code ---
the statement above: system is not a native Fortran function, it is a compiler extension (gfortran/g95/intel supported, but not sure other fortran compiler)
changed content:
--- Code: --- program main
implicit none
write(*,*) "Hello World!"
stop
end
--- End code ---
Any ideas from Fortran users??
thanks.
Loaden:
Commit it? any comment?
:lol:
MortenMacFly:
--- Quote from: ollydbg on October 22, 2010, 07:33:00 am ---because .f95 is not widely supported, such as Compa Visual Fortran, this compiler only support Fortran90 standard and the .f90 extension file.
--- End quote ---
Well - that's one of the #1 choices or a Fortran compiler so I'd say it *is* widely known and supported. Furthermore Fortran users are usually known to be very conservative. in fact all Fortran devs I know (and these are many in my domain) are still using Fortrtan77. What extension does GNU GFortran suggest?
As for the system() call I agree, but the extension is really not worth changing. Depending on the user's habits one argues this way, the other will argue the opposite. As long as C::B supports both extensions natively through "file types and extensions" it's just fine.
xunxun:
--- Quote from: MortenMacFly on October 23, 2010, 08:54:13 pm ---
--- Quote from: ollydbg on October 22, 2010, 07:33:00 am ---because .f95 is not widely supported, such as Compa Visual Fortran, this compiler only support Fortran90 standard and the .f90 extension file.
--- End quote ---
Well - that's one of the #1 choices or a Fortran compiler so I'd say it *is* widely known and supported. Furthermore Fortran users are usually known to be very conservative. in fact all Fortran devs I know (and these are many in my domain) are still using Fortrtan77. What extension does GNU GFortran suggest?
As for the system() call I agree, but the extension is really not worth changing. Depending on the user's habits one argues this way, the other will argue the opposite. As long as C::B supports both extensions natively through "file types and extensions" it's just fine.
--- End quote ---
I agree with you, and the Fortran Programmers around me generally use the extension name ".f" or ".for" (Fortrtan77, old programs, hardly to read and maintain) and ".f90" (Fortran 90 95 2003, new programs, easily to read and maintain) . In fact, I think the Fortran Project in CB should provide ".f", ".f90", ".f95", just like C/C++ Console Project.
MortenMacFly:
--- Quote from: xunxun1982 on October 24, 2010, 09:36:58 am ---In fact, I think the Fortran Project in CB should provide ".f", ".f90", ".f95", just like C/C++ Console Project.
--- End quote ---
That's what C::B does and that won't change. The question here only was about what the extension for the file created by the wizard shall be.
Navigation
[0] Message Index
[#] Next page
Go to full version