[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH] Correct svn_wc_get_pristine_copy_path() comment.

From: Madan U Sreenivasan <madan_at_collab.net>
Date: 2006-06-19 16:54:07 CEST

On Mon, 19 Jun 2006 18:23:26 +0530, Malcolm Rowe
<malcolm-svn-dev@farside.org.uk> wrote:

> On Mon, Jun 19, 2006 at 06:30:32PM +0530, Madan U Sreenivasan wrote:
[snip]
>> I spoke with eh on irc sometime back, and eh felt that this API might
>> be used in places where the text-base does not exist, but has to be
>> created. For example in case of a cp/mv.
> Or instead of guessing, you could have looked to see where it is
> actually used.

Yeah... I just didn't feel the need to validate eh's comments. Will keep
this in mind henceforth. Thanks. :)

[snip]
>> [[[
>> Correct comment for svn_wc_get_pristine_copy_path().
>>
>> * subversion/include/svn_wc.h
>> (svn_wc_get_pristine_copy_path): svn_wc_get_pristine_copy_path()
>> doesnt
>> return NULL for the pristine_path parameter, if passed a wc path, for
>> which a text-base doesn't exist. Removed part of the comment that
>> says
>> so.
>> ]]]
>>
>
> Too much detail, in my opinion. 'Remove incorrect statement in
> doc-comments' or anything similar would be fine.

Done.

>> /** Given a @a path to a wc file, return a @a pristine_path which
>> points to a
>> - * pristine version of the file. This is needed so clients can do
>> - * diffs. If the WC has no text-base, return a @c NULL instead of a
>> - * path.
>> + * pristine version of the file. This is needed so clients can do
>> diffs.
>> */
>
> I'd also remove the 'This is needed so clients can do diffs' statement,
> since this doesn't appear to be true, and even if it was, we shouldn't
> try to justify all the possible reasons a client might want access to the
> BASE version of the file. Mentioning the word 'BASE' here might be a
> good
> idea too, since 'pristine' isn't immediately obvious as the same thing.

Done too. Please find attached the fixed log and patch.

[[[
Correct comment for svn_wc_get_pristine_copy_path().

* subversion/include/svn_wc.h
   (svn_wc_get_pristine_copy_path): Remove incorrect statements from the
    doc-comments.
]]]

Regards,
Madan.

Index: subversion/include/svn_wc.h
===================================================================
--- subversion/include/svn_wc.h (revision 20165)
+++ subversion/include/svn_wc.h (working copy)
@@ -3034,9 +3034,7 @@
 
 
 /** Given a @a path to a wc file, return a @a pristine_path which points to a
- * pristine version of the file. This is needed so clients can do
- * diffs. If the WC has no text-base, return a @c NULL instead of a
- * path.
+ * BASE version of the file.
  */
 svn_error_t *svn_wc_get_pristine_copy_path(const char *path,
                                            const char **pristine_path,

Correct comment for svn_wc_get_pristine_copy_path().

* subversion/include/svn_wc.h
  (svn_wc_get_pristine_copy_path): Remove incorrect statements from the
   doc-comments.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Mon Jun 19 16:24:14 2006

This is an archived mail posted to the Subversion Dev mailing list.