This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

g++ bug


Hi.

I have a strange internal error of gcc. The following code is a minimal
version reproducing it when being compiled with `g++ test.C'

-----------------------------
namespace NS {

template<typename T>
class C
{
public:
  class D {};
  enum E {a,b,c};
};

}

void
main()
{
  NS::C<int> tri;
}
-----------------------------

If I leave away the namespace, the declaration of D or E or the template
parameter, or even if I swap the declaration of D and E, the error does
not occur.

My machine is a very new SGI visual PC and SGI's linux is very new and
probably buggy, so maybe its not really gcc's fault. The version
obtained by g++ -v is:

gcc version egcs-2.91.66 19990314/Linux (egcs-1.1.2 release)

Have fun,

	Marc

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]