Changes in directory llvm/lib/CodeGen:

MachineFunction.cpp updated: 1.102 -> 1.103
---
Log message:

add an assert


---
Diffs of the changes:  (+1 -0)

 MachineFunction.cpp |    1 +
 1 files changed, 1 insertion(+)


Index: llvm/lib/CodeGen/MachineFunction.cpp
diff -u llvm/lib/CodeGen/MachineFunction.cpp:1.102 
llvm/lib/CodeGen/MachineFunction.cpp:1.103
--- llvm/lib/CodeGen/MachineFunction.cpp:1.102  Tue Oct  3 15:19:23 2006
+++ llvm/lib/CodeGen/MachineFunction.cpp        Sat Oct 28 13:11:20 2006
@@ -363,6 +363,7 @@
 ///
 unsigned MachineJumpTableInfo::getJumpTableIndex(
                                      std::vector<MachineBasicBlock*> &DestBBs) 
{
+  assert(!DestBBs.empty() && "Cannot create an empty jump table!");
   for (unsigned i = 0, e = JumpTables.size(); i != e; ++i)
     if (JumpTables[i].MBBs == DestBBs)
       return i;



_______________________________________________
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits

Reply via email to