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

Questions in/on the code [was: svn commit: r33900 - trunk/subversion/libsvn_wc]

From: Julian Foad <julianfoad_at_btopenworld.com>
Date: Wed, 29 Oct 2008 11:48:42 +0000

On Tue, 2008-10-28 at 11:06 -0700, Greg Stein wrote:
> Why is it horrible? How are you tracking that you need to research
> these questions? Or maybe somebody else knows the answers.

It's horrible to ask questions about the code by inserting them into the
code

  1. because it's a poor channel for discussion, it implies I have no
more effective way to talk to colleagues, and useful changes to the code
base would be interleaved with useless commits of incremental
discussion;

  2. because historically such questions are rarely answered, usually
remaining in the code for years;

  3. because it presumes the questioner is right: on the occasions where
there is an answer that explains what I needed to know, and the code was
right, the result is just code churn. Only on the occasions where the
questioner had actually found a problem is the code churn then
justified.

How am I tracking that I need to research these questions? I'm not in
any formal way. Every time I read that code I recognise that I don't
understand those bits, but the questions I inserted are just a few of
many questions.

I suppose I should just ask them on the mailing list or IRC as soon as I
realise I haven't been able to find an answer for myself.

My intention at the time was that I and others should thoroughly review
all the code changes on the branch (and so see and resolve those
questions) before merging the branch back to trunk. But I got to feel
the pressure that the branch had languished far too long and the only
way to progress it was to merge it to trunk first.

- Julian

> On Mon, Oct 27, 2008 at 9:19 AM, <julianfoad_at_tigris.org> wrote:
> > Remove some question-comments that I inserted in the tree-conflicts branch
> > and then merged to trunk without resolving. (I still don't know the answers
> > but inserting question-comments is horrible.)
> >
> > * subversion/libsvn_wc/update_editor.c
> > (do_entry_deletion, add_directory, add_file): Delete question-comments.
[...]
> > @@ -1359,13 +1359,13 @@ do_entry_deletion(struct edit_baton *eb,
> >
> > tmp_entry.revision = *(eb->target_revision);
> > tmp_entry.kind =
> > - (entry->kind == svn_node_file) ? svn_node_file : svn_node_dir; /* ### redundant? */
> > + (entry->kind == svn_node_file) ? svn_node_file : svn_node_dir;
> > tmp_entry.deleted = TRUE;
> >
> > SVN_ERR(svn_wc__loggy_entry_modify(&log_item, adm_access,
> > full_path, &tmp_entry,
> > SVN_WC__ENTRY_MODIFY_REVISION
> > - | SVN_WC__ENTRY_MODIFY_KIND /* ### redundant change? */
> > + | SVN_WC__ENTRY_MODIFY_KIND
> > | SVN_WC__ENTRY_MODIFY_DELETED,
> > pool));
> >
> > @@ -1550,7 +1550,6 @@ add_directory(const char *path,
> >
> > /* Anything other than a dir scheduled for addition without
> > history is an error. */
> > - /* ### what's this "add_existed" clause for? */
> > if (entry
> > && entry->schedule == svn_wc_schedule_add
> > && ! entry->copied)
> > @@ -2541,8 +2540,6 @@ add_file(const char *path,
> > /* When adding, there should be nothing with this name unless unversioned
> > obstructions are permitted or the obstruction is scheduled for addition
> > (or replacement) without history. */
> > - /* ### " or the obstruction is scheduled for addition
> > - without history." ??? */
> > if (kind != svn_node_none)
> > {
> > if (eb->allow_unver_obstructions
> >

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: dev-help_at_subversion.tigris.org
Received on 2008-10-29 12:48:58 CET

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

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.