if ($exit = null ===
$error) { $error =
error_get_last();
} if ($error &&
$error['type'
] &= \E_PARSE | \E_ERROR | \E_CORE_ERROR | \E_COMPILE_ERROR
) { // Let's not throw anymore but keep logging
$handler->
throwAt(0, true
);
$trace =
$error['backtrace'
] ?? null;
if (str_starts_with($error['message'
], 'Allowed memory'
) ||
str_starts_with($error['message'
], 'Out of memory'
)) { $fatalError =
new OutOfMemoryError($handler->levels
[$error['type'
]].': '.
$error['message'
], 0,
$error, 2, false,
$trace);
} else { $fatalError =
new FatalError($handler->levels
[$error['type'
]].': '.
$error['message'
], 0,
$error, 2, true,
$trace);
} } else { $fatalError = null;
} try { if (null !==
$fatalError) { self::
$exitCode = 255;
$handler->
handleException($fatalError);
}