Sathishkumar has asked for the wisdom of the Perl Monks concerning the following question:

Hi All, I need help of Perl6 regex matching. Please find my below Perl6 code. I unable to find global match in the string.
my $line = 'abCdes123'; $line ~~ s:P5:i:g/abc/124/; say $line; while ($line ~~ m :P5:g/^\d{2,3}/) { my $value = "$/"; say $value; say get(); }
Thanks, Sathishkumar S

Replies are listed 'Best First'.
Re: Perl6 global regex matching
by moritz (Cardinal) on Oct 20, 2015 at 10:29 UTC
Re: Perl6 global regex matching
by Corion (Patriarch) on Oct 20, 2015 at 08:04 UTC

    So what is the output of your program and what do you expect instead?

Re: Perl6 global regex matching
by Sathishkumar (Scribe) on Oct 20, 2015 at 12:28 UTC
    Hi Moritz, Thanks for your reply. Its really helpful. Thanks, Sathishkumar S