exports.invokeGuardedCallbackAndCatchFirstError=function(...)exports.invokeGuardedCallback(...)if hasError then local Y=clearCaughtError()if not hasRethrowError then hasRethrowError=true rethrowError=Y end end end

exports.invokeGuardedCallbackAndCatchFirstError = function(...)
	-- deviation: instead of the weird `this` indirection, pass varargs through
	exports.invokeGuardedCallback(...)

	if hasError then
		local err = clearCaughtError()

		if not hasRethrowError then
			hasRethrowError = true
			rethrowError = err
		end
	end
end
