Landing: 34b57b2e14b8
Project / Subsystem
gcc / libstdc++
Date
2026-07-28
Author
Jonathan Wakely
Commit
34b57b2e14b87f0b1261c0252f404b38f0c1aa1b
Source
github
Perf win
No
Breaking
No
All attributes
- project
- gcc
- subsystem
- libstdc++
- patch_id
- —
- commit_hash
- 34b57b2e14b87f0b1261c0252f404b38f0c1aa1b
- source_type
- github
- headline
- libstdc++: Suppress false positive -Warray-bounds warnings in shared_ptr
- tldr
- Reduces noise from the compiler by disabling ARRAY-BOUNDS warnings in shared_ptr destructors.
- author
- Jonathan Wakely
- outcome
- committed
- performance_win
- false
- breaking_change
- false
- series_id
- —
- series_parts
- []
- tags
-
- • c++
- • libstdc++
- • warning
- discussion_id_link
- —
- bugzilla_pr
- —
- date
- 2026-07-28T00:00:00.000Z
This change disables compiler warnings related to -Warray-bounds in specific parts of the C++ standard library’s shared_ptr implementation. False positives were being triggered in the destructors and _M_dispose member functions of _Sp_counted_deleter and _Sp_counted_ptr_inplace. By suppressing these warnings, the compiler output remains cleaner and focuses on genuine programming errors, without impacting the correctness or behavior of shared_ptr.