[clang] [BoundsSafety][doc] Add a missing newline in C snippet (PR #126245)

Piotr Fusik via cfe-commits cfe-commits at lists.llvm.org
Fri Feb 7 06:07:02 PST 2025


https://github.com/pfusik updated https://github.com/llvm/llvm-project/pull/126245

>From 666c1d15556579707c1ebce07ed2774fe13437ec Mon Sep 17 00:00:00 2001
From: Piotr Fusik <p.fusik at samsung.com>
Date: Fri, 7 Feb 2025 14:58:34 +0100
Subject: [PATCH 1/2] [BoundsSafety][doc] Add a missing newline in C snippet

---
 clang/docs/BoundsSafety.rst | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/clang/docs/BoundsSafety.rst b/clang/docs/BoundsSafety.rst
index e24c69d8c7855f3..f867c7ba07b48b3 100644
--- a/clang/docs/BoundsSafety.rst
+++ b/clang/docs/BoundsSafety.rst
@@ -959,7 +959,8 @@ that has the define.
    #if defined(__has_feature) && __has_feature(bounds_safety)
    #define __counted_by(T) __attribute__((__counted_by__(T)))
    // ... other bounds annotations
-   #else #define __counted_by(T) // defined as nothing
+   #else
+   #define __counted_by(T) // defined as nothing
    // ... other bounds annotations
    #endif
 
@@ -1003,4 +1004,4 @@ Try it out
 
 Your feedback on the programming model is valuable. You may want to follow the
 instruction in :doc:`BoundsSafetyAdoptionGuide` to play with ``-fbounds-safety``
-and please send your feedback to `Yeoul Na <mailto:yeoul_na at apple.com>`_.
\ No newline at end of file
+and please send your feedback to `Yeoul Na <mailto:yeoul_na at apple.com>`_.

>From 6696886dbf074e814e06e7307cc5cd247ea64145 Mon Sep 17 00:00:00 2001
From: Piotr Fusik <p.fusik at samsung.com>
Date: Fri, 7 Feb 2025 15:06:37 +0100
Subject: [PATCH 2/2] [BoundsSafety][doc] Add a missing quote

---
 clang/docs/BoundsSafety.rst | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/clang/docs/BoundsSafety.rst b/clang/docs/BoundsSafety.rst
index f867c7ba07b48b3..8635bec6e17c73a 100644
--- a/clang/docs/BoundsSafety.rst
+++ b/clang/docs/BoundsSafety.rst
@@ -988,7 +988,7 @@ and it does not guarantee other types of memory safety properties. Consequently,
 it may not prevent some of the secondary bounds safety violations caused by
 other types of safety violations such as type confusion. For instance,
 ``-fbounds-safety`` does not perform type-safety checks on conversions between
-`__single`` pointers of different pointee types (e.g., ``char *__single`` →
+``__single`` pointers of different pointee types (e.g., ``char *__single`` →
 ``void *__single`` → ``int *__single``) beyond what the foundation languages
 (C/C++) already offer.
 



More information about the cfe-commits mailing list