Re: creating extension including dependencies - Mailing list pgsql-hackers

From Andres Freund
Subject Re: creating extension including dependencies
Date
Msg-id 20150907192427.GB25484@alap3.anarazel.de
Whole thread Raw
In response to Re: creating extension including dependencies  (Alvaro Herrera <alvherre@2ndquadrant.com>)
List pgsql-hackers
On 2015-09-07 16:09:27 -0300, Alvaro Herrera wrote:
> Andres Freund wrote:
> > On 2015-09-07 20:56:50 +0200, Petr Jelinek wrote:
> > > Yes that sounds cleaner. Just as a side note, List is a Node and does have
> > > copy support (and we pass List as DefElem->arg from gram.y in several
> > > places).
> > 
> > I know - but the list element in this case don't have copy support, no?
> > You seem to have put plain C strings in there, right?
> 
> Seems slightly easier to use makeString(), no?

It'd still be a god forsakenly ugly API to use DefElems for this. Imo
not being able to specify a boolean argument for a boolean value pretty
much hints at it being the wrong approach. I don't see any reason to go
that way rather than split the 'cycle detection' state into an argument
to CreateExtensionInternal() or something.

Greetings,

Andres Freund



pgsql-hackers by date:

Previous
From: Jeff Janes
Date:
Subject: Re: pgbench progress with timestamp
Next
From: Alvaro Herrera
Date:
Subject: Re: PATCH: numeric timestamp in log_line_prefix