// This file is part of the Luau programming language and is licensed under MIT License; see LICENSE.txt for details #pragma once #include "Luau/Cancellation.h" #include "Luau/Error.h" #include #include #include namespace Luau { class TimeLimitError : public InternalCompilerError { public: explicit TimeLimitError(const std::string& moduleName) : InternalCompilerError("Typeinfer failed to complete in allotted time", moduleName) { } }; class UserCancelError : public InternalCompilerError { public: explicit UserCancelError(const std::string& moduleName) : InternalCompilerError("Analysis has been cancelled by user", moduleName) { } }; struct TypeCheckLimits { std::optional finishTime; std::optional instantiationChildLimit; std::optional unifierIterationLimit; std::shared_ptr cancellationToken; }; } // namespace Luau