Skip to content

Commit ebdb3cf

Browse files
committed
Sema: Re-allowed coercion for existentials that have already been opened
1 parent 8ee220a commit ebdb3cf

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/Sema/CSApply.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -902,7 +902,7 @@ namespace {
902902
base, selfParamTy, member, semantics,
903903
locator.withPathElement(ConstraintLocator::MemberRefBase));
904904
} else {
905-
if (!isExistentialMetatype) {
905+
if (!isExistentialMetatype || openedExistential) {
906906
// Convert the base to an rvalue of the appropriate metatype.
907907
base = coerceToType(base,
908908
MetatypeType::get(

0 commit comments

Comments
 (0)