Skip to content

Commit 76046ba

Browse files
committed
[ConstraintSystem] Key path subscript index cannot be inferred as inout
Subscripts do not support inout parameters.
1 parent f6254f7 commit 76046ba

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/Sema/ConstraintSystem.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3688,7 +3688,7 @@ void ConstraintSystem::resolveOverload(ConstraintLocator *locator,
36883688
// the mutability of the base.
36893689
auto keyPathIndexTy = createTypeVariable(
36903690
getConstraintLocator(locator, ConstraintLocator::KeyPathSubscriptIndex),
3691-
TVO_CanBindToInOut);
3691+
/*options=*/0);
36923692
auto elementTy = createTypeVariable(
36933693
getConstraintLocator(locator, ConstraintLocator::FunctionArgument),
36943694
TVO_CanBindToLValue | TVO_CanBindToNoEscape);

0 commit comments

Comments
 (0)