@@ -52,7 +52,8 @@ void EnterCritical(const char* pszName, const char* pszFile, int nLine, void* cs
5252void LeaveCritical ();
5353void CheckLastCritical (void * cs, std::string& lockname, const char * guardname, const char * file, int line);
5454std::string LocksHeld ();
55- void AssertLockHeldInternal (const char * pszName, const char * pszFile, int nLine, void * cs) ASSERT_EXCLUSIVE_LOCK(cs);
55+ template <typename MutexType>
56+ void AssertLockHeldInternal (const char * pszName, const char * pszFile, int nLine, MutexType* cs) ASSERT_EXCLUSIVE_LOCK(cs);
5657void AssertLockNotHeldInternal (const char * pszName, const char * pszFile, int nLine, void * cs);
5758void DeleteLock (void * cs);
5859
@@ -66,7 +67,8 @@ extern bool g_debug_lockorder_abort;
6667void static inline EnterCritical (const char * pszName, const char * pszFile, int nLine, void * cs, bool fTry = false ) {}
6768void static inline LeaveCritical () {}
6869void static inline CheckLastCritical (void * cs, std::string& lockname, const char * guardname, const char * file, int line) {}
69- void static inline AssertLockHeldInternal (const char * pszName, const char * pszFile, int nLine, void * cs) ASSERT_EXCLUSIVE_LOCK(cs) {}
70+ template <typename MutexType>
71+ void static inline AssertLockHeldInternal (const char * pszName, const char * pszFile, int nLine, MutexType* cs) ASSERT_EXCLUSIVE_LOCK(cs) {}
7072void static inline AssertLockNotHeldInternal (const char * pszName, const char * pszFile, int nLine, void * cs) {}
7173void static inline DeleteLock (void * cs) {}
7274#endif
0 commit comments