Re: some more error location support

Поиск
Список
Период
Сортировка
От Fabien COELHO
Тема Re: some more error location support
Дата
Msg-id alpine.DEB.2.21.1808271057430.11066@lancre
обсуждение исходный текст
Ответ на some more error location support  (Peter Eisentraut <peter.eisentraut@2ndquadrant.com>)
Ответы Re: some more error location support
Список pgsql-hackers
> Here are three patches to add more detailed error location support to
> some parts of CREATE TABLE (defaults, check constraints, partition
> specifications) as well as the COPY command.  Examples can be seen in
> the regression test output.
>
> The first two are low-hanging fruit, since all the information was
> already collected and just needed to be passed through one last hop.
> The third one is a bit more invasive; it adds location information to
> the Value node, which is used in a variety of commands, so COPY is just
> a start here.

About patch 3: applies cleanly independently of the 2 others, compiles, 
"make check" is okay.

A few comments:

There seems to be several somehow unrelated changes: one about copy,
one about trigger and one about constraints? The two later changes do not 
seem to impact the tests, though.

In "CreateTrigger", you moved "make_parsestate" but removed 
"free_parsestate". I'd rather move it than remove it.

In "value.h", the added location field deserves a "/* token location, or 
-1 if unknown */" comment like others in "parsenode.h", "plannode.h" and 
"primnodes.h".

Copying and comparing values are updaed, but value in/out functions are 
not updated to read/write the location, although other objects have their 
location serialized. ISTM that it should be done as well.

-- 
Fabien.


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

Предыдущее
От: Fabien COELHO
Дата:
Сообщение: Re: some more error location support
Следующее
От: Yugo Nagata
Дата:
Сообщение: Re: has_table_privilege for a table in unprivileged schema causesan error