diff options
| author | tslil clingman <> | 2020-01-19 21:46:29 -0800 |
|---|---|---|
| committer | tslil clingman <> | 2020-01-19 21:46:29 -0800 |
| commit | 5553be28d41cefc72300be7160b5202fd297537b (patch) | |
| tree | 0ae58af677c9a2435012377db176defab1795061 | |
| parent | e40ee7ba4cdab6f26000f91393017d8a02f34978 (diff) | |
Fixed electric-pair on ' in rust-mode only
| -rw-r--r-- | emacs/inits/20-programming.el | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/emacs/inits/20-programming.el b/emacs/inits/20-programming.el index f48d419..a072e22 100644 --- a/emacs/inits/20-programming.el +++ b/emacs/inits/20-programming.el @@ -1,4 +1,4 @@ -;; Time-stamp: <2020-01-12 11:46:11 (tslil@bison)> +;; Time-stamp: <2020-01-19 21:42:02 (tslil@bison)> ;; ----------------------------------------------------------------------------- ;; General setup @@ -54,11 +54,7 @@ electric-pair-skip-self 'electric-pair-default-skip-self electric-pair-preserve-balance t electric-pair-skip-whitespace t - electric-pair-pairs '((?\" . ?\") - (?' . ?') - (?\( . ?\)) - (?< . ?>) - (?\[ . ?\])))) + electric-pair-inhibit-predicate 'electric-pair-default-inhibit)) (use-package js-comint :ensure t @@ -165,6 +161,9 @@ ("C-c C-c" . rust-compile) ("C-c C-r" . rust-run)) :hook (rust-mode . (lambda () + ;; For some reason this is not automatic + (setq-local electric-pair-pairs + (cons '(?' . ?') electric-pair-pairs)) (flycheck-mode) (flycheck-rust-setup))) :config |
