fix regex
This commit is contained in:
parent
13b934c250
commit
951c21366a
@ -33,8 +33,7 @@ function rawdict()
|
|||||||
filter(!isempty, split.(split(readstring(deps("CMUDict", "cmudict")), "\n"))))
|
filter(!isempty, split.(split(readstring(deps("CMUDict", "cmudict")), "\n"))))
|
||||||
end
|
end
|
||||||
|
|
||||||
# validword(s) = ismatch(r"^[\w-\.]+$", s)
|
validword(s) = ismatch(r"^[\w\-\.]+$", s)
|
||||||
validword(s) = ismatch(r"^\[\w-\.\]+$", s)
|
|
||||||
|
|
||||||
cmudict() = filter((s, ps) -> validword(s), rawdict())
|
cmudict() = filter((s, ps) -> validword(s), rawdict())
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user