Skip to content →

Fixing paredit in the clojure REPL

By default, paredit in the Clojure slime-repl doesn’t properly handle literal vectors and maps. This little snippet of elisp seems to fix it.

(defun fix-paredit-repl ()
  (local-set-key "{" 'paredit-open-curly)
  (local-set-key "}" 'paredit-close-curly)
  (modify-syntax-entry ?\{ "(}") 
  (modify-syntax-entry ?\} "){")
  (modify-syntax-entry ?\[ "(]")
  (modify-syntax-entry ?\] ")["))

Published in Uncategorized


Leave a Reply

Your email address will not be published. Required fields are marked *