Skip to content

Indentation is broken #890

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
ghost opened this issue Sep 20, 2015 · 2 comments
Closed

Indentation is broken #890

ghost opened this issue Sep 20, 2015 · 2 comments

Comments

@ghost
Copy link

ghost commented Sep 20, 2015

I have following code:

sumtorial :: Integer -> Integer
sumtorial 0 = 0
sumtorial n = n + sumtorial (n-1)

hailstone :: Integer -> Integer
hailstone n
  | mod n 2 == 0 = div n 2
  | otherwise    = 3*n + 1

sumPair :: (Int,Int) -> Int
sumPair (x,y) = x + y

I have in my ~/.emacs following line:
(add-hook 'haskell-mode-hook 'turn-on-haskell-indentation)

And now, when I use tab at line 7, the indentation of 2 spaces gets f*cked up to 4 spaces. When i press return at the end of line 8, im indented at the new line by 19 characters.

But now the funny thing is, when I start emacs with -q and do M x turn-on-haskell-indentation then, at least the problem in line 7, is away.

So how to fix my settings?

@gracjan
Copy link
Contributor

gracjan commented Sep 20, 2015 via email

@ghost
Copy link
Author

ghost commented Sep 20, 2015

Oh. There was a bug. I reinstalled haskell-mode now it works. Thanks :D

@gracjan gracjan closed this as completed Sep 23, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant