[Bug c++/51641] Lookup finds enclosing class member instead of template parameter
dodji at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Mon Jan 30 14:37:00 GMT 2012
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51641
--- Comment #2 from Dodji Seketeli <dodji at gcc dot gnu.org> 2012-01-30 14:26:19 UTC ---
Author: dodji
Date: Mon Jan 30 14:26:12 2012
New Revision: 183726
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=183726
Log:
PR c++/51641 - Lookup finds enclosing class member instead of template
parameter
gcc/cp/
PR c++/51641
* cp-tree.h (template_type_parameter_p): Declare new function.
(parameter_of_template_p): Remove
* pt.c (template_type_parameter_p): Define new function.
(parameter_of_template_p): Remove.
* name-lookup.c (binding_to_template_parms_of_scope_p): Don't rely
on parameter_of_template_p anymore. Compare the level of the
template parameter to the depth of the template.
gcc/testsuite/
PR c++/51641
* g++.dg/lookup/hidden-class17.C: New test.
Added:
trunk/gcc/testsuite/g++.dg/lookup/hidden-class17.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/cp-tree.h
trunk/gcc/cp/name-lookup.c
trunk/gcc/cp/pt.c
trunk/gcc/testsuite/ChangeLog
More information about the Gcc-bugs
mailing list