Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re^3: March a regex using split function

by AnomalousMonk (Archbishop)
on Sep 13, 2017 at 06:18 UTC ( [id://1199263]=note: print w/replies, xml ) Need Help??


in reply to Re^2: March a regex using split function
in thread March a regex using split function

I've no idea what "our" requirement is. My practice is to deploy defensive whitespace in situations like this.

Always /xms:

  • /x always use regex whtespace for comments;
  • /m ^ $ always match embedded newlines;
  • /s dot always matches all.
These regex behavior modifications reduce the "degrees of freedom" of regexes — less to think about.


Give a man a fish:  <%-{-{-{-<

Replies are listed 'Best First'.
Re^4: March a regex using split function
by Anonymous Monk on Sep 13, 2017 at 07:34 UTC
    ppixregexplain.pl
    'mods.x' => '(?x) disregarding whitespace and comments', 'mods.-x' => '(?-x) matching whitespace and # normally',

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others having a coffee break in the Monastery: (5)
As of 2024-04-23 22:31 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found