Skip to content

Commit 3af929e

Browse files
authored
Merge pull request #8447 from gottesmm/gardening_and_camelcasing
[gardening] camelCase helper functions correctly.
2 parents 7ee7eee + 65b523a commit 3af929e

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

lib/SILOptimizer/IPO/CapturePromotion.cpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -588,7 +588,7 @@ static SILArgument *getBoxFromIndex(SILFunction *F, unsigned Index) {
588588
/// for the address of the box's contents), return true if the closure is known
589589
/// not to mutate the captured variable.
590590
static bool
591-
isNonmutatingCapture(SILArgument *BoxArg) {
591+
isNonMutatingCapture(SILArgument *BoxArg) {
592592
SmallVector<ProjectBoxInst*, 2> Projections;
593593

594594
// Conservatively do not allow any use of the box argument other than a
@@ -635,7 +635,7 @@ isNonmutatingCapture(SILArgument *BoxArg) {
635635
/// instruction which possibly mutates the contents of the box, then add it to
636636
/// the Mutations vector.
637637
static bool
638-
isNonescapingUse(Operand *O, SmallVectorImpl<SILInstruction*> &Mutations) {
638+
isNonEscapingUse(Operand *O, SmallVectorImpl<SILInstruction*> &Mutations) {
639639
auto *U = O->getUser();
640640
if (U->isTypeDependentOperand(*O))
641641
return true;
@@ -667,7 +667,7 @@ isNonescapingUse(Operand *O, SmallVectorImpl<SILInstruction*> &Mutations) {
667667
Mutations.push_back(U);
668668

669669
for (auto *UO : U->getUses())
670-
if (!isNonescapingUse(UO, Mutations))
670+
if (!isNonEscapingUse(UO, Mutations))
671671
return false;
672672
return true;
673673
}
@@ -743,7 +743,7 @@ examineAllocBoxInst(AllocBoxInst *ABI, ReachabilityInfo &RI,
743743
// Verify that this closure is known not to mutate the captured value; if
744744
// it does, then conservatively refuse to promote any captures of this
745745
// value.
746-
if (!isNonmutatingCapture(BoxArg))
746+
if (!isNonMutatingCapture(BoxArg))
747747
return false;
748748

749749
// Record the index and continue.
@@ -762,14 +762,14 @@ examineAllocBoxInst(AllocBoxInst *ABI, ReachabilityInfo &RI,
762762
}
763763

764764
for (Operand *AddrOp : Addr->getUses()) {
765-
if (!isNonescapingUse(AddrOp, Mutations))
765+
if (!isNonEscapingUse(AddrOp, Mutations))
766766
return false;
767767
}
768768
continue;
769769
}
770770
// Verify that this use does not otherwise allow the alloc_box to
771771
// escape.
772-
if (!isNonescapingUse(O, Mutations))
772+
if (!isNonEscapingUse(O, Mutations))
773773
return false;
774774
}
775775

0 commit comments

Comments
 (0)