How to partially apply member functions?

Andrea Fontana via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Thu Jun 29 07:30:19 PDT 2017


On Thursday, 29 June 2017 at 13:01:10 UTC, ct wrote:
> I was only able to do it this way:
>
>     auto on_next_previous = &this.OnNextPreviousMatch;
>     entry_.addOnNextMatch(&partial!(on_next_previous, true));
>     entry_.addOnPreviousMatch(&partial!(on_next_previous, 
> false));

I think you should provide a better example in order to get some 
help.
We neither know what argument .addOnNextMatch() expects.

Usually a full example on https://dpaste.dzfl.pl or other 
websites is more useful :)

Andrea


More information about the Digitalmars-d-learn mailing list