mescc: Refactor comparisons.