Title
Accessibility check for destructor of incomplete class type
Status
wp
Section
7.6.2.9 [expr.delete]
Submitter
Alisdair Meredith

Created on 2024-03-07.00:00:00 last changed 4 days ago

Messages

Date: 2024-09-15.00:00:00

Additional notes (September, 2024)

Paper P3144R2 (Deleting a Pointer to an Incomplete Type Should be Ill-formed), approved in June, 2024 made the deletion of pointer-to-incomplete class types ill-formed, thus the situation cannot appear anymore.

Date: 2024-06-15.00:00:00

[Resolved by paper P3144R2, approved at the June, 2024 meeting.]

Subclause 7.6.2.9 [expr.delete] paragraph 6 specifies:

... The destructor shall be accessible from the point where the delete-expression appears. ...

This check cannot be performed in case the operand of the delete-expression is a pointer to incomplete type.

Possible resolution:

Change in 7.6.2.9 [expr.delete] paragraph 6 as follows:

... The Unless the object being deleted has incomplete class type, the destructor shall be accessible from the point where the delete-expression appears. ...
History
Date User Action Args
2024-12-17 09:54:02adminsetstatus: accepted -> wp
2024-09-25 17:32:08adminsetmessages: + msg7818
2024-09-25 17:32:08adminsetstatus: open -> accepted
2024-03-07 00:00:00admincreate