diff --git a/utils/TableGen/OptParserEmitter.cpp b/utils/TableGen/OptParserEmitter.cpp index 3cd5784c54e..6892912eee1 100644 --- a/utils/TableGen/OptParserEmitter.cpp +++ b/utils/TableGen/OptParserEmitter.cpp @@ -75,26 +75,10 @@ void OptParserEmitter::run(raw_ostream &OS) { Records.getAllDerivedDefinitions("OptionGroup"); std::vector Opts = Records.getAllDerivedDefinitions("Option"); - if (GenDefs) { - OS << "\ -//=== TableGen'erated File - Option Parsing Definitions ---------*- C++ -*-===//\n \ -//\n\ -// Option Parsing Definitions\n\ -//\n\ -// Automatically generated file, do not edit!\n\ -//\n\ -//===----------------------------------------------------------------------===//\n"; - } else { - OS << "\ -//=== TableGen'erated File - Option Parsing Table ---------------*- C++ -*-===//\n \ -//\n\ -// Option Parsing Definitions\n\ -//\n\ -// Automatically generated file, do not edit!\n\ -//\n\ -//===----------------------------------------------------------------------===//\n"; - } - OS << "\n"; + if (GenDefs) + EmitSourceFileHeader("Option Parsing Definitions", OS); + else + EmitSourceFileHeader("Option Parsing Table", OS); array_pod_sort(Opts.begin(), Opts.end(), CompareOptionRecords); if (GenDefs) {