* doc/lispref/modes.texi: Update manual.
* lisp/treesit.el (treesit-simple-indent-presets): Change prev-line to
mean bol of prev-line.
prev-line
@end example
-This anchor returns the start of the first named node on the previous
-line. This can be used for indenting an empty line.
+This anchor returns the first non-whitespace charater on the previous
+line.
@end defvar
@heading Indentation utilities
(save-excursion
(goto-char bol)
(forward-line -1)
- (skip-chars-forward " \t")
- (treesit-node-start
- (treesit-node-at (point) nil t))))))
+ (skip-chars-forward " \t")))))
"A list of presets.
These presets that can be used as MATHER and ANCHOR in
`treesit-simple-indent-rules'.
prev-line
- Find the named node on the previous line. This can be used when
- indenting an empty line: just indent like the previous node.")
+ The first non-whitespace charater on the previous line.")
(defun treesit--simple-apply (fn args)
"Apply ARGS to FN.