diff options
author | Noam Postavsky <npostavs@gmail.com> | 2019-06-05 19:24:58 -0400 |
---|---|---|
committer | Noam Postavsky <npostavs@gmail.com> | 2019-06-05 20:30:23 -0400 |
commit | da118e6a7c5d1d1d07fd186b0ae5e60340ac9dca (patch) | |
tree | 932423461bb4df20c46b50ffbf0c96c74ddf49d8 /lisp/nxml/nxml-rap.el | |
parent | 610fb73ab6d7a22b722f523d6ebc4aa8fa1db7c9 (diff) | |
download | emacs-da118e6a7c5d1d1d07fd186b0ae5e60340ac9dca.tar.gz |
Keep nxml prolog updated via syntax-propertize
Instead of using after-change-functions. Also, stop consulting
nxml-prolog-regions during syntax-propertize. It turns out the
problems fixed by using prolog information are actually due to using
the wrong syntax table during propertizing. This was fixed in
2019-06-04 "* lisp/emacs-lisp/syntax.el: Use syntax-ppss-table for
syntax-propertize." so consulting the prolog data is no longer needed.
* lisp/nxml/nxml-rap.el (nxml-maybe-rescan-prolog): Remove.
* lisp/nxml/nxml-mode.el (nxml-mode): Stop using it.
(nxml-syntax-propertize): Don't use nxml-prolog-regions, just call
nxml-scan-prolog if needed before delegating to
sgml-syntax-propertize.
* test/lisp/nxml/nxml-mode-tests.el (nxml-mode-edit-prolog): New test.
Diffstat (limited to 'lisp/nxml/nxml-rap.el')
-rw-r--r-- | lisp/nxml/nxml-rap.el | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/lisp/nxml/nxml-rap.el b/lisp/nxml/nxml-rap.el index 3be413ae00b..cf34119c2c0 100644 --- a/lisp/nxml/nxml-rap.el +++ b/lisp/nxml/nxml-rap.el @@ -108,13 +108,6 @@ Return nil if the character at POS is not inside." (setq nxml-prolog-regions (xmltok-forward-prolog)) (setq nxml-prolog-end (point)))) -(defun nxml-maybe-rescan-prolog (start _end _length) - "Reparse the prolog if START lies within it. -`nxml-mode' adds this function on `after-change-functions'." - (when (<= start nxml-prolog-end) - (save-excursion - (nxml-scan-prolog)))) - ;;; Random access parsing (defun nxml-token-after () |