expez / evil-smartparens

Evil integration for Smartparens
GNU General Public License v3.0
134 stars 17 forks source link

sp-region-ok gives nil on haskell pragmas #26

Closed unhammer closed 8 years ago

unhammer commented 8 years ago

A haskell pragma looks like {-# LANGUAGE ScopedTypeVariables #-} and smartparens-haskell sets "{-#" "#-}" as a pair in haskell-mode.

But any evil-smartparens op on these gives "That would leave the buffer unbalanced", which seems to be because sp-region-ok (used by e.g. evil-sp--new-ending) gives nil on these haskell pragmas.

I see sp-region-ok is only used in one place by smartparens itself, and sp-kill-sexp in fact works fine here, while evil-sp-delete errors out here.

expez commented 8 years ago

Most likely I'll be the one fixing this anyway, but if you've narrowed the bug down to sp-region-ok then the issue should probably be opened against the smartparens repo.

I really appreciate the legwork you did prior to opening this issue. It's certainly a lot quicker to fix when the cause is known! :)

expez commented 8 years ago

https://github.com/Fuco1/smartparens/commit/7aae97cc99ba45729d91f69656ca3b0fa6f2ccdb