just an idea (!! operator)

Roman D. Boiko rb at d-coding.com
Thu Jul 12 06:47:03 PDT 2012


On Thursday, 12 July 2012 at 12:51:38 UTC, Jacob Carlborg wrote:
> On 2012-07-12 13:35, Jonas Drewsen wrote:
>
>> Or the operator?? could be borrowed from c#
>>
>> auto a = foo ?? new Foo();
>>
>> is short for:
>>
>> auto a = foo is null ? new Foo() : foo;
>>
>> /Jonas
>>
>
> I really like that operator. The existential operator, also 
> known as the Elvis operator :) . It's available in many 
> languages with slightly different semantics.

+1


More information about the Digitalmars-d mailing list