在CodeIgniter中在没有Eval的情况下评估php中的表达式

I've stored an expression in a database, e.g.:

$expression = (({TENOR} <= 90) AND ({DEPOSIT_AMOUNT} > 0) AND {PENALTY_BASIS} = 0 )

I want to evaluate the expression in an IF...Else statement and get the results

if ($expression) {action} else {other action}

What is the best way to achieve the result? I've tried

$this->parser->parse_string($string, $data, TRUE);

but the output is always a string, hence if...else statement outputs TRUE every time.

I found out a solution at previously answered post here

The library can be found out at here

Thanks all for the help...