1.1 --- a/micropython/trans.py Thu Jan 13 23:58:12 2011 +0100
1.2 +++ b/micropython/trans.py Sat Jan 29 21:07:27 2011 +0100
1.3 @@ -426,8 +426,10 @@
1.4
1.5 # Produce a suitable instruction.
1.6
1.7 - if AddressInstruction is not None:
1.8 + if attr.is_static_attribute() and AddressInstruction is not None:
1.9 self.replace_active_value(AddressInstruction(attr))
1.10 + elif not attr.is_static_attribute() and AttrInstruction is not None:
1.11 + self.replace_active_value(AttrInstruction(attr))
1.12 else:
1.13 raise TranslateError("Storing of class or module attribute %r via an object is not permitted." % attrname)
1.14