comparison .hgsigs @ 39291:9f097214fbf3

index: embed nodetree in index object to avoid reference cycle Since the index has a reference to a nodetree and the nodetree has a reference back to the index, there is a reference cycle, so the index (and its nodetree) can never be freed. This patch fixes that by making "nodetree" a plan C struct that the index can embed, and also introduces a new "nodetreeObject" that is a Python type wrapping the nodetree struct. Thanks to Yuya for noticing this and for suggesting the solution. All tests passed on the first attempt once it compiled (I guess C is like Haskell in this regard?). Differential Revision: https://phab.mercurial-scm.org/D4372
author Martin von Zweigbergk <martinvonz@google.com>
date Fri, 24 Aug 2018 08:45:18 -0700
parents cc8657f6fd3e
children e574cae381b6
comparison
equal deleted inserted replaced
39290:286a666365ec 39291:9f097214fbf3