From 62cb2bc8376b03da4a2c8ebb53822946c24e97d7 Mon Sep 17 00:00:00 2001 From: Craig Topper Date: Wed, 31 Jul 2013 03:22:07 +0000 Subject: [PATCH] Increment arg_count inside the loop in printInline. Patch by Joe Matarazzo. llvm-svn: 187477 --- llvm/lib/Target/CppBackend/CPPBackend.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/llvm/lib/Target/CppBackend/CPPBackend.cpp b/llvm/lib/Target/CppBackend/CPPBackend.cpp index 3e69098edcc3..0ddcad2bbb86 100644 --- a/llvm/lib/Target/CppBackend/CPPBackend.cpp +++ b/llvm/lib/Target/CppBackend/CPPBackend.cpp @@ -1832,7 +1832,7 @@ void CppWriter::printInline(const std::string& fname, unsigned arg_count = 1; for (Function::const_arg_iterator AI = F->arg_begin(), AE = F->arg_end(); AI != AE; ++AI) { - Out << ", Value* arg_" << arg_count; + Out << ", Value* arg_" << arg_count++; } Out << ") {"; nl(Out);