The information in this article applies to:
SYMPTOMSCompiling code using Microsoft FORTRAN versions 4.0, 4.01, 4.1, and 5.0 under MS-DOS, and versions 4.1 and 5.0 under OS/2, when that code contains a subroutine with nested DO-loops in which arrays are indexed using a DO variable from an outer DO-loop, may generate the following error:
RESOLUTIONThe error can be suppressed by turning off loop optimization, using a temporary variable in place of the DO variable from the outer DO-loop, or by upgrading to FORTRAN 5.1. STATUSMicrosoft has confirmed this to be a problem in Microsoft FORTRAN versions 4.0, 4.01, 4.1, and 5.0 for MS-DOS and versions 4.1 and 5.0 for OS/2. This problem was corrected in Microsoft FORTRAN 5.1. MORE INFORMATIONThis error is caused by a problem with loop optimization. The following code generates the F1001 error: Sample code
Compiling with the /Od option or with the /Odct options suppresses the
error. Microsoft FORTRAN version 5.1 will not generate the error.
If a temporary variable is used in place of the DO variable "i" in the array subscript, the error will not generated. This allows full optimization to be used when compiling. The following code demonstrates this solution:
Additional query words: 4.00 4.01 4.10 5.00
Keywords : |
Last Reviewed: November 1, 1999 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |