Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 112d411

Browse files
committed
Remove deprecated containment operators for contrib types.
Since PG 8.2, @ and ~ have been deprecated aliases for the containment operators @> and <@. It seems like enough time has passed to actually remove them, so do so. This completes the project begun in commit 2f70fdb. Note that in the core types, the relation to the preferred operator names was reversed from what it is in these contrib modules. The confusion that induced was a large part of the reason for deprecation. Justin Pryzby Discussion: https://postgr.es/m/20201027032511.GF9241@telsasoft.com
1 parent 8a8f4d8 commit 112d411

14 files changed

+34
-40
lines changed

contrib/cube/Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ OBJS = \
77
cubeparse.o
88

99
EXTENSION = cube
10-
DATA = cube--1.2.sql cube--1.2--1.3.sql cube--1.3--1.4.sql \
10+
DATA = cube--1.2.sql cube--1.2--1.3.sql cube--1.3--1.4.sql cube--1.4--1.5.sql \
1111
cube--1.1--1.2.sql cube--1.0--1.1.sql
1212
PGFILEDESC = "cube - multidimensional cube data type"
1313

contrib/cube/cube--1.4--1.5.sql

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
/* contrib/cube/cube--1.4--1.5.sql */
2+
3+
-- complain if script is sourced in psql, rather than via ALTER EXTENSION
4+
\echo Use "ALTER EXTENSION cube UPDATE TO '1.5'" to load this file. \quit
5+
6+
-- Remove @ and ~
7+
DROP OPERATOR @ (cube, cube);
8+
DROP OPERATOR ~ (cube, cube);

contrib/cube/cube.control

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# cube extension
22
comment = 'data type for multidimensional cubes'
3-
default_version = '1.4'
3+
default_version = '1.5'
44
module_pathname = '$libdir/cube'
55
relocatable = true
66
trusted = true

contrib/hstore/hstore--1.7--1.8.sql

+4
Original file line numberDiff line numberDiff line change
@@ -11,3 +11,7 @@ LANGUAGE C STRICT IMMUTABLE PARALLEL SAFE;
1111
ALTER TYPE hstore SET (
1212
SUBSCRIPT = hstore_subscript_handler
1313
);
14+
15+
-- Remove @ and ~
16+
DROP OPERATOR @ (hstore, hstore);
17+
DROP OPERATOR ~ (hstore, hstore);

contrib/intarray/Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ OBJS = \
1212
_intbig_gist.o
1313

1414
EXTENSION = intarray
15-
DATA = intarray--1.3--1.4.sql intarray--1.2--1.3.sql \
15+
DATA = intarray--1.4--1.5.sql intarray--1.3--1.4.sql intarray--1.2--1.3.sql \
1616
intarray--1.2.sql intarray--1.1--1.2.sql \
1717
intarray--1.0--1.1.sql
1818
PGFILEDESC = "intarray - functions and operators for arrays of integers"
+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
/* contrib/intarray/intarray--1.4--1.5.sql */
2+
3+
-- complain if script is sourced in psql, rather than via ALTER EXTENSION
4+
\echo Use "ALTER EXTENSION intarray UPDATE TO '1.5'" to load this file. \quit
5+
6+
-- Remove @ and ~
7+
DROP OPERATOR @ (_int4, _int4);
8+
DROP OPERATOR ~ (_int4, _int4);

contrib/intarray/intarray.control

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# intarray extension
22
comment = 'functions, operators, and index support for 1-D arrays of integers'
3-
default_version = '1.4'
3+
default_version = '1.5'
44
module_pathname = '$libdir/_int'
55
relocatable = true
66
trusted = true

contrib/seg/Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ OBJS = \
77
segparse.o
88

99
EXTENSION = seg
10-
DATA = seg--1.1.sql seg--1.1--1.2.sql seg--1.2--1.3.sql \
10+
DATA = seg--1.1.sql seg--1.1--1.2.sql seg--1.2--1.3.sql seg--1.3--1.4.sql \
1111
seg--1.0--1.1.sql
1212
PGFILEDESC = "seg - line segment data type"
1313

