in reply to Re^2: Is there a hard limit on + in a regex?
in thread Is there a hard limit on + in a regex?

are you really sure that is the exact regex? by making the regex just one little bit more complex i can get the error i stated above. e.g. (?:<object+>)+ instead of (?:<object>)+

Replies are listed 'Best First'.
Re^4: Is there a hard limit on + in a regex?
by samtregar (Abbot) on Jul 09, 2004 at 18:57 UTC
    Yes, I'm reasonably sure. The only difference is that in XML::Validator::Schema the regex is built into a string and then compiled with qr//. But even that works from the command line:
    $ perl -e '$s = join("", (("<object>") x 160_000)); $re = qr/^(?:<o +bject>)+$/; print "ok\n" if $s =~ /$re/;' ok

    -sam

      Why don't you show us the regexp and perhaps the regexp as dumped by perl -Mre=debug? That's what will really tell you what is going on.