Re: [PATCH] Add some useful asserts into View Options macroses - Mailing list pgsql-hackers

From Robert Haas
Subject Re: [PATCH] Add some useful asserts into View Options macroses
Date
Msg-id CA+TgmobsfF_Rr89TS-2zDVTLjbp84WLJg4-reuqvN7yNHFMg6Q@mail.gmail.com
Whole thread Raw
In response to [PATCH] Add some useful asserts into View Options macroses  (Nikolay Shaplov <dhyan@nataraj.su>)
Responses Re: [PATCH] Add some useful asserts into View Options macroses  (Nikolay Shaplov <dhyan@nataraj.su>)
List pgsql-hackers
On Sat, Oct 5, 2019 at 5:23 PM Nikolay Shaplov <dhyan@nataraj.su> wrote:
> This thread is a follow up to the thread https://www.postgresql.org/message-id/2620882.s52SJui4ql@x200m where I've
beentrying to remove StdRdOptions
 
> structure and replace it with unique structure for each relation kind.
>
> I've decided to split that patch into smaller parts.
>
> This part adds some asserts to ViewOptions macroses.
> Since an option pointer there is converted into (ViewOptions *) it would be
> really good to make sure that this macros is called in proper context, and we
> do the convertation properly. At least when running tests with asserts turned
> on.

Seems like a good idea.  Should we try to do something similar for the
macros in that header file that cast to StdRdOptions?

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: How to retain lesser paths at add_path()?
Next
From: Fujii Masao
Date:
Subject: Re: recovery_min_apply_delay in archive recovery causes assertionfailure in latch