Fix style issues reported by clang-tidy (#1167)

This commit is contained in:
Fangjun Kuang
2024-07-23 09:26:36 +08:00
committed by GitHub
parent d32a46169f
commit 299f1a852b
7 changed files with 21 additions and 22 deletions

View File

@@ -102,13 +102,13 @@ class JiebaLexicon::Impl {
this_sentence.push_back(blank);
if (w == "" || w == "" || w == "" || w == "") {
ans.push_back(std::move(this_sentence));
ans.emplace_back(std::move(this_sentence));
this_sentence = {};
}
} // for (const auto &w : words)
if (!this_sentence.empty()) {
ans.push_back(std::move(this_sentence));
ans.emplace_back(std::move(this_sentence));
}
return ans;