I am currently trying to migrate an existing perl infrastructure from
perl 5.005/linux 6.22 to 5.6.0/linux 7.1
Most of my applications work fine, but I have found a few regex commands that
do not work in my new environment.
Here is an example - original:
if ($sb =~ /<$fi>\s*(.*?)\s*<\/$fi>/gis) {
works well on my old environment, but not on my new. If I make the
following modification the regex begins to work again
-modified:
if ($sb =~ /<$fi>\s*(.*?)\s*<\/$fi>/is) {
i.e. the global modifier causes the expression to stop working.
Does anyone have any thoughts as to what might cause this?
What I am wondering is if perhaps this is a bug in perl 5.6.0 or
if perhaps I have some configuration setting incorrect in my new
environment.
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.