From: | Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org> |
---|---|
To: | Darafei "Komяpa" Praliaskouski <me(at)komzpa(dot)net> |
Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-hackers(at)lists(dot)postgresql(dot)org |
Subject: | Re: Better testing coverage and unified coding for plpgsql loops |
Date: | 2018-01-02 13:46:23 |
Message-ID: | 20180102134623.4mhrbnc2im6bfp7a@alvherre.pgsql |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Darafei "Komяpa" Praliaskouski wrote:
> - how do currently existing coverage tools display coverage for such a
> large macro?
>
> I expect DEFINE's to be treated as comments.
It is, but then it is counted in the callsite where each branch is
displayed separately. So in
https://coverage.postgresql.org/src/pl/plpgsql/src/pl_exec.c.gcov.html
line 2028 you can see a bunch of "+" and three "-".
> - 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.
--
Álvaro Herrera https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
From | Date | Subject | |
---|---|---|---|
Next Message | Alvaro Herrera | 2018-01-02 14:02:26 | Re: pg_(total_)relation_size and partitioned tables |
Previous Message | Tels | 2018-01-02 13:45:47 | Re: Faster inserts with mostly-monotonically increasing values |