pugscode.org/ | nopaste: sial.org/pbot/perl6 | pugs: [~] <m oo se> (or rakudo:, kp6:, elf: etc.) (or perl6: for all) | irclog: irc.pugscode.org/
Set by Tene on 29 July 2008.
wayland76 diakopter: s/leery/wary/ 01:27
ihrd perl6: 'aaaa' ~~ m/ a | aaa | aa /; $/.say; 02:06
p6eval elf 22996: OUTPUT[␤␤]
..pugs: No output (you need to produce output to STDOUT)
..rakudo 32582: OUTPUT[a␤]
ihrd I just read Moritz lesson 19 and expect 'aaa' 02:08
PerlJam the longest token version of | isn't implemented yet AFAIK 02:09
so, | behaves much like ||
(possibly identically to || :-)
diakopter wayland76: eh? 02:15
ihrd Perljam: thank you. 02:17
Perljam: I think no one need bugreport about that? 02:18
TimToady considering it's one of pmichaud's major goals for the grant he just got... 02:19
pmichaud indeed, it is. 02:20
in rakudo you need to order your tokens manually if you want ltm semantics. 02:21
(that part of my grant isn't due/expected for about 2-3 months, though. I'm hoping to use TimToady's LTM as a starting point. :-)
TimToady STD has LTM but I'm rewriting it to be faster (hopefully) 02:22
pmichaud I figure TimToady got tired of waiting for me to start on my LTM version. Either that or he (probably correctly) surmises that I'll miss a few things in my implementation 02:23
ihrd O, great :) 02:24
TimToady I just figure I should try all the wrong ways first to see if any of them is faster than the right way. :) 02:27
meppl good night 02:28
pmichaud oh, and here I figured TMTOWTDI. :-P
I guess there's only one right WTDI, though. :-) 02:29
pmichaud is TORWTDI one of our recognized acronyms? Maybe it should be :-) 02:29
doesn't sound as melodic as "Tim Toady", though. :-) 02:30
ihrd and python use it firts
pmichaud sounds more like something we'd see in a Godzilla flick.
"Godzilla meets Torwati" 02:31
PerlJam python's motto isn't "there's only one right way to do it", but rather it's more like "there's only one obvious way to do it" 02:32
ihrd PerlJam: you right 02:38
pmichaud I've learned that sometimes "right way" != "obvious way". :-) 02:49
ihrd obvious -- very strange word at all 02:50
pimchaud: good luck with that grant and LTM (s now I now what is it) implementation :) 02:51
oh, sorry, I know now I mean 02:52
i need English gramma to do something like ./English.pl -s 02:53
chrisdolan I've got a good lead on perl#60456 (an assignment regression due to ObjectRef) but I'm having trouble figuring out the right patch to fix it 03:58
Anyone have a second to look at language/perl6/src/builtins/assign.pir with me?
pmichaud chrisdolan: I'm certain the problem is that a PGE::Match object doesn't fit Rakudo semantics (yet?) 03:59
so it's acting like a Parrot Hash 04:00
and a variety of other issues.
chrisdolan Oh, I see. So, should I let it go for now, or is there something I can help with? 04:01
pmichaud let me see if I can do a quick fix. 04:10
chrisdolan I've got a workaround, so no need to rush. I've got time and energy, so I thought I'd dig in. 04:12
pmichaud yes, what's apparenty happening is that PGE::Match is getting Hash's Scalar method 04:13
thus whenever it gets assigned to a Scalar it's doing Hash conversion like things first.
pmichaud otoh, the Scalar method for Hash is probably correct for PGE::Match, too. Checking. 04:14
[particle] pmichaud: is it a simple example to show chrisdolan how you determined that?
pmichaud [particle]: I'm guessing.
[particle] learning that technique would help him investigate further in the future 04:15
pmichaud [particle]: I haven't determined it at all -- I've just been seeing his messages and making educated guesses from that.
[particle] ah, ok
pmichaud I will say that using .WHAT as a diagnostic tool is often not safe.
because we have to make many of the non-Perl 6 types "lie" in order for them to act like Perl 6 types
[particle] yes, i figured getting the methods in vars and using =:=
pmichaud so, for example, if $x.WHAT comes back as 'Str', it could be either a Perl 6 Str or a Parrot String 04:16
chrisdolan Mmm, that's good to know. I had been trusting .WHAT
[particle] &x.Scalar =:= &y.Scalar for example
pmichaud I might implement a "REALLY" method for now 04:17
pmichaud or "REALWHAT" 04:17
[particle] ORLY?
chrisdolan :)
pmichaud 'YARLY'
[particle] perfect name.
chrisdolan And (please!) make it stringify to the longname instead of the shortname (please!) 04:18
pmichaud yes, of couse.
*course
pmichaud wishes he could come up with a clever interrogative pronoun for this.
[particle] the current interrogatives are already too clever by half 04:19
the relationship between WHAT and WHO isn't obvious 04:20
pmichaud ...and 'YARLY' isn't? ;-)
chrisdolan .PARROTCLASS would suffice (if boring...) 04:22
pmichaud .PARROTCLASS it is.
building, testing, rah rah rah 04:23
now, let's see what we get. 04:26
> my %a = 1..4; say %a.PARROTCLASS;
Perl6Hash
lambdabot <no location info>: parse error on input `='
pmichaud > my %a = 1..4; my $b = %a; say $b.PARROTCLASS; 04:27
ObjectRef -> Perl6Hash
lambdabot <no location info>: parse error on input `='
pmichaud > my $m = PGE::Match.new('foo'); say $m.PARROTCLASS; 04:28
ObjectRef -> Perl6Hash
lambdabot <no location info>: parse error on input `='
chrisdolan What do you get for 'say PGE::Match.new("").PARROTCLASS' ?
pmichaud PGE;Match, I bet
say PGE::Match.new('').PARROTCLASS;
PGE;Match
chrisdolan Useful. 04:29
[particle] indeed
pmichaud and, since PGE;Match isa Hash ( a Parrot Hash), it's getting Mapping's Scalar method 04:30
and Mapping's Scalar method converts self to a Perl6Hash before returning an ObjectRef 04:31
(because assigning a Mapping to a Scalar results in a reference to a (Perl6)Hash
chrisdolan So, PGE::Match just needs a Scalar() that returns itself, right? 04:32
pmichaud so, we want to prevent that from happening for PGE;Match objects
needs to return an ObjectRef to itself.
chrisdolan Oh, right
pmichaud just a sec, I can add that.
chrisdolan It has to return ObjectRef because PGE::Match is not a perl6 Object? 04:33
pmichaud ummmmm
because we use ObjectRefs for mutable types 04:34
because we use ObjectRefs for holding mutable types in Scalar containers.
chrisdolan Hmm, I'm going to have to think about that.
pmichaud it's a bit difficult to explain.
chrisdolan That's what source code is for. :-)
pmichaud but basically, if I have my $a = [1,2,3]; my $b = $a; then $b refers to the same object as $a 04:35
chrisdolan yup
pmichaud that means that $a and $b are ObjectRefs (each pointing to the same underlying Object)
chrisdolan Got it 04:36
pmichaud that's different for immutable values, such as Int or String
with my $b = $a -- we do the same operation (copy), but in the array case we're copying an ObjectRef while for immutable values we're copying the value 04:37
chrisdolan I've been doing too much Java lately where *everything* except primitives are effectively ObjectRefs
chrisdolan "copying an ObjectRef" -- because ObjectRef is shallowly immutable? 04:38
pmichaud yes. 04:50
alas, I have to run for a bit -- I'll have to fix the PGE;Match Scalar method when I get back. 04:57
(approx 1 hour)
pmichaud I think I might change .PARROTCLASS to just be .PARROT and have it report slightly more information than the class name (like object location) 05:53
chrisdolan sounds good 05:54
pmichaud pugs: say any(1,2,2,1,2,3,1).perl; 08:57
p6eval pugs: No output (you need to produce output to STDOUT)
pmichaud pugs: say any(1,2,2,1,2,3,1);
p6eval pugs: No output (you need to produce output to STDOUT)
pmichaud pugs: my $a = any(1,2,2,1,2,3,1); say $a;
p6eval pugs: No output (you need to produce output to STDOUT)
pmichaud pugs: say 'hello'; 08:58
p6eval pugs: No output (you need to produce output to STDOUT)
pmichaud well, okay then.
moritz_ pmichaud: pugs is currently broken on the server, I had no time to fix it yet 09:00
pmichaud no problem
I was just curious about collapsing junction values. Message going to p6l.
moritz_ rakudo: say %*VM<config><revision> 09:16
p6eval rakudo 32598: OUTPUT[32598␤]
masak I don't understand the pattern involved in the 'is export' trait on some methods in S29 and not on others. 12:25
for example, Array::delete is export, but Array::exists isn't
neither is grep, first, pick, join, map on Array 12:26
masak guesses that 'is export' is simply missing from those methods, but would like to know for sure 12:27
diakopter @tell wayland76 no, I was politely suggesting a spello to TimToady 12:56
lambdabot Consider it noted.
pmichaud masak: some methods can't be exported, because the signature is different when called as a function versus when called as a method 15:20
masak aha.
pmichaud for example, @foo.grep(...) has a different signature than grep(..., @foo)
where as $num.abs() and abs($num) can have the same signature (the invocant is the first param) 15:21
[particle]1 might be nice to mention that in S29
pmichaud we (Rakudo PIR readers) can actually see this by what gets !EXPORTed in the various src/classes/*.pir files 15:22
masak aye.
but what about exist versus delete?
(I mean, apart from the fact they might be deprecated.)
ok, I think I could learn to recognize that.
[particle]1: noted.
pmichaud: ok. 15:23
nice.
pmichaud I don't know about delete versus exists. 15:53
moritz_ I think both should become an adverb in the end, no? 15:59
pmichaud If chrisdolan's patch for RT #57980 works, I am duly impressed.
yes, delete and exists are now both adverbs
[particle] pmichaud: did you look at his patch? 16:00
pmichaud [particle]: yes, that's what impresses me. I'm testing it now.
I don't think that would've ever occurred to me.
[particle] ah, ok. you'll beat me to it, then
pmichaud does anyone know (is there a way to find out) what flags/options parrot is being run with when being run from the harness? 16:06
[particle] i don't know of one 16:08
other than examining /proc during a long-running test
pmichaud hey, that's a great idea :-) 16:21
I even know a long-running test -- rx.t
moritz_ couldn't open pipe to svn process: Cannot allocate memory at /usr/share/perl5/SVN/Log.pm line 204. 16:42
moritz_ that's why rakudo_svn was missing 16:42
rakudo_svn r32618 | pmichaud++ | [rakudo]: Fix ?? !! associativity (RT #57980, chrisdolan++)
r32618 | pmichaud++ | * Patch courtesy Chris Dolan
r32619 | pmichaud++ | [rakudo]: spectest-progress.csv update: 219 files, 4590 passing, 0 failing
moritz_ 0 failing, YaY
masak yay, indeed! 16:48
moritz_ and $pass > 4k5 16:50
masak pretty impressive. 16:53
TimToady heh, storing trie lexers with Storable instead of YAML makes it run faster, and take 5x disk space o_O 17:20
moritz_ Storable produces *larger* files than YAML? that's weird 17:22
TimToady probably using I32 or I64 where yaml gets away with bytes 17:23
well, it's not quite a fair comparison, I wasn't storing fate chains in yaml, but reconstructing them from the pats 17:25
[particle] obviously your algo isn't io limited 17:27
pugs_svn r22997 | moritz++ | [t/spec] unfudge two passing TODO tests in ternary.t, (chris dolan)++ 18:11
rakudo_svn r32625 | pmichaud++ | [rakudo]: any, all, none Junctions now act like sets (RT #60444, bacek++) 19:50
r32625 | pmichaud++ | * Patch courtesy Vasily Chekalkin [email@hidden.address]
pugs_svn r22998 | pmichaud++ | [spec]: Unfudge some junction tests for Rakudo. 20:33
moritz_ pmichaud: can I intrept the recent thread '.perl and other methods on Junctions?' such that we'll get a .values method in Junction as the test suite assumes in quite some places? 20:36
moritz_ rakudo: for 'abc'.split(m/b/) { .WHAT.say } 20:40
p6eval rakudo 32625: OUTPUT[Str␤Str␤]
ZuLuuuuuu hello is there a reference manual for perl 6 functions? 20:44
moritz_ S29 comes close to that
but it needs a lot of love 20:45
ZuLuuuuuu hmmm thanks
oh my god my firefox is crushed I think that page is huge :D 20:47
is there a way to pull a list of functions and their explanation from perl interpreter? maybe I can write a cgi script to create a reference with search features etc? Sorry I am new to perl world (learning perl 5 currently) because i am interested in perl 6... 20:50
pugs_svn r22999 | moritz++ | [t/spec] test for [perl #60482] 20:51
moritz_ ZuLuuuuuu: you could use the STD.pm syntax highlighter
in the pugs repo in src/perl6/ 20:52
ZuLuuuuuu ok i will look into that thanks 20:52
literal you mean a list of functions in your script or in the language?
ZuLuuuuuu in the whole language 20:53
there was a way to it in IO language I think something like that
literal perlcabal.org/syn/S29.html
lambdabot Title: S29
moritz_ then forget my suggestion, I didn't understand your question right
ZuLuuuuuu you mean processing that page to pull function information? 20:54
literal S29 lists Perl 6's builtin functions 20:54
moritz_ the POD might be easier to parse
literal: aye, but it's partly out-of-date and rather incomplete 20:55
ZuLuuuuuu hmmmmm
masak working on that.
literal moritz_: huh, if the synopsis is out of date, what's up to date?
masak literal: the other synopses are fine. S29 isn't.
literal I see
ZuLuuuuuu yes, I mean a way to pull the function names and body codes so that I can create an always-up-to-date reference automatically 20:56
masak it's a bit less official, because most of its information is derived from the other synopses.
moritz_ literal: larry's idea of the language most of the time isn't out-of-date
ruoso ZuLuuuuuu, Perl 6 has a different notion of built-in functions..
it's not something really special
literal I see
moritz_ ZuLuuuuuu: since there's no full implementation yet, you won't get a full list either
ZuLuuuuuu hmmmmm
ruoso in Perl 6, built-in functions are regular functions that happen to be there without any use 20:57
literal this lists some common ones: svn.pugscode.org/pugs/util/perl6.vim
ruoso er...
any "use" statement
built-in basically means: "loaded at prelude"
ZuLuuuuuu then it should be even easier actually to get the list of defined functions, if they are the same with user defined functions 20:58
maybe?
ruoso later &
rakudo_svn r32627 | pmichaud++ | [rakudo]: Encourage Parrot String PMCs to promote to Rakudo Str. 21:40
rakudo_svn r32628 | pmichaud++ | [rakudo]: Encourage Parrot String to become Rakudo Str *inplace*. 22:00
pugs_svn r23000 | moritz++ | [t/spec] unfudge passing tests in integration/real-strings.t, pmichaud++ 22:07
literal was there ever discussion about some sort of event loop/model for Perl 6? 22:09
TimToady every lazy list is basically an event loop 22:10
japhb "Every tool is a weapon, if you hold it right ...." 22:24
pugs_svn r23001 | ruoso++ | [smop] make AdhocSignature mold more coherent with other molds 22:25
pugs_svn r23002 | ruoso++ | [mildew] initial support for adhoc signature... we support positional arguments with no traits 23:19
azawawi ping 23:21
azawawi @tell lambdabot ping 23:23
lambdabot Nice try ;)
azawawi @tell TimToady im getting errors in my STD_syntax_highlighter cron logs (feather.perl6.nl/~azawawi/html/S02-...ppet.html) 23:26
lambdabot Consider it noted.
TimToady looks like a partial lexer is somewhere in lex/ 23:31
lambdabot TimToady: You have 1 new message. '/msg lambdabot @messages' to read it.
azawawi is waiting for the faulty cron job to finish 23:32
TimToady: so should i 'make distclean; make'? 23:33
TimToady make clean would probably be sufficient 23:35
unless something is corrupt in the code 23:36
azawawi is trying it right now 23:37
pugs_svn r23003 | azawawi++ | [STD_syntax_highlighter] cron job now properly svn up pugs directory 23:41
r23003 | azawawi++ | [STD_syntax_highlighter] 'make clean all' instead of only 'make'
wayland76 ping 23:42
lambdabot wayland76: You have 1 new message. '/msg lambdabot @messages' to read it.
azawawi TimToady: thx; it works like a charm now... TimToady++ 23:44
azawawi sleep & 23:45