Skip to content

Commit 64faab4

Browse files
Indentation: Handle first line after opening bracket
Fixes: "End position is smaller than start position" error.
1 parent 0810010 commit 64faab4

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

fsharp-mode-structure.el

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -766,6 +766,10 @@ dedenting."
766766
(open-bracket-pos (fsharp-nesting-level)))
767767

768768
(cond
769+
((and open-bracket-pos (eq (and (looking-back "[[:space:]\n\r]+" nil t)
770+
(match-beginning 0))
771+
(1+ open-bracket-pos)))
772+
fsharp-indent-offset)
769773
;; Continuation Lines
770774
((fsharp-continuation-line-p)
771775
(if open-bracket-pos

0 commit comments

Comments
 (0)