From 821a8ee15c40c7d7c6cf0db958cf81326f51aa25 Mon Sep 17 00:00:00 2001 From: Jonathan Wakely Date: Fri, 31 Oct 2025 12:05:49 +0000 Subject: [PATCH] [meta.define.static] qualify names from namespace meta Within library wording we don't do ADL, only unqualified lookup (as per [contents] p3). This means that all the metafunctions in namespace std need to qualify names from namespace std::meta in order to find them. This also fixes the bug that name lookup in the Effects: of define_static_array would find std::extent and not perform ADL to find std::meta::extent, even if ADL was performed here. --- source/meta.tex | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/source/meta.tex b/source/meta.tex index 932ce591c3..cc8e785672 100644 --- a/source/meta.tex +++ b/source/meta.tex @@ -3391,7 +3391,7 @@ \effects Equivalent to: \begin{codeblock} -return extract*>(meta::reflect_constant_string(r)); +return meta::extract*>(meta::reflect_constant_string(r)); \end{codeblock} \end{itemdescr} @@ -3408,8 +3408,8 @@ \begin{codeblock} using T = ranges::range_value_t; meta::info array = meta::reflect_constant_array(r); -if (is_array_type(type_of(array))) { - return span(extract(array), extent(type_of(array))); +if (meta::is_array_type(meta::type_of(array))) { + return span(meta::extract(array), meta::extent(meta::type_of(array))); } else { return span(); } @@ -3428,8 +3428,8 @@ Equivalent to: \begin{codeblock} using U = remove_cvref_t; -if constexpr (is_class_type(^^U)) { - return addressof(extract(meta::reflect_constant(std::forward(t)))); +if constexpr (meta::is_class_type(^^U)) { + return addressof(meta::extract(meta::reflect_constant(std::forward(t)))); } else { return define_static_array(span(addressof(t), 1)).data(); }