BUG: DX1020 or C1001 Generated Using /Gsw and /Bd Switches

Last reviewed: July 22, 1997
Article ID: Q115706
1.00 1.50 WINDOWS kbtool kbbuglist

The information in this article applies to:

  • The Microsoft C/C++ Compiler (CL.EXE), included with:

        - Microsoft Visual C++ for Windows, versions 1.0 and 1.5
    

SYMPTOMS

Compiling the source code shown below will generate the following internal compiler error when the /Gsw compiler option is used on the cl command line

   fatal error C1001: internal compiler error
                      (compiler file 'msc1.cpp', line 585)

Compiling the same source file, but adding the /Bd compiler option, will cause the compiler to generate the error message

   DX1020: unhandled exception: Page fault

instead of the internal compiler error.

This problem does not occur when compiling within the Visual Workbench.

STATUS

Microsoft has confirmed this to be a problem with the C/C++ compiler for MS-DOS, versions 8.0 and 8.0c. We are researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available.

MORE INFORMATION

The following sample code can be used to reproduce this problem.

Sample Code

/* Compile options needed: /c /Gsw (/Bd to see the DX1020 error)
*/

/* NOTE: This code intentionally contains an error */
/* which is necessary to demonstrate the problem   */

#include <afx.h>

class CTest{ public:
   CTime m_x;
};

CTest test;

BOOL func() {

   if (1) {
}


Additional reference words: 8.00 8.00c 1.00 1.50
KBCategory: kbtool kbbuglist
KBSubcategory: CPPIss
Keywords : kb16bitonly


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: July 22, 1997
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.