Comment AST: Declare function pointer variables as functions
authorAaron Puchert <aaron.puchert@sap.com>
Tue, 9 Nov 2021 20:51:38 +0000 (21:51 +0100)
committerAaron Puchert <aaron.puchert@sap.com>
Tue, 9 Nov 2021 21:30:08 +0000 (22:30 +0100)
commit4d6382430066465774f6f696ea3f4c402da1d705
tree9c58abcd23e62f21eb17b4927e22549e868dbfd6
parent3506e42ab67eef41a1f27e180e7c552a2ffff7bb
Comment AST: Declare function pointer variables as functions

We were doing this already for type aliases, and it deduplicates the
code looking through aliases and pointers to find a function type. As
a side effect, this finds two warnings that we apparently missed before.

Reviewed By: gribozavr2

Differential Revision: https://reviews.llvm.org/D111264
clang/include/clang/AST/Comment.h
clang/include/clang/AST/CommentSema.h
clang/lib/AST/Comment.cpp
clang/lib/AST/CommentSema.cpp
clang/test/Sema/warn-documentation.cpp
clang/test/Sema/warn-documentation.m