Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW

Re^3: Making a regex case insensitive

by scorpio17 (Abbot)
on Mar 06, 2007 at 18:42 UTC ( #603486=note: print w/replies, xml ) Need Help??

in reply to Re^2: Making a regex case insensitive
in thread Making a regex case insensitive

This characters will not be modified (nor will numbers, if you had any).

Replies are listed 'Best First'.
Re^4: Making a regex case insensitive
by ikegami (Pope) on Mar 06, 2007 at 18:45 UTC
    Nothing is modified, not even letters. Case is preserved.
    >perl -le "'aA' =~ /(.*)/i && print $1 aA

    Only the matching is affected. /i causes lower- and upper-case letters to match lower- and upper-case versions of itself.

    Maybe you were thinking of

    >perl -le "lc('aA') =~ /(.*)/ && print $1 aa

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://603486]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chilling in the Monastery: (6)
As of 2016-10-26 10:29 GMT
Find Nodes?
    Voting Booth?
    How many different varieties (color, size, etc) of socks do you have in your sock drawer?

    Results (340 votes). Check out past polls.