1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-24 11:42:57 +01:00

In ExecutionEngine::getPointerToGlobal(), throw away const qualifier

on Function * when passing it to getPointerToFunction().

llvm-svn: 7818
This commit is contained in:
Brian Gaeke 2003-08-13 18:16:14 +00:00
parent ccafb6e504
commit f162b11e38

View File

@ -22,7 +22,7 @@ Statistic<> NumInitBytes("lli", "Number of bytes of global vars initialized");
// value. This may involve code generation if it's a function.
//
void *ExecutionEngine::getPointerToGlobal(const GlobalValue *GV) {
if (const Function *F = dyn_cast<Function>(GV))
if (Function *F = const_cast<Function*>(dyn_cast<Function>(GV)))
return getPointerToFunction(F);
assert(GlobalAddress[GV] && "Global hasn't had an address allocated yet?");