Skip to content

Commit fd0c53d

Browse files
committed
Fix + 1 test
1 parent 57e6ffe commit fd0c53d

File tree

4 files changed

+13
-10
lines changed

4 files changed

+13
-10
lines changed

Diff for: doc/operators.sgm

+2-1
Original file line numberDiff line numberDiff line change
@@ -331,7 +331,8 @@
331331
a non-boolean operator returning the distance between two
332332
objects in radians. Currently,
333333
<application>pgSphere</application> supports only distances
334-
between points, circles, between point and circle, and between point and line. If the
334+
between points, circles, between point and circle, and
335+
between point and line. If the
335336
objects are overlapping, the distance operator returns zero
336337
(0.0).
337338
</para>

Diff for: expected/line.out

+5-4
Original file line numberDiff line numberDiff line change
@@ -141,10 +141,11 @@ SELECT round( CAST(sline '( 90d, 0d, 0d, XYZ ), 40d ' <-> spoint '( 0d, 90d )' a
141141
0.87266462599717
142142
(1 row)
143143

144-
SELECT round( CAST(sline '( 0d, 0d, 0d, XYZ ), 40d ' <-> spoint '( 0d, 90d )' as numeric), 14);
145-
round
146-
------------------
147-
1.57079632679490
144+
SELECT round( CAST(sline '( 90d, 0d, 0d, XYZ ), 40d ' <-> spoint '( 0d, 90d )' as numeric), 14) =
145+
round( CAST(spoint '( 0d, 90d )' <-> sline '( 90d, 0d, 0d, XYZ ), 40d ' as numeric), 14);
146+
?column?
147+
----------
148+
t
148149
(1 row)
149150

150151
SELECT round( CAST(sline '( 0d, 0d, 0d, XYZ ), 0d ' <-> spoint '( 0d, 90d )' as numeric), 14);

Diff for: pgs_line.sql.in

+4-4
Original file line numberDiff line numberDiff line change
@@ -604,7 +604,7 @@ CREATE FUNCTION dist(sline, spoint)
604604
IMMUTABLE STRICT;
605605

606606
COMMENT ON FUNCTION dist(sline, spoint) IS
607-
'distance between spherical line and spherical point';
607+
'returns the distance between spherical line and spherical point';
608608

609609

610610
CREATE OPERATOR <-> (
@@ -615,7 +615,7 @@ CREATE OPERATOR <-> (
615615
);
616616

617617
COMMENT ON OPERATOR <-> (sline, spoint) IS
618-
'distance between spherical line and spherical point';
618+
'returns the distance between spherical line and spherical point';
619619

620620

621621

@@ -630,7 +630,7 @@ CREATE FUNCTION dist(spoint, sline)
630630
IMMUTABLE STRICT;
631631

632632
COMMENT ON FUNCTION dist(spoint, sline) IS
633-
'distance between spherical line and spherical point';
633+
'returns the distance between spherical line and spherical point';
634634

635635

636636
CREATE OPERATOR <-> (
@@ -641,5 +641,5 @@ CREATE OPERATOR <-> (
641641
);
642642

643643
COMMENT ON OPERATOR <-> (spoint, sline) IS
644-
'distance between spherical line and spherical point';
644+
'returns the distance between spherical line and spherical point';
645645

Diff for: sql/line.sql

+2-1
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,8 @@ SELECT sline ( spoint '(0, 0d)', spoint '(0.000001d, 0d)' ) #
7373

7474
SELECT round( CAST(sline '( 90d, 0d, 0d, XYZ ), 40d ' <-> spoint '( 0d, 90d )' as numeric), 14);
7575

76-
SELECT round( CAST(sline '( 0d, 0d, 0d, XYZ ), 40d ' <-> spoint '( 0d, 90d )' as numeric), 14);
76+
SELECT round( CAST(sline '( 90d, 0d, 0d, XYZ ), 40d ' <-> spoint '( 0d, 90d )' as numeric), 14) =
77+
round( CAST(spoint '( 0d, 90d )' <-> sline '( 90d, 0d, 0d, XYZ ), 40d ' as numeric), 14);
7778

7879
SELECT round( CAST(sline '( 0d, 0d, 0d, XYZ ), 0d ' <-> spoint '( 0d, 90d )' as numeric), 14);
7980

0 commit comments

Comments
 (0)