@@ -1850,16 +1850,7 @@ visitRecursivelyLifetimeEndingUses(
1850
1850
continue ;
1851
1851
}
1852
1852
// FIXME: Handle store to indirect result
1853
-
1854
- // There shouldn't be any dead-end consumptions of a nonescaping
1855
- // partial_apply that don't forward it along, aside from destroy_value.
1856
- //
1857
- // On-stack partial_apply cannot be cloned, so it should never be used by a
1858
- // BranchInst.
1859
- //
1860
- // This is a fatal error because it performs SIL verification that is not
1861
- // separately checked in the verifier. It is the only check that verifies
1862
- // the structural requirements of on-stack partial_apply uses.
1853
+
1863
1854
auto *user = use->getUser ();
1864
1855
if (user->getNumResults () == 0 ) {
1865
1856
return visitUnknownUse (use);
@@ -1882,7 +1873,16 @@ PartialApplyInst::visitOnStackLifetimeEnds(
1882
1873
&& " only meaningful for OSSA stack closures" );
1883
1874
bool noUsers = true ;
1884
1875
1885
- auto visitUnknownUse = [](Operand *unknownUse){
1876
+ auto visitUnknownUse = [](Operand *unknownUse) {
1877
+ // There shouldn't be any dead-end consumptions of a nonescaping
1878
+ // partial_apply that don't forward it along, aside from destroy_value.
1879
+ //
1880
+ // On-stack partial_apply cannot be cloned, so it should never be used by a
1881
+ // BranchInst.
1882
+ //
1883
+ // This is a fatal error because it performs SIL verification that is not
1884
+ // separately checked in the verifier. It is the only check that verifies
1885
+ // the structural requirements of on-stack partial_apply uses.
1886
1886
llvm::errs () << " partial_apply [on_stack] use:\n " ;
1887
1887
auto *user = unknownUse->getUser ();
1888
1888
user->printInContext (llvm::errs ());
0 commit comments