<div dir="ltr"><div class="gmail_quote"><div dir="ltr">Is there a 'best practice' idiom for parsing out multiple matches from a string, ie.<div>   'blahMatchblah blah blahMatch blah blahMatchblah'</div><div><br></div><div>Previously I've done:</div><div>  while (my ($match,$rest) = $string =~ m#(Match)(.*)) {</div><div>     $string = $rest;</div><div>  }</div><div>which works, but seems inelegant.</div><div><br></div><div>Is there a better/recommended way?</div><div><br></div><div>cheers,</div><div>Nathan</div></div></div></div>