Index: components/query_parser/query_parser.h |
diff --git a/components/query_parser/query_parser.h b/components/query_parser/query_parser.h |
index 46d0bd22cbdbd8c29ffb8da96743a86d3b931ad3..c9a79ff69ac705bdeb06af544f99d94a2aef7e06 100644 |
--- a/components/query_parser/query_parser.h |
+++ b/components/query_parser/query_parser.h |
@@ -103,6 +103,10 @@ class QueryParser { |
void ExtractQueryWords(const base::string16& text, |
std::vector<QueryWord>* words); |
+ // Sorts the match positions in |matches| by their first index, then |
+ // coalesces any match positions that intersect each other. |
+ static void SortAndCoalesceMatchPositions(Snippet::MatchPositions* matches); |
+ |
private: |
// Does the work of parsing |query|; creates nodes in |root| as appropriate. |
// This is invoked from both of the ParseQuery methods. |