From: miguel <ms...@us...> - 2006-10-04 11:02:36
|
dg...@ni... wrote: > Quoting Miguel Sofer <ms...@us...>: >> TIP #278: FIX VARIABLE NAME RESOLUTION QUIRKS > >> * an absolute is always resolved starting at the global namespace. > > I would like this proposal to clearly declare that an absolute variable > name needs no resolving at all, and one can depend on an assumption > that ::foo::bar::baz refers to a variable named "baz" in a namespace > named "bar" that is a child of a namespace named "foo" that is a child > of the global namespace of the interpreter. > > I can't point to the examples without a bit of source diving, but there > are parts of the core that rely on this assumption. > > Yet, with customizable resolver routines possibly lurking, I don't > think that assumption can be considered 100% reliable. This proposal > should make it so. > > Yes, that means in at least some limited way this proposal needs > to address the Resolver swamp. Good catch, thank you! The TIP has been edited to incorporate this point. Sadly, it now mentions the resolvers - I just hope it will not cause more extension writers to use/abuse them before we get a chance to completely clear the swamp. Miguel |