An instantly expiring timer?
function
calldestroyfunction(udg_function_variable)
Set function_variable = new function
endfunction
library PrivateStruct requires Alloc
struct AccesibleEverywhere extends array
implement Alloc
static method Display takes nothing returns nothing
call BJDebugMsg("Hello!")
endmethod
private static method create takes nothing returns thistype
return thistype.allocate()
endmethod
endstruct
function f takes nothing returns nothing
local AccessibleEverywhere s = AccesibleEverywhere.allocate() // no error breaking the privacy
// because Alloc's static methods are not private
endfunction
endlibrary
struct S
private static method create takes nothing returns S
return allocate()
endmethod
endstruct
How should function variables be cleared properly during cleanup?
Ouch... I'm starting to see the grounds for the critique of those things.Yeah interface function pointers are integers, and "FuncInt" will get turned into an integer array, and every function pointer will turn into trigger evaluations and duplicated code.