Added a compare helper rewrite