diff gen/irstate.h @ 1145:40caa8207b3e

Moved IRTargetScopeS from IRState into IrFunction, fixes #240 .
author Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
date Thu, 26 Mar 2009 18:46:21 +0100
parents f99a3b393c03
children 3d1b16dabd25
line wrap: on
line diff
--- a/gen/irstate.h	Wed Mar 25 13:46:49 2009 +0100
+++ b/gen/irstate.h	Thu Mar 26 18:46:21 2009 +0100
@@ -36,7 +36,6 @@
 struct TypeStruct;
 struct BaseClass;
 struct AnonDeclaration;
-struct EnclosingHandler;
 
 struct IrModule;
 
@@ -51,23 +50,6 @@
     IRScope(llvm::BasicBlock* b, llvm::BasicBlock* e);
 };
 
-// scope statements that can be target of jumps
-// includes loops, switch, case, labels
-struct IRTargetScope
-{
-    // generating statement
-    Statement* s;
-    
-    // the try of a TryFinally that encloses the loop
-    EnclosingHandler* enclosinghandler;
-    
-    llvm::BasicBlock* breakTarget;
-    llvm::BasicBlock* continueTarget;
-
-    IRTargetScope();
-    IRTargetScope(Statement* s, EnclosingHandler* enclosinghandler, llvm::BasicBlock* continueTarget, llvm::BasicBlock* breakTarget);
-};
-
 struct IRBuilderHelper
 {
     IRState* state;
@@ -159,10 +141,6 @@
     llvm::CallSite CreateCallOrInvoke3(LLValue* Callee, LLValue* Arg1, LLValue* Arg2, LLValue* Arg3, const char* Name="");
     llvm::CallSite CreateCallOrInvoke4(LLValue* Callee, LLValue* Arg1, LLValue* Arg2,  LLValue* Arg3, LLValue* Arg4, const char* Name="");
 
-    // loop blocks
-    typedef std::vector<IRTargetScope> TargetScopeVec;
-    TargetScopeVec targetScopes;
-
     // this holds the array being indexed or sliced so $ will work
     // might be a better way but it works. problem is I only get a
     // VarDeclaration for __dollar, but I can't see how to get the