The expandSelectionToParagraph command includes (single-line) comment lines that are adjacent to the paragraph being under expansion. Conversely, when expanding a bunch of comment lines, adjacent non-comment lines are ignored by the expansion.
Is there a way to customize this behavior? Or, more generally, is there a way to define how paragraphs are identified?