Skip to content

Commit 6e03d47

Browse files
committed
Remove gram.y's precedence declaration for OVERLAPS.
The allowed syntax for OVERLAPS, viz "row OVERLAPS row", is sufficiently constrained that we don't actually need a precedence declaration for OVERLAPS; indeed removing this declaration does not change the generated gram.c file at all. Let's remove it to avoid confusion about whether OVERLAPS has precedence or not. If we ever generalize what we allow for OVERLAPS, we might need to put back a precedence declaration for it, but we might want some other level than what it has today --- and leaving the declaration there would just risk confusion about whether that would be an incompatible change. Likewise, remove OVERLAPS from the documentation's precedence table. Per discussion with Noah Misch. Back-patch to 9.5 where we hacked up some nearby precedence decisions.
1 parent 64ac985 commit 6e03d47

File tree

2 files changed

+0
-7
lines changed

2 files changed

+0
-7
lines changed

doc/src/sgml/syntax.sgml

-6
Original file line numberDiff line numberDiff line change
@@ -1069,12 +1069,6 @@ SELECT (5 !) - 6;
10691069
<entry>all other native and user-defined operators</entry>
10701070
</row>
10711071

1072-
<row>
1073-
<entry><token>OVERLAPS</token></entry>
1074-
<entry></entry>
1075-
<entry>time interval overlap</entry>
1076-
</row>
1077-
10781072
<row>
10791073
<entry><token>BETWEEN</token> <token>IN</token> <token>LIKE</token> <token>ILIKE</token> <token>SIMILAR</token></entry>
10801074
<entry></entry>

src/backend/parser/gram.y

-1
Original file line numberDiff line numberDiff line change
@@ -673,7 +673,6 @@ static Node *makeRecursiveViewSelect(char *relname, List *aliases, Node *query);
673673
%nonassoc '<' '>' '=' LESS_EQUALS GREATER_EQUALS NOT_EQUALS
674674
%nonassoc BETWEEN IN_P LIKE ILIKE SIMILAR NOT_LA
675675
%nonassoc ESCAPE /* ESCAPE must be just above LIKE/ILIKE/SIMILAR */
676-
%nonassoc OVERLAPS
677676
%left POSTFIXOP /* dummy for postfix Op rules */
678677
/*
679678
* To support target_el without AS, we must give IDENT an explicit priority

0 commit comments

Comments
 (0)