[PATCH 3 of 6 STABLE V2] dirstate: add 'rdirs()' to examine 'directory pattern' matching correctly

Matt Mackall mpm at selenic.com
Fri Mar 23 15:45:32 CDT 2012


On Fri, 2012-03-23 at 00:06 +0900, FUJIWARA Katsunori wrote:
> # HG changeset patch
> # User FUJIWARA Katsunori <foozy at lares.dti.ne.jp>
> # Date 1332428327 -32400
> # Branch stable
> # Node ID 200e12e1d1f146e52bf01aed854562df30089c45
> # Parent  d09da50da3b2a89eb2addc4deaea23b8b1683076
> dirstate: add 'rdirs()' to examine 'directory pattern' matching correctly

Ok, let's hit pause here.

This patch just further confirms my impression that something is deeply
wrong with the largefiles implementation. And the rule is: extensions
are not allowed to infect the core with their broken design. The core
doesn't need or want any of this extra complexity.

Obviously, this could be done in the largefiles code. For instance, we
could subclass dirstate. But it really seems to me there ought to be a
way to fix the abstraction to avoid the need for this sort of hack
entirely.

For instance, I think we should never have to ask the question "is this
a largefile?" outside a very small set of functions. But we're checking
this or converting largefile paths to standin paths or vice-versa in
hundreds of places. That means there are probably dozens of places where
we've done it wrong or forgotten to do it.

-- 
Mathematics is the supreme nostalgia of our time.




More information about the Mercurial-devel mailing list