24.11.2014 Views

Open Watcom FORTRAN 77 Language Reference

Open Watcom FORTRAN 77 Language Reference

Open Watcom FORTRAN 77 Language Reference

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>FORTRAN</strong> Source Program Format<br />

<strong>FORTRAN</strong> <strong>77</strong> allows up to 19 continuation lines to continue a statement. <strong>Open</strong> <strong>Watcom</strong> <strong>FORTRAN</strong> <strong>77</strong><br />

extends this by allowing more than 19 continuation lines. A minimum of 61 continuation lines are<br />

permitted when the source statement ends at column 72. A minimum of 31 continuation lines are permitted<br />

when the source statement ends at column 132. The maximum number of continuation lines depends on the<br />

sum of the lengths of all the continuation lines.<br />

1.3.5 Significance of the Blank Character<br />

Except in the following cases, blank characters have no meaning within a program unit.<br />

(1) Character and Hollerith constants.<br />

(2) Apostrophe and H edit descriptors in format specifications.<br />

For example, the symbolic name A B is the same as the symbolic name AB.<br />

1.3.6 Significance of Lower Case Characters (Extension)<br />

Except in the following cases, lower case characters are treated as if they were the upper case equivalent.<br />

This is a <strong>Open</strong> <strong>Watcom</strong> <strong>FORTRAN</strong> <strong>77</strong> extension to the usual rules of <strong>FORTRAN</strong>.<br />

(1) Character and Hollerith constants.<br />

(2) Apostrophe and H edit descriptors in format specifications.<br />

Hence, TOTAL, total, and Total represent the same symbolic name and 3F10.2 and 3f10.2<br />

represent the same format edit descriptor.<br />

1.3.7 Examples<br />

Example:<br />

C This and the following five lines are comment lines.<br />

c The following statement "INDEX = INDEX + 2" has a<br />

c statement number and is continued by placing a "$"<br />

c in column 6.<br />

* Column Numbers<br />

*234567890<br />

10 INDEX = INDEX<br />

$ + 2<br />

* The above blank lines are treated like comment lines.<br />

The following example demonstrates the use of comment lines, blanks lines, and continuation lines. We<br />

use the symbol "$" to denote continuation lines although any character other than a blank or "0" could have<br />

been used.<br />

Source Program Format 5

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!