From: Noam Postavsky <npostavs@users.sourceforge.net>
To: raman <raman@google.com>
Cc: Emacs developers <emacs-devel@gnu.org>
Subject: Re: with-temp-buffer: should we set buffer-undo-list to t?
Date: Sun, 12 Mar 2017 09:38:16 -0400 [thread overview]
Message-ID: <CAM-tV--hQ2zCCXK2am8xrAJh9HWciA=EdhsxpaeQZ_HTxEO1yg@mail.gmail.com> (raw)
In-Reply-To: <22724.36280.852934.614634@gargle.gargle.HOWL>
On Sat, Mar 11, 2017 at 6:52 PM, <raman@google.com> wrote:
> Would setting buffer-undo-list to t in the macro definition of
> with-temp-buffer help save some work?
>
> At present we dont do this, and as a consequence, operations within
> body of with-tem-buffer may well push entries on the undo stack that
> just get thrown away.
Seems it already happens:
(with-temp-buffer
buffer-undo-list) ;=> t
get-buffer-create has this code:
bset_undo_list (b, SREF (name, 0) != ' ' ? Qnil : Qt);
So buffers starting with a space have the undo list set to t.
next prev parent reply other threads:[~2017-03-12 13:38 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-11 23:52 with-temp-buffer: should we set buffer-undo-list to t? raman
2017-03-12 13:38 ` Noam Postavsky [this message]
2017-03-12 14:48 ` raman
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='CAM-tV--hQ2zCCXK2am8xrAJh9HWciA=EdhsxpaeQZ_HTxEO1yg@mail.gmail.com' \
--to=npostavs@users.sourceforge.net \
--cc=emacs-devel@gnu.org \
--cc=raman@google.com \
/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.