File tree Expand file tree Collapse file tree 2 files changed +12
-4
lines changed
Expand file tree Collapse file tree 2 files changed +12
-4
lines changed Original file line number Diff line number Diff line change 647647
648648 // \ref {meta.const.eval }, constant evaluation context
649649 constexpr bool is_constant_evaluated() noexcept;
650- consteval bool is_within_lifetime(const auto*) noexcept;
650+ template<class U=void, class T>
651+ consteval bool is_within_lifetime(const T*) noexcept;
651652}
652653\end {codeblock }
653654
28442845
28452846\indexlibraryglobal {is_within_lifetime}%
28462847\begin {itemdecl }
2847- consteval bool is_within_lifetime(const auto* p) noexcept;
2848+ template<class U=void, class T>
2849+ consteval bool is_within_lifetime(const T* p) noexcept;
28482850\end {itemdecl }
28492851
28502852\begin {itemdescr }
2853+ \pnum
2854+ \mandates
2855+ \tcode {static_cast<const volatile U*>(p)} is well-formed.
2856+
28512857\pnum
28522858\returns
28532859\tcode {true} if \tcode {p} is a pointer to an object that is
2854- within its lifetime\iref {basic.life }; otherwise, \tcode {false}.
2860+ within its lifetime\iref {basic.life } and
2861+ \tcode {static_cast<const volatile U*>(p)} is a constant subexpression;
2862+ otherwise, \tcode {false}.
28552863
28562864\pnum
28572865\remarks
Original file line number Diff line number Diff line change 749749#define @\defnlibxname {cpp_lib_is_sufficiently_aligned}@ 202411L // freestanding, also in \libheader {memory}
750750#define @\defnlibxname {cpp_lib_is_swappable}@ 201603L // freestanding, also in \libheader {type_traits}
751751#define @\defnlibxname {cpp_lib_is_virtual_base_of}@ 202406L // freestanding, also in \libheader {type_traits}
752- #define @\defnlibxname {cpp_lib_is_within_lifetime}@ 202306L // freestanding, also in \libheader {type_traits}
752+ #define @\defnlibxname {cpp_lib_is_within_lifetime}@ 202603L // freestanding, also in \libheader {type_traits}
753753#define @\defnlibxname {cpp_lib_jthread}@ 201911L // also in \libheader {stop_token}, \libheader {thread}
754754#define @\defnlibxname {cpp_lib_latch}@ 201907L // also in \libheader {latch}
755755#define @\defnlibxname {cpp_lib_launder}@ 201606L // freestanding, also in \libheader {new}
You can’t perform that action at this time.
0 commit comments