In some very specific scenarios, the auto indenter has almost unexplainable behavior that is very annoying. Example with haskell MultiWayIf syntax (cursor is at the "!"):
test
| test
| test = if
|!
when I press space, this turns into:
test
| test
| test = if
| !
I assume this is because it wants the pipe to be indented visually after the if
keyword, because when I press enter here:
| test = if!
it ends up here:
| test = if
!
but I do not want this behavior, and there should be some way to turn it off without turning off auto indentation entirely.
To be clear, the desired behavior would be this:
| test = if!
(enter is pressed)
| test = if
!
to conform with the four spaces for every level indentation style I have set in my .vimrc
(set tabstop=8 softtabstop=0 expandtab shiftwidth=4 smarttab
).