This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/22227] g++ 4.0.0 has issues with the typedef of reference
- From: "gdr at integrable-solutions dot net" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 29 Jun 2005 00:00:42 -0000
- Subject: [Bug c++/22227] g++ 4.0.0 has issues with the typedef of reference
- References: <20050628223059.22227.jcurran2@uiuc.edu>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From gdr at integrable-solutions dot net 2005-06-29 00:00 -------
Subject: Re: New: g++ 4.0.0 has issues with the typedef of reference
"jcurran2 at uiuc dot edu" <gcc-bugzilla@gcc.gnu.org> writes:
| G++ thinks that a nested type is a nested class and it expects a constructor,
| destructor, or type conversion before the object referenced in the class is
| processed when compiling a function of a nested type defined in the header file
| of a templated class.
|
| Header file below
|
| //C++ STL classes have 12 type definitions, so that every class
| // defines the following type names as nested types:
| //
| // value_type, pointer, reference, const_pointer, const_reference
| // iterator, const_iterator, reverse_iterator, const_reverse_iterator
| // allocator_type, size_type, diference_type
|
| typedef Etype& reference; //list<...>::value_type to access
| //whatever type this list holds
|
|
| template <class Etype>
| typename list<Etype>::reference
| list<Etype>::const_iterator*() const
I don't understand what that line is supposed to mean. It does not
look C++ to me.
-- Gaby
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=22227