re-write expr to see if it's an optimizer bug?