completion: do not invalidate cache when adding new characters

This commit is contained in:
Evgenii Balai 2019-11-08 00:43:40 -05:00 committed by Your Name
parent 396d0668af
commit dc4d0f7748

View File

@ -176,7 +176,7 @@ template <typename T> struct CompleteConsumerCache {
Position position) {
std::lock_guard lock(mutex);
return this->path == path && this->position == position &&
this->line == line;
line.substr(0,position.character) == this->line.substr(0, position.character);
}
};
} // namespace ccls