File tree Expand file tree Collapse file tree 2 files changed +12
-1
lines changed
validation-test/Sema/type_checker_crashers_fixed Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -3150,6 +3150,17 @@ static void eraseOpenedExistentials(Expr *&expr) {
3150
3150
" didn't see this OVE in a containing OpenExistentialExpr?" );
3151
3151
return { true , value->second };
3152
3152
}
3153
+
3154
+ // Handle collection upcasts specially so that we don't blow up on
3155
+ // their embedded OVEs.
3156
+ if (auto CDE = dyn_cast<CollectionUpcastConversionExpr>(expr)) {
3157
+ if (auto result = CDE->getSubExpr ()->walk (*this )) {
3158
+ CDE->setSubExpr (result);
3159
+ return { false , CDE };
3160
+ } else {
3161
+ return { true , CDE };
3162
+ }
3163
+ }
3153
3164
3154
3165
return { true , expr };
3155
3166
}
Original file line number Diff line number Diff line change 1
- // RUN: not --crash %target-swift-frontend %s -parse
1
+ // RUN: not %target-swift-frontend %s -parse
2
2
3
3
class C { }
4
4
class D : C { }
You can’t perform that action at this time.
0 commit comments