Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix imenu with Clojure code in string or comment
Ignore error that's thrown from `down-list` when called with point inside a string or comment. E.g. with code like: ``` (defn foo [] (let [a " (defn b [_] (bar {:bla \"bla\"}))"])) ``` `clojure-match-next-def` calls `down-list` with point inside the string and `down-list` will throw an user-error with "This command doesn't work in strings or comments". This user-error in `down-list` got introduced 2022-05-06 with https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=0b3b295776ce723885c9997ab26d57314db2a5df The `when ignore-errors` could be replaced with `unless (ppss-comment-or-string-start (syntax-ppss))` once the minimum requirement for clojure-mode is Emacs 27.
- Loading branch information