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

Side by Side Diff: base/strings/string_util.cc

Issue 100303003: Move more uses of string16 to specify base:: (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years 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 | Annotate | Revision Log
« no previous file with comments | « base/strings/string_util.h ('k') | ipc/ipc_message_utils.h » ('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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/strings/string_util.h" 5 #include "base/strings/string_util.h"
6 6
7 #include <ctype.h> 7 #include <ctype.h>
8 #include <errno.h> 8 #include <errno.h>
9 #include <math.h> 9 #include <math.h>
10 #include <stdarg.h> 10 #include <stdarg.h>
11 #include <stdio.h> 11 #include <stdio.h>
12 #include <stdlib.h> 12 #include <stdlib.h>
13 #include <string.h> 13 #include <string.h>
14 #include <time.h> 14 #include <time.h>
15 #include <wchar.h> 15 #include <wchar.h>
16 #include <wctype.h> 16 #include <wctype.h>
17 17
18 #include <algorithm> 18 #include <algorithm>
19 #include <vector> 19 #include <vector>
20 20
21 #include "base/basictypes.h" 21 #include "base/basictypes.h"
22 #include "base/logging.h" 22 #include "base/logging.h"
23 #include "base/memory/singleton.h" 23 #include "base/memory/singleton.h"
24 #include "base/strings/utf_string_conversion_utils.h" 24 #include "base/strings/utf_string_conversion_utils.h"
25 #include "base/strings/utf_string_conversions.h" 25 #include "base/strings/utf_string_conversions.h"
26 #include "base/third_party/icu/icu_utf.h" 26 #include "base/third_party/icu/icu_utf.h"
27 #include "build/build_config.h" 27 #include "build/build_config.h"
28 28
29 // Remove when this entire file is in the base namespace.
30 using base::char16;
31 using base::string16;
32
29 namespace { 33 namespace {
30 34
31 // Force the singleton used by Empty[W]String[16] to be a unique type. This 35 // Force the singleton used by Empty[W]String[16] to be a unique type. This
32 // prevents other code that might accidentally use Singleton<string> from 36 // prevents other code that might accidentally use Singleton<string> from
33 // getting our internal one. 37 // getting our internal one.
34 struct EmptyStrings { 38 struct EmptyStrings {
35 EmptyStrings() {} 39 EmptyStrings() {}
36 const std::string s; 40 const std::string s;
37 const std::wstring ws; 41 const std::wstring ws;
38 const string16 s16; 42 const string16 s16;
(...skipping 885 matching lines...) Expand 10 before | Expand all | Expand 10 after
924 } 928 }
925 929
926 } // namespace 930 } // namespace
927 931
928 size_t base::strlcpy(char* dst, const char* src, size_t dst_size) { 932 size_t base::strlcpy(char* dst, const char* src, size_t dst_size) {
929 return lcpyT<char>(dst, src, dst_size); 933 return lcpyT<char>(dst, src, dst_size);
930 } 934 }
931 size_t base::wcslcpy(wchar_t* dst, const wchar_t* src, size_t dst_size) { 935 size_t base::wcslcpy(wchar_t* dst, const wchar_t* src, size_t dst_size) {
932 return lcpyT<wchar_t>(dst, src, dst_size); 936 return lcpyT<wchar_t>(dst, src, dst_size);
933 } 937 }
OLDNEW
« no previous file with comments | « base/strings/string_util.h ('k') | ipc/ipc_message_utils.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698