in reply to Re: Match zero times in regex
in thread Match zero times in regex
Ignoring the symtax error, that won't work, its an infinite loop, you need
while( $pairs =~ m{(\S+) \s/ (\S+)}xg ) { my( $ip, $mask ) = ( $1, $2 ); }
See Re: Surprise: scalar(($x, $y) = split)
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Match zero times in regex
by ikegami (Patriarch) on Dec 13, 2011 at 20:00 UTC |