summaryrefslogtreecommitdiff
path: root/MLKRoot.m
diff options
context:
space:
mode:
authorMatthias Benkard <mulk@Minimulk.local>2008-08-24 18:44:05 +0200
committerMatthias Benkard <mulk@Minimulk.local>2008-08-24 18:44:05 +0200
commitf403bb6e9b0c64e2ce05eaf382c95884e753644e (patch)
treee90e54bb8bd0b546dba671741d9a2d062707fefb /MLKRoot.m
parent03f8b9a2dd1a41baee46fd82e07545ad7c10986d (diff)
Promote special operator EVAL to an intrinsic function.
Diffstat (limited to 'MLKRoot.m')
-rw-r--r--MLKRoot.m8
1 files changed, 8 insertions, 0 deletions
diff --git a/MLKRoot.m b/MLKRoot.m
index 361ce16..8045f54 100644
--- a/MLKRoot.m
+++ b/MLKRoot.m
@@ -776,4 +776,12 @@ as provided by method %@ of object %@",
? (id)[arglist array]
: (id)[NSArray array])];
}
+
++(NSArray *) eval:(NSArray *)args
+{
+ id evaluand = denullify ([args objectAtIndex:0]);
+ return [MLKInterpreter eval:evaluand
+ inLexicalContext:[MLKLexicalContext globalContext]
+ withEnvironment:[MLKLexicalEnvironment globalEnvironment]];
+}
@end