Converting function to delegate - was Re: How to know whether to use function or delegate

Frits van Bommel fvbommel at REMwOVExCAPSs.nl
Sat Jul 22 19:22:20 PDT 2006


Chris Miller wrote:
> Isn't there an easier way to directly convert a function to a delegate?

Ehm, how about this:

	mydelegate = { somethingStatic(); };

Seems pretty easy to me. Gotta love that new delegate syntax. :)
Gets a bit uglier once you add arguments though (especially if there are 
more than a few).



More information about the Digitalmars-d mailing list