The information in this article applies to:
SYMPTOMSApplications compiled with Microsoft FORTRAN version 5.0 or 5.1 that initialize entire structures in DATA statements may produce incorrect results. CAUSEInitializing entire structures in a DATA statement is not permitted (Microsoft FORTRAN version 5.1 "Reference" manual, page 140), but no error or warning is emitted by the compiler. Subsequent use of that structure variable may lead to incorrect results. RESOLUTIONTo initialize structure variables through DATA statements, specify every element of the structure separately. STATUSMicrosoft has confirmed this to be a problem in Microsoft FORTRAN versions 5.0 and 5.1 for MS-DOS and OS/2, and version 5.1 for Windows. This problem was corrected in FORTRAN PowerStation version 4.0. MORE INFORMATIONThe following code fails to produce any error message and the resulting output is incorrect: Sample Code #1
The following code demonstrates the correct use of a structure variable in
a DATA statement:
Sample Code #2
Additional query words: 1.00 5.00 5.10
Keywords : kbLangFortran |
Last Reviewed: November 3, 1999 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |