summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJames0124 <gladiatorrules22@gmail.com>2025-04-23 03:08:27 +0900
committerGitHub <noreply@github.com>2025-04-22 18:08:27 +0000
commitd5220b327632a8aeeb9a89494bb37bd82fec30cb (patch)
tree38b79366dbca214be3b54712c16e8ff89682b7af
parentcb361223b88a21446cea60d316e3c01b7f8c2546 (diff)
Add SLANG_OVERRIDE to SLANG_IUNKNOWN_ macros (#6864)
-rw-r--r--include/slang-com-helper.h28
1 files changed, 14 insertions, 14 deletions
diff --git a/include/slang-com-helper.h b/include/slang-com-helper.h
index 557b278df..cc36b6de9 100644
--- a/include/slang-com-helper.h
+++ b/include/slang-com-helper.h
@@ -139,22 +139,22 @@ SLANG_FORCE_INLINE bool operator!=(const Slang::Guid& a, const Slang::Guid& b)
return SLANG_E_NO_INTERFACE; \
}
- #define SLANG_IUNKNOWN_ADD_REF \
- SLANG_NO_THROW uint32_t SLANG_MCALL addRef() \
- { \
- return ++m_refCount; \
+ #define SLANG_IUNKNOWN_ADD_REF \
+ SLANG_NO_THROW uint32_t SLANG_MCALL addRef() SLANG_OVERRIDE \
+ { \
+ return ++m_refCount; \
}
- #define SLANG_IUNKNOWN_RELEASE \
- SLANG_NO_THROW uint32_t SLANG_MCALL release() \
- { \
- --m_refCount; \
- if (m_refCount == 0) \
- { \
- delete this; \
- return 0; \
- } \
- return m_refCount; \
+ #define SLANG_IUNKNOWN_RELEASE \
+ SLANG_NO_THROW uint32_t SLANG_MCALL release() SLANG_OVERRIDE \
+ { \
+ --m_refCount; \
+ if (m_refCount == 0) \
+ { \
+ delete this; \
+ return 0; \
+ } \
+ return m_refCount; \
}
#define SLANG_IUNKNOWN_ALL \