handle nonassociativity of comparison operators