Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re: Extracting a parenthesized fragment from a string

by almut (Canon)
on Sep 11, 2009 at 11:38 UTC ( [id://794758]=note: print w/replies, xml ) Need Help??


in reply to Extracting a parenthesized fragment from a string

Maybe you could use Text::Balanced instead? (in particular extract_bracketed())

Module::CoreList says it's a core module since:

$ corelist Text::Balanced Text::Balanced was first released with perl 5.007003

(IOW, for 5.6 you'd have an additional dependency...)

Replies are listed 'Best First'.
Re^2: Extracting a parenthesized fragment from a string
by fce2 (Sexton) on Sep 11, 2009 at 12:49 UTC

    I'd forgotten about this module, but yes, it could probably do quite well. I'll try a couple of implementations based on the different ideas that have been presented here and see how they compare for readability, speed, and so forth. Cheers!

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others about the Monastery: (6)
As of 2024-04-19 06:15 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found