Delete the BasicBlock ctor that only takes a BasicBlock to insert before. This
authorChris Lattner <sabre@nondot.org>
Wed, 4 Feb 2004 03:57:34 +0000 (03:57 +0000)
committerChris Lattner <sabre@nondot.org>
Wed, 4 Feb 2004 03:57:34 +0000 (03:57 +0000)
fails when the basic block points to the function->end.  Instead, require that
the client pass in the function AND the basicblock to insert into.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11112 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/BasicBlock.h

index 510124374263cc2552a939f8b25d5715a246bdaf..ad6cdd8fedbccccbc3bc49d0d29d47b496a73e99 100644 (file)
@@ -67,13 +67,14 @@ public:
   typedef std::reverse_iterator<iterator>             reverse_iterator;
 
   /// BasicBlock ctor - If the function parameter is specified, the basic block
-  /// is automatically inserted at the end of the function.
+  /// is automatically inserted at either the end of the function (if
+  /// InsertBefore is null), or before the specified basic block.
   ///
-  BasicBlock(const std::string &Name = "", Function *Parent = 0);
-
   /// BasicBlock ctor - If the InsertBefore parameter is specified, the basic
   /// block is automatically inserted right before the specified block.
-  BasicBlock(const std::string &Name, BasicBlock *InsertBefore);
+  ///
+  BasicBlock(const std::string &Name = "", Function *Parent = 0,
+             BasicBlock *InsertBefore = 0);
   ~BasicBlock();
 
   // Specialize setName to take care of symbol table majik