xLua
xLua copied to clipboard
isMethodInBlackList IsPointer type Bug
xLua/Assets/XLua/Src /CodeEmit.cs
static bool isMethodInBlackList(MethodBase mb)
{
if (mb.GetParameters().Any(pInfo => pInfo.ParameterType.IsPointer)) return true;
if (mb is MethodInfo && (mb as MethodInfo).ReturnType.IsPointer) return false; // ????
if (mb.IsDefined(typeof(BlackListAttribute), false) || mb.IsDefined(typeof(ObsoleteAttribute), false)) return true;
return BlackList.Contains(mb);
}
if (mb is MethodInfo && (mb as MethodInfo).ReturnType.IsPointer) return true;