I was playing with this code: 
https://github.com/Keith-S-Thompson/fizzbuzz-polyglot/blob/master/fizzbuzz.pl6

    [~](((1..100).map: {
        $_ % 15 == 0 ?? "FizzBuzz" !!
        $_ %  3 == 0 ?? "Fizz" !!
        $_ %  5 == 0 ?? "Buzz" !!
        $_
    })«~»("\n")).print;
 
I was cleaning it up and since not everyone can type guillemets, I wound up 
with this:

    [~](((1..100).map: {
        $_ %% 15 ?? "FizzBuzz" !!
        $_ %%  3 ?? "Fizz"     !!
        $_ %%  5 ?? "Buzz"     !!
        $_
    })<<~>>("\n")).print;

That generated this error:

    No such method 'postcircumfix:<( )>' for invocant of type 'Parcel'
      in  at src/gen/BOOTSTRAP.pm:852
      in any  at src/gen/BOOTSTRAP.pm:836
      in block  at fizzbuzz.p6:6

Reverting to guillemets fixes the problem. Is this a Rakudo bug or are double 
angle brackets not interchangeable with guillemets?


    bin/perl6 -v
    This is perl6 version 2013.01 built on parrot 4.10.0 revision 0

Cheers,
Ovid
--
Twitter - http://twitter.com/OvidPerl/
Buy my book - http://bit.ly/beginning_perl
Buy my other book - http://www.oreilly.com/catalog/perlhks/
Live and work overseas - http://www.overseas-exile.com/

Reply via email to