Check if critical error before throwing

This commit is contained in:
Sathya Gunasekaran
2023-11-07 11:04:34 +00:00
parent cf70ef899e
commit 688305a978
@@ -278,9 +278,8 @@ export function compileProgram(
memoSlots: compiledFn.memoSlotsUsed,
});
} catch (err) {
handleError(pass, fn.node.loc ?? null, err);
hasCriticalError ||= isCriticalError(err);
handleError(pass, fn.node.loc ?? null, err);
return;
}