branch: elpa/scala-mode
commit 4014cf6893809876e0a2b82ed282b089a204ff59
Author: Evgeny Kurnevsky <[email protected]>
Commit: Evgeny Kurnevsky <[email protected]>
Don't make post-self-insert-hook local variable.
Instead use additional argument to add-hook to add local hooks. This
fixes a case when smartparens is loaded after scala-mode and adds its
hook to post-self-insert-hook which intended to be global.
---
scala-mode-map.el | 8 ++++----
scala-mode.el | 1 -
2 files changed, 4 insertions(+), 5 deletions(-)
diff --git a/scala-mode-map.el b/scala-mode-map.el
index 615c8fd..b1014e9 100644
--- a/scala-mode-map.el
+++ b/scala-mode-map.el
@@ -13,13 +13,13 @@
(defun scala-mode-map:add-self-insert-hooks ()
(add-hook 'post-self-insert-hook
- 'scala-indent:indent-on-parentheses)
+ 'scala-indent:indent-on-parentheses nil t)
(add-hook 'post-self-insert-hook
- 'scala-indent:indent-on-special-words)
+ 'scala-indent:indent-on-special-words nil t)
(add-hook 'post-self-insert-hook
- 'scala-indent:indent-on-scaladoc-asterisk)
+ 'scala-indent:indent-on-scaladoc-asterisk nil t)
(add-hook 'post-self-insert-hook
- 'scala-indent:fix-scaladoc-close))
+ 'scala-indent:fix-scaladoc-close nil t))
(defun scala-mode-map:add-remove-indent-hook ()
(add-hook 'post-command-hook
diff --git a/scala-mode.el b/scala-mode.el
index 95b5203..b525a10 100644
--- a/scala-mode.el
+++ b/scala-mode.el
@@ -106,7 +106,6 @@ When started, runs `scala-mode-hook'.
; :abbrev
(scala-mode:make-local-variables
- 'post-self-insert-hook
'syntax-propertize-function
'font-lock-syntactic-face-function
'font-lock-defaults