From 49fb919fbc88160aa4c3ddbae65f073c53b2d475 Mon Sep 17 00:00:00 2001 From: Thomas Krijnen Date: Fri, 9 Aug 2019 10:05:49 +0200 Subject: [PATCH] thread_local define for clang --- src/ifcparse/IfcParse.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/ifcparse/IfcParse.h b/src/ifcparse/IfcParse.h index 83b10f0796..4dc960c31f 100644 --- a/src/ifcparse/IfcParse.h +++ b/src/ifcparse/IfcParse.h @@ -49,8 +49,9 @@ #include "../ifcparse/IfcSpfStream.h" - /* gcc doesn't know _Thread_local from C11 yet */ -#ifdef __GNUC__ +#if defined(__clang__) +# define my_thread_local thread_local +#elif defined(__GNUC__) # define my_thread_local __thread #elif __STDC_VERSION__ >= 201112L # define my_thread_local _Thread_local