libstdc++: Fix unconditional definition of __cpp_lib_span in <version> [PR 97869}
The <span> header is empty unless Concepts are supported, but <version> defines the __cpp_lib_span feature test macro unconditionally. It should be guarded by the same conditions as in <span>. libstdc++-v3/ChangeLog: PR libstdc++/97869 * include/precompiled/stdc++.h: Include <coroutine>. * include/std/version (__cpp_lib_span): Check __cpp_lib_concepts before defining.
This commit is contained in:
parent
1f8ac75991
commit
ecf65330c1
|
@ -137,6 +137,9 @@
|
|||
#include <bit>
|
||||
#include <compare>
|
||||
#include <concepts>
|
||||
#if __cpp_impl_coroutine
|
||||
# include <coroutine>
|
||||
#endif
|
||||
#include <numbers>
|
||||
#include <ranges>
|
||||
#include <span>
|
||||
|
|
|
@ -226,7 +226,9 @@
|
|||
# define __cpp_lib_ranges 201911L
|
||||
#endif
|
||||
#define __cpp_lib_shift 201806L
|
||||
#define __cpp_lib_span 202002L
|
||||
#if __cpp_lib_concepts
|
||||
# define __cpp_lib_span 202002L
|
||||
#endif
|
||||
#define __cpp_lib_ssize 201902L
|
||||
#define __cpp_lib_starts_ends_with 201711L
|
||||
# if _GLIBCXX_USE_CXX11_ABI
|
||||
|
|
Loading…
Reference in New Issue