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]
Other format: [Raw text]

[Bug c++/15534] New: Fails to inherit types from base class


In the source at the point of the first error messages:
    typedef
    typename std::allocator<T>::size_type st1;
    typedef
    typename size_type  st;
    typedef
    size_type   st2;
the first typedef works but the second two do not even though the class is derived from std::allocator<T>. In simple cases, e.g.:class A{
public:
    typedef
    int B;
    };

class C : public A {
public:
    B b;
    };

the derived class can inherit the types of the base class, but not here. Sticking in a "typename" doesn't help.

-- 
           Summary: Fails to inherit types from base class
           Product: gcc
           Version: 3.4.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: igodard at pacbell dot net
                CC: gcc-bugs at gcc dot gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15534


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