Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re^2: Iterator to parse multiline string with \\n terminator

by three18ti (Scribe)
on Oct 06, 2013 at 09:08 UTC ( #1057131=note: print w/replies, xml ) Need Help??


in reply to Re: Iterator to parse multiline string with \\n terminator
in thread Iterator to parse multiline string with \\n terminator

What's the difference between using redo and using next as a similar example above does?
  • Comment on Re^2: Iterator to parse multiline string with \\n terminator

Replies are listed 'Best First'.
Re^3: Iterator to parse multiline string with \\n terminator
by jwkrahn (Monsignor) on Oct 06, 2013 at 21:41 UTC

    next goes back to:

    while ( <$fh> ) {

    And therefore reads the next line into $_ while redo goes back to the line after that leaving $_ unchanged.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (2)
As of 2016-09-25 01:49 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Extraterrestrials haven't visited the Earth yet because:







    Results (463 votes). Check out past polls.