Content-Length: 357168 | pFad | http://github.com/postgrespro/postgres_cluster/commit/1f7a47912af2206698d14650f2149fa951b8ce07

39 Revert "Tweak "line" test to avoid negative zeros on some platforms" · postgrespro/postgres_cluster@1f7a479 · GitHub
Skip to content

Commit 1f7a479

Browse files
committed
Revert "Tweak "line" test to avoid negative zeros on some platforms"
This reverts commit a0a546f. It seems better to tweak the code to suppress -0 results during line_construct_pts(), which I'll do in the next commit.
1 parent a0a546f commit 1f7a479

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

src/test/regress/expected/line.out

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
--DROP TABLE LINE_TBL;
66
CREATE TABLE LINE_TBL (s line);
77
INSERT INTO LINE_TBL VALUES ('{1,-1,1}');
8-
INSERT INTO LINE_TBL VALUES ('(0,0.1),(6,6)');
8+
INSERT INTO LINE_TBL VALUES ('(0,0),(6,6)');
99
INSERT INTO LINE_TBL VALUES ('10,-10 ,-5,-4');
1010
INSERT INTO LINE_TBL VALUES ('[-1e6,2e2,3e5, -4e1]');
1111
INSERT INTO LINE_TBL VALUES ('(11,22,33,44)');
@@ -42,7 +42,7 @@ select * from LINE_TBL;
4242
s
4343
---------------------------------------------
4444
{1,-1,1}
45-
{0.983333333333333,-1,0.1}
45+
{1,-1,0}
4646
{-0.4,-1,-6}
4747
{-0.000184615384615385,-1,15.3846153846154}
4848
{1,-1,11}
@@ -55,7 +55,7 @@ SELECT * FROM LINE_TBL WHERE (s <-> line '[(1,2),(3,4)]') < 10;
5555
s
5656
---------------------------------------------
5757
{1,-1,1}
58-
{0.983333333333333,-1,0.1}
58+
{1,-1,0}
5959
{-0.4,-1,-6}
6060
{-0.000184615384615385,-1,15.3846153846154}
6161
{1,-1,11}
@@ -64,17 +64,17 @@ SELECT * FROM LINE_TBL WHERE (s <-> line '[(1,2),(3,4)]') < 10;
6464
(7 rows)
6565

6666
SELECT * FROM LINE_TBL WHERE (point '(0.1,0.1)' <-> s) < 1;
67-
s
68-
----------------------------
67+
s
68+
----------
6969
{1,-1,1}
70-
{0.983333333333333,-1,0.1}
70+
{1,-1,0}
7171
(2 rows)
7272

7373
SELECT * FROM LINE_TBL WHERE (lseg '[(0.1,0.1),(0.2,0.2)]' <-> s) < 1;
74-
s
75-
----------------------------
74+
s
75+
----------
7676
{1,-1,1}
77-
{0.983333333333333,-1,0.1}
77+
{1,-1,0}
7878
(2 rows)
7979

8080
SELECT line '[(1,1),(2,1)]' <-> line '[(-1,-1),(-2,-1)]';

src/test/regress/sql/line.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
CREATE TABLE LINE_TBL (s line);
88

99
INSERT INTO LINE_TBL VALUES ('{1,-1,1}');
10-
INSERT INTO LINE_TBL VALUES ('(0,0.1),(6,6)');
10+
INSERT INTO LINE_TBL VALUES ('(0,0),(6,6)');
1111
INSERT INTO LINE_TBL VALUES ('10,-10 ,-5,-4');
1212
INSERT INTO LINE_TBL VALUES ('[-1e6,2e2,3e5, -4e1]');
1313
INSERT INTO LINE_TBL VALUES ('(11,22,33,44)');

0 commit comments

Comments
 (0)








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/postgrespro/postgres_cluster/commit/1f7a47912af2206698d14650f2149fa951b8ce07

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy