stringutil: teach pprint() to recognize generators
Otherwise they get serialized as e.g.
<generator object X at 0x
7f543d3d68c0>
Differential Revision: https://phab.mercurial-scm.org/D4396
commitextras: no need to special case extras=[]
Differential Revision: https://phab.mercurial-scm.org/D4405
commitextras: work nicely with other extensions
Before this change, it doesn't add these extra fields when loaded
alongside another extension that does a bunch of things, including
wrapping commit.
I did not investigate exactly why, but
- the documentation of extensions.wrapfunction says to use subclassing
to play nicely with other extensions
- using subclassing does make commitextras work when loaded alongside
my other extension
Differential Revision: https://phab.mercurial-scm.org/D4404
context: use new names for unstable changesets in docstrings
Plus slight corrections.
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
catapipe: make the file executable
This silences test-check-execute.t.
Differential Revision: https://phab.mercurial-scm.org/D4403