Fix rx-any with range with ?\] and ?-
* lisp/emacs-lisp/rx.el: Make sure not to produce a circular list (Bug#25123). * test/lisp/emacs-lisp/rx-tests.el (rx-char-any): New test.
This commit is contained in:
parent
b21a3e726f
commit
a7523ba955
2 changed files with 38 additions and 1 deletions
|
@ -521,7 +521,7 @@ ARG is optional."
|
|||
(setq args (nconc (delq ?- args) (list ?-))))
|
||||
((setq m (assq ?- args))
|
||||
;; next to the bracket's range, make the second range
|
||||
(setcdr args (cons m (delq m args))))))
|
||||
(setcdr args (cons m (delq m (cdr args)))))))
|
||||
;; bracket in the end range
|
||||
;; => "[]...-]"
|
||||
((setq m (rassq ?\] args))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue