Re: Restore support for USE_ASSERT_CHECKING in extensions only
David Rowley <dgrowleyml@gmail.com>
From: David Rowley <dgrowleyml@gmail.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Andrew Kane <andrew@ankane.org>, pgsql-hackers@postgresql.org
Date: 2025-01-10T23:40:46Z
Lists: pgsql-hackers
On Sat, 11 Jan 2025 at 12:32, Tom Lane <tgl@sss.pgh.pa.us> wrote: > > 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. hmm, you got me confused. Maybe you missed that the extension will be the one compiling the static inline TupleDescCompactAttr() function and will use the macro instead? I'm not grasping why this does not solve the problem. David
Commits
-
Make verify_compact_attribute available in non-assert builds
- 34c6e652425f 18.0 landed