[llvm-commits] CVS: llvm/lib/AsmParser/llvmAsmParser.y
Andrew Lenharth
alenhar2 at cs.uiuc.edu
Mon Jun 20 08:41:49 PDT 2005
Changes in directory llvm/lib/AsmParser:
llvmAsmParser.y updated: 1.228 -> 1.229
---
Log message:
because some functions just use va_start and pass things to vfprintf
---
Diffs of the changes: (+11 -0)
llvmAsmParser.y | 11 +++++++++++
1 files changed, 11 insertions(+)
Index: llvm/lib/AsmParser/llvmAsmParser.y
diff -u llvm/lib/AsmParser/llvmAsmParser.y:1.228 llvm/lib/AsmParser/llvmAsmParser.y:1.229
--- llvm/lib/AsmParser/llvmAsmParser.y:1.228 Sun Jun 19 09:04:55 2005
+++ llvm/lib/AsmParser/llvmAsmParser.y Mon Jun 20 10:41:37 2005
@@ -737,6 +737,17 @@
Module *Result = ParserResult;
ParserResult = 0;
+ //Not all functions use vaarg, so make a second check for ObsoleteVarArgs
+ {
+ Function* F;
+ if ((F = Result->getNamedFunction("llvm.va_start"))
+ && F->getFunctionType()->getNumParams() == 0)
+ ObsoleteVarArgs = true;
+ if((F = Result->getNamedFunction("llvm.va_copy"))
+ && F->getFunctionType()->getNumParams() == 1)
+ ObsoleteVarArgs = true;
+ }
+
if (ObsoleteVarArgs && NewVarArgs)
{
std::cerr << "This file is corrupt in that it uses both new and old style varargs\n";
More information about the llvm-commits
mailing list