Created on 2001-10-22.00:00:00 last changed 243 months ago
Rationale (October, 2004):
Duplicate of issue 299.
Should it be allowed to use an object of a class type having a single conversion function to an integral type as an array size in the first bound of the type in an array new?
struct A { operator int(); } a; int main () { new int[a]; }
There are similar accommodations for the expression in a delete (7.6.2.9 [expr.delete] paragraph 1) and in a switch (8.5.3 [stmt.switch] paragraph 2) . There is also widespread existing practice on this (g++, EDG, MSVC++, and Sun accept it, and even cfront 3.0.2).
History | |||
---|---|---|---|
Date | User | Action | Args |
2004-11-07 00:00:00 | admin | set | messages: + msg1108 |
2004-11-07 00:00:00 | admin | set | status: open -> dup |
2001-10-22 00:00:00 | admin | create |