Remove bad pointer arithmetic in polygon comparators (fixes #295) Closes #295 See merge request !1462