TITLE: Types, variables, and name spaces PROBLEM: nikki@trmphrst.demon.co.uk (Nikki Locke) Is the following C++ code legal, or not ? typedef unsigned color; class ColoredButton { ColoredButton(color &color); }; RESPONSE: steve@taumet.com (Steve Clamage), 8 Oct 92 Vice Chair, ANSI C++ Committee, X3J16 I think this fragment is legal, but you will not have access to the type name 'color' inside the constructor. The ARM explictly lists (p 106) typedef long I; int I; as illegal, because the two "I" declarators are in the same scope; typedef names and variable names are in the same name space. In this example, the parameter name 'color' is in a new scope. In any event, it is certainly poor programming practice.