»ö« | perl6.org/ | nopaste: paste.lisp.org/new/perl6 | evalbot usage: 'perl6: say 3;' or rakudo:, alpha:, pugs:, std:, or /msg p6eval perl6: ... | irclog: irc.pugscode.org/ | UTF-8 is our friend!
Set by lichtkind on 5 March 2010.
lue out of a total of... [ :) ] 00:00
snarkyboojum rakudo is rapidly approaching [enlightenment] :P 00:01
masak reading through rt.perl.org/rt3/Ticket/Display.html?id=64928 again, I have the thought that we're running something of a double standard claiming that the % in %foo means 'Associative' nowadays, but when the parameter %foo? wasn't passed, it's an empty Hash.
or even 'my %foo', I guess.
jnthn Associative is a role, though.
A very minimal one at that.
sorear it's not possible to instantiate Associative 00:02
masak sure it is!
jnthn It's the same with @ and (Positional/Iterable)
sorear Hash is the most basic implementation of Associative
jnthn Well yeah, sure. It'd be useless though.
sorear masak: if it works it's a bug
masak sorear: no, this is: class Empty does Associative {}
sorear masak: that's a semantic error, Associative has required methods
masak sorear: no, there's role->class punning.
sorear: no, it doesn't :)
sorear a role with no required methods can be punned to a class 00:03
what's the implementation of Associative.postcircumfix({ })?
masak good question.
probably not something sensible. 00:04
lue what exactly *is* a role, and why is it useful for something like Temporal? 00:05
masak lue: a role is a way to collect behaviour (methods) into a single OO package. 00:06
sorear masak: let's pester TimToady to remove the implementation and make me right
masak lue: what used to be done with inheritance can sometimes be done more cleanly with a role.
sorear: aye. :)
lue I wish I could find role in the spec :) 00:07
masak rakudo: class A { method foo { say "OH A!" } }; class B { method foo { say "OH B!" } }; class C is A is B {}; C.new.foo 00:08
p6eval rakudo 3469ff: OUTPUT«OH A!␤»
masak lue: that might not be what the author of C intended... 00:09
rakudo: role A { method foo { say "OH A!" } }; role B { method foo { say "OH B!" } }; class C does A does B {}
sorear I see nothing in S32 speccing an implementation for it
p6eval rakudo 3469ff: OUTPUT«Method 'foo' collides and a resolution must be provided by the class␤current instr.: 'perl6;Perl6;Metamodel;RoleToClassApplier;_block132' pc 9109 (src/gen/RoleToClassApplier.pir:306)␤»
masak much better :)
sorear only that one must be provided
lue Perl6: where a failure is better
masak sorear: yes. it's a bit unclear what that mean. 00:10
lue: well, it's the case of failing early to make sure you get it right.
sorear rakudo: say Associative.new{'x'}
masak lue: and if C declares its own .foo to disambiguate, the error goes away.
p6eval rakudo 3469ff: OUTPUT«get_pmc_keyed() not implemented in class ''␤current instr.: 'perl6;Associative[::T];postcircumfix:<{ }>' pc 13832 (src/builtins/Code.pir:85)␤»
masak :)
masak submits rakudobug 00:11
lue so, role is good for the vanilla implementation, to allow people to not be stupid.
masak rakudo: say Positional.new[42]
p6eval rakudo 3469ff: OUTPUT«get_pmc_keyed() not implemented in class ''␤current instr.: 'perl6;Positional[::T];postcircumfix:<[ ]>' pc 10506 (src/metamodel/GrammarHOW.pir:44)␤»
masak lue: roles are a good way to collect behaviour independent of class hierarchies.
because sometimes behaviour isn't concentrated to just a clade in the hierarchy. 00:12
lue So I just use Roles unless there's a need not to :)
masak well... that's an open question :) 00:14
now that we have roles, do we switch to them for everything, or do we stay with classes when there's no obvious reason to switch.
s/\.$/?/
snarkyboojum you can't build role hierarchies can you..
lue why not just a subroutine? 00:15
masak snarkyboojum: a role can do another role.
snarkyboojum so you can compose roles of other roles..
jnthn A role can do many other roles. :-)
snarkyboojum: aye.
masak lue: how do you mean, a subroutine?
snarkyboojum ah k
lue then what is the difference between a sub and a role ?
masak lue: I pose the 'should we use roles for everything?' question at the end of use.perl.org/~masak/journal/40107 , by the way 00:16
lue: a sub is a piece of code. a role is an abstraction, much like a package.
lue: the former can be called. the latter can be used as a type.
lue thank you, now I know :) 00:17
.oO(little did everyone know, this was the day lue destroyed the whole of P6...)
masak I think it's a bit late in the game for that... 00:18
snarkyboojum "Consider using C when you simply want to factor out common code." ho ho ho
masak oh! 00:19
it should say 'roles' there.
masak fixes
snarkyboojum oh ok :)
freudian slip perhaps? :P
lue Oh, I could destroy the whole of P6 the day before Rakudo * using a combination of real and inane logic :)
masak snarkyboojum: well, use.perl.org turned C<roles> into just 'C' :) 00:20
snarkyboojum masak: ah - so a conspiracy! :P
colomon is having the urge to do a blog post singing the praises of the Rakudo team and the Perl 6 design. The [op] patch today really made me happy.
masak snarkyboojum: just because you're paranoid doesn't mean they're not after you! :) 00:21
colomon also has like four hours to get the house ready for the packers, so unlikely to be any happy blogging tonight....
snarkyboojum colomon: then I'll have to post an update on identi.ca about how cool justrakudoit is :P
pugssvn r30282 | masak++ | [S12] removed unnecessary C<> 00:26
masak heading home to make midnight pasta :)
00:26 masak left
jnthn omg I gets midnight pasta made for me! \o/ 00:26
lue is there anyway I can preview the outcome of pod documents? 00:27
jnthn o/
lue (the spec)
snarkyboojum rakudo: class Animal does Pet {}; role Pet { method pat() { say "Lick, lick" } }; 00:29
p6eval rakudo 3469ff: OUTPUT«Null PMC access in type()␤current instr.: 'perl6;Animal;!class_init_11' pc 374 (EVAL_1:167)␤»
snarkyboojum rakudo: class Animal does Pet {...}; role Pet { method pat() { say "Lick, lick" } }; 00:30
p6eval rakudo 3469ff: ( no output )
00:31 niros joined
snarkyboojum rakudo: class Animal does Pet { }; role Pet does Bite { }; role Bite { method bite() { say "ouch" } }; 00:35
p6eval rakudo 3469ff: OUTPUT«Null PMC access in type()␤current instr.: 'perl6;Animal;!class_init_11' pc 390 (EVAL_1:171)␤»
00:36 xabbu42 left
sorear tries to think of a good workaround for non-reentrant p5 hash iterators 00:39
00:40 meppl joined
colomon 30316 tests passing the latest run! \o/ 00:42
snarkyboojum I get fails in my spectest runs :|
colomon in instance.t? 00:43
snarkyboojum yep and others 00:44
colomon I think most of us are getting instance.t issues.
as for the others, what do you get when you do svn info t/spec 00:45
?
in particular, what revision?
snarkyboojum r30250
oops 00:46
sorry r30282
colomon hmmm, actually you're one revision ahead of me. 00:47
snarkyboojum just doing another run
colomon are you at 3469ffe042f2b2f749a163cbdb80289120d06a51 in git?
snarkyboojum yep
colomon then I have no explanation. :) 00:48
snarkyboojum I get failures in S02-literals/fmt-interpolation, S02-literals/char-by-number, S05-mass/rx, S12-methods/instance 00:49
oh well :) will have a look'see
colomon > say ([\*] 1..10).perl 00:50
[1, 2, 6, 24, 120, 720, 5040, 40320, 362880, 3628800]
nice
moritz_++ jnthn++
we don't have =:= yet, do we? 00:52
lue just for reference, is Int a role? 00:53
*defined as* 00:54
colomon no
Int is a type
snarkyboojum would have thought it'd be a class 00:55
colomon Int does the Real and Numeric roles
er, you say class, I say type. :)
it is a class, for sure.
snarkyboojum colomon: aye - you beat me to it (with a more appropriate answer) :)
lue my question is, for something like "my [type] $a = [something]", would [type] be implemented as a role? 00:56
00:56 dual left
colomon It could be a role or a class. 00:56
snarkyboojum rakudo: my $a = 5; my $b = $a; say $a =:= $b 00:57
colomon when you say [type] there, it is a check to make sure the variable is of that type.
p6eval rakudo 3469ff: OUTPUT«0␤»
snarkyboojum rakudo: my $a = 5; my $b := $a; say $a =:= $b
p6eval rakudo 3469ff: OUTPUT«:= binding of variables not yet implemented␤current instr.: '&die' pc 17215 (src/builtins/Junction.pir:399)␤»
snarkyboojum alpha: my $a = 5; my $b := $a; say $a =:= $b
colomon rakudo: my Numeric $a; $a = 1; say $a; $a = "hello"; say $a;
p6eval alpha 30e0ed: OUTPUT«1␤»
rakudo 3469ff: OUTPUT«1␤Type check failed for assignment␤current instr.: '&die' pc 17215 (src/builtins/Junction.pir:399)␤»
snarkyboojum rakudo doesn't complain about =:= being NYI, but it does for binding
where Numeric is a role I suppose 00:59
rakudo: say Num ~~ Numeric 01:00
p6eval rakudo 3469ff: OUTPUT«1␤»
colomon Numeric is the fundamental number role, yes.
snarkyboojum Num and Numeric :S
rakudo: say Num ~~ Int 01:01
p6eval rakudo 3469ff: OUTPUT«0␤»
snarkyboojum rakudo: say Int ~~ Num
p6eval rakudo 3469ff: OUTPUT«1␤»
colomon Num is Perl 6's basic floating point type.
Int is not supposed to be a Num any more, I'll have to fix that.
snarkyboojum yeah, just looking at the names
oh ok
lue afk
snarkyboojum rakudo: say Int ~~ Numeric 01:02
p6eval rakudo 3469ff: OUTPUT«1␤»
snarkyboojum rakudo: say Complex ~~ Numeric
p6eval rakudo 3469ff: OUTPUT«1␤»
snarkyboojum rakudo: say Int ~~ Complex
p6eval rakudo 3469ff: OUTPUT«0␤» 01:03
snarkyboojum rakudo: say Num ~~ Complex
p6eval rakudo 3469ff: OUTPUT«0␤»
snarkyboojum rakudo: say Complex ~~ Num
p6eval rakudo 3469ff: OUTPUT«0␤»
snarkyboojum ok - enough spam from me :)
pugssvn r30283 | colomon++ | [t/spec] Refudge S03-metaops/reduce.t a bit so that it works again.
01:08 jferrero left, dual joined 01:15 ruoso left
dalek kudo: 13a7610 | (Solomon Foster)++ | t/spectest.data:
Turn on S03-metaops/reduce.t.
01:15
pugssvn r30284 | colomon++ | [t/spec] Unfudge another handful of tests in reduce.t. 01:18
01:23 Schwern left
jnthn is in the $*zone 01:23
colomon news.discovery.com/space/big-pic-sp...ebula.html
rakudo: my $a = Bool::True; $a &&= Bool::False; say $a; 01:36
p6eval rakudo 3469ff: OUTPUT«Null PMC access in invoke()␤current instr.: '!assign_metaop' pc 17056 (src/builtins/Junction.pir:319)␤»
01:44 cls_bsd joined 01:55 Psyche^ joined 01:59 Patterner left, Psyche^ is now known as Patterner
dalek kudo: ed9deae | jonathan++ | src/Perl6/Grammar.pm:
Enforce zone constraints in signatures, so we can't end up with requireds after variadics, etc.
02:01
kudo: 16273e1 | jonathan++ | t/spectest.data:
Merge branch 'master' of github.com:rakudo/rakudo
colomon nooooooo....... ;)
jnthn er, do my patches annoy thee? 02:02
;-)
colomon I was halfway through a spectest before pushing my own patch. :) 02:03
jnthn Dom't worry, we've just started bouncing around the "t" word here. 02:04
colomon t ?
jnthn for tired ;-) 02:05
std: sub foo($x:) { }
p6eval std 30284: OUTPUT«ok 00:01 109m␤»
jnthn std: sub foo($x: $y) { }
p6eval std 30284: OUTPUT«ok 00:01 107m␤»
jnthn TimToady: ^ I seem to have memories of STD complaining about those with subs in the past... 02:06
($*INVOCANT_OK)
colomon alpha: say [**] 2, 3, 4 02:07
p6eval alpha 30e0ed: OUTPUT«4096␤»
colomon alpha: say [\**] 2, 3, 4
p6eval alpha 30e0ed: OUTPUT«** (HyperWhatever) is not yet implemented at line 10, near "] 2, 3, 4"␤in Main (file src/gen_setting.pm, line 2582)␤»
jnthn epic fejl!
master ftw.
pugssvn r30285 | jnthn++ | [t/spec] Untodo required after variadic ban test. 02:11
02:11 Chillance left 02:14 gfx joined 02:16 wtgee joined
pugssvn r30286 | jnthn++ | [t/spec] Unfudge two more tests thanks to zone enforcement. 02:17
jnthn Sleep time!
o/ o/
lisppaste3 wtgee pasted "enum in a class" at paste.lisp.org/display/97259 02:18
wtgee What is the proper way to enum some attributes in a class? Mine doesn't seem to work. 02:19
And hello. :) 02:20
colomon I believe that should be has Suit $.suit 02:21
but then, last time I checked named enums weren't working in current Rakudo either. :(
wtgee I tried that but then I get an error about typename Suit needing to be predeclared. 02:22
Ah...That might make sense. The way I had it gives no error but lets me assign anything.
Where is the up-to-date place to check for what is and isn't working?
colomon good question. this page rakudo.org/status is supposed to help, but it's woefully out-of-date, I think. 02:23
wtgee Yes, "has ::Suit $.suit;" gives no error but allows any value, like my original. 02:26
Great, thanks
colomon my apologies for not being more help, I'm off to bed now. 02:30
pugssvn r30287 | colomon++ | [t/spec] Unfudge more reduce tests. 02:31
dalek kudo: e50ff8c | (Solomon Foster)++ | src/core/metaops.pm:
Refactor the reducewith code a tad (could still use more) and extend triangle mode to chaining mode.
colomon probably your best bet for finding what currently works is to try things and ask for help here. Though you're coming up on the time most people are usually in bed or at least inactive on the channel.
good luck!
araujo wonders if he should wait for this insanely macpro book update or go with a thinkpad instead
snarkyboojum araujo: which macpro update? I'm looking at upgrading atm too 02:32
araujo snarkyboojum, the macbook pro line is supposed to be updated *soon* 02:33
snarkyboojum araujo: ah .. the Apple *soon* rumour :)
araujo but it has been like that since Dec last year ... a supposedly update coming soon :P
snarkyboojum i see :) 02:34
I guess they'll get the iPad releases around the world out of the way first
araujo it seems so
snarkyboojum I've thought long and hard about getting a great linux laptop e.g thinkpad, but the macbooks (and pros) are just too lovely :) 02:36
araujo heh, i can understand that .... just don't feel like paying that price when there are more updated machines at the moment ... 02:37
araujo been waiting for around 2 weeks now 02:38
snarkyboojum only 2 weeks? :)
my little black macbook has done me proud.. it's just past 3 years old, and is still compiling rakudo quickly :P
araujo heheh nice 02:39
lue I would not go for a Lenovo Thinkpad. That's how much I don't like the stupid nub-thing :( 02:42
I've never used it, but I *know* I'm going to press it when I don't want to. 02:43
araujo lue, ? 02:45
02:49 rv2733 joined 02:50 the_irrational_1 joined
lue yes? 02:51
snarkyboojum I don't recall every pressing one accidentally 02:52
:)
lue I just don't need it, and it bugs me it's right where I *could* press it. 02:54
It's supposed to be a second mouse, or something. I actually don't know what it is for, but I'm certain it doesn't need to be right in home row :) 02:56
snarkyboojum yeah.. mouse pointer thingy 02:57
never bothered to get used to it
lue It's only a button, so I'm assuming it's for if you're too lazy to tap the trackpad or the mouse button :) 02:59
wtgee My dell latitude has one and up until kernel 2.6.32 the drivers have been really, really screwed up.
lue It's already hard enough sometimes not to press the trackpad on accident (esp. considering how wide they get, I'm glad I have an old laptop).
(have you seen how wide the trackpads are on the newest Macbooks? It's ridiculous! You could be reaching for the ESC key and hit the trackpad on accident!) 03:03
snarkyboojum there has to be a gesture on the trackpad for escape right? :P 03:04
wtgee How can I specify a lib dir? Like "use lib 'lib/'" in perl5 03:05
lue snarky: start in the top-right, move left, down, right, left, down, right
std: use lib 'lib/' 03:06
p6eval std 30287: OUTPUT«ok 00:01 123m ./lib/lib.pm␤ok 00:01 108m␤»
lue rakudo: use lib 'lib/'
p6eval rakudo e50ff8: OUTPUT«Unable to find module 'lib'.␤current instr.: 'perl6;Perl6;Module;Loader;need' pc 34543 (src/gen/role_pm.pir:0)␤»
lue not yet implemented :(
lue submits rakudobug
snarkyboojum rakudo: say @*INC.pelr 03:08
p6eval rakudo e50ff8: OUTPUT«Method 'pelr' not found for invocant of class 'Array'␤current instr.: '_block14' pc 29 (EVAL_1:0)␤»
snarkyboojum rakudo: say @*INC.pelr
p6eval rakudo e50ff8: OUTPUT«Method 'pelr' not found for invocant of class 'Array'␤current instr.: '_block14' pc 29 (EVAL_1:0)␤»
snarkyboojum rakudo: say @*INC.perl
p6eval rakudo e50ff8: OUTPUT«[".", "/home/p6eval/.perl6/lib", "/home/p6eval//p2/lib/parrot/2.2.0-devel/languages/perl6/lib", "lib"]␤»
snarkyboojum eek
rakudo: push @*INC, '/something/else'; say @*INC.perl 03:09
p6eval rakudo e50ff8: OUTPUT«[".", "/home/p6eval/.perl6/lib", "/home/p6eval//p2/lib/parrot/2.2.0-devel/languages/perl6/lib", "lib", "/something/else"]␤»
lue rakudo: say @*INC.perl
p6eval rakudo e50ff8: OUTPUT«[".", "/home/p6eval/.perl6/lib", "/home/p6eval//p2/lib/parrot/2.2.0-devel/languages/perl6/lib", "lib"]␤» 03:10
snarkyboojum don't think p6eval would remember it between invocations
wtgee Ahh..., the perl6 dir is a hidden dir. Or I guess just push to it manually.
I had things in ~/perl6/lib. Thanks! 03:11
snarkyboojum rakudo: say pir::get_hll_global__PS('@INC') 03:13
p6eval rakudo e50ff8: OUTPUT«./home/p6eval/.perl6/lib/home/p6eval//p2/lib/parrot/2.2.0-devel/languages/perl6/liblib␤»
03:16 cognominal left, cognominal joined 03:23 wtgee left
lue here's a picture of a person drowning (on an actual sign in real life): lol 03:24
03:24 justatheory left
lue rakudo: say $*TIME 03:32
p6eval rakudo e50ff8: ( no output )
lue rakudo: say $*DONOTEXIST
p6eval rakudo e50ff8: ( no output )
03:34 meppel joined
lue rakudo: say $*DATE 03:35
p6eval rakudo e50ff8: ( no output )
snarkyboojum rakudo: say $*OUT
p6eval rakudo e50ff8: OUTPUT«IO()<0x29e8d68>␤»
03:36 meppl left, meppel is now known as meppl 03:38 nihiliad joined
lue almost done rewriting S32::Temporal. It's going to shock most everyone how much simpler it is :) 03:43
snarkyboojum no satellite clocks lue? 03:45
lue I'd have to come up with a Moon-based method of time-keeping first!
(I assume you mean natural satellite :) )
If I really wanted to make it difficult, I'd define an Instant as 42c*42m, where c is the speed of light and m is the # of vibrations of Molybdenum at 42 degress celsius in 1 hexsecond :) 03:49
oh yeah, and the Molybdenum is at a pressure of ~ 42ATM :)
(actually, to be useful, c should be how long it takes for light to travel 42m) 03:51
snarkyboojum rakudo: say $*CALENDAR 03:52
p6eval rakudo e50ff8: ( no output )
snarkyboojum :)
lue the only thing about the current S32::Temporal implemented so far is time() 03:53
rakudo: say time()
p6eval rakudo e50ff8: OUTPUT«1270265934.68309␤»
snarkyboojum say time().WHAT 03:54
rakudo: say time().WHAT
p6eval rakudo e50ff8: OUTPUT«Num()␤»
03:56 Sarten-X joined 04:04 rv2733 left
lue what's that calendar they use in astronomy? Where it's just one number? 04:08
(it's a Julian Year. nvm) 04:12
rakudo: say $*CALENDAR; $*CALENDAR='bob'; say $*CALENDAR
p6eval rakudo e50ff8: OUTPUT«Cannot assign to readonly value␤current instr.: '&die' pc 17215 (src/builtins/Junction.pir:399)␤»
04:16 alester joined
Coke-san I now have access to the planet six perl config. 04:18
if someone needs their feed added, ping me. 04:19
seen obra
lue \o/
"Today is Boomtime, the 19th day of Discord in the YOLD 3176" Discordian is _definitely_ going to be a part of the spec :)
Coke-san obra did say he was done with the planet feed, yes? 04:22
snarkyboojum rakudo: say Time.gmtime.time.iso8601;
p6eval rakudo e50ff8: OUTPUT«Could not find sub &Time␤current instr.: '_block14' pc 29 (EVAL_1:0)␤»
snarkyboojum alpha: Time.gmtime.time.iso8601; 04:23
p6eval alpha 30e0ed: ( no output )
snarkyboojum alpha: say Time.gmtime.time.iso8601;
p6eval alpha 30e0ed: OUTPUT«04:08:41␤»
lue rakudo: say $*NOW 04:38
p6eval rakudo e50ff8: ( no output ) 04:39
lue alpha: say $*NOW
p6eval alpha 30e0ed: OUTPUT«Contextual $*NOW not found␤␤»
04:51 nihiliad left 04:53 molaf joined
lue Time is just a jumbled iTem. 05:01
05:04 SmokeMachine joined, nihiliad joined 05:08 SmokeMachine left 05:18 nihiliad left 05:19 gfx left 05:20 PenThrive joined
snarkyboojum rakudo: <T i m e>.rotate(-2).reverse.say 05:38
p6eval rakudo e50ff8: OUTPUT«iTem␤»
snarkyboojum I see what you mean 05:40
05:47 the_irrational_1 left 05:51 rgrau left 05:56 cls_bsd left
snarkyboojum rakudo: drop <a b c>, 2 05:59
p6eval rakudo e50ff8: OUTPUT«Could not find sub &drop␤current instr.: '_block14' pc 29 (EVAL_1:0)␤» 06:00
06:00 cls_bsd joined
snarkyboojum rakudo: sub drop(@list, Int $nth) { return map { @list[$_] }, grep { ($_+1) % $nth }, 0 .. @list.elems - 1; }; say drop <a b c>, 2 06:00
p6eval rakudo e50ff8: OUTPUT«ac␤»
06:00 jaldhar left 06:02 the_irrational_1 joined 06:05 diakopter joined
lue I'm going to send off Temporal.pm tomorrow, when I feel like finishing it :) 06:05
06:05 ChanServ sets mode: +o diakopter, hanekomu left, diakopter sets mode: +o TimToady
lue (I'm still here for a bit, though. Just not working on Temporal.pod (I meant .pod!)) 06:06
o hai diakopter o/
.beat 06:07
.beats
phenny @297
06:10 iblechbot joined
lue snarkyboojum: ping 06:13
snarkyboojum lue: pong 06:14
lue Do you happen to know of something that lets me track the moon's position? It's amazingly difficult to find one :/ 06:16
bkeeler www.wolframalpha.com/input/?i=where...he+moon%3F 06:17
06:18 astrojp joined
lue Thank you Wolfram|Alpha, you have amazed me again! 06:19
.u 003F
phenny U+003F QUESTION MARK (?)
06:20 jql joined
lue 16.333^h:-24.684deg 06:23
that's the current Moontime :)
(that's a bit unruly though; it could be refined)
snarkyboojum www.wolframalpha.com/input/?i=when+...ome+out%3F 06:25
hehe - sorry - couldn't help it
rakudo: my $a = 'A'; say "\$x is $x" 06:30
p6eval rakudo e50ff8: OUTPUT«Symbol '$x' not predeclared in <anonymous>␤current instr.: 'perl6;PCT;HLLCompiler;panic' pc 152 (compilers/pct/src/PCT/HLLCompiler.pir:108)␤» 06:31
snarkyboojum rakudo: my $a = 'A'; say "\$a is $a"
p6eval rakudo e50ff8: OUTPUT«$a is A␤»
06:31 am0c left
snarkyboojum rakudo: use Test; my $x = 'A'; is("\$x is $x", '$x is A'); 06:32
p6eval rakudo e50ff8: OUTPUT«ok 1 - ␤»
lue .beats
phenny @314
lue good night
diakopter .u 33542
phenny diakopter: Sorry, no results for '33542'.
diakopter .u 3352
phenny U+3352 SQUARE RIRA (㍒)
diakopter .u 3524
phenny U+3524 CJK UNIFIED IDEOGRAPH-3524 (㔤) 06:33
diakopter lue: /
snarkyboojum night lue
06:33 am0c joined, am0c left 06:35 [particle] joined 06:45 the_irrational_1 left
diakopter std: ::System::Console.WriteLine(4) 07:00
p6eval std 30287: OUTPUT«ok 00:01 106m␤»
diakopter o goody
07:01 alester left
Coke-san .u 2653 07:06
phenny U+2653 PISCES (♓)
moritz_ rakudo: say ([\+] 1, 2, 3, 4, 5).perl
p6eval rakudo e50ff8: OUTPUT«[1, 3, 6, 10, 15]␤»
moritz_ we can haz 3angle reduze! 07:07
Coke-san rakudo: ([\+] 1, 2, 3, 4, 5).say
p6eval rakudo e50ff8: OUTPUT«1361015␤»
Coke-san ah.
zzz 07:08
snarkyboojum rakudo: say ~([\**] 1, 2, 3, 4, 5).perl 07:17
p6eval rakudo e50ff8: OUTPUT«[5, 1024, Inf, Inf, 1]␤»
snarkyboojum rakudo: say ~([\*] 1, 2, 3, 4, 5).perl
p6eval rakudo e50ff8: OUTPUT«[1, 2, 6, 24, 120]␤»
snarkyboojum rakudo: say ~([\*] 1, 2, 3, 4, 5)
p6eval rakudo e50ff8: OUTPUT«1 2 6 24 120␤»
snarkyboojum say ~([\**] 1, 2, 3, 4, 5) 07:18
rakudo: say ~([\**] 1, 2, 3, 4, 5)
p6eval rakudo e50ff8: OUTPUT«5 1024 Inf Inf 1␤»
snarkyboojum that's weird 07:19
rakudo: say ~([**] 1, 2, 3, 4, 5)
p6eval rakudo e50ff8: OUTPUT«1␤»
snarkyboojum rakudo: say ~([**] <1 2 3 4 5>) 07:20
p6eval rakudo e50ff8: OUTPUT«1␤»
snarkyboojum rakudo: say ~([\*] <1 2 3 4 5>)
p6eval rakudo e50ff8: OUTPUT«1 2 6 24 120␤»
snarkyboojum rakudo: say ~([\%] <1 2 3 4 5>)
p6eval rakudo e50ff8: OUTPUT«1 1 1 1 1␤»
snarkyboojum rakudo: say ~([\/] <1 2 3 4 5>) 07:21
p6eval rakudo e50ff8: OUTPUT«1 0.5 0.166666666666667 0.0416666666666667 0.00833333333333333␤»
snarkyboojum rakudo: say ~([\eqv] <1 2 3 4 5>) 07:23
p6eval rakudo e50ff8: OUTPUT«1 0 0 0 0␤»
snarkyboojum rakudo: say ~([\,] <1 2 3 4 5>)
p6eval rakudo e50ff8: OUTPUT«1 1 2 1 2 3 1 2 3 4 1 2 3 4 5␤»
snarkyboojum rakudo: say ~([\Z] <1 2 3 4 5>)
p6eval rakudo e50ff8: OUTPUT«Cannot resume dead coroutine.␤current instr.: 'perl6;GatherIterator;get' pc 465380 (src/gen/core.pir:74369)␤»
snarkyboojum 'dead coroutine'!
rakudo: say Inf ** Inf 07:24
p6eval rakudo e50ff8: OUTPUT«Inf␤»
snarkyboojum why isn't, say ~([\**] 1, 2, 3, 4, 5), just 1, 1, 1, 1, 1 07:26
rakudo: say (~[\**] <1 2 3 4 5>)
p6eval rakudo e50ff8: OUTPUT«5 1024 Inf Inf 1␤»
snarkyboojum rakudo: say ~[\**] <0 1 2 3 4 5> 07:27
p6eval rakudo e50ff8: OUTPUT«5 1024 Inf Inf 1 0␤»
moritz_ snarkyboojum: ** is right associative
snarkyboojum rakudo: say 0 ** 0
p6eval rakudo e50ff8: OUTPUT«1␤» 07:28
moritz_ snarkyboojum: and [**] a, b, c is meant to be the same as a ** b ** c
snarkyboojum yeah, but the \ is supposed to show you each iteration no?
moritz_ yes, it does 07:29
snarkyboojum rakudo: say 1 ** 2 ** 3
p6eval rakudo e50ff8: OUTPUT«1␤»
snarkyboojum should be 1
right
rakudo: say [**] <1 2 3> 07:30
p6eval rakudo e50ff8: OUTPUT«1␤»
snarkyboojum rakudo: say [\**] <1 2 3>
p6eval rakudo e50ff8: OUTPUT«381␤»
snarkyboojum how is that output derived at?
moritz_ rakudo: say 3, 2**3, 1**(2**3)
p6eval rakudo e50ff8: OUTPUT«381␤»
snarkyboojum oh 07:31
:)
moritz_ snarkyboojum: github.com/rakudo/rakudo/blob/maste...ops.pm#L99
snarkyboojum not 1, 1**2, (1**2)**3
moritz_ right, because ** is right associative 07:32
snarkyboojum oops
ok - sorry about that
moritz_ no problem :-)
snarkyboojum cheers :)
moritz_ runs off to obtain some $food
snarkyboojum rakudo: say ~[\*] <0 1 2 3> 07:34
p6eval rakudo e50ff8: OUTPUT«0 0 0 0␤»
snarkyboojum rakudo: say ~[\**] <0 1 2 3> 07:35
p6eval rakudo e50ff8: OUTPUT«3 8 1 0␤»
snarkyboojum lovely
rakudo: say 0 Z 1 07:38
p6eval rakudo e50ff8: OUTPUT«01␤»
snarkyboojum rakudo: say [\Z] <0 1 2 3>
p6eval rakudo e50ff8: OUTPUT«0» 07:39
snarkyboojum rakudo: say [\Z] <1 2 3 4 5>
p6eval rakudo e50ff8: OUTPUT«1»
snarkyboojum rakudo: say ~\Z] <1 2 3 4 5>
p6eval rakudo e50ff8: OUTPUT«Confused at line 11, near "] <1 2 3 4"␤current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)␤»
snarkyboojum rakudo: say ~([\Z] <1 2 3 4 5>) 07:40
p6eval rakudo e50ff8: OUTPUT«Cannot resume dead coroutine.␤current instr.: 'perl6;GatherIterator;get' pc 465380 (src/gen/core.pir:74369)␤»
snarkyboojum rakudo: say ~[\Z] <1 2 3 4 5>
p6eval rakudo e50ff8: OUTPUT«Cannot resume dead coroutine.␤current instr.: 'perl6;GatherIterator;get' pc 465380 (src/gen/core.pir:74369)␤»
snarkyboojum rakudo: say [\Z] <1 2 3 4 5>
p6eval rakudo e50ff8: OUTPUT«1»
07:40 hercynium left
snarkyboojum should stringifying that really result in a 'Cannot resume dead coroutine'? 07:40
rakudo: say +[\Z] <1 2 3 4 5> 07:41
p6eval rakudo e50ff8: OUTPUT«5␤»
07:41 Su-Shee joined
snarkyboojum rakudo: say ?[\Z] <1 2 3 4 5> 07:41
p6eval rakudo e50ff8: OUTPUT«1␤»
diakopter sits in silence 07:43
diakopter and notices the time 07:44
07:51 niros left 07:52 envi^home joined
snarkyboojum rakudo: say ~[\Z] <1 2 3 4 5 6> 07:53
p6eval rakudo e50ff8: OUTPUT«Cannot resume dead coroutine.␤current instr.: 'perl6;GatherIterator;get' pc 465380 (src/gen/core.pir:74369)␤»
snarkyboojum rakudo: say ~[\Z] <1> 07:54
p6eval rakudo e50ff8: OUTPUT«No applicable candidates found to dispatch to for 'reducewith'. Available candidates are:␤:(&op, Iterable $an-iterable, Any :chaining($chaining, Any :right-assoc($right-assoc, Any :triangle($triangle)␤␤current instr.: 'perl6;Code;assuming_helper' pc 13069
..(src/builtins/Str.pir:38)␤»
snarkyboojum rakudo: say ~[\Z] <>
p6eval rakudo e50ff8: OUTPUT«Unsupported use of <>; in Perl 6 please use lines() or () at line 11, near "<>"␤current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)␤»
snarkyboojum rakudo: say ~[\Z] []
p6eval rakudo e50ff8: OUTPUT«␤»
snarkyboojum rakudo: say ~[\Z] []
p6eval rakudo e50ff8: OUTPUT«␤»
snarkyboojum rakudo: say ~[\Z] [1]
p6eval rakudo e50ff8: OUTPUT«1␤»
07:55 iblechbot left
snarkyboojum rakudo: say ~[\Z] [1,2,3,4,5] 07:55
p6eval rakudo e50ff8: OUTPUT«Cannot resume dead coroutine.␤current instr.: 'perl6;GatherIterator;get' pc 465380 (src/gen/core.pir:74369)␤»
snarkyboojum rakudo: say <>.WHAT 07:56
p6eval rakudo e50ff8: OUTPUT«Unsupported use of <>; in Perl 6 please use lines() or () at line 11, near "<>.WHAT"␤current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)␤»
07:57 molaf left 07:58 niros joined 07:59 xabbu42 joined
cognominal rakudo: my %*a; a<4>=5; sub c { my %*a; say %a<4>.perl }; c(); 07:59
p6eval rakudo e50ff8: OUTPUT«Symbol '%a' not predeclared in c␤current instr.: 'perl6;PCT;HLLCompiler;panic' pc 152 (compilers/pct/src/PCT/HLLCompiler.pir:108)␤»
cognominal rakudo: my %*a; a<4>=5; sub c { my %*a; say %*a<4>.perl }; c();
p6eval rakudo e50ff8: OUTPUT«Could not find sub &a␤current instr.: '_block14' pc 29 (EVAL_1:0)␤»
cognominal rakudo: my %*a; a<4>=5; sub c { say %*a<4>.perl }; c(); 08:00
p6eval rakudo e50ff8: OUTPUT«Could not find sub &a␤current instr.: '_block14' pc 29 (EVAL_1:0)␤»
cognominal oops
rakudo: my %*a; %a<4>=5; sub c { my %*a; say %*a<4>.perl }; c();
p6eval rakudo e50ff8: OUTPUT«Symbol '%a' not predeclared in <anonymous>␤current instr.: 'perl6;PCT;HLLCompiler;panic' pc 152 (compilers/pct/src/PCT/HLLCompiler.pir:108)␤»
cognominal rakudo: my %*a; %*a<4>=5; sub c { my %*a; say %*a<4>.perl }; c();
p6eval rakudo e50ff8: OUTPUT«Proxy.new()␤»
cognominal rakudo: my %*a; %*a<4>=5; sub c { say %*a<4>.perl }; c(); 08:01
p6eval rakudo e50ff8: OUTPUT«5␤»
cognominal my %a; say %a<0>.perl
rakudo: my %a; say %a<0>.perl
p6eval rakudo e50ff8: OUTPUT«Proxy.new()␤»
cognominal rakudo: my %a; say %a<0>
p6eval rakudo e50ff8: OUTPUT«␤»
cognominal rakudo: my $a; say $a.perl 08:02
p6eval rakudo e50ff8: OUTPUT«Any␤»
pugssvn r30288 | moritz++ | [t/spec] correct a test for [,], and unfudge a few for rakudo 08:09
moritz_ phenny: tell masak that all the TODO tests in /S05-mass/properties-general.t pass for me - are you sure you tried it with the last parrot? 08:18
phenny moritz_: I'll pass that on when masak is around.
08:21 am0c joined
snarkyboojum rakudo: 0 but last 08:24
p6eval rakudo e50ff8: OUTPUT«Warning␤Null PMC access in can()␤current instr.: 'parrot;P6protoobject;ACCEPTS' pc -1 ((unknown file):-1)␤»
08:27 PenThrive left 08:29 gfx joined 08:52 riffraff joined
colomon loliblogged: justrakudoit.wordpress.com/2010/04/...-progress/ 09:14
rakudo: say [+] 1 09:19
p6eval rakudo e50ff8: OUTPUT«No applicable candidates found to dispatch to for 'reducewith'. Available candidates are:␤:(&op, Iterable $an-iterable, Any :chaining($chaining, Any :right-assoc($right-assoc, Any :triangle($triangle)␤␤current instr.: 'perl6;Code;assuming_helper' pc 13069
..(src/builtins/Str.pir:38)␤»
colomon doh!
sorear As a minor point of bikeshedding, may I recommend s/triangle/scan/
the incremenal reduction metaoperator in Haskell 98 is 'scanl' 09:20
mberends colomon++ # nice blog, after even nicer programming
sorear colomon++ 09:21
colomon mberends: that programming was very much a team effort.
09:22 pmurias joined
mberends :) that's clear. teamwork++ 09:22
sorear (perl6 community)++
(clean code)++
colomon sorear: triangle is actually the term used in the p6 spec 09:27
perlcabal.org/syn/S03.html#Reduction_operators and then scroll back a touch.
> say [+] 1 09:28
1
mberends colomon: in your blog, could you maybe add another example with a different operator, so that inexperienced readers do not think you are simply enhancing ** ? 09:29
colomon mberends: not a bad idea. 09:30
mberends colomon: ok then, with several other operators ;-) 09:33
colomon working on it now... ;) 09:34
09:35 Gothmog_ left
sorear colomon: ...oh. 09:37
colomon sorear: which isn't to say the Haskell term might not be better. but that's where we got triangle from. 09:38
mberends: further examples added. 09:43
mberends :-)
colomon Coke-san: if you could justrakudoit.wordpress.com/ to perl planet six, I'd appreciate it. thanks! 09:44
mberends likes the colomon++ blog 09:45
snarkyboojum enjoys justrakudoit too - colomon++ :) 09:52
colomon blush
lisppaste3 pmurias pasted "draft of my gsoc proposal" at paste.lisp.org/display/97262 09:57
pmurias any comments?
mberends pmurias: great proposal, +1 from me. any ideas on possible mentors? 09:59
pmurias: in the Abstract, a bit more explanation of the names Mildew, SMOP and CPAN would help those readers less familiar with our terminology. 10:01
dalek kudo: d906f51 | (Solomon Foster)++ | src/core/metaops.pm:
Add generic version of reducewith that treats its argument as a list, to allow the [+] 1 case to work.
pmurias mberends: i hope ruoso will be the mentor, want to get a confirmation from him before adding it to the proposal 10:04
mberends: thanks for feedback
colomon pmurias: what mberends said. also wasn't scons based on / inspired by an older p5 module called cons?
pugssvn r30289 | colomon++ | [t/spec] Add a few tests for the one-argument case. 10:07
colomon TimToady: what should [\*] () return? 10:08
snarkyboojum rakudo: say ~[\Z] [1,2,3,4,5] 10:10
p6eval rakudo e50ff8: OUTPUT«Cannot resume dead coroutine.␤current instr.: 'perl6;GatherIterator;get' pc 465380 (src/gen/core.pir:74369)␤»
snarkyboojum also, what's that about?
colomon snarkyboojum: I suspect that's the gather / take bug rearing its ugly head again.
snarkyboojum no idea if it's sane or not :) just wondering
ah ok
colomon Though I don't know why it goes away if you remove the .... oh, wait, I do know. It's because when you add ~, you are forcing the iterators to evaluate, which is what causes the problem. If you take it away, the result is just a list of iterators. 10:11
well, array of iterators.
pugssvn r30290 | colomon++ | [t/spec] Add a few more tests for the one-argument case. 10:15
10:20 Gothmog_ joined 10:23 TiMBuS joined 10:24 am0c left
colomon rakudo: say ('a'...*).batch(100).perl 10:26
p6eval rakudo d906f5: OUTPUT«("a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z", "aa", "ab", "ac", "ad", "ae", "af", "ag", "ah", "ai", "aj", "ak", "al", "am", "an", "ao", "ap", "aq", "ar", "as", "at", "au", "av", "aw", "ax",
.."ay", "…
mberends .perl could also use ' instead of " where interpolation is not expected 10:27
rakudo: say ('abc'...*).batch(30).perl 10:28
p6eval rakudo d906f5: OUTPUT«("abc", "abd", "abe", "abf", "abg", "abh", "abi", "abj", "abk", "abl", "abm", "abn", "abo", "abp", "abq", "abr", "abs", "abt", "abu", "abv", "abw", "abx", "aby", "abz", "aca", "acb", "acc", "acd", "ace", "acf")␤»
pmurias colomon: yes 10:30
mberends
.oO( that was base 26, how about base 36? )
rakudo: say ('a0a'...*).batch(40).perl 10:31
p6eval rakudo d906f5: OUTPUT«("a0a", "a0b", "a0c", "a0d", "a0e", "a0f", "a0g", "a0h", "a0i", "a0j", "a0k", "a0l", "a0m", "a0n", "a0o", "a0p", "a0q", "a0r", "a0s", "a0t", "a0u", "a0v", "a0w", "a0x", "a0y", "a0z", "a1a", "a1b", "a1c", "a1d", "a1e", "a1f", "a1g", "a1h", "a1i", "a1j", "a1k", "a1l", "a1m",
.."a1n")␤»
mberends \o/
although that is western cultural imperialism in the default ranges 10:33
10:42 M_o_C joined 10:46 payload joined, payload left, payload joined 10:48 payload left, payload joined 10:49 payload left, payload joined 10:54 payload left, wknight8111 joined 10:56 arthur-_ left
dalek kudo: 020a6a3 | (Solomon Foster)++ | src/core/metaops.pm:
Change reducewith triangle case to lazily return values.
11:04
11:05 jaldhar joined
colomon rakudo: say ([\*] 1..20).perl 11:05
p6eval rakudo d906f5: OUTPUT«[1, 2, 6, 24, 120, 720, 5040, 40320, 362880, 3628800, 39916800, 479001600, 6227020800, 87178291200, 1307674368000, 20922789888000, 355687428096000, 6.402373705728e+15, 1.21645100408832e+17, 2.43290200817664e+18]␤»
mberends colomon: cool!
colomon heh, it gets better. :)
> say ([\*] 1..*).batch(20).perl 11:06
(1, 2, 6, 24, 120, 720, 5040, 40320, 362880, 3628800, 39916800, 479001600, 6227020800, 87178291200, 1307674368000, 20922789888000, 355687428096000, 6.402373705728e+15, 1.21645100408832e+17, 2.43290200817664e+18)
The lazy version... I've just pushed it, but I expect p6eval won't have picked it up yet.
mberends pulls and starts compiling it, eagerly :) 11:07
snarkyboojum heh
11:07 arnsholt joined
snarkyboojum rakudo: my $a = 5; say ++$a++; 11:08
p6eval rakudo d906f5: OUTPUT«6␤»
snarkyboojum wouldn't have expected that to work :)
rakudo: my $a = 5; say ++$a++; say $a; 11:09
p6eval rakudo d906f5: OUTPUT«6␤7␤»
snarkyboojum ooh - is that legit eh? :) 11:10
mberends well, not in C, but this ain't Kansas any more,,,
pugssvn r30291 | colomon++ | [t/spec] Add two tests for lazy triangle reduce. 11:11
snarkyboojum and not in Perl 5 either
didn't realise that was spec'ed in Perl 6 ;)
rakudo: my $a = 5; say ++$a--; say $a;
p6eval rakudo d906f5: OUTPUT«6␤5␤» 11:12
mberends rakudo: my $a=5; say ++ ++ $a;
p6eval rakudo 020a6a: OUTPUT«7␤»
colomon std: my $a=5; say ++ ++ $a 11:13
p6eval std 30290: OUTPUT«ok 00:01 110m␤»
snarkyboojum std: my $a=5; say $a -- # should fail I suppose
p6eval std 30290: OUTPUT«===SORRY!===␤Postfix found where infix expected (omit whitespace?) at /tmp/p350DuwGL5 line 1:␤------> my $a=5; say $a ⏏-- # should fail I suppose␤ expecting any of:␤ bracketed infix␤ infix␤ infix or meta-infix␤FAILED 00:01 108m␤»
colomon > say (([\+] 1..*) Z- (1, 1, *+* ... *)).batch(20).perl 11:14
(0, 2, 4, 7, 10, 13, 15, 15, 11, 0, -23, -66, -142, -272, -490, -851, -1444, -2413, -3991, -6555)
> say (([\+] 1..*) RZ- (1, 1, *+* ... *)).batch(20).perl
(0, -2, -4, -7, -10, -13, -15, -15, -11, 0, 23, 66, 142, 272, 490, 851, 1444, 2413, 3991, 6555)
11:15 xabbu42 left 11:18 sundar joined 11:28 payload joined
moritz_ Coke-san: ping 11:36
11:37 flity left
jnthn lolimconcious! 11:38
mberends loljnthnisatthekeyboard! 11:39
moritz_ std: use foo; 11:45
p6eval std 30291: OUTPUT«Potential difficulties:␤ Can't locate module foo at /tmp/xBGQl6le7h line 1:␤------> use foo⏏;␤ok 00:01 107m␤»
mberends jnthn: do you use 32 or 64 bit Windows 7?
jnthn 32
mberends maybe that's why the free M$ 32 bit compiler does not build Parrot here 11:46
on 64 bit Win7
dalek ok: 36e0bbd | moritz++ | docs/announce/2010-03:
[docs] update release announcement, move to 2010-04 -- too late to release in March :-)
moritz_ colomon: did you take a look at rt.perl.org/rt3/Ticket/Display.html?id=74008 ? 11:47
11:48 gfx left 11:56 payload left 12:02 M_o_C left, riffraff left 12:09 payload joined
dalek ok: 70a86af | moritz++ | src/preface.pod:
[preface] start to explain what Perl 6 actually is; refactored description of multiple implementations and Rakudo
12:10
12:19 ruoso joined
moritz_ rakudo: use Test 'blah'; 12:23
p6eval rakudo 020a6a: OUTPUT«Confused at line 11, near "use Test '"␤current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)␤»
araujo just got a thinkpad 12:26
snarkyboojum araujo: what did you get? 12:33
araujo snarkyboojum, T410 , Core i7 620, 4GB
500GB HD 12:34
mberends araujo: what operating systems will you run on it?
araujo mberends, not sure yet
next dilemma to solve
mberends the coming Ubuntu 2010.04 already looks very good in beta 12:35
araujo mberends, yeah? 12:36
I have read the only tricky to get working in this machine model is the wireless card, apart from that, I shouldn't have any issue ... mmm even though, what still cares me (after many years) of configuring a linux system are the graphic drivers 12:37
mberends yeah, used both 32 and 64 bit versions here for 3 months now, including wireless 12:38
moritz_ araujo: that depends very much of the vendor of the GPU 12:40
araujo moritz_, let's say that the whole thing nvidia/ATI thing .. I have never caught up with that 12:41
moritz_ intel has pretty good open source drivers 12:42
araujo true that
moritz_ nvidia has an installer for their closed source driver which works pretty well
ATI I never tried 12:43
arnsholt Is it possible to write functions that take block arguments in NQP?
moritz_ nqp: sub f(&x) { &x(3) }; f(-> $a { $a * $a }) 12:44
p6eval nqp: ( no output )
moritz_ nqp: sub f(&x) { say(&x(3)) }; f(-> $a { $a * $a }) 12:45
p6eval nqp: OUTPUT«9␤»
moritz_ seems like "yes"
arnsholt Huzzah. Cheers!
moritz_ nqp: sub f(&x) { say(x(3)) }; f(-> $a { $a * $a })
p6eval nqp: OUTPUT«Could not find non-existent sub x␤current instr.: 'f' pc 38 (EVAL_1:0)␤»
mathw o/ 12:50
12:52 snarkyboojum left
arnsholt <3 NQP 12:53
Dynamic variables makes me happy 12:57
moritz_ arnsholt: how is your prolog implementation coming along? 13:00
arnsholt So far, so good
Got a blog post in the works as well. Just not done obsessing over wording and disposition yet =) 13:01
Fiddling with unification now
moritz_ hey, it's just a blog post. Chances that >10 people read it are slim :-)
arnsholt True, true. I'm just a bit perfectionist when it comes to words, and code 13:02
I'm quite happy with my test setup though. The interpreter just outputs TAP =) 13:03
moritz_ :-)
arnsholt So with a single test file it works just like it should (for all the wrong reasons =D) 13:04
pugssvn r30292 | moritz++ | [t/spec] some unfudges for rakudo 13:05
ruoso pmurias, btw... the gsoc proposal is looking just great... 13:08
13:18 arthur-_ joined
Coke-san colomon: nearly done. need your name. 13:26
moritz_: pong. 13:27
moritz_ Coke-san: pinged you about colomon's blog for planetsix :-)
Coke-san moritz++
arnsholt There we go. Done obsessing
moritz_ arnsholt: URL? 13:28
arnsholt starts writing the next entry
moritz_: blogs.perl.org/users/arne_skjaerhol...arted.html
colomon Coke-san: Solomon Foster
and thanks! 13:29
Coke-san done. it will probably take a little bit for it to show up on the roll.
colomon signing off now, going to take down the wireless router in a moment. in theory will have internet access again around dinner time. 13:30
moritz_ colomon: good luck 13:31
13:32 Chillance joined
Coke-san wtf. svn on sixperl planet not responding. 13:33
Juerd Given the uptime of >3 days now, I think this kernel on feather is stable 13:35
Coke-san seems to have gone through on the backend. now just need the cache to update.
Juerd++
Juerd finds some wood to knock on
mberends Juerd: thanks to a cancellation of work, it looks like I can attend Amsterdam.pm on Tuesday :) 13:36
Juerd \o/
Is that going to be your first time? 13:37
13:37 colomon left, masak joined
masak lol we're making Easter meatballs! :) 13:37
phenny masak: 08:18Z <moritz_> tell masak that all the TODO tests in /S05-mass/properties-general.t pass for me - are you sure you tried it with the last parrot?
moritz_ s/last/latest/
masak moritz_: pretty sure it wasn't the latest; I had trouble pulling from the Parrot repo at that time.
masak rebuilds everything
mberends Juerd: yes, I was only at London.pm once so far 13:38
Coke-san fondly remembers his last PM meeting, which was really just beers with a few guys from Leeds.pm
13:46 SmokeMachine joined
pmurias ruoso: just to make sure, you are interested in being my mentor? 13:51
arnsholt Yay. My blogs.perl.org is already #4 on Google for my real name 13:54
moritz_ which probably means you don't have much web presence otherwise :-) 14:02
arnsholt That's a safe assumption ^^ 14:09
Previously, it was mainly random questions from various mailing lists. There's also my father, who has almost the same name as me =) 14:10
ruoso pmurias, I already added myself as the prospective mentor of your proposal 14:14
;)
14:22 wknight8111 left 14:26 Chillance left, cognominal left
arnsholt nqp: sub foo() { say("ante"); if 1 { return; }; say("post"); }; foo(); 14:29
p6eval nqp: OUTPUT«ante␤post␤»
arnsholt That's a bug, right?
14:31 cognominal joined
masak looks that way. 14:32
nqp: sub foo() { say("ante"); if 1 { return 42; }; say("post"); }; }; foo(); 14:33
p6eval nqp: OUTPUT«Confused at line 1, near "}; foo();"␤current instr.: 'parrot;HLL;Grammar;panic' pc 500 (src/cheats/hll-grammar.pir:197)␤»
14:33 envi^home left
masak nqp: sub foo() { say("ante"); if 1 { return 42; }; say("post"); }; foo(); 14:33
p6eval nqp: OUTPUT«ante␤»
pmurias socghop.appspot.com/gsoc/student_pr...7020368113 # the proposal with formatting
masak return without an argument silently fails.
arnsholt Ooooh. Eenterestink 14:34
masak da.
mberends pmurias: your gsoc requires a Sign In :(
arnsholt goes to look at some PIR
moritz_ nqp: sub foo() { say("ante"); if 1 { return(42); }; say("post"); }; foo() 14:35
p6eval nqp: OUTPUT«ante␤Could not find non-existent sub return␤current instr.: 'foo' pc 27 (EVAL_1:0)␤»
14:37 envi^home joined
mberends pmurias: ok, reading after signing in, could you add an approximate time scale to the Schedule? 14:38
pmurias mberends: it's supposed to be public :( 14:39
arnsholt masak: Looks like a bare return is interpreted as getting a global var named return
Hmm. return is implemented as a prefix operator 14:44
Any good ideas how to fix it, given that? 14:50
14:55 masak left 15:03 lichtkind joined
lichtkind does promt autochomp`? 15:03
moritz_ arnsholt: maybe also add a term return? 15:04
15:04 rgrau joined
mberends lichtkind: can you not try it yourself? 15:04
arnsholt Yeah, that might work
moritz_ mberends: that only tells current behaviour, not expected 15:05
lichtkind mberends: im in the midst to clean up my system since my HDD is dissolving
moritz_ rakudo: print prompt('')
p6eval rakudo 020a6a: OUTPUT«Land der Berge, Land am Strome,»
moritz_ rakudo: print $*IN.get
p6eval rakudo 020a6a: OUTPUT«Land der Berge, Land am Strome,»
moritz_ both autochomp in rakudo
mberends and are specced to as well 15:06
15:06 riffraff joined
lichtkind moritz_: thanks you i supposed that but did not found i S32 15:09
in
15:10 takadonet left
mberends lichtkind: sorry your hdd is dissolving, I remember what it used to be like ;) 15:10
lichtkind: flash drives do not dissolve, they just vanish in a flash ;)
lichtkind :) 15:11
mberends: i still like to rename prompt into ask
mberends lichtkind: +1 to that idea 15:12
lichtkind mberends: i stole it from rebol
mberends: they have some cute ides more
mberends (stealing)++ # perl is good at that
lichtkind eg call the loop forever
mberends heh, -1 to that ;) 15:13
moritz_ bikeshedding++ # /me likes blue
lichtkind moritz_: i like blue too :)
mberends likes blue, but only on the inside of the bikeshed ;) 15:14
lichtkind :)
no honestly i was rethinking the control commands
most of the loops are nearly perferct
just the double meaning of loop bothers me a bit
i dont say rebol is perfect 15:15
because teir syntax is so minimal some command are just unnecesary but they have to becaus they dont know decent parameters 15:16
btw they do the switch / break in the same wys as in perl 6
i think perl 6 is now much more decent and less crazy then 4 years ago 15:17
mberends implementation makes all the difference 15:18
15:27 takadonet joined, PZt joined
pmurias mberends: added the dates 15:28
arnsholt What's the correct way to check for null/undef in NQP? 15:29
moritz_ pir::isnull iirc
arnsholt Makes sense 15:30
Yeah, that looks like it works. thanks!
mberends pmurias: well done, nicely detailed. It increases the confidence of the application a lot :) 15:32
TimToady std: blah: sub blah() { } 15:36
p6eval std 30292: OUTPUT«ok 00:01 109m␤»
TimToady std: blah: class blah { }
p6eval std 30292: OUTPUT«===SORRY!===␤Illegal redeclaration of symbol 'blah' (see line 1) at /tmp/LhrMsenR3e line 1:␤------> blah: class blah⏏ { }␤FAILED 00:01 106m␤»
TimToady a label is now a constant, not a pseudo-type 15:37
(a type has a sub for coercion, you see)
coercing to a label doesn't seem terribly useful 15:38
well, maybe in INTERCAL
I wonder if there's any other language that distinguishes forward goto from backward; in p6 a forward goto requires goto "label", while a backward goto can just say goto label 15:40
fortunately, most label uses involve doing something with a labelled loop, where there label can be predeclared 15:41
15:43 takadonet2 joined
pmurias std: goto "label1";label1: say 1 15:44
p6eval std 30292: OUTPUT«ok 00:01 106m␤»
15:44 takadonet left
pmurias std: goto "label2";label1: say 1 15:44
p6eval std 30292: OUTPUT«ok 00:01 106m␤»
TimToady that's semantics :)
at least until the compiler can do constant folding
15:44 M_o_C joined
pmurias couldn't we just always use goto label? 15:45
TimToady only if goto were a reserved word rather than a function
pmurias it's a function? 15:46
TimToady can be
with current def
and, in fact, is parsed as one by STD
pmurias so goto ["label1","label2"][(1|2).pick] is legal? 15:47
TimToady std: goto ["label1","label2"][(1|2).pick] 15:48
p6eval std 30292: OUTPUT«ok 00:01 108m␤»
TimToady p5 can do it too
though p6 can probably do it more efficiently, assuming we cache all the known labels for each dynamic scope that can catch a GOTO exception 15:51
moritz_ doesn't really think it's worth optimizing for GOTO 15:52
lue oh hai! (I see masak left early today...)
pmurias if goto is a function my &foo := &goto; foo("bar"); say 5;bar: say 3; just prints 3
arnsholt What's the correct way to create an undefined value in a PAST tree? 15:54
moritz_ what kind of undefined value? 15:55
TimToady pmurias: and that would be wrong because...? :)
arnsholt moritz_: To create the value returned by a bare return 15:56
moritz_ arnsholt: oh. In Perl 6 that's Nil - don't know what the nqp equivalent is
arnsholt (I also discovered that undef doesn't work the way I thought it does in NQP)
moritz_ arnsholt: and maybe there isn't one, which might be the reason there is no empty return
arnsholt True, true 15:57
TimToady what is this 'undef' of which you speak? :)
pmurias TimToady: that would be a label would stop the optimizer from building a control graph
arnsholt TimToady: Exactly ^^
pmurias s/would be/would mean/
moritz_ phenny: tell colomon to please correct the spelling of my name in the last justrakudoit blog post, s/mortiz/moritz/ :-) (common typo)
phenny moritz_: I'll pass that on when colomon is around.
15:58 justatheory joined
TimToady pmurias: I think you generally break basic blocks on a label boundary anyway 15:58
lue is finishing up S32::Temporal...
TimToady and certainly, if someone cloaks goto and breaks the optimizer, they probably deserve whatever hapens 15:59
pmurias will think about it while going to checking his bicycle
arnsholt moritz_: A different angle. Is there a way to explicitly reference null PMC in PIR?
TimToady *pp
moritz_ TimToady: care to update www.perlmonks.org/?node_id=732226 to current Perl 6 syntax? (just removing a single X) 16:01
16:03 astrojp left, riffraff left
TimToady moritz_: fixed, thanks 16:05
moritz_ also www.perlmonks.org/?node_id=716497 contains old series syntax
rakudo: .say for [\~] 1 xx 10 16:06
p6eval rakudo 020a6a: OUTPUT«1␤11␤111␤1111␤11111␤111111␤1111111␤11111111␤111111111␤1111111111␤»
TimToady you're gonna make be regret popularizing Perl 6 :P
moritz_ :-)
moritz_ stops digging out old Perl 6 code on perlmonks
TimToady hmm, I think we should leave that one historical, maybe with a note. 16:08
16:10 the_irrational_1 joined 16:11 the_irrational_1 left
lue how could I preview a pod document in html? 16:13
moritz_ lue: pod2html 16:15
TimToady moritz_: okay, added note on that one
lisppaste3 takadonet pasted "weird arguments" at paste.lisp.org/display/97273 16:20
takadonet2 can anyone tell me why I get two Pairs arguments instead of just one? 16:21
16:22 hicx174_ left 16:23 takadonet2 is now known as takadonet
moritz_ takadonet2: @first.kv returns the keys and values OF THE ARRAY 16:23
so 0 and the pair
you likely want for @first -> { say .key; say .value }
16:24 leedo joined
moritz_ rakudo: for a => 1, b => 2 -> $ ($key, $value) { say $value } 16:24
p6eval rakudo 020a6a: OUTPUT«Not enough positional parameters passed; got 0 but expected 2␤current instr.: '_block54' pc 389 (EVAL_1:152)␤»
moritz_ rakudo: for "a" => 1, "b" => 2 -> $ ($key, $value) { say $value }
p6eval rakudo 020a6a: OUTPUT«Not enough positional parameters passed; got 0 but expected 2␤current instr.: '_block54' pc 393 (EVAL_1:154)␤»
16:24 leedo left
moritz_ rakudo: for "a" => 1, "b" => 2 -> $pair ($key, $value) { say $value } 16:25
p6eval rakudo 020a6a: OUTPUT«Not enough positional parameters passed; got 0 but expected 2␤current instr.: '_block54' pc 393 (EVAL_1:154)␤»
takadonet rakudo: for "a" =>1,"b"=>2 -> $pair { say $pair.key} 16:26
p6eval rakudo 020a6a: OUTPUT«a␤b␤»
takadonet moritz_:thanks
lichtkind mberends: how you would describe the effect of implementation on spec ? 16:27
arnsholt Haha! 16:30
16:31 nihiliad joined
arnsholt moritz_: I've managed to hack the code into some form of submission. Care to take a look? 16:31
TimToady lue: the current S02 does *not* claim that Instants are TAI aware, only that there is likely a constant Instant that defines the TAI epoch 16:32
along with constants for several other common epochs 16:33
16:33 am0c joined, espadrine joined
moritz_ arnsholt: yes, but I need to run now... will look at it later when I come back 16:33
mberends lichtkind: in theory, theory and practice are the same. In practice, they're not ;) # with apologies to justatheory 16:34
arnsholt moritz_: Right. I'll wrestle git-format-patch into submission, and leave a message with phenny
lichtkind mberends: thats obvious, my question was more: i understand that implementation forces a prcatical way how details work together but i saw some grater syntactical changes, and i was not shure you want to explain them the same way 16:36
lisppaste3 arnsholt pasted "NQP bare returns patch" at paste.lisp.org/display/97274 16:39
mberends lichtkind: you saw it more deeply than I did :) you're right, too, because feedback from users has given us syntax changes such as $fh.get, even though another way was already working. It shows the value of combining a good balance of top down and bottom up design. 16:40
arnsholt phenny: msg moritz_ NQP bare returns patch: paste.lisp.org/display/97274
phenny: tell moritz_ NQP bare returns patch: paste.lisp.org/display/97274
phenny arnsholt: I'll pass that on when moritz_ is around.
TimToady I think of $fh.get more as feedback from a teacher 16:42
lue Almost done, just writing some details on various date/time system (being thorough) 16:43
16:45 nakajima joined 16:46 nakajima left 16:50 am0c__ joined 16:53 am0c__ left, dj_goku joined, dj_goku left, dj_goku joined 16:55 masak joined
lue ohaimasak! 16:57
masak ohailue! 16:59
lue almost done with S32::Temporal :) 17:00
masak take your time :) 17:02
17:04 lucs joined
lue All it took were 3 classes, and none of this :: business :) Just providing some details, which are horribly lacking in many parts of the spec. 17:04
TimToady \o/ for none of this :: business 17:05
masak I agree.
TimToady considers aiming the lue at IO's horrendous :: collection 17:06
masak it takes a brave person to cut down to the heart of the matter. 17:07
moritz_ is around
phenny moritz_: 16:40Z <arnsholt> tell moritz_ NQP bare returns patch: paste.lisp.org/display/97274
17:08 TimToady sets mode: +vvv buubot dalek hugme, TimToady sets mode: +vv ilogger2 IRSeekBot, TimToady sets mode: +vvv lisppaste3 p6eval phenny 17:10 astrojp joined
lue *WHEEE* *WHIRRR* "Rdie(*)'s cannon is pointed towards input. Output should orbit itself next to input in 5 hours" 17:11
moritz_ rakudo: say 2**2**3 17:12
p6eval rakudo 020a6a: OUTPUT«256␤»
moritz_ rakudo: say 2**(2**3)
p6eval rakudo 020a6a: OUTPUT«256␤»
lue hooray for CAS! 17:13
masak .oO( min CAS e kass ) 17:16
17:16 rgrau left
mberends masak: I've just got a patchy proto to install Rakudo on Windows XP 17:17
jnthn It's an apache project now? ;-) 17:18
masak lue: do you know anything about the new Dr Who this weekend?
mberends: wow, that's great news! \o/
mberends++
mberends the horrible thing is that the Parrot --prefix directive needs the *backslashes* changed to *forward* slashes :-/ 17:19
masak odd.
mberends somewhere inside Parrot, backslash separators completely disappeared 17:20
jnthn ohwtf. :-/
masak workaround time :)
lue masak: yes, but here in the US it's Apr. 17 :(
IT BUGS ME! 17:21
masak lue: ah. sorry about that... :)
lue In Britain it's 4/4 right 17:22
diakopter rakudo: say(foo(sub foo($x) { 4 })) 17:26
p6eval rakudo 020a6a: OUTPUT«4␤»
diakopter :|
masak o.O 17:27
diakopter std: say(foo(sub foo($x) { 4 }))
masak that's an old one, right?
p6eval std 30292: OUTPUT«ok 00:01 109m␤»
diakopter apparently it's not a bug
hence teh :|
masak the more I look at it, the more right it looks.
but... wow!
funky.
diakopter meh
masak probably chicken scratches to a Lisp hippie, though. 17:28
lue .u peace
phenny U+262E PEACE SYMBOL (☮)
diakopter ah well. sprixel stage2 won't support that. 17:29
but someone can make stage4 support it
lue .oO[The symbol of a Lisp hippie: (☮) ]
lichtkind lue: its the rune of death 17:30
TimToady std: say foo sub foo($x) {4}
p6eval std 30292: OUTPUT«ok 00:01 107m␤»
TimToady it's just a post-declaration
masak perl6: say foo(bar(sub foo($x) { 42 }, sub bar($x, $y) { $x }))
p6eval pugs: OUTPUT«*** ␤ Unexpected "foo"␤ expecting "=", subroutine parameters, trait or block␤ at /tmp/d370utDhlo line 1, column 17␤»
..elf 30292: OUTPUT«"my" variable $x masks earlier declaration in same scope at (eval 126) line 6.␤syntax error at (eval 126) line 3, near "(sub foo"␤"my" variable $Call::Api can't be in a package at (eval 126) line 3, near "($Call::Api"␤syntax error at (eval 126) line 6, near ")}"␤"my" variable
..$Call…
..rakudo 020a6a: OUTPUT«42␤»
masak \o/
lue Perl6: we cheer when things fail (sometimes) :) 17:31
masak but Rakudo doesn't fail.
TimToady rakudo: say foo sub foo($x) {4}
p6eval rakudo 020a6a: OUTPUT«4␤»
masak rakudo: if 0 { sub foo() { 4 } }; say foo 17:32
p6eval rakudo 020a6a: OUTPUT«Could not find sub &foo␤current instr.: '_block14' pc 29 (EVAL_1:0)␤»
TimToady std: if 0 { sub foo() { 4 } }; say foo
p6eval std 30292: OUTPUT«Undeclared routine:␤ 'foo' used at line 1␤ok 00:01 107m␤»
diakopter TimToady: when does std check whether foo has been declared
two ago
three ago
masak rakudo: say foo; sub foo() { 4 }
p6eval rakudo 020a6a: OUTPUT«4␤» 17:33
masak feels he's missing something
TimToady: what diakopter asked. how does it know not to create the &foo in the 'if 0', but know to create the &foo declared after the 'say foo'?
diakopter I guess std must queue up a list of sub names to check _after_ a block is done bein parsed 17:34
17:34 hicx174 joined
TimToady it has nothing to do with the 'if 0' 17:34
and everything to do with the fact that it's in the inner lexical scope
diakopter I was asking about say foo sub foo($x) {4}
masak oh. :)
right, subs are lexical nowadays.
TimToady S06:103 discusses postdeclaration, for those following along 17:35
diakopter when does std check whether foo has been declared in say foo sub foo($x) {4} 17:37
17:38 Austin joined
jnthn foo will have been installed into the lexpad already by the time you get to calling it there. 17:38
diakopter I'm asking about std
masak one failing spectest in t/spec/S12-methods/instance.rakudo:
not ok 15 - meth(%h) is not a valid method call syntax
jnthn masak: aye, some $*SCOPE tracking fejl.
masak looks incomprehensingly at that test 17:39
s/sing/ding/
TimToady STD calculates definition visibility at CHECK time with a method called 'explain_mystery' 17:40
masak ah, now I see it.
it tries to call a method .b as b()
TimToady doing it correctly involves remembering the lexpad that you check from so you don't get false positives
std: { foo; }; { sub foo {...} } # should fail 17:41
p6eval std 30292: OUTPUT«Undeclared routine:␤ 'foo' used at line 1␤ok 00:01 106m␤»
TimToady std: { foo; }; sub foo {...} # should succeed
p6eval std 30292: OUTPUT«ok 00:01 106m␤»
diakopter std: { foo; }; sub foo {...}
p6eval std 30292: OUTPUT«ok 00:01 106m␤»
diakopter hmm, ok; thanks
TimToady you just remember the pad, and the fact that the name was unresolved, and try again at CHECK time, basically 17:42
17:42 am0c left
TimToady easy peasy 17:42
masak :)
diakopter k. as I postulated, except the queue is at CHECK instead of per block
17:43 hicx174 left
masak TimToady: if I do eval('END { say "OH HAI" }'), I get the "OH HAI" at the end of the whole program, not at the end of the &eval call, right? 17:43
Austin Question: Given that many object attributes have similar characteristics, is there a way to group them by behavior? I'm thinking of the C# accessor feature, except maybe as some kind of first-class entity: Attribute "name" has "get_name" and "set_name", attribute "type" has "get_type" and "set_type", so how can I get that into a simple declaration? 17:44
masak Austin: has $!a; # no getter/setter 17:45
Austin: has $.a; # getter
Austin: has $.a is rw; # getter/setter
diakopter right, but I think he wants method form
instead of =
masak oh. 17:46
macros?
maybe something with traits?
Austin diakopter: What I'm looking for is a way to build on "has $.a is rw"
jnthn Custom meta-attribute class.
masak mutated sea urchins with ninja training.
jnthn wtf
Austin So that, for example, I can implement "you can only set this value once" or "this array is always initialized" type behavior
takadonet rakudo: say 'a'..'z'.WHAT
masak jnthn: er. or what you said. :)
p6eval rakudo 020a6a: ( no output ) 17:47
takadonet ...
17:47 hicx174 joined
jnthn rakudo: say ('a'..'z').WHAT 17:47
:-)
masak Austin: arrays *are* always initialized :)
p6eval rakudo 020a6a: OUTPUT«Range()␤»
takadonet thanks
diakopter oh, I see. he actually does want C#-style properties, where the "=" assignment actually calls a method the coder provided
takadonet rakudo: say ('a'..'z').WHAT
p6eval rakudo 020a6a: OUTPUT«Range()␤»
takadonet rakudo: say ("a..z").WHAT
p6eval rakudo 020a6a: OUTPUT«Str()␤» 17:48
masak diakopter: maybe modify the STORE method of the container somehow?
jnthn Austin: I guess short of implementing has $.x is rw style syntax in NQP..
takadonet rakudo: say ('a..z').WHAT
Austin diakopter: Not necessarily. I don't care about the =. I just want to avoid the copy/pasting of setter methods.
p6eval rakudo 020a6a: OUTPUT«Str()␤»
diakopter oh
Austin (Although that would logically follow...) 17:49
takadonet Any easy way to convert a Str() to a Range() ?
diakopter eval
TimToady masak: yes, end of the whole program 17:50
diakopter :P
masak Austin: t/spec/S14-traits/attributes.t seems to do much of what you want.
17:51 jonalv joined
jonalv oh hai 17:51
I am groupie, ask masak or jnthn
masak jonalv: \o/ 17:52
takadonet diakopter: how would you do that with an eval?
masak TimToady: S04: "Code that is generated at run time can still fire off C<CHECK> and C<INIT> phasers...". what about BEGIN phasers? why would those be treated differently from CHECK phasers? 17:53
TimToady BEGIN means 'as son as compiled', which can be after CHECK time
but not after the CHECK time for the eval 17:54
after the CHECK time for the mainline code though
17:54 Austin left
masak so the eval has its own CHECK time, but not its own END time? 17:54
what's the overriding rule that I'm missing?
17:55 Austin_Hastings joined
TimToady gravity 17:55
masak o.O
jnthn well, that drags you down.
TimToady as in window gravity
jonalv you talking about heavy stuff?
masak jonalv: this isn't something to be taken lightly!
TimToady 'this window moves to the northwest as far as possible'
diakopter has gravity gotten stronger by 1985? 17:56
TimToady BEGIN can't move to the left farther than its compile time
masak nodnod
TimToady END can't move to the right farther then the end of the process
masak so, basically, the overriding rule is that Perl 6 does what's temporally possible, and no more.
TimToady so I didn't intend levity by gravity 17:57
yes
masak haz a content
...with that answer.
rakudo: class Animal does Pet { }; role Pet does Bite { }; role Bite { method bite() { say "ouch" } };
p6eval rakudo 020a6a: OUTPUT«Null PMC access in type()␤current instr.: 'perl6;Animal;!class_init_11' pc 390 (EVAL_1:171)␤»
masak submits rakuodbug
TimToady is amazed that masak deduced he was missing an overriding principle :D 17:58
masak I usually am when things seem unfairly complex :)
TimToady Deducing that there must be a box outside of which you ought to think is really difficult. 17:59
masak that's like an overriding metaprinciple, I guess.
also, it seems more productive to assume "what am I missing?" rather than, say, "this box sucks!"
Austin_Hastings masak++ # Traits seems to be it. Thanks. 18:00
masak Austin_Hastings: jnthn++ tipped me off to their existence.
Austin_Hastings: only work in the past, not in the present.
Austin_Hastings ?
diakopter hasn't read about traits yet
masak Austin_Hastings: there's an old Rakudo branch called alpha.
Austin_Hastings: the master branch hasn't quite caught up yet after the last refactor. 18:01
Austin_Hastings Oh. NP. I'm asking for NQP.
masak ohohah. I see.
rakudo: role A does B {} 18:02
p6eval rakudo 020a6a: ( no output )
masak rakudo: role A does B {}; role B {}
p6eval rakudo 020a6a: ( no output )
masak rakudo: class A does B {}; role B {}
p6eval rakudo 020a6a: OUTPUT«Null PMC access in type()␤current instr.: 'perl6;A;!class_init_11' pc 374 (EVAL_1:167)␤»
masak rakudo: role B {}; class A does B {} 18:03
p6eval rakudo 020a6a: ( no output )
masak rakudo: class A does B {}
p6eval rakudo 020a6a: OUTPUT«Null PMC access in type()␤current instr.: 'perl6;A;!class_init_11' pc 353 (EVAL_1:161)␤»
masak ah. that's it. 18:04
18:05 Austin_Hastings left
masak we're discussing "type Slovaking", a kind of dual of "type Czeching" :) 18:05
std: sub foo($x: $y: $z) {} 18:06
p6eval std 30292: OUTPUT«ok 00:02 109m␤»
masak O.O
18:09 wknight8111 joined
lue The only bad thing about snow on a sunny day is that when you come back inside, everything 18:09
's tinted green very dim :/ 18:10
*and* very dim
masak green? is the snow at your place a bright purple?
lue No, that's just the afterimage after staring at very reflective white snow
TimToady
.oO(I have eaten purple snow...)
18:11
masak lue: maybe you're experiencing greenshift from time traveling...
jnthn
.oO(Does the purplse taste better than the yellow? That was srsly blech... )
18:12
TimToady perhaps a cosmic string is approaching to nullify his mucking about with time
yes, if it's purple from syrup
lue the good thing about staring at white snow on a clear, sunny day is that it filters what comes thru my eyes, and causes the monitor to not be so blue-tinted in my vision
mberends a surprise when auto-verifying a Rakudo build, is that the output of perl6 -v does not mention either Rakudo, or Perl, or 6 (unless in the Parrot revision) 18:13
TimToady the snow in question was at the summit of Mt Lassen, which I climbed at the tender age of four.
with Sunny Jim grape syrup.
masak TimToady: when would a BEGIN phaser fire after a CHECK phaser? also, what *does* happen if I do BEGIN {} inside an eval?
lue
.oO(actually, the snow does turn purple in 2030, when acid rain is more common than pure rain)
.oO(but even then only in parts of China)
18:14
masak knows the overriding principle now, but can't yet draw his own conclusions...
TimToady BEGIN always fires off the moment it is compiled, but compilation happens after mainline CHECK time for an eval
masak right.
TimToady well, unless the eval is done at compile time :) 18:15
(see constant folding...)
masak eval('BEGIN { say 2 }; END { say 4 }'); BEGIN { say 1 }; END { say 3 } # prints 1\n2\n3\n4 ? 18:16
18:17 rbaumer joined
masak an eval can be constant-folded? scary :) 18:17
sounds like an area where you have to step carefully so as not to trip over the Halting Problem...
s/4/\\n/ 18:18
er. s/4/4\\n/, I mean.
TimToady well, perl 5 does 1,2,4,3, but that's arguably wrong
pugssvn r30293 | lue++ | [P6 Spec] completely changed S32::Temporal
TimToady errands & 18:19
masak TimToady: I was hesitating between 3,4 and 4,3 myself when writing that up.
18:20 colomon joined
masak it depends on whether the second END {} block is enqueued when it's being executet over, or at some earlier point, I guess. 18:20
s/cutet/cuted/
rakudo: if 0 { END { say "OH HAI" } }
p6eval rakudo 020a6a: OUTPUT«OH HAI␤»
masak how do I conditionally enqueue an END phaser? :) 18:21
lue And...relax! (to myself, of course)
colomon I'm surprised END phasers even work yet. \o/
phenny colomon: 15:57Z <moritz_> tell colomon to please correct the spelling of my name in the last justrakudoit blog post, s/mortiz/moritz/ :-) (common typo)
moritz_ colomon: they are needed for Test.pm 18:22
lue I "fixed" S32::Temporal ! \o/
colomon moritz_: aaaaaa! 18:23
apologies.
18:23 literal joined
moritz_ no problem 18:23
colomon notice it is a typo, I got it right in the next paragraph.
moritz_ yes 18:24
and it's a quite common one, actually
colomon Fixed.
moritz_ masak: with newest parrot + rakudo, do you also get unexpected passes in S05-mass/properties-general.t? 18:25
masak no, don't think so. 18:26
I re-ran the spectests, but they didn't say anything about unexpected passes.
moritz_ now that's curious
lue
.oO(I realise I have just killed an entire t/spec folder and damaged every implementation of P6 so far :) )
masak I'll run that file only and see.
moritz_ masak: maybe it's not run at all, because you don't have icu?
masak I do have icu. 18:27
moritz_ you do? that's new :-)
masak well, I sometimes do and sometimes don't :)
there's occasionally a window of time between getting a new laptop and figuring out how to put ICU into a Mac. 18:28
I think it's happened twice by now.
lue masak: how many laptops do you have? How often do you get one? 18:29
masak moritz_: I'm running that file. and the TODO'd tests are the same as the failing ones.
moritz_ masak: weird. They all pass here
masak lue: one at a time, but I wear them out on a yearly basis. one got stolen. 18:30
lue How are they worn out, I have to wonder?
masak lue: by use.
moritz_: Parrot r45393, Rakudo 020a6a.
lue they don't become unusable, do they? If they do, then you're doing some serious work and deserve an extra ++ 18:31
masak oh, I don't know about that. :) I also use them to browse the web (heavily!), and watch movies and stuff. 18:32
18:33 colomon left, colomon joined
lue rakudo: say (264/60) 18:33
p6eval rakudo 020a6a: OUTPUT«4.4␤»
colomon rakudo: say (264/60).perl
p6eval rakudo 020a6a: OUTPUT«22/5␤»
lue rakudo: say sqrt(12) 18:35
p6eval rakudo 020a6a: OUTPUT«3.46410161513775␤»
lue rakudo: say sqrt(12).perl
p6eval rakudo 020a6a: OUTPUT«3.46410161513775␤»
lue it doesn't simplify roots! :( 18:36
rakudo: say (sqrt(12)).perl
p6eval rakudo 020a6a: OUTPUT«3.46410161513775␤»
masak lue: sounds like a good idea for a module.
Rats are quite enough for most people, methinks. Roots is probably past what many people care about. 18:37
lue coincidentally, the ping timeout of colomon in minutes is the premiere of Doctor Who in Europe. 18:39
masak *lol*
18:39 [particle]1 joined
colomon with any luck my connection should be stable now. 18:39
at least, the cable guy just left.
jonalv masak: "It's very Perl6 to be barefooted" 18:40
18:40 payload left, [particle] left, payload joined
masak jonalv: use.perl.org/~masak/journal/38988 :) 18:40
18:41 Trashlord joined, payload left
colomon rakudo: say sqrt(12).Rat.perl 18:41
p6eval rakudo 020a6a: OUTPUT«1351/390␤»
lue
.oO(priceless example of Wikisurfing: I began at Discordian Calendar, and am now at Beth numbers. See if you can find my trail :))
18:42
colomon rakudo: say sqrt(12).Rat(1e-12).perl
p6eval rakudo 020a6a: OUTPUT«3650401/1053780␤»
18:42 payload joined
masak ooh, Beth numbers. didn't know about those. 18:42
lue++
lue
.oO(this week in math class we'll learn about imaginary #'s, and I'm going to spend the weekend comprehending beth numbers. :P)
18:43
rakudo: multi sub infix:<Ω>($a,$b){$a++;$b+=$a;$b++;$a+=$b; $b - $a;}; say 4Ω3 18:47
p6eval rakudo 020a6a: OUTPUT«Confused at line 11, near "say 4\u03a93"␤current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)␤»
lue rakudo: multi sub infix:<œ>($a,$b){$a++;$b+=$a;$b++;$a+=$b; $b - $a;}; say 4œ3
p6eval rakudo 020a6a: OUTPUT«Confused at line 11, near "say 4\u01533"␤current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)␤»
lue rakudo: multi sub infix:<M>($a,$b){$a++;$b+=$a;$b++;$a+=$b; $b - $a;}; say 4 M 3
18:47 envi^home left
p6eval rakudo 020a6a: OUTPUT«Cannot assign to readonly value␤current instr.: '&die' pc 17215 (src/builtins/Junction.pir:399)␤» 18:47
lue alpha: multi sub infix:<M>($a,$b){$a++;$b+=$a;$b++;$a+=$b; $b - $a;}; say 4 M 3 18:48
p6eval alpha 30e0ed: OUTPUT«Cannot assign to readonly variable.␤in sub »
colomon rakudo: multi sub infix:<M>($a is copy,$b is copy){$a++;$b+=$a;$b++;$a+=$b; $b - $a;}; say 4 M 3
p6eval rakudo 020a6a: OUTPUT«-5␤»
lue dankon, colomon! 18:49
colomon ;)
masak rakudo: .say for [\~] 1 xx 10
p6eval rakudo 020a6a: OUTPUT«1␤11␤111␤1111␤11111␤111111␤1111111␤11111111␤111111111␤1111111111␤»
masak \o/
lue rakudo: multi sub infix:<M>($a is copy,$b is copy){$a++;$b+=$a;$b++;$a+=$b; $b - $a;}; say 3 M 4
p6eval rakudo 020a6a: OUTPUT«-4␤»
18:49 Logo joined
Logo Hi 18:50
colomon o/
18:53 astrojp left
masak Logo: hi! 18:53
mberends: [backlogging] 'in practice, theory and practice are different' -- Scott Aaronson once wrote: "I 18:55
Logo When perl6 is release?
masak mberends: "If that's so, the theory was really bad."
Logo: that's the million-dollar question :)
moritz_ Logo: once every month 18:56
Logo :)))
masak Logo: it's like this: we're working really hard on it, we have releases every month, and it's coming along fine.
Logo: we're basically getting to most people's threshold of usefulness as soon as we can.
how soon that will be for you depends on how resilient you are to various failures in the implementations :P 18:57
pugssvn r30294 | moritz++ | [t/spec] fudge catch.t for rakudo 18:58
lue rakudo: multi sub infix:<M>($a is copy,$b is copy){$a++;$b+=$a;$b++;$a+=$b; $b - $a;}; say 1 M 1 18:59
p6eval rakudo 020a6a: OUTPUT«-2␤»
masak Logo: many things already work. look:
rakudo: .say for [\+] 1..10
p6eval rakudo 020a6a: OUTPUT«1␤3␤6␤10␤15␤21␤28␤36␤45␤55␤»
masak rakudo: class Seal { method onk { say "ONK! } }; Seal.new.onk
p6eval rakudo 020a6a: OUTPUT«Unable to parse blockoid, couldn't find final '}' at line 11␤current instr.: 'perl6;Regex;Cursor;FAILGOAL' pc 1664 (ext/nqp-rx/src/stage0/Regex-s0.pir:907)␤» 19:00
masak oops.
rakudo: class Seal { method onk { say "ONK!" } }; Seal.new.onk
p6eval rakudo 020a6a: OUTPUT«ONK!␤»
Logo regex modifiers is not work(
masak Logo: we have a great number of operators, very advanced OO, great regex support...
Logo: jaffa4, is that you?
Logo Syntax error.. 19:01
moritz_ Logo: they mostly work from inside the regex
rakudo: say 'ABC' ~~ /:i abc/;
p6eval rakudo 020a6a: OUTPUT«ABC␤»
lue the one thing that's guaranteed broken right now is Date/Time related stuff :D
19:01 nihiliad left, nihiliad joined
masak Logo: in general, you'll find many things that will not work as spec'd. we're currently looking for "early adopters", those for whom the sense of immense coolness of actually using Perl 6 outweighs the sense of frustration over missing features. 19:03
pugssvn r30295 | moritz++ | [t/spec] test for RT #62264, .^isa on Exception objects 19:04
moritz_ is down to two tickets in RT 19:07
lue \o/
masak moritz_++
moritz_ tickets I own that need tests, that is.
masak nod.
diakopter assign a bunch more.. esp the WEIRD ones ;)
not to me. :)
lue We'd be throwing a party with webcams if there were two tickets in RT left :)
.oO(I am going to end up learning *a lot* of math above my current level to understand beth numbers :))
19:08
jnthn moritz_: I assigned two to you earlier today :-)
masak lue: is 'party with webcams' like an ordinary party, just better? :)
moritz_ jnthn: I know - I could close both of them without writing new tests
jnthn moritz_: Oh, just turned some on? :-)
Cool.
moritz_ akshually the tests for triangle reduce were already turned on by the time I got the mails from RT :-) 19:10
colomon++ took care of that
dalek kudo: 1935270 | moritz++ | t/spectest.data:
we now pass catch.t
lue well, we'd rather sit in our houses than go somewhere and risks someone reporting bugs while we're not near our computers :)
jnthn moritz_: oh awesome :-) 19:11
Logo Is there russians?
moritz_ goes early to bed because he has to attend at baptism at 5:30am tomorrow 19:12
jnthn Logo: Да! И водка!
moritz_ Logo: I know that somebody translated some of my blog posts and tutorials to russian 19:13
Logo Это хорошо:)
moritz_ I'm sure google can find them
lue
.oO(no! no more russian! last time you filled the IRC I almost cried /o\)
diakopter \o\
lue phenny: tell me to stop worrying 19:14
masak Logo: Есть, конечно, русский народ :)
phenny Hey, I'm not as stupid as Monty you know!
Logo Скоро 10 лет должно исполнится как Perl 6 разрабатывается 19:15
Скорей бы уже вышел)
masak Logo: well, 10 years, or 8 years, or 3 years, depending how you count... :) 19:16
sbp phenny: "Скоро 10 лет должно исполнится как Perl 6 разрабатывается"?
phenny sbp: "Soon 10 years should be fulfilled as Perl 6 is being developed" (ru to en, translate.google.com)
lue I prefer babelfish myself :)
Logo Почему в графике тестов rakudo.org/status в феврале скачок вниз? 19:17
masak Logo: because pmichaud usually does the updates.
and he hasn't been around too much lately...
Logo: snarkyboojum generated a newer graph. I have it here somewhere... 19:18
Logo: www.mutteringmadman.com/perl6/status.png
Logo: (that sudden drop followed by a quick recovery is what we're currently up to. it's a refactor) 19:19
lue
.oO(can't wait for the day of no regression!)
can P6 read binary files yet? (i.e. open and play with the individual bytes of, say, a PNG file) 19:22
Logo moritz_: What url have your blog? 19:23
lue
.oO("Aleph-null bottles of beer on the wall, Aleph-null bottles of beer, Take one down, and pass it around, Aleph-null bottles of beer on the wall")
19:31
masak lue: no, we'd need the Buf type for that, I think.
Logo: perlgeek.de/blog-en/ 19:32
lue and I'm guessing Buf is NYI 19:36
masak well, MNYI.
'mostly' 19:37
rakudo: Buf
p6eval rakudo 020a6a: OUTPUT«Could not find sub &Buf␤current instr.: '_block14' pc 29 (EVAL_1:0)␤»
masak and what little is in alpha doesn't seem ported over, either.
lue: want to implement Buf? it's mostly a simple matter of programming :)
19:38 SmokeMachine left
lue rakudo: my $object = Buf.new(0x2A,0x2B); say decode('utf8',$object) 19:39
p6eval rakudo 020a6a: OUTPUT«Could not find sub &Buf␤current instr.: '_block14' pc 29 (EVAL_1:0)␤»
lue (as usual, the spec is not too clear...)
masak lue: [new spec] Discordian!? 19:40
jnthn A disfunctional accordian?
masak lue: I'm assuming you're two days late for your April 1 joke...
19:41 Caelum joined
lue let's go with that 19:42
masak lue: on first reading of your spec change, I'm thinking two things:
lue (here it comes)
masak (1) oh, good, he got rid of a lot of cruft
(2) WTF!?
phrasing that in a vaguely constructive way: your commit is a good first step towards something :) 19:43
it'll need some revision.
not sure Perl 6 will gain anything from being combined with Discordia... :P 19:45
lue of course. In my head, putting them into classes makes perfect sense (short from actual types, which I *cough* don't know anything about creating in P6)
19:45 Caelum left
masak 'type' is just a collective term for class or role or subtype, IIUC. 19:46
lue something like my Time $onEarth = 13:47
or our Date $ofRelease = 12/31/∞ 19:47
masak seems to me you want to introduce some pretty special new parsing.
lue :)
.oO(isn't that the point of P6?)
19:48
masak that rethorical question is so vague that it wouldn't have an answer even if it weren't rethorical... :P
lue When it comes to the calendars: there honestly isn't much of anything, only Gregorian. I decided that another common calendar ought to be one present on every Linux distro (ddate) 19:49
masak lue: ok, so you actually are serious about the Discordian stuff. then I know.
lue It was either a couple semi-common, or every. single. calendar in existance. 19:50
masak this is one of the problems of Temporal.
there's a constant risk of doing too much.
lue You can get rid of it if you want :) I actually considered the Mayan calendar as well :P
masak I'm inclined to get rid of it.
here's my goal for that piece of spec:
(1) minimal-ish
(2) very, very clear 19:51
lue Of course, the Mayan calendar will be removed from the spec after 12/21/12 :)
masak (3) attractive, in the sense that people nod and think, "yes, I want to use this"
lue: by the way, you're using a very anglo-centric date format. I don't think that's going to fly...
lue It's all Earth-centric anyway (the Darian calendar would balace that out though...) 19:52
masak lue: the only date format I could even begin to defend as a standard is iso 8601.
lue: let's stay on Earth.
lue just commenting on the fact that nothing we do can be completely independent yet (you're lucky I didn't define an Instant; did you check the backlogs?) 19:55
I think the big problem is that, when it comes to time, different people need completely different things. 19:56
masak that's not unlike any other part of the spec.
lue but with (lunch)time, it's doubly so :) 19:57
masak I think what makes Temporal very bikeshed-friendly is that it's a field where everyone is an expert in some sense :)
lue: you're just full of HH quotes, aren't you? :P
diakopter not I
19:57 SmokeMachine joined
masak diakopter: but you have other admirable qualities, so we like you anyway :) 19:58
lue s/HH/H2G2/ # *cough*
masak lue: oh, indeed. sorry :)
rakudo: class X::Y {}; class X
p6eval rakudo 193527: OUTPUT«Malformed package declaration at line 11, near ""␤current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)␤»
masak rakudo: class X::Y {}; class X {}
p6eval rakudo 193527: ( no output )
diakopter masak: bleh 19:59
masak :) 20:00
diakopter everytime TimToady complains I'm perseverating, I think of salivating.
masak huh?
diakopter on this channel. 20:01
he says I'm perseverating.
masak you think of salivating on this channel?
diakopter no, the word 'perseverating' makes me think of the word 'salivating'
jnthn puts up an umbrella
masak why?
diakopter b/c they almost rhyme 20:02
masak lue: I have a desire to see something good come out of all the discussion around Temporal. I think it'll take an exotic combination of collaboration and benovelent self-proclaimed dictatorship that we haven't really managed to arrive at yet.
20:02 levengli joined, [particle]1 is now known as [particle]
masak diakopter: ah. 20:03
diakopter and salivation:food::perseveration:unreachable_goal
20:04 astrojp joined
masak lue: right now, I think I'd like to take a step back, look at a number of other datetime libraries, and try to figure out what API we really want. 20:05
lue: after that, try to connect it to some minimal internal implementation.
in fact, let's do that now. 20:06
lue alright. Lessee, there's Python, JavaScript, and Haskell, for starters
masak I have these:
ruby-doc.org/core/classes/Time.html
joda-time.sourceforge.net/
diakopter ticks & seconds as measures of duration. all other measures are relative to some external timestamp
masak hackage.haskell.org/packages/archiv...ormat.html
docs.python.org/library/time.html
lue to a notepad! (of some sort). Let's take notes on what we like, and nopaste them. 20:07
masak diakopter: thought you said you didn't have opinions on Temporal...
diakopter yeah yeah 20:08
masak diakopter: if durations are just seconds, do they really need their own class?
diakopter: wtf is a tick?
lue check the backlogs for my definition of an Instant :)
diakopter cpu tick
masak diakopter: is that the 1/18.2 of a second one? 20:09
diakopter I dunno
masak why is it necessary/relevant?
diakopter I dunno 20:10
I guess it isn't
masak ah. also called a 'jiffy'. "usually" 0.01 second.
diakopter: well, if I don't understand it, I'm inclined not to include it in a minimal description...
diakopter lue: I think of "instant" as "a point in time" or "a certain time" or just "a time" 20:11
in that sense, Time would be a class representing a point in time
and Timeline would be a universe-wide (ignoring relativistic effects & drift) ray 20:12
so, a Calendar would be a way of representing a Timeline
masak thing I like from the Ruby Time lib: Time.new creates a Time object initialized to the current time. simple, understandable, short, unambiguous. 20:13
lue
.oO(I can't seriously define an instant, because we go through an ∞ number of them every second, IMO)
masak lue: that never stopped us from defining other continuous entities, such as the real number line. 20:14
the .utc? and .gmt? methods are a nice touch. 20:15
diakopter similarly in JS, Date.new creates a new Date from Now (Then, when it was created)
lue I know there's a difference between UTC and GMT but I don't remember... 20:16
masak there isn't, it seems.
not here, at least.
lue .beats
phenny @886
masak also, it'd be nice to have an easy plan for converting back and forth between UTC and local times.
specify an easy, effortless way to do that => win 20:17
also, getting at year, month, day, hour, minute, second is a must for a serious time module.
lue maybe something like [time here].utc-8, where -8 is the same as if we did $x - 8 ?
masak a .strftime is a nice plus, but I doubt it's strictly minimal. 20:18
lue I tried once to find a way to go epoch->human-readable, but with no luck
.oO(this kind of discussion is what a second monitor was made for; I don't want to switch back-n-forth between IRC and firefox!)
20:19
masak I'm slightly ashamed I didn't include this into the things to be inspired by, too: search.cpan.org/dist/DateTime/lib/DateTime.pm
I'm done looking at Ruby. moving on to JodaTime. 20:20
joda-time.sourceforge.net/
I found this module, whose distinctive feature is that it steps away from the horribleness that is Java's GregorianCalendar 20:21
lue is currently trying to find out how to put chatzilla in the sidebar, to have seamless research & irc 20:22
diakopter lue: do you have All-In-One Sidebar? 20:23
lue no, not yet :)
I have very little use for a sidebar in firefox (until now) 20:24
20:28 astrojp left
lue
.oO(lue thinks of how awful it would be if someone came here with a nick of [OFF])
20:30
20:31 astrojp joined
masak in Joda Time, DateTime objects are immutable. I like that. joda-time.sourceforge.net/quickstart.html 20:32
they also think about localization. we needn't do localization in Perl 6 core, but we should think about it, too. 20:33
20:34 lucs left
lue That's the problem I encountered when defining Date in the spec; the localization. 20:35
masak "Joda-Time defaults to using the ISO calendar system (the calendar used by most of the business world)", and then it provides other, pluggable, calendar systems. I like that.
lue (I also think I used too many environment variables...)
masak also, Joda-Time seems to have DateTime but not individual Date and Time. I'm thinking we should have just one class, too. 20:36
still undecided on whether we ought call it DateTime or just Time.
lue diakopter: how do I open Chatzilla in AiOS? 20:37
masak oddly, they do have LocalDate and LocalTime separate.
wonder why.
if there's a reason, and if we choose to do the same, then DateTime is the definite choice for the non-local one.
I'd say logically, a DateTime object makes more sense than separate Date and Time objects. jnthn seems to agree. 20:41
lue I have to say it makes more sense as well. I think I was worried about how calendars/clocks would match up 20:42
masak hm. I pasted the wrong Haskell link before, it seems. here's a correct(er) one: hackage.haskell.org/packages/archiv...eTime.html
masak tries to get into a Haskell-y mood before reading that 20:43
in Haskell, a DateTime is a UTCTime. 20:44
a UTCTime "consists of the day number, and a time offset from midnight. Note that if a day has a leap second added to it, it will have 86401 seconds."
lue ( ChatZilla refuses to open in an AiOS sidebar :( ) 20:45
masak I think I like the simplicity of that.
they also allow for conversion to and from UniversalTime, which is "ime as measured by the earth's rotation, adjusted for various wobbles" 20:47
that's very pretty, but I'm unclear on what exactly that means in practice :)
but instinctively, I like the separation "Universal Time: Time as measured by the earth -- UTC: Time as measured by a clock". and I like the phrasing. 20:48
lue We get a wobble-ometer :) 20:49
masak but then I'm getting confused again. there's also a ClockTime and a CalendarTime :/ too many Times!
lue and they're all an illusion :)
I'm surprised no-one's defined a LunchTime :)
(ooh, that reminds me, what did IETF post _this_ April Fools?) 20:50
masak ok, going on to look at Python: docs.python.org/library/time.html
even their URL is orderly! Python++
20:52 colomon left
lue (but docs.python.org's search function is weird :/) 20:54
here's Python 3: docs.python.org/py3k/library/time.html
masak thanks. 20:55
lue "DST is Daylight Saving Time, an adjustment of the timezone by (usually) one hour during part of the year. DST rules are magic (determined by local law)" 20:56
I love the DST rules are magic part :)
masak :)
this is a very good reason to leave the actual implementation of local timezones as an exercise to the module implementor :) 20:57
at most, we might do one or two time zones ourselves to show the way. 20:58
but they're probably not going into core.
lue I personally like how Py3 returns gmtime and localtime as an array of elements.
wouldn't a library be best suited for that?
masak think so. 20:59
lue: where do you see that gmtime and localtime return an array of elements?
21:00 finanalyst joined
lue on the link I provided above (Py3), the first table demonstrates this array. 21:00
masak I'm not sure I like it. 21:01
sure, it's close to what time functions in Perl 5 return in array context. 21:02
but I guess I see that as a poor man's OO.
levengli where can i see good perl6 code?
library, module examples 21:03
somthing to get me started
lue An "array" would be better than a string of some sort, though
finanalyst masak: greetings. I have just tried using proto, and things have changed. But cant get it to work. got problem with projects.state
masak lue: yes, but we're talking about the primary representation of the DateTime object here, right? I'd prefer that to be opaque. 21:04
finanalyst: ok, good to know. can you nopaste?
finanalyst: mberends++ is currently making changes involving a S11-like module system and Windows compatibility.
21:05 M_o_C left
lue docs.python.org/py3k/library/datetime.html this is described as a more OOP way of date/time 21:05
masak lue: the reason, I think, is that I greatly prefer the readability of Time.new.year to gmtime()[0]
lisppaste3 finanalyst pasted "using proto" at paste.lisp.org/display/97286 21:06
masak "There are two kinds of date and time objects: “naive” and “aware”. This distinction refers to whether the object has any notion of time zone, daylight saving time, or other kind of algorithmic or political time adjustment." +1 to that.
masak likes the distinction 'naive' and 'aware'
finanalyst: looking
finanalyst: ok, seems it's just not finding the file. 21:07
finanalyst i modified the parrot / perl6 parts to point at where I have rakudo
it seems that it doesnt like locations other than <home>.perl/ 21:08
lue likes their datetime object, except for the part where they assume Gregorian and whatever the clock we use is called
finanalyst btw using ubuntu linux
levengli anyone?
lue I really can't think of any examples, except for the specification: perlcabal.org/syn 21:09
masak finanalyst: it dies on line 121 of lib/Ecosystem.pm 21:10
finanalyst: because 'open or die' isn't a functioning idiom in Rakudo.
it already dies if the open fails.
also, arguably, it shouldn't die if the file isn't there.
finanalyst but where is it looking? 21:11
masak it tries to find projects.state in your current directory.
what happens if you create an empty file and run proto again?
finanalyst looking 21:12
levengli someone had to have written code 21:13
masak phenny: tell mberends that it seems that if a projects.state doesn't exist when proto is executed, proto dies: paste.lisp.org/display/97286 -- we need to do something friendlier there than 'open or die' :)
phenny masak: I'll pass that on when mberends is around.
finanalyst projects.state is placed in <home>/.perl6/proto/
which exists 21:14
masak hm.
lue I'll have to think about Temporal, but I need to take a break, I'm starting to get bored :) [afk]
finanalyst but i have changed some of the configuration options because I have rakudo at another location
masak is ~/.perl6/proto/ the dir where you keep your proto installation? 21:15
is it the dir where you execute proto?
finanalyst no. proto is <home>/development/proto
masak lue: thanks for the discussion so far! I'll keep looking at Python and CPAN.
finanalyst thats where I run proto from
masak finanalyst: it should be in that dir, methinks. 21:16
finanalyst ok. will try. but that is not where the first run of proto put it at.
masak I see. 21:17
finanalyst ok now working
masak I'm not up-to-date with what proto is currently doing, sadly :/
I should take the time to study it a bit.
finanalyst i copied projects.state from where proto put it to where proto is 21:18
things not good!!!! :(
masak no? 21:19
finanalyst i tried ./proto install svg and got a whole load of failes
s/failes/faileds/
i dont want all modules. just svg
proto worked without a problem a few months ago. Now not! 21:20
spinclad pmurias: in gsoc proposal, in the Deliverables item, s/v8-mildew,/v6-mildew, / # (digit and space after)
masak finanalyst: right. are you using the new Rakudo master? 21:21
finanalyst i did a git pull a couple of days ago
masak right. you're aware that there's been a sizeable refactor of the whole of Rakudo? 21:22
finanalyst just install new ubuntu distribution and i updated rakudo. had to delete parrot
masak nod
finanalyst yes to refactor
do i need to delete rakudo directory and start again? 21:23
i had to do that when ng became master
21:24 frew is now known as frioux, frioux is now known as frooh
jnthn nqp: say('abc ' ~~ /\s*$/); 21:24
p6eval nqp: OUTPUT« ␤»
jnthn nqp: say('abc' ~~ /\s*$/);
p6eval nqp: OUTPUT«␤»
masak finanalyst: I'm afraid I don't know much more than you at this point. 21:25
spinclad levengli: i would look at the modules that proto knows about, and (not so much library/module code) the p6 advent calendar.
masak finanalyst: anyway, the feedback that you've given so far helps a lot.
levengli: what spinclad said. start by looking at the smaller, contained things, like JSON::Tiny. 21:27
levengli where do i find this?
spinclad (sorry, having a visual migraine right now, can't track down urls) 21:28
masak levengli: github.com/moritz/json
spinclad afk & 21:29
levengli github.com/perl6/perl6-examples look suitable 21:30
thanks all
finanalyst masak: just deleted previous rakudo location and trying to install whole environment via proto
masak finanalyst: that might help. it sorta works here, I think.
haven't tried to install anything in the last few days.
finanalyst if it works, then configuration options of proto either broken or not intuitive
masak agreed. 21:31
both are quite likely right now, I'm afraid.
finanalyst not really a problem as long as proto works from scratch
masak finanalyst: once upon a time, proto was something I had absolute control over. now, it's something that I have almost no control over :) 21:32
the OOP layer of time in Python does Date, Time and DateTime. 21:35
levengli has anyone tried the link i sent
everything is failing
masak it keeps all the 'aware' stuff in tzinfo classes. offsets, DST, etc.
levengli: that's probably because those were written for the old branch of Rakudo called 'alpha'.
spinclad levengli: or earlier 21:36
masak levengli: I bet no-one has looked at those scripts and tried to make them work with the new master.
levengli: if you point me to a particular script, I might help you get it working.
maybe :)
pmurias spinclad: thanks for mentioning the typo, fixed
masak hm. looking at DateTime on CPAN, I think that's an excellent starting point for a Temporal module in Perl 6. 21:37
(but perhaps with some things like time zones shunted off to non-core modules, I dunno) 21:38
but the synopsis in that CPAN module page is excellent! search.cpan.org/dist/DateTime/lib/DateTime.pm
levengli 99-problems/P01-scottp.pl
masak looks
"Method 'Int' not found for invocant of class 'Block'" 21:39
that's what I get when I try to run it.
levengli same here 21:40
masak let's try to find out why.
levengli although i don't know whether i should read the error messages bottom up or top to bottom
masak neither.
only the first line really matters. :)
the rest is unfortunate garbage.
levengli good to know
masak rakudo: <A B C D E F>[* - 1].say 21:41
p6eval rakudo 193527: OUTPUT«Method 'Int' not found for invocant of class 'Block'␤current instr.: 'perl6;Mu;' pc -1 ((unknown file):-1)␤»
masak there it is.
first nontrivial line.
rakudo: say <A B C D E F>.WHAT
p6eval rakudo 193527: OUTPUT«Parcel()␤»
masak rakudo: <A B C D E F>[5].say
p6eval rakudo 193527: OUTPUT«F␤»
21:42 Su-Shee left
masak right. 21:42
'* - 1' doesn't seem to work.
levengli WTF are you doing?
p6eval: voodoo
masak levengli: I'm running Perl 6 code on the channel :)
levengli how?
masak rakudo: say "hi levengli!"
p6eval rakudo 193527: OUTPUT«hi levengli!␤»
levengli rakudo: say "aha"
p6eval rakudo 193527: OUTPUT«aha␤»
masak :)
levengli++
buubot: karma levengli 21:43
buubot masak: levengli has karma of 2
masak levengli: welcome to #perl6 :) levengli++
buubot: karma levengli
buubot masak: levengli has karma of 3
levengli now that i got that, why is it not liking the [* -1]? and what is buubot?
masak levengli: at one point Rakudo handled [*-1], but we've been refactoring a bit in the past few months. 21:44
not everything is in place again.
we're working on it. :)
levengli: buubot is one of our many bots. I was mainly showing off its karma function.
levengli can i call man bots to see what you have? 21:45
masak levengli: we're a very bot-rich channel. it's like living in the future. p6eval is another very useful bot.
levengli: no, but I can give you a URL :)
lisppaste3 finanalyst pasted "proto not working" at paste.lisp.org/display/97288
levengli p6eval: say "lala"
masak levengli: howcaniexplainthis.blogspot.com/200...ts-do.html
levengli by all means
masak levengli: you can't say 'p6eval: ', you need to say 'rakudo: ' or some other implementation, like 'pugs: ' 21:46
finanalyst masak: tried using proto to install rakudo and parrot. All seems to function, then proto will not install
masak finanalyst: it looks thoroughly broken :(
why is it trying all projects? 21:47
and why is it failing to download them?
finanalyst: I'm unable to give much advice without looking at it closer, and I'm not sure I'll be able to give it the attention it deserves today.
finanalyst proto worked so well before
masak aye. 21:48
then ng happened.
finanalyst: *all* my projects are broken! not just proto.
everything.
but we're working to fix it.
finanalyst its a bit annoying as i have deleted all the files
which i was using as examples
of how to code! 21:49
levengli what language is rakudo written in?
masak finanalyst: you could go back in time to January, then everything will work again.
levengli: a combination of PIR, nqp and Perl 6.
finanalyst sigh. i had time to work on an svg output
masak levengli: and a little bit of C.
21:49 clintongormley left
levengli finally a "real" language 21:49
anything that i can do in the C department/ 21:50
?
jnthn Maybe hack on Parrot, but generally we want to keep the amount of C minimal in Rakudo.
finanalyst i want to have one of the first live perl6 examples on my company website when rakudo * comes out
got to sleep now. bye 21:51
jnthn The more written in Perl 6 or a subset of it, the better.
21:51 finanalyst left
masak levengli: in theory, you could also help mberends on vill, another Perl 6 implementation, which is written in C. 21:52
levengli and doesn't run on parrot, i assume
masak levengli: correct. it runs on llvm.
levengli why not run on the actual machine?
masak levengli: not even Perl 5 does that :) 21:53
in short, because it's hard for a dynamic to run directly on the metal.
s/dynamic/dynamic language/
jnthn levengli: Because a language like Perl 6 needs a _lot_ of runtime support that it's not good use of resources, and hard, to re-invent.
*to use
levengli given that i lead a team developing an embedded RTOS, metal is where i feel at home 21:54
sigh
masak levengli: wish we had more C code for you :) 21:55
levengli is there a graphical API in parrot?
if so, i could get started with that
masak not built-in, I don't think.
but there's an NCI bridge. 21:56
levengli you're killing me
too many TLA
masak 'Native Calling Interface'
a way to connect Parrot to C.
and, by extension, C libraries.
sorear levengli: SMOP is a bare metal (well, POSIX) Perl6 implementation 21:57
levengli is there a way for perl6 to call parrot api or does require another bridge?
is SMOP alive?
diakopter correction: llvm isn't a VM, per se; it's a framework that helps coders implement systems that include optimization phases
masak cues jnthn
sorear Rakudo can run inline parrot VM code
jnthn levengli: It's pretty easy to call into Parrot stuff.
masak diakopter: oh! didn't know that. thanks. 21:58
sorear rakudo: say Q:PIR { new %r, 'Integer' }
p6eval rakudo 193527: OUTPUT«0␤»
jnthn levengli: mberends++ and I wrote something called Zavolaj.
21:58 pmurias left
levengli jnthn: is Zavolaj perl6 calling into parrot? 21:58
jnthn levengli: It provides a nice wrapper that lets you declaratively write C bindings.
sorear Zavolaj automates perl6 calling into C 21:59
jnthn In Pelr 6.
*Perl
levengli where do i find it?
jnthn it's not 100% complete, but it's been enough to connect to MySQL and write a client for it.
gist.github.com/jnthn/zavolaj
masak would like to try to start with CPAN's DateTime and narrow it down to an 'essential core' for S32::Temporal 22:00
sorear rakudo: my $libc := pir::loadlib__ps("libc.so.6"); my $sin := pir::dlfunc__ppss($libc, "sin", "ff"); say $sin(0.1)
p6eval rakudo 193527: OUTPUT«:= binding of variables not yet implemented␤current instr.: '&die' pc 17215 (src/builtins/Junction.pir:399)␤»
sorear rakudo: my $libc = pir::loadlib__ps("libc.so.6"); my $sin = pir::dlfunc__ppss($libc, "sin", "ff"); say $sin(0.1)
p6eval rakudo 193527: OUTPUT«No NCI thunk available for signature 'ff'␤current instr.: '_block14' pc 29 (EVAL_1:0)␤»
masak 'NCI thunk'? :)
cognominal brotherbard.com/blog/2010/03/experi...gitx-fork/ # for the fanbois
sorear rakudo: my $libc = pir::loadlib__ps("libc.so.6"); my $atan2 = pir::dlfunc__ppss($libc, "atan2", "fff"); say $atan2(1, 1) 22:01
p6eval rakudo 193527: OUTPUT«3370280550400␤»
sorear rakudo: my $libc = pir::loadlib__ps("libc.so.6"); my $atan2 = pir::dlfunc__ppss($libc, "atan2f", "fff"); say $atan2(1, 1) 22:02
p6eval rakudo 193527: OUTPUT«0.785398185253143␤»
masak CPAN's DateTime considers the 'naive' datetimes to have a 'floating' time zone. not sure which model I like better.
levengli Q:PIR {
$P0 = find_lex 'self'
$P0 = getattribute $P0, '$!unmanaged'
$P1 = find_lex '$idx'
$S0 = $P0[$P1]
%r = box $S0
};
sorear that's how you call from Rakudo into C without Zavolaj
masak levengli: when you paste code, please use a nopaste service :)
levengli: see the /topic 22:03
levengli i assume that this is calling PIR code directly from perl6
jnthn Right.
levengli sorry
masak no problem.
levengli how do i nopaste?
jnthn We have Zavolaj so that we can do that in one place.
masak levengli: see /topic
sorear levengli: Rakudo is a Perl6 to PIR compiler; Q:PIR is like __asm__
masak levengli: paste.lisp.org/new/perl6
dalek kudo: 93fa3d5 | jonathan++ | src/Perl6/ (2 files):
Implement interpolation of method calls, array indexing and hash indexing in strings. Needs a workaround due to <after> being NYI.
22:04
kudo: 84fcbbc | jonathan++ | t/spectest.data:
Merge branch 'master' of github.com:rakudo/rakudo
levengli got it jnthn and masak
masak jnthn++! 22:05
jnthn: Rakudo just got a great deal more awesome! \o/
sorear jnthn++!
masak pugs: my @a = 1,2,3; say "@a" 22:06
p6eval pugs: OUTPUT«@a␤»
masak pugs: my @a = 1,2,3; say "@a[]"
p6eval pugs: OUTPUT«1 2 3␤»
masak pugs does it already, it seems.
pugs: my @a = 1,2,3; say @a.elems()
p6eval pugs: OUTPUT«3␤»
masak pugs: my @a = 1,2,3; say [email@hidden.address]
p6eval pugs: OUTPUT«3␤»
jnthn pugs: my @a = 1,-2,3; say "@a[1].abs.sin()"
p6eval pugs: OUTPUT«0.9092974268256817␤»
masak pugs: my @a = 1,2,3; my $method = 'elems'; say "@a."$method"()" 22:07
p6eval pugs: OUTPUT«*** ␤ Unexpected "$method"␤ expecting term postfix, operator, ":" or ","␤ at /tmp/NAw9xt4WCc line 1, column 47␤»
masak hah! :)
pugsbug.
jnthn Works in Rakudo. ;-)
masak jnthn++
22:07 snarkyboojum joined
masak snarkyboojum! \o/ 22:07
snarkyboojum masak: hi o/ 22:08
masak snarkyboojum: we're having a party, with webcams! :D
snarkyboojum is still half asleep
party.. with webcams?
:)
masak snarkyboojum: a party with webcams is like an ordinary part, only much awesomer :P 22:09
s/part,/party,/
snarkyboojum sounds... intriguing :P
masak rakudo: $_ = "an ordinary part,"; s/part\,/party\,/; .say 22:10
p6eval rakudo 193527: OUTPUT«an ordinary part,␤»
masak jnthn: why doesn't that work?
levengli all: doesn't perl6 -I<path> work for including module paths?
masak rakudo: $_ = 'a'; s/a/b/; .say
p6eval rakudo 193527: OUTPUT«a␤»
jnthn rakudo: my $_ = 'lol'; /o/; say $/; 22:12
p6eval rakudo 193527: OUTPUT«Redeclaration of symbol $_ at line 11, near " = 'lol'; "␤current instr.: 'perl6;HLL;Grammar;panic' pc 500 (ext/nqp-rx/src/stage0/HLL-s0.pir:328)␤»
jnthn rakudo: $_ = 'lol'; /o/; say $/;
p6eval rakudo 193527: OUTPUT«Any()␤»
masak levengli: I don't think it does. 22:14
levengli: I usually set $PERL6LIB
masak tries -I
levengli: no, no -I. 22:15
levengli any other suggestios?
masak levengli: I usually set $PERL6LIB 22:16
levengli tried it
works nicely
masak \o/ 22:17
levengli++
levengli no longer supported in Perl or not yet supported in rakodu?
masak the latter.
there are a number of simple flags it doesn't have... it's sort of in limbo since about a year back. 22:18
someone was supposed to work on a grant with it, but something distracting happened, I think.
levengli i'm guessing that this is not something written in C
masak I wouldn't mind having -n and -p, too.
levengli: no, most of it is written in PIR.
levengli you keep saying that
i finally got all phsyced up to get started on p6, now i have to learn PIR 22:19
i'll try and hold off a little longer
masak well, you don't have to learn PIR if you just want to write Perl 6 code.
levengli jnthn: win32-api-call.p6 returns "Can not handle type Mu in an 'is native' signature." 22:20
masak I frankly don't know a lot of PIR, and I get along fine.
levengli don't you write part of rakadu?
sorear levengli: PIR is Parrot VM assembly language... it's actually quite easy, just a tremendous amount of typing
jnthn The easiest bits to hack on are the bits written in Perl 6 and/or NQP. 22:21
22:21 colomon joined
masak PIR wasn't actually meant to be that widely used as a language written by humans, IIUC. 22:22
levengli jnthn: are you referring to your example or rakadu development?
jnthn levengli: Rakudo dev. 22:23
levengli: I'm not sure why that doesn't work.
levengli probably because i'm running on linux
:) 22:24
jnthn oh, calling a win32 api on linux may not work out so well ;-)
22:25 SmokeMachine left
snarkyboojum "Time is just a jumbled iTem." - hehe.. he really put it in 22:28
masak that was part of my 'wtf?' reaction.
snarkyboojum lol 22:29
jnthn > sub bold($t) { "<b>" ~ $t ~ "</b>" }; say "my &bold("huge") meatball";
my <b>huge</b> meatball
masak jnthn: \o/
snarkyboojum: by the way, I'm adding our first test for Yapsi::Runtime now, to set the scene.
snarkyboojum masak: excellent! 22:31
22:31 supernovus joined
masak supernovus: \o/ 22:32
supernovus So, I read that Temporal is changing, again. If anyone is interested in the half-baked version I was hacking on, I threw it up on github.
Hello masak! 22:33
masak supernovus: excellent. yes, we're interested.
I've been thinking out loud on the channel this evening.
supernovus masak: I never got very far in the Temporal reflux, I had all sorts of ideas for it. The code on github is only an example of what I had planned. I think a lot of it would make a better third-party library, rather than a part of the core. 22:34
github.com/supernovus/temporal-reflux 22:35
masak supernovus: I've had similar thoughts. do you think Perl 6 core should have any temporal support at all?
masak looks
"Temporal ReFlux: It's about time" :) 22:36
(time puns)++
supernovus masak: I'm not sure about whether it should or not. Honestly, as long as it has 'time', everything else may be better off in an external module.
masak wow, ambitious.
the reflux code, I mean.
22:36 Logo left
masak supernovus: I'd like to be able to do simple things without reaching for a library. things like asking what day of the month it is. 22:37
problem is, already that is a quite involved operation, because dates are inherently hairy.
supernovus I do plan to resume Temporal reflux, but I may wait to see what the Temporal spec rewrite looks like..
masak the quest of the API designer is to make it feel easy without outright lying.
supernovus: good. variation and different angles are potentially beneficial. 22:39
pugssvn r30296 | jnthn++ | [t/spec] Correct a test description that ccidentally the interpolated call. 22:43
jnthn *accidentally 22:44
:-)
masak snarkyboojum: I tried the subtype approach, and it worked, so I went with that :) github.com/masak/yapsi/commit/d6b91...443a3ef49f
snarkyboojum masak: beautifully simplified :) 22:45
masak snarkyboojum: I thought you'd like it :) 22:46
now for that test...
snarkyboojum masak: looks like real Perl 6 :)
masak supernovus: I hope whatever Temporal ends up being doesn't contain something called Gregorian::Calendar :/
supernovus Eh, I kept that name, but got rid of the rest of the Gregorian::* stuff. Basically, DateTime could take any "calendar" and just "use it". 22:47
masak mm. 22:48
supernovus Although, for namespace consistency, it should have been Calendar::Gregorian
masak yeah. 22:49
levengli good night all
supernovus o/ 22:50
masak levengli: 'night!
22:50 levengli left
dalek kudo: cd0c7cf | jonathan++ | src/Perl6/ (2 files):
Fix up quote mod checks for array and hash interpolations, and implement function call interpolation too.
22:50
lichtkind good ight 22:51
night
22:51 opx^away is now known as opx^on
masak jnthn++ 22:51
supernovus okay, there is a debugger called tardis and a bot called dalek... 22:52
22:53 k23z__ joined
supernovus is queuing up today's episode of Doctor Who... 22:53
k23z__ err 22:54
anyone here know svg ?
masak k23z__: I do. 22:55
snarkyboojum std: my $12-var = 'invalid name';
p6eval std 30295: OUTPUT«===SORRY!===␤Preceding context expects a term, but found infix = instead at /tmp/obIE8fFOAF line 1:␤------> my $12-var ⏏= 'invalid name';␤FAILED 00:01 107m␤»
k23z__ masak, I wonder why this doesn't render
pastie.org/902134
22:55 TiMBuS left
masak k23z__: no idea. looks fine to me on first inspection. 22:56
k23z__ masak, x1="-80" x2="-80" y1="0" y2="0" /> 22:57
masak, does that mean negative x ?
masak jnthn: rt.perl.org/rt3/Ticket/Display.html?id=73912
k23z__: yah, it should. 22:58
jnthn: rt.perl.org/rt3/Ticket/Display.html?id=73886
snarkyboojum: it works! github.com/masak/yapsi/commit/ce943...f76306475b 23:01
23:02 M_o_C joined, lichtkind left, meppl left
k23z__ masak, I was able to figure it out 23:03
snarkyboojum masak++ :) 23:04
afk for a bit&
colomon rakudo: class A { has $.color; method B(A $x: ) { say $x; } }; my $a = A.new(:color("green"); say $a.B; say B($a); 23:05
p6eval rakudo 84fcbb: OUTPUT«Unable to parse postcircumfix:sym<( )>, couldn't find final ')' at line 11␤current instr.: 'perl6;Regex;Cursor;FAILGOAL' pc 1664 (ext/nqp-rx/src/stage0/Regex-s0.pir:907)␤»
colomon rakudo: class A { has $.color; method B(A $x: ) { say $x; } }; my $a = A.new(:color("green")); say $a.B; say B($a);
p6eval rakudo 84fcbb: OUTPUT«A()<0x465e8b8>␤1␤Could not find sub &B␤current instr.: '_block14' pc 29 (EVAL_1:0)␤»
colomon rakudo: class A { has $.color; method B(A $x: ) { say $x.color; } }; my $a = A.new(:color("green")); say $a.B; say B($a); 23:06
p6eval rakudo 84fcbb: OUTPUT«green␤1␤Could not find sub &B␤current instr.: '_block14' pc 29 (EVAL_1:0)␤»
colomon rakudo: class A { has $.color; method B(A $x: ) { say $x.color; } }; my $a = A.new(:color("green")); $a.B; B($a);
p6eval rakudo 84fcbb: OUTPUT«green␤Could not find sub &B␤current instr.: '_block14' pc 29 (EVAL_1:0)␤»
colomon rakudo: class A { has $.color; method B(A $x: ) is export { say $x.color; } }; my $a = A.new(:color("green")); $a.B; B($a); 23:07
p6eval rakudo 84fcbb: OUTPUT«green␤Could not find sub &B␤current instr.: '_block14' pc 29 (EVAL_1:0)␤»
23:09 payload left
k23z__ masak, wanna see the result 23:09
?
23:12 phenny left, phenny joined
cognominal rakudo: (<a b>; 1,2).crosswith(&[~]) 23:17
p6eval rakudo cd0c7c: OUTPUT«Unable to parse postcircumfix:sym<( )>, couldn't find final ')' at line 11␤current instr.: 'perl6;Regex;Cursor;FAILGOAL' pc 1664 (ext/nqp-rx/src/stage0/Regex-s0.pir:907)␤»
cognominal <a b> X~ 1,2
rakudo: <a b> X~ 1,2
p6eval rakudo cd0c7c: ( no output )
23:17 opx^on is now known as opx^away, opx^away is now known as opx^on
cognominal rakudo: say <a b> X~ 1,2 23:17
p6eval rakudo cd0c7c: OUTPUT«a1a2b1b2␤»
colomon cognominal: I'm not sure if calling crosswith directly is strictly kosher, but... 23:18
rakudo: say crosswith(&infix:<~>, <a b>, (1, 2)); 23:19
p6eval rakudo cd0c7c: OUTPUT«a1a2b1b2␤»
23:19 opx^on left
cognominal colomon, I am typing it straight from S03:4438 23:20
colomon you can't always believe the spec. ;)
k23z__ masak, ?
colomon cognominal: that's totally not how it's implemented in Rakudo, and I'm not quite sure why the spec specifies it that way. (Though the general notions there were very helpful when implementing Xop.) 23:21
23:22 opx^on joined, opx^on is now known as opx^away, opx^away is now known as opx^on
k23z__ hey 23:22
how would you guys like some pretty images generated with Perl6 ? 23:23
I wonder
I have a project in mind but it requires also studying some mathematics and some group work
colomon pretty images are good.
k23z__ well there are these things, they're called braids, they are generalizations of permutations(as I can see by reading a bit of maths about them) 23:26
23:27 supernovus left
k23z__ for example if you have a transposition (1 2) and you apply it to itself , you get the identic permutation 23:27
basically a transposition (1 2) is the permutation (2,1)
but if you get a braid and apply it to itself you can twist it infinite many times
and it does not return to its initial position
it just twists some more :) it's very interesting IMHO 23:28
sorear That sounds an awful lot like a free group. 23:29
k23z__ sorear, well it has much to do with free groups actually
actually I will show you a braid right now, although it's not a fantastically interesting one ...
23:31 opx^on is now known as opx^away 23:32 opx^away is now known as opx^on
k23z__ i41.tinypic.com/11tlj6p.gif 23:32
i42.tinypic.com/20h7t68.png
just generated these two using some Perl5 and GD::SVG 23:33
I know Perl6 has some SVG
I was thinking I'd learn more braid theory and then render some more complicated braids
the only problem with it is that it has some rough edges that show up, I'd like to eliminate those dunno whow
*how 23:34
23:34 colomon left 23:39 envi^home joined 23:42 opx^on is now known as opx^away, opx^away is now known as opx^on 23:45 opx^on is now known as opx^away
sorear you could use GD::SVG in Perl6 23:45
23:45 opx^away is now known as opx^on
sorear the edges are rough, I'm working on that 23:45
k23z__ sorear, now ? 23:52
23:56 am0c joined
masak k23z__: sorry, I was away nomming... :) 23:58
k23z__: glad you figgered it out, though.
k23z__ masak, me too
masak time to head homewards...
23:58 nihiliad left
masak k23z__: personally, I'd love pretty images rendered by Perl 6! 23:59
here's my contribution to that: use.perl.org/~masak/journal/39152
that's SVG generated by a Perl 6 script.
'night
23:59 masak left