[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/pyim d5d98bdbdb 12/58: pyim-cstring-partition -> pyim-c
From: |
ELPA Syncer |
Subject: |
[elpa] externals/pyim d5d98bdbdb 12/58: pyim-cstring-partition -> pyim-cstring--partition |
Date: |
Fri, 24 Jun 2022 06:57:52 -0400 (EDT) |
branch: externals/pyim
commit d5d98bdbdb13821d63cf234a7cd59931556c7b11
Author: Feng Shu <tumashu@163.com>
Commit: Feng Shu <tumashu@163.com>
pyim-cstring-partition -> pyim-cstring--partition
---
pyim-cstring-utils.el | 2 +-
pyim-cstring.el | 4 ++--
tests/pyim-tests.el | 14 +++++++-------
3 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/pyim-cstring-utils.el b/pyim-cstring-utils.el
index 8fc854904d..7924b13101 100644
--- a/pyim-cstring-utils.el
+++ b/pyim-cstring-utils.el
@@ -98,7 +98,7 @@ CHINESE-STRING 分词,得到一个词条 alist,这个 alist 的元素都是
(pyim-cstring-split-to-string-1
str prefer-short-word separator max-word-length)
str)))
- (pyim-cstring-partition string) (or separator " ")))
+ (pyim-cstring--partition string) (or separator " ")))
(defun pyim-cstring-split-to-string-1 (chinese-string &optional
prefer-short-word
separator
max-word-length)
diff --git a/pyim-cstring.el b/pyim-cstring.el
index 8a8a76dbdb..9c97c81fde 100644
--- a/pyim-cstring.el
+++ b/pyim-cstring.el
@@ -37,7 +37,7 @@
"Chinese string tools for pyim."
:group 'pyim)
-(defun pyim-cstring-partition (string &optional to-cchar)
+(defun pyim-cstring--partition (string &optional to-cchar)
"STRING partition.
1. Hello你好 -> (\"Hello\" \"你\" \"好\"), when TO-CCHAR is non-nil.
@@ -124,7 +124,7 @@ BUG: 当 STRING 中包含其它标点符号,并且设置 SEPERATER 时,结
(if (pyim-string-match-p "\\cc" str)
(pyim-pymap-cchar2py-get str)
(list str)))
- (pyim-cstring-partition string t)))
+ (pyim-cstring--partition string t)))
;; 通过排列组合的方式, 重排 pinyins-list。
;; 比如:(("Hello") ("yin") ("hang" "xing")) -> (("Hello" "yin" "hang")
("Hello" "yin" "xing"))
diff --git a/tests/pyim-tests.el b/tests/pyim-tests.el
index 8eb8f7f643..dff65f422a 100644
--- a/tests/pyim-tests.el
+++ b/tests/pyim-tests.el
@@ -712,18 +712,18 @@
(should (equal (get-text-property 0 :comment (car words)) "(buf)")))))
;; ** pyim-cstring 相关单元测试
-(ert-deftest pyim-tests-pyim-cstring-partition ()
- (should (equal (pyim-cstring-partition "你好 hello 你好")
+(ert-deftest pyim-tests-pyim-cstring--partition ()
+ (should (equal (pyim-cstring--partition "你好 hello 你好")
'("你好" " hello " "你好")))
- (should (equal (pyim-cstring-partition "你好 hello 你好" t)
+ (should (equal (pyim-cstring--partition "你好 hello 你好" t)
'("你" "好" " hello " "你" "好")))
- (should (equal (pyim-cstring-partition "你好")
+ (should (equal (pyim-cstring--partition "你好")
'("你好")))
- (should (equal (pyim-cstring-partition "你好" t)
+ (should (equal (pyim-cstring--partition "你好" t)
'("你" "好")))
- (should (equal (pyim-cstring-partition "hello")
+ (should (equal (pyim-cstring--partition "hello")
'("hello")))
- (should (equal (pyim-cstring-partition "hello" t)
+ (should (equal (pyim-cstring--partition "hello" t)
'("hello"))))
(ert-deftest pyim-tests-pyim-cstring-substrings ()
- [elpa] externals/pyim c573694ae4 58/58: Update pyim-pymap-utils.el, (continued)
- [elpa] externals/pyim c573694ae4 58/58: Update pyim-pymap-utils.el, ELPA Syncer, 2022/06/24
- [elpa] externals/pyim f4074fc4ef 04/58: pyim-cregexp-valid-p -> pyim-cregexp--valid-p, ELPA Syncer, 2022/06/24
- [elpa] externals/pyim 291798d23d 09/58: pyim-cregexp-scheme -> pyim-cregexp--scheme, ELPA Syncer, 2022/06/24
- [elpa] externals/pyim b243e7e8e7 15/58: pyim-isearch-search-fun -> pyim-isearch--search-fun, ELPA Syncer, 2022/06/24
- [elpa] externals/pyim 56505723bc 16/58: pyim-autoselector-xingma-1 -> pyim-autoselector--xingma, ELPA Syncer, 2022/06/24
- [elpa] externals/pyim ea2988cf16 26/58: pyim-dict-manager-buffer -> pyim-dict-manager--buffer, ELPA Syncer, 2022/06/24
- [elpa] externals/pyim 91b1aa37da 11/58: pyim-cregexp-build-xingma-regexp-from-words -> pyim-cregexp--build-xingma-regexp-from-words, ELPA Syncer, 2022/06/24
- [elpa] externals/pyim 40ed5dc8a4 10/58: pyim-cregexp-quanpin- -> pyim-cregexp-quanpin--, ELPA Syncer, 2022/06/24
- [elpa] externals/pyim 2064692d35 40/58: pyim-liberime-get-code -> pyim-liberime--get-code, ELPA Syncer, 2022/06/24
- [elpa] externals/pyim 48e904bbe6 42/58: pyim-outcome-magic-convert-cache -> pyim-outcome--magic-convert-cache, ELPA Syncer, 2022/06/24
- [elpa] externals/pyim d5d98bdbdb 12/58: pyim-cstring-partition -> pyim-cstring--partition,
ELPA Syncer <=
- [elpa] externals/pyim 68e406ed4f 19/58: pyim-candidates-znabc-words -> pyim-candidates--znabc-words, ELPA Syncer, 2022/06/24
- [elpa] externals/pyim df48854299 22/58: pyim-cloudim-parse-baidu-buffer -> pyim-cloudim--parse-baidu-buffer, ELPA Syncer, 2022/06/24
- [elpa] externals/pyim 67f800c819 23/58: pyim-cloudim-parse-google-buffer -> pyim-cloudim--parse-google-buffer, ELPA Syncer, 2022/06/24
- [elpa] externals/pyim 0629a400d9 31/58: pyim-indicator-timer -> pyim-indicator--timer, ELPA Syncer, 2022/06/24
- [elpa] externals/pyim d40f7c4f86 45/58: pyim-pinyin-yunmu -> pyim-pinyin--yunmu, ELPA Syncer, 2022/06/24
- [elpa] externals/pyim 889db4b5ab 49/58: pyim-pinyin-get-charpy -> pyim-pinyin--get-charpy, ELPA Syncer, 2022/06/24
- [elpa] externals/pyim dfed7ddeaf 50/58: Sort pyim-pinyin.el, ELPA Syncer, 2022/06/24
- [elpa] externals/pyim 067ba514bd 56/58: pyim-pymap-py2cchar-cache3 -> pyim-pymap--py2cchar-cache3, ELPA Syncer, 2022/06/24
- [elpa] externals/pyim 29516cfd7a 35/58: pyim-indicator-update-mode-line -> pyim-indicator--update-mode-line, ELPA Syncer, 2022/06/24
- [elpa] externals/pyim 2a22da363a 39/58: pyim-liberime-create-word -> pyim-liberime--create-word, ELPA Syncer, 2022/06/24