From c3de7208ee3ac1bec30e62d03cb383ca21708f3d Mon Sep 17 00:00:00 2001 From: Vitaly Buka Date: Mon, 24 Jun 2019 22:42:53 +0000 Subject: [PATCH] [NFC] Add missing consts into memoryaccess_def_iterator git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@364247 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/Analysis/MemorySSA.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/llvm/Analysis/MemorySSA.h b/include/llvm/Analysis/MemorySSA.h index a0a1030c5df..b7730be7535 100644 --- a/include/llvm/Analysis/MemorySSA.h +++ b/include/llvm/Analysis/MemorySSA.h @@ -1106,15 +1106,15 @@ public: assert(Access && "Tried to access past the end of our iterator"); // Go to the first argument for phis, and the defining access for everything // else. - if (MemoryPhi *MP = dyn_cast(Access)) + if (const MemoryPhi *MP = dyn_cast(Access)) return MP->getIncomingValue(ArgNo); return cast(Access)->getDefiningAccess(); } using BaseT::operator++; - memoryaccess_def_iterator &operator++() { + memoryaccess_def_iterator_base &operator++() { assert(Access && "Hit end of iterator"); - if (MemoryPhi *MP = dyn_cast(Access)) { + if (const MemoryPhi *MP = dyn_cast(Access)) { if (++ArgNo >= MP->getNumIncomingValues()) { ArgNo = 0; Access = nullptr; -- 2.11.0