Skip to content

Commit 821a8ee

Browse files
committed
[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.
1 parent 42fad0f commit 821a8ee

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

source/meta.tex

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3391,7 +3391,7 @@
33913391
\effects
33923392
Equivalent to:
33933393
\begin{codeblock}
3394-
return extract<const ranges::range_value_t<R>*>(meta::reflect_constant_string(r));
3394+
return meta::extract<const ranges::range_value_t<R>*>(meta::reflect_constant_string(r));
33953395
\end{codeblock}
33963396
\end{itemdescr}
33973397

@@ -3408,8 +3408,8 @@
34083408
\begin{codeblock}
34093409
using T = ranges::range_value_t<R>;
34103410
meta::info array = meta::reflect_constant_array(r);
3411-
if (is_array_type(type_of(array))) {
3412-
return span<const T>(extract<const T*>(array), extent(type_of(array)));
3411+
if (meta::is_array_type(meta::type_of(array))) {
3412+
return span<const T>(meta::extract<const T*>(array), meta::extent(meta::type_of(array)));
34133413
} else {
34143414
return span<const T>();
34153415
}
@@ -3428,8 +3428,8 @@
34283428
Equivalent to:
34293429
\begin{codeblock}
34303430
using U = remove_cvref_t<T>;
3431-
if constexpr (is_class_type(^^U)) {
3432-
return addressof(extract<const U&>(meta::reflect_constant(std::forward<T>(t))));
3431+
if constexpr (meta::is_class_type(^^U)) {
3432+
return addressof(meta::extract<const U&>(meta::reflect_constant(std::forward<T>(t))));
34333433
} else {
34343434
return define_static_array(span(addressof(t), 1)).data();
34353435
}

0 commit comments

Comments
 (0)