Commit 125f19b2 authored by Kevin Modzelewski's avatar Kevin Modzelewski

Some small fixes

parent 2b8eae9b
......@@ -2017,7 +2017,6 @@ Box* dataDescriptorInstanceSpecialCases(GetattrRewriteArgs* rewrite_args, BoxedS
}
if (rewrite_args) {
assert(0 && "check refcounting");
r_descr->addAttrGuard(offsetof(BoxedProperty, prop_get), (intptr_t)prop->prop_get);
RewriterVar* r_prop_get = r_descr->getAttr(offsetof(BoxedProperty, prop_get));
......@@ -2460,7 +2459,7 @@ Box* getattrInternalGeneric(Box* obj, BoxedString* attr, GetattrRewriteArgs* rew
&& attr->interned_state == SSTATE_INTERNED_IMMORTAL)) {
class Helper {
public:
static Box* call(Box* obj, BoxedString* attr) { return incref(obj->getattr(attr)); }
static Box* call(Box* obj, BoxedString* attr) { return xincref(obj->getattr(attr)); }
};
RewriterVar* r_rtn = rewrite_args->rewriter->call(
......
# expected: reffail
# Make sure that callattrs handle exceptions (including
# different exception styles) correctly.
class C(object):
......
# expected: reffail
# Test some weird getattr/hasattr guarding scenarios
......
# expected: reffail
g = 0
class C(object):
@property
......
# expected: reffail
# run_args: -n
# statcheck: noninit_count('slowpath_getattr') <= 25
......
# expected: reffail
class Mgr(object):
def __init__(self): print 'Mgr.__init__()'
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment