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:
f96e27f
)
[MCJIT] Fix a cast warning in the unit-test introduced in r243589.
author
Lang Hames
<lhames@gmail.com>
Mon, 3 Aug 2015 18:03:40 +0000
(18:03 +0000)
committer
Lang Hames
<lhames@gmail.com>
Mon, 3 Aug 2015 18:03:40 +0000
(18:03 +0000)
Thanks to Aaron Ballman for spotting this.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@243891
91177308
-0d34-0410-b5e6-
96231b3b80d8
unittests/ExecutionEngine/MCJIT/MCJITCAPITest.cpp
patch
|
blob
|
history
diff --git
a/unittests/ExecutionEngine/MCJIT/MCJITCAPITest.cpp
b/unittests/ExecutionEngine/MCJIT/MCJITCAPITest.cpp
index 9d768d97f389828f5495a1d241bf258c6f13696f..cdc52a39b5f24677f202cd093d600b8e080cd973 100644
(file)
--- a/
unittests/ExecutionEngine/MCJIT/MCJITCAPITest.cpp
+++ b/
unittests/ExecutionEngine/MCJIT/MCJITCAPITest.cpp
@@
-514,7
+514,13
@@
TEST_F(MCJITCAPITest, addGlobalMapping) {
buildMCJITOptions();
buildMCJITEngine();
- LLVMAddGlobalMapping(Engine, MappedFn, reinterpret_cast<void*>(&localTestFunc));
+ union {
+ int (*raw)();
+ void *usable;
+ } functionPointer;
+ functionPointer.raw = &localTestFunc;
+
+ LLVMAddGlobalMapping(Engine, MappedFn, functionPointer.usable);
buildAndRunPasses();