Re: [HACKERS] Segfault while using an array domain

2015-11-29 Thread Tom Lane
Emre Hasegeli writes: > [ SQL function in a domain constraint doesn't work ] Hm, looks like I broke this in 8abb3cda0. Should have learned by now that long-lived caching of ExprState trees is dangerous. The proximate cause of the problem is that execQual.c is executing an expression state tree

[HACKERS] Segfault while using an array domain

2015-11-29 Thread Emre Hasegeli
I was getting segfaults while working on the current master for a while. This is the shortest way I could found to reproduce the problem: create or replace function is_distinct_from(anyelement, anyelement) returns boolean language sql as 'select $1 is distinct from $2'; create operator !== ( proc