forked from lix-project/lix
Fix incorrect comment in hiliteMatches
This commit is contained in:
parent
1dd7253133
commit
d137ceccef
|
@ -8,9 +8,9 @@ std::string hiliteMatches(
|
|||
std::string_view prefix,
|
||||
std::string_view postfix)
|
||||
{
|
||||
// Avoid copy on zero matches
|
||||
// Avoid extra work on zero matches
|
||||
if (matches.size() == 0)
|
||||
return (std::string) s;
|
||||
return std::string(s);
|
||||
|
||||
std::sort(matches.begin(), matches.end(), [](const auto & a, const auto & b) {
|
||||
return a.position() < b.position();
|
||||
|
|
Loading…
Reference in a new issue