diff options
author | Jason Merrill <jason@redhat.com> | 2012-01-11 21:30:47 -0500 |
---|---|---|
committer | Jason Merrill <jason@gcc.gnu.org> | 2012-01-11 21:30:47 -0500 |
commit | efcc9293a66671758a373804b60e7bb9517b8eac (patch) | |
tree | 9981dff1e612d221af04881c381213633dfa0578 /gcc/cp/call.c | |
parent | 00733a00417dbd433152c3ceaadd78a6edf77730 (diff) | |
download | gcc-efcc9293a66671758a373804b60e7bb9517b8eac.zip gcc-efcc9293a66671758a373804b60e7bb9517b8eac.tar.gz gcc-efcc9293a66671758a373804b60e7bb9517b8eac.tar.bz2 |
re PR c++/51565 (fastcall in array of method pointers: internal compiler error)
PR c++/51565
* call.c (standard_conversion): For ptrmemfuncs, compare the
static_fn_types.
From-SVN: r183120
Diffstat (limited to 'gcc/cp/call.c')
-rw-r--r-- | gcc/cp/call.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/gcc/cp/call.c b/gcc/cp/call.c index 57b1765..f7cfbd0 100644 --- a/gcc/cp/call.c +++ b/gcc/cp/call.c @@ -1274,10 +1274,8 @@ standard_conversion (tree to, tree from, tree expr, bool c_cast_p, tree tbase = class_of_this_parm (tofn); if (!DERIVED_FROM_P (fbase, tbase) - || !same_type_p (TREE_TYPE (fromfn), TREE_TYPE (tofn)) - || !compparms (TREE_CHAIN (TYPE_ARG_TYPES (fromfn)), - TREE_CHAIN (TYPE_ARG_TYPES (tofn))) - || cp_type_quals (fbase) != cp_type_quals (tbase)) + || !same_type_p (static_fn_type (fromfn), + static_fn_type (tofn))) return NULL; from = build_memfn_type (fromfn, tbase, cp_type_quals (tbase)); |