From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Lawrence Mitchell Newsgroups: gmane.emacs.devel Subject: Re: Incorrect indentation after :name Date: Thu, 07 Jul 2005 22:47:48 +0100 Organization: funfunfun Message-ID: References: NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1120773462 21329 80.91.229.2 (7 Jul 2005 21:57:42 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 7 Jul 2005 21:57:42 +0000 (UTC) Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Jul 07 23:57:40 2005 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1DqeMW-00030Z-KV for ged-emacs-devel@m.gmane.org; Thu, 07 Jul 2005 23:56:52 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1DqeNu-00087v-CC for ged-emacs-devel@m.gmane.org; Thu, 07 Jul 2005 17:58:18 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1DqeLW-0007Xg-0q for emacs-devel@gnu.org; Thu, 07 Jul 2005 17:55:50 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1DqeLS-0007Us-3V for emacs-devel@gnu.org; Thu, 07 Jul 2005 17:55:46 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1DqeLQ-0007S9-AF for emacs-devel@gnu.org; Thu, 07 Jul 2005 17:55:44 -0400 Original-Received: from [80.91.229.2] (helo=ciao.gmane.org) by monty-python.gnu.org with esmtp (TLS-1.0:RSA_AES_128_CBC_SHA:16) (Exim 4.34) id 1DqeKx-0002Ud-VP for emacs-devel@gnu.org; Thu, 07 Jul 2005 17:55:16 -0400 Original-Received: from list by ciao.gmane.org with local (Exim 4.43) id 1DqeDs-0001qU-8P for emacs-devel@gnu.org; Thu, 07 Jul 2005 23:47:56 +0200 Original-Received: from 82-32-211-171.cable.ubr07.newt.blueyonder.co.uk ([82.32.211.171]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 07 Jul 2005 23:47:56 +0200 Original-Received: from wence by 82-32-211-171.cable.ubr07.newt.blueyonder.co.uk with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 07 Jul 2005 23:47:56 +0200 X-Injected-Via-Gmane: http://gmane.org/ Mail-Followup-To: emacs-devel@gnu.org Original-To: emacs-devel@gnu.org Original-Lines: 40 Original-X-Complaints-To: usenet@sea.gmane.org X-Gmane-NNTP-Posting-Host: 82-32-211-171.cable.ubr07.newt.blueyonder.co.uk X-No-Yes: No Mail-Copies-To: nobody User-Agent: Gnus/5.110004 (No Gnus v0.4) Emacs/22.0.50 (gnu/linux) Cancel-Lock: sha1:5zKdzLAMZn3+Z8rOXc+rwSGn5tk= 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:40593 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:40593 Drew Adams wrote: > > (put 'if 'common-lisp-indent-function > > '(nil nil &body)))) > This breaks the standard indentation of IF in lisp-mode buffers. By standard, I mean the accepted way of indenting IF in common lisp. > I don't see that (with emacs -q). What are you seeing? > I assume that you meant adding the above to lisp-mode-hook instead of > emac-lisp-mode-hook, but either way I see this, which is also the vanilla > indentation of IF in lisp-mode: Well, (put 'if 'common-lisp-indent-function '(nil nil &body)) is not mode-local, so it will affect indentation of IF in all modes that use common-lisp-indent-function to indent. Emacs lisp IF is (if TEST THEN &REST ELSE), while common lisp IF is (if TEST THEN ELSE). The conventional mode of indenting IF in Emacs lisp is: (if test then else) whereas in common lisp: (if test then else) (since only the one else-form is allowed). It is this latter indentation that is affected by the above suggestion. [...] -- Lawrence Mitchell