lineRange(for:)
Returns the range of characters representing the line or lines containing a given range.
Declaration
func lineRange(for range: some RangeExpression<String.Index>) -> Range<Self.Index>Returns the range of characters representing the line or lines containing a given range.
func lineRange(for range: some RangeExpression<String.Index>) -> Range<Self.Index>