[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/pyim a142f82 3/3: * pyim.el (pyim-cregexp-build-1): Bet
From: |
ELPA Syncer |
Subject: |
[elpa] externals/pyim a142f82 3/3: * pyim.el (pyim-cregexp-build-1): Better handle "'". |
Date: |
Tue, 9 Mar 2021 19:57:10 -0500 (EST) |
branch: externals/pyim
commit a142f82edf3ccef2fd9b5ae90827e5283b8a8f95
Author: Feng Shu <tumashu@163.com>
Commit: Feng Shu <tumashu@163.com>
* pyim.el (pyim-cregexp-build-1): Better handle "'".
n'h can search nh and n'h
---
pyim.el | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/pyim.el b/pyim.el
index fb97ca9..73caa50 100644
--- a/pyim.el
+++ b/pyim.el
@@ -3881,9 +3881,8 @@ PUNCT-LIST 格式类似:
(if (or (pyim-string-match-p "[^a-z']+" string)
(equal string ""))
string
- (let* ((imobjs (pyim-imobjs-create
- (replace-regexp-in-string "'" "" string)
- scheme-name))
+ (let* ((string1 (replace-regexp-in-string "'" "" string))
+ (imobjs (pyim-imobjs-create string1 scheme-name))
(regexp-list
(mapcar
#'(lambda (imobj)
@@ -3898,7 +3897,7 @@ PUNCT-LIST 格式类似:
"\\|")))
(regexp
(if (> (length regexp) 0)
- (concat string "\\|" regexp)
+ (concat string "\\|" string1 "\\|" regexp)
string)))
(format "\\(?:%s\\)" regexp))))
lst "")))