model-writtenrun 8531 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Boris reported that creating or calling a SQL function returning a subquery whole-row value as a named composite type crashed the backend, while explicit casts and expanded rows worked #1.
- Ayush Tiwari identified the null ParseState and asked whether to reject the conversion or implement whole-row expansion #2; Tom Lane chose a defensive error because this conversion had never worked, had an easy explicit-cast workaround, and would require substantial implementation work #3.
- Boris requested an error hint explaining the explicit-cast workaround #4, and Tom supplied a patch with that hint, the null guard, corrected parser comments, and a regression test #5.
- Ayush tested the reported cases at function creation and execution and found two additional stale comments #6; Tom incorporated those corrections in the revised patch #7, which Ayush acknowledged #8.
- Tom committed the revised patch unchanged as f76c8480f5, with backpatches through PostgreSQL 15, and confirmed completion in #9; implicit conversion remains unsupported but now produces an error and workaround hint instead of crashing.