Should we deprecate comma?
Asman01
jckj33 at gmail.com
Tue Mar 25 08:20:35 PDT 2014
On Tuesday, 25 March 2014 at 13:15:17 UTC, Timon Gehr wrote:
> On 03/25/2014 02:08 PM, bearophile wrote:
>> Steve Teale:
>>
>>> The only place I have tended to use the comma operator is in
>>> ternary
>>> expressions
>>>
>>> bool universal;
>>>
>>> atq = whatever? 0: universal = true, 42;
>>
>> I classify that as quite tricky code, it's a negative example
>> :-(
>>
>> Bye,
>> bearophile
>
> It's not tricky code. It is not even valid code. Operator
> precedence from lowest to highest: , = ?.
Even ternary operator itself isn't allowed in a lot of
programming team.
More information about the Digitalmars-d
mailing list