GNU bug report logs - #11019
24.0.94; ring-insert+extend does not grow ring properly

Previous Next

Package: emacs;

Reported by: Chong Yidong <cyd <at> gnu.org>

Date: Thu, 15 Mar 2012 07:03:02 UTC

Severity: normal

Found in version 24.0.94

Done: Chong Yidong <cyd <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: Chong Yidong <cyd <at> gnu.org>
Subject: bug#11019: closed (Re: bug#11019: 24.0.94; ring-insert+extend
 does not grow ring properly)
Date: Thu, 15 Mar 2012 08:44:02 +0000
[Message part 1 (text/plain, inline)]
Your bug report

#11019: 24.0.94; ring-insert+extend does not grow ring properly

which was filed against the emacs package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to 11019 <at> debbugs.gnu.org.

-- 
11019: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=11019
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Chong Yidong <cyd <at> gnu.org>
To: 11019-done <at> debbugs.gnu.org
Subject: Re: bug#11019: 24.0.94; ring-insert+extend does not grow ring properly
Date: Thu, 15 Mar 2012 16:13:27 +0800
Chong Yidong <cyd <at> gnu.org> writes:

> I will write up a fix for this soon.

Fixed in revno 107606.

[Message part 3 (message/rfc822, inline)]
From: Chong Yidong <cyd <at> gnu.org>
To: bug-gnu-emacs <at> gnu.org
Subject: 24.0.94; ring-insert+extend does not grow ring properly
Date: Thu, 15 Mar 2012 14:31:42 +0800
Looks like ring-insert+extend with a non-nil GROW-P argument does not
grow the ring properly if the ring is already "wrapped around":

(require 'ring)

(setq ring (make-ring 4))
(ring-insert ring 0)
(ring-insert ring 1)
(ring-insert ring 2)
(ring-insert ring 3)
(ring-insert ring 4)

(setq foo (ring-elements ring))
;; ==> (4 3 2 1)

(ring-insert+extend ring 5 t)

(setq bar (ring-elements ring))
;; ==> (1 4 5 3 2)
;; expected: (5 4 3 2 1)


I will write up a fix for this soon.



This bug report was last modified 13 years and 97 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.