From 84597fcf74fc74672fe664456e62ec6be5f2b066 Mon Sep 17 00:00:00 2001 From: Matthias Andreas Benkard Date: Tue, 2 Sep 2008 11:59:47 +0200 Subject: Add classes MLKNoSuchSymbolError, MLKStreamError, and MLKUnboundVariableError. --- MLKThrowException.m | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) (limited to 'MLKThrowException.m') diff --git a/MLKThrowException.m b/MLKThrowException.m index 2c512a7..b306aec 100644 --- a/MLKThrowException.m +++ b/MLKThrowException.m @@ -22,12 +22,17 @@ @implementation MLKThrowException --(MLKThrowException *) initWithCatchTag:(MLKSymbol *)catchTag - value:(id)value +-(id) initWithCatchTag:(MLKSymbol *)catchTag + values:(NSArray *)values { - self = [super init]; + self = [super initWithName:@"MLKThrowException" + reason:[NSString stringWithFormat: + @"THROW: tag %@, values %@.", + MLKPrintToString(catchTag), + MLKPrintToString(values)] + userInfo:nil]; LASSIGN (_catchTag, catchTag); - LASSIGN (_value, value); + LASSIGN (_values, values); return self; } @@ -36,15 +41,15 @@ return _catchTag; } --(id) value +-(NSArray *) thrownValues { - return _value; + return _values; } -(void) dealloc { - LRELEASE (_catchTag); - LRELEASE (_value); + LDESTROY (_catchTag); + LDESTROY (_values); [super dealloc]; } @end -- cgit v1.2.3