Re: mcv compiler warning

From: Tomas Vondra <tomas(dot)vondra(at)2ndquadrant(dot)com>
To: Jeff Janes <jeff(dot)janes(at)gmail(dot)com>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: mcv compiler warning
Date: 2019-07-05 15:06:12
Message-ID: 20190705150612.t3j2mukkbwtk3az7@development
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Jul 05, 2019 at 10:13:25AM -0400, Jeff Janes wrote:
>One of the recent mcv commits introduced an unused variable warning.
>
>mcv.c: In function 'statext_mcv_serialize':
>mcv.c:914:7: warning: unused variable 'itemlen' [-Wunused-variable]
> int itemlen = ITEM_SIZE(dim);
>
>The attached fixes it.
>

Thanks.

I think I'll just get rid of the variable entirely, and will just call
the macro from the assert directly. The variable used to be referenced
on multiple places, but that changed during the serialization code
reworks.

regards

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

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Euler Taveira 2019-07-05 15:19:24 Re: Inconsistency between attname of index and attname of relation
Previous Message Ronan Dunklau 2019-07-05 14:58:43 Re: Inconsistency between attname of index and attname of relation