On Fri, Oct 13, 2017 at 1:42 PM, Szilfai Balázs <balazs@obiserver.hu> wrote:
Thanks a lot!
Ok, the (daterange, date[]) invocation is working now with (anyelement, anyarray) param list.
I assume you meant (daterate, daterange[])
But now is working with eg. (date, date[]) invocation. I can't forbid it anyway?
No. It also matches (text, text[]) and "(integer, integer[])". The best you can do is detect non-range values in the first argument and raise an exception. Or define explicitly typed functions for the variants you care about and drop the polymorphism.