Cannot implicitly convert delegate to function
Bruno Medeiros
brunodomedeirosATgmail at SPAM.com
Sun Apr 30 09:46:19 PDT 2006
pragma wrote:
> In article <e2qv42$2gnt$1 at digitaldaemon.com>, Stewart Gordon says...
>> Jarrett Billingsley wrote:
>> <snip>
>>> The other way around.. I don't think so either. Something tells me the
>>> mechanism for a delegate call would screw up if the context pointer were
>>> null, or if the function weren't designed to be a delegate.
>> But why? I can't understand why a function that doesn't touch the
>> context pointer at all can't be trivially be converted to a delegate in
>> which the context pointer is null.
>>
>
> Well, there's always the trival solution of declaring all of your "functions" as
> static members of a class - but that's not always possible. ;)
How would that be a solution? Static member functions of a class are
free-functions.
--
Bruno Medeiros - CS/E student
http://www.prowiki.org/wiki4d/wiki.cgi?BrunoMedeiros#D
More information about the Digitalmars-d-learn
mailing list