Store inline asm code in the AST.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@44255 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/AST/StmtPrinter.cpp b/AST/StmtPrinter.cpp
index fa3eb84..306bfcb 100644
--- a/AST/StmtPrinter.cpp
+++ b/AST/StmtPrinter.cpp
@@ -326,7 +326,9 @@
 
 
 void StmtPrinter::VisitAsmStmt(AsmStmt *Node) {
-  Indent() << "asm (/*todo*/);\n";
+  Indent() << "asm (";
+  VisitStringLiteral(Node->getAsmString());
+  OS << ");\n";
 }
 
 void StmtPrinter::VisitObjcAtTryStmt(ObjcAtTryStmt *Node) {
diff --git a/AST/StmtSerialization.cpp b/AST/StmtSerialization.cpp
index 24733eb..f2c7834 100644
--- a/AST/StmtSerialization.cpp
+++ b/AST/StmtSerialization.cpp
@@ -197,14 +197,16 @@
 
 void AsmStmt::EmitImpl(Serializer& S) const {
   S.Emit(AsmLoc);
+  getAsmString()->EmitImpl(S);
   S.Emit(RParenLoc);  
 }
 
 AsmStmt* AsmStmt::CreateImpl(Deserializer& D) {
   SourceLocation ALoc = SourceLocation::ReadVal(D);
+  StringLiteral *AsmStr = StringLiteral::CreateImpl(D);
   SourceLocation PLoc = SourceLocation::ReadVal(D);
   
-  return new AsmStmt(ALoc,PLoc);  
+  return new AsmStmt(ALoc, AsmStr, PLoc);  
 }
 
 void BinaryOperator::EmitImpl(Serializer& S) const {