vim2hs icon indicating copy to clipboard operation
vim2hs copied to clipboard

Folding for individual cabal fields in Cabal files

Open UnkindPartition opened this issue 12 years ago • 1 comments

Would it be possible to add folds for individual cabal fields? Some of them can get rather long, see e.g. https://github.com/haskell-suite/haskell-names/blob/master/haskell-names.cabal

UnkindPartition avatar Sep 29 '13 13:09 UnkindPartition

Should be quite doable. In the vim-cabal part of the rewrite (#45) I'm already defining field values as syntax regions across lines, to make sure it's not confused by things like colons in description, say, and in theory in that implementation it should be a simple matter of setting the fold option on the region. However, syntax folding is slow and expensive (likely the primary reason people are reporting sluggishness from vim2hs) so I want to avoid that in the rewrite and use expression folding instead, but it shouldn't be too hard with that either.

dag avatar Sep 29 '13 16:09 dag