These are chat archives for dropbox/pyston

30th
Mar 2015
Michael Arntzenius
@rntz
Mar 30 2015 22:43
Hm, a bunch of cpython's tests are failing under -n because None.__class__ raises an error under -n (but not normally). Anyone know why this might be so?
Kevin Modzelewski
@kmod
Mar 30 2015 23:52
maybe due to our static rules for NoneType in compvars.cpp?
Michael Arntzenius
@rntz
Mar 30 2015 23:52
Yeah, I just found out where it's happening
Kevin Modzelewski
@kmod
Mar 30 2015 23:52
err, NONE
Michael Arntzenius
@rntz
Mar 30 2015 23:53
NormalObjectType->getattr() thinks it can statically resolve getattrs and cls->getattr() is returning NULL
presumably cls->getattr() should be returning <type 'type'>, though?
since that is the class of NoneType
Kevin Modzelewski
@kmod
Mar 30 2015 23:54
ah, it looks like we use cls->getattr() and not typeLookup()
__class__ is defined on the object class, but we don't end up checking that
Michael Arntzenius
@rntz
Mar 30 2015 23:55
okay, so the solution is to use typeLookup(cls, attr, NULL)?
well, I'll try that anyway
Kevin Modzelewski
@kmod
Mar 30 2015 23:56
yeah, that sounds right
Michael Arntzenius
@rntz
Mar 30 2015 23:56
is there documentation on what Box->getattr does vs typeLookup (vs other ways, if they exist) anywhere?
Kevin Modzelewski
@kmod
Mar 30 2015 23:57
err, no :/