Skip to content

Commit 3dcce71

Browse files
committed
Merge pull request #1384 from juergenhoetzel/master
Handle Windows filenames in cider-compilation-regex
2 parents c642f3a + 0da920d commit 3dcce71

File tree

3 files changed

+10
-1
lines changed

3 files changed

+10
-1
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@
5050

5151
### Bugs fixed
5252

53+
* [#1384](https://github.com/clojure-emacs/cider/pull/1384): Match windows file names in `cider-compilation-regexp`.
5354
* [#1252](https://github.com/clojure-emacs/cider/issues/1252) `cider-repl-clear-buffer` stops working in certain circumstances.
5455
* [#1164](https://github.com/clojure-emacs/cider/pull/1164): Fix an error in `cider-browse-ns--doc-at-point`.
5556
* [#1189](https://github.com/clojure-emacs/cider/issues/1189): Don't show result from automatic ns form evaluation.

cider-interaction.el

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -811,7 +811,7 @@ It delegates the actual error content to the eval or op handler."
811811
(cider-default-err-eval-handler)))
812812

813813
(defvar cider-compilation-regexp
814-
'("\\(?:.*\\(warning, \\)\\|.*?\\(, compiling\\):(\\)\\([^:]*\\):\\([[:digit:]]+\\)\\(?::\\([[:digit:]]+\\)\\)?\\(\\(?: - \\(.*\\)\\)\\|)\\)" 3 4 5 (1))
814+
'("\\(?:.*\\(warning, \\)\\|.*?\\(, compiling\\):(\\)\\(.*?\\):\\([[:digit:]]+\\)\\(?::\\([[:digit:]]+\\)\\)?\\(\\(?: - \\(.*\\)\\)\\|)\\)" 3 4 5 (1))
815815
"Specifications for matching errors and warnings in Clojure stacktraces.
816816
See `compilation-error-regexp-alist' for help on their format.")
817817

test/cider-error-parsing-tests.el

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,14 @@
88
(should (equal (nth 2 info) nil))
99
(should (equal (nth 3 info) 'cider-error-highlight-face)))))
1010

11+
(ert-deftest test-cider-extract-error-info-14-windows ()
12+
(let ((message "CompilerException java.lang.RuntimeException: Unable to resolve symbol: dummy in this context, compiling:(c:\\some\\test\\file\\core.clj:31)"))
13+
(let ((info (cider-extract-error-info cider-compilation-regexp message)))
14+
(should (string= (nth 0 info) "c:\\some\\test\\file\\core.clj"))
15+
(should (= (nth 1 info) 31))
16+
(should (equal (nth 2 info) nil))
17+
(should (equal (nth 3 info) 'cider-error-highlight-face)))))
18+
1119
(ert-deftest test-cider-extract-error-info-14-no-file ()
1220
(let ((message "CompilerException java.lang.RuntimeException: Unable to resolve symbol: dummy in this context, compiling:(NO_SOURCE_PATH:31)"))
1321
(let ((info (cider-extract-error-info cider-compilation-regexp message)))

0 commit comments

Comments
 (0)