TITLE: do namespaces need protected/private (Newsgroups: comp.std.c++) PROBLEM: Namespaces have one deficiency: their members cannot be protected from the outside like class members can be with a "private:" or "protected:" keyword. RESPONSE: esap@cs.tut.fi (Pulkkinen Esa), 9 Aug 96 But you don't need those. First, namespaces can't be derived from each other, so I can't see much use for the protected keyword. Secondly, you can use unnamed namespaces to implement private members as follows: namespace A { namespace { int x,y,z; // only functions in A can access these! }; };