clojure-emacs / cider

The Clojure Interactive Development Environment that Rocks for Emacs
https://cider.mx
GNU General Public License v3.0
3.54k stars 646 forks source link

Handle negative line numbers in error messages #3688

Closed yuhan0 closed 4 months ago

yuhan0 commented 4 months ago

(partially fixes) #3687 I took the opportunity to refactor some of the rx forms and add documentation, let me know if these should be separated out or squashed.


Before submitting the PR make sure the following things have been done (and denote this by checking the relevant checkboxes):

Thanks!

If you're just starting out to hack on CIDER you might find this section of its manual extremely useful.

vemv commented 4 months ago

LGTM - great work!

Did you check that there's coverage for all code paths in

https://github.com/clojure-emacs/cider/pull/3688/commits/1378a72b3b9de7d6d11e5a54dc327f83a53b404b https://github.com/clojure-emacs/cider/pull/3688/commits/de162d58c4fc452ea04cd0aef33593783980fef4

?

yuhan0 commented 4 months ago

Yup, the existing cider-clojure-runtime-error-regexp tests cover both those cases:

Execution error (ArithmeticException) at foo/foo (src/haystack/parser.cljc:4). where either (ArithmeticException) or foo/foo may be missing