| От | Tom Lane |
|---|---|
| Тема | Re: Unary Operators |
| Дата | |
| Msg-id | 2550.1383961919@sss.pgh.pa.us обсуждение исходный текст |
| Ответ на | Unary Operators (Andreas Ulbrich <andreas.ulbrich@matheversum.de>) |
| Список | pgsql-general |
Andreas Ulbrich <andreas.ulbrich@matheversum.de> writes:
> In the documentation I can't find, that / is not possible as an unary
> operator.
> Are there any restrictions.
Yeah, if you look in the bison grammar you'll find out that the operators
with special precedence are hard-wired as to which syntaxes are allowed:
+ - prefix or infix
* / % ^ < > = infix only
It's possible that if we just added some more productions these could be
used in nonstandard ways. But I think interest in that is really pretty
low, and it might lead to behavior that would be surprising to people
who aren't interested in using them in weird ways.
regards, tom lane
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера