src/vs/workbench/api/browser/mainThreadErrors.ts/MainThreadErrors/$onUnexpectedError
class MainThreadErrors:	$onUnexpectedError(err: any | SerializedError): void {
		if (err && err.$isError) {
			const { name, message, stack } = err;
			err = err.noTelemetry ? new ErrorNoTelemetry() : new Error();
			err.message = message;
			err.name = name;
			err.stack = stack;
		}
		onUnexpectedError(err);
	}