KnowledgeBase Archive

An Archive of Early Microsoft KnowledgeBase Articles

View on GitHub

Q44300: Internal Compiler Error: omf.c:1.70 Line 146

Article: Q44300
Product(s): See article
Version(s): 5.10
Operating System(s): OS/2
Keyword(s): ENDUSER | buglist5.10 | mspl13_c
Last Modified: 30-MAY-1989

The following error message is produced when the example below is
compiled with the Microsoft C Optimizing Compiler Version 5.10:

   fatal error C1001: Internal Compiler Error
                   (compiler file '@(#)omf.c:1.70', line 146)
                   Contact Microsoft Technical Support

To prevent the error message, reverse the order of the #pragma and
#include directives.

Microsoft has confirmed this to be a problem in Version 5.10. We are
researching the problem and will post new information as it becomes
available.

Support for the data_seg pragma may be eliminated from future releases
of the C Optimizing Compiler. We recommend that you use the /ND
compiler option which provides equivalent functionality.

The following example demonstrates the problem:

#include "os2def.h"            /* os2def.h from IBM's toolkit v1.1 */
#pragma data_seg( global )

char *errors[] = {
   "no error",
   "unknown error"
  };

To prevent the problem, reverse the order of the #pragma and #include
directives, as follows:

#pragma data_seg( global )
#include "os2def.h"

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.

Copyright Microsoft Corporation 1986-2002.