提交 467627fa 编写于 作者: L Lukasz

Add mono_unity_gc_enable and mono_unity_gc_disable

上级 34dc12d5
......@@ -30,6 +30,10 @@
#include <mono/metadata/tokentype.h>
#include <mono/utils/mono-string.h>
#if HAVE_BDWGC_GC
#include <external/bdwgc/include/gc.h>
#endif
#include <glib.h>
#ifdef WIN32
......@@ -900,6 +904,25 @@ mono_unity_get_unitytls_interface()
return gUnitytlsInterface;
}
// gc
MONO_API void mono_unity_gc_enable()
{
#if HAVE_BDWGC_GC
GC_enable();
#else
g_assert_not_reached ();
#endif
}
MONO_API void mono_unity_gc_disable()
{
#if HAVE_BDWGC_GC
GC_disable();
#else
g_assert_not_reached ();
#endif
}
MONO_API void
mono_unity_install_unitytls_interface(unitytls_interface_struct* callbacks)
{
......
......@@ -150,6 +150,10 @@ typedef struct unitytls_interface_struct unitytls_interface_struct;
MONO_API unitytls_interface_struct* mono_unity_get_unitytls_interface();
MONO_API void mono_unity_install_unitytls_interface(unitytls_interface_struct* callbacks);
// gc
MONO_API void mono_unity_gc_enable();
MONO_API void mono_unity_gc_disable();
//misc
MonoAssembly* mono_unity_assembly_get_mscorlib();
MonoImage* mono_unity_image_get_mscorlib();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册