Skip to content
New issue

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

async await 报错 #222

Closed
ismakegame opened this issue Aug 28, 2020 · 2 comments
Closed

async await 报错 #222

ismakegame opened this issue Aug 28, 2020 · 2 comments

Comments

@ismakegame
Copy link

ismakegame commented Aug 28, 2020

iOS [IFix.Patch]和 [IFix.Interpret] 都报错
Delay();
Delay2();

 [IFix.Patch]
async void Delay(){
	Debug.Log("暂停执行1秒");
	int ms=1000;
	await Task.Delay(ms);
	Debug.Log("等待完成1");
}

[IFix.Interpret]
async void Delay2(){
Debug.Log("暂停执行4秒");
int ms=2000;
await Task.Delay(ms);
Debug.Log("等待完成4");
}

ExecutionEngineException: Attempting to call method 'System.Runtime.CompilerServices.AsyncVoidMethodBuilder::AwaitUnsafeOnCompleted<System.Runtime.CompilerServices.TaskAwaiter,IFix.ILFixInterfaceBridge>' for which no ahead of time (AOT) code was generated.
at System.Reflection.MonoMethod.Invoke (System.Object obj, System.Reflection.BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00000] in <00000000000000000000000000000000>:0
at IFix.Core.ReflectionMethodInvoker.Invoke (IFix.Core.VirtualMachine virtualMachine, IFix.Core.Call& call, System.Boolean isInstantiate) [0x00000] in <00000000000000000000000000000000>:0

@chexiongsheng
Copy link
Collaborator

应该可以解决这问题。

@chexiongsheng
Copy link
Collaborator

可以通过xLua的群联系下我。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants