diff options
author | Jiri Slaby <jirislaby@gmail.com> | 2017-06-07 14:30:54 +0200 |
---|---|---|
committer | Jiri Slaby <jirislaby@gmail.com> | 2017-06-15 14:42:45 +0200 |
commit | c9c90a0ecdce10172fd5318aea60a9ff4057679f (patch) | |
tree | 9bb4b6d1ca326480776340312c5454ee78a2a1a5 /lib/Module/InstructionInfoTable.cpp | |
parent | 6204a1faed8f6ed15318be8da3e8e4b5e2f2a4ac (diff) | |
download | klee-c9c90a0ecdce10172fd5318aea60a9ff4057679f.tar.gz |
llvm: get rid of static_casts from iterators
In commit b7a6aec4eeb4 (convert iterators using static_cast), I switched all implicit casts to static_cast. It turned out that llvm 4.0 banned casting via static_cast. See e.g. 1e2bc42eb988 in the llvm repo what they do. So similarly to the above commit, change all the casts of iterators to "&*" which is what they do in LLVM. Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Diffstat (limited to 'lib/Module/InstructionInfoTable.cpp')
-rw-r--r-- | lib/Module/InstructionInfoTable.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Module/InstructionInfoTable.cpp b/lib/Module/InstructionInfoTable.cpp index adf05442..be5ceba1 100644 --- a/lib/Module/InstructionInfoTable.cpp +++ b/lib/Module/InstructionInfoTable.cpp @@ -120,7 +120,7 @@ InstructionInfoTable::InstructionInfoTable(Module *m) for (Module::iterator fnIt = m->begin(), fn_ie = m->end(); fnIt != fn_ie; ++fnIt) { - Function *fn = static_cast<Function *>(fnIt); + Function *fn = &*fnIt; // We want to ensure that as all instructions have source information, if // available. Clang sometimes will not write out debug information on the @@ -193,6 +193,6 @@ InstructionInfoTable::getFunctionInfo(const Function *f) const { // and construct a test case for it if it does, though. return dummyInfo; } else { - return getInfo(static_cast<const Instruction *>(f->begin()->begin())); + return getInfo(&*(f->begin()->begin())); } } |