[PATCH, RFA, C++] ICE on ill-formed template_fun(&mem_fun) within template function
Alexandre Oliva
aoliva@redhat.com
Wed Apr 12 07:09:00 GMT 2006
On Mar 29, 2006, Alexandre Oliva <aoliva@redhat.com> wrote:
> This alternate, much simpler patch, appears to fix the problem in
> mainline, by extending the code that matches ADDR_EXPR and
> COMPONENT_REF to avoid wrapping them in a NON_DEPENDENT_EXPR if their
> inner_expr is an overloaded function, to match ADDR_EXPR of
> COMPONENT_REF as well. I'm still testing it, but does it look
> like it might be a better fix for the problem?
FWIW, testing succeeded on amd64-linux-gnu. I was set off track for a
while because of the various failures in the trunk that looked like
regressions possibly related with the patch, but that turned out to
also be present without it.
> Red Hat bugzilla #168260 triggered an ICE on an ill-formed construct,
> taking the address of a non-static member function using an
> unqualified id, within a template function, and passing that as an
> argument in a function call requiring overload resolution. Fixing
> that uncovered a number of other situations in which we used to fail
> or to handle things differently within templates.
:ADDPATCH c++/template:
-------------- next part --------------
A non-text attachment was scrubbed...
Name: cp-unify-nondepexpr-5.patch
Type: text/x-patch
Size: 4735 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20060412/5e346e31/attachment.bin>
-------------- next part --------------
--
Alexandre Oliva http://www.lsd.ic.unicamp.br/~oliva/
Secretary for FSF Latin America http://www.fsfla.org/
Red Hat Compiler Engineer aoliva@{redhat.com, gcc.gnu.org}
Free Software Evangelist oliva@{lsd.ic.unicamp.br, gnu.org}
More information about the Gcc-patches
mailing list