Title
The meaning of "resource" in the Cpp17Destructible requirements is undefined
Status
wp
Section
[utility.arg.requirements]
Submitter
Jiang An

Created on 2025-08-15.00:00:00 last changed 1 month ago

Messages

Date: 2025-11-11.10:48:16

Proposed resolution:

This wording is relative to N5014.

  1. Modify [utility.arg.requirements], Table 35 [tab:cpp17.destructible] as indicated:

    Table 35 — Cpp17Destructible requirements [tab:cpp17.destructible]
    Expression Post-condition
    u.~T() All resources owned by `u` are reclaimed, nNo exception is propagated.
    [Note 3: Array types and non-object types are not Cpp17Destructible. — end note]
Date: 2025-11-11.10:48:16

[ Kona 2025-11-08; Status changed: Voting → WP. ]

Date: 2025-10-15.00:00:00

[ 2025-10-14; Reflector poll ]

Set status to Tentatively Ready after six votes in favour during reflector poll.

Date: 2025-08-15.00:00:00

The meaning of "resource" in the Cpp17Destructible requirements cannot be inferred from the standard wording and it seems unlikely that the standard will determine its meaning in the future. What are considered as resources generally depends on users' intent, so the standard shouldn't determine the well-definedness of a program execution due to it. Moreover, the wording doesn't seem to consider shared ownership, which can be represented by `shared_ptr`.

History
Date User Action Args
2025-11-11 10:48:16adminsetmessages: + msg15639
2025-11-11 10:48:16adminsetstatus: voting -> wp
2025-10-30 17:45:31adminsetstatus: ready -> voting
2025-10-14 17:45:42adminsetmessages: + msg15154
2025-10-14 17:45:42adminsetstatus: new -> ready
2025-08-17 08:59:38adminsetmessages: + msg14937
2025-08-15 00:00:00admincreate