[all-commits] [llvm/llvm-project] 196554: Comment parsing: Complete list of Doxygen commands

Aaron Puchert via All-commits all-commits at lists.llvm.org
Tue Nov 9 09:39:24 PST 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 196554d42d329e45363afe2293d1fc19de75673d
      https://github.com/llvm/llvm-project/commit/196554d42d329e45363afe2293d1fc19de75673d
  Author: Aaron Puchert <aaron.puchert at sap.com>
  Date:   2021-11-09 (Tue, 09 Nov 2021)

  Changed paths:
    M clang/include/clang/AST/CommentCommands.td
    M clang/lib/AST/CommentLexer.cpp
    M clang/test/AST/ast-dump-comment.cpp
    M clang/test/Index/comment-lots-of-unknown-commands.c
    M clang/unittests/AST/CommentLexer.cpp
    M clang/utils/TableGen/ClangCommentCommandInfoEmitter.cpp

  Log Message:
  -----------
  Comment parsing: Complete list of Doxygen commands

These should be all the commands from [1] except those that are marked
obsolete, and "link" / "endlink", as that conflicts with the existing
HeaderDoc pair "link / "/link". For some commands we don't have the
ideal category, but it should work good enough for most cases.

There seems to be no existing test for most commands (except the ones
interpreted by -Wdocumentation), and to some extent such a test wouldn't
look very interesting. But I added a test for the correct parsing of
formulas, as they're a bit special. And I had to adapt
comment-lots-of-unknown-commands.c because typo correction was kicking
in and recognizing some of the commands.

This should fix a couple of reported bugs: PR17437, PR19581, PR24062
(partially, no diagnostic for matching cond/endcond), PR32909, PR37813,
PR44243 (partially, email at domain.com must be addressed separately).

[1] https://www.doxygen.nl/manual/commands.html

Reviewed By: gribozavr2

Differential Revision: https://reviews.llvm.org/D111190




More information about the All-commits mailing list