Refactor CompareExpression to use IComparable