Missing python-like chaining in D
H. S. Teoh
hsteoh at quickfur.ath.cx
Thu Feb 24 21:26:04 UTC 2022
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.
T
--
Written on the window of a clothing store: No shirt, no shoes, no service.
More information about the Digitalmars-d
mailing list