[Kaleidoscope] Fix incorrect use of reinterpret_cast.
[oota-llvm.git] / examples / Kaleidoscope / MCJIT / cached / toy-jit.cpp
index 7f5ed137cece386b00e5e44e35000b62272bfce1..77b7f001095af3088ffb085211deb0f3b4722828 100644 (file)
@@ -672,7 +672,7 @@ Value *BinaryExprAST::Codegen() {
     // For now, I'm building without RTTI because LLVM builds that way by
     // default and so we need to build that way to use the command line supprt.
     // If you build LLVM with RTTI this can be changed back to a dynamic_cast.
-    VariableExprAST *LHSE = reinterpret_cast<VariableExprAST*>(LHS);
+    VariableExprAST *LHSE = static_cast<VariableExprAST*>(LHS);
     if (!LHSE)
       return ErrorV("destination of '=' must be a variable");
     // Codegen the RHS.