[Bug c++/15534] Fails to inherit types from base class
pinskia at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Wed May 19 20:22:00 GMT 2004
------- Additional Comments From pinskia at gcc dot gnu dot org 2004-05-19 03:12 -------
This is equivent to:
template <class T> class A
{
typedef int t;
};
template <class T> class B: A<T>
{
typedef t t1;
};
Which is invalid as t is not dependent so it needs to be declare not in the subclasses.
The fix would be to declare t1 as "typedef A<T>::t t1;"
Also one the mainline I get the following note:
pr15534.ii:31253: error: `size_type' does not name a type
pr15534.ii:31253: note: (perhaps `typename std::allocator<_CharT>::size_type' was intended)
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |INVALID
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15534
More information about the Gcc-bugs
mailing list