From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: A Soare Newsgroups: gmane.emacs.devel Subject: Re: Indentation of constants in LISP Date: Tue, 20 Feb 2007 16:28:50 +0100 (CET) Message-ID: <24757263.582481171985330932.JavaMail.www@wwinf4204> Reply-To: alinsoar@voila.fr NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1171985358 26557 80.91.229.12 (20 Feb 2007 15:29:18 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 20 Feb 2007 15:29:18 +0000 (UTC) To: "Emacs Dev [emacs-devel]" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Feb 20 16:29:09 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1HJWvU-0001ZJ-IX for ged-emacs-devel@m.gmane.org; Tue, 20 Feb 2007 16:29:08 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HJWvU-0008IZ-30 for ged-emacs-devel@m.gmane.org; Tue, 20 Feb 2007 10:29:08 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1HJWvJ-0008IU-Fr for emacs-devel@gnu.org; Tue, 20 Feb 2007 10:28:57 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1HJWvF-0008IA-1T for emacs-devel@gnu.org; Tue, 20 Feb 2007 10:28:56 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HJWvE-0008I7-Sv for emacs-devel@gnu.org; Tue, 20 Feb 2007 10:28:52 -0500 Original-Received: from smtp3.voila.fr ([193.252.22.173]) by monty-python.gnu.org with esmtp (Exim 4.52) id 1HJWvE-0007Lm-FL for emacs-devel@gnu.org; Tue, 20 Feb 2007 10:28:52 -0500 Original-Received: from me-wanadoo.net (localhost [127.0.0.1]) by mwinf4202.voila.fr (SMTP Server) with ESMTP id F32C91C000B0 for ; Tue, 20 Feb 2007 16:28:50 +0100 (CET) Original-Received: from wwinf4204 (wwinf4204 [10.232.2.31]) by mwinf4202.voila.fr (SMTP Server) with ESMTP id E5FE31C000AE for ; Tue, 20 Feb 2007 16:28:50 +0100 (CET) X-ME-UUID: 20070220152850942.E5FE31C000AE@mwinf4202.voila.fr X-Originating-IP: [89.34.170.37] X-Wum-Nature: EMAIL-NATURE X-WUM-FROM: |~| X-WUM-TO: |~| X-WUM-REPLYTO: |~| X-detected-kernel: Linux 2.4-2.6 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:66555 Archived-At: I forgot to check that I am inside a LISP expression in order to make sense to align constant symbols. Here is a patch that fixes the bug just reported. Alin Soare cvs -d:pserver:anonymous@cvs.gnu.org:/sources/emacs diff -c emacs/lisp/emacs-lisp/lisp-mode.el Index: emacs/lisp/emacs-lisp/lisp-mode.el =================================================================== RCS file: /sources/emacs/emacs/lisp/emacs-lisp/lisp-mode.el,v retrieving revision 1.199 diff -c -r1.199 lisp-mode.el *** emacs/lisp/emacs-lisp/lisp-mode.el 17 Feb 2007 11:34:22 -0000 1.199 --- emacs/lisp/emacs-lisp/lisp-mode.el 20 Feb 2007 15:26:46 -0000 *************** *** 913,919 **** ;; test whether current line begins with a constant (goto-char indent-point) (skip-chars-forward " \t") ! (looking-at ":")) (let ((desired-indent (save-excursion (goto-char (1+ containing-sexp)) --- 913,920 ---- ;; test whether current line begins with a constant (goto-char indent-point) (skip-chars-forward " \t") ! (and (looking-at ":") ! containing-sexp)) (let ((desired-indent (save-excursion (goto-char (1+ containing-sexp))