Package: g++
Version: 2:2.95.4-8
Severity: normal

Hi,

In trying to compile the following C++ program fragment using the command
line
        g++ -c foo.cc
        
I get the messages

        foo.cc:20: Internal compiler error.
        foo.cc:20: Please submit a full bug report.
        foo.cc:20: Internal compiler error:
        foo.cc:20: See <URL:http://www.gnu.org/software/gcc/bugs.html> for 
instructions.

I believe the syntax to be correct.  This is the simplest case I could find.

Program code follows.  Thanks,

Avery

======snip=======

template <class T>
class Generic
{
public:
    T *obj;
    
    Generic(T &_obj) : obj(&_obj) { }
};

class Whatever
{
public:
    template <class T>
    class Gen2 : public Generic<T>
    {
    public:
        int x;
        
        Gen2() : Generic<T>(x) { }
    };
};

=========snip=========

-- System Information
Debian Release: testing/unstable
Kernel Version: Linux insight 2.4.9 #1 Thu Nov 1 23:29:21 EST 2001 i686 unknown

Versions of the packages g++ depends on:
ii  cpp            2.95.4-8       The GNU C preprocessor.
ii  g++-2.95       2.95.4-0.01042 The GNU C++ compiler.
ii  gcc-2.95       2.95.4-0.01042 The GNU C compiler.


Reply via email to