From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: don@donarmstrong.com (Emacs bug Tracking System) Newsgroups: gmane.emacs.bugs Subject: bug#1012: marked as done (calculate-lisp-indent) Date: Wed, 24 Sep 2008 01:30:04 -0700 Message-ID: References: <48D9F761.1000805@gmx.at> <48D68650.1040907@sauermann-consulting.de> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="----------=_1222245004-9317-0" X-Trace: ger.gmane.org 1222246266 2191 80.91.229.12 (24 Sep 2008 08:51:06 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 24 Sep 2008 08:51:06 +0000 (UTC) To: martin rudalics Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Sep 24 10:52:01 2008 connect(): Connection refused Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1KiQ5g-000378-H9 for geb-bug-gnu-emacs@m.gmane.org; Wed, 24 Sep 2008 10:51:21 +0200 Original-Received: from localhost ([127.0.0.1]:50774 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KiQ4e-0003Ki-90 for geb-bug-gnu-emacs@m.gmane.org; Wed, 24 Sep 2008 04:50:16 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KiQ4O-0003GW-CK for bug-gnu-emacs@gnu.org; Wed, 24 Sep 2008 04:50:00 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KiQ4N-0003GA-Rm for bug-gnu-emacs@gnu.org; Wed, 24 Sep 2008 04:49:59 -0400 Original-Received: from [199.232.76.173] (port=56469 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KiQ4N-0003G6-FU for bug-gnu-emacs@gnu.org; Wed, 24 Sep 2008 04:49:59 -0400 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:47678) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KiQ4M-0000DA-Ux for bug-gnu-emacs@gnu.org; Wed, 24 Sep 2008 04:49:59 -0400 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m8O8nr90013878; Wed, 24 Sep 2008 01:49:54 -0700 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.13.8/8.13.8/Submit) id m8O8U4Ap009358; Wed, 24 Sep 2008 01:30:04 -0700 X-Mailer: MIME-tools 5.420 (Entity 5.420) X-Loop: don@donarmstrong.com X-Emacs-PR-Message: closed 1012 X-Emacs-PR-Package: emacs X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:20721 Archived-At: This is a multi-part message in MIME format... ------------=_1222245004-9317-0 Content-Disposition: inline Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Your message dated Wed, 24 Sep 2008 10:16:33 +0200 with message-id <48D9F761.1000805@gmx.at> and subject line Re: bug#1012: calculate-lisp-indent has caused the Emacs bug report #1012, regarding calculate-lisp-indent to be marked as done. This means that you claim that the problem has been dealt with. If this is not the case it is now your responsibility to reopen the bug report if necessary, and/or fix the problem forthwith. (NB: If you are a system administrator and have no idea what this message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact don@donarmstrong.com immediately.) --=20 1012: http://emacsbugs.donarmstrong.com/cgi-bin/bugreport.cgi?bug=3D1012 Emacs Bug Tracking System Contact don@donarmstrong.com with problems ------------=_1222245004-9317-0 Content-Type: message/rfc822 Content-Disposition: inline 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=0.1 required=4.0 tests=BAYES_00,FOURLA,MIXEDBDN, MURPHY_DRUGS_REL8,ONEWORD autolearn=no version=3.2.3-bugs.debian.org_2005_01_02 Received: (at submit) by emacsbugs.donarmstrong.com; 21 Sep 2008 17:37:38 +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 m8LHbVfl022425 for ; Sun, 21 Sep 2008 10:37:34 -0700 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KhSsE-00080Q-Pj for bug-gnu-emacs@gnu.org; Sun, 21 Sep 2008 13:37:30 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KhSsD-00080A-Ho for bug-gnu-emacs@gnu.org; Sun, 21 Sep 2008 13:37:30 -0400 Received: from [199.232.76.173] (port=36735 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KhSsD-0007zz-6J for bug-gnu-emacs@gnu.org; Sun, 21 Sep 2008 13:37:29 -0400 Received: from smtp1.bitpoint.de ([80.67.224.9]:52803) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KhSsC-0006ud-1I for bug-gnu-emacs@gnu.org; Sun, 21 Sep 2008 13:37:28 -0400 Received: from p5499706c.dip.t-dialin.net ([84.153.112.108]) by smtp1.bitpoint.de with esmtpa (Exim 4.67 (FreeBSD)) (envelope-from ) id 1KhSs1-0009FM-1z for bug-gnu-emacs@gnu.org; Sun, 21 Sep 2008 19:37:17 +0200 Message-ID: <48D68650.1040907@sauermann-consulting.de> Date: Sun, 21 Sep 2008 19:37:20 +0200 From: Markus Sauermann User-Agent: Thunderbird 2.0.0.16 (Windows/20080708) MIME-Version: 1.0 To: bug-gnu-emacs@gnu.org Subject: calculate-lisp-indent X-Enigmail-Version: 0.95.7 Content-Type: multipart/mixed; boundary="------------070203090003050805040103" X-detected-operating-system: by monty-python.gnu.org: FreeBSD 6.x (1) This is a multi-part message in MIME format. --------------070203090003050805040103 Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: quoted-printable X-MIME-Autoconverted: from 8bit to quoted-printable by rzlab.ucr.edu id m8O8nr90013878 Hello, I found a bug concerning the function calculate-lisp-indent in lisp-mode.= el. It is triggered in the following scenarios (-!- marks the point): ---begin scenario 1 buffer *scratch*--- (,@foo :bar)-!- ---end scenario 1 buffer *scratch*--- ---begin scenario 2 buffer *scratch*--- ( foo :bar)-!- ---end scenario 2 buffer *scratch*--- Using (bound to the function lisp-indent-line) triggers the following error in both scenarios: ---begin error--- forward-sexp: Scan error: "Containing expression ends prematurely", 192, = 192 ---end error--- I traced this bug to the function calculate-lisp-indent. As far as I understand the code, the characters ",@" in scenario 1 and the spaces in scenario 2 are not treated correctly. In this E-Mail I included a patch, that solves the problems for me, and was created with the command mhoram@revelstone:~/emacs/trunk/emacs/lisp$ cvs diff -c > ~/emacs-bugreport.txt The patch works for scenario 1 by an additional call of the (backward-prefix-chars) function, which sets point back to the beginning of ",@". For scenario 2 the addition of "\\|([ \t]+" solves the problem, by not entering the while-loop (and thus calling the function (forward-sexp -1)), if there are only spaces between the "(" and the first object. Regards, Markus Sauermann In GNU Emacs 22.3.1 (i386-mingw-nt6.0.6001) of 2008-09-06 on SOFT-MJASON Windowing system distributor `Microsoft Corp.', version 6.0.6001 configured using `configure --with-gcc (3.4)' 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: DEU locale-coding-system: cp1252 default-enable-multibyte-characters: t Major mode: Lisp Interaction Minor modes in effect: encoded-kbd-mode: t tooltip-mode: t tool-bar-mode: t mouse-wheel-mode: t menu-bar-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 line-number-mode: t Recent input: q ( , @ f o o : b a r ) M-x r e p o r t Recent messages: ("D:\\Uninstalled\\emacs-22.3\\bin\\emacs.exe" "-q") Loading encoded-kb...done For information about GNU Emacs and the GNU system, type C-h C-a. forward-sexp: Scan error: "Containing expression ends prematurely", 192, = 192 Loading emacsbug... Loading regexp-opt...done Loading emacsbug...done --=20 Markus Sauermann E-Mail: info@sauermann-consulting.de Clemensstr. 55 Rgb. Web: http://www.sauermann-consulting.de 80803 M=FCnchen Tel: 089/337707, 0179/9879005, Fax: 089/38476434 --------------070203090003050805040103 Content-Type: text/plain; name="emacs-bugreport.txt" Content-Disposition: inline; filename="emacs-bugreport.txt" Content-Transfer-Encoding: quoted-printable X-MIME-Autoconverted: from 8bit to quoted-printable by rzlab.ucr.edu id m8O8nr90013878 Index: ChangeLog =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /sources/emacs/emacs/lisp/ChangeLog,v retrieving revision 1.14493 diff -c -r1.14493 ChangeLog *** ChangeLog 20 Sep 2008 22:09:39 -0000 1.14493 --- ChangeLog 21 Sep 2008 17:08:59 -0000 *************** *** 1,3 **** --- 1,9 ---- + 2008-09-21 Markus Sauermann +=20 + * emacs-lisp/lisp-mode.el (calculate-lisp-indent): + Fix indentation problem with keyword symbols when a list starts + with ,@ or spaces. +=20 2008-09-20 Vincent Bela=C3=AFche =20 * calc/calc-vec.el (calcFunc-venum): Properly handle intervals. Index: emacs-lisp/lisp-mode.el =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /sources/emacs/emacs/lisp/emacs-lisp/lisp-mode.el,v retrieving revision 1.226 diff -c -r1.226 lisp-mode.el *** emacs-lisp/lisp-mode.el 20 Sep 2008 21:54:44 -0000 1.226 --- emacs-lisp/lisp-mode.el 21 Sep 2008 17:09:04 -0000 *************** *** 1027,1033 **** ;; where it begins, so find that one, instead. (save-excursion (goto-char calculate-lisp-indent-last-sexp) ! (while (and (not (looking-back "^[ \t]*")) (or (not containing-sexp) (< (1+ containing-sexp) (point))= )) (forward-sexp -1) --- 1027,1034 ---- ;; where it begins, so find that one, instead. (save-excursion (goto-char calculate-lisp-indent-last-sexp) ! (backward-prefix-chars) ! (while (and (not (looking-back "^[ \t]*\\|([ \t]= +")) (or (not containing-sexp) (< (1+ containing-sexp) (point))= )) (forward-sexp -1) --------------070203090003050805040103-- ------------=_1222245004-9317-0 Content-Type: message/rfc822 Content-Disposition: inline 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.6 required=4.0 tests=AWL,BAYES_00,HAS_BUG_NUMBER, MURPHY_DRUGS_REL8 autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: (at 1012-done) by emacsbugs.donarmstrong.com; 24 Sep 2008 08:23:21 +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 m8O8NEk2007982 for <1012-done@emacsbugs.donarmstrong.com>; Wed, 24 Sep 2008 01:23:15 -0700 Received: (qmail invoked by alias); 24 Sep 2008 08:23:08 -0000 Received: from 62-47-41-49.adsl.highway.telekom.at (EHLO [62.47.41.49]) [62.47.41.49] by mail.gmx.net (mp042) with SMTP; 24 Sep 2008 10:23:08 +0200 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX18qZ/kSu3Yqxwog3yXQ6TEu5RqmMi1EKFQsP+HgJf XIDyDRYAn8HM+k Message-ID: <48D9F761.1000805@gmx.at> Date: Wed, 24 Sep 2008 10:16:33 +0200 From: martin rudalics User-Agent: Thunderbird 2.0.0.16 (Windows/20080708) MIME-Version: 1.0 To: 1012-done@emacsbugs.donarmstrong.com CC: Markus Sauermann Subject: Re: bug#1012: calculate-lisp-indent References: <48D895C4.6020901@gmx.at> In-Reply-To: <48D895C4.6020901@gmx.at> Content-Type: text/plain; charset=ISO-8859-15; format=flowed X-Y-GMX-Trusted: 0 X-FuHaFi: 0.73 Content-Transfer-Encoding: 7bit Fixed as: 2008-09-23 Markus Sauermann (tiny change) * emacs-lisp/emacslisp-mode.el (calculate-lisp-indent): Fix indentation problem with keyword symbols when a list starts with ,@ or spaces. (Bug#1012) Thanks for the patch, martin ------------=_1222245004-9317-0--