Precedence of '|' operator (was Re: [patch,rfc] binary operators on integers) - Mailing list pgsql-hackers

From Peter Eisentraut
Subject Precedence of '|' operator (was Re: [patch,rfc] binary operators on integers)
Date
Msg-id Pine.LNX.4.21.0010122134360.12683-100000@peter.localdomain
Whole thread Raw
In response to Re: [patch,rfc] binary operators on integers  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Precedence of '|' operator (was Re: [patch,rfc] binary operators on integers)
List pgsql-hackers
Tom Lane writes:

> Even though I think '|' is clearly given a bogus precedence, I doubt
> it's a good idea to change it.

The only builtin '|' operator, besides the not-there-yet bitor, is some
arcane prefix operator for the "tinterval" type, which returns the start
of the interval.  This is all long dead so that would perhaps give us a
chance to change this before we add "or" operators.  That might weigh more
than the possibility of a few users having highly specialized '|'
operators that rely on this precedence.

The tinterval type has pretty interesting parsing rules, btw.:

peter=# select 'whatever you say'::tinterval;                     ?column?
-----------------------------------------------------["1935-12-23 09:42:00+01" "1974-04-16 17:52:52+01"]
(1 row)

-- 
Peter Eisentraut      peter_e@gmx.net       http://yi.org/peter-e/



pgsql-hackers by date:

Previous
From: Alfred Perlstein
Date:
Subject: Re: pg_dump possible fix, need testers. (was: Re: pg_dump disaster)
Next
From: Stephan Szabo
Date:
Subject: Re: possible constraint bug?