Vote UpVote

Creating a delegate at runtime

Delphi sorcery – We know how anonymous methods work in Delphi for a while now. Barry explained how you can use that knowledge to put a delegate into a method pointer and Mason used the enhanced RTTI to get some details about them.So we know that a delegate type (like TProc<T>) is basically an interface with an Invoke method that has the same signature as the delegate type definition (like procedure(Arg: T)). We also know that there is an TInterfacedObject behind it that is normally compiler created (these classes with $ActRec in their name).So we basically have all we need to create our own delegate. ...
Favorite? Off-Topic? noreply@blogger.com @ 2012-04-22 18:35


Visits: 918
Votes: 4
Favorites: 0
Off-Topic: 0

Visits by Source

User Actions

Users who voted for this posting

Primoz Gabrijelcic
Yogi Yang
Contact us to advertise on DelphiFeeds.com

Community Links

Torry Firebird News


Please login or register to use this functionality.
(click on this box to dismiss)