[darcs-users] Emacs / Vim / etc
Ketil Malde
ketil at ii.uib.no
Mon May 24 06:39:08 UTC 2004
Kenneth Knowles <kknowles at berkeley.edu> writes:
> The emacs haskell-mode seems to have really weird indenting
> rules, and I want to be very compatible with existing developers if I hack on
> it more.
I use Emacs (well, Xemacs, to be exact) and haskell-mode from
somewhere. It works fairly well (remember to press TAB repeatedly,
until you have the desired indentation!). Here's what C-h m says:
Haskell mode:
Major mode for editing Haskell programs. Last adapted for Haskell 1.4.
Blank lines separate paragraphs, comments start with `-- '.
:
`haskell-indent', Guy Lapalme
Intelligent semi-automatic indentation.
`haskell-simple-indent', Graeme E Moss and Heribert Schuetz
Simple indentation.
And further down:
Haskell-Indent minor mode (indicator Ind):
``intelligent'' Haskell indentation mode that deals with
the layout rule of Haskell. tab starts the cycle
which proposes new possibilities as long as the TAB key is pressed.
Any other key or mouse click terminates the cycle and is interpreted
except for RET which merely exits the cycle.
Other special keys are:
C-c =
inserts an =
C-c |
inserts an |
C-c o
inserts an | otherwise =
these functions also align the guards and rhs of the current definition
C-c w
inserts a where keyword
C-c .
aligns the guards and rhs of the region
C-c >
makes the region a piece of literate code in a literate script
Note: M-C-\ which applies tab for each line
of the region also works but it stops and asks for any line having more
than one possible indentation.
Use TAB to cycle until the right indentation is found and then RET to go the
next line to indent.
Invokes `haskell-indent-hook' if not nil.
-kzm
--
If I haven't seen further, it is by standing in the footprints of giants
More information about the darcs-users
mailing list