Skip to content

Commit 9ad5598

Browse files
authored
Merge pull request #67923 from rjmccall/wip-variadic-arg-translation
NFC patches leading towards variadic tuple argument reabstraction
2 parents 7b3916e + 66ea1f1 commit 9ad5598

File tree

4 files changed

+1248
-1120
lines changed

4 files changed

+1248
-1120
lines changed

lib/SILGen/SILGenBackDeploy.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -190,14 +190,14 @@ void SILGenFunction::emitBackDeploymentThunk(SILDeclRef thunk) {
190190

191191
// Generate the thunk prolog by collecting parameters.
192192
SmallVector<ManagedValue, 4> params;
193-
SmallVector<SILArgument *, 4> indirectParams;
193+
SmallVector<ManagedValue, 4> indirectParams;
194194
collectThunkParams(loc, params, &indirectParams);
195195

196196
// Build up the list of arguments that we're going to invoke the the real
197197
// function with.
198198
SmallVector<SILValue, 8> paramsForForwarding;
199199
for (auto indirectParam : indirectParams) {
200-
paramsForForwarding.emplace_back(indirectParam);
200+
paramsForForwarding.emplace_back(indirectParam.getLValueAddress());
201201
}
202202

203203
for (auto param : params) {

lib/SILGen/SILGenFunction.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2252,7 +2252,7 @@ class LLVM_LIBRARY_VISIBILITY SILGenFunction
22522252
/// Used for emitting SILArguments of bare functions, such as thunks.
22532253
void collectThunkParams(
22542254
SILLocation loc, SmallVectorImpl<ManagedValue> &params,
2255-
SmallVectorImpl<SILArgument *> *indirectResultParams = nullptr);
2255+
SmallVectorImpl<ManagedValue> *indirectResultParams = nullptr);
22562256

22572257
/// Build the type of a function transformation thunk.
22582258
CanSILFunctionType buildThunkType(CanSILFunctionType &sourceType,

0 commit comments

Comments
 (0)