Name lookup hygiene

ADL control, namespaces, using enum.

Ground rules: unnamed namespaces over file-static, inline namespace for versioning, and respect for ADL — operators live in their type's namespace.

namespace lib { inline namespace v2 {
  struct Widget {};
  void swap(Widget&, Widget&);   // found by ADL with the type
}}

No change.

Nested namespace definitions (namespace a::b::c {}) remove the indentation tax; structured code stops avoiding deep namespaces.

using enum ends Color:: repetition inside switches, and hidden friends become the lookup-hygiene tool: findable by ADL, invisible to qualified lookup.

switch (c) {
  using enum Color;
  case red:   ...; break;
  case green: ...; break;
}

No change; the hygiene rules (no using namespace in headers, hidden friends for operators) are settled practice.

Reflection can enumerate namespace members, giving tooling-grade introspection, but lookup rules themselves are untouched.

C++29direction · not adopted

Stable.

C++26 per the final working draft; C++29 rows are proposals and direction, not adopted features.