eberle1080/dulwich-py3k — comment on commit 6ac57123389a73e3fa1da4ac9a15c0d223dc8b3b
File:  line 0
By eberle1080:

Basically what this patch is doing is turning `parse_tree` into a generator. If you use the pure python implementation, it's already returning a generator object. So technically this is just bringing the C module "up to par" with the python implementation.

However I do agree with you that this would marginally increase the memory usage for the common case. Perhaps a better solution would be to provide the original (non-generator) version and then this one under a different name. Then the user could do some monkey-patching if they want to use the generator version:

```
import objects
objects._parse_tree_simple = objects.parse_tree
objects.parse_tree = objects.parse_tree_iter
# Do something that requires the generator version
objects.parse_tree = objects._parse_tree_simple
```

Would this be a better solution?