unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Richard Stallman <rms@gnu.org>
To: emacs-devel@gnu.org
Subject: Re: mailabbrev fix from Jan 2005 now broken in latest CVS
Date: Sun, 12 Aug 2007 20:52:18 -0400	[thread overview]
Message-ID: <E1IKOAM-0000L9-JT@fencepost.gnu.org> (raw)

Would someone please fix this, then ack?

To: emacs-devel@gnu.org
From: John Owens <john_owens@yahoo.com>
Date: Wed, 1 Aug 2007 18:22:26 +0000 (UTC)
Lines: 82
Message-ID: <loom.20070801T202014-229@post.gmane.org>
References: <loom.20070731T053637-971@post.gmane.org>
	<E1IG6vT-0005Si-TM@fencepost.gnu.org>
Subject: Re: mailabbrev fix from Jan 2005 now broken in latest CVS

Richard Stallman <rms <at> gnu.org> writes:
> 
> Could you please send me a *precise* test case for this bug?  The test
> case should start with `emacs -q', so that your .emacs file does not
> affect it, and it should show exactly what text to put in the buffer,
> what commands to execute, and how and where to click.  Also please say
> exactly what incorrect results you get.

Thanks for your reply, and your detailed description of what you need
to take a closer look. Here are the steps I use to reproduce the
problem. There is probably a much more efficient way for me to do the
init than what I've done (having to set the load-path and manually add
the paths to the load-library calls seems kludgey), so please clue me
in.

I am using Carbon Emacs on OS X, though my best guess is that this
problem would also be present on other platforms.

GNU Emacs 22.1.1 (i386-apple-darwin8.9.1, Carbon Version 1.6.0) of
2007-06-16 on localhost

It uses what appears to be the latest cvs mailabbrev (the changes in
1.82.2.1 / 1.83) and almost certainly uses a mid-June drop of emacs
from cvs.

First, I defined the following file, ~/test-mailabbrev.el.

======

;;; begin test-mailabbrev.el

(setq load-path 
      '("/Applications/Emacs.app/Contents/Resources/lisp"
	"/Applications/Emacs.app/Contents/Resources/lisp/emacs-lisp"
	"/Applications/Emacs.app/Contents/Resources/lisp/mail"))

;; load compose-mail
(load-library 
 "/Applications/Emacs.app/Contents/Resources/lisp/simple.el")

;; load mailabbrev
(load-library
 "/Applications/Emacs.app/Contents/Resources/lisp/mail/mailabbrev.el")

(define-mail-abbrev "rms" "rms@gnu.org")
(define-mail-abbrev "rms-other" "rms@other.org")
(add-hook 'mail-mode-hook 'mail-abbrevs-setup)

;;; end test-mailabbrev.el

======

Then I reproduce using the following sequence:

======

/* launch emacs with -q */
$ /Applications/Emacs.app/Contents/MacOS/bin/emacs -q    

/* within emacs, type everything before the ;; */
M-x load-library ~/test-mailabbrev.el
M-x compose-mail  ;; this places point after "To: " 
rms,        ;; this properly expands "rms" to "rms@gnu.org"
            ;; "To" line is now "To: rms@gnu.org,"
rms-        ;; this should NOT expand the rms alias but does
            ;; I would like to finish the alias "rms-" to "rms-other"
            ;; "To" line is now "To: rms@gnu.org,rms@gnu.org-"
            ;; Desired "To" line is "To: rms@gnu.org,rms-"
            ;; with an unexpanded "rms-"

======

If I use the previous 1.68.2.10 version of mailabbrev (load it instead
of the one in cvs), the problem does not appear. Instead it does NOT
expand rms- with rms's alias and waits until the end of the alias (a
comma or a space) to expand rms-other. 

One-sentence summary: The character '-' should not cause an alias
expansion via mailabbrev.

JDO

             reply	other threads:[~2007-08-13  0:52 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-08-13  0:52 Richard Stallman [this message]
2007-08-15  2:07 ` mailabbrev fix from Jan 2005 now broken in latest CVS Glenn Morris
2007-08-15  3:35   ` John Owens
  -- strict thread matches above, loose matches on Subject: below --
2007-07-31  3:46 John Owens
2007-08-01  5:39 ` Richard Stallman
2007-08-01 18:22   ` John Owens

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=E1IKOAM-0000L9-JT@fencepost.gnu.org \
    --to=rms@gnu.org \
    --cc=emacs-devel@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 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).