Skip to content

Commit ae756d0

Browse files
committed
[CS] NFC: Add a couple of parameters to createConjunction
Allow callers to customize the isolation and referenced vars.
1 parent 837ef1a commit ae756d0

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

lib/Sema/CSSyntacticElement.cpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -306,11 +306,12 @@ using ElementInfo = std::tuple<ASTNode, ContextualTypeInfo,
306306

307307
static void createConjunction(ConstraintSystem &cs,
308308
ArrayRef<ElementInfo> elements,
309-
ConstraintLocator *locator) {
310-
bool isIsolated = false;
311-
309+
ConstraintLocator *locator,
310+
bool isIsolated = false,
311+
ArrayRef<TypeVariableType *> extraTypeVars = {}) {
312312
SmallVector<Constraint *, 4> constraints;
313313
SmallVector<TypeVariableType *, 2> referencedVars;
314+
referencedVars.append(extraTypeVars.begin(), extraTypeVars.end());
314315

315316
if (locator->directlyAt<ClosureExpr>()) {
316317
auto *closure = castToExpr<ClosureExpr>(locator->getAnchor());

0 commit comments

Comments
 (0)