projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7847229
)
Fix a -Wunused-local-typedefs warning
author
Alp Toker
<alp@nuanti.com>
Mon, 14 Jul 2014 22:46:45 +0000
(22:46 +0000)
committer
Alp Toker
<alp@nuanti.com>
Mon, 14 Jul 2014 22:46:45 +0000
(22:46 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@213002
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/Support/Windows/ThreadLocal.inc
patch
|
blob
|
history
diff --git
a/lib/Support/Windows/ThreadLocal.inc
b/lib/Support/Windows/ThreadLocal.inc
index 3914cf72fa95d143eb3cb91c7711ec24c748948b..14ce61933cba72a559ecbadae560f20d386483dd 100644
(file)
--- a/
lib/Support/Windows/ThreadLocal.inc
+++ b/
lib/Support/Windows/ThreadLocal.inc
@@
-23,7
+23,7
@@
namespace llvm {
using namespace sys;
ThreadLocalImpl::ThreadLocalImpl() : data() {
-
typedef int SIZE_TOO_BIG[sizeof(DWORD) <= sizeof(data) ? 1 : -1]
;
+
static_assert(sizeof(DWORD) <= sizeof(data), "size too big")
;
DWORD* tls = reinterpret_cast<DWORD*>(&data);
*tls = TlsAlloc();
assert(*tls != TLS_OUT_OF_INDEXES);