On Fri, 20 Mar 2026 at 01:56, David Rowley <dgrowleyml@gmail.com> wrote:
>
> On Fri, 20 Mar 2026, 01:39 Tender Wang, <tndrwang@gmail.com> wrote:
>> 1197 pg_assume(attlen > 0 || attlen == -1);
>> (gdb) p attlen
>> $1 = -2
>
>
> Thanks for the report. I'll look in detail in the morning when I'm at my computer again. I guess i'll need to add an
extraparameter (that will be constant folded away during the inlining) to the deformed function to specify if cstrings
canexist in the tuple, which seemingly needs to be true when deforming minimal tuples. I'd rather not lose that
optimisationwith heap tuples.
I've pushed a fix for this. A more simple recreator was:
with cte as materialized (select relname::cstring as relname from
pg_class) select relname from cte;
David