Skip to content

Commit ae51f61

Browse files
committed
Review feedback: always use #if
1 parent ab32e3f commit ae51f61

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

llvm/include/llvm/TableGen/CodeGenHelpers.h

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,14 +47,13 @@ class IfDefEmitter {
4747
};
4848

4949
// Simple RAII helper for emitting #if guard. It emits:
50-
// <IfGuard> <Condition>
50+
// #if <Condition>
5151
// #endif // <Condition>
5252
class IfGuardEmitter {
5353
public:
54-
IfGuardEmitter(raw_ostream &OS, StringRef Condition,
55-
StringRef IfGuard = "#if")
54+
IfGuardEmitter(raw_ostream &OS, StringRef Condition)
5655
: Condition(Condition.str()), OS(OS) {
57-
OS << IfGuard << " " << Condition << "\n\n";
56+
OS << "#if " << Condition << "\n\n";
5857
}
5958

6059
~IfGuardEmitter() { OS << "\n#endif // " << Condition << "\n\n"; }

0 commit comments

Comments
 (0)