make things compile under windows again, there's still some ugly ifdefs
I'd like to get rid of
This commit is contained in:
+4
-1
@@ -50,7 +50,10 @@ class be_t
|
||||
|
||||
public:
|
||||
typedef T type;
|
||||
be_t() noexcept = default;
|
||||
#ifdef __GNUG__
|
||||
be_t() noexcept = default
|
||||
#endif
|
||||
be_t(){}
|
||||
|
||||
be_t(const T& value)
|
||||
{
|
||||
|
||||
@@ -96,7 +96,11 @@ public:
|
||||
m_cur_id = s_first_id;
|
||||
}
|
||||
|
||||
template<typename T = char>
|
||||
template<typename T
|
||||
#ifdef __GNUG__
|
||||
= char
|
||||
#endif
|
||||
>
|
||||
ID_TYPE GetNewID(const std::string& name = "", T* data = nullptr, const u32 attr = 0)
|
||||
{
|
||||
std::lock_guard<std::mutex> lock(m_mtx_main);
|
||||
|
||||
@@ -1,7 +1,12 @@
|
||||
#include "stdafx.h"
|
||||
#include "Thread.h"
|
||||
|
||||
/*__declspec(thread)*/ thread_local NamedThreadBase* g_tls_this_thread = nullptr;
|
||||
#ifdef _WIN32
|
||||
__declspec(thread)
|
||||
#else
|
||||
thread_local
|
||||
#endif
|
||||
NamedThreadBase* g_tls_this_thread = nullptr;
|
||||
|
||||
NamedThreadBase* GetCurrentNamedThread()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user