This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [C++ RFC / patch] PR 32674


Mark Mitchell wrote:

I'm not sure; we might be parsing this as a comma-expression.  My memory
of the grammar is that we shouldn't be doing that, but I'd have to
recheck in detail.

What about just:

int i(3, 7);


This is rejected as "initializer expression list treated as compound expression".

But this is accepted:

int i = (3, 7);

and the behavior is thus consistent. I agree about a comma-expression, things seems ok after all ;)

Paolo.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]