ClonedConstraint typedef is dead code?

Started by Tom Lanealmost 7 years ago3 messageshackers
Jump to latest
#1Tom Lane
tgl@sss.pgh.pa.us

catalog/pg_constraint.h defines a typedef ClonedConstraint,
which AFAICS is no longer referenced anywhere. Is there a
reason not to remove it?

(I noticed this while eyeballing a test pgindent run.)

regards, tom lane

#2Alvaro Herrera
alvherre@2ndquadrant.com
In reply to: Tom Lane (#1)
Re: ClonedConstraint typedef is dead code?

On 2019-May-15, Tom Lane wrote:

catalog/pg_constraint.h defines a typedef ClonedConstraint,
which AFAICS is no longer referenced anywhere. Is there a
reason not to remove it?

Oh, I didn't realize it had become completely unused! It was used for
FK creation in partitioned tables, but we rewrote that code completely
and I don't foresee needing that struct for anything in the future, so
it seems safe to remove.

Thanks,

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

#3Tom Lane
tgl@sss.pgh.pa.us
In reply to: Alvaro Herrera (#2)
Re: ClonedConstraint typedef is dead code?

Alvaro Herrera <alvherre@2ndquadrant.com> writes:

On 2019-May-15, Tom Lane wrote:

catalog/pg_constraint.h defines a typedef ClonedConstraint,
which AFAICS is no longer referenced anywhere. Is there a
reason not to remove it?

Oh, I didn't realize it had become completely unused! It was used for
FK creation in partitioned tables, but we rewrote that code completely
and I don't foresee needing that struct for anything in the future, so
it seems safe to remove.

Thanks, done.

regards, tom lane