Fixing the other failing test in lib-python/3/test/test_itertools
, test_groupby
.
See https://bugs.python.org/issue30346 and https://github.com/python/cpython/pull/1569
Using weakref.ref
to mimick CPython's const void *currgrouper; /* borrowed reference */
and not keep a grouper object alive. Not sure if there's a better way to do so in PyPy?