Implement arity reabstraction for closures

This commit is contained in:
John McCall
2023-03-21 17:38:46 -04:00
parent 3fe46464c7
commit 5cf05f501b
6 changed files with 494 additions and 321 deletions

View File

@@ -687,7 +687,7 @@ void SILGenFunction::emitClosure(AbstractClosureExpr *ace) {
SILDeclRef(ace));
emitProlog(captureInfo, ace->getParameters(), /*selfParam=*/nullptr,
ace, resultIfaceTy, ace->isBodyThrowing(), ace->getLoc(),
SGM.M.Types.getConstantAbstractionPattern(SILDeclRef(ace)));
OrigFnType);
prepareEpilog(resultIfaceTy, ace->isBodyThrowing(), CleanupLocation(ace));
emitProfilerIncrement(ace);