diff options
author | Jason Merrill <jason@redhat.com> | 2014-01-28 17:00:05 -0500 |
---|---|---|
committer | Jason Merrill <jason@gcc.gnu.org> | 2014-01-28 17:00:05 -0500 |
commit | 4c690cea4cbbf3a707918cf039de565ce9a3ab4b (patch) | |
tree | 9605d218db0f780051e9178026f77a9ec6cbdb44 /gcc/cp | |
parent | 19cef1c1f1da315cf5c66aeea465058d3ef5114b (diff) | |
download | gcc-4c690cea4cbbf3a707918cf039de565ce9a3ab4b.zip gcc-4c690cea4cbbf3a707918cf039de565ce9a3ab4b.tar.gz gcc-4c690cea4cbbf3a707918cf039de565ce9a3ab4b.tar.bz2 |
re PR c++/59818 (Bogus error: call of overloaded .... is ambiguous)
PR c++/59818
* pt.c (tsubst_function_type): Make sure we keep the same function
quals.
From-SVN: r207215
Diffstat (limited to 'gcc/cp')
-rw-r--r-- | gcc/cp/ChangeLog | 4 | ||||
-rw-r--r-- | gcc/cp/pt.c | 2 |
2 files changed, 6 insertions, 0 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index a0ec066..502f218 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,5 +1,9 @@ 2014-01-28 Jason Merrill <jason@redhat.com> + PR c++/59818 + * pt.c (tsubst_function_type): Make sure we keep the same function + quals. + PR c++/58701 * semantics.c (build_anon_member_initialization): Stop walking when we run out of COMPONENT_REFs. diff --git a/gcc/cp/pt.c b/gcc/cp/pt.c index 6c68bae..011db2c 100644 --- a/gcc/cp/pt.c +++ b/gcc/cp/pt.c @@ -11189,6 +11189,8 @@ tsubst_function_type (tree t, else { tree r = TREE_TYPE (TREE_VALUE (arg_types)); + /* Don't pick up extra function qualifiers from the basetype. */ + r = cp_build_qualified_type_real (r, type_memfn_quals (t), complain); if (! MAYBE_CLASS_TYPE_P (r)) { /* [temp.deduct] |