aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/Sema/SemaStmtAsm.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Sema/SemaStmtAsm.cpp b/lib/Sema/SemaStmtAsm.cpp
index 922777e07d..792a91332e 100644
--- a/lib/Sema/SemaStmtAsm.cpp
+++ b/lib/Sema/SemaStmtAsm.cpp
@@ -567,7 +567,7 @@ StmtResult Sema::ActOnMSAsmStmt(SourceLocation AsmLoc, SourceLocation LBraceLoc,
if (HadError) { DEF_SIMPLE_MSASM(EmptyAsmStr); return Owned(NS); }
// Get the instruction descriptor.
- llvm::MCInst Inst = Instrs[0];
+ llvm::MCInst Inst = Instrs.back();
const llvm::MCInstrInfo *MII = TheTarget->createMCInstrInfo();
const llvm::MCInstrDesc &Desc = MII->get(Inst.getOpcode());
llvm::MCInstPrinter *IP =