This is the mail archive of the gcc-patches@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]

Re: [C++ PATCH] Fix dynamic_cast<XXX &> in template (PR c++/34364)


Jakub Jelinek wrote:

> 2007-12-10  Jakub Jelinek  <jakub@redhat.com>
> 
> 	PR c++/34364
> 	* rtti.c (build_dynamic_cast): Call convert_from_reference even for
> 	dynamic_cast in a template.
> 
> 	* g++.dg/rtti/dyncast2.C: New test.

Good work, this is fine.

(This is the long-standing issue that C++ does not have expressions of
reference type.  Variables and data members can have reference type, and
functions can return reference types, but expressions as such always
have non-reference types.  But, we've never quite made the internal
representation consistent with that.)

-- 
Mark Mitchell
CodeSourcery
mark@codesourcery.com
(650) 331-3385 x713


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