Re: [HACKERS] pgbench - allow backslash continuations in \set expressions

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [HACKERS] pgbench - allow backslash continuations in \set expressions
Дата
Msg-id 13144.1484928857@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: [HACKERS] pgbench - allow backslash continuations in \setexpressions  (Fabien COELHO <coelho@cri.ensmp.fr>)
Список pgsql-hackers
Fabien COELHO <coelho@cri.ensmp.fr> writes:
>> Probably the easiest fix is to add a rule that explicitly matches this
>> situation:
>> {nonspace}+{continuation}  { ... throw back 2 chars and return the rest ... }

> Well, as the continuation characters must be ignored, so there is no need
> to throw them back, just adding the special case is enough?

True, for the moment.  If we ever put an action into the continuation rule
(e.g. to count line numbers in the script) it might be better the other
way, but for now this is fine.

> Note anyway that it is not necessarily what people may intend when using a
> continuation:

Yeah, but as you say this varies from one language to another.  I'm fine
with treating the continuation marker like whitespace.

Pushed with cosmetic adjustments (mostly, adding comments).
        regards, tom lane



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

Предыдущее
От: Fujii Masao
Дата:
Сообщение: Re: [HACKERS] Logical Replication WIP
Следующее
От: Petr Jelinek
Дата:
Сообщение: Re: [HACKERS] Logical Replication WIP