[clang] [BoundsSafety][NFC] Add the count-refill logic for late-parsed bounds attributes (PR #224556)

Yeoul Na via cfe-commits cfe-commits at lists.llvm.org
Tue Sep 29 12:47:13 PDT 2026


================
@@ -2538,6 +2538,28 @@ class Sema final : public SemaBase {
   bool CheckCountedByAttrOnField(FieldDecl *FD, Expr *E, bool CountInBytes,
                                  bool OrNull);
 
+  /// Late-parsed bounds types dropped while their declarator was built. The
+  /// attribute has already been diagnosed and its node is no longer part of
+  /// any type, so the completion pass must skip it rather than parse its
+  /// argument and complete it.
+  llvm::SmallPtrSet<const BoundsAttributedType *, 4>
----------------
rapidsna wrote:

I just fixed it to `llvm::SmallPtrSet<const BoundsAttributedType *, 1>`.

https://github.com/llvm/llvm-project/pull/224556


More information about the cfe-commits mailing list