/* * Copyright 2015 Google Inc. * * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file. */ #ifndef GrNonAtomicRef_DEFINED #define GrNonAtomicRef_DEFINED #include "include/core/SkTypes.h" #include "include/private/base/SkNoncopyable.h" #include <cstdint> /** * A simple non-atomic ref used in the GrBackendApi when we don't want to pay for the overhead of a * threadsafe ref counted object */ template<typename TSubclass> class GrNonAtomicRef : public SkNoncopyable { … }; template<typename T> inline void GrTDeleteNonAtomicRef(const T* ref) { … } #endif