Fix a missing space after the return type in invoke statements.
authorDan Gohman <gohman@apple.com>
Wed, 15 Oct 2008 18:02:08 +0000 (18:02 +0000)
committerDan Gohman <gohman@apple.com>
Wed, 15 Oct 2008 18:02:08 +0000 (18:02 +0000)
This fixes PR2894.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@57589 91177308-0d34-0410-b5e6-96231b3b80d8

lib/VMCore/AsmWriter.cpp

index 0080d63b63a0ce43d9e5403265f93204b21dd98e..273fe3043aeb4210dfa644794b756252d6bc2bc8 100644 (file)
@@ -1621,16 +1621,16 @@ void AssemblyWriter::printInstruction(const Instruction &I) {
     // only do this if the first argument is a pointer to a nonvararg function,
     // and if the return type is not a pointer to a function.
     //
+    Out << ' ';
     if (!FTy->isVarArg() &&
         (!isa<PointerType>(RetTy) ||
          !isa<FunctionType>(cast<PointerType>(RetTy)->getElementType()))) {
-      Out << ' '; printType(RetTy);
+      printType(RetTy);
+      Out << ' ';
       writeOperand(Operand, false);
     } else {
-      Out << ' ';
       writeOperand(Operand, true);
     }
-
     Out << '(';
     for (unsigned op = 3, Eop = I.getNumOperands(); op < Eop; ++op) {
       if (op > 3)