From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.cc-mode.general,gmane.emacs.devel Subject: Re: Change of C indentation style ('{') Date: 29 Oct 2003 19:30:12 -0500 Sender: cc-mode-help-admin@lists.sourceforge.net Message-ID: References: <200310230109.KAA09465@etlken.m17n.org> <5bhe1zy4z8.fsf@lister.roxen.com> <5b1xt1l6si.fsf@lister.roxen.com> <5bn0bm7o7n.fsf@lister.roxen.com> <5boevzsv11.fsf@lister.roxen.com> <20031029214141.GA30336@fencepost> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1067474164 27159 80.91.224.253 (30 Oct 2003 00:36:04 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 30 Oct 2003 00:36:04 +0000 (UTC) Cc: Martin Stjernholm , bug-cc-mode@gnu.org, emacs-devel@gnu.org, rms@gnu.org, handa@m17n.org Original-X-From: cc-mode-help-admin@lists.sourceforge.net Thu Oct 30 01:35:59 2003 Return-path: Original-Received: from lists.sourceforge.net ([66.35.250.206] helo=sc8-sf-list2.sourceforge.net) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1AF0n9-0002BJ-00 for ; Thu, 30 Oct 2003 01:35:59 +0100 Original-Received: from sc8-sf-list1-b.sourceforge.net ([10.3.1.13] helo=sc8-sf-list1.sourceforge.net) by sc8-sf-list2.sourceforge.net with esmtp (Exim 3.31-VA-mm2 #1 (Debian)) id 1AF0mo-0002YY-00; Wed, 29 Oct 2003 16:35:38 -0800 Original-Received: from sc8-sf-mx1-b.sourceforge.net ([10.3.1.11] helo=sc8-sf-mx1.sourceforge.net) by sc8-sf-list1.sourceforge.net with esmtp (Cipher TLSv1:DES-CBC3-SHA:168) (Exim 3.31-VA-mm2 #1 (Debian)) id 1AF0lQ-0005zv-00 for ; Wed, 29 Oct 2003 16:34:12 -0800 Original-Received: from fencepost.gnu.org ([199.232.76.164]) by sc8-sf-mx1.sourceforge.net with esmtp (TLSv1:DES-CBC3-SHA:168) (Exim 4.24) id 1AF0lP-0003UJ-JG for cc-mode-help@lists.sourceforge.net; Wed, 29 Oct 2003 16:34:11 -0800 Original-Received: from monty-python.gnu.org ([199.232.76.173]) by fencepost.gnu.org with esmtp (Exim 4.24) id 1AF0gE-00025M-DD for bug-cc-mode@gnu.org; Wed, 29 Oct 2003 19:28:50 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.24) id 1AF0kX-0007O6-49 for bug-cc-mode@gnu.org; Wed, 29 Oct 2003 19:33:48 -0500 Original-Received: from [132.204.24.67] (helo=mercure.iro.umontreal.ca) by monty-python.gnu.org with esmtp (Exim 4.24) id 1AF0ih-0005pb-6B; Wed, 29 Oct 2003 19:31:23 -0500 Original-Received: from vor.iro.umontreal.ca (vor.iro.umontreal.ca [132.204.24.42]) by mercure.iro.umontreal.ca (8.12.9/8.12.9) with ESMTP id h9U0UCnR019262; Wed, 29 Oct 2003 19:30:13 -0500 Original-Received: by vor.iro.umontreal.ca (Postfix, from userid 20848) id 7AD303C63E; Wed, 29 Oct 2003 19:30:12 -0500 (EST) Original-To: Miles Bader In-Reply-To: <20031029214141.GA30336@fencepost> Original-Lines: 20 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50 X-DIRO-MailScanner: Found to be clean X-Spam-Score: 0.0 (/) Errors-To: cc-mode-help-admin@lists.sourceforge.net X-BeenThere: cc-mode-help@lists.sourceforge.net X-Mailman-Version: 2.0.9-sf.net Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Bug reports, feature requests, and general talk about CC Mode. List-Unsubscribe: , List-Archive: X-Original-Date: 29 Oct 2003 19:30:12 -0500 Xref: main.gmane.org gmane.emacs.cc-mode.general:975 gmane.emacs.devel:17597 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:17597 > [Not that I think requring `declarations' of macros is a very workable idea > -- people wouldn't do it 99% of the time] Not only people wouldn't do it, but manually fixing a slightly incorrect indentation is pretty easy and is cannot in general be avoided. For people who want a full-reindent of the code to correctly preserve the manually-indented parts of the code, I had suggested that we could support special tags in comments to mean "don't touch this". In my sml-mode, I used (*fixindent*) as the special tag. This is needed because it is very common in SML to want to indent some parts of code specially: typically one function acts as a module but the author does not want to indent everything within it by the customary 2 or 3 chars (SML code already suffers from the tendency to indent too much). The mode has no way to tell that this function is different from others, so the user has to reindent a few key lines manually. The `fixindent' trick allows them to make the whole file "reindent safe". Stefan ------------------------------------------------------- This SF.net email is sponsored by: SF.net Giveback Program. Does SourceForge.net help you be more productive? Does it help you create better code? SHARE THE LOVE, and help us help YOU! Click Here: http://sourceforge.net/donate/