diff options
| author | Jim Grosbach <grosbach@apple.com> | 2011-08-15 20:53:08 +0000 |
|---|---|---|
| committer | Jim Grosbach <grosbach@apple.com> | 2011-08-15 20:53:08 +0000 |
| commit | b59abbd4fde718b07ed0f579197c0786fb82fba3 (patch) | |
| tree | 3026d904b649a6c0a0aefb5cbeea75dcf82d95a7 /llvm | |
| parent | 91386c7be498996d25b23d8ff36a65c7b31ddbd5 (diff) | |
| download | bcm5719-llvm-b59abbd4fde718b07ed0f579197c0786fb82fba3.tar.gz bcm5719-llvm-b59abbd4fde718b07ed0f579197c0786fb82fba3.zip | |
Move MatchResultTy enum into base class definition.
No need for it to be redefined as part of every derived target asm parser
class.
llvm-svn: 137649
Diffstat (limited to 'llvm')
| -rw-r--r-- | llvm/include/llvm/MC/MCTargetAsmParser.h | 10 | ||||
| -rw-r--r-- | llvm/utils/TableGen/AsmMatcherEmitter.cpp | 7 |
2 files changed, 10 insertions, 7 deletions
diff --git a/llvm/include/llvm/MC/MCTargetAsmParser.h b/llvm/include/llvm/MC/MCTargetAsmParser.h index 0166f2327d6..fcb5edcef6a 100644 --- a/llvm/include/llvm/MC/MCTargetAsmParser.h +++ b/llvm/include/llvm/MC/MCTargetAsmParser.h @@ -22,6 +22,16 @@ template <typename T> class SmallVectorImpl; /// MCTargetAsmParser - Generic interface to target specific assembly parsers. class MCTargetAsmParser : public MCAsmParserExtension { +public: + enum MatchResultTy { + Match_ConversionFail, + Match_InvalidOperand, + Match_MissingFeature, + Match_MnemonicFail, + Match_Success + }; + +private: MCTargetAsmParser(const MCTargetAsmParser &); // DO NOT IMPLEMENT void operator=(const MCTargetAsmParser &); // DO NOT IMPLEMENT protected: // Can only create subclasses. diff --git a/llvm/utils/TableGen/AsmMatcherEmitter.cpp b/llvm/utils/TableGen/AsmMatcherEmitter.cpp index d302941061d..2b00d8630bb 100644 --- a/llvm/utils/TableGen/AsmMatcherEmitter.cpp +++ b/llvm/utils/TableGen/AsmMatcherEmitter.cpp @@ -2174,13 +2174,6 @@ void AsmMatcherEmitter::run(raw_ostream &OS) { OS << " // This should be included into the middle of the declaration of\n"; OS << " // your subclasses implementation of MCTargetAsmParser.\n"; OS << " unsigned ComputeAvailableFeatures(uint64_t FeatureBits) const;\n"; - OS << " enum MatchResultTy {\n"; - OS << " Match_ConversionFail,\n"; - OS << " Match_InvalidOperand,\n"; - OS << " Match_MissingFeature,\n"; - OS << " Match_MnemonicFail,\n"; - OS << " Match_Success\n"; - OS << " };\n"; OS << " bool ConvertToMCInst(unsigned Kind, MCInst &Inst, " << "unsigned Opcode,\n" << " const SmallVectorImpl<MCParsedAsmOperand*> " |

