From: Nick Roberts <nickrob@snap.net.nz>
Cc: emacs-devel@gnu.org, Paul Pogonyshev <pogonyshev@gmx.net>
Subject: Re: `gud-common-init'
Date: Fri, 17 Dec 2004 12:27:08 +1300 [thread overview]
Message-ID: <16834.6604.709346.496421@farnswood.snap.net.nz> (raw)
In-Reply-To: <jwv8y7x4zqv.fsf-monnier+emacs@gnu.org>
> While it´s generally not encouraged I think it´d be good not to mess up when
> the needs comes up...
Well the price paid is lisp code that is harder to understand.
> ... In PCL-CVS I wrote cvs-string->strings (and
> a corresponding cvs-strings->string) to handle that.
Its funny you should say that since in the previous thread (gud.el changes) I
thought you were the one who wasn't keen on the change. AFAIK the last message
in that thread was mine (Sun, 6 Jul 2003 03:37:34 +0100):
RMS> But if shell quoting is the wrong format for this use,
RMS> then comint-arguments is not right for it. In that case,
RMS> this statement is probably right:
You> I think we need something similar to cvs-string->strings in subr.el
You> (and a corresponding strings->string).
Me> As Richard is agreeable to this and since you wrote pcvs-util.el, can I
Me> suggest that you make this change.
Me> Please note, however that I had to change cvs-string->strings slightly
Me> because split-string has been re-defined and can now output null strings:
Me> --- pcvs-util.el.~1.19.~ 2003-05-10 11:27:06.000000000 +0100
Me> +++ pcvs-util.el 2003-06-28 17:43:22.000000000 +0100
Me> @@ -223,8 +223,8 @@
Me> The SEPARATOR regexp defaults to \"\\s-+\"."
Me> (let ((sep (or separator "\\s-+"))
Me> (i (string-match "[\"]" string)))
Me> - (if (null i) (split-string string sep) ; no quoting: easy
Me> - (append (unless (eq i 0) (split-string (substring string 0 i) sep))
Me> + (if (null i) (split-string string sep t) ; no quoting: easy
Me> + (append (unless (eq i 0) (split-string (substring string 0 i) sep t))
Me> (let ((rfs (read-from-string string i)))
Me> (cons (car rfs)
Me> (cvs-string->strings (substring string (cdr rfs))
Me> Then only one line need be changed in gud.el:
Me> --- gud.el.~1.3.~ 2003-06-19 01:54:57.000000000 +0100
Me> +++ gud.el 2003-06-28 17:17:02.000000000 +0100
Me> @@ -2297,7 +2297,7 @@
Me> ;; for local variables in the debugger buffer.
Me> (defun gud-common-init (command-line massage-args marker-filter
Me> &optional find-file)
Me> - (let* ((words (split-string command-line))
Me> + (let* ((words (cvs-string->strings command-line))
Me> (program (car words))
Me> (dir default-directory)
Me> ;; Extract the file name from WORDS
Me> though cvs-string->strings will no doubt have another name when it's moved to
Me> subr.el
Nick
next prev parent reply other threads:[~2004-12-16 23:27 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-12-15 3:01 `gud-common-init' Paul Pogonyshev
2004-12-15 4:09 ` `gud-common-init' Nick Roberts
2004-12-15 15:37 ` `gud-common-init' Paul Pogonyshev
2004-12-15 20:28 ` `gud-common-init' Nick Roberts
2004-12-15 20:48 ` `gud-common-init' Paul Pogonyshev
2004-12-15 22:26 ` `gud-common-init' Nick Roberts
2004-12-16 23:02 ` `gud-common-init' Stefan Monnier
2004-12-16 23:27 ` Nick Roberts [this message]
2004-12-17 13:51 ` `gud-common-init' Stefan Monnier
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=16834.6604.709346.496421@farnswood.snap.net.nz \
--to=nickrob@snap.net.nz \
--cc=emacs-devel@gnu.org \
--cc=pogonyshev@gmx.net \
/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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.