This doesn't make sense to me. The @ANON pragma avoids the add_method (or store_global) call in the first place.
I don't want the method added to a namespace, or stored as a global. I want it stored as a property of a class object.
I presumed that ;) Well, due to the described problem (class exists already or not) that's for now a good alternative
Python classes are not namespaces. Nor are they global. They are dictionaries.
Or, the view is a dictionary-like. The dict is CPython's implementation. I can imagine that Parrot's class namespaces work as well.
Take a look at the last test in parrot/languages/python/t/basic/oo_class.t to get an idea of what I am talking about.
Well, that just depends on how you implement attribute access, as far as I can see.
- Sam Ruby
leo