Scan file content for all section marker pairs and return their metadata.
Unclosed sections are silently skipped (useful for discovery across many files).
Get the comment style for a file based on its extension.
If a config is provided, language-specific overrides take priority,
then global overrides, then the hardcoded defaults.
Split a section ID into (group, variant) parts using the first : as separator.
Solo IDs (no colon) return (id, None); variant IDs return (group, Some(variant)).
Toggle comments using multi-line/block comment delimiters.
For each merged range, wraps the content in start/end delimiters (commenting)
or strips them (uncommenting). Force mode works the same as single-line.
Run validation on already-scanned sections grouped by file (PRD §0.14.3).
pair_only = true skips the pair-mismatch check on solos (i.e. when invoked
with --check --pair, a 3-variant group is still flagged).