From: Dan Nicolaescu <dann@ics.uci.edu>
To: Stefan Monnier <monnier@IRO.UMontreal.CA>
Cc: Dieter Wilhelm <dieter@duenenhof-wilhelm.de>,
4179@emacsbugs.donarmstrong.com
Subject: bug#4179: vc-merge with svn: syntax error in revision arg.
Date: Wed, 26 Aug 2009 11:04:57 -0700 (PDT) [thread overview]
Message-ID: <200908261804.n7QI4vh7023115@godzilla.ics.uci.edu> (raw)
In-Reply-To: <jwvzl9npyj6.fsf-monnier+emacsbugreports@gnu.org> (Stefan Monnier's message of "Tue, 25 Aug 2009 14:06:58 -0400")
Stefan Monnier <monnier@IRO.UMontreal.CA> writes:
> > vc-default-{previous,next}-revision use them, but they can go into
> > vc-rcs (or vc-cvs) and make one use the other (there's a precedent,
> > vc-cvs-comment-history uses an RCS backend function...).
>
> > Do you see an elegant way of dealing with this?
>
> Move them to vc-rcs.
I did that.
> > Stefan, how would you go about making these functions backend specific:
>
> > (defun vc-trunk-p (rev)
> > (defun vc-branch-p (rev)
> > (defun vc-branch-part (rev)
> > (defun vc-minor-part (rev)
>
> Not sure: for some backends (svn, bzr, darcs at least), they simply
> don't make any sense.
>
> > It seems to me that only `vc-branch-p' needs to be backend specific, the
> > rest are only used by RCS and CVS.
>
> That sounds right.
Also moved + renamed vc-trunk-p and vc-minor-part to vc-rcs.el, they are
only used in that file now.
All the above turned out to be a good cleanup, but unfortunately
not necessarily related to the problem in this bug report.
We have this code in `vc-merge'
(if (string= first-revision "")
(setq status (vc-call-backend backend 'merge-news file))
(if (not (vc-find-backend-function backend 'merge))
(error "Sorry, merging is not implemented for %s" backend)
(if (not (vc-branch-p first-revision))
(setq second-revision
(read-string "Second revision: "
(concat (vc-branch-part first-revision) ".")))
;; We want to merge an entire branch. Set revisions
;; accordingly, so that vc-BACKEND-merge understands us.
(setq second-revision first-revision)
;; first-revision must be the starting point of the branch
(setq first-revision (vc-branch-part first-revision)))
`vc-branch-p' can be made VC backend specific.
But what should we do with `vc-branch-part'?
What should be the new structure of this code?
next prev parent reply other threads:[~2009-08-26 18:04 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-08-17 17:34 bug#4179: vc-merge with svn: syntax error in revision arg Dieter Wilhelm
2009-08-20 2:59 ` Dan Nicolaescu
2009-08-25 18:06 ` Stefan Monnier
2009-08-26 18:04 ` Dan Nicolaescu [this message]
2021-08-27 3:06 ` Lars Ingebrigtsen
2021-08-27 20:11 ` H. Dieter Wilhelm
2021-08-29 0:50 ` Dmitry Gutov
2021-08-29 20:42 ` Lars Ingebrigtsen
2021-08-29 21:09 ` Dmitry Gutov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200908261804.n7QI4vh7023115@godzilla.ics.uci.edu \
--to=dann@ics.uci.edu \
--cc=4179@emacsbugs.donarmstrong.com \
--cc=dieter@duenenhof-wilhelm.de \
--cc=monnier@IRO.UMontreal.CA \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).