Better warnings for cross-type comparisons