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

Re: Pattern problem

by spadacciniweb (Deacon)
on Jan 27, 2006 at 14:21 UTC ( #525976=note: print w/ replies, xml ) Need Help??


in reply to Pattern problem

Why
$text =~ /Host System (?!#)/
??

Correct:
$text =~ /Host System [^#]/


Comment on Re: Pattern problem
Select or Download Code
Re^2: Pattern problem
by ikegami (Pope) on Jan 27, 2006 at 18:51 UTC

    $text =~ /Host System (?!#)/ is correct too. However, [^#] is probably faster and an acceptable replacement in this case.

    The problem is
    if $text =~ /Host System (?!#)/ next;
    was used instead of
    if ($text =~ /Host System (?!#)/) { next; }
    or
    next if ($text =~ /Host System (?!#)/);
    or
    next if $text =~ /Host System (?!#)/;

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (13)
As of 2015-07-02 10:48 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (34 votes), past polls