Updated with platform checks

This commit is contained in:
Yucheng Low
2015-12-15 14:26:03 -08:00
parent b9f55efe98
commit 3f14031142
2 changed files with 81 additions and 3 deletions

View File

@ -191,10 +191,12 @@ BOOST_REGEX_DECL void BOOST_REGEX_CALL put_mem_block(void* p)
#else
#ifdef BOOST_HAS_THREADS
#if defined(BOOST_REGEX_MEM_BLOCK_CACHE_LOCK_FREE)
mem_block_cache block_cache;
#elif defined(BOOST_HAS_THREADS)
mem_block_cache block_cache = { 0, 0, BOOST_STATIC_MUTEX_INIT, };
#else
mem_block_cache block_cache;
mem_block_cache block_cache = { 0, 0, };
#endif
BOOST_REGEX_DECL void* BOOST_REGEX_CALL get_mem_block()