Skip to content

Commit ff570fc

Browse files
committed
Extract Clojure compilation error handling into cider-compilation.el
Move the ~500-line compilation-error handling subsystem out of cider-eval.el into its own module. Sits below cider-eval.el in the layering: turns nREPL eval-error / stacktrace responses into the *cider-error* buffer, source overlays, and inline messages. Moved: - The user-tunable knobs: cider-show-error-buffer, cider-auto-jump-to-error, cider-auto-select-error-buffer, cider-error-highlight-face, cider-warning-highlight-face, cider-inline-error-message-function, cider-clojure-compilation-error-phases (plus its default value). - The compilation/error parsing and rendering subsystem: cider-clojure-compilation-regexp, cider-module-info-regexp, cider-compilation-regexp, cider-extract-error-info, cider-handle-compilation-errors, cider--display-error-unobtrusively, cider--handle-stacktrace-response, cider--analyze-last-stacktrace, cider-default-err-{handler,op-handler,eval-handler,eval-print-handler}, cider--handle-err-eval-response, cider--clojure-1.10-{error,location}, cider--clojure-warning, cider--render-stacktrace-causes, cider--find-last-error-location, cider--goto-expression-start, cider--show-error-buffer-p, cider-new-error-buffer, cider-emit-into-color-buffer, cider-jump-to-compilation-error, cider-find-property. - Highlight-clearing helpers from the old "Utilities" section (cider--clear-compilation-highlights, cider-clear-compilation-highlights, cider--quit-error-window). - cider--shorten-error-message (only used as the default of cider-inline-error-message-function). cider-eval.el requires cider-compilation and drops compile from its requires (no longer needed there). Two consumers that don't go through cider-eval (cider-log.el and cider-test.el) add an explicit require for cider-auto-select-error-buffer. The new file forward-declares only `cider-repl-mode' (used in a derived-mode-p check); no other shims needed. cider-eval.el drops from 1650 to 1156 lines.
1 parent 00ee39e commit ff570fc

4 files changed

Lines changed: 565 additions & 495 deletions

File tree

0 commit comments

Comments
 (0)