4.2 Options Controlling Fortran Dialect
The following options control the dialect of Fortran
that the compiler accepts:
-ffree-form
-ffixed-form
- Specify the layout used by the source file. The free form layout
was introduced in Fortran 90. Fixed form was traditionally used in
older Fortran programs.
-fd-lines-as-code
-fd-lines-as-comment
- Enables special treating for lines with `d' or `D' in fixed
form sources. If the -fd-lines-as-code option is given
they are treated as if the first column contained a blank. If the
-fd-lines-as-comments option is given, they are treated as
comment lines.
-fdefault-double-8
- Set the "DOUBLE PRECISION" type to an 8 byte wide.
-fdefault-integer-8
- Set the default integer and logical types to an 8 byte wide type.
Do nothing if this is already the default.
-fdefault-real-8
- Set the default real type to an 8 byte wide type.
Do nothing if this is already the default.
-fdollar-ok
- Allow `$' as a valid character in a symbol name.
-fno-backslash
- Compile switch to change the interpretation of a backslash from
“C”-style escape characters to a single backslash character.
-ffixed-line-length-
n- Set column after which characters are ignored in typical fixed-form
lines in the source file, and through which spaces are assumed (as
if padded to that length) after the ends of short fixed-form lines.
Popular values for n include 72 (the
standard and the default), 80 (card image), and 132 (corresponds
to “extended-source” options in some popular compilers).
n may be `none', meaning that the entire line is meaningful
and that continued character constants never have implicit spaces appended
to them to fill out the line.
-ffixed-line-length-0 means the same thing as
-ffixed-line-length-none.
-ffree-line-length-
n- Set column after which characters are ignored in typical free-form
lines in the source file. For free-form, the default value is 132.
n may be `none', meaning that the entire line is meaningful.
-ffree-line-length-0 means the same thing as
-ffree-line-length-none.
-fmax-identifier-length=
n- Specify the maximum allowed identifier length. Typical values are
31 (Fortran 95) and 63 (Fortran 200x).
-fimplicit-none
- Specify that no implicit typing is allowed, unless overridden by explicit
`IMPLICIT' statements. This is the equivalent of adding
`implicit none' to the start of every procedure.
-fcray-pointer
- Enables the Cray pointer extension, which provides a C-like pointer.
-frange-check
- Enable range checking on results of simplification of constant expressions
during compilation. For example, by default, gfortran will give
an overflow error at compile time when simplifying
a = EXP(1000)
.
With `-fno-range-check', no error will be given and the variable a
will be assigned the value +Infinity
.
-std=
std- Conform to the specified standard. Allowed values for std are
`gnu', `f95', `f2003' and `legacy'.