> It's on the right hand-side of the regex, however. Look at the output: > > C:\src\perl>perl -pe"s<{([^}]+)}><(?:@{[ ($a = $1) =~ y/,/|/ && $a ]})>" > blargh{a,b,c}blargh > blargh(?:a|b|c)blargh > > The OP didn't want the ?: in there....
So it is! I'm usually a fan of one-liners, but I think this is a great example of something that would benefit a lot from the extra clarity that can't be shoehorned into the right half of a regex. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>