mirror of
git://gcc.gnu.org/git/gcc.git
synced 2024-12-18 11:59:43 +08:00
re PR c++/8849 (ICE in resolve_overloaded_unification for invalid code)
PR c++/8849 * pt.c (resolve_overloaded_unification): Handle FUNCTION_DECL. * g++.dg/template/ptrmem4.C: New test. From-SVN: r62181
This commit is contained in:
parent
1824b90d08
commit
db0f613dfa
@ -1,3 +1,8 @@
|
||||
2003-01-31 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
|
||||
|
||||
PR c++/8849
|
||||
* pt.c (resolve_overloaded_unification): Handle FUNCTION_DECL.
|
||||
|
||||
2003-01-31 Nathan Sidwell <nathan@codesourcery.com>
|
||||
|
||||
* cp-tree.h (BINFO_SUBVTT_INDEX, BINFO_VPTR_INDEX,
|
||||
|
@ -8910,7 +8910,8 @@ resolve_overloaded_unification (tparms, targs, parm, arg, strict,
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (TREE_CODE (arg) == OVERLOAD)
|
||||
else if (TREE_CODE (arg) == OVERLOAD
|
||||
|| TREE_CODE (arg) == FUNCTION_DECL)
|
||||
{
|
||||
for (; arg; arg = OVL_NEXT (arg))
|
||||
{
|
||||
|
@ -1,3 +1,8 @@
|
||||
2003-01-31 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
|
||||
|
||||
PR c++/8849
|
||||
* g++.dg/template/ptrmem4.C: New test.
|
||||
|
||||
2003-01-29 Mark Mitchell <mark@codesourcery.com>
|
||||
|
||||
* g++.dg/parser/constant1.C: New test.
|
||||
|
20
gcc/testsuite/g++.dg/template/ptrmem4.C
Normal file
20
gcc/testsuite/g++.dg/template/ptrmem4.C
Normal file
@ -0,0 +1,20 @@
|
||||
// { dg-do compile }
|
||||
|
||||
// Origin: Scott Snyder <snyder@fnal.gov>
|
||||
|
||||
// PR c++/8849
|
||||
// Pointer to member function template argument deduction ICE.
|
||||
|
||||
|
||||
template <class CONT> void queryAliases(CONT& fill_me); // { dg-error "argument" }
|
||||
|
||||
struct SpyExample
|
||||
{
|
||||
void ready();
|
||||
void inputs();
|
||||
};
|
||||
|
||||
void SpyExample::ready()
|
||||
{
|
||||
queryAliases(inputs); // { dg-error "convert" }
|
||||
}
|
Loading…
Reference in New Issue
Block a user