From eb39ee7f0828fbe08f435d8b4426d8a29e13675a Mon Sep 17 00:00:00 2001 From: Gabor Horvath Date: Thu, 21 Nov 2024 14:03:18 +0000 Subject: [PATCH] [clang] Fix lifetimebound APINotes tests The APINotes implementation upstream and downstream are not exactly the same, this PR makes sure the lifetimebound type attribute for 'this' object is deduplicated, and updates the test to respect versioned attributes. rdar://140295698 --- clang/test/APINotes/lifetimebound.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/clang/test/APINotes/lifetimebound.cpp b/clang/test/APINotes/lifetimebound.cpp index f6fdb8535b181..6a2d439eb56ba 100644 --- a/clang/test/APINotes/lifetimebound.cpp +++ b/clang/test/APINotes/lifetimebound.cpp @@ -11,6 +11,8 @@ // CHECK-METHOD: CXXMethodDecl {{.+}} methodToAnnotate // CHECK-METHOD-NEXT: ParmVarDecl {{.+}} p +// CHECK-METHOD-NEXT: SwiftVersionedAdditionAttr +// CHECK-METHOD-NEXT: LifetimeBoundAttr // CHECK-METHOD-NEXT: LifetimeBoundAttr // CHECK-METHOD-THIS: CXXMethodDecl {{.+}} annotateThis 'int *() {{\[\[}}clang::lifetimebound{{\]\]}}'