ERROR: function range_overlap_array_any(daterange, text[]) does not exist
What's the mistake? Or did I break something?
When a pseudo-type is used in a function parameter specification the system enforces the constraint that the same "base" type is used for all arguments during function invocation.
"Each position (either argument or return value) declared as anyelement is allowed to have any specific actual data type, but in any given call they must all be the same actual type. [...]" - the rest of that paragraph basically explains with many words that which I summarize above but without the concept of "base type" to ease comprehension.
In this case "date" is your base type so the valid combination of arguments is
(daterange, date[])
Your first invocation (daterange, daterange[]) works if you define your function as "(anyelement, anyarray)"; thus making "daterange" your base type when invoked that way.
The invocation (daterange, text[]) is not a valid combination for any pure pseudo-argument function.