If fn is a function reference, Func(fn) returns it. Thus, fn := Func(fn) can be used to ensure fn is a function reference. If fn is neither a valid function name nor a function reference, Func returns a blank value.
Code: Select all
; Retrieve a reference to the function named "StrLen".
fn := Func("StrLen")
fn := Func(fn)
Error: Parameter #1 invalid.
Line#
002: fn := Func("StrLen")
---> 003: fn := Func(fn)
004: Exit
005: Exit
005: Exit
The current thread will exit.