This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
regexec.c: Turn test into an assertion
[perl5.git] / regexec.c
index 89da115..6438526 100644 (file)
--- a/regexec.c
+++ b/regexec.c
@@ -5552,8 +5552,7 @@ NULL
            * of the quantifier and the EXACT-like node.  -- japhy
            */
 
            * of the quantifier and the EXACT-like node.  -- japhy
            */
 
-           if (ST.min > ST.max) /* XXX make this a compile-time check? */
-               sayNO;
+           assert(ST.min <= ST.max);
            if (HAS_TEXT(next) || JUMPABLE(next)) {
                U8 *s;
                regnode *text_node = next;
            if (HAS_TEXT(next) || JUMPABLE(next)) {
                U8 *s;
                regnode *text_node = next;