Re: patch: remove redundant code from pl_exec.c

Поиск
Список
Период
Сортировка
От Pavel Stehule
Тема Re: patch: remove redundant code from pl_exec.c
Дата
Msg-id AANLkTi=ea+h_io3QM3zhECy=YyJVVTEcDXE-O45gi9Cb@mail.gmail.com
обсуждение исходный текст
Ответ на Re: patch: remove redundant code from pl_exec.c  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: patch: remove redundant code from pl_exec.c  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
2010/12/17 Tom Lane <tgl@sss.pgh.pa.us>:
> Pavel Stehule <pavel.stehule@gmail.com> writes:
>> This patch remove redundant rows from PL/pgSQL executor (-89 lines).
>> Doesn't change a functionality.
>
> I'm not really impressed with this idea: there's no a priori reason
> that all those loop types would necessarily have exactly the same
> control logic.
>

this code processes a rc from EXIT, CONTINUE and RETURN statement. All
these statements are defined independent to outer loops, so there are
no reason why this code has be different. And actually removed code
was almost same. There was different a process for FOR statement,
because there isn't possible direct "return" from cycle, because is
necessary to release a allocated memory.

There is no reason why the processing should be same, but actually is same.


>                        regards, tom lane
>


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

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: proposal: FOREACH-IN-ARRAY (probably for 9.2?)
Следующее
От: Tom Lane
Дата:
Сообщение: Re: bug in SignalSomeChildren