This is part of the C ++ standard; if it is not valid in g ++ then g ++ was inappropriate. There are several sections from the C ++ standard (ISO / IEC 14882: 2003):
5.3.4 / 15 regarding the new expression says:
If the new-initializer has the form (), the element is initialized with the value
8.5 / 5 regarding initializers says:
To initialize an object of type type T means:
- T - ( 9) (12.1), T ( , T );
- T - , , T ;
- T - , ;
-
, ints, , .