pub struct OverloadResolver { /* private fields */ }Implementations§
Source§impl OverloadResolver
impl OverloadResolver
pub fn is_arity_compatible( &self, candidate: TypePackId, desired: TypePackId, builtin_types: *mut BuiltinTypes, ) -> bool
Source§impl OverloadResolver
impl OverloadResolver
pub fn maybe_emplace_error_error_vec_location_module_name_subtyping_reasoning_optional_type_id_optional_type_id( &self, errors: *mut ErrorVec, arg_location: Location, module_name: &ModuleName, reason: *const SubtypingReasoning, wanted_type: Option<TypeId>, given_type: Option<TypeId>, )
Source§impl OverloadResolver
impl OverloadResolver
pub fn maybe_emplace_error_error_vec_location_module_name_subtyping_reasoning_optional_type_pack_id_optional_type_pack_id( &self, errors: *mut ErrorVec, arg_location: Location, module_name: &ModuleName, reason: *const SubtypingReasoning, wanted_tp: Option<TypePackId>, given_tp: Option<TypePackId>, )
Source§impl OverloadResolver
impl OverloadResolver
pub fn maybe_emplace_error_error_vec_location_module_name_subtyping_reasoning_optional_type_or_pack_optional_type_or_pack( &self, errors: *mut ErrorVec, arg_location: Location, module_name: &ModuleName, reason: *const SubtypingReasoning, wanted_type: Option<TypeOrPack>, given_type: Option<TypeOrPack>, )
Source§impl OverloadResolver
impl OverloadResolver
pub fn new( builtin_types: *mut BuiltinTypes, arena: *mut TypeArena, normalizer: *mut Normalizer, type_function_runtime: *mut TypeFunctionRuntime, scope: *mut Scope, reporter: *mut InternalErrorReporter, limits: *mut TypeCheckLimits, call_location: Location, ) -> Self
Source§impl OverloadResolver
impl OverloadResolver
pub fn overload_resolver_not_null_builtin_types_not_null_type_arena_not_null_normalizer_not_null_type_function_runtime_not_null_scope_not_null_internal_error_reporter_not_null_type_check_limits_location( &mut self, builtin_types: *mut BuiltinTypes, arena: *mut TypeArena, normalizer: *mut Normalizer, type_function_runtime: *mut TypeFunctionRuntime, scope: *mut Scope, reporter: *mut InternalErrorReporter, limits: *mut TypeCheckLimits, call_location: Location, )
Source§impl OverloadResolver
impl OverloadResolver
pub fn report_errors( &self, errors: &mut ErrorVec, fn_ty: TypeId, fn_location: Location, module_name: &ModuleName, arg_pack: TypePackId, arg_exprs: &[*mut AstExpr], reason: &SubtypingReasoning, )
Source§impl OverloadResolver
impl OverloadResolver
Sourcepub fn resolve_overload(
&mut self,
ty: TypeId,
args_pack: TypePackId,
fn_location: Location,
unique_types: *mut DenseHashSet<TypeId>,
_use_free_type_bounds: bool,
) -> OverloadResolution
pub fn resolve_overload( &mut self, ty: TypeId, args_pack: TypePackId, fn_location: Location, unique_types: *mut DenseHashSet<TypeId>, _use_free_type_bounds: bool, ) -> OverloadResolution
C++ OverloadResolution resolveOverload(TypeId ty, TypePackId argsPack, Location fnLocation, NotNull<DenseHashSet<TypeId>> uniqueTypes, bool useFreeTypeBounds).
Source§impl OverloadResolver
impl OverloadResolver
pub fn test_function( &mut self, result: &mut OverloadResolution, fn_ty: TypeId, args_pack: TypePackId, fn_location: Location, unique_types: *mut DenseHashSet<TypeId>, )
Source§impl OverloadResolver
impl OverloadResolver
pub fn test_function_or_call_metamethod( &mut self, result: &mut OverloadResolution, fn_ty: TypeId, args_pack: TypePackId, fn_location: Location, unique_types: *mut DenseHashSet<TypeId>, )
Source§impl OverloadResolver
impl OverloadResolver
pub fn test_function_or_union( &mut self, result: &mut OverloadResolution, fn_ty: TypeId, args_pack: TypePackId, fn_location: Location, unique_types: *mut DenseHashSet<TypeId>, )
Trait Implementations§
Source§impl Clone for OverloadResolver
impl Clone for OverloadResolver
Source§fn clone(&self) -> OverloadResolver
fn clone(&self) -> OverloadResolver
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl !RefUnwindSafe for OverloadResolver
impl !Send for OverloadResolver
impl !Sync for OverloadResolver
impl !UnwindSafe for OverloadResolver
impl Freeze for OverloadResolver
impl Unpin for OverloadResolver
impl UnsafeUnpin for OverloadResolver
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more