[Kaleidoscope] Fix incorrect use of reinterpret_cast.
[oota-llvm.git] / examples / Kaleidoscope / MCJIT / initial / toy.cpp
index dd35358753d04f5eef09a2fea4823b97df195a71..9455946087d139e74f46e1255958da187c92cf63 100644 (file)
@@ -897,7 +897,7 @@ Value *BinaryExprAST::Codegen() {
   // Special case '=' because we don't want to emit the LHS as an expression.
   if (Op == '=') {
     // Assignment requires the LHS to be an identifier.
-    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.