C++ Logo

std-proposals

Advanced search

Re: [std-proposals] [DRAFT PAPER] Allowing the establishment of namespace scopes in an export-declaration

From: Zopolis0 <creatorsmithmdt_at_[hidden]>
Date: Thu, 15 Sep 2022 12:19:39 +1000
> So what is your intent here? Should `strob`'s implementation be able
> to use the unqualified name `frob` to refer to `foo::frob`? Or should
> it be able to use the unqualified name only if the definition is in
> the interface file that exported `frob`? Or should all uses of it need
> full qualification?
All uses of it need full qualification. Again, exported names from a method
declaration with a namespace-name have an implied namespace block wrapping
them.

> Is breaking ADL in these cases something that you *intend* to do?
In brief, yes.

> Do you genuinely intend for two declarations side-by-side that are
> *visually* at the same scope to not actually be in the same scope?

Yes. I see no other way to not drastically break with namespace convention
and also preserve the core purpose of this proposal.
If we modify the qualification requirements, I think it will cause even
more confusion and make a relatively simple proposal much less
self-explanatory.

Received on 2022-09-15 02:19:52