FAQ
# New Ticket Created by Alex Jakimenko
# Please include the string: [perl #127190]
# in the subject line of all future correspondence about this issue.
# <URL: https://rt.perl.org/Ticket/Display.html?id=127190 >


Regular grep:

<AlexDaniel> m: say ^10 .grep: *.is-prime
<camelia> rakudo-moar fec061: OUTPUT«(2 3 5 7)␤»

With hyper:

<AlexDaniel> m: say ^10 .hyper.grep: *.is-prime
<camelia> rakudo-moar fec061: OUTPUT« it has 0 elements.␤()␤»

With race:

<AlexDaniel> m: say ^10 .race.grep: *.is-prime
<camelia> rakudo-moar fec061: OUTPUT« it has 0 elements.␤()␤»


More:

<AlexDaniel> m: my @a = ^1000 .hyper.grep(* > 5); say @a
<camelia> rakudo-moar fec061: OUTPUT« it has 0 elements.␤ it has 0
                     elements.␤ it has 0 elements.␤ it has 0
elements.␤ it has 0
                     elements.␤ it has 0 elements.␤ it has 0
elements.␤ it has 0
                     elements.␤ it has 0 elements.␤ it has 0
elements.␤ it has 0
                     elem…»

What is this “it has 0 elements.” thing? Why do I see it? Why it returns an
empty list?

Search Discussions

  • Will Coleda via RT at Jan 6, 2016 at 7:21 pm

    On Wed Jan 06 06:35:15 2016, alex.jakimenko@gmail.com wrote:
    Regular grep:

    <AlexDaniel> m: say ^10 .grep: *.is-prime
    <camelia> rakudo-moar fec061: OUTPUT«(2 3 5 7)␤»

    With hyper:

    <AlexDaniel> m: say ^10 .hyper.grep: *.is-prime
    <camelia> rakudo-moar fec061: OUTPUT« it has 0 elements.␤()␤»

    With race:

    <AlexDaniel> m: say ^10 .race.grep: *.is-prime
    <camelia> rakudo-moar fec061: OUTPUT« it has 0 elements.␤()␤»


    More:

    <AlexDaniel> m: my @a = ^1000 .hyper.grep(* > 5); say @a
    <camelia> rakudo-moar fec061: OUTPUT« it has 0 elements.␤ it has 0
    elements.␤ it has 0 elements.␤ it has 0
    elements.␤ it has 0
    elements.␤ it has 0 elements.␤ it has 0
    elements.␤ it has 0
    elements.␤ it has 0 elements.␤ it has 0
    elements.␤ it has 0
    elem…»

    What is this “it has 0 elements.” thing? Why do I see it? Why it returns an
    empty list?
    This was added by timo after Christmas; This debug output is the only thing in the conditional block it appears in.

    $ git show 20c796cd
    commit 20c796cd31e5148e2f8fd35aab4c7eca073696ca
    Author: Timo Paulssen <timonator@perpetuum-immobile.de>
    Date: Thu Dec 31 03:39:49 2015 +0100

         hyper now cares about sequence numbers of work

         this code wants to get a bit cleaned up. i'm sure
         the control flow could be a bit less convoluted.

    --
    Will "Coke" Coleda
  • Timo Paulssen at Jan 7, 2016 at 12:37 am
    I just kicked out the debug output, but sadly hyper + grep remains
    broken. sadly, hyper + grep has been broken for a longer time :(

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupperl6-compiler @
categoriesperl
postedJan 6, '16 at 2:35p
activeJan 7, '16 at 12:37a
posts3
users2
websiteperl6.org

People

Translate

site design / logo © 2018 Grokbase