blob: eaf715d6c958ef806eb1cc701fc1e6dab4c82901 [file] [log] [blame]
MG Mud User88f12472016-06-24 23:31:02 +02001SYNOPSIS
Zesstra715ec202025-07-09 22:18:31 +02002 closure unbound_lambda(mixed *args, mixed)
MG Mud User88f12472016-06-24 23:31:02 +02003
Zesstra715ec202025-07-09 22:18:31 +02004DESCRIPTION
5 Constructs a lambda closure that is not bound to an object,
6 like lambda function in LISP.
7 The closure cannot contain references to global variables, and
8 all lfun closures are inserted as is, since there is no native
9 object for this closure. You need to bind it before it can be
10 called. Ordinary objects can only bind to themselves, binding
11 to other objects causes a privilege violation(). The point is
12 that previous_object for calls done from inside the closure
13 will reflect the object doing bind_lambda(), and all object /
14 uid based security will also refer to this object.
MG Mud User88f12472016-06-24 23:31:02 +020015
Zesstra715ec202025-07-09 22:18:31 +020016 The first argument is an array describing the arguments
17 (symbols) passed to the closure upon evaluation by funcall()
18 or apply(), the second arg forms the code of the closure.
MG Mud User88f12472016-06-24 23:31:02 +020019
Zesstra715ec202025-07-09 22:18:31 +020020HISTORY
21 Introduced in 3.2@82.
MG Mud User88f12472016-06-24 23:31:02 +020022
Zesstra715ec202025-07-09 22:18:31 +020023SEE ALSO
MG Mud User88f12472016-06-24 23:31:02 +020024 closures(LPC), lambda(E), apply(E), funcall(E), bind_lambda(E)