PCRE2Project / pcre2

PCRE2 development is now based here.
Other
917 stars 191 forks source link

Use assert() for unreachable assertions #543

Closed NWilson closed 3 weeks ago

NWilson commented 3 weeks ago

Using assert rather than abort will give a (very slightly) better error message, which includes the containing function name.

Only affects Debug builds.

NWilson commented 3 weeks ago

Good thinking. I pulled out the #include <assert.h> and moved it up a few lines.

zherczeg commented 3 weeks ago

@carenas is this patch ok now?

carenas commented 3 weeks ago

Yes, merge it please; @zherczeg