https://github.com/egorzhdan created https://github.com/llvm/llvm-project/pull/182557
`Tags` can be nested under other `Tags`, which represents nested C++ classes. `Methods` can be nested under `Tags`, which represents C++ methods. rdar://151033780 >From d02f8e6e2ebd418bab27070afc91dd5be692f616 Mon Sep 17 00:00:00 2001 From: Egor Zhdan <[email protected]> Date: Fri, 20 Feb 2026 18:01:20 +0000 Subject: [PATCH] [APINotes] Document that Methods can now be nested under Tags `Tags` can be nested under other `Tags`, which represents nested C++ classes. `Methods` can be nested under `Tags`, which represents C++ methods. rdar://151033780 --- clang/docs/APINotes.rst | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/clang/docs/APINotes.rst b/clang/docs/APINotes.rst index 0018e4c883542..8a1018011d023 100644 --- a/clang/docs/APINotes.rst +++ b/clang/docs/APINotes.rst @@ -141,6 +141,47 @@ Each entry under 'Classes' and 'Protocols' can contain "Methods" and PropertyKind: Instance … +Each entry under "Tags" can contain "Methods", "Fields", and nested "Tags" +arrays. Methods under Tags are C++ methods identified by 'Name' (rather than +'Selector' and 'MethodKind' as used for Objective-C methods). + +:Methods (under Tags): + + Identified by 'Name'. + + :: + + Tags: + - Name: MyClass + Methods: + - Name: doSomething + … + +:Fields: + + Identified by 'Name'. + + :: + + Tags: + - Name: MyStruct + Fields: + - Name: value + Nullability: O + … + +:Tags (nested): + + Nested tags follow the same schema as top-level Tags entries. + + :: + + Tags: + - Name: OuterClass + Tags: + - Name: InnerClass + … + Each declaration supports the following annotations (if relevant to that declaration kind), all of which are optional: _______________________________________________ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
