BUG: F2707 on an Internal Read or Write to Record Element

ID: Q118433


The information in this article applies to:
  • Microsoft FORTRAN for MS-DOS, version 5.1
  • Microsoft FORTRAN PowerStation for MS-DOS, versions 1.0, 1.0a
  • Microsoft Fortran Powerstation 32 for Windows NT, version 1.0


SYMPTOMS

A program that uses a character string that is a member of an element in an array of records as an internal file gets the following error when compiling:

error F2707: illegal unit specifier


STATUS

Microsoft has confirmed this to be a bug in FORTRAN for MS-DOS, version 5.1, the FORTRAN PowerStation for MS-DOS, versions 1.0 and 1.0a, and the FORTRAN PowerStation 32 for Windows NT, version 1.0. We are researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available.


MORE INFORMATION

Reading or writing to a string used as an internal file generates a compiler error if the string is a member of an element of an array of records.

To demonstrate the problem, compile the sample code below. If "r" were a single record (not an array), or if "r" were an array of character strings (not records), the sample code would compile without error.

Sample Code


c compile options needed: none

      structure /s/ 
        character*6 cvar
      end structure
      record /s/ r(10)
      write (r(1).cvar,'(I6)') 123
      end 

Additional query words: 5.10 1.00 1.00a

Keywords :
Version : :1.0,1.0a,5.1
Platform :
Issue type :


Last Reviewed: November 2, 1999
© 2000 Microsoft Corporation. All rights reserved. Terms of Use.