[PATCH] D151373: [libclang] Expose arguments of clang::annotate{_type}

Fridtjof Mund via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed May 24 13:48:45 PDT 2023


fridtjof created this revision.
fridtjof added a reviewer: aaron.ballman.
Herald added a subscriber: arphaman.
Herald added a project: All.
fridtjof requested review of this revision.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.

This enables easy consumption of arbitrary data added
to these annotations in addition to the annotation category,
which was already exposed.

I mostly just copied all the bits and pieces that seemed to do similar stuff, which seems to work.

I tested this locally with a very small C++ program to try and dump arguments for clang::annotate, which works.
Adding annotate_type to my test source code does not even expose the annotation itself however (I've attached it to parameter and variable types to no success), which seems like an unrelated bug (it should work for all Decls!).


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D151373

Files:
  clang/tools/libclang/CIndex.cpp
  clang/tools/libclang/CursorVisitor.h

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D151373.525318.patch
Type: text/x-patch
Size: 5909 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20230524/781e2156/attachment.bin>


More information about the cfe-commits mailing list