From 041dab0f2ce644be62962082e64fcd4f9b56fc0a Mon Sep 17 00:00:00 2001 From: Vlad Serebrennikov Date: Wed, 28 Oct 2026 10:48:01 +0400 Subject: [PATCH] [basic.lookup.unqual] Add an example for 2.2 with using-directives --- source/basic.tex | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/source/basic.tex b/source/basic.tex index 34f3deae72..12785c94a6 100644 --- a/source/basic.tex +++ b/source/basic.tex @@ -2028,6 +2028,23 @@ the results of the unqualified search are the results of an unqualified search in the parent scope of $S$, if any, from $P$. +\begin{example} +\begin{codeblock} +namespace A { + constexpr int i = 0; +} +namespace N { + namespace B { + constexpr int i = 1; + } + using namespace B; + namespace M { + using namespace A; + static_assert(i == 1); + } +} +\end{codeblock} +\end{example} \begin{note} When a class scope is searched, the scopes of its base classes are also searched\iref{class.member.lookup}.