From 3fd292f83ef33f8052feb22eb133d37913d33c66 Mon Sep 17 00:00:00 2001 From: Matthias Benkard Date: Sun, 24 Aug 2008 17:03:33 +0200 Subject: Refactor the interpreter so as to build upon the MLKForm class cluster. The transition is not finished yet, so lots of things are broken right now. --- MLKInterpreter.h | 25 +++++++++++++++---------- 1 file changed, 15 insertions(+), 10 deletions(-) (limited to 'MLKInterpreter.h') diff --git a/MLKInterpreter.h b/MLKInterpreter.h index 59e2dfd..67f7377 100644 --- a/MLKInterpreter.h +++ b/MLKInterpreter.h @@ -16,9 +16,10 @@ * along with this program. If not, see . */ -#import "MLKStream.h" +#import "MLKForm.h" #import "MLKLexicalContext.h" #import "MLKLexicalEnvironment.h" +#import "MLKStream.h" #import #import @@ -43,15 +44,19 @@ enum MLKProcessingMode inLexicalContext:(MLKLexicalContext *)context withEnvironment:(MLKLexicalEnvironment *)lexenv; -+(NSArray*) eval:(id)program - inLexicalContext:(MLKLexicalContext *)context - withEnvironment:(MLKLexicalEnvironment *)lexenv - expandOnly:(BOOL)expandOnly; ++(BOOL) load:(MLKStream *)stream verbose:(BOOL)verbose print:(BOOL)print; -+(NSArray*) eval:(id)program - inLexicalContext:(MLKLexicalContext *)context - withEnvironment:(MLKLexicalEnvironment *)lexenv - mode:(enum MLKProcessingMode)mode; ++(id) compile:(id)object + inContext:(MLKLexicalContext *)context; +@end -+(BOOL) load:(MLKStream *)stream verbose:(BOOL)verbose print:(BOOL)print; + +@interface MLKForm (MLKInterpretation) +-(NSArray *) interpret; +-(NSArray *) interpretWithEnvironment:(MLKLexicalEnvironment *)env; +-(NSArray *) reallyInterpretWithEnvironment:(MLKLexicalEnvironment *)env; +@end + +@interface MLKBodyForm (MLKInterpretation) +-(NSArray *) interpretBodyWithEnvironment:(MLKLexicalEnvironment *)env; @end -- cgit v1.2.3