The FOR option designates various FORTRAN vendors to better support their extensions. Only one FOR option may be entered, i.e., they are mutually exclusive.
If your compiler is not mentioned, (or if you would like to restrict the use of certain extensions), select the Custom option and define the required behavior using the various FX Extension options in the Custom section of "cbfxopts.mac".
The FOR options are:
Absoft compiler options. Like most compilers, Absoft supports the typical contemporary extensions, plus Sun pointers and a variety of VAX extensions. In addition, selecting -FOR=absoft adds support for the following Absoft extensions:
VALUE is ignored GLOBAL /label/ var_array_list [GLOBAL is an alias to COMMON] WHILE()-ENDDO [DO is optional] REPEAT [REPEAT is an alias to ENDDO]
The following Absoft constructs are NOT supported (or allowed):
X lines, (although D lines are supported) IBM VS FORTRAN free form source X exponent for extended precision extended precisions: REAL*12 and COMPLEX*24 memory assignment statement INLINE
Indicates a custom user option setup. Use this option to add support for an additional compiler not currently listed by enabling specific extensions using the FORTRAN extension options.
Strict FORTRAN-77 compliance is provided for portability testing purposes. When this option is turned on (and no extension options are enabled), virtually all extensions will result in an error message. Notable exceptions are tab formatted source and '!' inline comments - since they are frequently used in the source.
For wide portability and reasonable code quality, the MILSPEC extensions can be used as well (turn on the MILSPEC extension option to accept these extensions with this option). All MILSPEC extensions have been grandfathered into Fortran-90.
Alternatively, you can cause FOR_STUDY to simply warn about extensions used in your source. This may be appropriate when use of this option causes too much confusion.
The Fortran-90 source option indicates only Fortran-90 source. At present, a subset of Fortran-90 is supported. The support in the new Fortran-90 syntax option roughly parallels that found in contemporary compilers as of 1993, and thus should be reasonably portable. Items grandfathered into Fortran-90 (and enabled with this option) include the MILSPEC extensions, NAMELIST, REAL*16, COMPLEX*16, and miscellaneous items (e.g., 32 character names, inline comments, length specifiers, etc.). See the Fortran-90 extension option for details of new Fortran-90 syntax support.
This option indicates HP FORTRAN-9000. As of 1993, this compiler is primarily a VAX FORTRAN-77 clone. Very few of the features found in earlier HP FORTRAN compiler syntax are not included. The notable exception is the notation for 16-bit vs. 32-bit integer constants. When followed by an 'I', the integer is a short or 16-bit quantity. When followed by a 'J', it is a long or 32-bit quantity (and is the default). HP FORTRAN 9000 also includes compiler directives denoted by a '$' in column 1 (similar to MS FORTRAN). All are ignored except for the conditional preprocessing statements $IF, $ELSE, $ENDIF, and $SET, which are evaluated according to the conditions defined at the time of processing. The macro "HP_F77" is defined for preprocessing use in "cbfxopts.mac".
This option designates Lahey FORTRAN F77L v5.0. As there is little difference between the 16 and 32 bit versions syntactically, this option serves both. Lahey F77L employs a basic set of contemporary extensions coupled with a good start on the new Fortran-90 standard (see the Fortran-90 new syntax option). F77L also supports the MS conditional preprocessing statements $DEFINE, $IF, $ELSEIF, $ELSE, $ENDIF, and $UNDEFINE.
Microsoft FORTRAN v5.1 and FORTRAN Powerstation v1.0 are indicated with this option, since there are few syntactical differences between the two compilers. MS FORTRAN employs a number of contemporary VAX and Fortran-8x extensions, hence, numerous extensions are enabled. Microsoft FORTRAN was quick to implement some extensions in the new Fortran standard, although these differ from the final standard adopted as Fortran-90; thus, some support enabled with the Fortran-90 option may differ from that of MS. Support is enabled for MS metacommands (denoted by a '$' in column 1). Any MS conditional preprocessing statements (e.g., $IF) in your source code will be evaluated according to present definitions and the particular code selected for analysis. With this option on, the MS FORTRAN declaration attributes (e.g., [near]) are tolerated by FOR_STUDY, but generally are ignored. Attributes are tolerated in type, common, dimension, record and external statements. In addition, alphas other than 'C' are tolerated in column 1; they are considered comments.
Selecting this option indicates SGI FORTRAN. SGI FORTRAN is a VAX/Sun FORTRAN clone.
Selecting this option indicates Sun FORTRAN Version 2.0. Sun FORTRAN primarily follows VAX extensions. It also supports the Cray POINTER statement; the AUTOMATIC/STATIC statements are supported, too. In addition, several alternative bit functions are added to the intrinsic table with the INTRNSDEF statement.
Selecting this option indicates VAX FORTRAN Version 4.0 source - possibly the definition of a de facto FORTRAN extension "standard" to FORTRAN-77. In addition to selecting numerous FORTRAN extension options, "cbfxopts.mac" redefines DICTIONARY as INCLUDE, which requires extracting the specified code from the VMS Common Data Dictionary, CDD, and placing it into a regular file. Once completed, the various DICTIONARY references in your code will be satisfied. Any OPTIONS specified with this VAX FORTRAN statement will need to be specified separately in terms of FOR_STUDY options (since the OPTIONS statement is ignored). Additional VAX FORTRAN intrinsic functions are added to the intrinsic table (via the INTRNSDEF statement in "cbfxopts.mac").
This option indicates Watcom FORTRAN v9.x source.
The supported contemporary extensions include the MILSPEC extensions, length specifiers, initialization in type statements, double complex, VAX style structures and records, F90 allocate/deallocate and exit/cycle, namelist, integers used as logicals and other loose typing accepted, additional I/O specifiers allowed with warnings, and support for multiple assignments.
Plus the following unique extensions:
LOOP-ENDLOOP, LOOP-UNTIL, WHILE()DO-ENDWHILE, WHILE()DO-UNTIL, WHILE(expr) stmt QUIT, --- (treated as EXIT) OTHERWISE, --- (treated as CASE DEFAULT)
plus variations on the SELECTCASE, list directed READ & PRINT, ALLOCATE, and Watcom style construct names. It allows C style character constants, Zffff hex constants in DATA, and RETURN from mains.
The following Watcom constructs are NOT supported (or allowed):
initializing character items with numeric data non-character arrays as format specifiers GUESS-ADMIT-ENDGUESS ATENDDO-ENDATEND ATEND-ENDATEND REMOTEBLOCK-ENDBLOCK EXECUTE