From 1459b83c7e90e6b173abf6fdd3cd79f5e4da1f06 Mon Sep 17 00:00:00 2001 From: SisMaker <1713699517@qq.com> Date: Fri, 30 Apr 2021 01:15:33 +0800 Subject: [PATCH] =?UTF-8?q?ft:=20replaceSw=E5=87=BD=E6=95=B0=E7=9A=84?= =?UTF-8?q?=E5=AE=9E=E7=8E=B0=20todo:=20replaceSw=E5=87=BD=E6=95=B0?= =?UTF-8?q?=E7=9A=84=E4=BC=98=E5=8C=96=20=E6=95=8F=E6=84=9F=E8=AF=8D?= =?UTF-8?q?=E5=8E=BB=E9=99=A4=E7=89=B9=E6=AE=8A=E5=AD=97=E7=AC=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/eAcs.erl | 8 -------- 1 file changed, 8 deletions(-) diff --git a/src/eAcs.erl b/src/eAcs.erl index 5089122..2a3c642 100644 --- a/src/eAcs.erl +++ b/src/eAcs.erl @@ -22,7 +22,6 @@ doMatchMs(<<>>, _, _Index, MatchList) -> doMatchMs(<>, State, Index, MatchList) -> case acsSpw:getSpw(Word) of true -> - %% 特殊字符跳过 且Index 不加 1 doMatchMs(Tail, State, Index, MatchList); _ -> {NewState, NewMatchList} = matchWordMs(Word, State, Index, MatchList), @@ -79,7 +78,6 @@ doMatchIs(<<>>, _) -> doMatchIs(<>, State) -> case acsSpw:getSpw(Word) of true -> - %% 特殊字符跳过 doMatchIs(Tail, State); _ -> case matchWordIs(Word, State) of @@ -163,13 +161,10 @@ getMatchWords(MatchWordCnt, BinStr, ByteIndex, BslCnt, Utf8Code, FilterWs) -> Byte = binary:at(BinStr, ByteIndex), if Byte < 128 -> - %% ASCII 查看是否特殊字符 是就维护原样 case acsSpw:getSpw(Byte) of true -> - %% 是特殊词 getMatchWords(MatchWordCnt, BinStr, ByteIndex - 1, 0, 0, [Byte | FilterWs]); _ -> - %% 不是特殊词 getMatchWords(MatchWordCnt - 1, BinStr, ByteIndex - 1, 0, 0, [?RW | FilterWs]) end; Byte bsr 6 == 2 -> @@ -191,10 +186,8 @@ getMatchWords(MatchWordCnt, BinStr, ByteIndex, BslCnt, Utf8Code, FilterWs) -> FullWord = Code bsl BslCnt + Utf8Code, case acsSpw:getSpw(FullWord) of true -> - %% 是特殊词 getMatchWords(MatchWordCnt, BinStr, ByteIndex - 1, 0, 0, [FullWord | FilterWs]); _ -> - %% 不是特殊词 getMatchWords(MatchWordCnt - 1, BinStr, ByteIndex - 1, 0, 0, [?RW | FilterWs]) end end. @@ -219,7 +212,6 @@ doMatchRs(<<>>, _TotalSize, _CurIndex, _State, MatchList) -> doMatchRs(<>, TotalSize, CurIndex, State, MatchList) -> case acsSpw:getSpw(Word) of true -> - %% 特殊字符跳过 且CurIndex 不加 1 doMatchRs(Tail, TotalSize, CurIndex, State, MatchList); _ -> {NewState, MatchCnt} = matchWordRs(Word, State, 0),