Expression calculation bug?