[PATCH] diff.noprefix no longer breaks {diffstat} (issue4755)

Sean Farley sean at farley.io
Fri Jan 13 14:33:26 EST 2017


Matthieu Laneuville via Mercurial-devel
<mercurial-devel at mercurial-scm.org> writes:

> # HG changeset patch
> # User Matthieu Laneuville <mlaneuville at protonmail.com>
> # Date 1484222815 -32400
> # Thu Jan 12 21:06:55 2017 +0900
> # Node ID c0030823eee2d2f320fe4b7e9d8ec90d05485980
> # Parent 493935e0327a2dca0987a702bf06fa89b62e6a5c
> templatekw: force noprefix=False to insure diffstat consistency (issue4755)
>
> The result of diffstatdata should not depend on having noprefix set or not, as
> was reported in issue 4755. Forcing noprefix to false on call makes sure the
> parser receives the diff in the correct format and returns the proper result.
>
> Another way to fix this would have been to change the regular expressions in
> path.diffstatdata(), but that would have introduced many unecessary special
> cases.

This reasoning and the test look good to me.


More information about the Mercurial-devel mailing list