diff options
Diffstat (limited to 'source/core/slang-smart-pointer.h')
| -rw-r--r-- | source/core/slang-smart-pointer.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/source/core/slang-smart-pointer.h b/source/core/slang-smart-pointer.h index bae30de37..ebc6f20b0 100644 --- a/source/core/slang-smart-pointer.h +++ b/source/core/slang-smart-pointer.h @@ -235,6 +235,12 @@ namespace Slang return rs; } + SLANG_FORCE_INLINE void setNull() + { + releaseReference(pointer); + pointer = nullptr; + } + /// Get ready for writing (nulls contents) SLANG_FORCE_INLINE T** writeRef() { *this = nullptr; return &pointer; } |
