summaryrefslogtreecommitdiff
path: root/MLKReader.m
diff options
context:
space:
mode:
authorMatthias Andreas Benkard <matthias@benkard.de>2008-07-07 01:16:01 +0200
committerMatthias Andreas Benkard <matthias@benkard.de>2008-07-07 01:16:01 +0200
commitd8fa1c646c7e6a8fe5d6235b3e635b30f2bfa745 (patch)
treead91edb4891e83505ed7c1dfd6eb7f6d279e2fe6 /MLKReader.m
parent97c4f28084dcd8ec65f739618e61fb5cfdfec9c8 (diff)
Ditch MLKEndOfFileError.
Diffstat (limited to 'MLKReader.m')
-rw-r--r--MLKReader.m10
1 files changed, 6 insertions, 4 deletions
diff --git a/MLKReader.m b/MLKReader.m
index 4acf24e..282db60 100644
--- a/MLKReader.m
+++ b/MLKReader.m
@@ -19,7 +19,6 @@
#import "MLKReader.h"
#import "MLKCharacter.h"
#import "MLKReadtable.h"
-#import "MLKEndOfFileError.h"
#import "MLKReaderError.h"
#import "MLKDynamicContext.h"
#import "MLKEnvironment.h"
@@ -62,7 +61,8 @@
if ([stream isEOF])
{
if (eofError)
- [[[MLKEndOfFileError alloc] initWithStream:stream] raise];
+ [NSException raise:@"MLKEndOfFileError"
+ format:@"Premature end of file on stream %@.", stream];
else
return eofValue;
}
@@ -98,7 +98,8 @@
if ([readtable isSingleEscapeCharacter:ch])
{
if ([stream isEOF])
- [[[MLKEndOfFileError alloc] initWithStream:stream] raise];
+ [NSException raise:@"MLKEndOfFileError"
+ format:@"Premature end of file on stream %@.", stream];;
token = [NSMutableString stringWithCapacity:8];
[token appendFormat:@"%C", [stream readChar]];
@@ -136,7 +137,8 @@
else if ([readtable isSingleEscapeCharacter:ch])
{
if ([stream isEOF])
- [[[MLKEndOfFileError alloc] initWithStream:stream] raise];
+ [NSException raise:@"MLKEndOfFileError"
+ format:@"Premature end of file on stream %@.", stream];
[token appendFormat:@"%C", [stream readChar]];
ever_escaped = YES;