diff --git a/search/geocoder.cpp b/search/geocoder.cpp index 98317e4fcd..a124d3a842 100644 --- a/search/geocoder.cpp +++ b/search/geocoder.cpp @@ -350,9 +350,6 @@ void Geocoder::SetParams(Params const & params) m_tokenRequests.emplace_back(); auto & request = m_tokenRequests.back(); m_params.GetToken(i).ForEach([&request](UniString const & s) { - // Here and below, we use LevenshteinDFAs for fuzzy - // matching. But due to performance reasons, we assume that the - // first letter is always correct. request.m_names.emplace_back(BuildLevenshteinDFA(s)); }); for (auto const & index : m_params.GetTypeIndices(i)) diff --git a/search/utils.cpp b/search/utils.cpp index 18caccfa58..e58f572a53 100644 --- a/search/utils.cpp +++ b/search/utils.cpp @@ -18,6 +18,9 @@ size_t GetMaxErrorsForToken(strings::UniString const & token) strings::LevenshteinDFA BuildLevenshteinDFA(strings::UniString const & s) { + // In search we use LevenshteinDFAs for fuzzy matching. But due to + // performance reasons, we assume that the first letter is always + // correct. return strings::LevenshteinDFA(s, 1 /* prefixCharsToKeep */, GetMaxErrorsForToken(s)); } } // namespace search