We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
出现报错: ArgumentException: Object of type 'ILRuntime.Runtime.Intepreter.ILEnumTypeInstance' cannot be converted to type 'System.Enum'. System.RuntimeType.CheckValue (System.Object value, System.Reflection.Binder binder, System.Globalization.CultureInfo culture, System.Reflection.BindingFlags invokeAttr) (at <7ba07f088431485bb722f3b3373e87ee>:0) System.Reflection.MonoMethod.ConvertValues (System.Reflection.Binder binder, System.Object[] args, System.Reflection.ParameterInfo[] pinfo, System.Globalization.CultureInfo culture, System.Reflection.BindingFlags invokeAttr) (at <7ba07f088431485bb722f3b3373e87ee>:0) System.Reflection.MonoMethod.Invoke (System.Object obj, System.Reflection.BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at <7ba07f088431485bb722f3b3373e87ee>:0) System.Reflection.MethodBase.Invoke (System.Object obj, System.Object[] parameters) (at <7ba07f088431485bb722f3b3373e87ee>:0) ILRuntime.CLR.Method.CLRMethod.Invoke (ILRuntime.Runtime.Intepreter.ILIntepreter intepreter, ILRuntime.Runtime.Stack.StackObject* esp, System.Collections.Generic.IList`1[T] mStack, System.Boolean isNewObj) (at Assets/Scripts/Core/ILRuntime/CLR/Method/CLRMethod.cs:316) ILRuntime.Runtime.Intepreter.ILIntepreter.Execute (ILRuntime.CLR.Method.ILMethod method, ILRuntime.Runtime.Stack.StackObject* esp, System.Boolean& unhandledException) (at Assets/Scripts/Core/ILRuntime/Runtime/Intepreter/ILIntepreter.cs:1797) Rethrow as ILRuntimeException: Object of type 'ILRuntime.Runtime.Intepreter.ILEnumTypeInstance' cannot be converted to type 'System.Enum'. IL_0051: call System.Boolean System.Enum::HasFlag(System.Enum)
The text was updated successfully, but these errors were encountered:
同遇到,不过原因大致能理解 ,热更内定义的enum只是个自定义数据结构 ,对clr而言根本不知道有这么个枚举类型存在,拿它去调HasFlag这种函数,肯定会判this无效了。要么把枚举移到主工程去定义,要么自己重载HasFlag函数。
Sorry, something went wrong.
70bfd54
No branches or pull requests
出现报错:
ArgumentException: Object of type 'ILRuntime.Runtime.Intepreter.ILEnumTypeInstance' cannot be converted to type 'System.Enum'.
System.RuntimeType.CheckValue (System.Object value, System.Reflection.Binder binder, System.Globalization.CultureInfo culture, System.Reflection.BindingFlags invokeAttr) (at <7ba07f088431485bb722f3b3373e87ee>:0)
System.Reflection.MonoMethod.ConvertValues (System.Reflection.Binder binder, System.Object[] args, System.Reflection.ParameterInfo[] pinfo, System.Globalization.CultureInfo culture, System.Reflection.BindingFlags invokeAttr) (at <7ba07f088431485bb722f3b3373e87ee>:0)
System.Reflection.MonoMethod.Invoke (System.Object obj, System.Reflection.BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at <7ba07f088431485bb722f3b3373e87ee>:0)
System.Reflection.MethodBase.Invoke (System.Object obj, System.Object[] parameters) (at <7ba07f088431485bb722f3b3373e87ee>:0)
ILRuntime.CLR.Method.CLRMethod.Invoke (ILRuntime.Runtime.Intepreter.ILIntepreter intepreter, ILRuntime.Runtime.Stack.StackObject* esp, System.Collections.Generic.IList`1[T] mStack, System.Boolean isNewObj) (at Assets/Scripts/Core/ILRuntime/CLR/Method/CLRMethod.cs:316)
ILRuntime.Runtime.Intepreter.ILIntepreter.Execute (ILRuntime.CLR.Method.ILMethod method, ILRuntime.Runtime.Stack.StackObject* esp, System.Boolean& unhandledException) (at Assets/Scripts/Core/ILRuntime/Runtime/Intepreter/ILIntepreter.cs:1797)
Rethrow as ILRuntimeException: Object of type 'ILRuntime.Runtime.Intepreter.ILEnumTypeInstance' cannot be converted to type 'System.Enum'.
IL_0051: call System.Boolean System.Enum::HasFlag(System.Enum)
The text was updated successfully, but these errors were encountered: