Loading libutils/binder/RefBase_test.cpp +4 −4 Original line number Diff line number Diff line Loading @@ -300,8 +300,8 @@ private: std::atomic<int>* mDeleteCount; }; static sp<Bar> buffer; static std::atomic<bool> bufferFull(false); [[clang::no_destroy]] static constinit sp<Bar> buffer; static constinit std::atomic<bool> bufferFull(false); // Wait until bufferFull has value val. static inline void waitFor(bool val) { Loading Loading @@ -380,8 +380,8 @@ TEST(RefBase, RacingDestructors) { } // Otherwise this is slow and probably pointless on a uniprocessor. } static wp<Bar> wpBuffer; static std::atomic<bool> wpBufferFull(false); [[clang::no_destroy]] static constinit wp<Bar> wpBuffer; static constinit std::atomic<bool> wpBufferFull(false); // Wait until wpBufferFull has value val. static inline void wpWaitFor(bool val) { Loading libutils/binder/include/utils/RefBase.h +1 −1 Original line number Diff line number Diff line Loading @@ -404,7 +404,7 @@ class wp public: typedef typename RefBase::weakref_type weakref_type; inline wp() : m_ptr(nullptr), m_refs(nullptr) { } inline constexpr wp() : m_ptr(nullptr), m_refs(nullptr) { } // if nullptr, returns nullptr // Loading libutils/binder/include/utils/StrongPointer.h +1 −1 Original line number Diff line number Diff line Loading @@ -30,7 +30,7 @@ template<typename T> class wp; template<typename T> class sp { public: inline sp() : m_ptr(nullptr) { } inline constexpr sp() : m_ptr(nullptr) { } // The old way of using sp<> was like this. This is bad because it relies // on implicit conversion to sp<>, which we would like to remove (if an Loading Loading
libutils/binder/RefBase_test.cpp +4 −4 Original line number Diff line number Diff line Loading @@ -300,8 +300,8 @@ private: std::atomic<int>* mDeleteCount; }; static sp<Bar> buffer; static std::atomic<bool> bufferFull(false); [[clang::no_destroy]] static constinit sp<Bar> buffer; static constinit std::atomic<bool> bufferFull(false); // Wait until bufferFull has value val. static inline void waitFor(bool val) { Loading Loading @@ -380,8 +380,8 @@ TEST(RefBase, RacingDestructors) { } // Otherwise this is slow and probably pointless on a uniprocessor. } static wp<Bar> wpBuffer; static std::atomic<bool> wpBufferFull(false); [[clang::no_destroy]] static constinit wp<Bar> wpBuffer; static constinit std::atomic<bool> wpBufferFull(false); // Wait until wpBufferFull has value val. static inline void wpWaitFor(bool val) { Loading
libutils/binder/include/utils/RefBase.h +1 −1 Original line number Diff line number Diff line Loading @@ -404,7 +404,7 @@ class wp public: typedef typename RefBase::weakref_type weakref_type; inline wp() : m_ptr(nullptr), m_refs(nullptr) { } inline constexpr wp() : m_ptr(nullptr), m_refs(nullptr) { } // if nullptr, returns nullptr // Loading
libutils/binder/include/utils/StrongPointer.h +1 −1 Original line number Diff line number Diff line Loading @@ -30,7 +30,7 @@ template<typename T> class wp; template<typename T> class sp { public: inline sp() : m_ptr(nullptr) { } inline constexpr sp() : m_ptr(nullptr) { } // The old way of using sp<> was like this. This is bad because it relies // on implicit conversion to sp<>, which we would like to remove (if an Loading