Lines Matching refs:ScopedRefPtrToSelf
37 class ScopedRefPtrToSelf : public base::RefCounted<ScopedRefPtrToSelf> { class
39 ScopedRefPtrToSelf() : self_ptr_(this) {} in ScopedRefPtrToSelf() function in __anon091b83080111::ScopedRefPtrToSelf
45 scoped_refptr<ScopedRefPtrToSelf> self_ptr_;
48 friend class base::RefCounted<ScopedRefPtrToSelf>;
49 ~ScopedRefPtrToSelf() { was_destroyed_ = true; } in ~ScopedRefPtrToSelf()
54 bool ScopedRefPtrToSelf::was_destroyed_ = false;
122 ScopedRefPtrToSelf::reset_was_destroyed(); in TEST()
124 ScopedRefPtrToSelf* check = new ScopedRefPtrToSelf(); in TEST()
125 EXPECT_FALSE(ScopedRefPtrToSelf::was_destroyed()); in TEST()
127 EXPECT_TRUE(ScopedRefPtrToSelf::was_destroyed()); in TEST()
131 ScopedRefPtrToSelf::reset_was_destroyed(); in TEST()
133 ScopedRefPtrToSelf* check = new ScopedRefPtrToSelf(); in TEST()
134 EXPECT_FALSE(ScopedRefPtrToSelf::was_destroyed()); in TEST()
138 check->self_ptr_ = scoped_refptr<ScopedRefPtrToSelf>(); in TEST()
139 EXPECT_TRUE(ScopedRefPtrToSelf::was_destroyed()); in TEST()