diff options
author | Jason Merrill <jason@redhat.com> | 2024-01-09 16:00:52 -0500 |
---|---|---|
committer | Jason Merrill <jason@redhat.com> | 2024-01-09 16:04:09 -0500 |
commit | 5a6d3b1737843aa64d83ffc5d639fa0afa5d8318 (patch) | |
tree | ae79a46ef382579cbb5ca1cde6406d9ce2c5d269 /gcc/cp/method.cc | |
parent | bfad006b88ec26e91b7edf9cf9ad4aaf9b8a9727 (diff) | |
download | gcc-5a6d3b1737843aa64d83ffc5d639fa0afa5d8318.zip gcc-5a6d3b1737843aa64d83ffc5d639fa0afa5d8318.tar.gz gcc-5a6d3b1737843aa64d83ffc5d639fa0afa5d8318.tar.bz2 |
c++: explicit object cleanups
The FIXME in xobj_iobj_parameters_correspond was due to expecting
TYPE_MAIN_VARIANT to be the same for all equivalent types, which is not the
case. And I adjusted some comments that I disagree with; the iobj parameter
adjustment only applies to overload resolution, we can handle that in
cand_parms_match (and I have WIP for that).
gcc/cp/ChangeLog:
* call.cc (build_over_call): Refactor handle_arg lambda.
* class.cc (xobj_iobj_parameters_correspond): Fix FIXME.
* method.cc (defaulted_late_check): Adjust comments.
Diffstat (limited to 'gcc/cp/method.cc')
-rw-r--r-- | gcc/cp/method.cc | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/gcc/cp/method.cc b/gcc/cp/method.cc index da6a08a..6a9f03e 100644 --- a/gcc/cp/method.cc +++ b/gcc/cp/method.cc @@ -3400,8 +3400,7 @@ defaulted_late_check (tree fn) || TYPE_REF_IS_RVALUE (fn_obj_ref_type)) return false; /* If implicit_fn's object parameter is not a pointer, something is not - right. (Or we have finally changed the type of the iobj parameter - in iobj member functions.) */ + right. */ gcc_assert (TYPE_PTR_P (TREE_VALUE (implicit_fn_parms))); /* Strip the reference/pointer off each object parameter before comparing them. */ @@ -3422,10 +3421,6 @@ defaulted_late_check (tree fn) { error ("defaulted declaration %q+D does not match the " "expected signature", fn); - /* FIXME: If the user is defaulting an xobj member function we should - emit an xobj member function for a signature. When we do this, maybe - we can just synthesize implicit_fn as an xobj member function and - avoid the dance in compare_fn_parms. */ inform (DECL_SOURCE_LOCATION (fn), "expected signature: %qD", implicit_fn); } |