Re: Violation of principle that plan trees are read-only - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Violation of principle that plan trees are read-only
Date
Msg-id 405314.1747665326@sss.pgh.pa.us
Whole thread Raw
In response to Re: Violation of principle that plan trees are read-only  (Robert Haas <robertmhaas@gmail.com>)
List pgsql-hackers
Robert Haas <robertmhaas@gmail.com> writes:
> On Sun, May 18, 2025 at 7:31 PM Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> While chasing down Valgrind leakage reports, I was disturbed
>> to realize that some of them arise from a case where the
>> executor scribbles on the plan tree it's given, which it is
>> absolutely not supposed to do:

> Is there some way that we can detect violations of this rule
> automatically? I recall that we were recently discussing with Richard
> Guo a proposed patch that would have had a similar problem, so it's
> evidently not that hard for a committer to either fail to understand
> what the rule is or fail to realize that they are violating it.

I proposed a possible way to test for this at [1].  I was intending to
get around to that sooner or later, but the urgency of the matter just
went up in my eyes...

            regards, tom lane

[1] https://www.postgresql.org/message-id/flat/2531459.1743871597%40sss.pgh.pa.us



pgsql-hackers by date:

Previous
From: David Steele
Date:
Subject: Regression in statement locations
Next
From: Robert Haas
Date:
Subject: Re: Violation of principle that plan trees are read-only