My gut feeling is that there is some mis-interaction between withResource and findByExtension. I tried to create a simpler test case using those methods, but couldn't seem to exercise the bug. I thought this diff was at least small enough that it could be a usable starting point!
For details, look at this commit: https://github.com/chreekat/vim-haskell-syntax/commit/77519b477af09ad469fa66dc85e294ee3017e133
My gut feeling is that there is some mis-interaction between withResource and findByExtension. I tried to create a simpler test case using those methods, but couldn't seem to exercise the bug. I thought this diff was at least small enough that it could be a usable starting point!