[llvm-commits] Fwd: [patch] set AssemblerDialect

Jun Koi junkoi2004 at gmail.com
Mon Oct 1 20:41:41 PDT 2012


---------- Forwarded message ----------
From: Jun Koi <junkoi2004 at gmail.com>
Date: Tue, Oct 2, 2012 at 11:33 AM
Subject: [patch] set AssemblerDialect
To: llvmdev at cs.uiuc.edu


currently, there is no (easy) way to set the AssemblerDialect. the
only method i am aware of is to set that via cl:opt.

this patch fixes that by adding a public function
setAssemblerDialect() to class MCAsmInfo.

Signed-off-by: Jun Koi <junkoi2004 at gmail.com>


diff --git a/include/llvm/MC/MCAsmInfo.h b/include/llvm/MC/MCAsmInfo.h
index 97aad71..cd08a7e 100644
--- a/include/llvm/MC/MCAsmInfo.h
+++ b/include/llvm/MC/MCAsmInfo.h
@@ -453,6 +453,9 @@ namespace llvm {
     unsigned getAssemblerDialect() const {
       return AssemblerDialect;
     }
+    void setAssemblerDialect(unsigned dialect) {
+      AssemblerDialect = dialect;
+    }
     bool doesAllowQuotesInName() const {
       return AllowQuotesInName;
     }



More information about the llvm-commits mailing list