form infile outfile [options]*
StartstatemenT=nn IncrementstatemenT=mm StartFormat=nn IncrementFormat=mm StartseQuence=nn IncrementseQuence=mm (+|-)Fold (-) (+|-)Indent (-) (+|-)Warning (+)
form /freeform fixform form /freeform fixform st=1000 it=10 +warning form /freeform fixform sq=10000 iq=5 form /freeform fixform st=1000 sf=9000 +in +fld +wrn
FORM uses a two-pass process to accept a free format Fortran program and format it with statement numbers right-justified in columns 1-5, comment markers in column 1, continuation markers in column 6, program text in columns 7-72, and, if requested, sequence numbers in columns 73-80. The program tests the "first" card of input in the following manner:
If line numbers are present according to the above test, they are stripped off. If the line number is followed immediately by a "#", the "#" is also stripped off. Lines beginning with a "##", a "$", a "C", or a "*" (comment or control cards) are not reformatted but are folded and continuation from position 73 occurs. (Note: this may cause unsightly comments if one of the lines exceeds 72 characters and subsequent lines are indented by more than 2 or 3 spaces).
If the input and output file names are the same, the input file is copied to the temporary file ".form" and is left in the AFT. The formatted program is not transferred to the output file until all action is complete.
FORM renumbers statements in each routine (or function) using the start and increment numbers specified either explicitly or by default. If no matching statement number is encountered in the current routine or function during conversion of an appropriate number within a statement, the number is converted to zero for identification and debug.
If +Indent is specified, FORM indents "DO loops" in the following manner:
The +Warning option attempts to identify lines that have unbalanced parentheses or quotation marks. When a line with such a problem is identified, a message is directed to the terminal, giving the number of the line that has been identified.
A number of bugs have been identified in this program. Some of them are listed in "expl form bugs".
.form .form1. .form2.
Copyright © 1996, Thinkage Ltd.