Function: cider-extract-error-info
cider-extract-error-info is a byte-compiled function defined in
cider-eval.el.
Signature
(cider-extract-error-info REGEXP MESSAGE)
Documentation
Extract error information with REGEXP against MESSAGE.
Source Code
;; Defined in ~/.emacs.d/elpa/cider-20260414.1619/cider-eval.el
(defun cider-extract-error-info (regexp message)
"Extract error information with REGEXP against MESSAGE."
(let ((file (nth 1 regexp))
(line (nth 2 regexp))
(col (nth 3 regexp))
(type (nth 4 regexp))
(pat (car regexp)))
(when (string-match pat message)
;; special processing for type (1.2) style
(setq type (if (consp type)
(or (and (car type) (match-end (car type)) 1)
(and (cdr type) (match-end (cdr type)) 0)
2)))
(list
(when file
(let ((val (match-string-no-properties file message)))
(unless (or (string= val "REPL") (string= val "NO_SOURCE_PATH")) val)))
(when line (string-to-number (match-string-no-properties line message)))
(when col
(let ((val (match-string-no-properties col message)))
(when (and val (not (string-blank-p val))) (string-to-number val))))
(aref [cider-warning-highlight-face
cider-warning-highlight-face
cider-error-highlight-face]
(or type 2))
message))))