Initial function and settings.
Supporting function, IndentLevel to return the indent level of given line.

Useful for determining what the fold level should be, since most times the fold level should be the same as the
indent level.
Non-blank lines have a fold level equal to their indent level.
Empty lines are folded same as the one before them so they continue the fold.
Fold consectutive `use` statements that aren't indented (i.e. namespace alias/import, not traits in a class declaration)
Supporting function FindNextDelimiter() to find the specified delimiter.

Search from specified line number.
Search for specified delimiter, any regex, really.
Search in direction specified, 'f'orward or 'b'ackward.
Optionally limit search to a number of lines, otherwise search to start or end of file.
Fold classes and functions.
Supporting function FindPrevClassFunc()
Increase the fold level of multi-line class implements lists and function argument lists by 1.

This allows those lists to be additionally folded inside the class' or function's fold.
Fold multi-line comment (/* */) regions.
Fold if/elseif/else and try/catch/finally.

Does not properly fold if/elseif statements that have conditions spanning multiple lines.
Fold pairs of `()` and `[]`.

This includes (but not limited to):
 * multi-line conditionals for `if`, `elseif`, `for`, `while`, etc.
 * Arrays declared with `array()`
 * Arrays declared with `[]`
 * Function calls whose arguments span multiple lines
Closure arguments and `use` variables are in separate folds when both are on multiple lines.