https://github.com/marcauberer created 
https://github.com/llvm/llvm-project/pull/126372

Fixes #126362

>From 3a8b503f851a7b0b610797e5eaad4bd27397cb70 Mon Sep 17 00:00:00 2001
From: Marc Auberer <marc.aube...@chillibits.com>
Date: Sat, 8 Feb 2025 16:04:21 +0100
Subject: [PATCH] [clang][docs] Fix example in likely/unlikely attr
 documentation

---
 clang/include/clang/Basic/AttrDocs.td | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/clang/include/clang/Basic/AttrDocs.td 
b/clang/include/clang/Basic/AttrDocs.td
index 0ad4c958d098303..2a0354a3222eba8 100644
--- a/clang/include/clang/Basic/AttrDocs.td
+++ b/clang/include/clang/Basic/AttrDocs.td
@@ -2450,9 +2450,9 @@ path of execution, but that can be confusing:
 
 .. code-block:: c++
 
-  if (b) {
-    [[unlikely]] --b; // In the path of execution,
-                      // this branch is considered unlikely.
+  if (b) [[unlikely]] {
+    --b; // In the path of execution,
+         // this branch is considered unlikely.
   }
 
   if (b) {

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to