Corrected sourcePath info in Errors
@@ -196,12 +196,12 @@ class Error (Exception):
def __str__ (self):
result = 'Error while compiling (offending file last):'
+ for importRecord in program.importStack [ : -1]:
try:
sourcePath = importRecord[0].sourcePath
except:
sourcePath = '<unknown>'
- for importRecord in program.importStack [ : -1]:
result += '\n\tFile \'{}\', line {}, at import of:'.format (sourcePath, importRecord [1])
result += '\n\tFile \'{}\', line {}, namely:'.format (str (program.importStack [-1][0] ), self.lineNr)
