[libclang][ObjC] Inherit availability attribute from containing decls or
authorAkira Hatanaka <ahatanaka@apple.com>
Mon, 11 Jul 2022 17:01:23 +0000 (10:01 -0700)
committerAkira Hatanaka <ahatanaka@apple.com>
Tue, 19 Jul 2022 16:17:39 +0000 (09:17 -0700)
commita62868aaeaac1c6464a3acbc90209458e4594338
tree689b5da89456501af8036071d3efeb90c73a52fc
parente45ef5ebf4402e553c9a0b10e8765811cc33bbdd
[libclang][ObjC] Inherit availability attribute from containing decls or
interface decls

This patch teaches getCursorPlatformAvailabilityForDecl to look for
availability attributes on the containing decls or interface decls if
the current decl doesn't have any availability attributes.

Differential Revision: https://reviews.llvm.org/D129504
clang/test/Index/availability.mm [new file with mode: 0644]
clang/tools/libclang/CIndex.cpp