Use StringMap instead of std::map<std::string, SDNode*>.
[oota-llvm.git] / include / llvm / BasicBlock.h
index b569a7aeaf0c42506c98c6ed76ba224267825a89..108f43a7675eef58ad684060526a851ce9c1a2fa 100644 (file)
@@ -7,8 +7,8 @@
 //
 //===----------------------------------------------------------------------===//
 //
-//
 // This file contains the declaration of the BasicBlock class.
+//
 //===----------------------------------------------------------------------===//
 
 #ifndef LLVM_BASICBLOCK_H
@@ -16,7 +16,7 @@
 
 #include "llvm/Instruction.h"
 #include "llvm/SymbolTableListTraits.h"
-#include "llvm/ADT/ilist"
+#include "llvm/ADT/ilist.h"
 #include "llvm/Support/DataTypes.h"
 
 namespace llvm {
@@ -106,6 +106,9 @@ public:
   /// the first instruction, which might be PHI.
   /// Returns 0 is there's no non-PHI instruction.
   Instruction* getFirstNonPHI();
+  const Instruction* getFirstNonPHI() const {
+    return const_cast<BasicBlock*>(this)->getFirstNonPHI();
+  }
   
   /// removeFromParent - This method unlinks 'this' from the containing
   /// function, but does not delete it.