13#ifndef LLVM_TABLEGEN_CODEGENHELPERS_H
14#define LLVM_TABLEGEN_CODEGENHELPERS_H
27 OS <<
"#ifdef " << Name <<
"\n"
28 <<
"#undef " << Name <<
"\n\n";
41 : Name(Name.str()), OS(OS) {
42 OS <<
"#ifndef " << Name <<
"\n"
43 <<
"#define " << Name <<
"\n\n";
58 : Name(trim(NameUntrimmed).str()), OS(OS) {
60 OS <<
"namespace " << Name <<
" {\n";
67 if (!Closed && !Name.empty())
68 OS <<
"} // namespace " << Name <<
"\n";
81 Name.consume_front(
"::");
IfDefEmitter(raw_ostream &OS, StringRef Name)
IncludeGuardEmitter(raw_ostream &OS, StringRef Name)
NamespaceEmitter(raw_ostream &OS, StringRef NameUntrimmed)
StringRef - Represent a constant reference to a string, i.e.
This class implements an extremely fast bulk output stream that can only output to a stream.
This is an optimization pass for GlobalISel generic memory operations.