Re: \if, \elseif, \else, \endif (was Re: [HACKERS] PSQL commands:\quit_if, \quit_unless)

Поиск
Список
Период
Сортировка
От Fabien COELHO
Тема Re: \if, \elseif, \else, \endif (was Re: [HACKERS] PSQL commands:\quit_if, \quit_unless)
Дата
Msg-id alpine.DEB.2.20.1702141109500.20948@lancre
обсуждение исходный текст
Ответ на Re: \if, \elseif, \else, \endif (was Re: [HACKERS] PSQL commands:\quit_if, \quit_unless)  (Corey Huinker <corey.huinker@gmail.com>)
Список pgsql-hackers
>> For two states:
>>   * for being executed (beware, it is ***important***)
>
> It does lend importance, but that's also the line continuation marker for
> "comment". Would that be a problem?

Argh. Indeed, even if people seldom type C comments in psql interactive 
mode...

Remaining ASCII characters I can thing of, hopefully avoiding already used 
ones: +%,@$\`|&:;_

So, maybe consider these ones:  "+" for it is "on"  "`" which is a "sub-shell execution"  "&" for "and the next command
is..."
 

>>   / for not (under the hood, and it is opposed to *)
>
> +1, I was going to suggest '/' for a false state, with two possible
>     metaphors to justify it
>  1. the slash in a "no" sign ("no smoking", ghostbusters, etc)
>  2. the leading char of a c/java/javascript comment (what is written here
>     is just words, not code)

Great.

-- 
Fabien.



В списке pgsql-hackers по дате отправления:

Предыдущее
От: David Rowley
Дата:
Сообщение: Re: [HACKERS] Small improvement to parallel query docs
Следующее
От: Dave Page
Дата:
Сообщение: [HACKERS] PostgreSQL Code of Conduct Draft