diff mbox series

[committed] libstdc++: Add parentheses around operand of |

Message ID 20241111185927.1252783-1-jwakely@redhat.com
State New
Headers show
Series [committed] libstdc++: Add parentheses around operand of | | expand

Commit Message

Jonathan Wakely Nov. 11, 2024, 6:59 p.m. UTC
libstdc++-v3/ChangeLog:

	* include/bits/unicode.h (_Utf_iterator::_M_read_utf16): Add
	parentheses.
---
Tested x86_64-linux. Pushed to trunk. Will backport to gcc-14 too.

 libstdc++-v3/include/bits/unicode.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/libstdc++-v3/include/bits/unicode.h b/libstdc++-v3/include/bits/unicode.h
index d79824c3ddb..24b1ac3d53d 100644
--- a/libstdc++-v3/include/bits/unicode.h
+++ b/libstdc++-v3/include/bits/unicode.h
@@ -377,7 +377,7 @@  namespace __unicode
 	      {
 		++_M_curr();
 		__to_incr = 2;
-		uint32_t __x = (__u & 0x3F) << 10 | __u2 & 0x3FF;
+		uint32_t __x = (__u & 0x3F) << 10 | (__u2 & 0x3FF);
 		uint32_t __w = (__u >> 6) & 0x1F;
 		__c = (__w + 1) << 16 | __x;
 	      }