Microsoft KB Archive/147748

= DOCERR: Program-Name Not Optional in PROGRAM Statement =

Article ID: 147748

Article Last Modified on 12/8/2003

-

APPLIES TO


 * Microsoft FORTRAN PowerStation 1.0 Standard Edition
 * Microsoft Fortran PowerStation 1.0a for MS-DOS
 * Microsoft FORTRAN PowerStation 32
 * Microsoft FORTRAN PowerStation 4.0 Standard Edition

-



This article was previously published under Q147748



SUMMARY
The Microsoft Fortran PowerStation version 4.0 reference manual and Help file incorrectly state that the program-name is optional when using the the PROGRAM statement. Actually, it is not optional. Compiling a source file using the PROGRAM statement without a program-name will cause one of the following syntax errors to occur:

For Fortran PowerStation versions 1.0 and 1.0a for MS-DOS and Fortran PowerStation version 1.0 for Windows NT, the error is:

error F2115: syntax error

For Fortran PowerStation version 4.0 with the .for file extension, the errors are:

error FOR2934: lexical error: Unrecognized statement error FOR3852: syntax error

For Fortran PowerStation version 4.0 with the .f90 file extension, the error is:

error FOR3852: syntax error



MORE INFORMATION
According to the FORTRAN standard, the PROGRAM statement is optional, but if it is used, a program-name is required.

Sample Code to Illustrate Problem
C Compile options needed: none

PROGRAM PRINT *, 'Hello!, World' END

Additional query words: 1.00 1.00a 4.00

Keywords: kblangfortran KB147748

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.