static private IsCallable ( object obj ) : bool | ||
obj | object | |
return | bool |
internal static bool IsCallable( object obj )
{
return obj is Function || obj is UserCallback;
}
/// <summary> /// Returns the value as a callable (if it is callable, else returns Callable.Nil). /// </summary> public Callable ToCallable() { if (!Callable.IsCallable(RefVal)) { return(Callable.Nil); } return(new Callable() { Val = RefVal }); }