From e29d3963931e0a03100e88a23569eef6e84c4247 Mon Sep 17 00:00:00 2001 From: David Blaikie Date: Tue, 3 Mar 2015 21:17:00 +0000 Subject: [PATCH] Remove the explicit SUnitIterator::operator= as the default is just fine There doesn't seem to be any need to assert that iterator assignment is between iterators over the same node - if you want to reuse an iterator variable to iterate another node, that's perfectly acceptable. Just don't mix comparisons between iterators into disjoint sequences, as usual. llvm-svn: 231134 --- llvm/include/llvm/CodeGen/ScheduleDAG.h | 6 ------ 1 file changed, 6 deletions(-) diff --git a/llvm/include/llvm/CodeGen/ScheduleDAG.h b/llvm/include/llvm/CodeGen/ScheduleDAG.h index 80aee8c..8391314 100644 --- a/llvm/include/llvm/CodeGen/ScheduleDAG.h +++ b/llvm/include/llvm/CodeGen/ScheduleDAG.h @@ -628,12 +628,6 @@ namespace llvm { } bool operator!=(const SUnitIterator& x) const { return !operator==(x); } - const SUnitIterator &operator=(const SUnitIterator &I) { - assert(I.Node==Node && "Cannot assign iterators to two different nodes!"); - Operand = I.Operand; - return *this; - } - pointer operator*() const { return Node->Preds[Operand].getSUnit(); } -- 2.7.4