[patch,rfc] binary operators on integers - Mailing list pgsql-hackers

From Marko Kreen
Subject [patch,rfc] binary operators on integers
Date
Msg-id 20000920211159.A19995@l-t.ee
Whole thread Raw
Responses Re: [patch,rfc] binary operators on integers
Re: [patch,rfc] binary operators on integers
List pgsql-hackers
Well, I was interested in binary operators on integers
and as Peter suggested that I should look into it
myself, so I did it.

Choice of operators:
~ - not& - and# - xor  - I like it :)| - or

Things I am unsure of:

1) Precedence.  I quite nonscientifically hacked in gram.y,  and could not still make it understand expression '5 # ~1'
nor the precedence between '&' and '|#'...
 
  At the moment all the gram.y changes could be dropped and  it works ok, but without operator precedence.  Any hints?

2) Choice of oids.  I took 1890 - 1913.  Should I have taken  directly from 1874 upwards, or somewhere else?

3) Choice of operators.  As I understand the '^' is taken,  I wont get it.  Now, in gram.y I found that the '|' is
usedin weird situations and with weird precedence so  maybe I should use something else for OR too?
 

4) Is anybody else interested? ;)


I would like to get comments/further hints on this...



-- 
marko


pgsql-hackers by date:

Previous
From: Stephan Szabo
Date:
Subject: Re: Solution for RI permission problem
Next
From: Jesus Sandoval
Date:
Subject: Dynamic application data refreshing