Re: Test not working so well

2023-12-11 Thread ToddAndMargo via perl6-users
f"; say so $x.match( / ^ <+[0..9] + [a..z]> ** {$x.chars} $ / ) True Explanation of the above: This is the "match" usage of "regex". The test starts from the beginning of the string and ends at the end of the string. It asks each cell in the string if cont

Re: Test not working so well

2023-12-11 Thread ToddAndMargo via perl6-users
On 12/11/23 16:11, William Michels via perl6-users wrote: On Dec 11, 2023, at 15:54, ToddAndMargo via perl6-users wrote: On 12/11/23 15:48, William Michels via perl6-users wrote: On Dec 10, 2023, at 23:22, ToddAndMargo via perl6-users wrote: Is there a list somewhere of all the shortc

Re: Test not working so well

2023-12-11 Thread William Michels via perl6-users
> On Dec 11, 2023, at 15:54, ToddAndMargo via perl6-users > wrote: > > On 12/11/23 15:48, William Michels via perl6-users wrote: >>> On Dec 10, 2023, at 23:22, ToddAndMargo via perl6-users >>> wrote: >>> > > Is there a list somewhere of all the shortcuts, such as "alnum"? > -- https://do

Re: Test not working so well

2023-12-11 Thread ToddAndMargo via perl6-users
On 12/11/23 15:48, William Michels via perl6-users wrote: On Dec 10, 2023, at 23:22, ToddAndMargo via perl6-users wrote: On 12/10/23 22:26, William Michels via perl6-users wrote: Hi Bill, Yes it does help.  I am slowly getting there. If I do not know the length of the sting and have to as

Re: Test not working so well

2023-12-11 Thread ToddAndMargo via perl6-users
On 12/11/23 15:48, William Michels via perl6-users wrote: On Dec 10, 2023, at 23:22, ToddAndMargo via perl6-users wrote: On 12/10/23 22:26, William Michels via perl6-users wrote: Hi Bill, Yes it does help.  I am slowly getting there. If I do not know the length of the sting and have to as

Re: Test not working so well

2023-12-11 Thread William Michels via perl6-users
> On Dec 10, 2023, at 23:22, ToddAndMargo via perl6-users > wrote: > > On 12/10/23 22:26, William Michels via perl6-users wrote: > > Hi Bill, > Yes it does help. I am slowly getting there. > > If I do not know the length of the sting and have to ask > with .chars, is there a way to use a va

Re: Test not working so well

2023-12-11 Thread ToddAndMargo via perl6-users
On 12/11/23 13:39, ToddAndMargo via perl6-users wrote: On 12/11/23 00:55, Kevin Pye wrote: Seriously Todd? "What is a digit?" The characters '0' to '9' are digits.   (Unicode probably has a whole lot of others, but those will do for the moment.) Yes seriously.  Does '9' have the ascii value of

Re: Test not working so well

2023-12-11 Thread ToddAndMargo via perl6-users
On 12/11/23 00:55, Kevin Pye wrote: Seriously Todd? "What is a digit?" The characters '0' to '9' are digits. (Unicode probably has a whole lot of others, but those will do for the moment.) Yes seriously. Does '9' have the ascii value of 57 or the binary value of 9? Or do you mean a single c

Re: Test not working so well

2023-12-11 Thread Kevin Pye
Seriously Todd? "What is a digit?" The characters '0' to '9' are digits. (Unicode probably has a whole lot of others, but those will do for the moment.) On Mon, 11 Dec 2023, at 18:22, ToddAndMargo via perl6-users wrote: > On 12/10/23 22:26, William Michels via perl6-users wrote: > If I do not kn

Re: Test not working so well

2023-12-10 Thread ToddAndMargo via perl6-users
On 12/10/23 22:26, William Michels via perl6-users wrote: Inline: On Dec 10, 2023, at 12:25, ToddAndMargo via perl6-users wrote: On 12/9/23 22:49, William Michels via perl6-users wrote: f $x.match( / ^ <+[0..9] + [a..z]> ** 7 $ / ) { do something...}; What is the difference between    <

Re: Test not working so well

2023-12-10 Thread William Michels via perl6-users
Inline: > On Dec 10, 2023, at 12:25, ToddAndMargo via perl6-users > wrote: > > On 12/9/23 22:49, William Michels via perl6-users wrote: >> f $x.match( / ^ <+[0..9] + [a..z]> ** 7 $ / ) { do something...}; > > > What is the difference between > ><+[0..9] > and > <[0..9] > Nothing, atm

Re: Test not working so well

