summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp/regexp-opt.el
diff options
context:
space:
mode:
authorChong Yidong <cyd@stupidchicken.com>2008-04-09 04:29:43 +0000
committerChong Yidong <cyd@stupidchicken.com>2008-04-09 04:29:43 +0000
commit75407435b1821f065e1c42967f3d3384c3732a28 (patch)
tree5c268c82b1b50b63906b4b9a94306e005ce1e64e /lisp/emacs-lisp/regexp-opt.el
parent2d9653c4985e398950e3cee47878f9d5903fd016 (diff)
downloademacs-75407435b1821f065e1c42967f3d3384c3732a28.tar.gz
(regexp-opt-group): Use substring-no-properties for correct handling
of unibyte strings.
Diffstat (limited to 'lisp/emacs-lisp/regexp-opt.el')
-rw-r--r--lisp/emacs-lisp/regexp-opt.el2
1 files changed, 1 insertions, 1 deletions
diff --git a/lisp/emacs-lisp/regexp-opt.el b/lisp/emacs-lisp/regexp-opt.el
index 18bd094e4d4..51ed53e71fc 100644
--- a/lisp/emacs-lisp/regexp-opt.el
+++ b/lisp/emacs-lisp/regexp-opt.el
@@ -226,7 +226,7 @@ This means the number of non-shy regexp grouping constructs
;; Otherwise, divide the list into those that start with a
;; particular letter and those that do not, and recurse on them.
- (let* ((char (char-to-string (string-to-char (car strings))))
+ (let* ((char (substring-no-properties (car strings) 0 1))
(half1 (all-completions char strings))
(half2 (nthcdr (length half1) strings)))
(concat open-group