mirror of
https://github.com/Artikash/Textractor.git
synced 2024-12-23 08:54:12 +08:00
make logic clearer, remove second call to size
This commit is contained in:
parent
663bb97fff
commit
4b67b8a5cf
@ -166,9 +166,9 @@ bool ProcessSentence(std::wstring& sentence, SentenceInfo sentenceInfo)
|
|||||||
tokens.push(token); // popped one too many
|
tokens.push(token); // popped one too many
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if (tokens.size() < tokenCount) tokens.push(current);
|
bool available = tokens.size() < tokenCount;
|
||||||
else return false;
|
if (available) tokens.push(current);
|
||||||
return tokens.size() <= tokenCount;
|
return available;
|
||||||
}
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user