2023-12-10 Thread ToddAndMargo via perl6-users
ly worked for me. You are using the technique, so I will give it a try and you tell me what I am doing wrong: my Str $x="abc3defg"; if $x.match( / ^ <[0..9]> ** 8 $ / ) { print "True\n"; } else { print "False\n" }; False $x is the string to test `.m

Re: Test not working so well

2023-12-10 Thread Kevin Pye
On Mon, 11 Dec 2023, at 09:24, ToddAndMargo via perl6-users wrote: > On 12/10/23 14:16, Kevin Pye wrote: >> Because you asked for a match with a string consisting entirely of exactly 8 >> digits. > I am not following. :'( ^beginning of string <[0..9]> a digit ** 8 repeated exactly eig

Re: Test not working so well

2023-12-10 Thread ToddAndMargo via perl6-users
On 12/10/23 14:16, Kevin Pye wrote: On Mon, 11 Dec 2023, at 07:31, ToddAndMargo via perl6-users wrote: [0] > my Str $x="abc3defg"; if $x.match( / ^ <[0..9]> ** 8 $ / ) { print "True\n"; } else { print "False\n" }; False "3" is in the string. Why False? Because you asked for a match with a

Re: Test not working so well

2023-12-10 Thread Kevin Pye
On Mon, 11 Dec 2023, at 07:31, ToddAndMargo via perl6-users wrote: > [0] > my Str $x="abc3defg"; if $x.match( / ^ <[0..9]> ** 8 $ / ) { print > "True\n"; } else { print "False\n" }; > False > > "3" is in the string. Why False? Because you asked for a match with a string consisting entirely o

Re: Test not working so well

2023-12-10 Thread ToddAndMargo via perl6-users
On 12/10/23 12:25, ToddAndMargo via perl6-users wrote: On 12/9/23 22:49, William Michels via perl6-users wrote: f $x.match( / ^ <+[0..9] + [a..z]> ** 7 $ / ) { do something...}; What is the difference between     <+[0..9] and    <[0..9] And     / ^ <+[0..9] + [a..z]> ** 7 $ / does this

Re: Test not working so well

2023-12-10 Thread ToddAndMargo via perl6-users
On 12/9/23 22:49, William Michels via perl6-users wrote: f $x.match( / ^ <+[0..9] + [a..z]> ** 7 $ / ) { do something...}; What is the difference between <+[0..9] and <[0..9] And / ^ <+[0..9] + [a..z]> ** 7 $ / does this mean that both [0..9] AND [a..z] have to be present. In o

Re: Test not working so well

2023-12-09 Thread ToddAndMargo via perl6-users
False #Below: use `Bool`, back to a  7-character match, add `say`: [4] > my $x="abc2def";   Bool($x ~~ / ^ ** 7 $ /).say; True #Below: use `Bool`, a  8-character (non)-match, with `say`: [4] > my $x="abc2def";   Bool($x ~~ / ^ ** 8 $ /).say; False #Below: make a custom

Re: Test not working so well

2023-12-09 Thread William Michels via perl6-users
return in the REPL. Parentheses work: >>> [1] > my $x="abc2def"; ($x ~~ / ^ ** 7 $ /).so; >>> True #Below: use `Bool` instead of `so`: >>> [2] > my $x="abc2def"; Bool($x ~~ / ^ ** 7 $ /); >>> True #Below: use `Bool` to check an

Re: Test not working so well

2023-12-09 Thread ToddAndMargo via perl6-users
On 12/9/23 21:32, ToddAndMargo via perl6-users wrote: On 12/9/23 19:42, William Michels via perl6-users wrote: On 12/9/23 17:44, Tom Browder wrote: > Try: say so $= > Would you give me a quick example? Hi Todd! In the Raku REPL (MoarVM 2023.05): [0] > my $x="abc2def"; say  $x ~~ / ^

Re: Test not working so well

2023-12-09 Thread ToddAndMargo via perl6-users
On 12/9/23 19:42, William Michels via perl6-users wrote: On 12/9/23 17:44, Tom Browder wrote: > Try: say so $= > Would you give me a quick example? Hi Todd! In the Raku REPL (MoarVM 2023.05): [0] > my $x="abc2def"; say  $x ~~ / ^ ** 7 $ /; 「abc2def」  alnum => 「a」  alnum => 「b」  aln

Re: Test not working so well

2023-12-09 Thread William Michels via perl6-users
> On 12/9/23 17:44, Tom Browder wrote: > > Try: say so $= > > > > Would you give me a quick example? Hi Todd! In the Raku REPL (MoarVM 2023.05): [0] > my $x="abc2def"; say $x ~~ / ^ ** 7 $ /; 「abc2def」 alnum => 「a」 alnum => 「b」 alnum => 「c」 alnum => 「2」 alnum => 「d」 alnum => 「e」 a

Re: Test not working so well

2023-12-09 Thread ToddAndMargo via perl6-users
On Sat, Dec 9, 2023 at 18:22 ToddAndMargo via perl6-users mailto:perl6-us...@perl.org>> wrote: Hi All, What am I doing wrong here? my $x="abc2def"; say  $x=/ ^ <[0..9]> ** 7 $ /; / ^ <[0..9]> ** 7 $ / [0] > my $x="abc2def"; say  $x=/ ^ <[l..z]> ** 7 $ /; / ^ <[l..z

Re: Test not working so well

2023-12-09 Thread Tom Browder
Try: say so $= On Sat, Dec 9, 2023 at 18:22 ToddAndMargo via perl6-users < perl6-us...@perl.org> wrote: > Hi All, > > What am I doing wrong here? > > > my $x="abc2def"; say $x=/ ^ <[0..9]> ** 7 $ /; > / ^ <[0..9]> ** 7 $ / > > [0] > my $x="abc2def"; say $x=/ ^ <[l..z]> ** 7 $ /; > / ^ <[l..

Test not working so well

2023-12-09 Thread ToddAndMargo via perl6-users
Hi All, What am I doing wrong here? my $x="abc2def"; say $x=/ ^ <[0..9]> ** 7 $ /; / ^ <[0..9]> ** 7 $ / [0] > my $x="abc2def"; say $x=/ ^ <[l..z]> ** 7 $ /; / ^ <[l..z]> ** 7 $ / [0] > my $x="abc2def"; say $x~~/ ^ <[0..9]> ** 7 $ /; Nil [0] > my $x="abc2def"; say $x~~/ ^ <[l..z]>

[perl #124915] Roast rakudo skip/todo test:./S02-names/pseudo.t line:36 reason: 'various issues, skipping all for now'

2019-08-01 Thread Christian Bartolomaeus via RT
The skip directive has been removed (at least for v6.e) with commit https://github.com/perl6/roast/commit/04c7d09341 (see also https://github.com/perl6/roast/commit/2913fbe564 for v6.c and v6.d). I'm closing this ticket as 'rejected', since there wasn't added any additional information.

[perl #124860] [NYI] [UNI] [JVM] Roast rakudo skip/todo test:./S05-mass/properties-general.t line:163 reason: No 'Lr' property defined

2019-07-09 Thread Christian Bartolomaeus via RT
These tests have been adjusted with https://github.com/perl6/roast/commit/551a7ffd7b I'm closing this ticket as 'resolved'.

[perl #124838] [JVM] Roast rakudo skip/todo test:./S29-conversions/ord_and_chr.t line:168 reason: 'high character name lookup'

2019-07-09 Thread Christian Bartolomaeus via RT
This test works with more recent Java version, cmp. https://github.com/perl6/roast/commit/b5c4ed2345 I'm closing this ticket as 'resolved'.

[perl #124669] Roast rakudo skip/todo test:./S06-other/main-usage.t line:190 reason: '[NYI]'

2019-07-09 Thread Christian Bartolomaeus via RT
This test works now, cmp. https://github.com/perl6/roast/commit/472bc003f0 I'm closing this ticket as 'resolved'.

[perl #124517] Roast rakudo skip/todo test:./S03-metaops/eager-hyper.t line:35 reason: 'hyper prefix [NYI] entirely, I guess'

2019-07-09 Thread Christian Bartolomaeus via RT
The test in question works now, cmp. https://github.com/perl6/roast/commit/bba5083af5. I'm closing this ticket as 'resolved'.

[perl #124675] Roast rakudo skip/todo test:./S16-io/quoting-syntax.t line:42 reason: Unsupported use of /s

2019-07-09 Thread Christian Bartolomaeus via RT
Test has been removed with https://github.com/perl6/roast/commit/1a88ef7e03. I'm closing this ticket as 'rejected'.

[perl #124674] Roast rakudo skip/todo test:./S16-io/quoting-syntax.t line:32 reason: two terms in a row

2019-07-09 Thread Christian Bartolomaeus via RT
Test has been removed with https://github.com/perl6/roast/commit/1a88ef7e03. I'm closing this ticket as 'rejected'.

[perl #124673] Roast rakudo skip/todo test:./S16-io/quoting-syntax.t line:18 reason: undeclared routine / urecognized adverb

2019-07-09 Thread Christian Bartolomaeus via RT
Test has been removed with https://github.com/perl6/roast/commit/1a88ef7e03. I'm closing this ticket as 'rejected'.

[perl #124672] Roast rakudo skip/todo test:./S16-io/quoting-syntax.t line:8 reason: two terms in a row / unrecognized adverb

2019-07-09 Thread Christian Bartolomaeus via RT
Test has been removed with https://github.com/perl6/roast/commit/1a88ef7e03. I'm closing this ticket as 'rejected'.

[perl #131167] [JVM] Newly-added NQP test for catching exceptions fails on JVM

2019-04-17 Thread Christian Bartolomaeus via RT
I have committed https://github.com/perl6/nqp/commit/59d7a8869c and this test passes now. As far as I understand, the right handler was missed when moving to the outside, because unwind_check sets the outer handler to 0 by default if no outer handler is passed. We do the latter now. I&#

[perl #124692] [JVM] Roast rakudo skip/todo test:./S32-str/substr.t line:43 reason: 'java.nio.charset.MalformedInputException'

2019-04-04 Thread Christian Bartolomaeus via RT
On Thu, 04 Apr 2019 23:15:25 -0700, barto...@gmx.de wrote: > I'm going to change two skipped tests to 'todo'. For the record: https://github.com/perl6/roast/commit/aaf7ad02fc

Re: binary test and position?

2019-02-05 Thread ToddAndMargo via perl6-users
On 2/5/19 8:26 AM, Curt Tilmes wrote: If you have glibc (probably yes for Linux or Mac, probably no for Windows), you can call memmem(): use NativeCall; sub memmem(Blob $haystack, size_t $haystacklen,            Blob $needle,   size_t $needlelen --> Pointer) is native {} sub buf-index(Blob

Re: binary test and position?

2019-02-05 Thread ToddAndMargo via perl6-users
On 2/5/19 7:55 AM, Brad Gilbert wrote: `index` is an NQP op, which means in this case that it is written in C (assuming you are using MoarVM) https://github.com/MoarVM/MoarVM/blob/ddde09508310a5f60c63474db8f9682bc922700b/src/strings/ops.c#L557-L656 The code I gave for finding a Buf inside of an

Re: binary test and position?

2019-02-05 Thread Curt Tilmes
If you have glibc (probably yes for Linux or Mac, probably no for Windows), you can call memmem(): use NativeCall; sub memmem(Blob $haystack, size_t $haystacklen, Blob $needle, size_t $needlelen --> Pointer) is native {} sub buf-index(Blob $buffer, Blob $needle) { (memmem($buffe

Re: binary test and position?

2019-02-05 Thread Brad Gilbert
`index` is an NQP op, which means in this case that it is written in C (assuming you are using MoarVM) https://github.com/MoarVM/MoarVM/blob/ddde09508310a5f60c63474db8f9682bc922700b/src/strings/ops.c#L557-L656 The code I gave for finding a Buf inside of another one was quickly made in a way to pr

Re: binary test and position?

2019-02-04 Thread ToddAndMargo via perl6-users
On 2/2/19 9:29 PM, Brad Gilbert wrote: Subs do not need to have a `return` statement if it is returning the last value. You also broke the return value of the subroutine that I wrote by assigning it to a variable. What I wrote would return `Nil` if it failed to find a match, yours will return a

Re: binary test and position?

2019-02-03 Thread ToddAndMargo via perl6-users
On 2/2/19 9:29 PM, Brad Gilbert wrote: It is also weird that you are using CamelCase for variables, and a mixture of CamelCase and snake-case for the subroutine name. Hi Brad, An explanation. I do this for "maintainability". I have been able to "type" since high school typing class. Upper

Re: binary test and position?

2019-02-02 Thread ToddAndMargo via perl6-users
> On Sat, Feb 2, 2019 at 10:05 PM ToddAndMargo via perl6-users > wrote: >> >> On 2/2/19 6:09 AM, Brad Gilbert wrote: >>> sub buf-index ( Buf $buf, +@match ) { >>> my $elems = @match.elems; >>> $buf.rotor( $elems => 1 - $elems ).first(* eqv @match.List, :k) >>> }

Re: binary test and position?

2019-02-02 Thread Brad Gilbert
Subs do not need to have a `return` statement if it is returning the last value. You also broke the return value of the subroutine that I wrote by assigning it to a variable. What I wrote would return `Nil` if it failed to find a match, yours will return an undefined `Int`. It should return `Nil`

Re: binary test and position?

2019-02-02 Thread ToddAndMargo via perl6-users
On 2/2/19 6:09 AM, Brad Gilbert wrote: sub buf-index ( Buf $buf, +@match ) { my $elems = @match.elems; $buf.rotor( $elems => 1 - $elems ).first(* eqv @match.List, :k) } my $buf = Buf[uint8].new(0x4D, 0x5A, 0x90, 0x00, 0x03); say buf-index( $buf, (0x90, 0x00

Re: binary test and position?

2019-02-02 Thread ToddAndMargo via perl6-users
> On Fri, Feb 1, 2019 at 11:02 PM ToddAndMargo via perl6-users> wrote: >> >> On 2/1/19 8:26 PM, ToddAndMargo via perl6-users wrote: >>> On 2/1/19 8:07 PM, ToddAndMargo via perl6-users wrote: On 2/1/19 8:03 PM, ToddAndMargo via perl6-users wrote: > > On Fri, Feb 1, 2019 at 9:37 PM Todd

Re: binary test and position?

2019-02-02 Thread Brad Gilbert
sub buf-index ( Buf $buf, +@match ) { my $elems = @match.elems; $buf.rotor( $elems => 1 - $elems ).first(* eqv @match.List, :k) } my $buf = Buf[uint8].new(0x4D, 0x5A, 0x90, 0x00, 0x03); say buf-index( $buf, (0x90, 0x00, 0x03)); # 2 On Fri, Feb 1, 2019 at 11:02 PM

Re: binary test and position?

2019-02-01 Thread ToddAndMargo via perl6-users
On 2/1/19 8:26 PM, ToddAndMargo via perl6-users wrote: On 2/1/19 8:07 PM, ToddAndMargo via perl6-users wrote: On 2/1/19 8:03 PM, ToddAndMargo via perl6-users wrote:  > On Fri, Feb 1, 2019 at 9:37 PM ToddAndMargo via perl6-users  > wrote:  >>  >> On 2/1/19 7:22 PM, ToddAndMargo via perl6-users

Re: binary test and position?

2019-02-01 Thread ToddAndMargo via perl6-users
On 2/1/19 8:07 PM, ToddAndMargo via perl6-users wrote: On 2/1/19 8:03 PM, ToddAndMargo via perl6-users wrote:  > On Fri, Feb 1, 2019 at 9:37 PM ToddAndMargo via perl6-users  > wrote:  >>  >> On 2/1/19 7:22 PM, ToddAndMargo via perl6-users wrote:  >>> Hi All,  >>>  >>> On a type Buf, what do I u

Re: binary test and position?

2019-02-01 Thread ToddAndMargo via perl6-users
On 2/1/19 8:03 PM, ToddAndMargo via perl6-users wrote: > On Fri, Feb 1, 2019 at 9:37 PM ToddAndMargo via perl6-users > wrote: >> >> On 2/1/19 7:22 PM, ToddAndMargo via perl6-users wrote: >>> Hi All, >>> >>> On a type Buf, what do I use to check for the >>> position of a byte pattern? >>

Re: binary test and position?

2019-02-01 Thread ToddAndMargo via perl6-users
> On Fri, Feb 1, 2019 at 9:37 PM ToddAndMargo via perl6-users > wrote: >> >> On 2/1/19 7:22 PM, ToddAndMargo via perl6-users wrote: >>> Hi All, >>> >>> On a type Buf, what do I use to check for the >>> position of a byte pattern? >>> >>> >>> Many thanks, >>> -T >> >> >> Basically, what am I doing

Re: binary test and position?

2019-02-01 Thread Brad Gilbert
`eq` is string equality `==` is numeric equality a Buf is neither. You want `eqv` (equivalent) $b[2..4] eqv (0x90,0x00,0x04) On Fri, Feb 1, 2019 at 9:37 PM ToddAndMargo via perl6-users wrote: > > On 2/1/19 7:22 PM, ToddAndMargo via perl6-users wrote: > > Hi All, > > > > On a type Buf, what

Re: binary test and position?

2019-02-01 Thread ToddAndMargo via perl6-users
On 2/1/19 7:37 PM, ToddAndMargo via perl6-users wrote: On 2/1/19 7:22 PM, ToddAndMargo via perl6-users wrote: Hi All, On a type Buf, what do I use to check for the position of a byte pattern? Many thanks, -T Basically, what am I doing wrong here? $ p6 'my $handle=open("filever.exe", :bin,

Re: binary test and position?

2019-02-01 Thread ToddAndMargo via perl6-users
> > On Fri, Feb 1, 2019 at 9:22 PM ToddAndMargo via perl6-users > wrote: >> >> Hi All, >> >> On a type Buf, what do I use to check for the >> position of a byte pattern? >> >> >> Many thanks, >> -T On 2/1/19 7:35 PM, Brad Gilbert wrote: This would work: my $b = Buf.new( 0,0,0, 1, 2, 0 );

Re: binary test and position?

2019-02-01 Thread ToddAndMargo via perl6-users
On 2/1/19 7:22 PM, ToddAndMargo via perl6-users wrote: Hi All, On a type Buf, what do I use to check for the position of a byte pattern? Many thanks, -T Basically, what am I doing wrong here? $ p6 'my $handle=open("filever.exe", :bin, :ro); my Buf $b; $b= $handle.read(5); say $b; say $b[2

Re: binary test and position?

2019-02-01 Thread Brad Gilbert
This would work: my $b = Buf.new( 0,0,0, 1, 2, 0 ); my $match = Buf.new( 1, 2 ); $b.rotor( $match.elems => 1 - $match.elems ).grep(* eqv $match.List, :k) If you only need the first one, swap out `grep` for `first` Another iffy option is to decode it as latin1 $b.decode('latin1'

binary test and position?

2019-02-01 Thread ToddAndMargo via perl6-users
Hi All, On a type Buf, what do I use to check for the position of a byte pattern? Many thanks, -T

Re: How do I test my substitutions?

2018-08-14 Thread ToddAndMargo
On 08/14/2018 06:33 PM, yary wrote: "so" coerces to True or False. "say /c/" would output the match object "say so /c/" says True. Depends on what you want to see. " $x ?? $y !! $z" is a shortcut - "if $x use value of $y else use value of $z" and ought to be used for the final value. You may

Re: How do I test my substitutions?

2018-08-14 Thread yary
"so" coerces to True or False. "say /c/" would output the match object "say so /c/" says True. Depends on what you want to see. " $x ?? $y !! $z" is a shortcut - "if $x use value of $y else use value of $z" and ought to be used for the final value. You may know it in perl5 as "$result = $x ? $y :

Re: How do I test my substitutions?

2018-08-14 Thread ToddAndMargo
On 08/14/2018 08:29 AM, yary wrote: Or, store the string in $_, and take advantage of less to type- perl6 -e '$_="abc"; say so /z/; say so /b/; s/c/defg/ ?? .say !! say "Failed!"' -y Thank you! Well I can see it working, but what does "so" "??" ".say" "!!" do? My actual c

Re: How do I test my substitutions?

2018-08-14 Thread yary
Or, store the string in $_, and take advantage of less to type- perl6 -e '$_="abc"; say so /z/; say so /b/; s/c/defg/ ?? .say !! say "Failed!"' -y On Tue, Aug 14, 2018 at 4:17 AM, ToddAndMargo wrote: > > On 14/08/18 13:08, ToddAndMargo wrote: > >> Hi All, > >> > >> The Perl 5 guys have it pou

Re: How do I test my substitutions?

2018-08-14 Thread ToddAndMargo
> On 14/08/18 13:08, ToddAndMargo wrote: >> Hi All, >> >> The Perl 5 guys have it pounded into my head that I >> always had to check my substitutions to see if they >> worked if not working would crash the program. >> >> So in Perl 6 I have: >> >> $ p6 'my $x="abc"; if s/b/z/ {say "sub worked"}els

Re: How do I test my substitutions?

2018-08-14 Thread Timo Paulssen
You're putting your starting string in a variable, $x, but aren't telling the s/// operator specifically what to operate on, so it defaults to $_, which is still at its default value. On 14/08/18 13:08, ToddAndMargo wrote: > Hi All, > > The Perl 5 guys have it pounded into my head that I > always

How do I test my substitutions?

2018-08-14 Thread ToddAndMargo
Hi All, The Perl 5 guys have it pounded into my head that I always had to check my substitutions to see if they worked if not working would crash the program. So in Perl 6 I have: $ p6 'my $x="abc"; if s/b/z/ {say "sub worked"}else{say "sub failed"}; say "$x";' Use of uninitialized value of

[perl #124815] Roast rakudo skip/todo test:./S32-num/fatrat.t line:191 reason: 'unknown'

2018-05-14 Thread Zoffix Znet via RT
Test was incorrect. Fixed in https://github.com/perl6/roast/commit/771a2bbeb1

[perl #124815] Roast rakudo skip/todo test:./S32-num/fatrat.t line:191 reason: 'unknown'

2018-05-14 Thread Zoffix Znet via RT
Test was incorrect. Fixed in https://github.com/perl6/roast/commit/771a2bbeb1

[perl #124814] Roast rakudo skip/todo test:./S32-num/fatrat.t line:181 reason: 'FatRat arith + type objects'

2018-05-14 Thread Zoffix Znet via RT
Re-filed with more details on the issue in https://github.com/rakudo/rakudo/issues/1830

[perl #124552] Roast rakudo skip/todo test:./S03-operators/reduce-le1arg.t line:43 reason: 'expected Any but got Mu instead'

2018-05-08 Thread Christian Bartolomaeus via RT
I'm closing this ticket, cmp. https://github.com/rakudo/rakudo/issues/1797: > #124552 can be closed. Test was working but skipped. Unskipped in roast now.

[perl #124738] Roast rakudo skip/todo test:./S32-str/comb.t line:59 reason: 'cannot call match, no signature matches'

2018-05-04 Thread Christian Bartolomaeus via RT
I'm closing this ticket, cmp. https://github.com/rakudo/rakudo/issues/1797: > #124738 can be closed because the roast test was wrong, trying to use a m// > where an rx// was intended. > Fixed by samcv in roast commit > https://github.com/perl6/roast/commit/659fcf44b0

[perl #132983] Roast S32-io/IO-Socket-Async.t test fails WSL - listen "already in use" test

2018-03-15 Thread via RT
# New Ticket Created by Ron Schmidt # Please include the string: [perl #132983] # in the subject line of all future correspondence about this issue. # https://rt.perl.org/Ticket/Display.html?id=132983 > Roast S32-io/IO-Socket-Async.t has a test for a second tap on a Supply from listen wh

[perl #126702] [JVM] failing test in S06-multi/subsignature.t: wrong multi candidate called when slurpy and named are passed

2018-03-10 Thread Christian Bartolomaeus via RT
{ 1 }; multi catch(| (*@all, > > :$really! ) ) { 2 }; say catch(0, 5, :!really)' > > 1 > > > Neither the mentioned test file nor the specific code example seem to > fail on current Rakudo as well as the currently availabe camelia build > (which is a92950fb4). With conf

[perl #126702] [JVM] failing test in S06-multi/subsignature.t: wrong multi candidate called when slurpy and named are passed

2018-01-27 Thread Pepe Schwarz via RT
On Sat, 21 Nov 2015 06:12:07 -0800, barto...@gmx.de wrote: > The following code does not give the expected result ('2') on > rakudo.jvm: > > $ perl6-j -e 'multi catch(| (*@all ) ) { 1 }; multi catch(| (*@all, > :$really! ) ) { 2 }; say catch(0, 5, :!really)' &g

[perl #124540] Roast rakudo skip/todo test:./S03-operators/context-forcers.t line:96 reason: 'failure modes of Str.Numeric'

2017-12-30 Thread Zoffix Znet via RT
Fudge rejected in https://github.com/perl6/roast/commit/79803f6322

[perl #124540] Roast rakudo skip/todo test:./S03-operators/context-forcers.t line:96 reason: 'failure modes of Str.Numeric'

2017-12-30 Thread Zoffix Znet via RT
Fudge rejected in https://github.com/perl6/roast/commit/79803f6322

[perl #124832] Roast rakudo skip/todo test:./S12-enums/basic.t line:24 reason: 'Cannot convert string to number'

2017-12-02 Thread Aleks-Daniel Jakimenko-Aleksejev via RT
This ticket is replaced with https://github.com/rakudo/rakudo/issues/1296

[perl #125053] Roast rakudo skip/todo test:./S04-declarations/multiple.t line:30 reason: 'nom regression'

2017-12-02 Thread Aleks-Daniel Jakimenko-Aleksejev via RT
See https://github.com/perl6/roast/blob/03686da5d7f8d8c359e0ce6a538e29dc95e1d218/S04-declarations/multiple.t#L29-L31 Do we *really* want to allow multi subs without multi (when there's a proto)? If so, why? Because you can replace “sub” with a “multi” and it easy to do yet it adds clarity. Is thi

[perl #124617] Roast rakudo skip/todo test:./S02-magicals/DISTRO.t line:44 reason: 'no Distro.signature yet'

2017-12-02 Thread Aleks-Daniel Jakimenko-Aleksejev via RT
Actually I'm wrong. See RT#124624 for more info. On 2017-12-02 06:38:29, alex.jakime...@gmail.com wrote: > https://docs.perl6.org/language/variables#index-entry-%24%2ADISTRO > https://docs.perl6.org/type/Distro > > Tests that have to be unfudged: > https://github.com/perl6/roast/blob/master/S02-ma

[perl #124617] Roast rakudo skip/todo test:./S02-magicals/DISTRO.t line:44 reason: 'no Distro.signature yet'

2017-12-02 Thread Aleks-Daniel Jakimenko-Aleksejev via RT
https://docs.perl6.org/language/variables#index-entry-%24%2ADISTRO https://docs.perl6.org/type/Distro Tests that have to be unfudged: https://github.com/perl6/roast/blob/master/S02-magicals/DISTRO.t

[perl #125027] [REGEX] Roast rakudo skip/todo test:./S05-modifier/perl5_9.t line:35 reason: 'Quantifier quantifies nothing'

2017-12-01 Thread Christian Bartolomaeus via RT
The test in question passes now. < bartolin> bisectable6: say "ab" ~~ rx:P5/^(a(??{"(?!)"})|(a)(?{1}))b/ && $1 # RT 125027 < bisectable6> bartolin, Bisecting by exit code (old=2015.12 new=5929887). Old exit code: 1 <+synopsebot>

[perl #125021] [JVM] Failing test in S05-modifier/perl5_5.t for regex with lazy quantifier on alternation

2017-11-18 Thread Christian Bartolomaeus via RT
This works now on the JVM backend as well. I've unfudged the old tests and 've added one test with a P6 regex to S05-metasyntax/regex.t with commit https://github.com/perl6/roast/commit/ae57169b24 I'm closing this ticket as 'resolved'.

[perl #126823] [BUG] Failing test in S32-array/adverbs.t and S32-hash/adverbs.t: Code does not die as expected with 'use '

2017-11-10 Thread Christian Bartolomaeus via RT
The tests in S32-array/adverbs. and S32-hash/adverbs.t (and all code snippets in this ticket) are passing again. I'm closing this ticket as 'resolved'.

Re: tip: case insensitive test

2017-11-07 Thread ToddAndMargo
t; it was the same name but three different capitalizations and the the capitalization was a moving target.  I couldn't count on it staying the same. and `i/test/` or `:i/test/` did not work. One of the guys helped me out with this on the chat line. `m:i/test/` did the trick, and forgave

Re: tip: case insensitive test

2017-11-07 Thread ToddAndMargo
erent capitalizations and the the capitalization was a moving target. I couldn't count on it staying the same. and `i/test/` or `:i/test/` did not work. One of the guys helped me out with this on the chat line. `m:i/test/` did the trick, and forgave me for not actually doing a match. He said

Re: tip: case insensitive test

2017-11-07 Thread Brad Gilbert
file and > pick out those entries with a particular name in it. Problem" > it was the same name but three different capitalizations and > the the capitalization was a moving target. I couldn't count > on it staying the same. > > and `i/test/` or `:i/test/` did not work.

tip: case insensitive test

2017-11-03 Thread ToddAndMargo
arget. I couldn't count on it staying the same. and `i/test/` or `:i/test/` did not work. One of the guys helped me out with this on the chat line. `m:i/test/` did the trick, and forgave me for not actually doing a match. He said one of the benefits of "m" was that it allows for

[perl #127856] [LTA] error message when declaring variables without a space between “my” and parens (my($test);)

2017-10-07 Thread Aleks-Daniel Jakimenko-Aleksejev via RT
Basically, this would need to throw X::Syntax::KeywordAsFunction, but it blows up when trying to look up $test so that's rather unfortunate. Pretty sure we can do something about it but maybe it's not a one-line fix. On 2016-04-07 16:29:37, alex.jakime...@gmail.com wrote: > Code: >

[perl #125902] [LTA] error message “Type 'Str' is not declared” (my Str where 'foo' $test;)

2017-10-07 Thread Aleks-Daniel Jakimenko-Aleksejev via RT
2016-05-08 08:59:55, barto...@gmx.de wrote: > As a status update: All code snippet in this ticket die now with > X::Syntax::Malformed and complain about 'Malformed my' during > compilation (I think, it was fixed with rakudo commit e1e03e6ed5): > > $ perl6-m -e 'my Str

[perl #132108] [REGRESSION] Test output should not be buffered even for non-TTYs (prove -j 8 …)

2017-09-17 Thread Aleks-Daniel Jakimenko-Aleksejev via RT
The change was made in https://github.com/rakudo/rakudo/pull/1160 See also: https://rt.perl.org/Ticket/Display.html?id=132111 On 2017-09-16 21:06:03, coke wrote: > See https://rt.cpan.org/Public/Bug/Display.html?id=108390 which was > mentioned here: > > https://irclog.perlgeek.de/perl6/2017-09-13#

[perl #132108] [REGRESSION] Test output should not be buffered even for non-TTYs (prove -j 8 …)

2017-09-16 Thread Will Coleda via RT
See https://rt.cpan.org/Public/Bug/Display.html?id=108390 which was mentioned here: https://irclog.perlgeek.de/perl6/2017-09-13#i_15159739 -- Will "Coke" Coleda

[perl #132108] [REGRESSION] Test output should not be buffered even for non-TTYs (prove -j 8 …)

2017-09-16 Thread Will Coleda via RT
See https://rt.cpan.org/Public/Bug/Display.html?id=108390 which was mentioned here: https://irclog.perlgeek.de/perl6/2017-09-13#i_15159739 -- Will "Coke" Coleda

[perl #132108] [REGRESSION] Test output should not be buffered even for non-TTYs (prove -j 8 …)

2017-09-16 Thread via RT
are it with output like this: ===( 27;4 8/? 9/? 4/? 6/? ) **How to replicate:** Create 8 files like this: use Test; for ^20 { sleep rand; is 42, 42, ‘42 is 42’; } done-testing; Now run it with: $ prove -j 4 --exec=perl6 t/ It can be “f

[perl #132102] [JVM] ‘make test’ fails a lot of nativecall tests

2017-09-16 Thread via RT
017-09-16#i_15171820 2) 'make test' fails a lot of nativecall tests. afaik that happens because the op 'nativecallinvoke' was introduced with commit cd7dc4ce93 in lib/NativeCall.pm6 (but isn't known on the JVM backend) https://github.com/rakudo/rakudo/commit/cd7dc4ce934003b9da1e540e638ee6dbe1f44b1b

[perl #124848] Roast rakudo skip/todo test:./S12-methods/multi.t line:87 reason: 'unknown bug'

2017-09-16 Thread Christian Bartolomaeus via RT
The tests this ticket was about (from RT #69192) have been fixed with https://github.com/perl6/roast/commit/e4a2c0b589 Since the tests are passing now, I'm closing this ticket as 'resolved'.

[perl #124788] Roast rakudo skip/todo test:./S32-io/mkdir_rmdir.t line:12 reason: mkdir rmdir [NYI]

2017-09-16 Thread Christian Bartolomaeus via RT
The tests in question where adjusted and unfudged with https://github.com/perl6/roast/commit/8a351395cd I'm closing this ticket as 'resolved'.

[perl #124529] Roast rakudo skip/todo test:./S03-operators/bag.t line:69 reason: Rakudo update in progress, but not done yet

2017-09-16 Thread Christian Bartolomaeus via RT
There was a second attempt at fixing the underlying issue in Rakudo: https://github.com/rakudo/rakudo/pull/934. The tests in question were adjusted and unfudged with https://github.com/perl6/roast/pull/187. Currently there are no longer any fudged tests with this ticket number, so I'm closing t

[perl #127947] [CONC] Hangs in spectests with test that calls .quit on Supplier

2017-09-12 Thread Christian Bartolomaeus via RT
akudo-j 463e7589a1 > * 0 hangs when running golfed code from command line (s.a.) > * 1 hang when running 'perl6-j -Ilib t/spec/S17-supply/Channel.t > * 2 hangs when running 'perl t/harness --fudge --jvm t/spec/S17- > supply/Channel.t' I haven't seen a single hang in

Re: zef install --/test cro

2017-08-31 Thread Timo Paulssen
Scratch that, the openssl docs say ERR_load_error_strings(), SSL_load_error_strings() and ERR_free_strings() are available in all versions of SSLeay and OpenSSL. So maybe it's a different ssl implementation that provides libssl.so ?!?! On 08/31/2017 02:21 PM, Timo Paulssen wrote: > The erro

Re: zef install --/test cro

2017-08-31 Thread Timo Paulssen
The error for a missing libssl.so looks like Cannot locate native library 'libwhatevenisthis.so': libwhatevenisthis.so: cannot open shared object file: No such file or directory so in this case the library can be found but the symbol SSL_load_error_strings isn't in it. it might be an incompat

Re: zef install --/test cro

2017-08-31 Thread Steve Mynott
> Wanting to have a look at cro http://mi.cro.services/ > > But getting this when try to install. Any suggestions? > > $ zef install --/test cro --force-install > ===> Searching for: cro > ===> Searching for missing dependencies: Cro::WebSocket > ===> Searching f

Re: zef install --/test cro

2017-08-31 Thread Richard Hainsworth
2:45 PM, Norman Gaywood wrote: Wanting to have a look at cro http://mi.cro.services/ But getting this when try to install. Any suggestions? $ zef install --/test cro --force-install ===> Searching for: cro ===> Searching for missing dependencies: Cro::WebSocket ===> Searching for mi

  1   2   3   4   5   6   7   8   9   10   >