[darcs-devel] DarcsFlags propagation reduction

quick at sparq.org quick at sparq.org
Mon Jul 2 15:17:06 PDT 2007


This patch may be a little controversial, so I'm prepared to entertain
discussion and rework this if needed.

It appears that originally, the command-line options were passed around
to various functions as the [DarcsFlag] argument, but that eventually
these options were bound into the Repository class when the latter is
created (usually via withRepoLock).  This patch removes the explicit
[DarcsFlag] argument where the flags are available via the Repository
argument instead.  The intent is to cleanup the interfaces and prevent
confusion arising from having two different sources for the same
information.

In order to achieve this and still provide appropriate content-hiding
of Repository objects, a repoFlags function was added that extracts
the [DarcsFlag] from a Repository.  In addition, there were a couple
of internal functions within the Repository/ that I did not change
because these were internal and the paradigm in those cases was
better suited to an explicit [DarcsFlag] argument (e.g. iteration
over the list via pattern matching).

[Note: includes two patches previously sent in a separate email; the
patch in question was developed after--and depends on--the previous
patches; if the previous patches are rejected but this patch is still
desired I can resubmit a new version without the dependencies.]



Mon Jun 11 21:15:16 MST 2007  Kevin Quick <quick at sparq.org>
  * Provide [DarcsFlag] command-line options to copyLocal

Wed Jun 13 12:37:42 MST 2007  Kevin Quick <quick at sparq.org>
  * Added --nolinks option to request actual copies instead of hard-links for files.

Thu Jun 28 16:23:28 MST 2007  Kevin Quick <quick at sparq.org>
  * Remove explicit DarcsFlags args; use Repository options (adds repoFlags).

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: text/x-darcs-patch
Size: 84356 bytes
Desc: A darcs patch for your repository!
Url : http://lists.osuosl.org/pipermail/darcs-devel/attachments/20070702/ed0aec58/attachment-0001.bin


More information about the darcs-devel mailing list