Re: Better testing coverage and unified coding for plpgsql loops
| От | Tom Lane | 
|---|---|
| Тема | Re: Better testing coverage and unified coding for plpgsql loops | 
| Дата | |
| Msg-id | 31838.1514905690@sss.pgh.pa.us обсуждение исходный текст | 
| Ответ на | Re: Better testing coverage and unified coding for plpgsql loops (Alvaro Herrera <alvherre@alvh.no-ip.org>) | 
| Ответы | Re: Better testing coverage and unified coding for plpgsql loops | 
| Список | pgsql-hackers | 
Alvaro Herrera <alvherre@alvh.no-ip.org> writes:
> Darafei "Komяpa" Praliaskouski wrote:
>> - can this macro become a function?
> The "exit_action" argument makes it tough.  It can probably be done --
> it seems to require contorting the one callsite that uses "goto" though.
It could be converted into a function returning bool, a la
    if (!loop_rc_processing(...))
        break;
but then the burden is on you to show there's negligible performance
impact, a question that doesn't arise when just macro-izing existing
code.  I suppose the function could be made inline, but then we're
right back to the question of how well lcov will display the actual
code coverage.
            regards, tom lane
		
	В списке pgsql-hackers по дате отправления: