(This question applies to any language -- Python and Haskell are examples -- that lets you organize code via indentation instead of parentheses. Such languages are more readable and take less time to write, at least according to people like myself.)
The code I'm reading has some big indented passages that don't fit on one screen, or sometimes ten screens (I use a big font), and it'd be much easier to see what was going on if I could go to some line and press a keyboard shortcut to hide everything that follows until the next line that starts at the same position or farther left.
I've found a number of code-folding packages for Emacs, but all seem to suffer at least one of these problems:
- they've got few features and appear to be ill-maintained
- they rely on explicit brackets (such as
{{{ ... }}}
) to know where - they let you fold top-level code, but they won't let you fold from an arbitrary inner level
- they let you fold inner levels, but only in parallel -- that is, if you fold one of the level-2 items in a level-1 block, you have to fold the rest also.