Author: Chris Bieneman Date: 2022-07-27T21:36:43-05:00 New Revision: 76e951e80307d26da260a73d8209417d9bb5e9f9
URL: https://github.com/llvm/llvm-project/commit/76e951e80307d26da260a73d8209417d9bb5e9f9 DIFF: https://github.com/llvm/llvm-project/commit/76e951e80307d26da260a73d8209417d9bb5e9f9.diff LOG: [Docs] Fix column ordering on clang attribute docs This patch just adjusts the ordering of the headings on the attribute docs to match the order of the column content. Added: Modified: clang/utils/TableGen/ClangAttrEmitter.cpp Removed: ################################################################################ diff --git a/clang/utils/TableGen/ClangAttrEmitter.cpp b/clang/utils/TableGen/ClangAttrEmitter.cpp index 9d1ec9bd9d869..e5ab1129d1790 100644 --- a/clang/utils/TableGen/ClangAttrEmitter.cpp +++ b/clang/utils/TableGen/ClangAttrEmitter.cpp @@ -4633,10 +4633,12 @@ static void WriteDocumentation(RecordKeeper &Records, OS << Doc.Heading << "\n" << std::string(Doc.Heading.length(), '-') << "\n"; // List what spelling syntaxes the attribute supports. + // Note: "#pragma clang attribute" is handled outside the spelling kinds loop + // so it must be last. OS << ".. csv-table:: Supported Syntaxes\n"; OS << " :header: \"GNU\", \"C++11\", \"C2x\", \"``__declspec``\","; - OS << " \"Keyword\", \"``#pragma``\", \"``#pragma clang attribute``\","; - OS << " \"HLSL Semantic\"\n\n \""; + OS << " \"Keyword\", \"``#pragma``\", \"HLSL Semantic\", \"``#pragma clang "; + OS << "attribute``\"\n\n \""; for (size_t Kind = 0; Kind != NumSpellingKinds; ++Kind) { SpellingKind K = (SpellingKind)Kind; // TODO: List Microsoft (IDL-style attribute) spellings once we fully _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits