| Index: chrome/browser/extensions/api/declarative/substring_set_matcher.cc
|
| diff --git a/chrome/browser/extensions/api/declarative/substring_set_matcher.cc b/chrome/browser/extensions/api/declarative/substring_set_matcher.cc
|
| index 847fff9099a567b41cfb629f293d703c76c2b064..af03601a775c30bd217e86a14811bf00e7e113bd 100644
|
| --- a/chrome/browser/extensions/api/declarative/substring_set_matcher.cc
|
| +++ b/chrome/browser/extensions/api/declarative/substring_set_matcher.cc
|
| @@ -92,6 +92,11 @@ bool SubstringSetMatcher::Match(const std::string& text,
|
| return old_number_of_matches != matches->size();
|
| }
|
|
|
| +bool SubstringSetMatcher::IsEmpty() const {
|
| + // An empty tree consists of only the root node.
|
| + return patterns_.empty() && tree_.size() == 1u;
|
| +}
|
| +
|
| void SubstringSetMatcher::RebuildAhoCorasickTree() {
|
| tree_.clear();
|
|
|
|
|