Created on 1999-06-08.00:00:00 last changed 208 months ago
Proposed resolution (10/00):
In 18.2 [except.ctor] paragraph 2, replace
If the object or array was allocated in a new-expression and the new-expression does not contain a new-placement, the deallocation function (220.127.116.11 [basic.stc.dynamic.deallocation], 15.5 [class.free]) is called to free the storage occupied by the object; the deallocation function is chosen as specified in 8.3.4 [expr.new]. If the object or array was allocated in a new-expression and the new-expression contains a new-placement, the storage occupied by the object is deallocated only if an appropriate placement operator delete is found, as specified in 8.3.4 [expr.new].
If the object or array was allocated in a new-expression, the matching deallocation function (18.104.22.168 [basic.stc.dynamic.deallocation], 8.3.4 [expr.new], 15.5 [class.free]), if any, is called to free the storage occupied by the object.
See also issue 429.
If a placement allocation function has default arguments for all its parameters except the first, it can be called using non-placement syntax. In such a case, it is not clear whether the deallocation function to be called if the constructor terminates by throwing an expression is determined on the basis of the syntax of the new-expression (i.e., a non-placement deallocation function) or the declaration of the selected (placement) allocation function. 8.3.4 [expr.new] paragraph 19 indicates that the deallocation function must match the declaration of the allocation function. However, 18.2 [except.ctor] says that the distinction is based on whether the new-expression contains a new-placement or not.
|2003-04-25 00:00:00||admin||set||status: dr -> tc1|
|2000-11-18 00:00:00||admin||set||status: ready -> dr|
|2000-05-21 00:00:00||admin||set||status: drafting -> ready|
|2000-02-23 00:00:00||admin||set||messages: + msg238|
|2000-02-23 00:00:00||admin||set||status: open -> drafting|