-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix bug in
ExactEquals
for empty Points
The `ExactEquals` method didn't properly take into consideration coordinates type (XY vs. XYZ vs. XYM vs. XYZM) when both Point arguments were empty. The actual fix is only in the `pointsEq` method. In the previous code, `ok1` and `ok2` would both evaluate to `false` (because the `Points` are both empty). This would then skip the call to `c.eq(c1, c2)`, which was where the coordinates type comparison occurred. The fix is to explicitly check for the case where both `Point`s are empty, and handle the coordinates type check there. The `c.eq` method still needs to check for coordinate type, to ensure that inputs such as `POINT (1 2)` and `POINT Z (1 2 3)` continue to compared as non-equal.
- Loading branch information
1 parent
44a87b3
commit b59f80a
Showing
2 changed files
with
52 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters