all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* last-abbrev-location
@ 2004-02-24  4:37 Luc Teirlinck
  2004-02-24 14:19 ` last-abbrev-location Luc Teirlinck
  0 siblings, 1 reply; 4+ messages in thread
From: Luc Teirlinck @ 2004-02-24  4:37 UTC (permalink / raw)


Unlike `abbrev-start-location', which is a marker,
`last-abbrev-location' is just a buffer position, an integer.  Is
there a reason for this?  It seems to cause problems.

Do `emacs -q'.  Define an abbrev `exp' expanding to `expansion'.

In the *scratch* buffer type exp in the following position (no
trailing whitespace):

;; This buffer is for notes you don't want to save, and for Lisp evaluation.
;; If you want to create a file, visit that file with C-x C-f,
;; then enter the text in that file's own buffer.

exp

Then expand exp.  Go to the previous line and type 12345:

;; This buffer is for notes you don't want to save, and for Lisp evaluation.
;; If you want to create a file, visit that file with C-x C-f,
;; then enter the text in that file's own buffer.
12345
expansion


M-x unexpand-abbrev results in:

;; This buffer is for notes you don't want to save, and for Lisp evaluation.
;; If you want to create a file, visit that file with C-x C-f,
;; then enter the text in that file's own buffer.
1expnsion

This does not seem right and I have the impression that if
`last-abbrev-location' were a marker instead of an integer, one would
get:

;; This buffer is for notes you don't want to save, and for Lisp
   evaluation.
;; If you want to create a file, visit that file with C-x C-f,
;; then enter the text in that file's own buffer.
12345
exp

It would seem from the docstring of `unexpand-abbrev' that it is still
supposed to work orrectly after some minor editing of the type
described above:

Undo the expansion of the last abbrev that expanded.
This differs from ordinary undo in that other editing done since then
is not undone.

Sincerely,

Luc.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: last-abbrev-location
  2004-02-24  4:37 last-abbrev-location Luc Teirlinck
@ 2004-02-24 14:19 ` Luc Teirlinck
  2004-02-25 13:23   ` last-abbrev-location Richard Stallman
  0 siblings, 1 reply; 4+ messages in thread
From: Luc Teirlinck @ 2004-02-24 14:19 UTC (permalink / raw)
  Cc: emacs-devel

>From my previous message:

   Unlike `abbrev-start-location', which is a marker,
   `last-abbrev-location' is just a buffer position, an integer.  Is
   there a reason for this?  It seems to cause problems.

Maybe, on second thought, it might give compatibility problems if one
tried to change this now.  Maybe `unexpand-abbrev' is only intended to
be used after having typed a few extra characters _after_ the epanded
abbrev, in which case the problems described in my previous message do
not occur.  Maybe the only problem is that its docstring does not make
that sufficiently clear.

Sincerely,

Luc.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: last-abbrev-location
  2004-02-24 14:19 ` last-abbrev-location Luc Teirlinck
@ 2004-02-25 13:23   ` Richard Stallman
  2004-02-26  2:17     ` last-abbrev-location Luc Teirlinck
  0 siblings, 1 reply; 4+ messages in thread
From: Richard Stallman @ 2004-02-25 13:23 UTC (permalink / raw)
  Cc: teirllm, emacs-devel

    Maybe, on second thought, it might give compatibility problems if one
    tried to change this now.

What compatibility problems?  That variable is obscure; changing it
is ok if it fixes something.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: last-abbrev-location
  2004-02-25 13:23   ` last-abbrev-location Richard Stallman
@ 2004-02-26  2:17     ` Luc Teirlinck
  0 siblings, 0 replies; 4+ messages in thread
From: Luc Teirlinck @ 2004-02-26  2:17 UTC (permalink / raw)
  Cc: emacs-devel

Richard Stallman wrote:

   What compatibility problems?  That variable is obscure; changing it
   is ok if it fixes something.

It would require some accompanying changes in idlwave.el, but those
would not appear to be very extensive.

Sincerely,

Luc.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2004-02-26  2:17 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-02-24  4:37 last-abbrev-location Luc Teirlinck
2004-02-24 14:19 ` last-abbrev-location Luc Teirlinck
2004-02-25 13:23   ` last-abbrev-location Richard Stallman
2004-02-26  2:17     ` last-abbrev-location Luc Teirlinck

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.