You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
CWG3186 [basic.lookup.argdep] ADL is performed for a name #891
Careful reading of [basic.lookup.argdep]/4 suggests that g is also found by ADL, because it's "declared as a friend of a class with a reachable definition in the set of associated entities". Note the lack of any name requirements in [basic.lookup.argdep]/4.2, and in [basic.lookup.argdep]/4 in general.
[. . .] Argument-dependent lookup for a name N finds all declarations of functions and function templates that
— are found by a search of for N in any associated namespace, or
— have the same name as N and are declared as a friend ([class.friend]) of any class with a reachable definition in the set of associated entities, or
— have the same name as N, are exported, are attached to a named module M ([module.interface]), do not appear in the translation unit containing the point of the lookup, and have the same innermost enclosing non-inline namespace scope as a declaration of an associated entity attached to M ([basic.link]).
If the lookup is for aN is dependent name ([temp.dep], [temp.dep.candidate]), the above lookup is also performed from each point in the instantiation context ([module.context]) of the lookup, additionally ignoring any declaration that appears in another translation unit, is attached to the global module, and is either discarded ([module.global.frag]) or has internal linkage.
changed the title [-][basic.lookup.argdep] ADL is performed for a name[/-][+]CWG3186 [basic.lookup.argdep] ADL is performed for a name[/+]on May 2, 2026
Activity
jensmaurer commentedon May 2, 2026
CWG3186
[-][basic.lookup.argdep] ADL is performed for a name[/-][+]CWG3186 [basic.lookup.argdep] ADL is performed for a name[/+]