Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2007-03-19

Perl 6 | Reference Documentation | Rakudo

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:06 ludwig- joined perl6
00:14 bonesss joined perl6
00:45 zev joined perl6
01:04 explorer is now known as JoaquinFerrero
01:12 shay joined perl6
01:19 gnuvince left perl6
01:25 avarab joined perl6
01:28 drupek12 joined perl6
01:40 penk joined perl6
01:41 Psyche^ joined perl6
01:47 avarab is now known as avar
01:52 Psyche^ is now known as Patterner
02:04 Schwern joined perl6
02:18 weinig is now known as weinig|zZz
03:03 lisppaste3 joined perl6
03:25 REPLeffect_ joined perl6
03:25 REPLeffect_ is now known as REPLeffect
03:31 esstone joined perl6
03:38 Aankhen`` ?eval any(<a b c>)
03:39 evalbot_r15765 ("a" | "b" | "c")
03:39 Aankhen`` ?eval $x = any(1..10); $y = all(1..10); $x <= $y
03:39 evalbot_r15765 ((Bool::False | Bool::True) & (Bool::True))
03:40 Aankhen`` Oh, good.  That explains everything.
03:40 Aankhen`` ?eval $x = any(1..10); $y = all(1..10); ($x <= $y) ?? 1 :: 0
03:40 evalbot_r15765 Error: ␤Unexpected ":: 0"␤expecting operator or "!!"
03:40 Aankhen`` ?eval $x = any(1..10); $y = all(1..10); ($x <= $y) ?? 1 !! 0
03:40 evalbot_r15765 1
03:40 Aankhen`` Yay.
03:42 Aankhen`` ?eval any(1..Inf) < 10
03:43 evalbot_r15765 pugs: out of memory (requested 1048576 bytes)
03:51 RHainsworth joined perl6
03:54 RHainsworth left perl6
04:13 justatheory joined perl6
04:46 geoffb_ joined perl6
05:09 Schwern joined perl6
05:23 dmpk2k Pugs doesn't do any form of dead code elimination at the moment, does it?
05:40 kattana_ joined perl6
05:44 lisppaste3 joined perl6
05:59 mjk joined perl6
06:14 BooK_ joined perl6
06:28 kanru joined perl6
06:34 RHainsworth joined perl6
06:37 iblechbot joined perl6
07:04 geoffb joined perl6
07:29 xinming_ joined perl6
07:40 xinming joined perl6
07:51 Schwern joined perl6
08:25 dolmans joined perl6
08:51 rindolf joined perl6
08:55 krivenok2 joined perl6
08:55 krivenok2 Hello guys!
08:56 krivenok2 I have a trouble with multi-line regexp
08:56 tene Post it!  Maybe we can help!
08:56 krivenok2 Why this code prints "NO"?
08:56 krivenok2 my $string = "Hello\nworld";
08:56 krivenok2 if ( $string =~ /\A(^\w$)+\Z/m ) { print "YES\n";} else { print "NO\n";}
08:57 tene Oh, a perl5 regex
08:57 krivenok2 if ( $string =~ /\A(^\w+$)+\Z/m ) { print "YES\n";} else { print "NO\n";}
08:57 tene Have you asked in #perl?
08:58 rindolf krivenok2: #perl
08:58 krivenok2 I can't find #perl room in rooms list
08:59 krivenok2 just perl6
08:59 tene krivenok2: type /join #perl
08:59 krivenok2 /join #perl
08:59 krivenok2 Thanks!
09:00 krivenok2 left perl6
09:11 penk joined perl6
09:14 the_dormant joined perl6
09:27 ofer0 joined perl6
09:32 Jedai joined perl6
09:33 miyagawa joined perl6
09:40 RHainsworth joined perl6
09:40 RHainsworth left perl6
09:49 yts joined perl6
10:11 yuteh joined perl6
10:12 yuteh left perl6
10:16 kanru joined perl6
10:17 yuteh joined perl6
10:32 Jedai666 joined perl6
10:46 yhsuan_ joined perl6
10:48 mjk joined perl6
11:22 fglock joined perl6
11:27 theorbtwo joined perl6
11:29 lichtkind joined perl6
11:58 charsbar_ joined perl6
11:58 buetow joined perl6
12:02 sunnavy joined perl6
12:31 jisom joined perl6
12:44 sunnavy joined perl6
12:49 weinig|zZz is now known as weinig
12:51 weinig is now known as weinig|bbl
12:51 svnbot6 r15766 | fglock++ | Sub::Multi - minor fix in dispatch(); passes v6.pm t/01-sanity/07-simple-multisubs.t
12:51 svnbot6 r15766 | fglock++ | - version 0.003
12:56 iblechbot joined perl6
13:00 the_dormant joined perl6
13:06 svnbot6 r15767 | fglock++ | v6.pm - bare 'Str' is an object
13:06 svnbot6 r15767 | fglock++ | - added syntax: 'term.meth: list'
13:06 svnbot6 r15767 | fglock++ | - added syntax: 'meth(term: list)'
13:06 svnbot6 r15767 | fglock++ | - requires Sub::Multi 0.003
13:19 Debolaz2 joined perl6
13:35 rodi joined perl6
13:35 rodi Anyone else going to the emerging techology conference next week?
13:40 mr_ank joined perl6
13:49 fglock would it be possible to allow (?<0>.) in the new p5 regex (named capture with number-only name) ?
13:49 fglock this would make it much easier to translate p6->p5 (though I can work around it)
13:55 fglock s/much//
13:59 forsaken joined perl6
13:59 ProperNoun joined perl6
14:09 ruz joined perl6
14:12 vel joined perl6
14:20 xern joined perl6
14:26 scw joined perl6
14:28 arguile joined perl6
14:29 devogon joined perl6
14:33 VanilleBert joined perl6
15:14 vel joined perl6
15:19 RHainsworth joined perl6
15:24 amnesiac joined perl6
15:49 [particle] joined perl6
15:55 GabrielVieira joined perl6
16:04 Jedai joined perl6
16:08 IllvilJa joined perl6
16:11 chris2 joined perl6
16:17 diakopter joined perl6
16:19 VanilleBert left perl6
16:23 drupek12 joined perl6
16:27 * gaal boings
16:28 audreyt @tell TimToady in "{ sub f { 1 } }; f()", &f is not visible lexically -- should the &-variable fixup fallback to &Main::g before &*g? Or is this a legitimate change from perl5?
16:28 lambdabot Consider it noted.
16:28 audreyt @tell TimToady also, spec claims that $! $/ $_ are always "implicitly lexical." are they declared for each Routine, or for each Block? That is, does "sub f { { $! } }" mean "sub f { { $OUTER::! } }" or not?
16:28 lambdabot Consider it noted.
16:29 TimToady @messages
16:29 lambdabot audreyt said 3d 20h 31m 26s ago: S06:1711 is contradicting S02:1542 badly :)
16:29 lambdabot audreyt said 3d 20h 30m 27s ago: "our multi f (){...}; { &f(1); our multi f($x){...} }" is fine, right? "our multi f(){...}; { &f(1); my multi f($x){...} }" explodes, correct?
16:29 lambdabot audreyt said 1m 16s ago: in "{ sub f { 1 } }; f()", &f is not visible lexically -- should the &-variable fixup fallback to &Main::g before &*g? Or is this a legitimate change from perl5?
16:29 lambdabot audreyt said 17s ago: also, spec claims that $! $/ $_ are always "implicitly lexical." are they declared for each Routine, or for each Block? That is, does "sub f { { $! } }" mean "sub f { { $OUTER::
16:29 lambdabot ! } }" or not?
16:29 audreyt gaal: params are part of the pad now :)
16:29 lambdabot audreyt: You have 2 new messages. '/msg lambdabot @messages' to read them.
16:29 audreyt @massages
16:29 lambdabot Limbic_Region said 1d 15h 41m 33s ago: WOW. r15726 = 87 minutes, r15751 = 148 minutes but r15761 = 30 minutes. It may have even been a few minutes faster than that. Each time pugs compiles my
16:29 lambdabot firewall sees it as a new program and asks if it is ok to let it open a socket (one of the http tests). I wasn't paying attention since it never asks that quickly.
16:29 lambdabot allbery_b said 20h 3m 41s ago: 6.7 build fixed, and is much faster (and leaves my machine more usable) both building and running
16:29 gaal audreyt: do you think that if we had a scheme to annotate positions from without the main ast structure, we could get better compression? Ann MkPos{} RealNode spoils identity
16:31 gaal eg consider Ann MkPos{} bar@{......Ann MkPos{} foo@{}}
16:31 gaal now, since positions do not recur, the best we can do is memoize foo, where foo does not contain position annotations
16:32 gaal while in principle bar could have been a duplicate, too
16:32 audreyt gaal: well, GHC's way is to have
16:32 TimToady up till now a bare "sub" declaration would default to "our", so the outer f() would find f via the current package.
16:32 audreyt type AnnExpr bndr annot = (annot, AnnExpr' bndr annot)
16:32 audreyt data AnnExpr' bndr annot
16:32 audreyt  | AnnLam      bndr (AnnExpr bndr annot)
16:32 audreyt  | AnnApp      (AnnExpr bndr annot) (AnnExpr bndr annot)
16:32 audreyt etc etc
16:32 fglock joined perl6
16:32 gaal *nod*
16:32 audreyt i.e. another data type that separates annotated vs unannotated
16:33 audreyt so we have
16:33 audreyt deAnnotate :: AnnExpr bndr annot -> Expr bndr
16:33 audreyt etc
16:33 gaal hmm that doesn't solve compressibility, because the problem lies in the recursion
16:33 audreyt TimToady: but I thought pkgvar has to be qualified, i.e.
16:33 audreyt "{ our $f }; say $f"
16:33 audreyt is illegal
16:33 audreyt under default stricture
16:34 gaal we need a xanaduish nonexplicit anchor
16:34 audreyt or is the rule somehow different for &f?
16:34 TimToady not to get to your own package!
16:34 audreyt oh?
16:34 audreyt "sub f {our $f}; say $f"
16:34 audreyt "sub somesub {our $f}; say $f"
16:34 audreyt this is legal?
16:34 audreyt I thought you need to say
16:34 audreyt "sub somesub { our $f }; say our $f"
16:34 audreyt instead
16:35 Southen joined perl6
16:35 audreyt I'm fine with saying that &f fallsback to &CurPkg::f if not found in lexical scope, but $f does not...
16:35 audreyt which is closest to p5
16:36 TimToady but in P5 even $f looks in package under use strict
16:36 audreyt $ perl -Mstrict -e 'sub somesub { our $f }; $f'
16:36 audreyt Variable "$f" is not imported at -e line 1.
16:36 audreyt Global symbol "$f" requires explicit package name at -e line 1.
16:36 audreyt Execution of -e aborted due to compilation errors.
16:37 TimToady interesting
16:38 kanru joined perl6
16:38 audreyt also S02:
16:38 audreyt The postdeclaration may be in any lexical or package scope that
16:38 audreyt could have made the declaration visible to the provisional call had the
16:38 audreyt declaration occurred before rather than after the provisional
16:38 audreyt call.
16:38 audreyt which seems to justify the &f-special treatment
16:39 audreyt but again that paragraph was just dealing with
16:39 audreyt f()
16:39 audreyt instea of &f()
16:39 audreyt so maybe f() is translated to Main::f() if at end of compunit, no lexical f is fount but pkg f is found
16:39 audreyt but if you had said
16:39 audreyt &f()
16:39 audreyt then it fails, the same way $f() fails. that seems consistent, yet a bit surprising.
16:40 PerlJam people are already going to be surprised at many other things.
16:40 PerlJam consistency over surprise!  :-)
16:40 audreyt that too is true :)
16:40 audreyt well if the p5 idiom
16:40 TimToady hmm, well, your package is your public interface, so you ought to be able to call it yourself.  But it's not so important to have variables visible through the public interface
16:41 PerlJam (though, I have to admit that the p5er in me expects the &f special case)
16:41 audreyt "{ my $shared_lex; sub f () {...}; sub g () {...} }; f(); g();"
16:41 audreyt is to be preserved
16:41 audreyt then f() needs to be resolvable back to $Pkg::f
16:41 audreyt er &Pkg::f()
16:41 audreyt but whether &f() should work or not is another question
16:41 audreyt and I _think_ I'd like a bit more consistency here... maybe
16:41 TimToady so I think I can agree with that consistency
16:42 audreyt ok, cool
16:42 audreyt gaal: re the Pos question -- I don't actually have a good answer to that except the p5 way
16:42 audreyt i.e. generate unique numbers to associate with each node
16:43 audreyt and then have a map from cop_seq to annotations
16:44 gaal but the unique numbers can't be explicit in the serialized structure either...
16:44 audreyt the incrementing counter can be part of parser state
16:44 TimToady I think people will expect $_ $/ $! to scope to the current block
16:44 audreyt gaal: why not?
16:44 gaal because then it won't memoize, again :)
16:44 audreyt TimToady: "{ $_ = 3; if True { $_ = 4 }; say $_ }"
16:44 audreyt would print 3 then?
16:45 TimToady I think people will expect inconsistent things.  :)
16:46 audreyt hrmph.
16:46 fglock I'd prefer to write 'my $_=4'
16:46 PerlJam I currently expect $_ to be a "super-global" as the PHP folks say but that it can be auto-scoped sometimes.
16:46 PerlJam (in absense of some other declarator that is)
16:46 PerlJam s/other//
16:47 TimToady the way we originally designed it, $_ would be bound to the OUTER::_ unless the caller of the block supplied it as an argument.
16:48 TimToady so it would print 4
16:48 TimToady because "if" doesn't supply a new $_
16:48 gaal consider the repetitive code "if 42 say <moose>; if 42 say <moose>". Ideally we want that serialized as [&1 [{{{if 42 say <moose>}}}], *1]  (handwaving yamly syntax here)
16:48 TimToady but "for 1..10 {...}" does
16:49 audreyt TimToady: so that means
16:49 audreyt "my $_ = 123; sub f { say $_ }; f(); "
16:49 audreyt prints 123?
16:50 TimToady no, routines always get a fresh $_
16:50 TimToady it's only blocks that fudge it.
16:50 gaal the best we can do now is something like [&1 [Pos X &2 Cond Pos Y &3 42 Pos Z &4 {{{say <moose>}}}], [Pos X2 Cond Pos Y2 *3 Pos Z2 *4]
16:50 gaal which is much less efficient
16:50 audreyt so why not say routines always get $_ $! $/
16:51 TimToady they do
16:51 audreyt and blocks explicitly topicalize if they want to?
16:51 audreyt it seems silly to say
16:51 audreyt oh ok, good :)
16:51 gaal if instead of a pos node you have a counter, you still have to have a different value in each occurrence of the *1 if statement, so memoization still breaks
16:53 gaal if we had a structure (that would only make sense if you looked at its entirety, but that's okay) that had *every* node implicity assigned a running number, then we could append a sparse map with positions
16:54 gaal of course, that would cost runtime transformation both ways...
16:54 Limbic_Region joined perl6
16:54 gaal and I'm not sure I know how to implement it...
16:55 * avar pokes the pugs people with http://sial.org/pbot/23601 :)
16:55 lambdabot Title: Paste #23601 from Someone at 85.197.228.236
16:57 avar perl5.9.5 -Mblib -Mre::engine::PCR -lE 'if ("aoeu" =~ /((.).)./) { say $1 }'
16:57 avar ao
16:57 avar :)
16:57 audreyt avar: oooooh
16:57 fglock avar: nice! are you publishing it?
16:57 avar audreyt: comments on the API?
16:57 gaal there are perl -lne '$x = () = $_ =~ /(MkPos)/g; print $x' blib6/lib/Prelude.pm.yml  =>  550
16:58 gaal pos nodes
16:58 avar yeah, when I finally get re::engine::Plugin v0.02 on CPAN
16:58 gaal in prelude
16:58 gaal (and as many associated Ann nodes, of course)
16:58 audreyt gaal: can you strip those nodes and see how much startup we buy?
16:59 audreyt it's only worthwhile if it's.. worthwhile :)
16:59 gaal sure. :)
16:59 avar wrt Pugs::Compiler::Rule, would it be possible to supply pos => *after* ->compile for multiple ->matches?
16:59 fglock avar: btw, I'm trying to find out how to package 5.9.5 named captures into a match object; ideas welcome
16:59 avar this is required for re::engines that implement m//g
17:00 avar it's either that or compiling the pattern all over again with ->compile, can-do, but more expensive:)
17:00 diotalevi joined perl6
17:00 avar I note that I haven't understood Pugs::CR internals:)
17:00 fglock avar: it supports a 'continue' flag; I think there is an example somewhere (looking)
17:00 forsaken joined perl6
17:00 avar fglock: You want $+{eek} to be a match object?
17:01 avar perl5.9.5 -Mblib -Mre::engine::PCR -lE 'if ("aoeu" =~ /((.).)./) { say ref $& }'
17:01 avar Pugs::Runtime::Match
17:01 avar same for $1 et al
17:01 * ingy got his passport finally. looks like I'll be able to go to yapc after all...
17:01 fglock avar: I only need to know the 'from' and 'to'
17:01 avar fglock: mm, lost you there, where do you need that?
17:01 fglock one sec
17:03 avar oh, and I'm also thinking of how to wrap grammar => in engine::PCR and supporting ::Regex and ::Token as well as ::Rule
17:03 fglock avar: http://svn.pugscode.org/pugs/perl5/Pugs-Compiler-Rule/lib/Pugs/Compiler/RegexPerl5.pm
17:03 lambdabot http://tinyurl.com/2d3mqm
17:03 avar if ("aa" =~ /rx: pattern/ perhaps?
17:04 avar there aren't a whole lot of ways to pass options around, all you get are /msixp and the pattern
17:05 fglock local @PCR::options = qw(ratchet);
17:05 fglock mm - no
17:06 avar me likes his implementation of $1, $2, et al
17:06 avar $re->captures( sub { my ($re, $n) = @_; $match->[$n - 1] } ); # :))
17:06 avar $1 implemented with closures:)
17:07 RHainsworth joined perl6
17:08 RHainsworth left perl6
17:09 justatheory joined perl6
17:09 lichtkind joined perl6
17:10 prly_ joined perl6
17:10 fglock avar: re /g, supplying { continue=>1 } at runtime should return the next match
17:10 fglock this is not much tested
17:11 avar to ->match?
17:11 fglock see PCR t/10-regex_perl5.t
17:12 fglock yes
17:12 avar with "1" being a POS offset?
17:12 * avar looks
17:13 avar maybe use re::engine::Pugs::Compiler 'Rule'; is the best way?
17:13 avar hrmp
17:13 lichtkind unbelievable in the wp perl article was written that perl uses pcre
17:14 avar fglock: rm, RTFS:)
17:14 avar the german one?
17:14 lichtkind avar of course
17:14 lichtkind avar i seldom check the english even when its on my wishlist to translate the german perl article
17:15 avar audreyt: do you have co-maint to give out for re::engine::PCRE? Have I asked you this before?;)
17:15 avar The geman one is usually better though
17:16 avar more succinct, en. is so full of redundant crap that fails to explain the simplest of concepts
17:16 lichtkind avar because its maintainem by me :)
17:16 lichtkind german like logical structures a lot
17:16 TimToady I wonder if it makes sense to be able to declare resource limits on any dynamic scope?
17:16 lichtkind even MJD was pro a translation
17:16 avar germans++
17:16 prly__ joined perl6
17:17 fglock TimToady: it would be a nice thing to have
17:17 lichtkind audreyt im not yet finished there was more than i thought to revamp but its not much left
17:18 lichtkind avar your to kind, whats your interest in this expedition?
17:18 ajs_ TimToady: you mean, something like, "within this scope, memory usage may not grow more than X?"
17:19 TimToady was coming at it more from the time perspective, but that would be a logical generalization
17:19 avar lichtkind: expedition?
17:20 TimToady TheDamain gave me feedback about the conjecture in S05 that :exhaustive should have a time limit, and he thought it should be generalize to a :timeout option, but I'm thinking it wants to generalize further than that.
17:20 lichtkind avar: yes this exploration where no man has thrown a leg before called perl6
17:20 TimToady I'm not sure about the performance implications though.
17:21 ajs_ Interesting. I think the problem would be: how would execution time constraints play with an existing SIGALRM handler if any?
17:21 ajs_ under POSIX systems
17:21 TimToady I think it would be advisory more than mandatory: "If and when you notice this scope using more than X units, make it throw an exception"
17:22 TimToady so it'd be okay to check every now and then
17:22 ajs_ Ah, ok. So not a replacement for timeouts in general, then. Cool.
17:23 TimToady but I don't know how you account for which dynamic scopes would own which memory resources
17:23 TimToady and presumably you'd have to have a story for not counting time spent by another thread against your thread.
17:24 bonesss joined perl6
17:24 ajs_ That's an interesting problem. As is the play between continuations and resource control.
17:25 TimToady and it's really only mostly for sanity from the human perspective, so just wall clock time limits would be a good start
17:25 TimToady as long as we keep the API open to other resources
17:25 bonesss joined perl6
17:25 * ajs_ goes back to work, sadly
17:28 wilx` joined perl6
17:28 gaal audreyt: got a min for generics help?
17:29 pasteling "gaal" at 192.115.25.249 pasted "type error" (10 lines, 922B) at http://sial.org/pbot/23602
17:31 lichtkind avar: do i get an answer?
17:31 fglock limits are probably implementable at the compiler level, adding some extra code
17:32 avar lichtkind: I have no idea what you're going on about:)
17:33 lichtkind avar:  i asked about your interest and actions acording to perl6/ i simply dont know you
17:33 fglock problem is how to timeout external libs, such as the regex engine
17:33 gaal svk cat -r11738 src/Pugs/AST/CapInternals.hs | grep -15 doExtractPlaceholderVars suggests this is the right direction...
17:34 gaal (orig r11644)
17:34 audreyt a sec
17:34 avar lichtkind: interested in various stuff;)
17:34 gaal sure :)
17:34 avar lichtkind: Mainly in getting it used "in the real world", which is partly why I'm playing with re plugins in 5.10:)
17:34 * avar is going to make re::engine::PGE :)
17:35 lichtkind avar: that are full perl6 rules in perl5?
17:36 avar yeah, using the parrot grammar engine
17:36 lichtkind avar: first i thought your alvar a german guy
17:36 audreyt gaal: you need mkT
17:36 avar PGE is probably more viable than Pugs::Complier::Rule which makes my perl script as slow as pugs code:)
17:36 gaal oh!
17:36 lichtkind avar: but pge produces parse tree
17:36 audreyt there's a example in src/Text/Parser/Rule.hs
17:36 gaal right
17:37 gaal thanks :
17:37 gaal )
17:37 avar lichtkind: yeah
17:37 audreyt :)
17:37 [particle] avar++
17:37 lichtkind but how to squeese a parse tree into perl5?
17:37 avar I need to learn how to embed parrot though
17:37 gaal I thought gmapT was = everywhere . mkT...
17:37 avar you wouldn't expose the parse tree, just match objects
17:37 [particle] cd ext/Parrot-Embed && Makefile.PL && make
17:37 audreyt avar: there's also a faster one in misc/pX/Common/yet_another_regex_engine if you're interested :) but Parrot::Embed sounds like fun too
17:38 avar [particle]: mm, cool
17:40 lichtkind avar: i dont grok that yet
17:40 gaal not having P.A.Internals will be such a relief :)
17:40 audreyt working on it :)
17:40 audreyt (now passing slightly more tests)
17:40 gaal :)))
17:40 audreyt both Sym and Pad nodes are gone now
17:40 avar I wonder if that wraps all the datatypes pge needs..
17:41 gaal how are proto decls expresed?
17:41 fglock joined perl6
17:41 gaal proto values that is, my $x = 8
17:42 gaal (that's what Exp.Pad was used for, right?)
17:43 fglock is there profiling results for yet_another_regex_engine?
17:44 nxu7-wrk joined perl6
17:44 dmpk2k joined perl6
17:46 lichtkind avar: so its pure magic how pge works inside perl?
17:54 audreyt fglock: time make test or something like that... putter has posted some numbers before iirc
17:54 geoffb audreyt: are you still planning that your pad branch will drop "tonight"?
17:55 gaal hmm. everywhere requires Exp to instantiate Data. ouch.
17:57 gaal but hey, looks like it can be derived
17:58 gaal whee. I was sure it'll failed on some subordinate datatype....
17:59 gaal hahaha yes indeed it does, only far away from the derivation :(
17:59 gaal which actually makes sense come to think of it
17:59 gaal because of open instances etc. hmmmmm....
18:00 gaal that'll require Data (Eval Val), which I can fake :/
18:00 gaal remind me why there's separate Data and Typeable classes? :(
18:01 audreyt gaal: it's a PadEntry with _proto
18:02 audreyt geoffb: I don't know yet :) in the next 24 hours though.
18:02 audreyt the #1 problem is that Prelude.pm doesn't like the new pad code
18:02 fglock oops - Data::Bind->sub_signature should bind @_ to @{$_[0]} in v6.pm ?
18:02 audreyt which was just clarified by TimToady
18:02 audreyt but that requires a restructure
18:02 gaal argh, I remember now that we actaully removed the data derives from Exp ages ago... it'll be painful to remoose them. ideas?
18:02 audreyt (previously f() and &f() are the same thing)
18:03 fglock does @_ in perl6 only contain the positional arguments?
18:03 audreyt fglock: correct
18:03 fglock k
18:03 audreyt (but now f() and &f() requires two nodes, which I'm still trying to devise a clever representation for)
18:04 chris2 joined perl6
18:05 buetow joined perl6
18:06 vel joined perl6
18:07 penk joined perl6
18:11 gaal bbiab &
18:11 Limbic_Region joined perl6
18:16 offby1 joined perl6
18:31 [particle] joined perl6
18:34 VanilleBert joined perl6
18:37 Kinbote joined perl6
18:42 Kattana joined perl6
18:45 bonesss is now known as bonesss`out
18:48 offby1 ping?
18:48 allbery_b hm?
18:49 offby1 just checkin' to see if my IRC client had flaked out.  It has not.  That is all :-)
18:51 xerox joined perl6
18:57 drupek12 joined perl6
18:57 Caelum joined perl6
19:02 svnbot6 r15768 | fglock++ | v6.pm - @_ is now aliased to the list of positional arguments
19:03 ozo_ joined perl6
19:03 ajs_ Does that imply $_ and %_ get aliased to invocant and named parameters as well?
19:04 audreyt no...
19:04 audreyt though for methods %_ does gets named by default
19:04 marmic joined perl6
19:05 ajs_ It just seemed an obvious extension of the capture concept if @_ was aliases to positionals.
19:06 audreyt yeah it was like that before
19:07 audreyt but then confusion between .foo and $.foo is a bit too much
19:07 audreyt so Juerd invented this .foo vs ./foo syntax
19:07 audreyt but then ./foo was changed to $.foo
19:07 audreyt and there was much general happiness.
19:09 wolverian heh, I wonder if the html version of S26 is valid in any html spec
19:10 gaal rehi
19:10 gaal I wonder if for the sake of the test it's worth de-possing the yaml from outside pugs
19:11 forsaken joined perl6
19:11 gaal but would YAML::Syck roundtrip prelude.yml? prolly not :/
19:12 bonesss`out is now known as bonesss
19:13 gaal heh, x8 size
19:13 gaal and way bogus tags
19:15 avar (./foo)--
19:15 gaal why?
19:15 avar looks lame:)
19:15 [particle] relative pathing
19:15 gaal terribly cute iyam
19:16 gaal but that's one flogged horse
19:16 avar aren't has() vars inherited?
19:17 gnuvince joined perl6
19:20 TimToady vars are never inherited, only accessors.
19:21 TimToady but $.foo is an accessor, not a var
19:21 TimToady the real var is named $!foo
19:23 rashakil__ joined perl6
19:23 gaal or, hmm, I can just not do it with generics...
19:24 kolibrie speaking of accessors,
19:24 kolibrie fglock: is there a way to call a method from an object returned from a match?
19:24 kolibrie in pcr
19:25 fglock kolibrie: just call it?
19:25 kolibrie I have been using $$match->{$key} to get to the values
19:26 fglock $$match->{$key}->meth should work
19:26 * kolibrie has been trying $$match->$key()
19:27 [particle] $$match->{$key}->() ??
19:27 fglock ${$match->{$key}}->meth if $key is a capture that contains a return object
19:28 * gaal patches matterns
19:31 kolibrie fglock: Can't locate object method ...
19:33 fglock does ref( ${$match->{$key}} ) returns the right class name?
19:33 fglock nopaste a sample program?
19:36 forsaken joined perl6
19:37 kolibrie fglock: looks like my $match is the $m->{$key}, so ref($$match) gives me my object name
19:38 kolibrie $$match->$method() gives me Can't locate object method "$method"
19:39 kolibrie I can put together a small sample program
19:47 jisom left perl6
19:50 fglock kolibrie: you mean you are using ${$match->{$key}}->$method(), right?
19:52 kolibrie $match = $match->{$key}; # match is now object; $match->{$accessor}; # ok; $match->$accessor(); # Can't locate object method ...
19:54 kolibrie so far I've only needed 'has' accessors in perl 5 land, but now I need to read from a method, and cannot seem to call it
19:55 kolibrie my grammar and emitter are native perl 6, compiled with v6.pm, the script is native perl 5
19:55 kolibrie if that matters
19:58 fglock maybe take a look at the generated .pmc files; you might be seeing a v6 compiler bug?
19:58 * kolibrie still trying to build a sample script
19:59 offby1 the one nice thing about a language that's still being hacked on: when you blame a bug on the compiler, there's a chance you're actually right
20:00 fglock for some value of 'nice' :)
20:01 offby1 yeah
20:10 amnesiac joined perl6
20:11 gaal so, I ended up just whacking MkPos' asYAML instance :)
20:11 gaal -rw-r--r-- 1 gaal gaal 76365 2007-03-19 16:11 blib6/lib/Prelude.pm.yml
20:11 gaal -rw-r--r-- 1 gaal gaal 38474 2007-03-19 16:11 blib6/lib/Test.pm.yml
20:11 gaal as opposed to:
20:11 gaal -rw-r--r-- 1 gaal gaal   107033 2007-03-19 13:22 Prelude.pm.yml
20:11 gaal -rw-r--r-- 1 gaal gaal    58046 2007-03-19 13:22 Test.pm.yml
20:12 gaal the speed difference (not entirely reliably measured) is about 4-8%
20:12 gaal so, possibly not worth the effort, especially if newVal/newAST isn't going to derive Data.
20:13 audreyt ok.
20:13 * audreyt meanwhile is adding circularity support to DrIFT.YAML
20:13 audreyt once it's done I'll checkin padbranch.
20:13 gaal (if we do do this, the files will also have to have the Pos fixup table appended, but that can be much more compact than MkPos serialization
20:13 bernhard joined perl6
20:14 gaal yay!
20:14 gaal brb
20:15 penk joined perl6
20:16 gaal (back)
20:17 kolibrie fglock: ok, the sample script clarified some things
20:17 kolibrie it is the 'has' accessors that are behaving strangely
20:17 pasteling "kolibrie" at 66.239.158.2 pasted "fglock: sample script showing accessor as method problems" (45 lines, 1.1K) at http://sial.org/pbot/23605
20:18 fglock looking
20:19 lichtkind avar: would you be interestet in proofreading an de -> en tranlation of the perl article?
20:20 audreyt gaal: I'm too sleepy to get the circularity thing right :-/
20:21 gaal ok :)
20:21 audreyt gaal: if you have some cycles, can you try getting DrIFT.YAML serialize two TVars, each pointing to a singleton list containing each other, correclty?
20:21 audreyt once it's there, Prelude.pm.yml won't take infinite time to generate
20:21 fglock it may be a problem with Moose.pm (still looking)
20:21 gaal what's the yaml look like for that?
20:22 audreyt - &1 [*2]
20:22 audreyt - &2 [*1]
20:22 audreyt or something like that?
20:22 gaal ok
20:22 * kolibrie has Moose 0.12
20:22 audreyt I'll post the branch diff
20:22 audreyt and finish it tomorrow
20:22 gaal HsSyck does do that right, right?
20:23 audreyt right
20:23 gaal the plan is handing it over anchor-annotated nodes?
20:23 audreyt http://perlcabal.org/~audreyt/tmp/YAML.hs
20:23 gaal thanks
20:24 audreyt restores it for tvar
20:24 fglock kolibrie: same problem here; the p5 code is " has 'url' => (  ); "
20:24 rashakil joined perl6
20:24 audreyt but then the compression doesn't jive well
20:24 audreyt with that
20:25 gaal hmm right. I see the version you put up reverts part of the comression stuff?
20:25 gaal (-IntMap +IntSet again)
20:26 audreyt er that is irrelevant
20:26 audreyt not compression
20:26 fglock hmm - " has 'url' => ( is => 'ro' ); " works - fixing...
20:26 audreyt we switched to IntMap to try if it's stableptr earlygc
20:26 audreyt it's not it
20:26 kolibrie fglock: what is it supposed to be?  looks like Moose is just expecting traits (rw, isa) to go in there
20:26 audreyt so intset == intmap
20:26 gaal ok
20:27 audreyt Huge diff: http://perlcabal.org/~audreyt/tmp/pad-branch.diff
20:27 audreyt compiles; runs; passes sanity
20:27 audreyt but Prelude.pm.yml gen is broken
20:27 audreyt works fine when recomp prelude
20:27 audreyt I mean, resource prelude
20:27 audreyt but too slow to meaningfully run smoke with
20:27 audreyt so tomorrow.
20:27 audreyt sorry for late :)
20:27 audreyt *wave* &
20:27 kolibrie fglock: oh, just saw your 'is => 'ro'' comment
20:27 gaal moose :)
20:31 mathlord joined perl6
20:32 kolibrie fglock: changing my 'has' lines to 'rw' seems to emit correct p5 code, as well
20:32 VanilleBert left perl6
20:36 Loro joined perl6
20:37 avar lichtkind: sure, I don't know german though;)
20:37 fglock kolibrie: fixed
20:37 lichtkind avar: nono check the english and you knoe perl a littl ei suppose
20:39 * kolibrie pulls
20:39 svnbot6 r15769 | fglock++ | v6.pm - Moose requires that attributes have an 'is ro' declaration; noticed by kolibrie++
20:40 kolibrie fglock: thank you!
20:40 integral joined perl6
20:43 fglock np :)
20:43 lichtkind avar: k have to gow i remember you see you later
20:51 rlb3_work joined perl6
20:51 sri_ joined perl6
20:52 cj joined perl6
20:52 masak joined perl6
20:52 polettix joined perl6
20:52 svnbot6 r15770 | fglock++ | v6.pm - ChangeLog update
20:56 devogon joined perl6
21:01 diotalevi joined perl6
21:01 Limbic_Region joined perl6
21:06 fglock joined perl6
21:06 fglock @tell clkao please sanity check r15766 (Sub::Multi); maybe upload to cpan?
21:06 lambdabot Consider it noted.
21:07 fglock home &
21:09 Psyche^ joined perl6
21:21 Psyche^ is now known as Patterner
21:25 [particle] smash: compilers\imcc\imclexer.c(4357) : warning C4018: '<' : signed/unsigned mismatch
21:25 [particle] compilers\imcc\imcc.l(666) : warning C4090: 'function' : different 'const' quali
21:25 [particle] fiers
21:26 the_dormant joined perl6
21:32 rod1 joined perl6
21:35 BooK joined perl6
21:39 weinig|bbl is now known as weinig
21:48 autark joined perl6
21:53 Loro changes topic to: ?
21:56 Kinbote would anyone happen to know where the "official" parrot channel is? nobody's on #parrot.
21:57 Loro changes topic to: tuna is gay.
21:57 justatheory joined perl6
21:57 Limbic_Region ircc.perl.org
21:57 Limbic_Region er
21:57 Limbic_Region irc.perl.org
21:58 Limbic_Region Kinbote - and if that was as clear as mud.  The channel is #parrot but the network is irc.perl.org (not freenode)
22:04 avar Man, I should peek at the regex plugins now:)
22:04 avar <- been lazy
22:05 Kinbote thanks
22:07 gaal Kinbote: it's in Zembla :-p
22:12 Aankhen`` joined perl6
22:18 malpertuis joined perl6
22:23 gaal changes topic to: http://pugscode.org | http://sial.org/pbot/perl6 | ?eval "m" ~ "oo" ~ "se" | > reverse (show (scanl (*) 1 [1..] !! 4))
22:28 malpertuis left perl6
22:30 malpertuis joined perl6
22:30 malpertuis left perl6
22:45 meppl good night
22:50 moshik joined perl6
22:54 ruoso joined perl6
22:56 mathlord is now known as mathlord[sleepin
22:56 mathlord[sleepin is now known as math[sleeping]
23:02 TimToady_ joined perl6
23:11 avar .
23:14 gnuvince_ joined perl6
23:14 gnuvince_ ?eval reverse (show (scanl (*) 1 [1..] !! 4))
23:14 evalbot_r15765 is now known as evalbot_r15770
23:14 evalbot_r15770 Error: ␤Unexpected "1"␤expecting operator, ":", "," or ")"
23:15 moritz gnuvince_: try @eval ;-)
23:15 gnuvince_ @eval reverse (show (scanl (*) 1 [1..] !! 4))
23:15 gnuvince_ Did I kill Larry Wall?
23:15 moritz @help
23:15 lambdabot help <command>. Ask for help for <command>. Try 'list' for all commands
23:15 moritz @help eval
23:15 lambdabot eval. Do nothing (perversely)
23:16 moritz @help list
23:16 lambdabot list [module|command]
23:16 lambdabot show all commands or command for [module]. http://www.cse.unsw.edu.au/~dons/lambdabot/COMMANDS
23:16 geoffb TimToady_ appeared a bit ago (note trailing underscore), I think he must have just had timeout issues.
23:16 [particle] larry's not dead, he's just reached his recursion limit
23:22 diakopter joined perl6
23:33 diakopter joined perl6
23:35 explorer joined perl6
23:45 jferrero joined perl6
23:50 explorer joined perl6
23:57 TimToady_ is now known as TimToady

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

Perl 6 | Reference Documentation | Rakudo