Lines Matching refs:fPtr
23 explicit SkTLazy(const T* src) : fPtr(src ? new (&fStorage) T(*src) : nullptr) {} in SkTLazy()
24 SkTLazy(const SkTLazy& that) : fPtr(that.fPtr ? new (&fStorage) T(*that.fPtr) : nullptr) {} in SkTLazy()
25 SkTLazy(SkTLazy&& that) : fPtr(that.fPtr ? new (&fStorage) T(std::move(*that.fPtr)) : nullptr){} in SkTLazy()
55 fPtr = new (&fStorage) T(std::forward<Args>(args)...); in init()
56 return fPtr; in init()
67 *fPtr = src; in set()
69 fPtr = new (&fStorage) T(src); in set()
71 return fPtr; in set()
76 *fPtr = std::move(src); in set()
78 fPtr = new (&fStorage) T(std::move(src)); in set()
80 return fPtr; in set()
88 fPtr->~T(); in reset()
89 fPtr = nullptr; in reset()
97 bool isValid() const { return SkToBool(fPtr); } in isValid()
103 T* get() const { SkASSERT(this->isValid()); return fPtr; } in get()
111 T* getMaybeNull() const { return fPtr; } in getMaybeNull()
115 T* fPtr{nullptr}; // nullptr or fStorage