Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re^5: Unnecessary use of capturing in regex?

by gothic_mallard (Pilgrim)
on Nov 03, 2004 at 14:56 UTC ( [id://404911]=note: print w/replies, xml ) Need Help??


in reply to Re^4: Unnecessary use of capturing in regex?
in thread Unnecessary use of capturing in regex?

As previously mentioned, in this particular case there isn't any reason to use "(.)" over purely "."

If you were going to require the value you replaced here afterwards for another purpose then it would make sense. Otherwise "(.)" has no advantages that I'm aware of.

--- Jay

All code is untested unless otherwise stated.
All opinions expressed are my own and are intended as guidance, not gospel; please treat what I say as such and as Abigail said Think for yourself.
If in doubt ask.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://404911]
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: (2)
As of 2024-04-25 23:00 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found