Function: nrepl--bdecode-error
nrepl--bdecode-error is a byte-compiled function defined in
nrepl-bencode.el.
Signature
(nrepl--bdecode-error)
Documentation
Handle an unrecoverable bencode parse failure.
Log the offending position and the remaining buffer to the nREPL error buffer, surface a notification to the user, and return an :end cons that drains the rest of the buffer so the decoder loop terminates.
Source Code
;; Defined in ~/.emacs.d/elpa/cider-20261106.1225/nrepl-bencode.el
(defun nrepl--bdecode-error ()
"Handle an unrecoverable bencode parse failure.
Log the offending position and the remaining buffer to the nREPL error
buffer, surface a notification to the user, and return an `:end' cons
that drains the rest of the buffer so the decoder loop terminates."
(message "Invalid bencode message detected. See the %s buffer for details."
nrepl-error-buffer-name)
(nrepl-log-error
(format "Decoder error at position %d (`%s'):"
(point) (buffer-substring (point) (min (+ (point) 10) (point-max)))))
(nrepl-log-error (buffer-string))
(ding)
;; Drain the buffer so `nrepl-bdecode' exits its loop with clean queue state.
(goto-char (point-max))
(cons :end nil))