title: Simple Math Expression in ExprTk
body: <p>I am attempting to use a simple expression such as the following and the result should be that the value of z becomes 1. However nothing seems to be happening any suggestions on how I could resolve this issue ? </p>
  
  <pre><code>template&lt;typename t&gt;
  void MyTestB()
  {
  
      t x = 1.0;
      t z = 0;
  
      std::string e = "if((x + 2) == 3){z=1;}";
      exprtk::symbol_table&lt;t&gt; symbol_table;
      symbol_table.add_variable("x",x);
      symbol_table.add_variable("z",z);
  
      exprtk::expression&lt;t&gt; expression;
      expression.register_symbol_table(symbol_table);
  
  
      exprtk::parser&lt;t&gt; parser;
  
      parser.compile(e,expression);
      t y = expression.value();
      std::cout &lt;&lt; z;
  }
  </code></pre>
  
  <p>The program does finish however at y = NAN (which is understandable because expression is a conditional statement) However z still remains 0. I was expecting it to become 1</p>