[llvm-commits] CVS: llvm/lib/AsmParser/llvmAsmParser.y

Chris Lattner lattner at cs.uiuc.edu
Fri May 6 12:50:08 PDT 2005



Changes in directory llvm/lib/AsmParser:

llvmAsmParser.y updated: 1.220 -> 1.221
---
Log message:

remove some ugly hacks that are no longer needed since andrew removed the
varargs munging code


---
Diffs of the changes:  (+6 -14)

 llvmAsmParser.y |   20 ++++++--------------
 1 files changed, 6 insertions(+), 14 deletions(-)


Index: llvm/lib/AsmParser/llvmAsmParser.y
diff -u llvm/lib/AsmParser/llvmAsmParser.y:1.220 llvm/lib/AsmParser/llvmAsmParser.y:1.221
--- llvm/lib/AsmParser/llvmAsmParser.y:1.220	Fri May  6 00:51:46 2005
+++ llvm/lib/AsmParser/llvmAsmParser.y	Fri May  6 14:49:51 2005
@@ -46,14 +46,6 @@
 
 #define YYERROR_VERBOSE 1
 
-// HACK ALERT: This variable is used to implement the automatic conversion of
-// variable argument instructions from their old to new forms.  When this
-// compatiblity "Feature" is removed, this should be too.
-//
-static BasicBlock *CurBB;
-static bool ObsoleteVarArgs;
-
-
 // This contains info used when building the body of a function.  It is
 // destroyed when the function is completed.
 //
@@ -1706,22 +1698,22 @@
     $$ = $1;
   }
   | /* empty */ {
-    $$ = CurBB = getBBVal(ValID::create((int)CurFun.NextBBNum++), true);
+    $$ = getBBVal(ValID::create((int)CurFun.NextBBNum++), true);
 
     // Make sure to move the basic block to the correct location in the
     // function, instead of leaving it inserted wherever it was first
     // referenced.
-    CurFun.CurrentFunction->getBasicBlockList().remove(CurBB);
-    CurFun.CurrentFunction->getBasicBlockList().push_back(CurBB);
+    CurFun.CurrentFunction->getBasicBlockList().remove($$);
+    CurFun.CurrentFunction->getBasicBlockList().push_back($$);
   }
   | LABELSTR {
-    $$ = CurBB = getBBVal(ValID::create($1), true);
+    $$ = getBBVal(ValID::create($1), true);
 
     // Make sure to move the basic block to the correct location in the
     // function, instead of leaving it inserted wherever it was first
     // referenced.
-    CurFun.CurrentFunction->getBasicBlockList().remove(CurBB);
-    CurFun.CurrentFunction->getBasicBlockList().push_back(CurBB);
+    CurFun.CurrentFunction->getBasicBlockList().remove($$);
+    CurFun.CurrentFunction->getBasicBlockList().push_back($$);
   };
 
 BBTerminatorInst : RET ResolvedVal {              // Return with a result...






More information about the llvm-commits mailing list