From fc9e55b4391499863cd603e37adc2306734389de Mon Sep 17 00:00:00 2001 From: Tobias Grosser Date: Wed, 13 Jan 2010 22:21:43 +0000 Subject: [PATCH] Add getSource() to SuccIterator Get the source BB of an iterator. llvm-svn: 93364 --- include/llvm/Support/CFG.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/include/llvm/Support/CFG.h b/include/llvm/Support/CFG.h index 71e76f866c9..90b95bf7cfd 100644 --- a/include/llvm/Support/CFG.h +++ b/include/llvm/Support/CFG.h @@ -189,6 +189,11 @@ public: // tmp += offset; // return tmp.operator*(); // } + + /// Get the source BB of this iterator. + inline BB_ *getSource() { + return Term->getParent(); + } }; typedef SuccIterator succ_iterator;