D dropped in favour of C# for PSP emulator
Nick Sabalausky
SeeWebsiteToContactMe at semitwist.com
Fri May 11 21:39:02 PDT 2012
"Ali Çehreli" <acehreli at yahoo.com> wrote in message
news:jok8f1$k1r$1 at digitalmars.com...
> On 05/11/2012 02:45 PM, Timon Gehr wrote:
>> On 05/11/2012 10:10 PM, Nick Sabalausky wrote:
>>> I use 'in' all the time, and I never even think about it returning a
>>> pointer. I just do:
>>>
>>> if(foo in bar)
>>>
>>> And it just works. So I don't see a particularly big problem here.
>>>
>>>
>>
>> Try this:
>>
>> bool fun(){ return foo in bar; }
>
> Isn't that an inconsistency in the language then? Are pointer values
> implicitly convertible to bool or not?
>
Like Timon said, it's a feature of "if". I agree it's weird and confusing,
though. At least I'm used to it :/
More information about the Digitalmars-d
mailing list