all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: David Kastrup <dak@gnu.org>
To: rms@gnu.org
Cc: drew.adams@oracle.com, emacs-devel@gnu.org
Subject: Re: should query-replace-regexp-eval be in the manual?
Date: Mon, 16 Apr 2007 19:22:02 +0200	[thread overview]
Message-ID: <85slb0utdx.fsf@lola.goethe.zz> (raw)
In-Reply-To: <E1HdTGw-0000vU-WE@fencepost.gnu.org> (Richard Stallman's message of "Mon\, 16 Apr 2007 11\:37\:42 -0400")

Richard Stallman <rms@gnu.org> writes:

>     Basically it has been my experience that query-replace-regexp-eval is
>     a nice idea, but in practice quite unusable.  \, achieves a similar
>     purpose but with a much more convenient interface.
>
> Could you write some text to document the \ feature in the Emacs Manual?

\, has been documented in
(info "(emacs) Regexp Replace")
the Emacs manual pretty much since its inception.

>     To get back to the original question: since \, has all of the
>     functionality of query-replace-regexp-eval with a more convenient
>     interface, query-replace-regexp-eval could be considered obsolete or
>     at least obscure.
>
> I think its doc string should mention that the \ feature is more
> convenient for interactive use, and the function should be marked
> obsolete.

Since the only advantage appears to be with non-interactive use, and
for non-interactive use, the query-replace functions are not
recommended, I'll put something to this effect into the doc string.

As to obsoletion: its main effect would appear to be a byte-compiler
warning.  So perhaps something like

(make-obsolete 'query-replace-regexp-eval
  "For interactive use, use the special `\\,' feature of
`query-replace-regexp' instead.  Non-interactively, a loop
using `search-forward-regexp' and `replace-match' is
preferred." "22.1")

would be ok, even though we had no `deprecation' before `obsoletion'
and `\,' is new in Emacs 22.

-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum

  reply	other threads:[~2007-04-16 17:22 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-04-13 16:41 should query-replace-regexp-eval be in the manual? Drew Adams
2007-04-14  9:47 ` Alan Mackenzie
2007-04-14 14:43   ` Drew Adams
2007-04-15 21:56     ` David Kastrup
2007-04-15 22:03       ` David Kastrup
2007-04-15 22:11         ` Lennart Borgman (gmail)
2007-04-15 22:55           ` Drew Adams
2007-04-16  0:51             ` Robert J. Chassell
2007-04-16  3:45               ` Stefan Monnier
2007-04-15 22:54       ` Drew Adams
2007-04-16 15:37       ` Richard Stallman
2007-04-16 17:22         ` David Kastrup [this message]
2007-04-17 18:03           ` Richard Stallman
2007-04-17 23:27             ` David Kastrup
2007-04-18 14:56               ` Richard Stallman
2007-04-18 16:37                 ` David Kastrup

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=85slb0utdx.fsf@lola.goethe.zz \
    --to=dak@gnu.org \
    --cc=drew.adams@oracle.com \
    --cc=emacs-devel@gnu.org \
    --cc=rms@gnu.org \
    /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.