Andres Freund <andres(at)anarazel(dot)de> writes:
> On 2021-02-23 12:52:28 -0500, Tom Lane wrote:
>> ... It is annoying to have to expend
>> an always-on check for a can't-happen case, though.
> Wouldn't quite work like that because of the restrictions of what pg
> infrastructure we want to expose the regex engine to, but a
> if (depth < 0)
> pg_unreachable();
> would avoid the runtime overhead and does fix the warning.
Yeah, I still have dreams of someday converting the regex engine
into an independent project, so I don't want to make it depend on
pg_unreachable. I'll put in the low-tech fix.
regards, tom lane