Vote UpVote

Function pointers, direct method implementation now in DWScript

DelphiTools – The googlecode SVN version of DWS introduces delegates capability: Function pointers are now supported in DWS, the syntax is similar to Delphi, though no distinction is made between standalone functions and methods, ie. as long as the parameter(s) and return types match, the following will work: type TMyFunc = function (i : Integer) : String; var f : TMyFunc; f := IntToStr; f := SomeObject.SomeMatchingFunc; f := TSomeClass.SomeMatchingClassFunc; Support for direct method implementation from within the class declaration has been added, ie. the following code (which will likely be ...
Favorite? Off-Topic? Eric @ 2011-04-04 16:34


Visits: 575
Votes: 2
Favorites: 0
Off-Topic: 0

Visits by Source

User Actions

Users who voted for this posting

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)