Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

fatal error C1001: INTERNAL COMPILER ERROR

116 views
Skip to first unread message

Daniel P.

unread,
Mar 11, 2004, 4:45:23 PM3/11/04
to
I'm trying to move a C++ app from Visual Studio C++ 6.0 to MSDEV .NET 2003
and I get the following error. It happens a header file at a forward
declaration:

class CString; // <<<< here


Compiling...
cl : Command line warning D4025 : overriding '/EHs' with '/EHa'
StdAfx.cpp
d:\dev\CURRENT\retail\..\Common\Stuff\XHelpers.h(30) : fatal error C1001:
INTERNAL COMPILER ERROR
(compiler file 'msc1.cpp', line 2701)
Please choose the Technical Support command on the Visual C++
Help menu, or open the Technical Support help file for more information


Hendrik Schober

unread,
Mar 12, 2004, 6:46:15 AM3/12/04
to


The error must be something that you didn't
post. This

class CString;

int main()
{
return 0;
}

compiles fine for me.
VC usually ICEs on real syntax errors. Of
course, with an error message like this, it
is hard to find the cause. I suggest you
try to throw together a simple repro case
(preferrably <50LOC). It might well be you
find the error while doing this. Otherwise
someone here might.
Also, if there's a repro it can be added to
MS' bug DB, so we have a chance to get this
fixed for the next version.

Schobi

--
Spam...@gmx.de is never read
I'm Schobi at suespammers dot org

"Sometimes compilers are so much more reasonable than people."
Scott Meyers


Daniel P.

unread,
Mar 12, 2004, 9:14:24 AM3/12/04
to
Unfortunately it is a pretty big project.
It fires the error when it deals with "stdafx.h". This file includes lots of
other files.

I was thinking to do what you suggested: create a test project to duplicate
the error. I hope I'll have time.

Thanks!


"Hendrik Schober" <Spam...@gmx.de> wrote in message
news:eWtnQhCC...@TK2MSFTNGP09.phx.gbl...

Michael Buechel

unread,
Mar 12, 2004, 9:27:48 AM3/12/04
to
occurs this compiler error in a dll or a exe?

--
kind regards, michael

while(!sleep())
++sheep;


Daniel P.

unread,
Mar 12, 2004, 9:38:15 AM3/12/04
to
It's an MDI app using MFC.
I succefully created a test project.

It seems that if you have a header file that has

class CString;

and you include this header file into "stdafx.h" you get that error.

I'm going to send the test project to MS.

Thanks!


"Michael Buechel" <Mue...@gmx.at> wrote in message
news:%23G%232X4DC...@TK2MSFTNGP09.phx.gbl...

Daniel P.

unread,
Mar 12, 2004, 11:11:15 AM3/12/04
to
I spoke with Microsoft incident support for my MSDN licence and the fix is:

#if _MFC_VER < 0x0700
class CString;
#endif

CString is not a class in MFC anymore. It is a template in ATL so forward
declarations are invalid.


"Daniel P." <danu...@hotmail.comU> wrote in message
news:%23%23VJp%23DCEH...@TK2MSFTNGP11.phx.gbl...

Unknown

unread,
Mar 15, 2004, 1:08:56 PM3/15/04
to
have the same errors, please help me!

[strstream]
// CLASS istringstream
class istringstream
: public istream // <<< here

D:\visualcpp\Vc7\include\strstream(120) : fatal error C1001: INTERNER COMPILERFEHLER
(Compilerdatei 'msc1.cpp', Zeile 2701)
Wählen Sie im Menü '?' von Visual C++
den Befehl 'Software Service', oder öffnen Sie die Hilfedatei für den Software Service, um weitere Informationen zu erhalten


very important, i think this is a bug.

is there a patch?

**********************************************************************
Sent via Fuzzy Software @ http://www.fuzzysoftware.com/
Comprehensive, categorised, searchable collection of links to ASP & ASP.NET resources...

Daniel P.

unread,
Mar 15, 2004, 4:20:25 PM3/15/04
to
There is no patch yet but there may be one.

"alex tugarev" <ma...@alex-t.de> wrote in message
news:uroKWirC...@TK2MSFTNGP09.phx.gbl...

Hendrik Schober

unread,
Mar 16, 2004, 3:57:20 AM3/16/04
to
alex tugarev <ma...@alex-t.de> wrote:
> have the same errors, please help me!


You also have an ICE. It might be triggered by the
same error, or it might not.

> [strstream]
> // CLASS istringstream
> class istringstream
> : public istream // <<< here
>
> D:\visualcpp\Vc7\include\strstream(120) : fatal error C1001: INTERNER COMPILERFEHLER
> (Compilerdatei 'msc1.cpp', Zeile 2701)
> Wählen Sie im Menü '?' von Visual C++
> den Befehl 'Software Service', oder öffnen Sie die Hilfedatei für den Software Service, um weitere Informationen zu
> erhalten
>
>
> very important, i think this is a bug.

An ICE certainly is a bug.

> is there a patch?

Show some code (<20LOC) that we can paste
into our editor, compile, and see the error.

G

unread,
Mar 22, 2004, 4:17:17 PM3/22/04
to
Hi...

To reproduce, forward declare the CString in the header file.

If you just remove the forward declaration, it should work fine.

Thanks,
G

___
Newsgroups brought to you courtesy of www.dotnetjohn.com

Hendrik Schober

unread,
Mar 23, 2004, 5:51:46 AM3/23/04
to
G <aquar...@yahoo.com> wrote:
> Hi...
>
> To reproduce, forward declare the CString in the header file.
>
> If you just remove the forward declaration, it should work fine.

I'm not sure what you mean. I _did_
forward declare 'CString' in the code
below.

> Thanks,
> G
> [...]


> > The error must be something that you didn't
> > post. This
> >
> > class CString;
> >
> > int main()
> > {
> > return 0;
> > }
> >
> > compiles fine for me.

> [...]

0 new messages