19 MCAsmParser *Parser =
nullptr;
21 template <
bool (XCOFFAsmParser::*HandlerMethod)(StringRef, SMLoc)>
22 void addDirectiveHandler(StringRef Directive) {
24 std::make_pair(
this, HandleDirective<XCOFFAsmParser, HandlerMethod>);
26 getParser().addDirectiveHandler(Directive, Handler);
30 XCOFFAsmParser() =
default;
32 void Initialize(MCAsmParser &
P)
override {
37 addDirectiveHandler<&XCOFFAsmParser::ParseDirectiveCSect>(
".csect");
39 bool ParseDirectiveCSect(StringRef, SMLoc);
51 return new XCOFFAsmParser;
Generic interface for extending the MCAsmParser, which is implemented by target and object file assem...
virtual void Initialize(MCAsmParser &Parser)
Initialize the extension for parsing using the given Parser.
std::pair< MCAsmParserExtension *, DirectiveHandler > ExtensionDirectiveHandler
Represents a location in source code.
Represent a constant reference to a string, i.e.
This is an optimization pass for GlobalISel generic memory operations.
LLVM_ABI MCAsmParserExtension * createXCOFFAsmParser()
LLVM_ABI void report_fatal_error(Error Err, bool gen_crash_diag=true)