aboutsummaryrefslogtreecommitdiffstats
path: root/test/lisp
diff options
context:
space:
mode:
authorStefan Monnier2019-05-22 18:36:37 -0400
committerStefan Monnier2019-05-22 18:36:37 -0400
commit70839740214c5fac91536df8bd4cd7af23afa3b2 (patch)
treef52973570958cf1b4005cd620409625b9d5c2496 /test/lisp
parentdfed333b312d06b3416ebfadff544eae38313391 (diff)
downloademacs-70839740214c5fac91536df8bd4cd7af23afa3b2.tar.gz
emacs-70839740214c5fac91536df8bd4cd7af23afa3b2.zip
* lisp/textmodes/sgml-mode.el: Fix lone `>` in sgml text
(sgml--syntax-propertize-ppss):New variable and function. (sgml-syntax-propertize-rules): Use it. Don't ignore quotes not followed by a matching quote or a '>' or '<'. (sgml-syntax-propertize): Set up sgml--syntax-propertize-ppss. * test/lisp/textmodes/sgml-mode-tests.el (sgml-tests--quotes-syntax): Add test for lone '>'.
Diffstat (limited to 'test/lisp')
-rw-r--r--test/lisp/textmodes/sgml-mode-tests.el4
1 files changed, 4 insertions, 0 deletions
diff --git a/test/lisp/textmodes/sgml-mode-tests.el b/test/lisp/textmodes/sgml-mode-tests.el
index a900e8dcf22..1b8965e3440 100644
--- a/test/lisp/textmodes/sgml-mode-tests.el
+++ b/test/lisp/textmodes/sgml-mode-tests.el
@@ -165,6 +165,10 @@ The point is set to the beginning of the buffer."
165 (sgml-mode) 165 (sgml-mode)
166 (insert "a\"b <tag>c'd</tag>") 166 (insert "a\"b <tag>c'd</tag>")
167 (should (= 1 (car (syntax-ppss (1- (point-max)))))) 167 (should (= 1 (car (syntax-ppss (1- (point-max))))))
168 (should (= 0 (car (syntax-ppss (point-max)))))
169 (erase-buffer)
170 (insert "<tag>c>d</tag>")
171 (should (= 1 (car (syntax-ppss (1- (point-max))))))
168 (should (= 0 (car (syntax-ppss (point-max))))))) 172 (should (= 0 (car (syntax-ppss (point-max)))))))
169 173
170(provide 'sgml-mode-tests) 174(provide 'sgml-mode-tests)