Re: [HACKERS] WITH clause in CREATE STATISTICS - Mailing list pgsql-hackers

From Alvaro Herrera
Subject Re: [HACKERS] WITH clause in CREATE STATISTICS
Date
Msg-id 20170512214426.sdzcocysfv6ykjjr@alvherre.pgsql
Whole thread Raw
In response to Re: [HACKERS] WITH clause in CREATE STATISTICS  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: [HACKERS] WITH clause in CREATE STATISTICS  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Tom Lane wrote:
> Alvaro Herrera <alvherre@2ndquadrant.com> writes:
> > Tom Lane wrote:
> >> Oh, sorry --- I already pushed something about this.
> 
> > That's fine, thanks.
> 
> Oh, I see your patch also fixes missing code in getObjectDescription().
> We need that.  Is there a decent way to get the compiler to warn about
> that oversight?

We could remove the default clause.  That results in the expected
warning, and no others (i.e. the switch was already complete):

/pgsql/source/master/src/backend/catalog/objectaddress.c:2657:2: warning: enumeration value 'OCLASS_STATISTIC_EXT' not
handledin switch [-Wswitch]
 

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



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: [HACKERS] WITH clause in CREATE STATISTICS
Next
From: Tom Lane
Date:
Subject: Re: [HACKERS] WITH clause in CREATE STATISTICS