Re: BUG #18097: Immutable expression not allowed in generated at - Mailing list pgsql-hackers

From Aleksander Alekseev
Subject Re: BUG #18097: Immutable expression not allowed in generated at
Date
Msg-id CAJ7c6TNNG_x8enNdhqmGdg_9A0fNa0LBadecBkuHc-=a7YqaFg@mail.gmail.com
Whole thread Raw
In response to Re: BUG #18097: Immutable expression not allowed in generated at  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: BUG #18097: Immutable expression not allowed in generated at
List pgsql-hackers
Hi,

I noticed that the patchset needs a review and decided to take a look.

> There are a couple of points worth bikeshedding perhaps.  I didn't
> spend much thought on the wrapper functions' names, but it's surely
> true that the semantic difference between contain_mutable_functions
> and ContainMutableFunctions is quite un-apparent from those names.
> Anybody got a better idea?

Oh no! We encountered one of the most difficult problems in computer
science [1].

ContainMutableFunctionsAfterPerformingPlannersTransformations() would
be somewhat long but semantically correct. It can be shortened to
ContainMutableFunctionsAfterTransformations() or perhaps
TransformedExprContainMutableFunctions(). Personally I don't mind long
names. This being said, ContainMutableFunctions() doesn't disgusts my
sense of beauty too much either. All in all any name will do IMO.
Naturally ContainVolatileFunctions() should be renamed consistently
with ContainMutableFunctions().

I couldn't find anything wrong with 0001..0003. The parches were
tested in several environments and passed `make check-world`. I
suggest merging them.

[1]: https://martinfowler.com/bliki/TwoHardThings.html

-- 
Best regards,
Aleksander Alekseev



pgsql-hackers by date:

Previous
From: Tomas Vondra
Date:
Subject: Re: Why do indexes and sorts use the database collation?
Next
From: Alexander Korotkov
Date:
Subject: Re: Assert failure on 'list_member_ptr(rel->joininfo, restrictinfo)'