contrib/seg/seg--1.3--1.4.sql

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
/* contrib/seg/seg--1.3--1.4.sql */
2+
3+
-- complain if script is sourced in psql, rather than via ALTER EXTENSION
4+
\echo Use "ALTER EXTENSION seg UPDATE TO '1.4'" to load this file. \quit
5+
6+
-- Remove @ and ~
7+
DROP OPERATOR @ (seg, seg);
8+
DROP OPERATOR ~ (seg, seg);

contrib/seg/seg.control

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# seg extension
22
comment = 'data type for representing line segments or floating-point intervals'
3-
default_version = '1.3'
3+
default_version = '1.4'
44
module_pathname = '$libdir/seg'
55
relocatable = true
66
trusted = true

doc/src/sgml/cube.sgml

-8
Original file line numberDiff line numberDiff line change
@@ -222,14 +222,6 @@
222222
</tgroup>
223223
</table>
224224

225-
<para>
226-
(Before PostgreSQL 8.2, the containment operators <literal>@&gt;</literal> and <literal>&lt;@</literal> were
227-
respectively called <literal>@</literal> and <literal>~</literal>. These names are still available, but are
228-
deprecated and will eventually be retired. Notice that the old names
229-
are reversed from the convention formerly followed by the core geometric
230-
data types!)
231-
</para>
232-
233225
<para>
234226
In addition to the above operators, the usual comparison
235227
operators shown in <xref linkend="functions-comparison-op-table"/> are

doc/src/sgml/hstore.sgml

-10
Original file line numberDiff line numberDiff line change
@@ -318,16 +318,6 @@ key =&gt; NULL
318318
</tgroup>
319319
</table>
320320

321-
<note>
322-
<para>
323-
Prior to PostgreSQL 8.2, the containment operators <literal>@&gt;</literal>
324-
and <literal>&lt;@</literal> were called <literal>@</literal> and <literal>~</literal>,
325-
respectively. These names are still available, but are deprecated and will
326-
eventually be removed. Notice that the old names are reversed from the
327-
convention formerly followed by the core geometric data types!
328-
</para>
329-
</note>
330-
331321
<table id="hstore-func-table">
332322
<title><type>hstore</type> Functions</title>
333323
<tgroup cols="1">

doc/src/sgml/intarray.sgml

-8
Original file line numberDiff line numberDiff line change
@@ -364,14 +364,6 @@
364364
</tgroup>
365365
</table>
366366

367-
<para>
368-
(Before PostgreSQL 8.2, the containment operators <literal>@&gt;</literal> and
369-
<literal>&lt;@</literal> were respectively called <literal>@</literal> and <literal>~</literal>.
370-
These names are still available, but are deprecated and will eventually be
371-
retired. Notice that the old names are reversed from the convention
372-
formerly followed by the core geometric data types!)
373-
</para>
374-
375367
<para>
376368
The operators <literal>&amp;&amp;</literal>, <literal>@&gt;</literal> and
377369
<literal>&lt;@</literal> are equivalent to <productname>PostgreSQL</productname>'s built-in

doc/src/sgml/seg.sgml

-8
Original file line numberDiff line numberDiff line change
@@ -352,14 +352,6 @@ test=&gt; select '6.25 .. 6.50'::seg as "pH";
352352
</tgroup>
353353
</table>
354354

355-
<para>
356-
(Before PostgreSQL 8.2, the containment operators <literal>@&gt;</literal> and <literal>&lt;@</literal> were
357-
respectively called <literal>@</literal> and <literal>~</literal>. These names are still available, but are
358-
deprecated and will eventually be retired. Notice that the old names
359-
are reversed from the convention formerly followed by the core geometric
360-
data types!)
361-
</para>
362-
363355
<para>
364356
In addition to the above operators, the usual comparison
365357
operators shown in <xref linkend="functions-comparison-op-table"/> are

0 commit comments

Comments
 (0)