pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
bugfifx: a minor mistake in brin_inclusion.c comment
2+ messages / 2 participants
[nested] [flat]

Commits from this thread:
  2018-03-26 d2b9c02054 43cd7abdcc b69df6fdbb 530bcf7581  Fix thinko in comment
* bugfifx: a minor mistake in brin_inclusion.c comment
@ 2018-03-23 00:32 Tomas Vondra <tomas.vondra@2ndquadrant.com>
  2018-03-26 15:11 ` Re: bugfifx: a minor mistake in brin_inclusion.c comment Alvaro Herrera <alvherre@alvh.no-ip.org>
  0 siblings, 1 reply; 2+ messages in thread

From: Tomas Vondra @ 2018-03-23 00:32 UTC (permalink / raw)
  To: pgsql-hackers

Hi,

while looking at brin_inclusion.c, I've noticed that the comment about
INCLUSION_UNMERGEABLE and INCLUSION_CONTAINS_EMPTY uses incorrect values
(1 instead of 2). Attached is a simple fix.

But perhaps it would be better to use the constants in the comment.

regards

-- 
Tomas Vondra                  http://www.2ndQuadrant.com
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

Attachments:

brin-inclusion-doc-fix.patch (text/x-patch, 764B) download diff --git a/src/backend/access/brin/brin_inclusion.c b/src/backend/access/brin/brin_inclusion.c index 2542877..d8042b0 100644 --- a/src/backend/access/brin/brin_inclusion.c +++ b/src/backend/access/brin/brin_inclusion.c @@ -60,9 +60,9 @@ * The values stored in the bv_values arrays correspond to: * * 0 - the union of the values in the block range - * 1 - whether an empty value is present in any tuple in the block range - * 2 - whether the values in the block range cannot be merged (e.g. an IPv6 + * 1 - whether the values in the block range cannot be merged (e.g. an IPv6 * address amidst IPv4 addresses). + * 2 - whether an empty value is present in any tuple in the block range */ #define INCLUSION_UNION 0 #define INCLUSION_UNMERGEABLE 1
^ permalink raw reply [nested|flat] 2+ messages in thread

* Re: bugfifx: a minor mistake in brin_inclusion.c comment
  2018-03-23 00:32 bugfifx: a minor mistake in brin_inclusion.c comment Tomas Vondra <tomas.vondra@2ndquadrant.com>
@ 2018-03-26 15:11 ` Alvaro Herrera <alvherre@alvh.no-ip.org>
  0 siblings, 0 replies; 2+ messages in thread

From: Alvaro Herrera @ 2018-03-26 15:11 UTC (permalink / raw)
  To: Tomas Vondra <tomas.vondra@2ndquadrant.com>; +Cc: pgsql-hackers

Tomas Vondra wrote:
> Hi,
> 
> while looking at brin_inclusion.c, I've noticed that the comment about
> INCLUSION_UNMERGEABLE and INCLUSION_CONTAINS_EMPTY uses incorrect values
> (1 instead of 2). Attached is a simple fix.

Uh, yeah, this is wrong.

> But perhaps it would be better to use the constants in the comment.

I fixed it like this, which seems neater.

Thanks!

-- 
Álvaro Herrera                https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services




^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2018-03-26 15:11 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2018-03-23 00:32 bugfifx: a minor mistake in brin_inclusion.c comment Tomas Vondra <tomas.vondra@2ndquadrant.com>
2018-03-26 15:11 ` Alvaro Herrera <alvherre@alvh.no-ip.org>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox