Skip to content

Commit da090d2

Browse files
authored
Merge pull request #20 from Dr-Julius-No/master
Make word list public; addresses #19
2 parents aeccaf6 + f01e0b2 commit da090d2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/language/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ impl Language {
8282

8383
/// The word list for this language.
8484
#[inline]
85-
pub(crate) fn word_list(self) -> &'static [&'static str; 2048] {
85+
pub fn word_list(self) -> &'static [&'static str; 2048] {
8686
match self {
8787
Language::English => &english::WORDS,
8888
#[cfg(feature = "chinese-simplified")]
@@ -146,7 +146,7 @@ impl Language {
146146

147147
/// Get the index of the word in the word list.
148148
#[inline]
149-
pub(crate) fn find_word(self, word: &str) -> Option<u16> {
149+
pub fn find_word(self, word: &str) -> Option<u16> {
150150
self.word_list().iter().position(|w| *w == word).map(|i| i as u16)
151151
}
152152
}

0 commit comments

Comments
 (0)