diff options
author | Paul Sokolovsky <pfalcon@users.sourceforge.net> | 2014-05-18 20:37:18 +0300 |
---|---|---|
committer | Paul Sokolovsky <pfalcon@users.sourceforge.net> | 2014-05-19 21:56:06 +0300 |
commit | 13684fd60b3f75956564fd09711cb93dcb6648fd (patch) | |
tree | c30c487a73d72fa10d08171ec2ee830a56df01e6 /py/qstrdefs.h | |
parent | eee31288dd9cc81a648dc033b320c6ccaf803a71 (diff) | |
download | micropython-13684fd60b3f75956564fd09711cb93dcb6648fd.tar.gz micropython-13684fd60b3f75956564fd09711cb93dcb6648fd.zip |
objtype: Separate __new__ and __init__ methods.
Now schedule is: for native types, we call ->make_new() C-level method, which
should perform actions of __new__ and __init__ (note that this is not
compliant, but is efficient), but for user types, __new__ and __init__ are
called as expected.
Also, make sure we convert scalar attribute value to a bound-pair tight in
mp_obj_class_lookup() method, which avoids converting it again and again in
its callers.
Diffstat (limited to 'py/qstrdefs.h')
-rw-r--r-- | py/qstrdefs.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/py/qstrdefs.h b/py/qstrdefs.h index ca30010120..e33d9967db 100644 --- a/py/qstrdefs.h +++ b/py/qstrdefs.h @@ -34,6 +34,7 @@ Q(__class__) Q(__doc__) Q(__import__) Q(__init__) +Q(__new__) Q(__locals__) Q(__main__) Q(__module__) |