r182 - CJKSplitter/trunk

0 views
Skip to first unread message

czug-checkins

unread,
Mar 2, 2006, 8:59:11 AM3/2/06
to czug-c...@googlegroups.com
Author: panjy
Date: Thu Mar 2 21:55:08 2006
New Revision: 182

Modified:
CJKSplitter/trunk/CJKSplitter.py
CJKSplitter/trunk/tests.py
Log:
reverted previous commit for it breaks normal chinese search


Modified: CJKSplitter/trunk/CJKSplitter.py
==============================================================================
--- CJKSplitter/trunk/CJKSplitter.py (original)
+++ CJKSplitter/trunk/CJKSplitter.py Thu Mar 2 21:55:08 2006
@@ -98,7 +98,8 @@
# result.append(w[i-1:i+1])
i += 1

- result.append(w[-1])
+ if not isGlob:
+ result.append(w[-1])
else:
result.append(w)
# return [word.encode('utf8') for word in result]

Modified: CJKSplitter/trunk/tests.py
==============================================================================
--- CJKSplitter/trunk/tests.py (original)
+++ CJKSplitter/trunk/tests.py Thu Mar 2 21:55:08 2006
@@ -1,6 +1,6 @@
from CJKSplitter import CJKSplitter

-words = ['知识库-招聘资料']
+words = ['知识库-招聘资料', '大学生']
for word in words:
print '=====now test:', word
u = unicode(word, 'utf8').encode('utf8')

Reply all
Reply to author
Forward
0 new messages