Re: Restore support for USE_ASSERT_CHECKING in extensions only - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Restore support for USE_ASSERT_CHECKING in extensions only
Date
Msg-id 2714509.1736551923@sss.pgh.pa.us
Whole thread Raw
Responses Re: Restore support for USE_ASSERT_CHECKING in extensions only
List pgsql-hackers
David Rowley <dgrowleyml@gmail.com> writes:
> hmm, I didn't think of that scenario.  I think since
> verify_compact_attribute() does nothing when USE_ASSERT_CHECKING isn't
> defined that we might as well define a ((void) 0) macro to avoid the
> undefined symbol error. That'll avoid the useless call in your debug
> builds.

No, this completely fails to address the problem.  The concern is
that the extension has been compiled under USE_ASSERT_CHECKING,
so it will try to call the function.  If the function's not there
in core, kaboom.

What you need to do is provide an empty no-op version of
verify_compact_attribute() in non-assert builds.

            regards, tom lane



pgsql-hackers by date:

Previous
From: Melanie Plageman
Date:
Subject: Re: Moving the vacuum GUCs' docs out of the Client Connection Defaults section
Next
From: David Rowley
Date:
Subject: Re: Restore support for USE_ASSERT_CHECKING in extensions only