MCPcopy Create free account
hub / github.com/anjo76/angelscript / IsCompatibleWithTypeId

Method IsCompatibleWithTypeId

sdk/angelscript/source/as_scriptfunction.cpp:572–589  ·  view source on GitHub ↗

interface

Source from the content-addressed store, hash-verified

570
571// interface
572bool asCScriptFunction::IsCompatibleWithTypeId(int typeId) const
573{
574 asCDataType dt = engine->GetDataTypeFromTypeId(typeId);
575
576 // Make sure the type is a function
577 if (!dt.IsFuncdef())
578 return false;
579
580 asCScriptFunction *func = CastToFuncdefType(dt.GetTypeInfo())->funcdef;
581 if( !IsSignatureExceptNameEqual(func) )
582 return false;
583
584 // If this is a class method, then only return true if the object type is the same
585 if( objectType != func->objectType )
586 return false;
587
588 return true;
589}
590
591// interface
592const char *asCScriptFunction::GetModuleName() const

Callers

nothing calls this directly

Calls 4

CastToFuncdefTypeFunction · 0.85
GetDataTypeFromTypeIdMethod · 0.80
IsFuncdefMethod · 0.80
GetTypeInfoMethod · 0.80

Tested by

no test coverage detected