Missing python-like chaining in D
Stanislav Blinov
stanislav.blinov at gmail.com
Thu Feb 24 21:51:09 UTC 2022
On Thursday, 24 February 2022 at 21:26:04 UTC, H. S. Teoh wrote:
> On Thu, Feb 24, 2022 at 09:19:38PM +0000, Stanislav Blinov via
> Digitalmars-d wrote:
>> On Thursday, 24 February 2022 at 21:05:49 UTC, H. S. Teoh
>> wrote:
> [...]
>> > There's std.algorithm.ordered which lets you write:
>> >
>> > ordered(i, 4, n)
>> >
>> > which isn't too bad, it just needs to be promoted more so
>> > that people are more aware of it.
>>
>> No short circuit though.
> [...]
>
> The docs don't say it, but it *does* in fact short-circuit if
> you look at the implementation.
Yes, but after evaluating all the arguments :)
More information about the Digitalmars-d
mailing list