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

Side by Side Diff: base/memory/scoped_ptr.h

Issue 1549003002: Switch to standard integer types in base/memory/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 12 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/memory/ref_counted_memory_unittest.cc ('k') | base/memory/scoped_ptr_unittest.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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // Scopers help you manage ownership of a pointer, helping you easily manage a 5 // Scopers help you manage ownership of a pointer, helping you easily manage a
6 // pointer within a scope, and automatically destroying the pointer at the end 6 // pointer within a scope, and automatically destroying the pointer at the end
7 // of a scope. There are two main classes you will use, which correspond to the 7 // of a scope. There are two main classes you will use, which correspond to the
8 // operators new/delete and new[]/delete[]. 8 // operators new/delete and new[]/delete[].
9 // 9 //
10 // Example usage (scoped_ptr<T>): 10 // Example usage (scoped_ptr<T>):
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 83
84 #include <assert.h> 84 #include <assert.h>
85 #include <stddef.h> 85 #include <stddef.h>
86 #include <stdlib.h> 86 #include <stdlib.h>
87 87
88 #include <iosfwd> 88 #include <iosfwd>
89 #include <memory> 89 #include <memory>
90 #include <type_traits> 90 #include <type_traits>
91 #include <utility> 91 #include <utility>
92 92
93 #include "base/basictypes.h"
94 #include "base/compiler_specific.h" 93 #include "base/compiler_specific.h"
94 #include "base/macros.h"
95 #include "base/move.h" 95 #include "base/move.h"
96 #include "base/template_util.h" 96 #include "base/template_util.h"
97 97
98 namespace base { 98 namespace base {
99 99
100 namespace subtle { 100 namespace subtle {
101 class RefCountedBase; 101 class RefCountedBase;
102 class RefCountedThreadSafeBase; 102 class RefCountedThreadSafeBase;
103 } // namespace subtle 103 } // namespace subtle
104 104
(...skipping 493 matching lines...) Expand 10 before | Expand all | Expand 10 after
598 scoped_ptr<T> make_scoped_ptr(T* ptr) { 598 scoped_ptr<T> make_scoped_ptr(T* ptr) {
599 return scoped_ptr<T>(ptr); 599 return scoped_ptr<T>(ptr);
600 } 600 }
601 601
602 template <typename T> 602 template <typename T>
603 std::ostream& operator<<(std::ostream& out, const scoped_ptr<T>& p) { 603 std::ostream& operator<<(std::ostream& out, const scoped_ptr<T>& p) {
604 return out << p.get(); 604 return out << p.get();
605 } 605 }
606 606
607 #endif // BASE_MEMORY_SCOPED_PTR_H_ 607 #endif // BASE_MEMORY_SCOPED_PTR_H_
OLDNEW
« no previous file with comments | « base/memory/ref_counted_memory_unittest.cc ('k') | base/memory/scoped_ptr_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698