Skip to content

Commit 06a9c83

Browse files
Ko van der SlootKo van der Sloot
authored andcommitted
adapt to newest ucto
1 parent e85540b commit 06a9c83

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

configure.ac

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ PKG_CHECK_MODULES([folia],[folia >= 1.4])
6767
CXXFLAGS="$CXXFLAGS $folia_CFLAGS"
6868
LIBS="$folia_LIBS $LIBS"
6969

70-
PKG_CHECK_MODULES([ucto],[ucto >= 0.9.3])
70+
PKG_CHECK_MODULES([ucto],[ucto >= 0.15])
7171
CXXFLAGS="$CXXFLAGS $ucto_CFLAGS"
7272
LIBS="$ucto_LIBS $LIBS"
7373

src/froggen.cxx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -527,14 +527,14 @@ void create_lemmatizer( const Configuration& config,
527527
void check_data( Tokenizer::TokenizerClass *tokenizer,
528528
const multimap<UnicodeString,map<UnicodeString,map<UnicodeString,size_t>>>& data ){
529529
for ( const auto& word : data ){
530-
int num = tokenizer->tokenizeLine( word.first );
531-
if ( num != 1 ){
530+
tokenizer->tokenizeLine( word.first );
531+
vector<Tokenizer::Token> v = tokenizer->popSentence();
532+
if ( v.size() != 1 ){
532533
cerr << "the provided tokenizer doesn't handle '" << word.first
533-
<< "' well (splits it into " << num << " parts.)" << endl;
534-
vector<string> v = tokenizer->getSentences();
534+
<< "' well (splits it into " << v.size() << " parts.)" << endl;
535535
cerr << "[";
536536
for ( const auto& w : v ){
537-
cerr << w << " ";
537+
cerr << w.us << " ";
538538
}
539539
cerr << "]" << endl;
540540
}

0 commit comments

Comments
 (0)