summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2019-03-27 10:01:21 -0700
committerPaul Eggert <eggert@cs.ucla.edu>2019-03-27 10:02:18 -0700
commita697d1e638eabdb3eb32337fde6d802ef712eaf8 (patch)
tree6b72ddfea5e6cf6bc99e67ecde61537bc8e62a10
parent907d11fc5372e899c89739f79c653eed055450cf (diff)
downloademacs-a697d1e638eabdb3eb32337fde6d802ef712eaf8.tar.gz
Minor xml.el tweaks
* lisp/xml.el (xml-name-start-char-re, xml-name-char-re): No need to call concat. (xml-name-char-re): Use \u escapes rather than chars inline, so that the code matches the comments better and is easier to audit.
-rw-r--r--lisp/xml.el4
1 files changed, 2 insertions, 2 deletions
diff --git a/lisp/xml.el b/lisp/xml.el
index 44506b971aa..2337952f064 100644
--- a/lisp/xml.el
+++ b/lisp/xml.el
@@ -176,11 +176,11 @@ See also `xml-get-attribute-or-nil'."
;; [4] NameStartChar
;; See the definition of word syntax in `xml-syntax-table'.
-(defconst xml-name-start-char-re (concat "[[:word:]:_]"))
+(defconst xml-name-start-char-re "[[:word:]:_]")
;; [4a] NameChar ::= NameStartChar | "-" | "." | [0-9] | #xB7
;; | [#x0300-#x036F] | [#x203F-#x2040]
-(defconst xml-name-char-re (concat "[-0-9.[:word:]:_·̀-ͯ‿⁀]"))
+(defconst xml-name-char-re "[[:word:]:_.0-9\u00B7\u0300-\u036F\u203F\u2040-]")
;; [5] Name ::= NameStartChar (NameChar)*
(defconst xml-name-re (concat xml-name-start-char-re xml-name-char-re "*"))