File tree Expand file tree Collapse file tree 1 file changed +5
-8
lines changed
Expand file tree Collapse file tree 1 file changed +5
-8
lines changed Original file line number Diff line number Diff line change @@ -3381,20 +3381,17 @@ class SILVerifier : public SILVerifierBase<SILVerifier> {
33813381 CBI->getCastType (),
33823382 " success dest block argument of checked_cast_br must match type of "
33833383 " cast" );
3384- require (F.hasOwnership () || CBI->getFailureBB ()->args_empty (),
3385- " failure dest of checked_cast_br in unqualified ownership sil must "
3386- " take no arguments" );
3387- #if 0
3388- require(F.hasUnqualifiedOwnership() ||
3389- CBI->getFailureBB()->args_size() == 1,
3384+ require (!F.hasOwnership () || CBI->getFailureBB ()->args_size () == 1 ,
33903385 " failure dest of checked_cast_br must take one argument in "
33913386 " ownership qualified sil" );
3392- require(F.hasUnqualifiedOwnership () ||
3387+ require (!F. hasOwnership () ||
33933388 CBI->getFailureBB ()->args_begin ()[0 ]->getType () ==
33943389 CBI->getOperand ()->getType (),
33953390 " failure dest block argument must match type of original type in "
33963391 " ownership qualified sil" );
3397- #endif
3392+ require (F.hasOwnership () || CBI->getFailureBB ()->args_empty (),
3393+ " Failure dest of checked_cast_br must not take any argument in "
3394+ " non-ownership qualified sil" );
33983395 }
33993396
34003397 void checkCheckedCastValueBranchInst (CheckedCastValueBranchInst *CBI) {
You can’t perform that action at this time.
0 commit comments