I hadn't seen this before, but I tried it out, and the parts I'm interested in are nice. The indenting is less flaky than what I was using before (comments had issues).

If you're rewriting things, though, it'd be nice to be able to customize indentation a little more. For instance, I like laying out ifs like:

    if foo
      then bar
      else baz

But I like to lay out wheres as:

    foo = ...
     where
     bar = ...

But both the indents here are based on shiftwidth, so they're tied together.

Another 'nice to have' would be some intelligent outdenting. For instance, if you type a let block right now:

    let foo = zig
        bar = zag
        in ...

That's what you'll get. It'd be nice if typing the 'in' snapped back to the let. I know it's possible to implement something like this, because the scala indentation mode I use frequently outdents when I type '=>' (which annoys the hell out of me, because it's almost never correct), but I don't know if it can be done intelligently enough to be useful (which would be important). Something to keep in mind, though.

-- Dan


On Sun, Mar 3, 2013 at 9:48 AM, dag.odenhall@gmail.com <dag.odenhall@gmail.com> wrote:
I see now in your README that you have seen vim2hs.  I'd love to hear what you disliked about it, especially given my plan to rewrite the whole thing [1]! :)

[1] https://github.com/dag/vim2hs/issues/45


On Sun, Mar 3, 2013 at 3:38 PM, dag.odenhall@gmail.com <dag.odenhall@gmail.com> wrote:
Hi

Have you seen vim2hs?

https://github.com/dag/vim2hs


On Sat, Mar 2, 2013 at 9:11 PM, Tristan Ravitch <travitch@cs.wisc.edu> wrote:
Cafe,

I've recently been playing with vim and wasn't quite satisfied with the
existing syntax highlighting and indentation, so I thought I'd try my
hand at a new Haskell mode:

https://github.com/travitch/hasksyn

It is minimal in that it doesn't provide support for running external
commands over code or anything fancy.  It just does syntax highlighting
and reasonably-smart indentation.  There is no support for literate
Haskell since supporting both with one mode is very tricky.

It might be useful to some people.  Comments, bug reports, and suggestions
welcome.

_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe




_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe