We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b65d71b commit a5b9e86Copy full SHA for a5b9e86
lib/IRGen/IRGenSIL.cpp
@@ -3215,7 +3215,7 @@ static void emitReturnInst(IRGenSILFunction &IGF,
3215
assert(!IGF.IndirectReturn.isValid() &&
3216
"Formally direct results should stay direct results for async "
3217
"functions");
3218
- llvm::Value *context = IGF.CurFn->getArg(2);
+ llvm::Value *context = IGF.getAsyncContext();
3219
auto layout = getAsyncContextLayout(IGF);
3220
3221
Address dataAddr = layout.emitCastTo(IGF, context);
0 commit comments