diff options
-rw-r--r-- | MLKReader.m | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/MLKReader.m b/MLKReader.m index 8784f30..68db172 100644 --- a/MLKReader.m +++ b/MLKReader.m @@ -449,6 +449,12 @@ { package = [MLKPackage findPackage:[token substringToIndex:packageMarker]]; + + if (!package) + [NSException raise:@"MLKReaderError" + format:@"Can't find package %@.", + [token substringToIndex:packageMarker]]; + if ([readtable isPackageMarker:[token characterAtIndex:(i+1)]]) symbolName = [token substringFromIndex:(packageMarker+2)]; else |