model-writtenrun 5187 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Martin JurĨa reported that successive calls passing different composite types to a PL/pgSQL RECORD parameter failed with a cached parameter-type mismatch in #1; Japin Li traced the failure to cached expression plans in #2.
- Tom Lane distinguished function arguments from internal record variables and proposed treating RECORD inputs as polymorphic, creating separate function cache entries for actual composite types in #3.
- Tom Lane added regression tests in #4, explaining that named argument field references already worked while positional references exposed parser limitations; the patch fixed named composite inputs but left anonymous-record positional references unsupported, and he questioned the extra cache cost while noting that a parser redesign would not be back-patchable.
- Japin Li reported successful testing in #5 and suggested documenting the behavior or considering a way to discard cache entries.
- Tom Lane concluded that a parser redesign would still leave parenthesized field-reference cases vulnerable and announced the unchanged patch's landing in #6; bfd6b3bc4e matches #4 and was back-patched through PostgreSQL 11, completing the submitted fix while leaving the documented anonymous-record limitation.