Exemplo n.º 1
0
 def member_setter(self, space, w_self, w_value):
     assert isinstance(self, W_MemberDescr)
     check_descr(space, w_self, self.w_type)
     pyref = make_ref(space, w_self)
     try:
         PyMember_SetOne(space, rffi.cast(rffi.CCHARP, pyref), self.member,
                         w_value)
     finally:
         decref(space, pyref)
Exemplo n.º 2
0
 def member_delete(self, space, w_self):
     assert isinstance(self, W_MemberDescr)
     check_descr(space, w_self, self.w_type)
     pyref = make_ref(space, w_self)
     try:
         PyMember_SetOne(
             space, rffi.cast(rffi.CCHARP, pyref), self.member, None)
     finally:
         Py_DecRef(space, pyref)
Exemplo n.º 3
0
 def member_setter(self, space, w_self, w_value):
     assert isinstance(self, W_MemberDescr)
     check_descr(space, w_self, self.w_type)
     PyMember_SetOne(space, w_self, self.member, w_value)
Exemplo n.º 4
0
 def member_delete(self, space, w_self):
     assert isinstance(self, W_MemberDescr)
     check_descr(space, w_self, self.w_type)
     PyMember_SetOne(space, w_self, self.member, None)