diff options
Diffstat (limited to 'gcc/cp/typeck.c')
-rw-r--r-- | gcc/cp/typeck.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/gcc/cp/typeck.c b/gcc/cp/typeck.c index 7e2dcccac6b..ae9267509b6 100644 --- a/gcc/cp/typeck.c +++ b/gcc/cp/typeck.c @@ -7963,8 +7963,7 @@ convert_for_initialization (tree exp, tree type, tree rhs, int flags, && (TREE_CODE (type) != REFERENCE_TYPE || TREE_CODE (TREE_TYPE (type)) != ARRAY_TYPE)) || (TREE_CODE (TREE_TYPE (rhs)) == FUNCTION_TYPE - && (TREE_CODE (type) != REFERENCE_TYPE - || TREE_CODE (TREE_TYPE (type)) != FUNCTION_TYPE)) + && !TYPE_REFFN_P (type)) || TREE_CODE (TREE_TYPE (rhs)) == METHOD_TYPE) rhs = decay_conversion (rhs, complain); |