From: Duncan P. N. Exon Smith Date: Sun, 11 Sep 2016 20:47:27 +0000 (+0000) Subject: ADT: Remove ilist_iterator::reset(), NFC X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=0e63013f27ce672495fd8c4569c925140cd77dcb;p=platform%2Fupstream%2Fllvm.git ADT: Remove ilist_iterator::reset(), NFC ilist_iterator::reset was unnecessary API, and wasn't any clearer (or safer) at the call site than constructing a temporary and assigning it to the iterator. llvm-svn: 281175 --- diff --git a/llvm/include/llvm/ADT/ilist_iterator.h b/llvm/include/llvm/ADT/ilist_iterator.h index 9e85518..ef532d2 100644 --- a/llvm/include/llvm/ADT/ilist_iterator.h +++ b/llvm/include/llvm/ADT/ilist_iterator.h @@ -121,8 +121,6 @@ public: return ilist_iterator(); } - void reset(pointer NP) { NodePtr = NP; } - // Accessors... reference operator*() const { assert(!NodePtr->isKnownSentinel()); diff --git a/llvm/include/llvm/IR/IRBuilder.h b/llvm/include/llvm/IR/IRBuilder.h index 93e1af6..a4c4096 100644 --- a/llvm/include/llvm/IR/IRBuilder.h +++ b/llvm/include/llvm/IR/IRBuilder.h @@ -114,7 +114,7 @@ public: /// inserted into a block. void ClearInsertionPoint() { BB = nullptr; - InsertPt.reset(nullptr); + InsertPt = BasicBlock::iterator(); } BasicBlock *GetInsertBlock() const { return BB; }