Fix thread_local test

If _Thread_local is used on a block-scope declaration, it must be
combined with either static or extern to decide linkage.

Change-Id: I228b3520767197c6cdf5134ff5a666ab2aca33ea
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
bb10
Samuli Piippo 2018-02-22 16:48:24 +02:00
parent ab28ef132e
commit bcd5532fcb
1 changed files with 1 additions and 1 deletions

View File

@ -110,7 +110,7 @@ Q_STATIC_ASSERT(!!1);
static thread_local int gt_var;
void thread_local_test()
{
thread_local int t_var;
static thread_local int t_var;
t_var = gt_var;
}
#endif