[perl6/specs] eca5f2: Be clear about the return value of s/// et al.

2014-07-23 Thread GitHub
-regex.pod Log Message: --- Be clear about the return value of s/// et al. The various m//, and s/// constructs must all work as expected when used as a smartmatcher, which means they always return either Match or Nil, even when that has to be emulated for :g reasons.

Re: return value of s///

2004-11-19 Thread Larry Wall
On Fri, Nov 19, 2004 at 10:20:23PM +, Nicholas Clark wrote: : In perl 6 will these always return a match object? Or will it be as perl 5 : and return the number of substitutions (or the empty string if none) Yes, and yes. The match object returns the number of substitutions in a numeric conte

return value of s///

2004-11-19 Thread Nicholas Clark
Synopsis 5 has a section on the return value from matches: http://www.wall.org/~larry/syn/S05.html#return_values_from_matches However, it has nothing on the return values of substitutions. In perl 6 will these always return a match object? Or will it be as perl 5 and return the number of substit