diff options
author | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2020-03-11 11:32:04 +0100 |
---|---|---|
committer | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2020-03-18 13:40:17 +0000 |
commit | 31ccca0778db85c159634478b4ec7997f6704860 (patch) | |
tree | 3d33fc3afd9d5ec95541e1bbe074a9cf8da12a0e /chromium/components/url_matcher | |
parent | 248b70b82a40964d5594eb04feca0fa36716185d (diff) | |
download | qtwebengine-chromium-31ccca0778db85c159634478b4ec7997f6704860.tar.gz |
BASELINE: Update Chromium to 80.0.3987.136
Change-Id: I98e1649aafae85ba3a83e67af00bb27ef301db7b
Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io>
Diffstat (limited to 'chromium/components/url_matcher')
-rw-r--r-- | chromium/components/url_matcher/string_pattern.cc | 9 | ||||
-rw-r--r-- | chromium/components/url_matcher/string_pattern.h | 4 |
2 files changed, 9 insertions, 4 deletions
diff --git a/chromium/components/url_matcher/string_pattern.cc b/chromium/components/url_matcher/string_pattern.cc index a4b87bcaad5..3a2919a721e 100644 --- a/chromium/components/url_matcher/string_pattern.cc +++ b/chromium/components/url_matcher/string_pattern.cc @@ -5,15 +5,18 @@ #include "components/url_matcher/string_pattern.h" #include <tuple> +#include <utility> namespace url_matcher { -StringPattern::StringPattern(const std::string& pattern, - StringPattern::ID id) - : pattern_(pattern), id_(id) {} +StringPattern::StringPattern(std::string pattern, StringPattern::ID id) + : pattern_(std::move(pattern)), id_(id) {} StringPattern::~StringPattern() {} +StringPattern::StringPattern(StringPattern&&) = default; +StringPattern& StringPattern::operator=(StringPattern&&) = default; + bool StringPattern::operator<(const StringPattern& rhs) const { return std::tie(id_, pattern_) < std::tie(rhs.id_, rhs.pattern_); } diff --git a/chromium/components/url_matcher/string_pattern.h b/chromium/components/url_matcher/string_pattern.h index 34ad2132000..67697079aa4 100644 --- a/chromium/components/url_matcher/string_pattern.h +++ b/chromium/components/url_matcher/string_pattern.h @@ -24,8 +24,10 @@ class URL_MATCHER_EXPORT StringPattern { public: typedef int ID; - StringPattern(const std::string& pattern, ID id); + StringPattern(std::string pattern, ID id); ~StringPattern(); + StringPattern(StringPattern&&); + StringPattern& operator=(StringPattern&&); const std::string& pattern() const { return pattern_; } ID id() const { return id_; } |