RE: Proposal: Add more compile-time asserts to exposeinconsistencies. - Mailing list pgsql-hackers

From Smith, Peter
Subject RE: Proposal: Add more compile-time asserts to exposeinconsistencies.
Date
Msg-id 201DD0641B056142AC8C6645EC1B5F62014B9C3649@SYD1217
Whole thread Raw
In response to Re: Proposal: Add more compile-time asserts to exposeinconsistencies.  (Michael Paquier <michael@paquier.xyz>)
Responses Re: Proposal: Add more compile-time asserts to exposeinconsistencies.  (Michael Paquier <michael@paquier.xyz>)
List pgsql-hackers
> It seems to me that there is a good point to be consistent with the treatment of StaticAssertStmt and
StaticAssertExprin c.h, which have fallback implementations in *all* the configurations supported. 

Consistency is good, but:

* That is beyond the scope for what I wanted my patch to achieve; my use-cases are C code only

* It is too risky for me to simply cut/paste my C version of StaticAssertDecl and hope it will work OK for C++. It
needslots of testing because there seems evidence that bad things can happen. E.g. Peter Eisentraut wrote "if you're
asking,why is the fallback implementation in C++ different from the one in C, then that's because the C variant didn't
workin C++." 

~

I am happy if somebody else with more ability to test C++ properly wants to add the __cplusplus variant of the new
macro.

Meanwhile, I've attached latest re-based version of this patch.

Kind Regards.
--
Peter Smith
Fujitsu Australia

Attachment

pgsql-hackers by date:

Previous
From: Rafia Sabih
Date:
Subject: Re: How to prohibit parallel scan through tableam?
Next
From: Amit Kapila
Date:
Subject: Re: [HACKERS] Block level parallel vacuum