nielsAD / lape

Scripting engine with Pascal-like syntax for FPC and Delphi
114 stars 27 forks source link

How to set the return type of a registered function? #203

Closed jarroddavis68 closed 3 hours ago

jarroddavis68 commented 3 hours ago

Is there an example anywhere of doing this?

I'm registering with: LCompiler.addGlobalMethod('function test(): string;', @test, Self);

jarroddavis68 commented 3 hours ago

Ok, I see how to do it now.