aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Support/ThreadLocal.cpp
diff options
context:
space:
mode:
authorChandler Carruth <chandlerc@gmail.com>2013-12-30 23:36:11 +0000
committerChandler Carruth <chandlerc@gmail.com>2013-12-30 23:36:11 +0000
commita989fb5ce7cfbb99342fe3360ed51975a57ca398 (patch)
treee749163520af667cf26aacd929bc96dc4b151bfe /llvm/lib/Support/ThreadLocal.cpp
parent35d8703dbe89f717ef6c71b35e4b29aa51bbd7a7 (diff)
downloadllvm-a989fb5ce7cfbb99342fe3360ed51975a57ca398.zip
llvm-a989fb5ce7cfbb99342fe3360ed51975a57ca398.tar.gz
llvm-a989fb5ce7cfbb99342fe3360ed51975a57ca398.tar.bz2
Fix an ODR violation in the sanitizer runtimes.
A helper function is a C++ function, and so even though one of the two definitions is weak, it still technically triggers the ODR. Perhaps these two definitions are ODR equivalent, but I'm not even confident in that. Instead, just define the function once, declare it as weak, and use a wrapper that is clearly file-local. This avoids two definitions. Also make the function extern "C" so that we can't even mess up the type signature somehow or otherwise fail to match up the weak declaration here with the interceptor defined elsewhere. llvm-svn: 198253
Diffstat (limited to 'llvm/lib/Support/ThreadLocal.cpp')
0 files changed, 0 insertions, 0 deletions