我现在用的版本是:
(defun eh-ivy-cregexp (str)
(let ((x (ivy--regex-plus str))
(case-fold-search nil))
(if (listp x)
(mapcar (lambda (y)
(if (cdr y)
(list (if (equal (car y) "")
""
(pyim-cregexp-build (car y)))
(cdr y))
(list (pyim-cregexp-build (car y)))))
x)
(pyim-cregexp-build x))))