From 13f01b07c3c51138d90f1649882da4fe5384af43 Mon Sep 17 00:00:00 2001 From: Ahmed Bougacha Date: Wed, 21 Aug 2013 19:40:25 +0000 Subject: [PATCH] Style cleanup following David's review for r188876. llvm-svn: 188924 --- lib/MC/MCFunction.cpp | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/lib/MC/MCFunction.cpp b/lib/MC/MCFunction.cpp index 85e88e5852d..767e1e0f470 100644 --- a/lib/MC/MCFunction.cpp +++ b/lib/MC/MCFunction.cpp @@ -31,16 +31,15 @@ MCBasicBlock &MCFunction::createBlock(const MCTextAtom &TA) { return *MCBB; } -const MCBasicBlock *MCFunction::find(uint64_t StartAddr) const { +MCBasicBlock *MCFunction::find(uint64_t StartAddr) { for (const_iterator I = begin(), E = end(); I != E; ++I) if ((*I)->getInsts()->getBeginAddr() == StartAddr) - return (*I); + return *I; return 0; } -MCBasicBlock *MCFunction::find(uint64_t StartAddr) { - return const_cast( - const_cast(this)->find(StartAddr)); +const MCBasicBlock *MCFunction::find(uint64_t StartAddr) const { + return const_cast(this)->find(StartAddr); } // MCBasicBlock