if (cause instanceof UnableToResolveForeignEntityException) {
generateLogger.logMessage(((UnableToResolveForeignEntityException)cause).getCompilerMessage());
}
// Code generation aborted. Error generating code for: {cl.getQualifiedName()}
generateLogger.logMessage(new CompilerMessage(new MessageKind.Error.CodeGenerationAborted(gmf.getQualifiedName().getQualifiedName()), e));
} catch (CompilerMessage.AbortCompilation e2) {/* Ignore exceptions generated by the act of logging. */}
return generateLogger.getMaxSeverity();
}
}
fixupPushGlobals (module);
} catch (Exception e) {
try {
if (generateLogger.getNErrors() > 0) {
//if an error occurred previously, we continue to compile the program to try to report additional
//meaningful compilation errors. However, this can produce spurious exceptions related to the fact
//that the program state does not satisfy preconditions because of the initial error(s). We don't
//report the spurious exception as an internal coding error.
generateLogger.logMessage(new CompilerMessage(new MessageKind.Fatal.UnableToRecoverFromCodeGenErrors(module.getName())));
} else {
generateLogger.logMessage(new CompilerMessage(new MessageKind.Fatal.CodeGenerationAbortedDueToInternalCodingError(module.getName()), e));
}
} catch (CompilerMessage.AbortCompilation ace) {
/* Ignore exceptions generated by the act of logging. */
}
} catch (Error e) {
try {
generateLogger.logMessage(new CompilerMessage(new MessageKind.Error.CodeGenerationAbortedWithException(module.getName(), e)));
} catch (CompilerMessage.AbortCompilation ace) {
/* Ignore exceptions generated by the act of logging. */
}
} finally {
if (logger != null) {