]> granicus.if.org Git - postgresql/commit
Ensure that the result of evaluating a function during constant-expression
authorTom Lane <tgl@sss.pgh.pa.us>
Thu, 11 Oct 2007 21:28:30 +0000 (21:28 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Thu, 11 Oct 2007 21:28:30 +0000 (21:28 +0000)
commitad8e3b37a7782f529a21deae1dafdbbc7b51bc17
tree5b8546967b09d6d114aff945f59d461935100cd5
parentd9e961d52737823b30549d5c130790d62a79731f
Ensure that the result of evaluating a function during constant-expression
simplification gets detoasted before it is incorporated into a Const node.
Otherwise, if an immutable function were to return a TOAST pointer (an
unlikely case, but it can be made to happen), we would end up with a plan
that depends on the continued existence of the out-of-line toast datum.
src/backend/optimizer/util/clauses.c