Re: Enhanced error message to include hint messages for redundant options error

Поиск
Список
Период
Сортировка
От Bharath Rupireddy
Тема Re: Enhanced error message to include hint messages for redundant options error
Дата
Msg-id CALj2ACWbvEcc3HhP_m8aTCNOZmoeBaukF6W2_gd7+o7JhA=eKw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Enhanced error message to include hint messages for redundant options error  (vignesh C <vignesh21@gmail.com>)
Список pgsql-hackers
On Tue, May 11, 2021 at 6:54 PM vignesh C <vignesh21@gmail.com> wrote:
>
> On Tue, May 11, 2021 at 2:47 AM Alvaro Herrera <alvherre@alvh.no-ip.org> wrote:
> >
> > On 2021-May-10, vignesh C wrote:
> >
> > > That sounds fine to me, Attached v6 patch which has the changes for the same.
> >
> > What about defining a function (maybe a static inline function in
> > defrem.h) that is marked noreturn and receives the DefElem and
> > optionally pstate, and throws the error?  I think that would avoid the
> > patch's need to have half a dozen copies of the "duplicate_error:" label
> > and ereport stanza.
>
> Thanks for the comment, this reduces a significant amount of code.

Yeah, the patch reduces more than 200 LOC which is a  pretty good thing.

 25 files changed, 239 insertions(+), 454 deletions(-)

With Regards,
Bharath Rupireddy.
EnterpriseDB: http://www.enterprisedb.com



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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Some other CLOBBER_CACHE_ALWAYS culprits
Следующее
От: Tom Lane
Дата:
Сообщение: Python 3.10 breaks regression tests with traceback changes