Home | History | Annotate | Download | only in tr1

Lines Matching refs:__r

141         __shared_count(std::auto_ptr<_Tp>& __r)
143 _Sp_deleter<_Tp>, _Lp >(__r.get(), _Sp_deleter<_Tp>()))
144 { __r.release(); }
146 // Throw bad_weak_ptr when __r._M_get_use_count() == 0.
148 __shared_count(const __weak_count<_Lp>& __r);
156 __shared_count(const __shared_count& __r)
157 : _M_pi(__r._M_pi) // nothrow
164 operator=(const __shared_count& __r) // nothrow
166 _Sp_counted_base<_Lp>* __tmp = __r._M_pi;
179 _M_swap(__shared_count& __r) // nothrow
181 _Sp_counted_base<_Lp>* __tmp = __r._M_pi;
182 __r._M_pi = _M_pi;
221 __weak_count(const __shared_count<_Lp>& __r)
222 : _M_pi(__r._M_pi) // nothrow
228 __weak_count(const __weak_count<_Lp>& __r)
229 : _M_pi(__r._M_pi) // nothrow
242 operator=(const __shared_count<_Lp>& __r) // nothrow
244 _Sp_counted_base<_Lp>* __tmp = __r._M_pi;
254 operator=(const __weak_count<_Lp>& __r) // nothrow
256 _Sp_counted_base<_Lp>* __tmp = __r._M_pi;
266 _M_swap(__weak_count<_Lp>& __r) // nothrow
268 _Sp_counted_base<_Lp>* __tmp = __r._M_pi;
269 __r._M_pi = _M_pi;
295 __shared_count(const __weak_count<_Lp>& __r)
296 : _M_pi(__r._M_pi)
408 /** @brief If @a __r is empty, constructs an empty %__shared_ptr;
410 * with @a __r.
411 * @param __r A %__shared_ptr.
412 * @post get() == __r.get() && use_count() == __r.use_count()
415 __shared_ptr(const __shared_ptr<_Tp1, _Lp>& __r)
416 : _M_ptr(__r._M_ptr), _M_refcount(__r._M_refcount) // never throws
419 /** @brief Constructs a %__shared_ptr that shares ownership with @a __r
420 * and stores a copy of the pointer stored in @a __r.
421 * @param __r A weak_ptr.
422 * @post use_count() == __r.use_count()
423 * @throw bad_weak_ptr when __r.expired(),
428 __shared_ptr(const __weak_ptr<_Tp1, _Lp>& __r)
429 : _M_refcount(__r._M_refcount) // may throw
432 // It is now safe to copy __r._M_ptr, as _M_refcount(__r._M_refcount)
434 _M_ptr = __r._M_ptr;
439 * @post use_count() == 1 and __r.get() == 0
443 __shared_ptr(std::auto_ptr<_Tp1>& __r)
444 : _M_ptr(__r.get()), _M_refcount()
447 // TODO requires _Tp1 is complete, delete __r.release() well-formed
448 _Tp1* __tmp = __r.get();
449 _M_refcount = __shared_count<_Lp>(__r);
456 __shared_ptr(const __shared_ptr<_Tp1, _Lp>& __r, __static_cast_tag)
457 : _M_ptr(static_cast<element_type*>(__r._M_ptr)),
458 _M_refcount(__r._M_refcount)
462 __shared_ptr(const __shared_ptr<_Tp1, _Lp>& __r, __const_cast_tag)
463 : _M_ptr(const_cast<element_type*>(__r._M_ptr)),
464 _M_refcount(__r._M_refcount)
468 __shared_ptr(const __shared_ptr<_Tp1, _Lp>& __r, __dynamic_cast_tag)
469 : _M_ptr(dynamic_cast<element_type*>(__r._M_ptr)),
470 _M_refcount(__r._M_refcount)
478 operator=(const __shared_ptr<_Tp1, _Lp>& __r) // never throws
480 _M_ptr = __r._M_ptr;
481 _M_refcount = __r._M_refcount; // __shared_count::op= doesn't throw
488 operator=(std::auto_ptr<_Tp1>& __r)
490 __shared_ptr(__r).swap(*this);
599 * <code>shared_ptr<_Tp, _Lp>(static_cast<_Tp*>(__r.get()))</code>
605 static_pointer_cast(const __shared_ptr<_Tp1, _Lp>& __r)
606 { return __shared_ptr<_Tp, _Lp>(__r, __static_cast_tag()); }
609 * <code>shared_ptr<_Tp, _Lp>(const_cast<_Tp*>(__r.get()))</code>
615 const_pointer_cast(const __shared_ptr<_Tp1, _Lp>& __r)
616 { return __shared_ptr<_Tp, _Lp>(__r, __const_cast_tag()); }
619 * <code>shared_ptr<_Tp, _Lp>(dynamic_cast<_Tp*>(__r.get()))</code>
625 dynamic_pointer_cast(const __shared_ptr<_Tp1, _Lp>& __r)
626 { return __shared_ptr<_Tp, _Lp>(__r, __dynamic_cast_tag()); }
660 // __weak_ptr(const __weak_ptr<_Tp1, _Lp>& __r)
661 // : _M_ptr(__r._M_ptr), _M_refcount(__r._M_refcount) // never throws
666 // __r._M_ptr may already have been invalidated. The _M_ptr(__r._M_ptr)
667 // conversion may require access to *__r._M_ptr (virtual inheritance).
670 // in multithreaded programs __r._M_ptr may be invalidated at any point.
672 __weak_ptr(const __weak_ptr<_Tp1, _Lp>& __r)
673 : _M_refcount(__r._M_refcount) // never throws
676 _M_ptr = __r.lock().get();
680 __weak_ptr(const __shared_ptr<_Tp1, _Lp>& __r)
681 : _M_ptr(__r._M_ptr), _M_refcount(__r._M_refcount) // never throws
686 operator=(const __weak_ptr<_Tp1, _Lp>& __r) // never throws
688 _M_ptr = __r.lock().get();
689 _M_refcount = __r._M_refcount;
695 operator=(const __shared_ptr<_Tp1, _Lp>& __r) // never throws
697 _M_ptr = __r._M_ptr;
698 _M_refcount = __r._M_refcount;
849 shared_ptr(const shared_ptr<_Tp1>& __r)
850 : __shared_ptr<_Tp>(__r) { }
854 shared_ptr(const weak_ptr<_Tp1>& __r)
855 : __shared_ptr<_Tp>(__r) { }
860 shared_ptr(std::auto_ptr<_Tp1>& __r)
861 : __shared_ptr<_Tp>(__r) { }
865 shared_ptr(const shared_ptr<_Tp1>& __r, __static_cast_tag)
866 : __shared_ptr<_Tp>(__r, __static_cast_tag()) { }
869 shared_ptr(const shared_ptr<_Tp1>& __r, __const_cast_tag)
870 : __shared_ptr<_Tp>(__r, __const_cast_tag()) { }
873 shared_ptr(const shared_ptr<_Tp1>& __r, __dynamic_cast_tag)
874 : __shared_ptr<_Tp>(__r, __dynamic_cast_tag()) { }
878 operator=(const shared_ptr<_Tp1>& __r) // never throws
880 this->__shared_ptr<_Tp>::operator=(__r);
887 operator=(std::auto_ptr<_Tp1>& __r)
889 this->__shared_ptr<_Tp>::operator=(__r);
903 static_pointer_cast(const shared_ptr<_Tp1>& __r)
904 { return shared_ptr<_Tp>(__r, __static_cast_tag()); }
908 const_pointer_cast(const shared_ptr<_Tp1>& __r)
909 { return shared_ptr<_Tp>(__r, __const_cast_tag()); }
913 dynamic_pointer_cast(const shared_ptr<_Tp1>& __r)
914 { return shared_ptr<_Tp>(__r, __dynamic_cast_tag()); }
929 weak_ptr(const weak_ptr<_Tp1>& __r)
930 : __weak_ptr<_Tp>(__r) { }
933 weak_ptr(const shared_ptr<_Tp1>& __r)
934 : __weak_ptr<_Tp>(__r) { }
938 operator=(const weak_ptr<_Tp1>& __r) // never throws
940 this->__weak_ptr<_Tp>::operator=(__r);
946 operator=(const shared_ptr<_Tp1>& __r) // never throws
948 this->__weak_ptr<_Tp>::operator=(__r);