aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Monnier2014-04-28 11:04:49 -0400
committerStefan Monnier2014-04-28 11:04:49 -0400
commit4f5fa75591973935b59beb0b66ffbfcbc9ee63cc (patch)
treee8efd4a5613919865db7903bf20c4b8879ffa245
parent8e554df009bc64b4e5e75028f36c397ba78596b4 (diff)
downloademacs-4f5fa75591973935b59beb0b66ffbfcbc9ee63cc.tar.gz
emacs-4f5fa75591973935b59beb0b66ffbfcbc9ee63cc.zip
* lisp/textmodes/rst.el (electric-pair-pairs): Declare.
(rst-mode): Set it. Fixes: debbugs:17131
-rw-r--r--doc/lispref/ChangeLog5
-rw-r--r--lisp/ChangeLog5
-rw-r--r--lisp/textmodes/rst.el7
3 files changed, 15 insertions, 2 deletions
diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog
index c2907cccf6e..f538b960b50 100644
--- a/doc/lispref/ChangeLog
+++ b/doc/lispref/ChangeLog
@@ -10,6 +10,11 @@
10 10
11 * internals.texi (Building Emacs): Improve indexing. 11 * internals.texi (Building Emacs): Improve indexing.
12 12
132014-04-15 Stefan Monnier <monnier@iro.umontreal.ca>
14
15 * display.texi (Overlay Properties): Reword the doc of `priority'.
16 (Finding Overlays): Document new arg of `overlays-at'.
17
132014-04-05 Glenn Morris <rgm@gnu.org> 182014-04-05 Glenn Morris <rgm@gnu.org>
14 19
15 * os.texi (Recording Input): Dribble files may contain passwords. 20 * os.texi (Recording Input): Dribble files may contain passwords.
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 94a80120ed8..e27d7b1c6a0 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,8 @@
12014-04-28 Stefan Monnier <monnier@iro.umontreal.ca>
2
3 * textmodes/rst.el (electric-pair-pairs): Declare.
4 (rst-mode): Set it (bug#17131).
5
12014-04-27 Juri Linkov <juri@jurta.org> 62014-04-27 Juri Linkov <juri@jurta.org>
2 7
3 * desktop.el (desktop-value-to-string): Let-bind `print-length' 8 * desktop.el (desktop-value-to-string): Let-bind `print-length'
diff --git a/lisp/textmodes/rst.el b/lisp/textmodes/rst.el
index d4a3438ce97..b05a5e5a7e3 100644
--- a/lisp/textmodes/rst.el
+++ b/lisp/textmodes/rst.el
@@ -784,11 +784,9 @@ This inherits from Text mode.")
784 (modify-syntax-entry ?\u2019 "." st) 784 (modify-syntax-entry ?\u2019 "." st)
785 (modify-syntax-entry ?\u201c "." st) 785 (modify-syntax-entry ?\u201c "." st)
786 (modify-syntax-entry ?\u201d "." st) 786 (modify-syntax-entry ?\u201d "." st)
787
788 st) 787 st)
789 "Syntax table used while in `rst-mode'.") 788 "Syntax table used while in `rst-mode'.")
790 789
791
792(defcustom rst-mode-hook nil 790(defcustom rst-mode-hook nil
793 "Hook run when `rst-mode' is turned on. 791 "Hook run when `rst-mode' is turned on.
794The hook for `text-mode' is run before this one." 792The hook for `text-mode' is run before this one."
@@ -799,6 +797,8 @@ The hook for `text-mode' is run before this one."
799;; Pull in variable definitions silencing byte-compiler. 797;; Pull in variable definitions silencing byte-compiler.
800(require 'newcomment) 798(require 'newcomment)
801 799
800(defvar electric-pair-pairs)
801
802;; Use rst-mode for *.rst and *.rest files. Many ReStructured-Text files 802;; Use rst-mode for *.rst and *.rest files. Many ReStructured-Text files
803;; use *.txt, but this is too generic to be set as a default. 803;; use *.txt, but this is too generic to be set as a default.
804;;;###autoload (add-to-list 'auto-mode-alist (purecopy '("\\.re?st\\'" . rst-mode))) 804;;;###autoload (add-to-list 'auto-mode-alist (purecopy '("\\.re?st\\'" . rst-mode)))
@@ -860,6 +860,9 @@ highlighting.
860 (set (make-local-variable 'uncomment-region-function) 860 (set (make-local-variable 'uncomment-region-function)
861 'rst-uncomment-region) 861 'rst-uncomment-region)
862 862
863 (set (make-local-variable 'electric-pair-pairs)
864 '((?\" . ?\") (?\* . ?\*) (?\` . ?\`)))
865
863 ;; Imenu and which function. 866 ;; Imenu and which function.
864 ;; FIXME: Check documentation of `which-function' for alternative ways to 867 ;; FIXME: Check documentation of `which-function' for alternative ways to
865 ;; determine the current function name. 868 ;; determine the current function name.