Landing: 23b9ac257cf5

Project / Subsystem

gcc / libstdc++

Date

2026-05-26

Author

Jonathan Wakely

Commit

23b9ac257cf508bc4fa479c82fcfc768c4abcd79

Source

github

Perf win

No

Breaking

No

All attributes

project
gcc
subsystem
libstdc++
patch_id
commit_hash
23b9ac257cf508bc4fa479c82fcfc768c4abcd79
source_type
github
headline
Libstdc++: Fix <optional> for freestanding [PR125450]
tldr
The <optional> header is modified to avoid defining range_format when building in a freestanding environment.
author
Jonathan Wakely
outcome
committed
performance_win
false
breaking_change
false
series_id
series_parts
[]
tags
  • libstdc++
  • optional
  • freestanding
discussion_id_link
bugzilla_pr
date
2026-05-26T00:00:00.000Z

This commit fixes an issue in libstdc++ where the range_format functionality within the <optional> header caused problems in freestanding environments. By conditionally excluding the definition of range_format in such environments, this change ensures that <optional> can be used in environments where standard library features are limited.