Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(867)

Unified Diff: components/autofill/browser/autofill_regexes.cc

Issue 13973004: Convert string16 -> base::string16 in components/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/autofill/browser/autofill_regexes.cc
diff --git a/components/autofill/browser/autofill_regexes.cc b/components/autofill/browser/autofill_regexes.cc
index 64df56a9930d5ead104dfa6863affe4f7cffd254..18bf96b56ef5ccfdb7b99bbf8cb8eb52c5abbd55 100644
--- a/components/autofill/browser/autofill_regexes.cc
+++ b/components/autofill/browser/autofill_regexes.cc
@@ -22,7 +22,7 @@ class AutofillRegexes {
static AutofillRegexes* GetInstance();
// Returns the compiled regex matcher corresponding to |pattern|.
- icu::RegexMatcher* GetMatcher(const string16& pattern);
+ icu::RegexMatcher* GetMatcher(const base::string16& pattern);
private:
AutofillRegexes();
@@ -30,7 +30,7 @@ class AutofillRegexes {
friend struct DefaultSingletonTraits<AutofillRegexes>;
// Maps patterns to their corresponding regex matchers.
- std::map<string16, icu::RegexMatcher*> matchers_;
+ std::map<base::string16, icu::RegexMatcher*> matchers_;
DISALLOW_COPY_AND_ASSIGN(AutofillRegexes);
};
@@ -48,7 +48,7 @@ AutofillRegexes::~AutofillRegexes() {
matchers_.end());
}
-icu::RegexMatcher* AutofillRegexes::GetMatcher(const string16& pattern) {
+icu::RegexMatcher* AutofillRegexes::GetMatcher(const base::string16& pattern) {
if (!matchers_.count(pattern)) {
const icu::UnicodeString icu_pattern(pattern.data(), pattern.length());
@@ -68,7 +68,8 @@ icu::RegexMatcher* AutofillRegexes::GetMatcher(const string16& pattern) {
namespace autofill {
-bool MatchesPattern(const string16& input, const string16& pattern) {
+bool MatchesPattern(const base::string16& input,
+ const base::string16& pattern) {
icu::RegexMatcher* matcher =
AutofillRegexes::GetInstance()->GetMatcher(pattern);
icu::UnicodeString icu_input(input.data(), input.length());

Powered by Google App Engine
This is Rietveld 408576698