Re: a quick question about namespaces

2005-02-01 Thread Steven Bethard
Jay donnell wrote: in the code below 'print locals()' shows mc2. What is the equivalent way to see the namespace that mc resides in? class myClass: --def func1(self): self.mc = 1 mc2 = 3 print 'in myClass.func1' print 'printing locals' print locals() print I think you're loo

a quick question about namespaces

2005-02-01 Thread Jay donnell
in the code below 'print locals()' shows mc2. What is the equivalent way to see the namespace that mc resides in? class myClass: --def func1(self): self.mc = 1 mc2 = 3 print 'in myClass.func1' print 'printing locals' print locals() print Google mungs up the spacing so I p