1
0
Fork 0
mirror of https://github.com/beefytech/Beef.git synced 2025-06-08 03:28:20 +02:00

Added Variant support to reflected method invocation

This commit is contained in:
Brian Fiete 2020-06-22 17:06:26 -07:00
parent 5bdaeadc25
commit 2eb7ce3e1a
7 changed files with 387 additions and 7 deletions

View file

@ -1226,6 +1226,12 @@ void DbgExprEvaluator::BeefTypeToString(const DbgTypedValue& val, String& outStr
_TypeCode mTypeCode;
uint8 mAlign;
};
struct _PointerType : _Type
{
_TypeCode mElementType;
};
struct _String
{
@ -1343,6 +1349,14 @@ void DbgExprEvaluator::BeefTypeToString(const DbgTypedValue& val, String& outStr
else
{
BfTypeCode typeCode = (BfTypeCode)mDebugger->ReadMemory<uint8>(typeAddr + (int)offsetof(_Type, mTypeCode));
if (typeCode == BfTypeCode_Pointer)
{
_TypeId elementType = mDebugger->ReadMemory<_TypeId>(typeAddr + offsetof(_PointerType, mElementType));
BeefTypeToString(GetBeefTypeById(elementType), outStr);
outStr += "*";
return;
}
switch (typeCode)
{
case BfTypeCode_None: outStr += "void"; break;