Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2007-10-23

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:00 dlocaus & dog walk
00:00 dlocaus left #perl6
00:05 theorbtwo joined #perl6
00:46 araujo joined #perl6
00:46 vbattsAtWork joined #perl6
00:52 bsb joined #perl6
00:54 [particle1 joined #perl6
00:56 kanru joined #perl6
01:00 nekokak_ left #perl6
01:07 awwaiid joined #perl6
01:12 Jamtech joined #perl6
01:14 r0bby joined #perl6
01:17 lyokato joined #perl6
01:48 cognominal_ joined #perl6
01:49 vel joined #perl6
01:56 amnesiac joined #perl6
02:05 [particle] joined #perl6
02:19 weinig joined #perl6
02:43 justatheory joined #perl6
02:53 diotalevi joined #perl6
03:46 Caelum joined #perl6
04:01 IllvilJa joined #perl6
04:11 justatheory joined #perl6
04:33 jiing joined #perl6
05:00 Ashizawa joined #perl6
05:04 ofer joined #perl6
05:27 devogon joined #perl6
05:28 jisom joined #perl6
05:28 SubSyn joined #perl6
06:29 drrho joined #perl6
06:33 SubSyn left #perl6
06:40 pugs_svn r18576 | agentz++ | PCR - tracer now works in the console (mostly)
06:43 agentzh to run the current tracer, try out the following commands:
06:43 agentzh $ util/compile_p6grammar.pl -D examples/adder.grammar > Adder.pm
06:43 agentzh $ perl -Ilib -MAdder -e 'print Adder->add("3 + 23")->(), "\n"'
06:43 moritz_ agentzh: is PCR updated to the "new" regex syntax already?
06:43 agentzh moritz_: nope
06:44 agentzh moritz_: (afaik)
06:48 agentzh yay! examples/digits.grammar works with the tracer as well
06:48 agentzh currently the tracer outputs are not human-readable...
06:49 agentzh should be fed into another renderer
06:49 agentzh >>BEGIN concat<< 248..270 at 5
06:49 agentzh >>BEGIN group<< 248..252 at 5
06:50 agentzh 248..270 is the positional range in the original .grammar file
06:50 agentzh while "at 5" is the current parsing focus in the input string
06:50 agentzh "concat" and "group" are both regex AST node names
06:51 Casan joined #perl6
06:51 moritz_ agentzh: as a proof of concept you could write a regex syntax hilighter based on that output ;)
06:52 agentzh moritz_: that's what i'm currently working on ;)
06:52 moritz_ agentzh: ok ;)
07:01 faxathisia joined #perl6
07:29 Aankhen`` joined #perl6
07:29 iblechbot joined #perl6
07:31 elmex joined #perl6
07:43 franck___ joined #perl6
08:14 ruoso considering everything must be able to stringify, would it be sane to implement the hash lookup based on the stringification of the object? It must be noted that this doesn't mean storing the string as the key, but only using it in the needed copmarisions inside the hash implementation...
08:14 Aankh|Clone joined #perl6
08:19 moritz_ that's what perl5 does, right?
08:20 fglock joined #perl6
08:21 Aankh|Clone Yes.
08:21 Aankh|Clone Wait, what?
08:21 Aankh|Clone :-P
08:24 fglock ruoso: I'd use the object id instead
08:24 moritz_ is that backend specific?
08:26 ruoso the object id wouldn't work for strings
08:26 ruoso because different objects with the same value must match the same key
08:26 ruoso moritz_, p5 stores the stringification
08:26 pugs_svn r18577 | fglock++ | [kp6-perl5] allow mixed positional and named arguments
08:26 ruoso I'm only using the stringification to comparisions
08:26 ruoso not storing it
08:27 moritz_ ruoso: so use stringification for low-level values (Str, Num...) and ID for other objects?
08:28 ruoso hmm... this would complicate things...
08:28 ruoso because I would need to test if it is a low-level value or not
08:28 fglock kp6: sub x ($a,$b){ print " $a-$b, " }; x(1,2); x( a=>3, b=>4 ); x( b=>6, a=>5 );
08:28 exp_evalbot r18577: OUTPUT[ 1-2,  3-4,  5-6, ]
08:28 moritz_ but hash keys need to be immutable, right?
08:29 ruoso moritz_, why?
08:29 moritz_ ruoso: in order to allow efficient lookup
08:29 ruoso ah.. ok
08:29 ruoso yeah..
08:29 moritz_ that's what the "hash" part of a hash is all about ;)
08:29 ruoso heh
08:30 moritz_ so perhaps stringification isn't all that bad
08:31 moritz_ there was a reason for the way it was done in p5
08:32 ruoso yep... but the problem is... this may end up with bad behaviour...
08:32 ruoso for objects that does have stringifications
08:32 ruoso that aren't unique when they should be
08:33 moritz_ ruoso: that's a trade off between efficiency and usability
08:33 ruoso maybe a "hashcode" thing is needed
08:33 moritz_ ruoso: thou shalt not write object that stringify identically ;)
08:33 ruoso heh
08:34 moritz_ and take hashcode if available, otherwise stringification?
08:34 ruoso having to test that is a bad thing
08:34 ruoso better to have mandatory "hashcode"
08:35 ruoso the default implementation may be the stringification
08:35 moritz_ that makes sense
08:37 ruoso but hashcode must always be a string...
08:40 fglock ruoso: I don't think $dog1 and $dog2 must hash to the same thing, only Constants do
08:41 ruoso fglock, if $dog1 = "foo"; and $dog2 = "foo"... yes, they do....
08:41 ruoso if $dog1 = "123" and $dog2 = 123... hmmm... I think they should do...
08:41 masak joined #perl6
08:42 * moritz_ agrees
08:42 ruoso if class Dog has only the memeber "name", and the hashcode is its name
08:42 ruoso $dog1 with name "Rex" and $dog2 with name "Rex" should do also...
08:42 ruoso other way you can't reproduce the key...
08:42 moritz_ ruoso: I don't think you can enforce that in the general case
08:43 ruoso if that's the last reference you have
08:43 ruoso moritz_, if the hashcode returns the name, yes...
08:43 moritz_ ruoso: so use .perl instead of .hashcode
08:43 moritz_ ruoso: right, but you can't be sure that the dumb perl author makes that right
08:44 ruoso moritz_, that way the objects won't match
08:44 ruoso that's normal
08:44 ruoso the default hashcode for an object is it's id
08:44 ruoso ok
08:44 ruoso that solves the problem
08:44 moritz_ um, why not?
08:44 ruoso the point is, you must have a way to make two objects match
08:45 Aankh|Clone Why?
08:45 ruoso and this is using the hashcode methods
08:45 Aankh|Clone Er, two arbitrary objects or...?
08:45 moritz_ ruoso: so if you have two Dog objects, that have identical content, they won't match if you use ID
08:45 moritz_ ruoso: do you want that?
08:45 ruoso yep... that would be the default
08:45 moritz_ ok
08:46 ruoso so...
08:46 moritz_ and for strings you just return self?
08:46 moritz_ in .hashcode, I mean
08:46 ruoso the basic values default for hashcode is the stringification
08:46 ruoso objects return the id
08:46 ruoso (stringified id for that matter...)
08:46 Aankh|Clone <moritz_> ruoso: so if you have two Dog objects, that have identical content, they won't match if you use ID # isn't that the required behaviour for a hash table?
08:47 ruoso Aankh|Clone, the problem is to know whether the objects must or must not match
08:47 moritz_ kp6: class Foo { has $.bar }; my $a = Foo.new(bar => 'baz'); say "$a";
08:47 exp_evalbot r18577: OUTPUT[::Foo(...)␤]
08:47 ruoso and that's the pourpose of the hashcode method
08:47 Aankh|Clone ruoso: I'm not following you.
08:47 ruoso that should be at the control of the programmer
08:47 Aankh|Clone Mmm.
08:47 moritz_ and the default should be not to match
08:47 ruoso think about a XML DOM node
08:48 ruoso yep
08:48 moritz_ ok, then the stringification of an ID is a sensible default
08:48 ruoso you probably want a XML DOM node to match based in it's name and attributes
08:48 ruoso moritz_, yep.. like Foo(0x123123123)
08:48 ruoso :)
08:48 moritz_ ruoso: but the current stringification doesn't include the ID - are you going to change that?
08:49 ruoso nope...
08:49 moritz_ ok
08:49 ruoso i'm changing that: for objects, the hashcode returns a stringified id
08:49 ruoso probably with the tag like p5 does
08:50 ruoso so $dog1 would stringify to Dog=0x123123123
08:50 moritz_ you can add a 'class hashcode', so .hashcode is a natural typecasting method
08:50 ruoso s/stringify/hashcode/
08:50 moritz_ and in that class you can implement the hash algorithm
08:50 moritz_ and it inherits from Str or str
08:50 moritz_ Str, that is ;)
08:51 moritz_ or is that an abuse of the coercion/type casting sytem?
08:52 ruoso maybe not...
08:52 ruoso I don't know yet
08:52 ruoso I'm thinking in the low-level yet...
08:52 ruoso low-level doesn't have type casting system yet
08:52 ruoso (for low-level, I refer yap6)
08:55 ruoso I should probably wait for TimToady's opinion on that, before taking any decision...
08:56 * moritz_ looks at the back door
09:00 pugs_svn r18578 | fglock++ | [kp6] Roadmap: added Milestone 5.1 - Upgrade the regex engine to the current specification
09:01 moritz_ html version of the roadmap updated
09:04 moritz_ fglock: the status for gather/take should be updated as well
09:06 Aankh|Clone <ruoso> you probably want a XML DOM node to match based in it's name and attributes # I'm not so sure about that.
09:06 ruoso Aankh|Clone, just an example...
09:06 Aankh|Clone <top><one foo="bar"/><two><one foo="bar"/></two></top>
09:07 Aankh|Clone That way, the <one foo="bar"/> within <top> and <one foo="bar"/> within <two> would match.
09:07 ruoso no, because the parentNode would be different
09:07 Aankh|Clone Ah, so not just attributes then.
09:07 Aankh|Clone Not just XML attributes, that is. :-)
09:08 ruoso yep..
09:08 pugs_svn r18579 | moritz++ | [kp6] roadmap: updated gather/take and threads section
09:08 moritz_ fglock: please take a look at this commit, not sure I made it rigth
09:08 moritz_ s/th$/ht/
09:12 pmurias joined #perl6
09:12 rafl joined #perl6
09:12 pmurias_ joined #perl6
09:14 pmurias_ @tell ruoso re hashing: S02:571-573
09:14 lambdabot Consider it noted.
09:15 moritz_ ok, so .WHICH is roughly the same as the intended .hashcode
09:16 * masak is still very bad at keeping the different .WHO, .WHAT and .WHICH methods apart
09:17 Aankhen`` Yay.
09:17 moritz_ pugs: say "foo".WHAT
09:17 exp_evalbot OUTPUT[Str␤]
09:17 Aankhen`` So WHICH is not a macro?
09:17 Aankhen`` Just a regular method?
09:17 moritz_ pugs: say "foo".WHO
09:17 exp_evalbot OUTPUT[*** No such method in class Str: "&WHO"␤    at /tmp/nUduFpqUy3 line 1, column 5 - line 2, column 1␤]
09:17 moritz_ Aankhen``: why should it be a macro?
09:17 moritz_ masak: there seems to be no .WHO method, and .WHAT returns the meta-object
09:18 Aankhen`` I didn't say it should, I was confirming that it isn't a macro, unlike one of the other all-uppercase method thingies...
09:18 Aankhen`` s/should/should be/
09:19 Aankhen`` S12 says that it is a macro, though.
09:19 fglock moritz_:  looks good, thanks
09:19 Aankhen`` http://perlcabal.org/syn/S12.html#Introspection
09:19 lambdabot Title: S12
09:19 moritz_ ok, whatever ;)
09:19 Aankhen`` "These are all actually macros, not true operators or methods."
09:19 moritz_ Aankhen``: does it make a difference?
09:19 Aankhen`` So if .WHICH is a macro, how does a class define that its own WHICH method is called instead? :-S
09:19 ruoso moritz_, yep... WHICH is hashcode
09:19 lambdabot ruoso: You have 1 new message. '/msg lambdabot @messages' to read it.
09:20 Aankhen`` Then you'd have to use .'WHICH' or ."WHICH" or something everywhere to allow for custom methods.
09:20 Aankhen`` Unless the macro automatically calls that method!  Yay.
09:21 * moritz_ still doesn't grok macros at all
09:21 moritz_ is there a _gentle_ introduction somewhere? no lisp please ;)
09:21 Aankhen`` Why?  Macros take an AST and transform it into another AST.
09:21 Aankhen`` Awww, what's wrong with Lisp?
09:21 moritz_ Aankhen``: the syntax
09:21 Aankhen`` Common Lisp macros are the easiest thing to understand.
09:22 Aankhen`` Bigot. :-P
09:22 moritz_ they just view an AST like a nested list, right?
09:22 ruoso moritz_, now... if you have problems understanding macros... you'll realise why lisp is so hard ;)
09:22 Aankhen`` moritz_: A list in Lisp is actually just a tree, so the answer is "sort of".
09:22 Aankhen`` ruoso: What's hard about Lisp?
09:23 moritz_ ruoso: I never really tried, I have to admit ;)
09:23 Aankhen`` (By which I'm guessing you mean Common Lisp.)
09:23 ruoso heh... everytime I try to customize emacs, i have a headache
09:24 ruoso and quit after two minutes
09:24 Aankhen`` moritz_: Okay, here's one way to look at it: macros are regular functions that run at compile-time; they take an AST and transform it into another AST. That resulting AST is used in the compiled code in place of the call to the macro.
09:24 ruoso :)
09:25 moritz_ Aankhen``: ok, that's nice... how do I access the AST in p6 macros?
09:25 Aankhen`` Some part of the arguments passed.
09:26 Aankhen`` I'm not sure how exactly, though.
09:27 moritz_ hm, ok
09:27 Aankhen`` Here we go: "In the absence of a signature to the contrary, a macro is called as if it were a method on the current match object returned from the grammar rule being reduced; that is, all the current parse information is available by treating self as if it were a $/ object."
09:27 moritz_ ok
09:28 moritz_ so basically you have to know the parser's internals to fiddle with macros
09:28 Aankhen`` Not the parser's internals, really.  But you do have to be familiar with the grammar, at least the part that you're transforming from and the part that you're transforming to.
09:29 ruoso but there are also the quasiquotes
09:29 ruoso which help with that
09:29 jql it's a beautiful design tactic, though
09:29 ruoso you may use quasiquotes to expand the macro
09:29 ruoso then you don't need to know about the ast at all
09:30 Aankhen`` ruoso: Yes.
09:30 Aankhen`` jql: What is?
09:30 * moritz_ waits with grokking macros until somebody write a tutorial with many examples
09:30 jql the macro works by manipulating whatever "is supposed to be" in $/
09:30 jql whatever that is. :)
09:30 Aankhen`` Heh/
09:30 Aankhen`` Heh.
09:30 chris2 joined #perl6
09:32 chris2 joined #perl6
09:42 pugs_svn r18580 | fglock++ | [kp6] move Visitor::Perl to Visitor::Emit::AstPerl
09:45 xinming joined #perl6
09:52 pugs_svn r18581 | fglock++ | [kp6] script/kp6 - add options -Cperl5rx and -Bperl5rx
09:58 pugs_svn r18582 | fglock++ | [kp6-perl5rx] s/.str/.Str/
10:02 pugs_svn r18583 | fglock++ | [kp6-perl5rx] fixed lib search order
10:03 moritz_ fglock: are you working quasi-fulltime on kp6 today? ;-)
10:03 fglock yes :)
10:04 moritz_ $flocks_employer++ ;-)
10:04 fglock (I had a meeting, but it was moved to tomorrow)
10:06 fglock actually, I'm also working on the $work business plan for Perl 6
10:18 pugs_svn r18584 | fglock++ | [kp6-perl5rx] s/bool/true/ ; token execution returns the Match object
10:25 pugs_svn r18585 | fglock++ | [kp6-perl5rx] started Perl 6-5 bridge; t/kp6/grammar/01-simple-or-token.t passes
10:27 agentzh fglock: take a look at this: http://agentzh.org/misc/tracer/main.html
10:27 lambdabot Title: Test
10:27 agentzh the tracer is working (mostly) now :)
10:28 fglock agentzh++ x 1e9
10:28 agentzh :D
10:28 agentzh thanks :)
10:28 fglock cool
10:29 agentzh the tracer adds ~0 runtime cost to compilers w/o the -D option :)
10:30 agentzh i'm expecting to add this to kp6 ;)
10:34 pugs_svn r18586 | fglock++ | [kp6-perl5rx] properly escapes space ; t/kp6/grammar/02-non-capturing-group.t passes
10:35 fglock agentzh: take a look at: $ perl script/kp6 -Cperl5rx t/kp6/grammar/02-non-capturing-group.t
10:35 fglock it compiles Perl 6 regex into Perl 5 regex
10:36 agentzh fglock: looking
10:37 agentzh heh, very interesting p5 code :)
10:38 agentzh i think i'll be able to add hooks into the code blocks :)
10:39 pugs_svn r18587 | fglock++ | [kp6-perl5rx] t/kp6/grammar/03-ident-token-from-grammar.t - fixed syntax ; passes
10:41 fglock agentzh: it reuses the p5 backtracking, it should be much faster than the code in PCR
10:43 pugs_svn r18588 | fglock++ | [kp6-perl5rx] t/kp6/grammar/04-not-before-subrule.t - fixed syntax; passes
10:44 dmq joined #perl6
10:49 reZo joined #perl6
10:52 pugs_svn r18589 | fglock++ | [kp6-perl5rx] t/kp6/grammar/05-code-inside-rule.t passes
10:55 agentzh fglock: thanks for the info :)
10:57 fglock agentzh: I mean to replace the engine in PCR with the KP6 engine, but KP6 still needs some more features
10:58 agentzh fglock: is the AST stay the same?
10:58 agentzh *does
10:58 fglock KP6 uses an OO ast, but it's mostly the same
10:58 agentzh hmm
10:59 agentzh is there any PCR component that is reusable?
10:59 agentzh or have i rewrite everything in PCR using kp6's code?
10:59 agentzh *do i have to
11:00 fglock PCR compilers are plugged-in, so it's mostly just writing a wrapper, I guess
11:00 agentzh cool
11:00 agentzh super &
11:00 Kattana that tracer is awesome
11:01 agentzh Kattana: thanks :)
11:01 agentzh Kattana: but it does not run in IE...sadly
11:01 ruoso (agentzh++) for 1..Inf;
11:01 agentzh ruoso: :D
11:01 ruoso the tracer is really awesome
11:01 fglock agentzh: to see the AST: $ perl script/kp6 -Cast t/kp6/grammar/06-P5-modifier.t
11:01 agentzh that's what i had in mind months ago ;)
11:02 agentzh and that was why i hacked on PCR madly this summer ;)
11:02 agentzh fglock: thanks for the info :)
11:02 fglock agentzh++ mad hacker
11:02 agentzh :)
11:03 agentzh sorry, gotta run for supper now &
11:06 [particle] joined #perl6
11:12 pugs_svn r18590 | fglock++ | [kp6-perl5rx] initial support for :Perl5 modifier; t/kp6/grammar/06-P5-modifier.t passes 2, fails 2 tests
11:20 drrho joined #perl6
11:24 fglock perl5rx tests 07-10 pass; test 11 = "panic: top_env"
11:25 iblechbot joined #perl6
11:27 pugs_svn r18591 | fglock++ | [kp6-perl5rx] fixed tests 13, 16
11:29 faxathisia joined #Perl6
11:42 pugs_svn r18592 | fglock++ | [kp6-perl5rx] added script/run_tests_kp6_mp6_perl5rx.pl
11:43 pugs_svn r18593 | fglock++ | [kp6-perl5rx] t/kp6/grammar/11-to-line-end.t passes
11:52 pugs_svn r18594 | fglock++ | [kp6-perl5rx] t/kp6/grammar/17-complex-return.t passes
11:59 rindolf joined #perl6
12:05 pugs_svn r18595 | fglock++ | [kp6-perl5rx] code cleanup
12:27 integral is perl5rx generating 5.10 regexps, perhaps taking advantage of all its new features?
12:37 mr_ank joined #perl6
12:48 dalecooper joined #perl6
13:01 dmq joined #perl6
13:06 funktio joined #perl6
13:06 moritz_ integral: afaict it generates 5.8 regexes
13:07 jhorwitz joined #perl6
13:30 cmarcelo joined #perl6
13:31 integral ah.
13:33 fglock joined #perl6
13:35 fglock integral: it will use 5.10 features as-needed, but it's 5.8 compatible so far
13:35 integral okay
13:46 vbattsAtWork joined #perl6
13:52 pugs_svn r18596 | fglock++ | [kp6-perl5rx] fixed t/kp6/grammar/06-P5-modifier.t
13:52 TJCRI joined #perl6
14:09 pugs_svn r18597 | fglock++ | [kp6-perl5rx] t/kp6/grammar/06-P5-modifier.t passes
14:20 pugs_svn r18598 | fglock++ | [kp6-perl5rx] t/kp6/grammar/12-non-return-block.t passes
14:40 toshinori joined #perl6
14:43 pugs_svn r18599 | moritz++ | [kp6] make forcerecompile
14:53 pugs_svn r18600 | fglock++ | [kp6-perl5rx] fixed t/kp6/grammar/15-capture-from-rule-block.t
14:56 c9s_ joined #perl6
14:56 pugs_svn r18601 | fglock++ | [kp6-perl5rx] all grammar tests pass
14:58 moritz_ confirmed ;)
14:59 moritz_ which means that perl5rx is now in better shape than pure perl5
14:59 fglock now let's take a look at the other tests
15:02 pugs_svn r18602 | fglock++ | [kp6-perl5rx] add ShortCircuit processor
15:04 TJCRI joined #perl6
15:05 pugs_svn r18603 | fglock++ | [kp6] fixed t/kp6/42-single-rule-grammar.t
15:06 moritz_ kp6: say( defined(undef) ?? "yes" !! "no" );
15:06 exp_evalbot r18603: OUTPUT[no␤]
15:06 moritz_ kp6: say( defined(0) ?? "yes" !! "no" );
15:06 exp_evalbot r18603: OUTPUT[yes␤]
15:07 moritz_ kp6: my %a; %a{ 'a' } = 1; say(defined(%a.keys));
15:07 exp_evalbot r18603: OUTPUT[1␤]
15:08 moritz_ kp6: my %a; %a{ 'a' } = 1; my $h = %a.keys; say( defined($h)  ?? "yes" !! "no")
15:08 exp_evalbot r18603: OUTPUT[yes␤]
15:08 moritz_ kp6: my %a; %a = { a => 1, }; my $h = %a.keys; say( defined($h)  ?? "yes" !! "no")
15:08 exp_evalbot r18603: OUTPUT[yes␤]
15:09 fglock moritz_: what are you looking for?
15:10 fglock ah - failing tests
15:11 pasteling "moritz_" at 89.12.253.20 pasted "kp6: 40-hash-keys" (5 lines, 99B) at http://sial.org/pbot/28185
15:11 moritz_ this paste prints "no"
15:11 moritz_ but it is esentially the same as what I just tried with evalbot
15:11 drrho left #perl6
15:16 fglock hmm - I think I found it
15:17 c9s__ joined #perl6
15:24 fridim joined #perl6
15:24 demq joined #perl6
15:25 fridim joined #perl6
15:26 moritz joined #perl6
15:28 rindolf joined #perl6
15:31 moritz_ irc logs (and logging bot) will go down shortly, but I expect them to be up really soon[tm] (less than 20min)
16:23 test joined #perl6
16:23 Topic for #perl6is now http://pugscode.org/ | nopaste: http://sial.org/pbot/perl6 | ?eval [~] <m oo se> | We do Haskell, too | > reverse . show $ foldl1 (*) [1..4] | irclog: http://irc.pugscode.org/
16:23 Topic for #perl6is now http://pugscode.org/ | nopaste: http://sial.org/pbot/perl6 | ?eval [~] <m oo se> | We do Haskell, too | > reverse . show $ foldl1 (*) [1..4] | irclog: http://irc.pugscode.org/
16:23 fglock sorry, I mean: echo 123 | perl script/kp6 -Bparrot
16:23 fglock I was playing with another backend here
16:24 dlocaus humm.. I got something that looks like a macro language.
16:24 justatheory joined #perl6
16:25 fglock yes, that's Parrot "pir"
16:25 moritz_ joined #perl6
16:25 moritz left #perl6
16:26 * Tene was tracking the pugs repository via git-svn for a while... that's on my currently-dead laptop, though.
16:26 dlocaus fglock: If this is where help is needed, I'm willing to put effort into it.
16:27 fglock dlocaus: there seems to be many people willing to help with the Parrot backend,
16:28 fglock it's not difficult to get help on Parrot, either here or in the #parrot irc
16:28 moritz_ #parrot is on irc.perl.org btw
16:30 fglock dlocaus: you can find out about the emitters at src/KindaPerl6/Visitor/Emit/
16:30 fglock the file structure is about the same for each backend
16:30 dlocaus fglock: ok.
16:30 spinclad kp6: sub f($a,$b){ "$a:$b" }; f(a=>1,2)
16:30 exp_evalbot r18606: OUTPUT['2:'␤]
16:30 spinclad kp6: sub f($a,$b){ "$a:$b" }; f(b=>1,2)
16:31 exp_evalbot r18606: OUTPUT['2:1'␤]
16:31 fglock spinclad: fixing
16:32 spinclad kp6: sub f($a,$b){ "$a:$b" }; f(1,a=>2)
16:32 exp_evalbot r18606: OUTPUT['1:'␤]
16:32 spinclad kp6: sub f($a,$b){ "$a:$b" }; f(1,b=>2)
16:32 exp_evalbot r18606: OUTPUT['1:2'␤]
16:33 spinclad C<f(1,a=>2)> should perhaps complain, like f(a=>1,a=>2)
16:34 spinclad kp6: sub f($a,$b){ "$a:$b" }; f(a=>1,a=>2)
16:34 exp_evalbot r18606: OUTPUT['2:'␤]
16:35 fglock spinclad: fixed it here, but svn is currently down
16:35 fglock I could paste the diff
16:36 spinclad let me check the spec tho; (if :namedargs and positionalargs are split into two streams first, their order between streams could be lost.  Spec might disallow this...)
16:44 araujo joined #perl6
16:46 dlocaus & food.
16:48 cathya joined #perl6
16:48 fglock & decommute
16:57 dalek joined #perl6
16:57 pasteling "pugsbot_r17185" at 193.200.132.135 pasted "Pugs build failure" (6 lines, 278B) at http://sial.org/pbot/28189
16:57 pugsbot_r17185 joined #perl6
16:58 pugs_svnbot joined #perl6
16:58 moritz_ YaY, svn is back
16:58 moritz_ Juerd++
16:59 pugs_svn r18607 | dlo++ | Made minor changes to the warning for using nmake (MSWin32).
16:59 pugs_svnbot r18607 | dlo++ | Made minor changes to the warning for using nmake (MSWin32).
16:59 pugs_svnbot diff: http://dev.pugscode.org/changeset/18607
16:59 lambdabot Title: Changeset 18607 - Pugs - Trac
16:59 pugs_svn r18608 | moritz++ | [irclog] start transition to extensive use of mod_rewrite
17:00 Juerd joined #perl6
17:00 pugs_svnbot r18608 | moritz++ | [irclog] start transition to extensive use of mod_rewrite
17:00 pugs_svnbot diff: http://dev.pugscode.org/changeset/18608
17:01 lambdabot Title: Changeset 18608 - Pugs - Trac
17:01 Juerd Bad news: I have no idea what is wrong
17:01 spinclad :(
17:01 Juerd It has to do with LVM snapshots, which are used for the daily backups.
17:01 Juerd There have not been correct backups the past few days.
17:01 blindfish joined #perl6
17:01 Juerd If you like to panic, now would be a good time.
17:02 spinclad any indications of hardware/software issue?
17:02 Juerd spinclad: It must be software, because the snapshots don't use different hardware than the normal volumes.
17:04 rindolf joined #perl6
17:06 knewt joined #perl6
17:08 barney joined #perl6
17:09 pmurias joined #perl6
17:10 spinclad kp6: sub f($a,$b){ "$a:$b" }; f(a=>1,2)
17:10 exp_evalbot r18608: OUTPUT['2:'␤]
17:10 TimToady I'd guess the snapshot mechanism is spinning trying to acquire a lock it can't get.
17:11 Juerd Well, it does work, but incredibly slow
17:11 Juerd 2 megabytes per second datatransfer on the snapshot
17:12 Juerd And I have no idea how to debug a kernel :)
17:12 TimToady are you backing the LVMs serially or concurrently?
17:13 Juerd I'm not sure what you mean
17:13 TimToady maybe they're fighting...
17:13 TimToady is there more than one LVM that you're backing up?
17:13 Juerd There's one big VG, that's on one big PV, which is one big MD raid array
17:13 Juerd No, just one.
17:13 TimToady nevermind then
17:14 Juerd It does them sequentially because they're all on the same drives.
17:14 Juerd And it works perfectly on other hosts. It has worked great on feather until the crash recently
17:14 Juerd It probably caused the crash too
17:15 TimToady seems like there's some way it's storing persistent locks that maybe arent GC'd even by a crash
17:15 TimToady like the problems RPM gets sometimes with Berkeley DB locks
17:16 TimToady if any part of the backup system is using BDB, you might have to go in by hand and occasionally blow away the locks by hand
17:17 TimToady let me see if I can dig up a reference
17:19 Juerd There's no Berkely DB involved
17:19 Juerd Just lvm snapshots and tar
17:19 Juerd and gzip, ssh, perl
17:20 dlocaus http://svn.pugscode.org/pugs/v6/v6-K​indaPerl6/src/KindaPerl6/Grammar.pm
17:20 dlocaus on the "token ident {" rule, there is an odd character after the closing '|'.  Is that supposed to be there?
17:20 lambdabot http://tinyurl.com/23kuus
17:21 Psyche^ joined #perl6
17:21 [particle] that's the cent sign, and yes
17:21 [particle] $¢ is valid perl 6
17:21 dlocaus humm, ok.
17:22 spinclad one of the odd bits of utf8 that have crept in
17:23 TimToady Juerd: well, for reference, here's the link anyway: http://rpm.org/hintskinks/repairdb/
17:23 lambdabot Title: Repair an RPM database safely
17:23 [particle] what's a hint skink? is that like a perl monk?
17:23 pmurias dlocaus: it was added because of STD.pm
17:24 TimToady $¢ is supposed to look like deep magic because it is deep magic.
17:24 TimToady it's basically the current match continuation
17:25 pmurias dlocaus: do you know Common Lisp?
17:25 dlocaus I'm reading up on it.  On my monitor/font, I couldn't make out the character.
17:25 TimToady we run this channel in utf8
17:25 dlocaus I studied a little schema about 10 years in college.  But I hated it. (sorry)
17:25 pmurias no problem ;)
17:26 TimToady dlocaus: what locale are you running in?
17:26 TimToady oh, wait, you're on XP
17:26 dlocaus TimToady: I'm running WinXP.
17:26 dlocaus US-English.
17:26 [particle] that's the 'ms-redmond' locale ;)
17:27 TimToady when I'm on win I usually run putty for a terminal, which does support unicode to some extent
17:27 [particle] i use pidgin for im/irc, and it's pretty unicode friendly
17:27 TimToady especially since I run irssi on a different machine under screen
17:27 IllvilJa joined #perl6
17:28 TimToady so I need a remote terminal anyway
17:28 TimToady the nice thing about using screen is you never have to log off the irc channel
17:28 dlocaus I'm playing with the font's on my editor trying to see if I can find a nice "c" cent redering.
17:29 TimToady what do you use for an editor?
17:29 [particle] there's probably a lucida console unicode font variant
17:29 dlocaus UltraEdit.
17:29 TimToady can't help you there; first thing I do is download vim :)
17:30 spinclad TimToady: is there a spec on the order of binding positional and named args to positional parameters?  as in sub f($a,$b) {...}; f(1,:a(2)); f(:a(2),1) ... does the 1 get bound to $b in either case?
17:30 [particle] i usually download firefox first, then vim :)
17:30 dlocaus :), I've been using it for a long time.  I think a lot of keyboard short cuts are now hardwired into my finger muscles.
17:31 spinclad or conversely, bound to $a, and 2 bound to $a as well?
17:32 wolv oh, wow, git-svn cloning the pugs repo takes a while
17:32 spinclad (i saw that :a(1),:a(2) could be bound to @a, but that's something else again)
17:32 allbery_b TimToady++ (you just answered a completley unrelated problem I've been figting with this morning.  unfortunately it seems to be a sleepycat-- db bug)
17:34 spinclad (checked the specs; S06 didn't seem to say)
17:35 TimToady yes, the section on binding has evolved over time as pugs was being developed, and now seems less clear than it used to be.
17:35 integral .oO( git-svn clone it on feather, then rsync the git repo home, wolv )
17:37 TimToady at the moment it seems to say that binding order is controlled by the call's arguments rather than the formal parameter's order, but that seems wrongish to me; maybe that sentence was trying to say something else.
17:39 TimToady my mental model is that you march through the formals left to right finding either a named binding or the next position if there's no named binding.
17:39 TimToady *positional
17:39 wolv integral: not a bad idea :)
17:39 Juerd TimToady: Thanks for the link
17:39 integral git++ # rsync and plain-ol' http serving
17:39 wolverian joined #perl6
17:40 Juerd TimToady: I have to maintain two RPM-based servers too, so it might come in handy
17:40 TimToady in any case, it's very important that parameter binding not end up O(N**2)
17:41 TimToady pugs: sub f($a,$b){ "$a:$b" }; f(2,a=>1)
17:41 exp_evalbot OUTPUT["1:2"␤]
17:41 spinclad thinking of the arguments translating to a Capture, with its separate @ and % aspects... it seems (to me) that the named args and positional args end up in different streams, with no ordering between them.  then it seems you can only specify @| then %|, or %| then @|, globally for the whole language...
17:41 wolverian what's the path to the pugs repo on feather?
17:42 wolverian if there is a public one, that is.. I just assumed it's on feather for some reason
17:43 spinclad sorry, your 'my mental model' is a third possibility i missed.  good.
17:43 weinig joined #perl6
17:43 wolverian thanks :)
17:44 spinclad (well, that amounts to eat from %| then @|, for each parameter.)
17:45 TimToady part of the reason for using proto subs is to allow mapping of named arguments to positional at compile time so we know the first N args can just be slapped in positionally
17:46 TimToady so you don't pay the % lookup penalty for parameters that the sig is expecting positionally.
17:46 spinclad wolverian: http://svn.pugscode.org/pugs
17:46 lambdabot Title: Revision 18608: /
17:47 spinclad indeed
17:47 Juerd wolverian: http://feather.perl6.nl/svk.html
17:47 lambdabot Title: SVK on Feather
17:48 Juerd I want a way to backup feather1. The only safe way I can currently think of is to suspend the virtual machine and then copy its data
17:48 wolverian well, there's no git-svk I think..
17:48 Juerd Which would suck
17:48 weinig_ joined #perl6
17:48 wolverian so I did git-svn clone file:///... I'm not sure how proper that is :)
17:49 TimToady balancing out flexibility with efficiency while keeping a simple mental model is hard; we were very happy when we came up with the proto sub hack... :)
17:49 TimToady but yes, the specs don't really seem to express it right yet
17:49 wolverian well, getting one revision was quite fast
17:50 spinclad TimToady: this ('my mental model') answers my question then
17:50 cj TimToady: when I mention implementing perl6 on the CLI (.NET), the first response I get is that stack-based virtual machines are not as well-suited for implementing dynamic languages as register-based VMs.  Can you tell me why someone might say that, or where I might read to get some details?
17:50 TimToady another reason that the binding must happen in formal order is that we allow defaults to refer to previous formals
17:50 cj TimToady: there's a lot of support from MS around implementing perl6 on the CLI
17:51 TimToady so I think the sentence in S06 has the terms backwards
17:52 TimToady uh, they must be assuming that they would be targeting the CLI via Parrot, which is regeister based.
17:52 TimToady but there's nothing about the Perl 6 language that requires a register-based VM
17:52 TimToady or a stack-based VM, for that matter
17:59 TimToady a more interesting question is how hard it'll be to at least emulate continuations for purposes of pattern matching and logic programming; and whether that forces Perl 6 to keep its own runloop
17:59 wolverian is irc.pugscode.org working?
17:59 wolverian oh, it is
18:00 wolverian I have a terrible urge to rewrite irclog in catalyst
18:01 TimToady another interesting question is the extent to which we can make their exception model fail-soft in a way that works well will parallel programming
18:02 TimToady you don't want to be unwinding the whole stack merely because one element out of your million element hyperoperation turned out to be undefined....
18:02 [particle] hopefully for .net users, ms will figure that out on their own
18:03 Tene wolverian: port catalyst to Perl 6 first.
18:03 TimToady unwinding the stack should be the last resort, and then only when you already know where you're unwinding it to.
18:04 wolverian Tene, that's even more terrible :)
18:04 wilx joined #perl6
18:04 TimToady another question is on porting to the CLI is whether it can support STM efficiently.
18:05 TimToady wolverian: can't be any harder than porting Perl 6 to Perl 6 first... :)
18:07 wolverian I'll just take a few years off from university..
18:07 wolverian should be done by christmas!
18:10 wolverian hm.. the git svn repo doesn't have any branches, does it?
18:10 wolverian er... s/git/pugs/
18:11 [particle] no branches in pugs repo
18:11 wolverian damn, I was hoping for some cute gitk graphs :)
18:14 Tene wolverian: nah, svn is too fond of linear history for there to be anything interesting.
18:14 wolverian that's so web1.0
18:16 PerlJam joined #perl6
18:17 * Tene gets to use git at work and rather enjoys it.
18:18 jisom joined #perl6
18:20 weinig joined #perl6
18:24 moritz_ ?eval "test"
18:24 pugsbot_r17185 "test"
18:24 theorbtwo joined #perl6
18:24 TimToady ?eval sub f($a,$b){ "$a:$b" }; f(2,a=>1)
18:24 pugsbot_r17185 "1:2"
18:25 bradb joined #perl6
18:25 moritz_ kp6: sub f($a,$b){ "$a:$b" }; f(2,a=>1)
18:25 exp_evalbot r18608: OUTPUT['2:'␤]
18:26 TimToady pugs is correct assuming we keep the priority of % over @
18:27 [particle] can you mix $a and $^a ?
18:27 PerlJam [particle]: mix?  They're the same aren't they?
18:28 [particle] pugs: f($^a, $a, $b){ "$^a:$a:$b"; f(3,2,a=>1)
18:28 exp_evalbot OUTPUT[*** ␤    Unexpected "){"␤    expecting "::"␤    Variable "$b" requires predeclaration or explicit package name␤    at /tmp/SbBeuJaPi5 line 1, column 14␤]
18:29 TimToady currently only bare blocks with no arguments are allowed to use $^a
18:29 [particle] oops
18:29 [particle] pugs: f($^a, $a, $b){ "$^a:$a:$b"}; f(3,2,a=>1)
18:29 exp_evalbot OUTPUT[*** ␤    Unexpected "){"␤    expecting "::"␤    Variable "$b" requires predeclaration or explicit package name␤    at /tmp/ieGFXsHunv line 1, column 14␤]
18:29 [particle] ah, good.
18:31 Jedai joined #perl6
18:34 cj thanks, TimToady!
18:34 cj TimToady: mind if I send your comments to the ms devs?
18:35 BinGOs_ joined #perl6
18:35 [particle] better yet... send the ms devs here :)
18:36 weinig_ joined #perl6
18:37 TimToady cj: I assume anything I say here is public record...
18:39 cj TimToady: roger that
18:40 BinGOs__ joined #perl6
18:41 cerridwen joined #perl6
18:42 shlomif joined #perl6
18:46 cj TimToady: you want to be CC'd?
18:49 TJCRI joined #perl6
18:49 araujo TimToady, be careful then ;-)
18:50 moritz_ araujo: in case you didn't notice: this channel is publicly logged ;)
18:51 moritz_ araujo: nobody with just a tiny bit of sanity will read through all of it, but you never know... ;)
18:52 * Tene reads almost everything in this channel.
18:52 moritz_ Tene: me too. I meant somebody not on the channel ;)
18:53 bilbo1507 Lots of lurkers, too, like myself.  :)
18:54 moritz_ bilbo1507: you lost! now you're not lurking anymore ;)
18:55 bilbo1507 True, true.  But the Evil Empire (whoever you consider that to be) is always lurking :)
18:56 cj why are all of the links broken on this page?
18:56 cj http://m19s28.dyndns.org/iblech/stuff/pugs-s​mokes/pugs-smoke-6.2.13-r18569-linux-normal-​-1193086418-1229--19131-18044-1087-1992-731-​33--fef96421fb0b2f65c1b283a25bbbe6f4.html
18:56 lambdabot Title: TAP Matrix - Mon Oct 22 20:53:14 2007 GMT, http://tinyurl.com/yukavl
19:07 pugs_svnbot r18609 | moritz++ | [irclog]
19:07 pugs_svnbot r18609 | moritz++ |  - moved .htaccess to cgi/
19:07 pugs_svnbot r18609 | moritz++ |  - prepared switiching to different virtual host
19:07 pugs_svnbot diff: http://dev.pugscode.org/changeset/18609
19:07 lambdabot Title: Changeset 18609 - Pugs - Trac
19:21 dlocaus left #perl6
19:21 cmarcelo_ joined #perl6
19:21 rlb3_work_ joined #perl6
19:25 bradb left #perl6
19:31 bkaney joined #perl6
19:38 xinming_ joined #perl6
19:42 bkaney Hi.  Are traits available in pugs 6.2.13?  I am having syntax troubles...
19:46 spinclad 'traits' == roles?
19:47 bkaney Yes. http://dev.perl.org/perl6/doc/design/syn/S12.html (Traits section)
19:47 lambdabot Title: Synopsis 12: Objects - perl6
19:54 spinclad i think full support of roles depends on a new meta-object model for pugs, which has been pending for most of a year now.
19:54 TimToady as used in S12, traits !== roles
19:54 TimToady in fact, we should rename traits to something else, "tweaks" maybe
19:56 TimToady but yes, bare 6.2.13 is a year old now, and you'll have much better luck with the latest revision of pugs
19:56 bkaney Okay.  I did the emerge (gentoo) and that's what I got, although there could be a new ebuild...
19:56 TimToady even though it doesn't have a full MO implementation yet
19:57 TimToady most of us just go straight from the svn repo
19:59 bkaney yea, I'll have to do that and give it a shot and see what happens.  thanks.
20:01 TimToady in any case, as soon as we give you a commit bit, you'll want the fresh version anyway.  :)
20:02 weinig joined #perl6
20:07 TimToady bbl &
20:40 c9s joined #perl6
20:41 cj TimToady: bah.  I'm going to cc you on this email to the .NET devs since you didn't object :)
20:46 marmic joined #perl6
20:53 pugs_svnbot r18610 | moritz++ | [irclog] added more configuration to .htaccess
20:53 pugs_svnbot diff: http://dev.pugscode.org/changeset/18610
20:53 lambdabot Title: Changeset 18610 - Pugs - Trac
20:55 BinGOs_ joined #perl6
21:00 BinGOs joined #perl6
21:00 daxim joined #perl6
21:01 weinig joined #perl6
21:05 pugs_svnbot r18611 | moritz++ | [irclog] added missing (new) index.pl
21:05 pugs_svnbot diff: http://dev.pugscode.org/changeset/18611
21:05 lambdabot Title: Changeset 18611 - Pugs - Trac
21:06 weinig joined #perl6
21:09 justatheory_ joined #perl6
21:17 pugs_svnbot r18612 | moritz++ | [irclog] more .htaccess hacking
21:17 pugs_svnbot diff: http://dev.pugscode.org/changeset/18612
21:17 lambdabot Title: Changeset 18612 - Pugs - Trac
21:20 pugs_svnbot r18613 | moritz++ | [irclog] enable caching of index page
21:20 pugs_svnbot diff: http://dev.pugscode.org/changeset/18613
21:20 lambdabot Title: Changeset 18613 - Pugs - Trac
21:29 pugs_svnbot r18614 | moritz++ | [irclog] more template whacking
21:29 pugs_svnbot diff: http://dev.pugscode.org/changeset/18614
21:29 lambdabot Title: Changeset 18614 - Pugs - Trac
21:30 ST47 joined #perl6
21:40 perlbot joined #perl6
21:41 pugs_svnbot r18615 | moritz++ | [irclog] channel indexes are cached as well
21:41 pugs_svnbot diff: http://dev.pugscode.org/changeset/18615
21:41 lambdabot Title: Changeset 18615 - Pugs - Trac
21:42 perlbot joined #perl6
21:44 pugs_svnbot r18616 | moritz++ | [irclog] don't send xhtml header for channel index (which isn't valid xhtml)
21:44 pugs_svnbot diff: http://dev.pugscode.org/changeset/18616
21:44 lambdabot Title: Changeset 18616 - Pugs - Trac
21:44 perlbot joined #perl6
21:47 moritz_ caching testing sucks if you don't have an easy way to reset the cache ;9
21:47 pugs_svnbot r18617 | moritz++ | [irclog] fixed caching for channel index
21:47 pugs_svnbot diff: http://dev.pugscode.org/changeset/18617
21:47 lambdabot Title: Changeset 18617 - Pugs - Trac
21:48 moritz_ ah, found it ;)
21:48 perlbot joined #perl6
21:53 pugs_svnbot r18618 | moritz++ | [irclog] fixed previous commit. Hopefully.
21:53 pugs_svnbot diff: http://dev.pugscode.org/changeset/18618
21:53 lambdabot Title: Changeset 18618 - Pugs - Trac
22:33 polettix joined #perl6
22:35 Limbic_Region joined #perl6
22:40 mr_ank joined #perl6
22:45 bkaney left #perl6
23:14 lambdabot joined #perl6

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

Perl 6 | Reference Documentation | Rakudo