Re: Some surprising precedence behavior in PG's grammar
От | Greg Stark |
---|---|
Тема | Re: Some surprising precedence behavior in PG's grammar |
Дата | |
Msg-id | BANLkTimux=065doRc8oMK7KWJs16hKppuw@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: Some surprising precedence behavior in PG's grammar (Tom Lane <tgl@sss.pgh.pa.us>) |
Список | pgsql-hackers |
On Thu, May 5, 2011 at 4:03 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote: > Greg Stark <gsstark@mit.edu> writes: >> Isn't there already some gadget which forces postfix operators to be >> discouraged compared to some other interpretation in other cases? > > Yeah. I'm not unhappy with the current grammar's behavior in this case. > What's bothering me is that the implementation seems likely to create > surprising/unexpected behaviors after future grammar changes. I do wonder how much we really gain from having postfix operators. Other than ! I've never seen one and of course anyone who wanted to use one could just as easily use a prefix operator. In practice I think most unary operators are just special cases of binary operators anyways and often once you have the binary operator it's clearer to just use that anyways. A *lot* of grammar conflicts we've had to worry about end up going away if we didn't have postfix operators. -- greg
В списке pgsql-hackers по дате отправления: