syl20bnr / spacemacs

A community-driven Emacs distribution - The best editor is neither Emacs nor Vim, it's Emacs *and* Vim!
http://spacemacs.org
GNU General Public License v3.0
23.65k stars 4.89k forks source link

Problems with brackets in haskell-mode #3734

Closed simonjantsch closed 8 years ago

simonjantsch commented 8 years ago

In haskell it is common to use anonymous function that are declared like this : \x -> x+x When specifying a function over for list or tuple type, one would write: (x,y) -> foo or [x,y,z] -> bar When doing this however the bracket matching function of spacemacs escapes the first bracket sign after \ and thus all brackets in the document that come after are highlighted.

d12frosted commented 8 years ago

Do you mean that when you hit \[ it inserts \[\] instead of \[]? If so, then you should share result of SPC h d s and also check that you don't have any funky settings for smartparens.

simonjantsch commented 8 years ago

What I mean is, if i write [x,y,z] -> [x] then all bracket signs in the expression but the first one will be highlighted

TheBB commented 8 years ago

Because of unmatched parentheses? I can't reproduce this. Works fine here.

d12frosted commented 8 years ago

The same, works fine for me

screenshot 2015-11-09 16 58 20
simonjantsch commented 8 years ago

Hm ok, im not sure why im having this but I'm using spacemacs out of the box pretty much. I am attaching a screenshot with the the file I was editing. screenshot_2015-11-09_16-25-49

d12frosted commented 8 years ago

Could you, please, share your .spacemacs so I can check it out?

StreakyCobra commented 8 years ago

It would also be nice to share the problematic part of your file (if the content is not sensible). It may help to reproduce :relaxed:

simonjantsch commented 8 years ago

Thanks for trying to solve the problem. I'm attaching my .spacemacs file .spacemacs.txt

d12frosted commented 8 years ago

Have terrible internet connection right now, so can't really reproduce it (MELPA is not available!). But when I think about your problem I remember having something very similar in JSX files. I haven't hunted that problem, that's why I haven't reported it yet.

In any case, with my setup I don't see this problem in haskell file. Will try your spacemacs file later when I have better connection.

d12frosted commented 8 years ago

Still can't reproduce. Can you verify that it still happen with latest packages and Spacemacs?

simonjantsch commented 8 years ago

I have not had this problem for a while now, so I'm closing the thread.