Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re^2: Deleting a matching string in an array

by naikonta (Curate)
on Oct 30, 2007 at 16:15 UTC ( #648044=note: print w/replies, xml ) Need Help??


in reply to Re: Deleting a matching string in an array
in thread Deleting a matching string in an array

Note that grep doesn't modify its arguments (normally...),
Are you against Note that $_ is an alias to the list value, so it can be used to modify the elements of the LIST. or you mean something else?

Open source softwares? Share and enjoy. Make profit from them if you can. Yet, share and enjoy!

  • Comment on Re^2: Deleting a matching string in an array

Replies are listed 'Best First'.
Re^3: Deleting a matching string in an array
by moritz (Cardinal) on Oct 31, 2007 at 06:36 UTC
    Shameaso seemed to use grep as if he expected it to modify the array, although he didn't modify $_ in grep's block.

    So I thought it was noteworthy that grep doesn't do in-place grepping.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://648044]
help
Chatterbox?
[Corion]: Heh. Perl heredocs are nasty - Filter::Simple doesn't know whether the line continued after the heredoc or not. The heredoc payload starts on the next line.
[Corion]: So currently, Filter::Simple mangles your code/line numbers if you use heredocs ;)

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (7)
As of 2017-01-22 10:19 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Do you watch meteor showers?




    Results (187 votes). Check out past polls.