[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Change of C indentation style ('{')

From: Stefan Monnier
Subject: Re: Change of C indentation style ('{')
Date: 29 Oct 2003 19:30:12 -0500
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50

> [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".


reply via email to

[Prev in Thread] Current Thread [Next in Thread]