From unknown Sat Jun 21 03:23:56 2025 X-Loop: don@donarmstrong.com Subject: bug#1301: previous-single-char-property-change on string with no match returns string end Reply-To: "Tim Toolan" , 1301@debbugs.gnu.org Resent-From: "Tim Toolan" Resent-To: bug-submit-list@lists.donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Mon, 03 Nov 2008 13:45:02 +0000 Resent-Message-ID: Resent-Sender: don@donarmstrong.com X-Emacs-PR-Message: report 1301 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Received: via spool by submit@emacsbugs.donarmstrong.com id=B.122571949518307 (code B ref -1); Mon, 03 Nov 2008 13:45:02 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-4.9 required=4.0 tests=BAYES_00,FOURLA, MSGID_FROM_MTA_HEADER,RCVD_IN_DNSWL_MED autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at submit) by emacsbugs.donarmstrong.com; 3 Nov 2008 13:38:15 +0000 Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id mA3DcBbH018301 for ; Mon, 3 Nov 2008 05:38:12 -0800 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KwzdD-0008Lk-2K for bug-gnu-emacs@gnu.org; Mon, 03 Nov 2008 08:38:11 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KwzdB-0008LB-JX for bug-gnu-emacs@gnu.org; Mon, 03 Nov 2008 08:38:10 -0500 Received: from [199.232.76.173] (port=36873 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KwzdB-0008L8-Dv for bug-gnu-emacs@gnu.org; Mon, 03 Nov 2008 08:38:09 -0500 Received: from orca.ele.uri.edu ([131.128.51.63]:50084) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KwzdA-0002JW-TS for bug-gnu-emacs@gnu.org; Mon, 03 Nov 2008 08:38:09 -0500 Received: from lobster (lobster.ele.uri.edu [131.128.51.4]) by orca.ele.uri.edu (8.14.3/8.14.3) with SMTP id mA3Dc0C2025214 for ; Mon, 3 Nov 2008 08:38:00 -0500 Message-Id: <200811031338.mA3Dc0C2025214@orca.ele.uri.edu> Received: by lobster (sSMTP sendmail emulation); Mon, 3 Nov 2008 08:38:00 -0500 From: "Tim Toolan" Date: Mon, 3 Nov 2008 08:38:00 -0500 To: bug-gnu-emacs@gnu.org X-Scanned-By: MIMEDefang 2.64 on 131.128.51.63 X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) When searching a string using previous-single-char-property-change, and no change is found, it returns the maximum valid position in object, instead of the minimum valid position in object as stated in the emacs lisp manual. This can be reproduced by the following lisp statement, which returns 10 instead of 0. (previous-single-char-property-change 10 'display "0123456789") In GNU Emacs 22.2.1 (x86_64-pc-linux-gnu, X toolkit, Xaw3d scroll bars) of 2008-06-12 on aquarius Windowing system distributor `The X.Org Foundation', version 11.0.10300000 configured using `configure '--prefix=/usr' '--host=x86_64-pc-linux-gnu' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--datadir=/usr/share' '--sysconfdir=/etc' '--localstatedir=/var/lib' '--program-suffix=-emacs-22' '--infodir=/usr/share/info/emacs-22' '--without-carbon' '--with-sound' '--with-x' '--with-toolkit-scroll-bars' '--with-jpeg' '--with-tiff' '--with-gif' '--with-png' '--with-xpm' '--with-x-toolkit=athena' '--without-gtk' '--without-hesiod' '--with-kerberos' '--with-kerberos5' '--libdir=/usr/lib64' '--build=x86_64-pc-linux-gnu' 'build_alias=x86_64-pc-linux-gnu' 'host_alias=x86_64-pc-linux-gnu' 'CFLAGS=-march=nocona -pipe -O2' 'LDFLAGS='' Important settings: value of $LC_ALL: nil value of $LC_COLLATE: nil value of $LC_CTYPE: nil value of $LC_MESSAGES: nil value of $LC_MONETARY: nil value of $LC_NUMERIC: nil value of $LC_TIME: nil value of $LANG: C locale-coding-system: nil default-enable-multibyte-characters: t Major mode: Emacs-Lisp Minor modes in effect: show-paren-mode: t tooltip-mode: t mouse-wheel-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t unify-8859-on-encoding-mode: t utf-translate-cjk-mode: t auto-compression-mode: t column-number-mode: t line-number-mode: t transient-mark-mode: t Recent input: M-x r e p o r t Recent messages: Warning: no fonts matching `-*-fixed-medium-r-normal-*-16-*-*-*-*-*-iso8859-1' available [2 times] ("emacs" "pscpc.el") Loading paren...done Loading /usr/share/emacs/site-lisp/auctex/tex-site.el (source)...done Loading /u/staff/toolan/.emacs.d/auxlabel.el (source)...done Loading /u/staff/toolan/.emacs.d/auxlabel.el (source)...done For information about GNU Emacs and the GNU system, type C-h C-a. Loading emacsbug... Loading regexp-opt...done Loading emacsbug...done From unknown Sat Jun 21 03:23:56 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.420 (Entity 5.420) X-Loop: don@donarmstrong.com From: help-debbugs@gnu.org (Emacs bug Tracking System) To: "Tim Toolan" Subject: bug#1301 closed by martin rudalics (Re: bug#1301: previous-single-char-property-change on string with no match returns string end) Message-ID: References: <490F3655.1050101@gmx.at> <200811031338.mA3Dc0C2025214@orca.ele.uri.edu> X-Emacs-PR-Message: they-closed 1301 X-Emacs-PR-Package: emacs Reply-To: 1301@debbugs.gnu.org Content-Type: multipart/mixed; boundary="----------=_1225734303-14898-1" This is a multi-part message in MIME format... ------------=_1225734303-14898-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" This is an automatic notification regarding your bug report which was filed against the emacs package: #1301: previous-single-char-property-change on string with no match returns= string end It has been closed by martin rudalics . Their explanation is attached below along with your original report. If this explanation is unsatisfactory and you have not received a better one in a separate message then please contact martin rudalics by replying to this email. --=20 1301: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D1301 Emacs Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1225734303-14898-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit >From rudalics@gmx.at Mon Nov 3 09:37:15 2008 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-6.9 required=4.0 tests=AWL,BAYES_00,HAS_BUG_NUMBER autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at 1301-done) by emacsbugs.donarmstrong.com; 3 Nov 2008 17:37:15 +0000 Received: from mail.gmx.net (mail.gmx.net [213.165.64.20]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with SMTP id mA3HbBe0013651 for <1301-done@emacsbugs.donarmstrong.com>; Mon, 3 Nov 2008 09:37:13 -0800 Received: (qmail invoked by alias); 03 Nov 2008 17:37:05 -0000 Received: from 88-117-47-134.adsl.highway.telekom.at (EHLO [88.117.47.134]) [88.117.47.134] by mail.gmx.net (mp053) with SMTP; 03 Nov 2008 18:37:05 +0100 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX184r/gGVJo4t//fQnM9MRRq03OehAi3rpGpvv85p/ l9gd13NMwPhSxk Message-ID: <490F3655.1050101@gmx.at> Date: Mon, 03 Nov 2008 18:35:17 +0100 From: martin rudalics User-Agent: Thunderbird 2.0.0.16 (Windows/20080708) MIME-Version: 1.0 To: 1301-done@debbugs.gnu.org CC: Tim Toolan Subject: Re: bug#1301: previous-single-char-property-change on string with no match returns string end References: <200811031338.mA3Dc0C2025214@orca.ele.uri.edu> In-Reply-To: <200811031338.mA3Dc0C2025214@orca.ele.uri.edu> Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 X-FuHaFi: 0.58 > When searching a string using previous-single-char-property-change, and no > change is found, it returns the maximum valid position in object, instead > of the minimum valid position in object as stated in the emacs lisp manual. > > This can be reproduced by the following lisp statement, which returns 10 > instead of 0. > > (previous-single-char-property-change 10 'display "0123456789") > > > In GNU Emacs 22.2.1 (x86_64-pc-linux-gnu, X toolkit, Xaw3d scroll bars) > of 2008-06-12 on aquarius Thank you very much for the report. Fixed for Emacs 23.0.60 as 2008-11-03 Martin Rudalics * textprop.c (Fprevious_single_char_property_change): Return 0 when there's no change in a string. (Bug#1301) martin ------------=_1225734303-14898-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit >From toolan@ele.uri.edu Mon Nov 3 05:38:15 2008 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Status: No, score=-4.9 required=4.0 tests=BAYES_00,FOURLA, MSGID_FROM_MTA_HEADER,RCVD_IN_DNSWL_MED autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at submit) by emacsbugs.donarmstrong.com; 3 Nov 2008 13:38:15 +0000 Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id mA3DcBbH018301 for ; Mon, 3 Nov 2008 05:38:12 -0800 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KwzdD-0008Lk-2K for bug-gnu-emacs@gnu.org; Mon, 03 Nov 2008 08:38:11 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KwzdB-0008LB-JX for bug-gnu-emacs@gnu.org; Mon, 03 Nov 2008 08:38:10 -0500 Received: from [199.232.76.173] (port=36873 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KwzdB-0008L8-Dv for bug-gnu-emacs@gnu.org; Mon, 03 Nov 2008 08:38:09 -0500 Received: from orca.ele.uri.edu ([131.128.51.63]:50084) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KwzdA-0002JW-TS for bug-gnu-emacs@gnu.org; Mon, 03 Nov 2008 08:38:09 -0500 Received: from lobster (lobster.ele.uri.edu [131.128.51.4]) by orca.ele.uri.edu (8.14.3/8.14.3) with SMTP id mA3Dc0C2025214 for ; Mon, 3 Nov 2008 08:38:00 -0500 Message-Id: <200811031338.mA3Dc0C2025214@orca.ele.uri.edu> Received: by lobster (sSMTP sendmail emulation); Mon, 3 Nov 2008 08:38:00 -0500 From: "Tim Toolan" Date: Mon, 3 Nov 2008 08:38:00 -0500 To: bug-gnu-emacs@gnu.org Subject: previous-single-char-property-change on string with no match returns string end X-Scanned-By: MIMEDefang 2.64 on 131.128.51.63 X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) When searching a string using previous-single-char-property-change, and no change is found, it returns the maximum valid position in object, instead of the minimum valid position in object as stated in the emacs lisp manual. This can be reproduced by the following lisp statement, which returns 10 instead of 0. (previous-single-char-property-change 10 'display "0123456789") In GNU Emacs 22.2.1 (x86_64-pc-linux-gnu, X toolkit, Xaw3d scroll bars) of 2008-06-12 on aquarius Windowing system distributor `The X.Org Foundation', version 11.0.10300000 configured using `configure '--prefix=/usr' '--host=x86_64-pc-linux-gnu' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--datadir=/usr/share' '--sysconfdir=/etc' '--localstatedir=/var/lib' '--program-suffix=-emacs-22' '--infodir=/usr/share/info/emacs-22' '--without-carbon' '--with-sound' '--with-x' '--with-toolkit-scroll-bars' '--with-jpeg' '--with-tiff' '--with-gif' '--with-png' '--with-xpm' '--with-x-toolkit=athena' '--without-gtk' '--without-hesiod' '--with-kerberos' '--with-kerberos5' '--libdir=/usr/lib64' '--build=x86_64-pc-linux-gnu' 'build_alias=x86_64-pc-linux-gnu' 'host_alias=x86_64-pc-linux-gnu' 'CFLAGS=-march=nocona -pipe -O2' 'LDFLAGS='' Important settings: value of $LC_ALL: nil value of $LC_COLLATE: nil value of $LC_CTYPE: nil value of $LC_MESSAGES: nil value of $LC_MONETARY: nil value of $LC_NUMERIC: nil value of $LC_TIME: nil value of $LANG: C locale-coding-system: nil default-enable-multibyte-characters: t Major mode: Emacs-Lisp Minor modes in effect: show-paren-mode: t tooltip-mode: t mouse-wheel-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t unify-8859-on-encoding-mode: t utf-translate-cjk-mode: t auto-compression-mode: t column-number-mode: t line-number-mode: t transient-mark-mode: t Recent input: M-x r e p o r t Recent messages: Warning: no fonts matching `-*-fixed-medium-r-normal-*-16-*-*-*-*-*-iso8859-1' available [2 times] ("emacs" "pscpc.el") Loading paren...done Loading /usr/share/emacs/site-lisp/auctex/tex-site.el (source)...done Loading /u/staff/toolan/.emacs.d/auxlabel.el (source)...done Loading /u/staff/toolan/.emacs.d/auxlabel.el (source)...done For information about GNU Emacs and the GNU system, type C-h C-a. Loading emacsbug... Loading regexp-opt...done Loading emacsbug...done ------------=_1225734303-14898-1--