package stem
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>
A stemmer of words for few languages
Install
dune-project
Dependency
Authors
Maintainers
Sources
stem-0.0.1.tbz
sha256=ec121bc02bca7121ce04cd346648d0432826be12dabf386d064795197cbf0275
sha512=f45989d23cc1211df3c8a9c3a164a7f853e6a1cb1274061f65c8c7e5b631a8a88c675c76b5d939da6777d571f63ce59d5b18940abc5fddb944ca402bc095b1ca
doc/src/stem.tokenizer/dash.ml.html
Source file dash.ml
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32(* TODO(dinosaure): handle [encoding]. *) let find_matches ?encoding:_ str = match String.split_on_char '-' str with | [] -> assert false | [ str ] -> List.to_seq [ { S.str; is_match = false } ] | hd :: tl -> let dash = { S.str = "-"; is_match = true } in let rec go acc = function | [] -> List.to_seq (List.rev acc) | "" :: r -> go (dash :: acc) r | str :: r -> let x = { S.str; is_match = false } in go (x :: dash :: acc) r in go [ { S.str = hd; is_match = false } ] tl let find_matches_on_bstr ?encoding:_ bstr = match Bstr.split_on_char '-' bstr with | [] -> assert false | [ bstr ] -> let str = Bstr.to_string bstr in List.to_seq [ { S.str; is_match = false } ] | hd :: tl -> let dash = { S.str = "-"; is_match = true } in let rec go acc = function | [] -> List.to_seq (List.rev acc) | bstr :: r when Bstr.is_empty bstr -> go (dash :: acc) r | bstr :: r -> let str = Bstr.to_string bstr in let x = { S.str; is_match = false } in go (x :: dash :: acc) r in let hd = Bstr.to_string hd in go [ { S.str = hd; is_match = false } ] tl
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>