Add generics support to TypeInfo.GetVTable
This patch fixes TypeInfo.GetVTable so that it specializes the vtable for generic type instances. Also fix a minor bug in PropertyInfo that would pass null pointers to GetMethodByDefinition.
This commit is contained in:
@@ -77,8 +77,10 @@ namespace Il2CppInspector.Reflection {
|
||||
rootDefinition = propertyDef;
|
||||
|
||||
Name = propertyDef.Name;
|
||||
GetMethod = declaringType.GetMethodByDefinition(propertyDef.GetMethod);
|
||||
SetMethod = declaringType.GetMethodByDefinition(propertyDef.SetMethod);
|
||||
if (propertyDef.GetMethod != null)
|
||||
GetMethod = declaringType.GetMethodByDefinition(propertyDef.GetMethod);
|
||||
if (propertyDef.SetMethod != null)
|
||||
SetMethod = declaringType.GetMethodByDefinition(propertyDef.SetMethod);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user