fidsearches the target source-code file for various HP FORTRAN 77™ extensions that are known to be incompatible with HP Fortran. It also detects incompatible command-line options when given anf77 command line. fid reports both source-code and object-code incompatibilities between HP

FORTRAN 77™ and HP Fortran. Furthermore, if fiddetects an incompatible extension whose functionality is enabled by some other means in HP Fortran, it will suggest a fix.

fidworks by searching the entire program and reporting all its findings at once. Like the

f77command, it expects the target program to conform to HP FORTRAN 77™syntax and will report syntax errors along with incompatibilities it detects. Unlikef77, however, if fidencounters a syntax error, it attempts to recover and continue parsing the rest of the program. This recovery mechanism allows fid to accept programs that contain HP Fortran language features.

Not all incompatibilities are onfid's detection list. Some cannot be found by any automated means, and others require too much time to compute for even medium-sized programs.

To invoke fid, supply the fidcommand with one or more FORTRAN 77™source files and any desired f77 options. If a file has been partially migrated to HP Fortran, change its extension to

.ffor use with fid. Following are example command lines:

$ fid +800 file.f

$ fid +es program.f

Following are examples of the warning messages fid issues when it detects an incompatibility:

fid Warning: The command-line option, +800,

is both source incompatible and .o incompatible with F90

fid Warning on line 8 of file.f: ON EXTERNAL not supported by F90

fid Warning on line 9 of file.f: Detected IOSTAT specifier in OPEN statement: Minor differences exist between F90 and F77 IOSTAT error numbers

The incompatibilities currently detected by fid are:

The I/O specifiers to the OPEN statement listed in “Input/output” (page 134).

The HP FORTRAN 77 forms of ON EXTERNAL and ON INTERNAL.

LOGICAL types used as operands to the .EQ. and .NE. operators.

All HP FORTRAN 77 compiler directives except those listed in “Directives” (page 134).

Command-line options that are not supported (see Table 37 (page 131)) or that have been replaced by f90 options (see Table

on page 221).

NOTE: fid's list of incompatibilities will be periodically updated. For more information about the fid command, see thefid((1)) man page.

140 Migrating to HP Fortran