Function: helpful--outer-sexp
helpful--outer-sexp is a byte-compiled function defined in helpful.el.
Signature
(helpful--outer-sexp BUF POS)
Documentation
Find position POS in BUF, and return the name of the outer sexp, along with its position.
Moves point in BUF.
Source Code
;; Defined in ~/.emacs.d/elpa/helpful-20250408.334/helpful.el
(defun helpful--outer-sexp (buf pos)
"Find position POS in BUF, and return the name of the outer sexp,
along with its position.
Moves point in BUF."
(with-current-buffer buf
(goto-char pos)
(let* ((ppss (syntax-ppss))
(outer-sexp-posns (nth 9 ppss)))
(when outer-sexp-posns
(goto-char (car outer-sexp-posns))))
(list (point) (-take 2 (read buf)))))