Re: Junctions as arguments (Pugs bug)

2006-12-20 Thread Larry Wall
On Wed, Dec 20, 2006 at 10:26:41AM -0600, Jonathan Rockway wrote: : Ovid wrote: : (reversed the message a bit) : > is 'b', any('a' .. 'h'), 'junctions should work'; : : This looks like a Test "bug"; it's doing something like: : :is 'b', 'a' # not ok :is 'b', 'b' # ok :is 'b', 'c' #

Re: Junctions as arguments (Pugs bug)

2006-12-20 Thread Jonathan Rockway
Ovid wrote: (reversed the message a bit) > is 'b', any('a' .. 'h'), 'junctions should work'; This looks like a Test "bug"; it's doing something like: is 'b', 'a' # not ok is 'b', 'b' # ok is 'b', 'c' # not ok ... If you write: ok 'b' === any('a'..'h') The result is one passing

Junctions as arguments (Pugs bug)

2006-12-19 Thread Ovid
Hi all, use v6-alpha; sub no_donut_for_you (Str $junction) { state $count = 0; $count++; return $count; } say no_donut_for_you( any( 'a' .. 'd' ) ); no_donut_for_you( any( 'a' .. 'd' ) ).say; That outputs something like the following on my system (Version: 6.2.13 (r14

Re: Pugs Bug

2005-04-05 Thread Larry Wall
On Tue, Apr 05, 2005 at 07:31:40PM +0300, wolverian wrote: : Does [EMAIL PROTECTED] DWIM, by the way? I'm not sure about the precedence. That depends on whether you mean ([EMAIL PROTECTED]).words or ~(@array.words) It happens to mean the latter. A . binds tighter than a symbolic unary

Re: Pugs Bug

2005-04-05 Thread Juerd
wolverian skribis 2005-04-05 19:31 (+0300): > Does [EMAIL PROTECTED] DWIM, by the way? I'm not sure about the precedence. Yes, . is supertight. Juerd -- http://convolution.nl/maak_juerd_blij.html http://convolution.nl/make_juerd_happy.html http://convolution.nl/gajigu_juerd_n.html

Re: Pugs Bug

2005-04-05 Thread wolverian
On Tue, Apr 05, 2005 at 09:21:41AM -0700, Larry Wall wrote: > Plus you really don't want to clutter the Str type with every little > thing you might want to do with a string. "foo".open() will probably > work, but only because it doesn't find a Str.open and fails over to > MMD dispatch, which ends

Re: Pugs Bug

2005-04-05 Thread Larry Wall
On Tue, Apr 05, 2005 at 09:36:18AM +0300, wolverian wrote: : (Replying to p6l instead of p6c as requested.) : : On Mon, Apr 04, 2005 at 10:39:16AM -0700, Larry Wall wrote: : > (Now that builtins are just functions out in * space, we can probably : > afford to throw a few more convenience functions

Re: Pugs Bug

2005-04-05 Thread Adriano Ferreira
> Shouldn't these be just methods? I guess not. This is Perl and OO is not mandatory, or even desirable all the time. Adriano.

Re: Pugs Bug

2005-04-05 Thread wolverian
(Replying to p6l instead of p6c as requested.) On Mon, Apr 04, 2005 at 10:39:16AM -0700, Larry Wall wrote: > (Now that builtins are just functions out in * space, we can probably > afford to throw a few more convenience functions out there for common > operations like word splitting and whitespace

Re: Pugs Bug

2005-04-04 Thread Larry Wall
On Sun, Apr 03, 2005 at 05:28:44PM +0800, Autrijus Tang wrote: : On Sat, Apr 02, 2005 at 09:32:12PM -0500, Stevan Little wrote: : > I was writing tests for split(, ) and I stumbled upon this : > bug: : > : > pugs -e 'split(rx:perl5//, "not good")' : > : > Will go into an infinite loop. I also tr

Re: Pugs Bug

2005-04-03 Thread Autrijus Tang
On Sat, Apr 02, 2005 at 09:32:12PM -0500, Stevan Little wrote: > I was writing tests for split(, ) and I stumbled upon this > bug: > > pugs -e 'split(rx:perl5//, "not good")' > > Will go into an infinite loop. I also tried the empty regexp in a match > on it's own, and it was not a problem. >

Re: Pugs Bug

2005-04-02 Thread Uri Guttman
> "AS" == Andrew Savige <[EMAIL PROTECTED]> writes: AS> The sometimes seemingly arbitrary semantics of p5 split seem to AS> have become something of a de facto standard, with even Java and AS> .NET following suit (I *think*, not certain about this and too AS> lazy to check right now).

Re: Pugs Bug

2005-04-02 Thread Andrew Savige
--- Stevan Little wrote: > I was writing tests for split(, ) and I stumbled upon this > bug: > > pugs -e 'split(rx:perl5//, "not good")' > > Will go into an infinite loop. I also tried the empty regexp in a match > on it's own, and it was not a problem. Further to that, I noticed that the somewh

Pugs Bug

2005-04-02 Thread Stevan Little
Autrijus, I was writing tests for split(, ) and I stumbled upon this bug: pugs -e 'split(rx:perl5//, "not good")' Will go into an infinite loop. I also tried the empty regexp in a match on it's own, and it was not a problem. - Steve