未验证 提交 067ea2fc 编写于 作者: A Alex Thibodeau 提交者: GitHub

Merge pull request #1372 from Unity-Technologies/fix-1293534

Expose mono_class_is_open_constructed_type to Unity to allow us to ch…
...@@ -287,7 +287,10 @@ MonoClass* mono_unity_class_get_generic_definition(MonoClass* klass) ...@@ -287,7 +287,10 @@ MonoClass* mono_unity_class_get_generic_definition(MonoClass* klass)
MonoClass* mono_unity_class_inflate_generic_class(MonoClass *gklass, MonoGenericContext *context) MonoClass* mono_unity_class_inflate_generic_class(MonoClass *gklass, MonoGenericContext *context)
{ {
MonoError error; MonoError error;
return mono_class_inflate_generic_class_checked(gklass, context, &error); MonoClass* klass;
klass = mono_class_inflate_generic_class_checked(gklass, context, &error);
mono_error_cleanup (&error);
return klass;
} }
gboolean mono_unity_class_has_parent_unsafe(MonoClass *klass, MonoClass *parent) gboolean mono_unity_class_has_parent_unsafe(MonoClass *klass, MonoClass *parent)
...@@ -1945,4 +1948,10 @@ MONO_API uint32_t ...@@ -1945,4 +1948,10 @@ MONO_API uint32_t
mono_unity_allocation_granularity() mono_unity_allocation_granularity()
{ {
return (uint32_t)(2 * sizeof(void *)); return (uint32_t)(2 * sizeof(void *));
} }
\ No newline at end of file
MONO_API gboolean
mono_unity_class_is_open_constructed_type (MonoClass *klass)
{
return mono_class_is_open_constructed_type (&klass->byval_arg);
}
...@@ -219,4 +219,6 @@ mono_unity_set_enable_handler_block_guards (mono_bool allow); ...@@ -219,4 +219,6 @@ mono_unity_set_enable_handler_block_guards (mono_bool allow);
mono_bool mono_bool
mono_unity_get_enable_handler_block_guards (void); mono_unity_get_enable_handler_block_guards (void);
MONO_API gboolean mono_unity_class_is_open_constructed_type (MonoClass *klass);
#endif #endif
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册