MC: Give target specific parsers access to the MCStreamer.
authorDaniel Dunbar <daniel@zuster.org>
Thu, 10 Sep 2009 00:59:15 +0000 (00:59 +0000)
committerDaniel Dunbar <daniel@zuster.org>
Thu, 10 Sep 2009 00:59:15 +0000 (00:59 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81416 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/MC/MCAsmParser.h
tools/llvm-mc/AsmParser.h

index 8c1b7b8863361a9f309fe0b22f97ef5e84eca73b..c1b5d133cdea94b1e12670e5a25d288697cbca34 100644 (file)
@@ -16,6 +16,7 @@ namespace llvm {
 class MCAsmLexer;
 class MCContext;
 class MCExpr;
+class MCStreamer;
 class MCValue;
 class SMLoc;
 class Twine;
@@ -35,6 +36,9 @@ public:
 
   virtual MCContext &getContext() = 0;
 
+  /// getSteamer - Return the output streamer for the assembler.
+  virtual MCStreamer &getStreamer() = 0;
+
   /// Warning - Emit a warning at the location \arg L, with the message \arg
   /// Msg.
   virtual void Warning(SMLoc L, const Twine &Msg) = 0;
index 7f038c90ff0794e2a6bbe6003f092d97be2736fd..919d959d08d0b17b41186ad5ce5c7dd92993c12c 100644 (file)
@@ -67,6 +67,8 @@ public:
 
   virtual MCContext &getContext() { return Ctx; }
 
+  virtual MCStreamer &getStreamer() { return Out; }
+
   virtual void Warning(SMLoc L, const Twine &Meg);
 
   virtual bool Error(SMLoc L, const Twine &Msg);