unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: "Drew Adams" <drew.adams@oracle.com>
To: 12314@debbugs.gnu.org
Subject: bug#12314: 24.2.50; `add-to-history': use `setq' with `delete'
Date: Thu, 30 Aug 2012 16:08:05 -0700	[thread overview]
Message-ID: <7602D24B74DE42CF9901322634B85CA2@us.oracle.com> (raw)

This line in `add-to-history':
 
(if history-delete-duplicates (delete newelt history))
 
should be this:
 
(if history-delete-duplicates (setq history (delete newelt history)))
 
(Or for more clarity, use `when' instead of `if'.)
 
I'm not 100% sure this is a problem, but it seems to be in a case I saw.
And there seems to be no reason not to set `history' to the `delete'
result here.

In GNU Emacs 24.2.50.1 (i386-mingw-nt5.1.2600)
 of 2012-08-26 on MARVIN
Bzr revision: 109788 dmantipov@yandex.ru-20120827041533-3cy7pdjdqz14o90c
Windowing system distributor `Microsoft Corp.', version 5.1.2600
Configured using:
 `configure --with-gcc (4.6) --no-opt --enable-checking --cflags
 -ID:/devel/emacs/libs/libXpm-3.5.8/include
 -ID:/devel/emacs/libs/libXpm-3.5.8/src
 -ID:/devel/emacs/libs/libpng-dev_1.4.3-1/include
 -ID:/devel/emacs/libs/zlib-dev_1.2.5-2/include
 -ID:/devel/emacs/libs/giflib-4.1.4-1/include
 -ID:/devel/emacs/libs/jpeg-6b-4/include
 -ID:/devel/emacs/libs/tiff-3.8.2-1/include
 -ID:/devel/emacs/libs/gnutls-3.0.9/include
 -ID:/devel/emacs/libs/libiconv-1.13.1-1-dev/include
 -ID:/devel/emacs/libs/libxml2-2.7.8/include/libxml2'
 






             reply	other threads:[~2012-08-30 23:08 UTC|newest]

Thread overview: 37+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-30 23:08 Drew Adams [this message]
2012-09-08 14:32 ` bug#12314: 24.2.50; `add-to-history': use `setq' with `delete' Chong Yidong
2012-09-08 14:43   ` Eli Zaretskii
2012-09-08 14:57     ` Drew Adams
2012-09-08 15:20       ` Eli Zaretskii
2012-09-08 15:48         ` Drew Adams
2012-09-08 16:05           ` Eli Zaretskii
2012-09-08 16:19             ` Andreas Schwab
2012-09-08 16:33               ` Eli Zaretskii
2012-09-08 16:50                 ` Lars Ingebrigtsen
2012-09-08 16:54                 ` Drew Adams
2012-09-08 17:06                 ` Andreas Schwab
2012-09-08 16:35               ` Drew Adams
2012-09-08 16:25             ` Drew Adams
2012-09-08 16:32               ` Eli Zaretskii
2012-09-08 16:42                 ` Drew Adams
2012-09-08 21:21                   ` Eli Zaretskii
2012-09-08 22:26                     ` Drew Adams
2012-09-09  3:00                       ` Eli Zaretskii
2012-09-09  6:29                         ` Drew Adams
2012-09-09  7:53                         ` Chong Yidong
2012-09-09 17:25                           ` Eli Zaretskii
2012-09-10 11:54                       ` Wolfgang Jenkner
2012-09-08 23:11                     ` Stefan Monnier
2012-09-09  2:51                       ` Eli Zaretskii
2012-09-09 14:44                         ` Stefan Monnier
2012-09-09 17:14                           ` Eli Zaretskii
2012-09-09 17:35                             ` Drew Adams
2012-09-09 18:20                               ` Eli Zaretskii
2012-09-09 19:46                                 ` Drew Adams
2012-09-09 21:37                             ` Stefan Monnier
2012-09-10  4:37                               ` Eli Zaretskii
2012-09-10 12:59                                 ` Stefan Monnier
2012-09-10 15:01                                   ` Stefan Monnier
2012-09-10 15:21                                   ` Drew Adams
2012-09-10 16:24                                   ` Eli Zaretskii
2012-09-09  8:25 ` Dmitry Gutov

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=7602D24B74DE42CF9901322634B85CA2@us.oracle.com \
    --to=drew.adams@oracle.com \
    --cc=12314@debbugs.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).