Home
last modified time | relevance | path

Searched refs:ptr_ (Results 1 – 25 of 184) sorted by relevance

12345678

/external/rust/crates/grpcio-sys/grpc/third_party/upb/upb/
Ddef.hpp24 FieldDefPtr() : ptr_(nullptr) {} in FieldDefPtr()
25 explicit FieldDefPtr(const upb_fielddef* ptr) : ptr_(ptr) {} in FieldDefPtr()
27 const upb_fielddef* ptr() const { return ptr_; } in ptr()
28 explicit operator bool() const { return ptr_ != nullptr; } in operator bool()
34 const char* full_name() const { return upb_fielddef_fullname(ptr_); } in full_name()
36 Type type() const { return upb_fielddef_type(ptr_); } in type()
37 Label label() const { return upb_fielddef_label(ptr_); } in label()
38 const char* name() const { return upb_fielddef_name(ptr_); } in name()
39 const char* json_name() const { return upb_fielddef_jsonname(ptr_); } in json_name()
40 uint32_t number() const { return upb_fielddef_number(ptr_); } in number()
[all …]
/external/tensorflow/tensorflow/compiler/xrt/
Dxrt_refptr.h33 RefPtr(T* ptr) : ptr_(ptr) {} // NOLINT in RefPtr()
34 RefPtr(const RefPtr& other) : ptr_(other.ptr_) { Acquire(ptr_); } in RefPtr()
35 RefPtr(RefPtr&& other) : ptr_(other.ptr_) { other.ptr_ = nullptr; } in RefPtr()
37 ~RefPtr() { Release(ptr_); } in ~RefPtr()
41 Acquire(other.ptr_);
42 Release(ptr_);
43 ptr_ = other.ptr_;
50 Release(ptr_);
51 ptr_ = other.ptr_;
52 other.ptr_ = nullptr;
[all …]
/external/protobuf/src/google/protobuf/
Darenastring.h59 void Set(T* p) { ptr_ = reinterpret_cast<uintptr_t>(p); } in Set()
60 T* Get() const { return reinterpret_cast<T*>(ptr_); } in Get()
62 bool IsNull() { return ptr_ == 0; } in IsNull()
65 uintptr_t ptr_;
71 if (ptr_ == default_value) { in Set()
74 *ptr_ = value; in Set()
84 inline const ::std::string& Get() const { return *ptr_; } in Get()
88 if (ptr_ == default_value) { in Mutable()
91 return ptr_; in Mutable()
100 if (ptr_ == default_value) { in Release()
[all …]
/external/webrtc/api/
Dscoped_refptr.h76 scoped_refptr() : ptr_(nullptr) {} in scoped_refptr()
78 scoped_refptr(T* p) : ptr_(p) { // NOLINT(runtime/explicit) in scoped_refptr()
79 if (ptr_) in scoped_refptr()
80 ptr_->AddRef(); in scoped_refptr()
83 scoped_refptr(const scoped_refptr<T>& r) : ptr_(r.ptr_) { in scoped_refptr()
84 if (ptr_) in scoped_refptr()
85 ptr_->AddRef(); in scoped_refptr()
89 scoped_refptr(const scoped_refptr<U>& r) : ptr_(r.get()) { in scoped_refptr()
90 if (ptr_) in scoped_refptr()
91 ptr_->AddRef(); in scoped_refptr()
[all …]
/external/webrtc/sdk/objc/helpers/
Dscoped_cftyperef.h38 ScopedTypeRef() : ptr_(Traits::InvalidValue()) {} in ScopedTypeRef()
39 explicit ScopedTypeRef(T ptr) : ptr_(ptr) {} in ScopedTypeRef()
41 if (ptr_ && policy == RetainPolicy::RETAIN) in ScopedTypeRef()
42 Traits::Retain(ptr_); in ScopedTypeRef()
45 ScopedTypeRef(const ScopedTypeRef<T, Traits>& rhs) : ptr_(rhs.ptr_) { in ScopedTypeRef()
46 if (ptr_) in ScopedTypeRef()
47 ptr_ = Traits::Retain(ptr_); in ScopedTypeRef()
51 if (ptr_) { in ~ScopedTypeRef()
52 Traits::Release(ptr_); in ~ScopedTypeRef()
56 T get() const { return ptr_; } in get()
[all …]
/external/libchrome/base/
Dbig_endian.cc12 : ptr_(buf), end_(ptr_ + len) {} in BigEndianReader()
15 if (ptr_ + len > end_) in Skip()
17 ptr_ += len; in Skip()
22 if (ptr_ + len > end_) in ReadBytes()
24 memcpy(out, ptr_, len); in ReadBytes()
25 ptr_ += len; in ReadBytes()
30 if (ptr_ + len > end_) in ReadPiece()
32 *out = base::StringPiece(ptr_, len); in ReadPiece()
33 ptr_ += len; in ReadPiece()
39 if (ptr_ + sizeof(T) > end_) in Read()
[all …]
/external/google-breakpad/src/common/
Dscoped_ptr.h92 explicit scoped_ptr(C* p = NULL) : ptr_(p) { } in ptr_() function
98 delete ptr_; in ~scoped_ptr() local
105 if (p != ptr_) {
107 delete ptr_; variable
108 ptr_ = p;
115 assert(ptr_ != NULL);
116 return *ptr_;
119 assert(ptr_ != NULL);
120 return ptr_;
122 C* get() const { return ptr_; } in get()
[all …]
/external/perfetto/include/perfetto/protozero/
Dcopyable_ptr.h41 CopyablePtr() : ptr_(new T()) {} in CopyablePtr()
45 CopyablePtr(const CopyablePtr& other) : ptr_(new T(*other.ptr_)) {} in CopyablePtr()
47 *ptr_ = *other.ptr_;
52 CopyablePtr(CopyablePtr&& other) noexcept : ptr_(std::move(other.ptr_)) { in CopyablePtr()
53 other.ptr_.reset(new T()); in CopyablePtr()
57 ptr_ = std::move(other.ptr_);
58 other.ptr_.reset(new T());
62 T* get() { return ptr_.get(); } in get()
63 const T* get() const { return ptr_.get(); } in get()
65 T* operator->() { return ptr_.get(); }
[all …]
/external/libcxx/test/support/
Dmin_allocator.h202 const void* ptr_; variable
205 min_pointer(std::nullptr_t) TEST_NOEXCEPT : ptr_(nullptr) {} in min_pointer()
207 min_pointer(min_pointer<T, ID> p) TEST_NOEXCEPT : ptr_(p.ptr_) {} in min_pointer()
209 explicit operator bool() const {return ptr_ != nullptr;}
211 friend bool operator==(min_pointer x, min_pointer y) {return x.ptr_ == y.ptr_;}
219 void* ptr_; variable
222 min_pointer(std::nullptr_t) TEST_NOEXCEPT : ptr_(nullptr) {} in min_pointer()
229 min_pointer(min_pointer<T, ID> p) TEST_NOEXCEPT : ptr_(p.ptr_) {} in min_pointer()
231 explicit operator bool() const {return ptr_ != nullptr;}
233 friend bool operator==(min_pointer x, min_pointer y) {return x.ptr_ == y.ptr_;}
[all …]
/external/protobuf/src/google/protobuf/stubs/
Dstringpiece.cc53 : ptr_(x.ptr_ + pos), length_(x.length_ - pos) { in StringPiece()
61 : ptr_(x.ptr_ + pos), length_(std::min(len, x.length_ - pos)) { in StringPiece()
68 target->assign(ptr_, length_); in CopyToString()
72 target->append(ptr_, length_); in AppendToString()
77 ptr_ += x.length_; in Consume()
96 memcpy(buf, ptr_ + pos, ret); in copy()
109 const char *result = std::search(ptr_ + pos, ptr_ + length_, in find()
110 s.ptr_, s.ptr_ + s.length_); in find()
111 return result == ptr_ + length_ ? npos : result - ptr_; in find()
119 memchr(ptr_ + pos, c, length_ - pos)); in find()
[all …]
/external/llvm-project/libcxx/test/support/
Dmin_allocator.h203 const void* ptr_; variable
206 min_pointer(std::nullptr_t) TEST_NOEXCEPT : ptr_(nullptr) {} in min_pointer()
208 min_pointer(min_pointer<T, ID> p) TEST_NOEXCEPT : ptr_(p.ptr_) {} in min_pointer()
210 explicit operator bool() const {return ptr_ != nullptr;}
212 friend bool operator==(min_pointer x, min_pointer y) {return x.ptr_ == y.ptr_;}
220 void* ptr_; variable
223 TEST_CONSTEXPR_CXX14 min_pointer(std::nullptr_t) TEST_NOEXCEPT : ptr_(nullptr) {} in min_pointer()
230 TEST_CONSTEXPR_CXX14 min_pointer(min_pointer<T, ID> p) TEST_NOEXCEPT : ptr_(p.ptr_) {} in min_pointer()
232 TEST_CONSTEXPR_CXX14 explicit operator bool() const {return ptr_ != nullptr;}
234 …EST_CONSTEXPR_CXX14 friend bool operator==(min_pointer x, min_pointer y) {return x.ptr_ == y.ptr_;}
[all …]
/external/protobuf/python/google/protobuf/pyext/
Dscoped_pyobject_ptr.h51 : ptr_(py_object) {} in ptr_() function
54 ~ScopedPythonPtr() { Py_XDECREF(ptr_); } in ~ScopedPythonPtr()
63 Py_XDECREF(ptr_);
64 ptr_ = p;
65 return ptr_;
71 PyObject* p = ptr_; in release()
72 ptr_ = NULL; in release()
76 PyObjectStruct* get() const { return ptr_; } in get()
78 PyObject* as_pyobject() const { return reinterpret_cast<PyObject*>(ptr_); } in as_pyobject()
82 void inc() const { Py_INCREF(ptr_); } in inc()
[all …]
/external/marisa-trie/include/marisa/
Dscoped-ptr.h11 scoped_ptr() : ptr_(NULL) {} in scoped_ptr()
12 explicit scoped_ptr(T *ptr) : ptr_(ptr) {} in scoped_ptr()
15 delete ptr_; in ~scoped_ptr() local
19 MARISA_DEBUG_IF((ptr != NULL) && (ptr == ptr_), MARISA_RESET_ERROR);
24 MARISA_DEBUG_IF(ptr_ == NULL, MARISA_STATE_ERROR);
25 return *ptr_;
28 MARISA_DEBUG_IF(ptr_ == NULL, MARISA_STATE_ERROR);
29 return ptr_;
32 return ptr_; in get()
39 marisa::swap(ptr_, rhs.ptr_); in swap()
[all …]
Dquery.h10 Query() : ptr_(NULL), length_(0), id_(0) {} in Query()
12 : ptr_(query.ptr_), length_(query.length_), id_(query.id_) {} in Query()
15 ptr_ = query.ptr_;
23 return ptr_[i];
32 ptr_ = str; in set_str()
37 ptr_ = ptr; in set_str()
45 return ptr_; in ptr()
58 marisa::swap(ptr_, rhs.ptr_); in swap()
64 const char *ptr_;
Dkey.h10 Key() : ptr_(NULL), length_(0), union_() { in Key()
14 : ptr_(key.ptr_), length_(key.length_), union_(key.union_) {} in Key()
17 ptr_ = key.ptr_;
25 return ptr_[i];
35 ptr_ = str; in set_str()
41 ptr_ = ptr; in set_str()
53 return ptr_; in ptr()
69 marisa::swap(ptr_, rhs.ptr_); in swap()
75 const char *ptr_;
/external/libchrome/base/task_scheduler/
Dtracked_ref.h76 : ptr_(other.ptr_), factory_(other.factory_) { in TrackedRef()
82 : ptr_(other.ptr_), factory_(other.factory_) { in TrackedRef()
100 T& operator*() const { return *ptr_; }
102 T* operator->() const { return ptr_; }
104 explicit operator bool() const { return ptr_ != nullptr; }
110 : ptr_(ptr), factory_(factory) { in TrackedRef()
114 T* ptr_; variable
123 : ptr_(ptr), self_ref_(WrapUnique(new TrackedRef<T>(ptr_, this))) { in TrackedRefFactory()
124 DCHECK(ptr_); in TrackedRefFactory()
144 return TrackedRef<T>(ptr_, this); in GetTrackedRef()
[all …]
/external/rust/crates/grpcio-sys/grpc/third_party/upb/upb/pb/
Ddecoder.h60 DecoderMethodPtr() : ptr_(nullptr) {} in DecoderMethodPtr()
61 DecoderMethodPtr(const upb_pbdecodermethod* ptr) : ptr_(ptr) {} in DecoderMethodPtr()
63 const upb_pbdecodermethod* ptr() { return ptr_; } in ptr()
69 return upb_pbdecodermethod_desthandlers(ptr_); in dest_handlers()
74 return upb_pbdecodermethod_inputhandler(ptr_); in input_handler()
79 return upb_pbdecodermethod_isnative(ptr_); in is_native()
83 const upb_pbdecodermethod* ptr_;
120 DecoderPtr() : ptr_(nullptr) {} in DecoderPtr()
121 DecoderPtr(upb_pbdecoder* ptr) : ptr_(ptr) {} in DecoderPtr()
123 upb_pbdecoder* ptr() { return ptr_; } in ptr()
[all …]
/external/rust/crates/grpcio-sys/grpc/third_party/abseil-cpp/absl/strings/
Dstring_view.cc88 strings_internal::memmatch(ptr_ + pos, length_ - pos, s.ptr_, s.length_); in find()
89 return result ? result - ptr_ : npos; in find()
97 static_cast<const char*>(memchr(ptr_ + pos, c, length_ - pos)); in find()
98 return result != nullptr ? result - ptr_ : npos; in find()
105 const char* last = ptr_ + std::min(length_ - s.length_, pos) + s.length_; in rfind()
106 const char* result = std::find_end(ptr_, last, s.ptr_, s.ptr_ + s.length_); in rfind()
107 return result != last ? result - ptr_ : npos; in rfind()
116 if (ptr_[i] == c) { in rfind()
131 if (s.length_ == 1) return find_first_of(s.ptr_[0], pos); in find_first_of()
134 if (tbl[ptr_[i]]) { in find_first_of()
[all …]
/external/abseil-cpp/absl/strings/
Dstring_view.cc88 strings_internal::memmatch(ptr_ + pos, length_ - pos, s.ptr_, s.length_); in find()
89 return result ? result - ptr_ : npos; in find()
97 static_cast<const char*>(memchr(ptr_ + pos, c, length_ - pos)); in find()
98 return result != nullptr ? result - ptr_ : npos; in find()
105 const char* last = ptr_ + std::min(length_ - s.length_, pos) + s.length_; in rfind()
106 const char* result = std::find_end(ptr_, last, s.ptr_, s.ptr_ + s.length_); in rfind()
107 return result != last ? result - ptr_ : npos; in rfind()
116 if (ptr_[i] == c) { in rfind()
131 if (s.length_ == 1) return find_first_of(s.ptr_[0], pos); in find_first_of()
134 if (tbl[ptr_[i]]) { in find_first_of()
[all …]
/external/libtextclassifier/abseil-cpp/absl/strings/
Dstring_view.cc88 strings_internal::memmatch(ptr_ + pos, length_ - pos, s.ptr_, s.length_); in find()
89 return result ? result - ptr_ : npos; in find()
97 static_cast<const char*>(memchr(ptr_ + pos, c, length_ - pos)); in find()
98 return result != nullptr ? result - ptr_ : npos; in find()
105 const char* last = ptr_ + std::min(length_ - s.length_, pos) + s.length_; in rfind()
106 const char* result = std::find_end(ptr_, last, s.ptr_, s.ptr_ + s.length_); in rfind()
107 return result != last ? result - ptr_ : npos; in rfind()
116 if (ptr_[i] == c) { in rfind()
131 if (s.length_ == 1) return find_first_of(s.ptr_[0], pos); in find_first_of()
134 if (tbl[ptr_[i]]) { in find_first_of()
[all …]
/external/openscreen/third_party/abseil/src/absl/strings/
Dstring_view.cc88 strings_internal::memmatch(ptr_ + pos, length_ - pos, s.ptr_, s.length_); in find()
89 return result ? result - ptr_ : npos; in find()
97 static_cast<const char*>(memchr(ptr_ + pos, c, length_ - pos)); in find()
98 return result != nullptr ? result - ptr_ : npos; in find()
105 const char* last = ptr_ + std::min(length_ - s.length_, pos) + s.length_; in rfind()
106 const char* result = std::find_end(ptr_, last, s.ptr_, s.ptr_ + s.length_); in rfind()
107 return result != last ? result - ptr_ : npos; in rfind()
116 if (ptr_[i] == c) { in rfind()
131 if (s.length_ == 1) return find_first_of(s.ptr_[0], pos); in find_first_of()
134 if (tbl[ptr_[i]]) { in find_first_of()
[all …]
/external/webrtc/third_party/abseil-cpp/absl/strings/
Dstring_view.cc88 strings_internal::memmatch(ptr_ + pos, length_ - pos, s.ptr_, s.length_); in find()
89 return result ? result - ptr_ : npos; in find()
97 static_cast<const char*>(memchr(ptr_ + pos, c, length_ - pos)); in find()
98 return result != nullptr ? result - ptr_ : npos; in find()
105 const char* last = ptr_ + std::min(length_ - s.length_, pos) + s.length_; in rfind()
106 const char* result = std::find_end(ptr_, last, s.ptr_, s.ptr_ + s.length_); in rfind()
107 return result != last ? result - ptr_ : npos; in rfind()
116 if (ptr_[i] == c) { in rfind()
131 if (s.length_ == 1) return find_first_of(s.ptr_[0], pos); in find_first_of()
134 if (tbl[ptr_[i]]) { in find_first_of()
[all …]
/external/angle/third_party/abseil-cpp/absl/strings/
Dstring_view.cc88 strings_internal::memmatch(ptr_ + pos, length_ - pos, s.ptr_, s.length_); in find()
89 return result ? result - ptr_ : npos; in find()
97 static_cast<const char*>(memchr(ptr_ + pos, c, length_ - pos)); in find()
98 return result != nullptr ? result - ptr_ : npos; in find()
105 const char* last = ptr_ + std::min(length_ - s.length_, pos) + s.length_; in rfind()
106 const char* result = std::find_end(ptr_, last, s.ptr_, s.ptr_ + s.length_); in rfind()
107 return result != last ? result - ptr_ : npos; in rfind()
116 if (ptr_[i] == c) { in rfind()
130 if (s.length_ == 1) return find_first_of(s.ptr_[0], pos); in find_first_of()
133 if (tbl[ptr_[i]]) { in find_first_of()
[all …]
/external/libchrome/base/memory/
Dscoped_refptr.h174 constexpr scoped_refptr(T* p) : ptr_(p) { in scoped_refptr()
175 if (ptr_) in scoped_refptr()
176 AddRef(ptr_); in scoped_refptr()
181 scoped_refptr(const scoped_refptr& r) : scoped_refptr(r.ptr_) {} in scoped_refptr()
187 scoped_refptr(const scoped_refptr<U>& r) : scoped_refptr(r.ptr_) {} in scoped_refptr()
191 scoped_refptr(scoped_refptr&& r) noexcept : ptr_(r.ptr_) { r.ptr_ = nullptr; } in scoped_refptr()
197 scoped_refptr(scoped_refptr<U>&& r) noexcept : ptr_(r.ptr_) { in scoped_refptr()
198 r.ptr_ = nullptr; in scoped_refptr()
207 if (ptr_) in ~scoped_refptr()
208 Release(ptr_); in ~scoped_refptr()
[all …]
/external/webrtc/rtc_base/
Dweak_ptr.h168 WeakPtr() : ptr_(nullptr) {} in WeakPtr()
174 : internal::WeakPtrBase(other), ptr_(other.ptr_) {} in WeakPtr()
177 : internal::WeakPtrBase(std::move(other)), ptr_(other.ptr_) {} in WeakPtr()
179 T* get() const { return ref_.is_valid() ? ptr_ : nullptr; } in get()
192 ptr_ = nullptr; in reset()
204 : internal::WeakPtrBase(ref), ptr_(ptr) {} in WeakPtr()
208 T* ptr_; variable
242 explicit WeakPtrFactory(T* ptr) : ptr_(ptr) {} in WeakPtrFactory()
244 ~WeakPtrFactory() { ptr_ = nullptr; } in ~WeakPtrFactory()
247 RTC_DCHECK(ptr_); in GetWeakPtr()
[all …]

12345678