summaryrefslogtreecommitdiff
path: root/lisp/nxml/rng-nxml.el
diff options
context:
space:
mode:
authorStefan Monnier <monnier@iro.umontreal.ca>2016-01-15 10:29:20 -0500
committerStefan Monnier <monnier@iro.umontreal.ca>2016-01-15 10:29:20 -0500
commit930f8e8377e40ba161bd16ea4d612cb4c570ee1b (patch)
treefd3c9aa7fd154317758053492ad855df68658f15 /lisp/nxml/rng-nxml.el
parenta600f4c69309bf37f67c02cbcc9a9e4ba1e69c76 (diff)
downloademacs-930f8e8377e40ba161bd16ea4d612cb4c570ee1b.tar.gz
Update nXML to use Emacs's Unicode support, and lexical-binding
* etc/nxml/*.el: Remove obsolete char-name files. * lisp/nxml/xsd-regexp.el (xsdre-range-list-difference): Remove unused var `next'. * lisp/nxml/rng-nxml.el (rng-set-state-after): Don't assume point-min==1. * lisp/nxml/rng-match.el (rng-update-match-state): Simplify. * lisp/nxml/nxml-outln.el (nxml-outline-state-transform-exceptions) (nxml-target-section-pos, nxml-depth-in-target-section) (nxml-outline-state-transform-alist) (nxml-outline-display-section-tag-function): Move decl before first use. * lisp/nxml/nxml-mode.el (nxml-char-name-ignore-case) (nxml-char-name-alist, nxml-char-name-table) (nxml-autoload-char-name-set-list, nxml-named-char-history): Remove vars. (nxml-enable-char-name-set, nxml-disable-char-name-set) (nxml-char-name-set-enabled-p, nxml-autoload-char-name-set) (nxml-define-char-name-set, nxml-get-char-name): Remove functions. (nxml-insert-named-char): Use read-char-by-name instead. (nxml-char-ref-display-extra): Use get-char-code-property. * lisp/nxml/nxml-maint.el (nxml-create-unicode-char-name-sets): Remove function. * lisp/nxml/nxml-glyph.el, lisp/nxml/nxml-uchnm.el: Remove files.
Diffstat (limited to 'lisp/nxml/rng-nxml.el')
-rw-r--r--lisp/nxml/rng-nxml.el6
1 files changed, 3 insertions, 3 deletions
diff --git a/lisp/nxml/rng-nxml.el b/lisp/nxml/rng-nxml.el
index fe90dffb555..85e4bf33ee0 100644
--- a/lisp/nxml/rng-nxml.el
+++ b/lisp/nxml/rng-nxml.el
@@ -1,4 +1,4 @@
-;;; rng-nxml.el --- make nxml-mode take advantage of rng-validate-mode
+;;; rng-nxml.el --- make nxml-mode take advantage of rng-validate-mode -*- lexical-binding:t -*-
;; Copyright (C) 2003, 2007-2016 Free Software Foundation, Inc.
@@ -349,7 +349,7 @@ Return non-nil if in a context it understands."
(recover-fun (funcall recover-fun prefix (cdr qname)))))
(cons (and defaultp (nxml-ns-get-default)) (cdr qname)))))
-(defun rng-start-tag-expand-recover (prefix local-name)
+(defun rng-start-tag-expand-recover (_prefix local-name)
(let ((ns (rng-match-infer-start-tag-namespace local-name)))
(and ns
(cons ns local-name))))
@@ -386,7 +386,7 @@ set `xmltok-dtd'. Returns the position of the end of the token."
(save-restriction
(widen)
(nxml-with-invisible-motion
- (if (= pos 1)
+ (if (= pos (point-min))
(rng-set-initial-state)
(let ((state (get-text-property (1- pos) 'rng-state)))
(cond (state