Table of Contents

Previous: -extern


Option: f77

-f77=list
Use this setting to catch language extensions which violate the Fortran 77 Standard. Such extensions may cause your program not to be portable. Examples include the use of underscores in variable names; variable names longer than six characters; statement lines longer than 72 characters; and nonstandard statements such as the DO ... ENDDO structure. ftnchek does not report on the use of lowercase letters. By default, all warnings are turned off.

This setting provides detailed control over the warnings about supported extensions to the Fortran 77 Standard. The list consists of keywords separated by commas or colons. There are three special keywords: all to turn on all the warnings about nonstandard extensions, none to turn them all off, and help to print the list of all the keywords with a brief explanation of each. If list is omitted, -f77 is equivalent to -f77=all , and -nof77 is equivalent to -f77=none . The warning keywords with their meanings are as follows. (Further details about the extensions themselves are given below in the section on Extensions.)

accept-type:
ACCEPT and TYPE I/O statements.
array-bounds:
Expressions defining array bounds that contain array elements or function references.
assignment-stmt:
Assignment statements involving arrays. In Fortran 90, an array can be assigned to another array of compatible shape, or a scalar can be assigned to an array. Neither of these assignments is permitted in Fortran 77.

A related warning occurs when an array is assigned to a scalar. Since this is illegal also in Fortran 90, it is always warned about regardless of the -f77 setting (unless all checking is turned off with the -nocheck flag).

automatic-array:
Local (not dummy) arrays which have variable size. These would correspond to arrays whose storage would have to be dynamically allocated at run time.
backslash:
Unix backslash escape in strings. This warning will be given only if the -source=unix-backslash setting is specified to cause the escape interpretation of backslash..
byte:
BYTE data type declaration.
common-subprog-name:
Common block and subprogram having the same name.
construct-name:
Use of a construct-name to label a control statement.
continuation:
More than 19 successive continuation lines.
cpp:
Unix C preprocessor directives in the source code.
cycle-exit:
The CYCLE and EXIT statements.
d-comment:
Debugging comments starting with D in the source code.
dec-tab:
DEC Fortran style tab-formatted source code. This warning will be given only if the -source=dec-tab setting is specified to cause interpretation of tabs in this style.
do-enddo:
DO loop extensions: terminal statement label omitted, END DO , and WHILE .
double-complex:
Double precision complex datatype.
format-dollarsign:
Dollar sign control code in FORMAT statements.
format-edit-descr:
Nonstandard edit descriptors in FORMAT statements.
function-noparen:
Function definition without parentheses.
implicit-none:
IMPLICIT NONE statement.
include:
INCLUDE statement.
inline-comment:
Inline comments starting with an exclamation point.
internal-list-io:
List-directed I/O to or from an internal file.
intrinsic:
Nonstandard intrinsic functions.
io-keywords
Nonstandard keywords used in I/O statements. These fall into three groups. The first group includes keywords that are accepted in Fortran 90:
ACTION PAD READWRITE
ADVANCE POSITION SIZE
DELIM READ WRITE
EOR
The second group comprises the following VMS Fortran keywords:
BLOCKSIZE EXTENDSIZE READONLY
BUFFERCOUNT INITIALSIZE RECORDSIZE
CARRIAGECONTROL MAXREC RECORDTYPE
DEFAULTFILE NAME (in OPEN ) SHARED
DISP NOSPANBLOCK TYPE
DISPOSE ORGANIZATION
(The keyword NAME is standard only in the INQUIRE statement.) The third group consists of the following IBM/MVS keyword:
NUM
long-line:
Statements with meaningful code past 72 columns. This warning is given only if the -columns setting has been used to increase the statement field width.
long-name:
Identifiers over 6 characters long.
mixed-common:
Mixed character and noncharacter data in COMMON block.
mixed-expr:
Nonstandard type combinations in expressions, for example DOUBLE PRECISION with COMPLEX , assigning hollerith to integer, logical operations on integers.
name-dollarsign:
Dollar sign used as a character in identifiers.
name-underscore:
Underscore used as a character in identifiers.
namelist:
NAMELIST statement.
param-implicit-type:
Implicit typing of a parameter by the data type of the value assigned. This warning can only occur if implicit parameter typing has been turned on by the -source=parameter-implicit-type option, or if the PARAMETER statement is of the nonstandard form without parentheses. If this option is turned on, then any instances where implicit parameter typing occurs will be warned about. If you want to be warned only in those instances where the implicit data type differs from the default type, use -portability=param-implicit-type instead. According to the Fortran 77 standard, the data type of a parameter is given by the same rules as for a variable, and if necessary a type conversion is done when the value is assigned.
param-intrinsic:
Intrinsic function or exponentiation by a real used to define the value of a PARAMETER definition.
param-noparen:
PARAMETER statement without parentheses. The user should be aware that the semantics of this form of the statement differs from that of the standard form: in this form, the parameter takes its data type from the value assigned, rather than having its default data type based on the first letter of the parameter name. (This form of the PARAMETER statement was introduced by DEC before the Fortran 77 standard was defined, and should be avoided.)
pointer:
``Cray pointer'' syntax.
quad-constant:
Quad precision real constants, e.g. of the form 1.23Q4 .
quotemark:
Strings delimited by quote marks rather than apostrophes.
relops:
Relational (comparison) operators composed of punctuation, namely: < <= == /= > >=.
statement-order
Statements out of the sequence mandated by the Standard. The allowed sequence is illustrated in Table 1 in the section on Interpreting the Output.
typeless-constant:
Typeless constants, for example Z'19AF' .
type-size:
Type declarations specifying a size, for example REAL*8 .
variable-format:
Variable repeat specification or field size in FORMAT. These are of the form < expr > .
vms-io:
Obsolete. Now has the same meaning as the io-keywords keyword.

See also: -f90 , -f95 , -portability , -pretty , -wordsize .


Next: -f90