summaryrefslogtreecommitdiff
path: root/MLKInterpreter.m
diff options
context:
space:
mode:
authorMatthias Andreas Benkard <matthias@benkard.de>2008-08-18 01:19:06 +0200
committerMatthias Andreas Benkard <matthias@benkard.de>2008-08-18 01:22:08 +0200
commitbdfe4801295945b92f84b8c03cb2e0be485ae4f0 (patch)
tree4e3b51b3ad5269404a168fe10b9e3ffddcacb3d5 /MLKInterpreter.m
parentec1b0c41160ce153f3b2cd39ffeb2f4522fd1c38 (diff)
Promote special operator APPLY to an intrinsic function.
Diffstat (limited to 'MLKInterpreter.m')
-rw-r--r--MLKInterpreter.m29
1 files changed, 1 insertions, 28 deletions
diff --git a/MLKInterpreter.m b/MLKInterpreter.m
index 540b9b5..0cdf904 100644
--- a/MLKInterpreter.m
+++ b/MLKInterpreter.m
@@ -193,34 +193,7 @@
}
}
- if (car == APPLY)
- {
- MLKCons *rest = denullify([[self eval:[[[program cdr] cdr] car]
- inLexicalContext:context
- withEnvironment:lexenv
- expandOnly:expandOnly]
- objectAtIndex:0]);
-
- id function = denullify([[self eval:[[program cdr] car]
- inLexicalContext:context
- withEnvironment:lexenv
- expandOnly:expandOnly]
- objectAtIndex:0]);
-
- if (expandOnly)
- RETURN_VALUE ([MLKCons cons:APPLY
- with:[MLKCons cons:function
- with:[MLKCons cons:rest
- with:nil]]]);
-
- if ([function isKindOfClass:[MLKSymbol class]])
- function = [lexenv functionForSymbol:function];
-
- return [function applyToArray:(rest
- ? (id)[rest array]
- : (id)[NSArray array])];
- }
- else if (car == CATCH)
+ if (car == CATCH)
{
id catchTag;
NSArray *values;