Closed RblSb closed 5 years ago
The folding start marker “wins” so TextMate currently sees the middle line as a start marker and allows folding the latter block.
If this is undesired, one could update the pattern to specifically handle the case where a line is both a start and stop marker, and not match on such lines.
Closing issue as this is not considered a bug in TextMate.
Every language bundle have this folding:
As a result, folding does not work as required, if I understand correctly, because of the conflict foldingStartMarker and foldingStopMarker on one line.
I would suggest, if they are both on the same line, completely ignore the existence of any of them on this line.
If this solution breaks any bundles, maybe you know the regex fix for this case? Tested with:
{foldingStartMarker = '\{\s*(//.*)?$|\[\s*(//.*)?$|\(\s*(//.*)?$'; foldingStopMarker = '^\s*\}|^\s*\]|^\s*\)'; }