version: multiple conditions
ketmar via Digitalmars-d
digitalmars-d at puremagic.com
Thu Jun 18 04:51:04 PDT 2015
On Thu, 18 Jun 2015 09:57:19 +0000, Ola Fosheim Grøstad wrote:
> Although I think it might be more readable to have "and", "or"
> etc as operators. This is actually allowed in C++:
>
> "a && b" <=> "a and b"…
i prefer that to "&&" and "||", tbh, not because i have pascal/oberon
background, but 'cause it's harder to make a typo. "|" is binary, "or" is
logic. simple and easy.
p.s. and i hate that "true" converts to "1". in many forth systems "true"
is "-1", and it's way better. `a&cast(int)true` actually works for the
most widely used case (when a.sizeof <= int.sizeof), for examplt.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: not available
URL: <http://lists.puremagic.com/pipermail/digitalmars-d/attachments/20150618/b0632238/attachment.sig>
More information about the Digitalmars-d
mailing list