in reply to Re^3: I need a "non-trivial" bug for my script!
in thread I need a "non-trivial" bug for my script!
Do the match in list context, and don't use $\d+ at all
Obviously you can use my($cats, $kittens) in place of @kitties there.if (@kitties = $string =~ /pattern (with) captures/) { paw_at @kitties; }
The other option is check that the match succeeded first
but $1 is ugly... unpacking into either an array or bundle of scalars will get you less maintenence-programmer hate.if ($string =~ /pattern (with) captures/) { paw_at $1; }
@_=qw; ask f00li5h to appear and remain for a moment of pretend better than a lifetime;;s;;@_[map hex,split'',B204316D8C2A4516DE];;y/05/os/&print;
|
|---|