* Gabriel Dos Reis:
>>> Is this intentional? The equivalent "new char[a][b]" is rejected (as
>>> required by the C++ standard).
>>
>> Is there any reason that g++ should reject your sample program?
>
> Yes: there is no obvious reason for gratuitous incompatibility in
> semantics.
That, and it re
On Mon, Sep 21, 2009 at 4:56 PM, Ian Lance Taylor wrote:
> Florian Weimer writes:
>
>> G++ currently accepts the following code:
>>
>> char *
>> alloc(unsigned a, unsigned b)
>> {
>> typedef char array[a];
>> return &**(new array[b]);
>> }
>>
>> Is this intentional? The equivalent "new char[
Florian Weimer writes:
> G++ currently accepts the following code:
>
> char *
> alloc(unsigned a, unsigned b)
> {
> typedef char array[a];
> return &**(new array[b]);
> }
>
> Is this intentional? The equivalent "new char[a][b]" is rejected (as
> required by the C++ standard).
Is there any r