Re: the file slurping is not working

2009-06-05 Thread Larry Wall
On Fri, Jun 05, 2009 at 01:39:02PM +0200, Carl Mäsak wrote: : Daniel (>), Leon (>>), Daniel (>>>): : >>> Then why is it that .get works fine for $*IN? : >>> : >>> while $*IN.get -> $line { : >>>       say $line : >>> } : >>> : >> : >> Because you're using a while loop instead of a for loop ;-) : >

[perl #65128] Cannot return empty typed List

2009-06-05 Thread jn...@jnthn.net via RT
On Fri Jun 05 07:29:16 2009, jn...@jnthn.net wrote: > On Sat Apr 25 09:23:43 2009, b...@abrij.org wrote: > > > > The following work as expected: > > > > my Num List sub f () { return ("A") }; > > my Num List sub f () { return (1) }; > > my List sub f () { return () }; > > > > The following dies

[perl #66270] [TODO] get Perl::Grammar.parse (with the Perl6::Grammar::Actions) to work

2009-06-05 Thread Patrick R. Michaud via RT
Test now added to S05-grammar/std.t, closing ticket. Pm

[perl #66270] [TODO] get Perl::Grammar.parse (with the Perl6::Grammar::Actions) to work

2009-06-05 Thread Patrick R. Michaud via RT
Now added in 056847f. Please add a test to t/spec so we can close this ticket. :-) Pm

Re: [perl #66250] Trouble with white space in Rakudo grammars

2009-06-05 Thread Jonathan Scott Duff
On Wed, Jun 3, 2009 at 8:08 AM, Håkon Skaarud Karlsen < perl6-bugs-follo...@perl.org> wrote: > # New Ticket Created by Håkon Skaarud Karlsen > # Please include the string: [perl #66250] > # in the subject line of all future correspondence about this issue. > # http://rt.perl.org/rt3/Ticket/Displ

[perl #66330] [BUG] Null PMC access when calling Grammar.WALK in Rakudo

2009-06-05 Thread Carl Mäsak
# New Ticket Created by "Carl Mäsak" # Please include the string: [perl #66330] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt3/Ticket/Display.html?id=66330 > rakudo: my ($meth) = Grammar.WALK(:name); $meth(Perl6::Grammar.new, '42') rakudo 10a9b

[perl #66312] [BUG] Unicode doesn't work from the terminal.

2009-06-05 Thread via RT
# New Ticket Created by Daniel Carrera # Please include the string: [perl #66312] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt3/Ticket/Display.html?id=66312 > The following lines all print "funny characters": perl6 -e 'say "ü"' perl6 -e 'say "ñ

Re: the file slurping is not working

2009-06-05 Thread Carl Mäsak
Daniel (>), Leon (>>), Daniel (>>>): >>> Then why is it that .get works fine for $*IN? >>> >>> while $*IN.get -> $line { >>>       say $line >>> } >>> >> >> Because you're using a while loop instead of a for loop ;-) > > Worse. The code I wrote has a subtle but horrible error. The condition will >

[perl #66300] [BUG] .flip and .trans don't like each other.

2009-06-05 Thread via RT
# New Ticket Created by Daniel Carrera # Please include the string: [perl #66300] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt3/Ticket/Display.html?id=66300 > To reproduce the error: "hello".flip.trans("aeiou" => "AEIOU") => too few arguments

Re: the file slurping is not working

2009-06-05 Thread Daniel Carrera
Leon Timmermans wrote: Then why is it that .get works fine for $*IN? while $*IN.get -> $line { say $line } Because you're using a while loop instead of a for loop ;-) Worse. The code I wrote has a subtle but horrible error. The condition will fail as soon as you hit a blank line!!

Re: rakudo-current loop 2-3 orders of magnitude slower than perl 5?

2009-06-05 Thread Steffen Schwigon
Parrot Raiser <1parr...@gmail.com> writes: > If Sun's propaganda about Dtrace : > http://www.sun.com/bigadmin/content/dtrace/ is anywhere near true Which I can confirm. DTrace *is* cool. Steffen -- Steffen Schwigon Dresden Perl Mongers Deutscher Perl-Workshop

Re: the file slurping is not working

2009-06-05 Thread Leon Timmermans
> > Then why is it that .get works fine for $*IN? > > while $*IN.get -> $line { >        say $line > } > Because you're using a while loop instead of a for loop ;-) Leon

Re: the file slurping is not working

2009-06-05 Thread Daniel Carrera
Carl Mäsak wrote: Aruna (>): I tested the below code on parrot-1.1.0 and it read all the lines in the file and tested same code on the latest git update (4th June 2009), it outputs only the first line. That's what C<$file.get> does -- it gives you one line per default. You want C<$file.lines>.

Re: the file slurping is not working

2009-06-05 Thread Aruna Goke
Carl Mäsak wrote: Aruna (>): I tested the below code on parrot-1.1.0 and it read all the lines in the file and tested same code on the latest git update (4th June 2009), it outputs only the first line. That's what C<$file.get> does -- it gives you one line per default. You want C<$file.lines>.

Re: the file slurping is not working

2009-06-05 Thread Carl Mäsak
Aruna (>): > I tested the below code on parrot-1.1.0 and it read all the lines in the > file and tested same code on the latest git update (4th June 2009), it > outputs only the first line. That's what C<$file.get> does -- it gives you one line per default. You want C<$file.lines>. // Carl

Announcing pun (Re: rakudo-current loop 2-3 orders of magnitude slower than perl 5?)

2009-06-05 Thread Carl Mäsak
Steffen (>), Fagyal (>>): >> However, performance is an issue. I would not mind running into >> bugs, writing some extra code to work around missing stuff, etc., >> but right now it is just hard to find any projects (for me - YMMV) >> where performance would not be a blocker. > > I suggest to start

the file slurping is not working

2009-06-05 Thread Aruna Goke
I tested the below code on parrot-1.1.0 and it read all the lines in the file and tested same code on the latest git update (4th June 2009), it outputs only the first line. #!/usr/bin/perl6 use v6; my $fname = 'README'; if my $file = open($fname, :r) { for $file.get-> $line { say $line;

[perl #66304] [BUG] Rakudo still promotes List to Array when assigning to a scalar variable

2009-06-05 Thread Carl Mäsak
# New Ticket Created by "Carl Mäsak" # Please include the string: [perl #66304] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt3/Ticket/Display.html?id=66304 > rakudo: my $a = (1,3,4); $a[1] = 8; # BAH! rakudo 10a9b2: ( no output ) hm. pmicha

[perl #66292] Something is wrong in Match.perl in Rakudo

2009-06-05 Thread Carl Mäsak
# New Ticket Created by "Carl Mäsak" # Please include the string: [perl #66292] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt3/Ticket/Display.html?id=66292 > rakudo: say ?("say " ~~ //); say $/.perl rakudo 77db80: OUTPUT«1␤No result object␤in m

[Invitation] June Dallas.p6m Meeting @ Tue Jun 9 7pm – 10pm (perl6-langu...@perl.org)

2009-06-05 Thread jason switzer
BEGIN:VCALENDAR PRODID:-//Google Inc//Google Calendar 70.9054//EN VERSION:2.0 CALSCALE:GREGORIAN METHOD:REQUEST BEGIN:VEVENT DTSTART:20090610T00Z DTEND:20090610T03Z DTSTAMP:20090605T035152Z ORGANIZER;CN=jason switzer:mailto:jswit...@gmail.com UID:g3rsts66avsaacp817n7ri1...@google.com ATTEND

Re: rakudo-current loop 2-3 orders of magnitude slower than perl 5?

2009-06-05 Thread Parrot Raiser
If Sun's propaganda about Dtrace : http://www.sun.com/bigadmin/content/dtrace/ is anywhere near true, it sounds as though it's a wheel we won't have to invent for Parrot/Rakudo. It is apparently also available for Mac OS (Leopard) http://tinyurl.com/2xas7q

[perl #66288] items of a constant array can be modified in Rakudo

2009-06-05 Thread Carl Mäsak
# New Ticket Created by "Carl Mäsak" # Please include the string: [perl #66288] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt3/Ticket/Display.html?id=66288 > rakudo: constant $ARR = (1,2,3,4);$ARR[1]=4;say $ARR rakudo 77db80: OUTPUT«1 4 3 4␤»

Re: rakudo-current loop 2-3 orders of magnitude slower than perl 5?

2009-06-05 Thread Steffen Schwigon
Fagyal Csongor writes: > However, performance is an issue. I would not mind running into > bugs, writing some extra code to work around missing stuff, etc., > but right now it is just hard to find any projects (for me - YMMV) > where performance would not be a blocker. I suggest to start using it