The -fpedantic command-line option specifies that g77 is to warn about code that is not standard-conforming. This is useful for finding some extensions g77 accepts that other compilers might not accept. (Note that the -pedantic and -pedantic-errors options always imply -fpedantic.)
With -fno-f90 in force, ANSI FORTRAN 77 is used as the standard for conforming code. With -ff90 in force, Fortran 90 is used.
The constructs for which g77 issues diagnostics when -fpedantic and -fno-f90 are in force are:
SUBROUTINE X(N) REAL A(N) ...
where `A' is not listed in any
and thus is not a dummy argument.
These commas are disallowed by FORTRAN 77, but, while strictly superfluous, are syntactically elegant, especially given that commas are required in statements such as `READ 99, I' and `PRINT *, J'. Many compilers permit the superfluous commas for this reason.
DOUBLE COMPLEX, either explicitly or implicitly.
An explicit use of this type is via a
DOUBLE COMPLEX or
IMPLICIT DOUBLE COMPLEX statement, for examples.
An example of an implicit use is the expression `C*D',
where `C' is
and `D' is
This expression is prohibited by ANSI FORTRAN 77
because the rules of promotion would suggest that it
DOUBLE COMPLEX result—a type not
provided for by that standard.
INTEGER(KIND=1)in contexts such as:
FORMATrun-time expressions (not yet supported).
CHARACTERentities in specification statements.
INTEGERin contexts such as arithmetic
COMPLEXexpressions are disallowed anyway).
CHARACTERentities, as in:
PRINT *, ''
PRINT *, 'hello'(3:5)
PRINT *, FOO(,3)
SAVEd (for targets where program units in a single source file are “glued” together as they typically are for UNIX development environments).
(In the GNU Fortran language, `DATA I/1/' may be followed by `INTEGER J', but not `INTEGER I'. The -fpedantic option disallows both of these.)
CALL FOO; CALL BAR
CHARACTERconstants to initialize numeric entities, and vice versa.
If -fpedantic is specified along with -ff90, the following constructs result in diagnostics: