Fix suppression handling when 'formatter:on' not properly specified by paul-dingemans · Pull Request #2719 · ktlint/ktlint (original) (raw)

Description

Fix suppression handling when 'formatter:on' not properly specified

If the 'formatter:on' tag is not specified in the same scope as the 'formatter:off' tag, then the IndentationRule might throw an exception as the IndentationContextStack is not properly cleaned.

Also, cleaned up of CommentSuppressionHint.EOL type as it was not used since replacing the EOL suppression hints in 1.0 release.

Closes #2695

Checklist

Before submitting the PR, please check following (checks which are not relevant may be ignored):

Documentation is updated. See difference between snapshot and release documentation