summaryrefslogtreecommitdiff
path: root/include/llvm/CodeGen/MachineBasicBlock.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/llvm/CodeGen/MachineBasicBlock.h')
-rw-r--r--include/llvm/CodeGen/MachineBasicBlock.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/llvm/CodeGen/MachineBasicBlock.h b/include/llvm/CodeGen/MachineBasicBlock.h
index 5a6581c21c..ad121572fc 100644
--- a/include/llvm/CodeGen/MachineBasicBlock.h
+++ b/include/llvm/CodeGen/MachineBasicBlock.h
@@ -305,6 +305,10 @@ public:
/// it returns end()
iterator getFirstTerminator();
+ const_iterator getFirstTerminator() const {
+ return const_cast<MachineBasicBlock*>(this)->getFirstTerminator();
+ }
+
/// getLastNonDebugInstr - returns an iterator to the last non-debug
/// instruction in the basic block, or end()
iterator getLastNonDebugInstr();