• Philipp von Weitershausen's avatar
    Merged from old philikon-aq-and-__parent__ branch: · 50768a62
    Philipp von Weitershausen authored
    Log message for revision 71221:
      Step 2: Make aq_acquire aware of __parent__ pointers, even if the object
      isn't acquisition wrapped.
    
    Log message for revision 71223:
      Add another test that tests acquisition wrappers with containers that have __parent__.
    
    Log message for revision 71225:
      Cosmetics: adjust a piece of code that I added earlier to the indentation
      style of the overall file
    
    Log message for revision 71226:
      Cleanup:
      * no need to introduce another variable where we check for a __parent__ attribute
      * clean up after failed getattr (it throws an AttributeError)
      * properly DECREF the __parent__ attribute when it's no longer needed and
        the wrapper that is temporarily created from the __parent__ attribute.
    
    Log message for revision 75578:
      Added a test to Acquisition that shows the current segmentation fault problem, when Acquisition goes in circles.
    
    Log message for revision 76140:
      First attempt to fix 'Acquisition problem' when encountering cyclic hierarchies via __parent__ pointers. [hannosch, nouri]
    
    
    In addition, Hanno and Nouri's fix was expanded to not only cover circular __parent__
    pointers but also to cover a mixture of circular __parent__ and aq_parent pointers
    (which can occur when old Implicit acquisition meets new __parent__ pointer code).
    
    Also cleaned up much of the comments and added more comments.
    50768a62
_Acquisition.c 43.3 KB