Skip to content

Commit 09634d6

Browse files
committed
[ownership] Fix duplicate getOperandRef def given upstream changes that I rebased upon.
1 parent 9eb717a commit 09634d6

File tree

1 file changed

+13
-13
lines changed

1 file changed

+13
-13
lines changed

include/swift/SIL/SILInstruction.h

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -468,13 +468,6 @@ class SILInstruction
468468
/// Return the array of operands for this instruction.
469469
ArrayRef<Operand> getAllOperands() const;
470470

471-
/// Return the ith operand of this instruction.
472-
///
473-
/// Equivalent to performing getAllOperands()[index];
474-
const Operand &getOperandRef(unsigned index) const {
475-
return getAllOperands()[index];
476-
}
477-
478471
/// Return the array of type dependent operands for this instruction.
479472
///
480473
/// Type dependent operands are hidden operands, i.e. not part of the SIL
@@ -504,11 +497,6 @@ class SILInstruction
504497
/// Return the array of mutable operands for this instruction.
505498
MutableArrayRef<Operand> getAllOperands();
506499

507-
/// Return the ith mutable operand of this instruction.
508-
///
509-
/// Equivalent to performing getAllOperands()[index];
510-
Operand &getOperandRef(unsigned index) { return getAllOperands()[index]; }
511-
512500
/// Return the array of mutable type dependent operands for this instruction.
513501
MutableArrayRef<Operand> getTypeDependentOperands();
514502

@@ -553,7 +541,19 @@ class SILInstruction
553541
SILValue getOperand(unsigned Num) const {
554542
return getAllOperands()[Num].get();
555543
}
556-
Operand &getOperandRef(unsigned Num) { return getAllOperands()[Num]; }
544+
545+
/// Return the ith mutable operand of this instruction.
546+
///
547+
/// Equivalent to performing getAllOperands()[index];
548+
Operand &getOperandRef(unsigned index) { return getAllOperands()[index]; }
549+
550+
/// Return the ith operand of this instruction.
551+
///
552+
/// Equivalent to performing getAllOperands()[index];
553+
const Operand &getOperandRef(unsigned index) const {
554+
return getAllOperands()[index];
555+
}
556+
557557
void setOperand(unsigned Num, SILValue V) { getAllOperands()[Num].set(V); }
558558
void swapOperands(unsigned Num1, unsigned Num2) {
559559
getAllOperands()[Num1].swap(getAllOperands()[Num2]);

0 commit comments

Comments
 (0)