It turns out it's quite hard to have @safe pure nothrow functions. Oh, and const.
Kagamin via Digitalmars-d
digitalmars-d at puremagic.com
Sun Sep 14 01:50:30 PDT 2014
On Sunday, 14 September 2014 at 01:38:33 UTC, Jakob Ovrum wrote:
> This is necessary for `inout` to work with callback functions,
> such as with internal iteration (i.e. `opApply`).
Can you write a pass and xfail test for it? This scenario looks
non-trivial.
> It can be worked around exactly the same way you would work
> around it with functions that return a value - by duplicating
> the function. It is essentially the same problem and thus
> `inout` could easily be used to fix it.
Can you elaborate? I don't quite understand, what you mean.
More information about the Digitalmars-d
mailing list