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

Side by Side Diff: base/version.cc

Issue 3447008: base: Finish moving the SplitString functions from string_util.h to string_split.h (Closed) Base URL: git://git.chromium.org/chromium.git
Patch Set: chromeos fixes Created 10 years, 3 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 unified diff | Download patch
« no previous file with comments | « base/string_util_unittest.cc ('k') | chrome/app/breakpad_win.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/version.h" 5 #include "base/version.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/string_number_conversions.h" 8 #include "base/string_number_conversions.h"
9 #include "base/string_split.h"
9 #include "base/string_util.h" 10 #include "base/string_util.h"
10 #include "base/utf_string_conversions.h" 11 #include "base/utf_string_conversions.h"
11 12
12 // static 13 // static
13 Version* Version::GetVersionFromString(const std::wstring& version_str) { 14 Version* Version::GetVersionFromString(const std::wstring& version_str) {
14 if (!IsStringASCII(version_str)) 15 if (!IsStringASCII(version_str))
15 return NULL; 16 return NULL;
16 return GetVersionFromString(WideToUTF8(version_str)); 17 return GetVersionFromString(WideToUTF8(version_str));
17 } 18 }
18 19
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 return false; 88 return false;
88 // This throws out things like +3, or 032. 89 // This throws out things like +3, or 032.
89 if (base::IntToString(num) != *i) 90 if (base::IntToString(num) != *i)
90 return false; 91 return false;
91 uint16 component = static_cast<uint16>(num); 92 uint16 component = static_cast<uint16>(num);
92 components_.push_back(component); 93 components_.push_back(component);
93 } 94 }
94 is_valid_ = true; 95 is_valid_ = true;
95 return true; 96 return true;
96 } 97 }
OLDNEW
« no previous file with comments | « base/string_util_unittest.cc ('k') | chrome/app/breakpad_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698