»ö« | perl6.org/ | 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 moritz_ on 25 June 2010.
sorear trying to code nested loops without a working last / next / redo is a bit interesting 00:00
it's like Pascal :(
00:01 Patterner left, Psyche^ is now known as Patterner 00:08 justatheory left 00:12 Trashlord joined
pugssvn r31777 | Kodi++ | [S32/Temporal] Reverted DateTime back to being mutable. I think we ought to make a big change like this only after reaching some kind of consensus to do so, not least because I just implemented a lot of mutating methods! 00:12
r31777 |
r31777 | Note that += and friends need only the *container* on the LHS to be mutable, not the valueâ'$x += 1' should be allowed whether $x holds an Int, a Date, or a DateTime.
00:13 lest_away is now known as lestrrat 00:24 timbunce left 00:25 eternaleye left
ash_ sorear: nested loops without last/next/redo end up with lots of conditionals, which makes me sad :-( 00:27
jjore_ Hi, got my speed improvement report at diotalevi.isa-geek.net/~josh/100720...akudo2.txt
apparently at the fastest, it goes 2.65x as fast. Thanks pmichaud++
Since a year ago this was taking hours or never finished, this is now a distinct improvement. 00:28
anywya, it's time for Seattle.pm & 00:29
jnthn Good to hear we've improved, even if it's still hardly fast. :-) 00:32
00:42 meppl left 00:45 eternaleye joined 00:50 skids joined 01:09 amkrankruleuen left 01:11 masonkramer joined
ingy phenny: tell masak I removed ./t/ from the PERL6LIB in the Makefile that ufo generates. TestML doesn't need it anymore, and it wasn't really "standard". 01:14
phenny ingy: I'll pass that on when masak is around.
ingy crap. ufo seems busted. 01:16
diakopter ls .. 01:18
ingy rakudo: if 'sbdfksjdh'.IO !~~ :e { say "OK" }
p6eval rakudo 278366: OUTPUT«OK␤»
ingy hmm 01:19
maybe my rakudo is stale
diakopter rakudo: if '..'.IO !~~ :e { say "OK" }
p6eval rakudo 278366: ( no output )
diakopter rakudo: if '.'.IO !~~ :e { say "OK" }
p6eval rakudo 278366: ( no output )
ingy Method 'IO' not found for invocant of class 'Str'
that's what I get locally 01:20
Tene diakopter: shouldn't that be just ~~?
rakudo: if '.'.IO ~~ :e { say "OK" }
01:20 drbean left
p6eval rakudo 278366: OUTPUT«OK␤» 01:20
ingy diakopter: github.com/masak/ufo/commit/f3e6cdd...0b69837976 01:21
our rakudo's must be old
Tene yes 01:22
ingy or, at least mine is
What are the delivery goals for Rakudo *? 01:25
I have the feeling it will feel old, a few hours after release! 01:26
pmichaud if it took you a month to arrive at that conclusion, I think we're okay :-) 01:27
ingy hahaha 01:28
pmichaud++
pmichaud: I handed my printed/signed waiver document to gwall to give to you. Please make sure that happens when you see her. 01:29
pmichaud will do.
I suspect I'll see her in the next 45 minutes or so. :-) 01:30
ingy \o/
pmichaud: I expect a commit bit in 46 mins
pmichaud that partially depends on the oscon wireless, I'd wager. Or I could tether via my phone :-) 01:31
colomon pmichaud: I just got a segfault with a very simple (but repetitive) bit of p6.
:(
ingy ufo works for me again \o/
pmichaud colomon: what's the bit of p6? 01:35
colomon something like for 1e10 ... 1 -> $i { $i.say; }
(it's 30000 lines back in my backscroll.)
01:36 plobsing joined
pmichaud it's probably making too many gc-ables 01:36
currently the series operator eats memory when iterated 01:37
sorear the Parrot GC recurses on the C stack when marking objects
pmichaud (at least that's my suspicion)
sorear so if you nest objects more than about 6,000 deep you get a segfault (i386 linux)
our iterators are linked lists
they create a nesting level of objects for each item iterated 01:38
colomon sorear: but "for" shouldn't be keeping them.
but yeah, I guess if they don't GC fast enough they effectively will be keeping them, eh?
pmichaud "for" isn't keeping them, but the GatherIter is.
sorear for is well-established to leak memory, since we don't have sink context yet
pmichaud and that too 01:39
since for goes through a ParrotIter at the moment.
(sink context isn't really an issue -- we can emulate that at any point) 01:40
colomon: ooc, does it fail if you use 'map' instead of 'for' ? 01:43
colomon map with .eager or .munch or something?
pmichaud just map
yeah, with eager.
or try .munch 01:44
.munch probably makes more sense
or repeated shift
or even... (gasp) try sink :-P
colomon .sink works?
pmichaud not .sink
prefix sink
colomon \o/
pmichaud sink (1e10...1).map({ .say }) # or something like that 01:45
01:45 whiteknight left
pmichaud anyway, the current list implementation isn't guaranteed not to leak memory yet. But at least the API isn't one that forces us to have an implementation that leaks memory :-) 01:46
afk, heading to oscon
colomon will report what happens when it happens. :)
oh, that was fast. 01:48
seg fault in about 20,000 iterations.
actual code was something like sink (1e10 ... 1).map(-> $i { $i.say }) 01:49
01:49 drbean joined, snarkyboojum left
sorear same issue 01:50
the input list is building up to segfaulty lengths 01:51
01:57 snarkyboojum joined 02:01 nimiezko joined 02:02 snarkyboojum left 02:07 nimiezko left
pmichaud yes, we likely need to clean up either gather or series or both a bit to avoid holding all of the objects. 02:08
02:09 nimiezko joined
sorear pmichaud: I still blame CallContext. 02:14
jnthn That recursive marking of CallContexts has caused us issues before too. 02:15
02:16 nimiezko left 02:17 snarkyboojum joined
sorear Parrot-land doesn't understand the fact that nulling registers after their lifetime ends is the difference between O(n) and O(1) memory usage 02:17
and my explaining skills suck too much
au|irc: I'm having a great deal of trouble adding a regex compiler to niecza; I feel as though I have the wrong factoring somewhere, or I'm not looking at a problem in the right way 02:20
rakudo: Mu.^methods.Str 02:21
p6eval rakudo 278366: ( no output )
sorear rakudo: say Mu.^methods.Str
p6eval rakudo 278366: OUTPUT«BUILDALL new Bool say print item WALK defined BUILD clone perl WHICH Capture CREATE PARROT bless WHENCE WHERE notdef ␤»
sorear rakudo: say Any.^methods(:local).Str 02:23
p6eval rakudo 278366: OUTPUT«Seq grep none values can reverse keys uniq isa map classify kv min max flat pick first minmax does rotate join Numeric elems end reduce Str all list postcircumfix:<{ }> postcircumfix:<[ ]> at_key pairs one ACCEPTS at_pos sort any␤»
dalek ecza: f0e814f | sorear++ | rxwork.pl:
rxwork: Inside a regex, use raw iterator subs for added optimizability
sorear rakudo: say Cool.^methods(:local).Str
p6eval rakudo 278366: OUTPUT«ceiling cotanh comb unpolar trim-trailing atan ord acos eval chop tanh atanh cosec chars roots uc ucfirst substr tan log10 from-radians cos fmt bytes pred acosec sinh asinh Numeric cosech trim asec trim-leading chr acotanh floor sech asech rand truncate round rindex sqrt asin
..split…
02:29 timbunce joined
dalek ecza: 03f7ce1 | sorear++ | (2 files):
Implement Mu.bless, Any.flat
02:29
02:33 ashleydev left 02:34 tylercurtis joined 02:38 agentzh joined, sorear sets mode: +oo timbunce tylercurtis 02:39 justatheory joined 02:40 masonkramer left, drbean left 02:42 felliott joined, felliott left, felliott joined 02:44 drbean joined 02:46 justatheory left 02:52 azert0x left 02:53 rgrau__ left 02:55 tedv joined 02:59 drbean left, snarkyboojum left 03:02 gbacon left
colomon rakudo: say (1...100).grep({ $_ %% 2 }).grep({ $_ %% 3 }).perl 03:12
p6eval rakudo 278366: OUTPUT«Cannot resume dead coroutine.␤ in 'Any::join' at line 1␤ in 'List::perl' at line 2528:CORE.setting␤ in main program body at line 22:/tmp/eJhgHd3XUU␤»
colomon rakudo: say (6, 12 ... 96).perl 03:13
p6eval rakudo 278366: OUTPUT«(6, 12, 18, 24, 30, 36, 42, 48, 54, 60, 66, 72, 78, 84, 90, 96)␤»
03:14 justatheory joined 03:23 zachy left, skids left 03:27 nbrown joined, jaldhar joined 03:33 drbean joined 03:34 justatheory left, timbunce left, synth left 03:36 synth joined 03:45 tedv left 03:50 snarkyboojum joined
au|irc sorear: sleeping on it might help. :) 03:54
03:56 DemoFreak left, DemoFreak joined
sorear au|irc: I'm exactly in the middle of my normal wake cycle 03:57
au|irc ah. power napping on it then :)
what's your TZ nowadays, btw?
sorear PDT.
au|irc mm nice sleep-through-noon nocturnal hacking cycle. 03:59
03:59 nbrown left 04:02 au|irc is now known as au|afk|lunch
sorear Does anybody read p6c these days? It's starting to look like our designated troll prison 04:10
tylercurtis reads it. 04:26
04:28 [Coke] joined
[Coke] blah! Hopefully the rakudo release will go smoother than the parrot one. 04:28
parrot 2.6.0 is now available for you to play with. Here's hoping there's no suprirses for the release. =-) 04:29
04:39 lestrrat is now known as lest_away
dalek ecza: 3963e68 | sorear++ | (3 files):
Stop relying on !slots, SPOT lexicals into Decl
04:45
ecza: f0c3f28 | sorear++ | (2 files):
Pass lexical types directly to CodeGen instead of using (lextypes)
ecza: 1334694 | sorear++ | CgOp.pm:
No longer need to use lextypes in CgOp foo_lex
04:46 lest_away is now known as lestrrat 04:49 markjreed joined
markjreed what's the best way to initialize a derived attribute in a class? I want the default new, CREATE, and BUILD to do their thing and then take over and initialize some other attributes based on the ones passed in. 04:50
04:54 [Coke] left, [Coke] joined
sorear markjreed: There is no default BUILD 04:55
BUILD runs after standard processing, and is entirely yours to implement 04:56
markjreed If you define a BUILD, then the auomatic paramater iniialization from named parameters doesn't happen anymore except for parameters explicitly declared on BUILD. 04:57
sorear That sounds like a bug 05:04
markjreed It seems to follow what I'm reading in S12. 05:05
However, it also prevents initialization to defaults... 05:06
And that's a bug... 05:07
rakudo: class Foo { has $.bar = "baz"; }; say Foo.new.bar 05:09
p6eval rakudo 278366: OUTPUT«baz␤»
markjreed rakudo: class Foo { has $.bar = "baz"; submethod BUILD{}}; say Foo.new.bar 05:10
p6eval rakudo 278366: OUTPUT«Any()␤»
05:14 LionMade0fLions left, markjreed left 05:16 Mowah joined, timbunce joined 05:30 synth left 05:31 synth joined 05:33 exodist left
dalek ecza: cf25c36 | sorear++ | CgOp.pm:
Remove lexget and lexput as user facing ops
05:35
ecza: a8fb8a5 | sorear++ | (4 files):
Do not require aux stacks to be predeclared
ecza: b861595 | sorear++ | (4 files):
Unify aux and let
ecza: 3aa3ff8 | sorear++ | (3 files):
Kill off lextypes for good
05:36 exodist joined 05:51 Su-Shee joined
pmichaud 04:55 <sorear> markjreed: There is no default BUILD 05:52
S12 seems to indicate otherwise.
S12:614 and S12:800
explicitly mention "default C<BUILD>"
(perhaps I'm misunderstanding sorear++'s comment.) 05:53
sorear I was speaking from memory, not with a copy of S12 open next to me
so I automatically concede this
05:56 wolo joined 06:06 justatheory joined, LionMade0fLions joined
dalek kudo: 3176182 | pmichaud++ | build/PARROT_REVISION:
Bump PARROT_REVISION to latest Parrot release. Frozen until #31 release.
06:08
06:11 tylercurtis left, uniejo joined
pmichaud interestingly, the "double gather" bug might not be a problem with gather. 06:11
rakudo: (gather { for (1,2,3,4,5).grep(* > 2).list { take $_ if $_ ~~ { $_ < 5 } } }).say;
p6eval rakudo 278366: OUTPUT«34␤»
moritz_ rakudo: say <a b c>.kv.kv.perl 06:14
p6eval rakudo 278366: OUTPUT«Cannot resume dead coroutine.␤ in 'Any::join' at line 1␤ in 'List::perl' at line 2528:CORE.setting␤ in main program body at line 22:/tmp/ap4qCsJ32q␤»
pmichaud I agree it shows up when gather is used. 06:16
but if I write the gathers directly (as opposed to in a sub/method), it works just fine.
06:16 baest joined
moritz_ it shows up when the *same* gather/take is used twice in a lazy list 06:17
which you don't achieve when writing a gather/take directly
pmichaud okay, that's possible. 06:18
looking.
moritz_ rakudo: say <a b c>.map({$_}).map({$_})
p6eval rakudo 278366: OUTPUT«abc␤»
pmichaud .map doesn't use gather, so it's not relevant.
moritz_ ok
pmichaud this is interesting
consider:
gather { @list.map({ take $_ if $_ > 2 }) } 06:19
should the statement in the gather be considered to be in sink context?
I guess gather must impose sink context on its block.
moritz_ probably
06:20 justatheory left
pmichaud ohhhhhhhhhh 06:21
I think I see the problem.
the gather statement isn't properly cloning its block.
oh wait, that's probably not it. 06:22
grrrr
sorear what was the first version to have this bug?
pmichaud hard to say -- it's been mixed up with general closure problems from the beginning.
PGE does something weird with its coroutines here... I'll try the same thing here. 06:30
06:42 eternaleye left 06:48 synth left 06:49 synth joined
pmichaud aha, it's a Parrot Coroutine bug 06:52
filing trac ticket
moritz_ damn, a bit too late to get into the parrot release :/ 06:53
pmichaud no problem, easy workaround.
PGE inadvertently worked around the bug for years :-)
timbunce what's the perl6 way to find what modules have been loaded (ie like keys %INC in p5)? 06:54
pmichaud timbunce: I don't think one has been officially spec'd.
Rakudo might have a way, though.
timbunce that would be handy
moritz_ rakudo: use Test; say %LOADED.perl;
p6eval rakudo 317618: OUTPUT«PackFile_unpack: This Parrot cannot read bytecode files with version 8.0.␤␤PackFile header failed during unpack␤»
moritz_ timbunce: try %Perl6::Module::Loader::LOADED 06:55
06:55 lestrrat is now known as lest_away
pmichaud %LOADED appears to ... yeah. 06:55
perhaps that should be a contextual or PROCESS:: variable.
or GLOBAL::
or something.
it might be interesting to distinguish "what modules have been loaded" versus "what modules have been loaded in the current lexical scope" 06:56
06:56 wolo left
timbunce say %Perl6::Module::Loader::LOADED.perl; says Method 'perl' not found for invocant of class 'Hash' 06:58
pmichaud it's a Parrot native hash and not a Perl 6 Hash :-|
(so it doesn't have a .perl method)
I suspect that needs to be reworked a bit.
(the whole LOADED part) 06:59
timbunce how can I see the contents?
pmichaud might try casting it 07:00
say (CREATE_HASH_FROM_LOW_LEVEL %Perl6::Module::Loader::LOADED).perl;
obviously that's not going to be standard Perl 6 :-|
but it might work for now
timbunce yeah! it did. pmichaud++ 07:01
sorear au|afk|lunch: ping 07:02
dalek ecza: f4addf6 | sorear++ | (6 files):
Upward type inference for let
07:07
ecza: f2668ba | sorear++ | CodeGen.pm:
Remove dup and swap fossils
07:07 daxim joined, [particle]1 joined 07:08 [particle] left
moritz_ fun. I had to reboot my currently-being-upgraded debian box, and now I have neither mouse nor keyboard in X 07:10
mathw Morning 07:11
07:13 synth left
sorear pmichaud: What did PGE use coros for? 07:15
pmichaud restarting after a successful match
moritz_ backtracking?
ah
pmichaud i.e., the code would .yield() a successful match, and invoking the coroutine would then backtrack and find another successful match 07:16
07:16 whiteknight joined
pmichaud great, the workaround that works for PGE appears not to work for Rakudo. 07:16
:-(
mathw :(
pmichaud probably due to the intermediate exception handler. 07:17
07:19 zulon joined
sorear wonders when we'll see perl6 parsers nearly as fast as perl5's 07:20
sorear sets the bar at 5,000 lines per second on his computer
07:20 mberends left 07:23 au|afk|lunch is now known as au|irc
au|irc sorear: pong 07:23
sorear au|irc: How much would it hurt your goals if the code generator were modified to generate CLR assembly directly, instead of horribly-low-level C#? 07:26
au|irc seeing I have no intrinsic goals, the answer would be not at all :)
and I get to learn one more language! (CLR assembly)
07:26 plobsing left
pmichaud +1 07:26
au|irc++ 07:27
au|irc :)
pmichaud really likes the "au" nick. It's.... golden.
au|irc why, thank you *smile*
mathw thinks that's an excellent attitude 07:28
People shouldn't be scared of learning another language 07:29
sorear or, to be more precise, I'd like to see a STD-level parser which can process a file of similar size and statistical properties to STD.pmc in under 30 seconds
07:31 masak joined
sorear 63,500 lines, 1,600,000 bytes, minimal whitespace 07:31
masak god morgon, #perl6!
phenny masak: 20 Jul 21:54Z <dolmen> tell masak I have committed my Temporal spec patch
sorear perl5 requires 1.9 seconds
phenny masak: 20 Jul 23:48Z <Kodi> tell masak gist.github.com/483792 I actually think I got the day-name stuff right the first time. At any rate, this time, DateTime-strftime.t works fine for me. If you get that problem again, try double-checking that you're using the right strftime.pm (or strftime.pir).
masak: 01:14Z <ingy> tell masak I removed ./t/ from the PERL6LIB in the Makefile that ufo generates. TestML doesn't need it anymore, and it wasn't really "standard".
sorear you have 30.
masak ingy++
Kodi: I'll apply and spectest.
au|irc mathw: well it could be scary, but it gets better with practice... it's called "desensitization treatment" or something :)
sorear o/ masak
au|irc greetings masak :)
07:31 sorear sets mode: +o masak
masak hello all you lovely butterflies. 07:32
mathw au|irc: :)
Morning masak
07:34 zulon left 07:36 Su-Shee left
diakopter sorear: plz zpl pzl use this for assemblygen: github.com/jbevain/cecil 07:39
masak zlp!
diakopter istr reading somwehere it's the most efficient to operate and expedient to adopt of them.. 07:40
"of them" referring to 1. Microsoft's System::Reflection::Emit 2. libraries wrapping (1), such as runsharp, 3. metalanguage environments wrapping runsharp, such as perlesque ;), and 4. Mono's Cecil 07:42
the github fork of cecil is supposed to contain a refactor-for-more-lightness branch somewhere or it's already merged 07:43
au|irc sorear: re the perf point, seems a large fraction of time are in the CursorBase::_tangle_edges => CursorBase::_elem_matches codepath 07:45
# audreyt.org/niecza-nytprof/nytprof/
au|irc wonders if inlining would help a bit with 539,205 calls
diakopter heh 07:46
at that point you might just package custom JIT logic for Mono to enforce such things 07:47
speaking of shipping a custom Mono... 07:48
timbunce au|irc: looking at that profile I could give some suggestions for what might help
au|irc ah, the author of the fabulous nytprof is here :) hi timbunce :)
timbunce waves 07:49
moritz_ niecza: say 1
p6eval niecza : OUTPUT«1␤»
moritz_ hum, does not report the version yet :(
pmichaud thinks more about Rakudo's double-gather bug and suddenly says... wtf?! 07:50
au|irc coheres and entangles back to timbunce
pmichaud I need a walk
bbiaw
moritz_ niecza: say 1
au|irc o/ pmichaud
p6eval niecza 3aa3ff8: OUTPUT«1␤»
diakopter pmichaud is walking at 1 am 07:51
take a torch
au|irc listens to timbunce re: what might help
masak ingy's blog post made a splash on Twitter.
timbunce au|irc: try avoiding unpacking the args: return $_[0] eq $_[1] if length($_[1]) == 1;
masak can we just keep making good noise like this up until the R* release? kthxbai 07:52
we can take turns... :)
07:52 whiteknight left
diakopter ^Z& 07:52
sorear au|irc: nytprof doesn't work very well on my computer, btw
timbunce sorear: in what way? 07:53
timbunce guesses windows
masak diakopter: I read that and went, "hm, meta-sleep?" :)
07:54 tadzik joined
sorear timbunce: linux; every single clock I choose, including MONOTONIC, seems to wind up ticking backward 07:54
timbunce are you in a vm or freebsd? (perhaps best to take this to #nytprof) 07:55
sorear no, and no
au|irc: what did you run? 07:56
mathw masak: ingy's blog post was very cool :)
sorear timbunce: can you explain the not-adding-up of that profile? 07:57
au|irc sorear: just the standard settiing compilation
masak mathw: it was.
timbunce mathw: got a url?
masak mathw: it matches a sentiment I've had for some time, but it says it better than I would have.
mathw timbunce: blogs.perl.org/users/ingy_dot_net/2...ready.html
masak mathw: I thought when pmichaud made the R* announcement almost a year ago, "heck, we're ready *now*" 07:58
I didn't think (but should have) "give us a year and we'll be awesome" :)
timbunce sorear: can you be more specific? (the 37.9 vs 21.7) 07:59
pugssvn r31778 | audreyt++ | * timbunce++ suggests we avoid unpack the args on the hottest codepath.
r31778 | This alone should save 2~3% of runtime for STD.
sorear timbunce: 37s vs 2s 08:00
pmichaud pmichaud@plum:~/rakudo$ ./perl6
> (1,2,3,4,5).grep(* > 2).grep(* < 5).say
34
sorear timbunce: nevermind, though; I misunderstood the run
moritz_ rakudo: (1,2,3,4,5).grep(* > 2).grep(* < 5).say
p6eval rakudo 317618: OUTPUT«PackFile_unpack: This Parrot cannot read bytecode files with version 8.0.␤␤PackFile header failed during unpack␤»
pmichaud p6eval fail, apparently.
dukeleto is p6eval running from a non-installed parrot? 08:01
masak pmichaud++
sorear timbunce: I thought it was a startup-shutdown test and was baffled as to why the dominating startup code was only 4%
moritz_ dukeleto: it probably just has problems rebuilding parrot automatically
dukeleto: it's installed
pmichaud > say <a b c>.kv.kv.perl
(0, 0, 1, "a", 2, 1, 3, "b", 4, 2, 5, "c")
moritz_ \o/ 08:02
ship it!
pmichaud decides to run 'make spectest' first before shpping.
*shipping
and I still want my walk. :)
moritz_ you can walk while spectesting :-) 08:03
masak ooh, an edit war in the spec!
pmichaud yes, I noticed the edit war.
masak for once I don't immediately dismiss the discussion on p6l about it. 08:04
pmichaud I think that's our first :)
masak aye.
it's an important issue.
I don't know exactly where I stand re it.
pmichaud I'm biased towards immutable, myself.
moritz_ too
masak certainly persisting a DateTime object to a database is easier when... yeah.
pmichaud but I've basically ignored the entire thread until now
after going through the problems with cursors and iterators and lists and .... I've decided that immutability will forevermore be my good friend. 08:05
masak next sensible step seems to be to dicuss immutability with Kodi++.
he's the one doing Actual Commits to Rakudo's Temporal right now.
oh, and making dolmen not feel run over is important, too. 08:06
dolmen++
08:06 mberends joined
pmichaud mberends: o/ 08:06
sorear phenny: tell diakopter Cecil appears to be a .NET assembly. I can only use tools with file-based interfaces pre-bootstrap (since I'm running on the p5vm), and ilasm seems to beat gmcs
phenny sorear: I'll pass that on when diakopter is around.
mberends o/ pmichaud 08:07
phenny mberends: 19 Jul 18:46Z <tylercurtis> ask mberends pmurias tells me you started work on a Perl 6 to LLVM compiler at some point. How far did you get? Still working on it at all? Is it available somewhere?
mberends: 20 Jul 20:47Z <masak> tell mberends when I remove (Cool-)Str.bytes, t/spec/S32-io/IO-Socket-INET.rakudo fails 10 tests. sure enough, src/core/IO/Socket.pm contains the only use of .bytes in the whole Rakudo code base right now. I'd like to confer with you re what to do with it.
masak \o mberends
frettled mberends \o/
masak EONEINAPPROPRIATEUSEOFBYTES
pmichaud I should rephrase my earlier comment.
mberends good *, #perl6
pmichaud I'm *strongly* biased towards immutable.
frettled All the cool people are here today!
masak I'm surprised I still have 'Net connectivity today. apparently my provider has a charitable definition of "one week of surf time". 08:08
pmichaud okay, definitely walk time
bbiab
frettled masak: I must confess that I've not actually read the changelogs much lately, what is the edit war about? 08:09
masak frettled: right. so.
frettled: Kodi is making (good) changes to Rakudo's Temporal right now.
mberends masak: I'd like to confer about .bytes and IO this evening, away from $work
masak as in, making spectests pass and implementing missing functionality.
mberends: goodie.
mberends: I'll be traveling this evening. I can make no guarantees about my availability. 08:10
frettled masak: That's really nice! (Kodi++)
masak frettled: dolment is arguing for changing the spec to immutable DateTimes.
08:10 xabbu42 joined
masak frettled: I told him "prepare a patch and I'll apply it" 08:10
frettled Oh. Aha. 08:11
mberends masak: np, later this week is also fine
masak frettled: I didn't tell him "apply a patch", but forgiveness applies in this case :)
frettled masak: Well, you said those words, just not in that order, and not merely those words :)
masak mberends: basically though, there needs to be a .Buf converstion in there somewhere.
mberends: I could just change it and hope for the best, but I'd like to make sure it works, too.
08:11 sorear sets mode: +ov mberends phenny
masak mberends: this is a great test for what my grant work is about. 08:12
mberends masak: yes. we must find out exactly where is the right point to convert
masak frettled: :)
mberends: it's a read, right?
mathw masak: I think we're much readier now for an R*-type release. The thing is, I think it's going to lead to enormous pressure from outside to make things go fast.
masak mberends: then the read should probably be binary.
frettled masak: thanks for the heads-up, pmichaud's comments made much more sense to me now :)
masak frettled: thanks for allowing me to summarize things :) 08:13
I hope both Kodi and dolmen will read this backlog.
frettled no problemo, camarada
mberends masak: a web server would read from a file and write to a socket. But a web client such as LWP would do exactly the opposite, so we should think about all the cases.
masak nodnod 08:14
08:15 jkva joined
mberends nice wishlist item from #dbdi : auto-compile modules to .pir and auto-refresh the .pir file if the source (.pm|.pm6) has a newer timestamp. Something to put on the post-R* discussion table in Pisa. 08:15
frettled mberends: not to forget that we'll probably have people implementing stuff that reads and writes from a socket, not necessarily the same one. 08:16
frettled settles for stating the obvious.
frettled is, after all, Grand Master.
mberends frettled: some of us need to be told the obvious, some of the time 08:17
mathw mberends: That's a good wishlist item for me :)
Juerd Going to migrate feather2 now.
frettled mberends: I believe there's a captaincy available in the Order of the Bleeding Obvious, should you want one. 08:18
mberends frettled: obviously I don't
frettled ooh, nice one :)
mberends: But back to your suggestion: that's solved with a nice Makefile and issuing the appropriate make command at the appropriate time. So when should the make command run? 08:20
08:20 meppl joined
dalek ecza: 2841e81 | au++ | STD_REVISION:
* Updating STD_REVISION to r31778 for STD.pm's perf gains.
08:20
08:26 azert0x joined
sorear au|irc: are you planning to continue chasing STD.pm perf? 08:28
dalek kudo: ac0987c | pmichaud++ | src/Perl6/Actions.pm:
Fix double-gather bug.
sorear au|irc: also, I'm releived to see that profile and see that niecza itself barely even registers :)
au|irc \o/
truthfully, I don't have a plan :) 08:29
I just saw you mentioning STD.pm perf and thought nytprof might help...
sorear I spent a few days with NYTprof a while back and managed to make STD.pm about 30% faster in total 08:30
au|irc cool!
sorear It's still 600 times slower than the Perl 5 parser
2% here 2% there isn't going to bridge the gap 08:31
au|irc wouldn't it be cool if a project can take STD.pm6 and compile it to low-level CIL assembly
oh wait, there is such a project :)
sorear that's actually my original goal. 08:32
08:32 thebird joined
pmichaud rakudo: say 1 # working yet? 08:33
p6eval rakudo 317618: OUTPUT«PackFile_unpack: This Parrot cannot read bytecode files with version 8.0.␤␤PackFile header failed during unpack␤»
au|irc so the bridge will be gapped naturally, then :)
sorear I'm expecting to get up into the 20-50x slower range once the parser is complete enough and there are some basic optimizations
but. I can only try and see 08:34
au|irc :)
08:35 sftp left, salv0 left, Lorn left, cognominal left, pjcj left, c1sung left, Tene left, sukria left, dimid_ left, mikehh left, dukeleto left
tadzik hmm, my perl6 executable stopped working after pulling: wklej.org/id/367077/ 08:36
sorear I might be able to take advantage of Parrot's lack of working threads and beat Rakudo to working data-parallel »«
:)
08:36 sftp joined, salv0 joined, Lorn joined, cognominal joined, pjcj joined, c1sung joined, Tene joined, sukria joined, dimid_ joined, mikehh joined, dukeleto joined, card.freenode.net sets mode: +o dukeleto
sorear assuming Chandon++ doesn't beat me to it, of course 08:37
au|irc sorear: interesting. does STD.pm6 itself uses parallelizable techniques?
or do you just mean userland code in general
timbunce sorear: I looked through the nytprof report and couldn't see anything worth noting. I figured someone had done some polishing. It's always possible there are logic bugs causing too much work, or places where caching would help, but they're certainly beyond me. 08:38
pmichaud sorear: I very much look forward to steali...^W learning from your experiences. :) 08:39
sorear au|irc: userland code in general
au|irc "Implementation is the sincerest form of flattery." - L Peter Deutsch 08:40
moritz_ tadzik: you need to rebuild parrot, and reconfigure and rebuild rakudo 08:41
tadzik moritz_: I pulled, perl Configure.pl --gen-parrot, make and make install
moritz_ tadzik: the parrot release implied a bump in the bytecode version number
Juerd wishes that people would tgz their disused build trees. 08:42
moritz_ tadzik: try rm -rf parrot parrot_install and then again
tadzik ok
frettled Juerd: deduplication FTW :) 08:43
masak sorear: p6c a troll prison? all I see is RT ticket emails.
Juerd frettled: ext3 doesn't do that :)
frettled: But the main problem is the sheer number of files. It makes every backup tool really slow.
frettled Juerd: and that's not the only think ext3 doesn't do :(
sorear Juerd: I have occasionally ben tempted to write a cron job to kill all the .o files on my system. I wonder how much collateral damage it would do. 08:44
Juerd Even without gz, a tar would be so much faster to copy around.
08:44 zulon joined
Juerd You don't realise that having so many small files is a problem until you make backups or want to move everything over to a new box 08:44
frettled Juerd: loopback-mounted filesystems :)
sorear Wait. What's the cool FS these days? 08:45
frettled sorear: WAFL and ZFS, still.
moritz_ sorear: btrfs
Juerd frettled: No, that'd be counter productive because then you'll be diffing huge files. Just tar those things that aren't in active use :)
sorear I thought it reverted back to extN after the Reiser backlash
moritz_ finds that he has a public_html/pugs/ and goes wtf and rm -rf 08:46
frettled moritz_: btrfs isn't cool yet, IMHO, since it's not stable
Juerd moritz_: Oh, removing is even better :)
moritz_ ah, that was probably my old git mirror
which is now on github anyway
mathw frettled: but when it is stable... :D
frettled Juerd: I don't think you'd be diffing huge files any more than with tarballs.
Juerd Yeah, we have old mirrors, old checkouts, and old everything all over the filesystem :) 08:47
frettled mathw: I have a bridge to sell you ;)
Juerd frettled: If the mtime doesn't change, you don't have to diff anything.
08:48 snarkyboojum left
frettled Juerd: the idea is to use loopback-mounted filesystems for build trees. When you're done, you're done, and there's a binary blob of a file that you _don't_ diff and don't necessarily move again. It's huge, it's hopefully a sparse file and treated efficiently as such, and easier to move around than a zillion small files. 08:48
pmichaud ...I have '.imc' files in my feather dir?!?!?! 08:49
Juerd frettled: But when you do write to it again, the huge blob changes.
frettled Juerd: but you still don't diff it 08:50
Juerd frettled: big never changing blobs > real build dirs > big changing blobs
moritz_ frettled: the problem is not the lack of technology, but the lack of care
frettled moritz_: mmm
Hmm, but there are merely 4.2 million files in /data on feather6 :)
pmichaud I fear the mental image of huge changing blobs is too much for my brane at 02h00
frettled s/6//
Juerd frettled: Sparse files aren't faster, by the way. They just take up less space. 08:51
moritz_ people could just rm -rf the stuff they haven't used for 3 months, or tar and then rm
frettled Juerd: that's kind of the point (taking up less space)
08:51 timbunce left
Juerd Using up space is not the issue here. 08:51
frettled moritz_: yup
Juerd Having a gazillion tiny files is
moritz_ svn doesn't help there :-)
Juerd Not really, no
08:52 dalek left
Juerd I deleted 4 GB of /home/*/.ccache yesterday 08:52
Ooh, nice system load on feather1 now :) 08:53
frettled How long does the backup take, anyway?
moritz_ Juerd: I'm doing a du -sch /home/*, and plan to publish the results later on 08:54
frettled Juerd: 9-10 processes in blocking wait
Juerd frettled: A full backup takes 4,5 hours
moritz_ then I should rather abort it soon :-)
Juerd frettled: An incremental backup takes almost an hour
pmichaud yeah, I'm deleting some old svn checkouts too
frettled Juerd: and what do you use for backups? 08:55
Juerd Great!
frettled: dump
frettled Juerd: aha.
Juerd: try rdiff-backup or BackupPC? All backups are incremental.
Juerd Hah.
No thanks :)
Those are enormous resource hogs. I prefer to continue to actually use the system while backups are being made.
Again, storage is not an issue at all. 08:56
A single full backup with dump is generally faster than an incremental backup with rdiff-backup, and backuppc is much worse in many respects. 08:57
frettled At work, I think a single incremental backup with rsync (which is, performance-wise, comparable with rdiff-backup) takes around 6.5 hours for around 27.2 million files. 09:00
The performance penalty is negligible on our hardware, but that's probably because it's a mid-range SMB RAID system. 09:01
09:01 pugssvn left
moritz_ has reduced his home dir to 541 files now (42M) 09:03
Juerd Thanks
moritz_ not having a pugs checkout helps immensely :-)
Juerd Damn. I copied feather3 again, when I should have copied feather2 09:04
Trashlord oh no
Juerd That was really weird, seeing "feather2" boot, and seeing all kinds of feather3 stuff.
moritz_ I hope that feather2 is pretty light (at least in comparison to feather1) 09:05
Juerd It certainly should be :)
masak ingy++'s post made Reddit! www.reddit.com/r/programming/commen...y_porting/
zulon++ 09:06
moritz_ upvotes
09:06 snarkyboojum joined
zulon hey, it's me 09:06
!
hi
moritz_ hi :-)
zulon thanks for the upvotes
masak snarkyboojum! \o/
snarkyboojum hi masak o/ 09:07
Juerd Oh, here's what happened: dump reads the fs itself, but I gave the path of a mounted filesystem (which in itself is okay). I had feather3 mounted on /mnt, and then feather2 on /mnt too. In Linux itself, this means /mnt is feather2. Dump however reads the mount table and apparently uses the *first* entry rather than the last.
moritz_ oh wow
Juerd Oh well, shouldn't take long to do it again.
moritz_ btw I read the perl 5.13.3 release announcement, and was kinda surprised to see my name in it. I don't even remember what patch I submitted :-) 09:08
frettled Juerd: oh
masak "patch amnesia"
Juerd Oh, wow, copying the real feater2 took er, 3 minutes.
09:09 rgrau left
Juerd s/feater/feather/ 09:09
moritz_ it doesn't really hold much data beside the system itself
like, one or two pugs checkouts a few small git repos
Juerd frettled: Anyway, the incrementals taking an *hour* means the downtime of feather1 will be at least an hour too, when it's being moved. 09:10
09:10 rgrau joined
moritz_ (and the pugs checkouts don't contain any built files) 09:10
pmichaud time for sleep -- bbiaw
09:11 dalek joined
Juerd Sleep well :) 09:11
au|irc g'㊰ pmichaud :)
pmichaud rakudo: (1,2,3,4,5).grep(* > 2).grep(* < 5).say; # ready yet?
p6eval rakudo ac0987: OUTPUT«PackFile_unpack: This Parrot cannot read bytecode files with version 8.0.␤␤PackFile header failed during unpack␤»
09:11 hugme joined
pmichaud ENOTYET 09:11
Juerd feather2 login:
That's better.
perl6.org works again, so it's up :)
tadzik wklej.org/id/367085/ 09:12
moritz_ hugme is also back
Juerd tadzik: Wicked prompt! :) 09:13
tadzik what do I need to do to die in the outer scope?
Juerd :)
moritz_ tadzik: in rakudo, you currently can't
tadzik oh
moritz_ you need to set a flag, and then after the try block check that flag, and die again
frettled Juerd: so it can't be done without a downtime? Hmm. :-/
tadzik yeah, that's what I thought about 09:14
moritz_ hugme: hug frettled
hugme hugs frettled
Juerd frettled: No
frettled: The downtime will be at least the time it takes to build an incremental backup.
frettled moritz_: tee-hee 09:15
Juerd And that's mostly influenced by the number of inodes in use
So that's why I'd like it if this were reduced. A lot. :)
frettled I can see that :)
sorear pff, just delete a few user accounts 09:18
Juerd I'm tempted 09:21
masak Dave Whipp suggests a 'conjugate' method on Complex.
Juerd Only a part of the users are still active
masak I'd argue that that's a case where the method might make sense on Real, too. (identity opration)
Juerd my ncdu is still running. 2.8 million files so far.
masak either that, or one chooses consistency over convenience, and forces promotion to Complex. 09:22
moritz_ masak: if you argue that way, 1.re and 1.im should also work
so I'm in favor or keeping it in Complex
masak moritz_: aye.
moritz_: thing is, his use case presupposes that it work on non-Complex, too. 09:23
so at least his expectations are aligned with Work Everywhere.
Juerd (That's a lot. feather2 has 63460 files for 1.4 GB and feather1 has 49 GB in use)
(So I'd expect the number of files to be around 2.2 M) 09:24
Haha. On feather2, most disk space is used by apt's cache :) 09:25
moritz_ I do try to keep it up-to-date once in a while, but I seldom apt-get clean
Juerd That's okay
I'm doing apt-get clean on feather now; Will kill >4 GB 09:26
moritz_ (and apt-get clean is my first reflex when a debian box goes out of disk space)
Juerd Same here :)
tadzik if my module is a module literally, not a class, how do I call its methods? Let's say I have 'module Foo::Bar' in the .pm file, now calling Foo::Bar.function() says 'method function not found for non object', Foo::Bar::function() fails even funnier. What is the right way? 09:27
moritz_ tadzik: Foo::Bar::function should work if you defined it as 'our sub function () {...}' 09:28
tadzik it's sub function is export {}
moritz_ add an our() to it
or import it, and just call function()
09:28 zulon left
moritz_ erm, 'our', not our() 09:28
sorry 09:29
tadzik oh, it's even not exported
moritz_ Foo::Bar.thing is only supposed to work on classes
tadzik Confused at line 16, near "my %a = Co"
my %a = Config::INI::parse: $test1;
masak phenny: tell Kodi this spectest run looks good. might be I should've run 'make install' last time, because this time I got "Unable to find module 'DateTime::strftime' in the @*INC directories." and 'make install' fixed that.
phenny masak: I'll pass that on when Kodi is around.
tadzik ok, works with parens
the last : was confusing it 09:30
moritz_ masak: uhm, spectesting should work without 'make install'
09:30 dakkar joined
moritz_ rakudo: say @*INC.perl 09:30
p6eval rakudo ac0987: OUTPUT«PackFile_unpack: This Parrot cannot read bytecode files with version 8.0.␤␤PackFile header failed during unpack␤» 09:31
masak moritz_: it should.
moritz_: here's what I see: lib/DateTime/strftime.pm is used by one of the spectests.
moritz_: with an unmodified PERL6LIB, @*INC points to the installed location of that module. 09:32
it does not point to lib/ in the Rakudo dir.
hence, 'make install' makes a difference.
not saying it should be that way, just that it is.
moritz_ that's something that has annoyed me for quite some time
lib/ should come before the installed location
09:33 su_penguin joined
masak does the test harness pass in the rakudo dir's lib/ ? 09:33
moritz_ nope
masak because what I observed countraindicates th... oh, good.
maybe it should.
moritz_ right
09:36 dalek left 09:37 dalek joined 09:40 cjk101010 joined
masak spectesting, I got failed tests in t/spec/S29-context/die.rakudo and t/spec/S29-context/exit.rakudo. I'll go out on a limb and assume those are unrelated to Kodi++'s Temporal patch. 09:41
sorear ok, I now have all the important pre-refactors done 09:42
moritz_ rebuilds parrot and rakudo on the p6eval server, again 09:43
masak phenny: tell Kodi patch pushed. Kodi++
phenny masak: I'll pass that on when Kodi is around.
moritz_ rakudo: 1
p6eval rakudo _: OUTPUT«../p/bin/perl6: error while loading shared libraries: libparrot.so.2.5.0: cannot open shared object file: No such file or directory␤»
09:46 su_penguin left
dalek kudo: c412170 | (Kodi Arfer)++ | (7 files):
Temporal goodness.
09:48
ecza: 4aabaad | sorear++ | (3 files):
Compile the kernel as a separate assembly in preparation
ecza: 83afb45 | sorear++ | C (2 files):
Implement CPS conversion (more precisely, partial A normal form) as a
masak Juerd: I'm down to 304M in my home folder. biggest things in there are some rakudo/parrot install that I use for November et al. 09:49
tadzik masak: you're the November guy? 09:51
moritz_ rakudo: say 42 09:52
p6eval rakudo ac0987: OUTPUT«PackFile_unpack: This Parrot cannot read bytecode files with version 8.0.␤␤PackFile header failed during unpack␤»
moritz_ WTF?
tadzik moritz_: you have to do what you told me to do :) 09:53
rm -r parrot_install and again, from the beggining
* beginning
moritz_ tadzik: and I thought I did. Which is why I'm surprised now 09:54
tadzik mysterious release
masak tadzik: yes, one of two/three. 09:57
Juerd masak: Thank you
tadzik masak: november-wiki.org/ has some broken links, they're pointing to e.g. /perl6 and this redirects (?) to /edit/perl6 which is forbidden
Juerd Oh, heh, there are some people that never read their feather mail, and don't forward it either
09:58 au|irc is now known as au|afk|dinner
masak tadzik: :( sad to hear it. I don't have the energy to work on November at present. 09:58
tadzik: I'm happy the site runs at all. either I or someone else should adopt November and fix up all the small glitches/cases of bitrot.
09:59 salv0 left 10:00 pugssvn joined, salv0 joined
Juerd Almost a million emails in audreyt's maildir. Let's see if that's cron or spam. 10:01
au|afk|dinner please feel free to rm them either way... it's not like I can backlog through ~1Mi mails :) 10:02
Juerd++ # tireless sysadminning through the years!
10:02 au|afk|dinner is now known as au|afkForReal
Juerd au|afkForReal: If it's cron, I want to remove it *and* do something about it :) 10:04
Bezig met het lezen van .... 97750/986945 (9%)
This'll take a while. afk
10:09 gbacon joined
tadzik what happened to perl6-users ML? 10:17
moritz_ it exists.
tadzik does it? Can you supply a link or something? 10:18
Haven't seen it on lists.perl.org or anywhere
moritz_ www.nntp.perl.org/group/perl.perl6.users/ 10:19
just no postings to it this month, it seems
10:22 dalek left 10:25 pmurias joined 10:28 agentzh left 10:29 gbacon left 10:31 dalek joined
masak ENOTENOUGHPERL6USERS 10:34
10:37 mikehh left
cono masak: enot (russian) - racoon (eng) :) 10:37
mathw There seems to have been an upswing in here lately... 10:44
cono does rakudo have any stuff for pack data to binary data (like pack, unpack in p5) ? 10:48
did not found pack & unpack in Str.pm
masak cono: wow. learn something every day. :) In Esperanto it's (of course) "lav-urso". :P 10:49
sorear cono: no.
masak mathw: what time-scale "lately"?
cono Any idea how to make binary protocol in rakudo now? 10:50
masak cono: if you mean binary I/O, I'm working on it. 10:52
cono: there's partial functionality already. please break it and poke me about it.
mathw masak: last few days 10:53
masak mathw: au++ is back. R* nears. there's a release tomorrow. 10:54
mathw exactly
I'm not saying I'm surprised by it
Just contrasting it against ENOTENOUGHPERL6USERS 10:55
masak mathw: who in here are *using* Perl 6, or have been in the past few days? I count you, and ingy. :P 10:56
mathw so that's two
yay! two!
timbunce has as well I believe
masak three. 10:57
mathw R* is going to trigger interest I believe
we will see more people
Tene masak: I was helping a co-worker with a Perl 6 program for work the other day.
mathw followed immediately by pressure to make Rakudo go faster
masak for the purpose of the count, writing Perl 6 code in Rakudo doesn't count. :)
Tene: ok, nice; that's four if we don't count your co-wo and five if we do :) 10:58
we probably shouldn't, since co-wo isn't on #perl6 (I suppose).
Tene Not right now he's not. Looks like he's in #parrot, though. 10:59
masak he's probably afraid to get punched in the nose. 11:00
not everybody is happy about their clown nose.
mathw but we're the Friendliest Place On The Internet(tm)
mathw -> noms
Tene #parrot has never been anything but friendly to me.
masak yes, #parrot is friendly. 11:01
#perl, both on freenode and on irc.perl.org, are odd channels to enter when one is used to the tone here in #perl6.
pmurias #perl on freenode is friendly 11:02
#perl on irc.perl.org is not a help channel 11:03
masak pmurias: I had a slightly non-positive brush with #perl on freenode in association with use.perl.org/~masak/journal/39861 11:04
cono masak: I have something like: class Record { has $!record_id; has $!length; has $!msg; method binary { ... }; }; And I need to make something pack("LLC*", record_id, length, msg);
masak pmurias: but maybe that was just asking for a fight, I dunno. 11:05
cono: you're in luck! that's in the direct path of my GSoC work.
cono: thing with .pack is that it produces a Buf, not a Str.
and Buf hasn't been completely implemented yet.
cono: but it's really nice to know that someone plans to make use of it :) 11:06
cono ic
Yeah, I need it :)
masak cono: you'll notice in the spec that .pack is somewhat under-spec'd. so I'd be happy to discuss it with someone who is used to the Perl 5 version.
nom &
Tene rakudo.org/status/ -- looks like there's a huge drop in passes recently? 11:07
cono I only foudn tthat pack and unpack is in Str
11:07 alexm joined 11:08 ChrisB joined
cono maybe pir have something like pack already? 11:08
colomon Tene: I removed something on the order of 10,000 tests from the spec test last week. 11:13
Tene Ah, trig?
colomon yes
trig gets more done with fewer tests now. :) 11:14
jnthn o/ folks 11:19
cono rakudo: use MONKEY_TYPING; class MyTime { has $!time; method ago { time-$!time }; }; augment class Int { method minutes { MyTime.new(time=> self*60 ) }; }; my Int $x = 5; say 5.minutes.ago 11:20
p6eval rakudo c41217: OUTPUT«1279709745␤»
cono wanna this feature in p6 :) (steal from ruby)
colomon \o 11:21
11:21 wallberg joined
alexm rakudo: my regex num { \d+ }; say 10 ~~ / <num> /; 11:22
p6eval rakudo c41217: OUTPUT«Method 'num' not found for invocant of class 'Cursor'␤ in <anon> at line 22:/tmp/ThLFa6hx9d␤ in 'Cool::match' at line 2352:CORE.setting␤ in 'Regex::ACCEPTS' at line 5449:CORE.setting␤ in 'infix:<~~>' at line 401:CORE.setting␤ in main program body at line 11:23
..22:/tmp/ThLFa6hx9d␤»
Tene That's extremely distasteful to me.
I really hate stuffing weird shit like that in the core classes.
alexm i've been trying szabgab prestool examples and can't get the regex working, any ideas? 11:24
github.com/szabgab/prestool/blob/ma...t#L385-389
jnthn rakudo: my regex num { \d+ }; say 10 ~~ / <&num> /;
p6eval rakudo c41217: OUTPUT«10␤»
alexm jnthn: great, so it was lacking the & 11:25
moritz_ alexm: there was a change recently of how regexes are looked up
<&num> doesn't create a named capture though; if you want that, you need <num=&num> (yes, that's ugly. Yes, that's going to get fixed, eventually) 11:26
alexm i'm planning a perl6 presentation next Thu for Barcelona.pm and was trying to getting started
moritz_ alexm++ 11:27
alexm moritz_: i read the latest perl6book pdf and the examples there are also outdated then
moritz_ alexm: yes, I know. It's fixed in the repository, but the PDF is outdated
alexm no wonder i was hammering my head ;)
moritz_ sorry about that 11:28
tadzik alexm: I had a a presentetion on Warsaw.pm few days ago :)
people amazingly turned from "ha! ha! Perl 5.20 will come out before Perl 6 even happens!" to "So, we're celebrating Rakudo Star next week, aren't we?" 11:29
alexm moritz_: don't worry, i knew i could get help on this channel but i wanted to fight it a little first
masak cono: at least .unpack shouldn't be in Str.
Juerd au|afkForReal: juerd.nl/i/3458d0fd0af74bb43337c0c2009b4260.png Disabling cron job 11:30
cono masak: method unpack, but sub unpack maybe, dunno... or in Buf
Juerd au|afkForReal: Oh, ignore previous. That was a single occurrence
masak cono: sub unpack should accept a Buf; not a Str.
Juerd juerd.nl/i/94d5003c0ea598d19a6ea298984f426f.png Any volunteers for fixing this on feather1? 11:31
alexm tadzik: care to share your slides? i'd like to mix some of gabor's examples with others
tadzik alexm: sure, but they're in Polish :)
still want? :)
alexm tadzik: no problem, google translate rocks in catalan too ;)
cono masak: maybe method Buf::unpack ?
tadzik alexm: Not sure if Google Translate can handle pdf, but there you go: tjs.azalayah.net/moje.pdf 11:32
moritz_ rakudo: say ?(3 ~~ 0 ... 4) 11:35
colomon pmichaud++
p6eval rakudo c41217: OUTPUT«1␤»
alexm tadzik: translate.google.cat/translate?hl=c...2Fmoje.pdf :) 11:36
tadzik oh, nice :
:)
images are missing though. I'm looking at an english translation and it isn't bad 11:37
watch out, it traslates 'my' to 'We' 11:38
alexm tadzik: could it be possible to have the beamer source files, so i can translate the whole presentation? i really like it 11:39
Juerd Is there any reason why I shouldn't rm -rf /home/*/.cpan/build on feather1?
tadzik alexm: sure
my LaTeX sucks though, I was learning it by writing this presentation :)
alexm: wklej.org/id/367135/ 11:40
alexm: want images too?
alexm tadzik: sure 11:41
tadzik gimme a sec
alexm tadzik: what about pushing to github and /me forking?
11:41 kensanata joined
tadzik hmm, can be 11:41
not a bad idea. Give me another sec then :)
alexm your call, tadzik, what's easier for you
tadzik makes more sense, so I'll go this way 11:42
jnthn tadzik: Nice slides! :-) 11:43
tadzik jnthn: thanks :)
11:43 dalek left
jnthn could follow quite a bit of it 11:43
tadzik alexm: github.com/tadzik/Perl6-slides I hope I didn't forgot any images 11:44
jnthn The Polish rendering of "sigil" is cute :-)
alexm tadzik: forked, thanks a lot! :) 11:45
tadzik jnthn: what do you mean? 11:46
11:47 envi^home joined
tadzik alexm: oh, the everything is a reference exapmle could be better, turned out that people didn't see nothing special in the new way. Choose something more obfuscated in Perl 5 and show how Perl 6 beatifully handles it ;) 11:47
daxim he thinks the word zmiennej is the bee's knees
jnthn Ah, I guessed "prefix zmiennej" = sigil? 11:48
11:49 dalek joined
jnthn Oh, it's just "variable prefix" or so. 11:49
tadzik yep
you can always say "przedrostek", which is almost literally "prefix"
moritz_ (looks like "prefix steak" to me :-) 11:50
tadzik but I guess "przedrostek" is more cryptic even for Polish Perlists than "sigil"
masak TimToady: Mark J. Reed is right: smartmatch on Range checks containment in that Range in Rakudo. 11:51
TimToady: even the spec says so.
TimToady: S03:3539
tadzik hmm, I feel tempted to check the specs for this BUILD thing
moritz_ masak: TimToady was talking about series, not ranges
rakudo: say 3 ~~ 1..4
masak ohohoh!
p6eval rakudo c41217: OUTPUT«1␤»
moritz_ rakudo: say 3 ~~ 1...4
p6eval rakudo c41217: 11:52
..OUTPUT«011111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111…
moritz_ rakudo: say 3 ~~ (1...4)
p6eval rakudo c41217: OUTPUT«0␤»
masak rakudo: say 3.14 ~~ 1..4; say 3.14 ~~ 1...4
jnthn tadzik: And for foreigners guessing their way through Polish. :-)
moritz_ rakudo++
p6eval rakudo c41217:
..OUTPUT«1␤0111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111…
masak er.
moritz_ masak: watch your precedence (don't know if rakudo gets that right)
tadzik jnthn: yep :)
masak rakudo: say 3.14 ~~ 1..4; say 3.14 ~~ (1...4)
p6eval rakudo c41217: OUTPUT«1␤0␤»
masak moritz_: I suspect that is right.
but it will surprise people.
Juerd Is there any reason why I shouldn't rm -rf /home/*/.cpan/build on feather1? 11:53
moritz_ well, smartmatching against a series is stupid, more often than not
Juerd: no. And please also do it for .cpanplus/build/
masak TimToady wrote in A03 that there's no way not to surprise someone sometimes re precedence.
Juerd moritz_: Good one
1;0 root@feather:/home/audreyt/Maildir# rm -rf cur new tmp
Still running...
feather's load is exploding :) 11:54
alexm tadzik: i got a weird "LaTeX Error: File `camelia' not found." message but the PDF is build ok, it seems
tadzik alexm: are you compiling with pdflatex?
moritz_ masak: I think that mark reed did something wrong when testing with rakudo (or used a horribly outdated rakudo)
tadzik I believe I pushed camelia to GH
moritz_ alexm: camelia is also in the pugs repo, in misc/
alexm tadzik: you're right, pdflatex builds fine, i was trying plain old latex ;) 11:55
daxim on tadzik's GH filename is camelia.png, not camelia, is that significant?
tadzik daxim: no, it should go like this
you just give latex the name, not the extension
moritz_ if you leave out the extension, and there are multiple files, latex picks the best 11:56
alexm moritz_: thanks, the logo is already on tadzik's repo
tadzik (I'm quite allergic to the word 'extension', but anyway)
moritz_ ie .eps for latex, .pdf for pdflatex etc.
you *can* also provide the full name
11:58 grondilu joined 11:59 ChrisB left
grondilu apt-get install perl6 ? :-( 11:59
tadzik not yet I'm afraid
Leonidas grondilu: it would rather be called rakudo
tadzik but you might have rakudo
moritz_ fedora has a package for rakudo 12:00
gerd++
Leonidas it is in experimental (an ancient version, though)
tadzik oh, by the way, moritz_, you can add CRUX in the list of distributions having rakudo in repos, to the Rakudo README
grondilu apt-cache search raduko gives nothing (and I'm on Sid )
tadzik rakudo
moritz_ tadzik: have a link to it?
tadzik moritz_: sure
Leonidas grondilu: as said, it is only in experimental, not in sid
tadzik moritz_: crux.nu/portdb/index.php?q=rakudo&a=search it's in unofficial ports though 12:01
parrot's also there
moritz_: I can write some sensemaking paragraph if You wish
grondilu ok I'll wait for it to go in Sid.
tadzik grondilu: that may take time, why not just compile it yourself?
grondilu I'm to lazy 12:02
s/to/too/
12:02 dalek left
frettled It's just about as easy as it is to install a package. 12:02
12:02 au|afkForReal is now known as au|irc
moritz_ tadzik: I think I'll add a note "the following linux distributions are known to have Rakudo in their repositories" or so 12:02
Leonidas grondilu: this will take several months, I think. 12:03
frettled grondilu: 1) git clone git://github.com/rakudo/rakudo.git
12:03 takadonet joined
frettled 2) cd rakudo 12:03
tadzik moritz_: I can write a patch for Readme, so it would make sense
takadonet morning all
frettled 3) perl Configure.pl --gen-parrot
4) make && make install
alexm grondilu: i confirm is very easy to compile rakudo and parrot in one shot
moritz_ tadzik: and there's a list on rakudo.org/how-to-get-rakudo to which I will refer
takadonet tadzik: you are still here asking questions? Wow you really love perl6 :)
moritz_ tadzik: I just don't want to clutter the README with links. It's too long already
frettled And as opposed to other "make install" animals, this one doesn't shove things in /usr/local/ by default. 12:04
mathw Mission accomplished!
Form.pm now passes all tests
grondilu thks frettled
frettled grondilu: no problem!
tadzik takadonet: I try to be more constructive and less consuming recently, but yep, I still need to ask sometimes :)
mathw Just need to push it to github when I get home and my laptop's online again
tadzik moritz_: sure thing. The link I supplied will do, CRUXers will know their way 12:05
moritz_: oh, it's CRUX, uppercase. Just saying :)
Leonidas hmm the rakudo in Arch AUR is still outdated
moritz_ tadzik: fixed
pugssvn r31779 | colomon++ | [t/spec] Add some tests for doubled gathers.
tadzik moritz_: doesn't look like to me :/ 12:06
masak I wrote a reply to the so-far only comment on www.reddit.com/r/programming/commen...y_porting/
moritz_ tadzik: maybe a caching issue
tadzik moritz_: probably, looks fine now, moritz_++ 12:07
frettled grondilu: updating the installation later is _usually_ just as easy: simply use "git pull" (no URL needed) in step 1) instead of "git clone git://…", and follow the remaining steps. 12:08
grondilu: occasionally, you may need to remove the parrot_install directory before building. 12:09
Is there anything else I've forgotten to mention?
grondilu ok thks, this comment is usefull since I don't know the "git" tool very well.
pugssvn r31780 | colomon++ | [t/spec] Some simple tests of Real.rand. 12:11
grondilu ahh it seems that I need svn.
would apt-get install subversion be fine ?
moritz_ grondilu: yes
frettled yup
moritz_ grondilu: the README has a list of debian packages that you need
works on Ubuntu too 12:12
grondilu ok, I' m installing libicu-dev and subversion 12:13
12:13 Kodi joined
frettled My only complaint is that README is in POD format, which is kindof annoying when I expect a README to be readable with e.g. "less". 12:14
colomon rakudo: say 3.1 ~~ 1...4
moritz_ well, it's still readable as plaintext
12:14 dalek joined
p6eval rakudo c41217: 12:14
..OUTPUT«011111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111…
moritz_ colomon: watch your precdece :-)
frettled moritz_: it's messy as plaintext 12:15
colomon that was somewhat unexpected. :)
frettled moritz_: I'd prefer: mv README{,.pod}; pod2text README.pod > README # :)
moritz_ rakudo: say True.succ.perl
p6eval rakudo c41217: OUTPUT«Bool::True␤»
colomon rakudo: say 3.1 ~~ (1...4)
p6eval rakudo c41217: OUTPUT«0␤»
colomon rakudo: say 3 ~~ (1...4)
tadzik Pseudo-assignment to an attribute declaration specifies the default value. The value on the right is treated as an implicit closure and evaluated at object build time, that is, when the object is being constructed (says S12)
p6eval rakudo c41217: OUTPUT«0␤»
moritz_ frettled: works for me. Just submit a patch that builds the README during 'make', and I'll apply it 12:16
tadzik so has $.required = die ("ASD") should work,no?
moritz_ right
colomon moritz_: I think True.succ ought to fail. (I think it's following spec at the moment, though?)
tadzik hmm
frettled moritz_: ok
grondilu one question : will I be able to "make install" safely ? I mean : it won't overwrite my existing perl5 installation, right ?
Juerd wolverian: Please clean your feather homedir 12:17
moritz_ grondilu: right
Kodi This issue of the mutability of DateTimes is ugly.
phenny Kodi: 09:29Z <masak> tell Kodi this spectest run looks good. might be I should've run 'make install' last time, because this time I got "Unable to find module 'DateTime::strftime' in the @*INC directories." and 'make install' fixed that.
Kodi: 09:43Z <masak> tell Kodi patch pushed. Kodi++
moritz_ grondilu: it will install into rakudo/parrot_install/
Kodi Yayness!
tadzik rakudo: class A { has $.b = die("OH NOES"); }; my $f = A.new;
p6eval rakudo c41217: OUTPUT«OH NOES␤ in <anon> at line 22:/tmp/3vHKQ5wSJT␤ in main program body at line 22:/tmp/3vHKQ5wSJT␤»
tadzik hmm
Juerd (Others who should clean their homedirs, but appear not to be on irc, are: andara, ayrnieu, nemux, fibonaci, viklund, jafelds, rafl)
moritz_ grondilu: so to use the perl6 executable, please put the rakudo/parrot_install/bin directory into $PATH
grondilu ok 12:18
Juerd I'll probably just tar those homedirs.
masak Kodi: have you backlogged? if not, I can provide you a link with the relevant backlog.
jnthn rakudo: class A { has $.b = die("OH NOES"); }; say "alive" # doesn't blow up 12:19
p6eval rakudo c41217: OUTPUT«alive␤»
moritz_ Juerd: iirc jafields is occasionally on IRC with the nick 'Wolfman2000'
Kodi masak: Yeah, I just read it.
Juerd [Coke]: I tarred your ~/sandbox
moritz_ Juerd: and rafl is on irc.perl.org.. I can contact him if you want
Juerd moritz_: Oh, please do so :)
masak Kodi: I, moritz_, and pmichaud vote for immutability. what do you think?
grondilu is doing "perl Configure.pl --gen-parrot" 12:20
Kodi masak: I'm actually not firmly against making DateTimes immutable. I just… I don't see why it would be useful. You shouldn't use DateTimes as hash keys or store them in databases; they're too big and they'll likely include functions (timezones), so they'll be difficult, at best, to serialize.
masak Kodi: the argument about container mutability doesn't quite cut it, because if the object attributes can change, then hash keys etc might be invalidated.
dalek kudo: 10a2585 | moritz++ | README:
[README] shorten section on binary packages, and refer to the website instead
12:21
Kodi masak: Yeah, there, I was just talking about +=, etc.
masak ok.
moritz_ rakudo: my $x =3; $x += 5; say $x #hey, Int is immutable too
p6eval rakudo c41217: OUTPUT«8␤»
Kodi masak: I say that when people feel themselves wanting an immutable DateTime, they should actually use an Instant.
moritz_ Kodi: the question is more, if you use the same DateTime in two places, and one of them is modified, will they be surprised to find that it's also changed in the other place? 12:22
Kodi moritz_: Good point. I guess that would be surprising. It helps that Perl 6 has a builtin clone method. 12:23
Juerd moritz_: s/DateTime/Int/, and no
moritz_: So what's so different about DateTimes that makes it okay to take away their mutability?
I think that's the correct approach to answer if immutability is a good idea :) 12:24
wolverian Juerd: will do.
moritz_ Juerd: I see it the other way round: immutability has lots of advantages
Kodi Juerd: The idea is that, currently, DateTime is actually the odd one out by its mutability. I think.
Juerd If you don't ask what's *different*, then you should at least ask the same questions for other datatimes, and perhaps even make those immutable.
s/times/types/ 12:25
12:25 nimiezko joined
moritz_ what's different is that it's harder to build the right DateTime object from the start, including timezone etc. 12:25
Kodi moritz_: What are the other advantages of immutability?
moritz_ that's why it was mutable to begin with
sorear Would it be OK for *.perl to return a Cat?
moritz_ Kodi: fewer surprises, no need to for locking in threads, easier to cache 12:26
wolverian Juerd: done.
huf a cat is fine too?
moritz_ Juerd: rafl reports on #perlde that he just cleaned up his home dir
Juerd wolverian: Thank you 12:27
moritz_: Great. Please relay my thanks :)
Kodi moritz_: I see. Largely issues at a lower level than I tend to think in. :) Well, public opinion seems against me, so I guess we should go with immutability. No guarantees I could change the the spec and the implementation in time for Rakudo *, though. 12:28
colomon sorear: you mean, for a .perl method (all .perl methods?) to return a Cat? 12:29
sorear colomon: yes
colomon my initial thought would be yes, but I'm pulling up the spec in another window. 12:30
moritz_ if a Cat works in eval() and say(), why not?
colomon okay, honestly, my initial thought was "sorear has working Cats!?!!!!"
moritz_ colomon: mine too :-)
14:29 * rafl bedankt sich bei Juerd!
12:31 bluescreen joined, goksie joined, bluescreen is now known as Guest78269
colomon S03 says "Perlish representation of any object", don't see why that would have to be a Str as long as it was Stringy 12:31
sorry, S02
Kodi masak: So long as we're all bikeshedding about Temporal, though, let me at least bring up one thought I had from the beginning. Shouldn't there be a TimeOfDay class, such that a DateTime is just a Date + a TimeOfDay? 12:32
masak Kodi: there can't be.
Kodi masak: Why not?
masak well, not with proper limit checking, at least.
and it quickly gets very tricky with time zones and stuff. 12:33
colomon though I guess the question of whether it then makes sense to return an infinite representation for an infinite list .perl is kind of weird, unless eval is smart enough to handle Cats lazily
moritz_ date length depends on the exact day
masak Kodi: I agree that the assymmetry is disturbing, but I've concluded that it has to be this way.
Kodi moritz_: But DateTime already doesn't check for leap seconds.
masak Kodi: dates can exist without times, but not the other way around.
nimiezko rakudo : my @x = 'A'..'ZZ' ; say @x.perl ;
masak Kodi: right. and whether DateTime should check for leap seconds is a tricky issue, to.
Kodi: I'd argue it should.
grondilu is running "make"
Kodi masak: Oh, boy. 12:34
masak Kodi: since it represents "civil time".
frettled masak: well, actually, time-of-day can exist without a day, but it then becomes a very basic class without any of the date baggage
nimiezko rakudo: my @x = 'A'..'ZZ' ; say @x.perl ;
Kodi masak: In fact, I've realized that whether or not DateTime recognizes them explicitly, leap seconds will need some kind of support in Perl 6, in order for Instants to work.
masak frettled: right. it's just three values.
p6eval rakudo c41217: 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", "…
masak Kodi: that is correct.
12:35 alexm left
mathw TIME IS HARD 12:35
nimiezko rakudo: my @x = 'A'..'BB' ; say @x.perl ;
masak Kodi: it's one of those "my, what have we started?" slippery slope thingies.
frettled masak: yup, which is kindof useful, but whether it's useful to let DateTime inherit from that class is something else entirely
p6eval rakudo c41217: OUTPUT«["A", "B"]␤»
12:35 skids joined
masak frettled: inherit?! heaves, no! 12:35
frettled Kodi: and it's (very nearly) all my fault ;)
masak s/heaves/heavens/
nimiezko rakudo: my @x = 'AA'..'BB' ; say @x.perl ;
frettled masak: heaves, too.
p6eval rakudo c41217: OUTPUT«["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", "AZ", "BA", "BB"]␤»
masak frettled: :)
frettled: a DateTime is not a TimeOfDate in any universe. 12:36
frettled: nor is it a Date.
frettled or a date
12:36 whiteknight joined
moritz_ Juerd: fyi, the discussion with rafl lead to tinita++ stating that her account could be removed too. I've done that now. 12:36
masak (slight lag over here. punchlines may be delayed)
colomon rakudo: my @x = 'AA'...'BB' ; say @x.perl ;
[Coke] github.com/rakudo/rakudo/commit/ac0...aa476bbce9
p6eval rakudo c41217: OUTPUT«["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", "AZ", "BA", "BB"]␤»
Juerd moritz_: Great, thanks 12:37
nimiezko rakudo: my @x = 'A'..'BB' ; say @x.perl ;
p6eval rakudo c41217: OUTPUT«["A", "B"]␤»
Kodi masak: Wouldn't it make sense for TimeOfDay to be fairly simple-minded, like Date, and have DateTime check if the combination is valid?
Juerd moritz_: I'm also removing all accounts of which the homedirs were last modified < 2008-01-01
nimiezko rakudo: my @x = 'A'...'BB' ; say @x.perl ;
p6eval rakudo c41217: OUTPUT«["A", "B"]␤» 12:38
moritz_ Juerd: +1
masak Kodi: give me a use case for TimeOfDay.
Juerd moritz_: Still pondering 2008
masak (that's also *not* a use case for DateTime) 12:39
[Coke] www.reddit.com/r/programming/commen...y_really_r
moritz_ masak: a calendar app, that schedules a meeting at 7am at certain days
Juerd read "give me a use case for TimToady" instead of "... TimeOfDay"
nimiezko hum, there is an idiosyncrasie with 'A'..'ZZ'
Kodi masak: I'm writing a module for parsing stuff like "4:15", "may 5", or "2:00 tomorrow". So you'd want parse-timeofday, parse-date, and parse-datetime functions.
Juerd ambs.tgz automatist.tgz boogie.tgz bynari.tgz castaway.tgz cognominal.tgz edenc.tgz fonkie.tgz gerrit.tgz hjertnes.tgz jjore.tgz jmb.tgz kingd.tgz lumi.tgz markov.tgz merlyn.tgz mrborisguy.tgz ovid.tgz plural.tgz pmc.tgz ppillai.tgz robkinyon.tgz ryan.tgz smash.tgz snowstalker.tgz spo0nman.tgz vladtz.tgz zigdon.tgz 12:40
masak ugh, as little parsing in core as possible, please.
Kodi masak: No, I don't mean a core module!
masak ISO-8601 yes, other things no.
Juerd If your name is in this list, your feather account has just been removed. If you want your data or account back, let me know :)
Kodi masak: I mean something you'd get with proto/pls.
masak Kodi: isn't it possible that if someone writes a time parsing module, that they'll also want their own custom Time class?
moritz_ Kodi: +1 to an external module 12:41
masak Kodi: it's a bit of "Time is so easy to implement. let's not"
[Coke] backscrolls enough to see that rakudo evalbot came back. yay, not the release.
moritz_ [Coke]: the evalbot had a problem with rebuilding and the bytecode version bump
which I basically solved with rm -rf 12:42
12:42 rgrau_ joined
[Coke] Juerd: hokay, no problems. 12:42
tadzik hmm. Reading through S12, I see that the BUILD method does not exactly the same as in Moose. Is there any easy way to do some post-creation operations, without writing BUILD yourself, initializing parameters and stuff?
[Coke] apologizes for the pasting of the cut urls from backscroll. whoops.
Kodi masak: I see the value of Temporal stuff that ships with Perl 6 as preventing people from making three different modules that do basically the same things. But yeah, parse-time could just return a (hour, minute, second) list. Or there could be an external DayOfTime module. Whatever! 12:43
masak seems we agree.
yay for list of three Ints.
you could even do a :hour, :minute, :second hash, and then pass it right into a DateTime constructor. 12:44
[Coke] figures out what a blorst is!
what a horrible name! =-)
moritz_ block or statement
rakudo: say BEGIN 3;
p6eval rakudo c41217: OUTPUT«3␤»
moritz_ rakudo: say BEGIN { 3 };
p6eval rakudo c41217: OUTPUT«3␤»
Kodi masak: Right. Well, I don't disagree *enough* to keep arguing. So let's leave it at that. :)
moritz_ BEGIN expects eitehr a block or a statement. That's what blorst parses 12:45
Kodi++ # non-bikesheddy temporal discussions
masak Kodi: choosing battles. fair enough. back to immutability, then. :)
Kodi moritz_++ # charitable interpretation of my bikeshedding 12:46
masak: Yeah. Um. I guess I'll change the spec and then submit another patch. Someday?
masak [Coke]: the name 'blorst' was even defended on p6l at one point as reminding someone of 'borscht'. :P
Kodi: submit it to me next time, and we might do a coup together by patching Rakudo at the same time. :) 12:47
jnthn omnomnom borsch
grondilu has successfully compiled perl6. Thanks !
Kodi masak: Sneaky. I like it.
12:47 grondilu left
jnthn I think at one point folks wanted to call them "blast" (block, alternatively statement) so we could have phaser blasts though :-) 12:47
[Coke] *eye roll* 12:48
I could use some borscht.
12:48 masonkramer joined
sorear jnthn: they are called blast in STD.pm6 12:48
Kodi masak: What's, like, the latest I could submit a patch and see it in Rakudo *? The 27th?
moritz_ jnthn: I think in STD.pm they are still blasts
jnthn Oh blast!
12:49 sorear sets mode: +oo moritz_ [Coke]
moritz_ Kodi: depends. We might base Rakudo Star on the compiler release from this Thursday 12:49
masak Kodi: might be tomorrow. might be 27th.
[Coke] needs to do a dry run of the release tonight. 12:50
to avoid the issues he had with parrot. :P
Kodi Hm. Well, I guess we'll see what I can do.
frettled moritz_: patch coming up, just double-checking
masak [Coke]: issues?
mathw needs to write some documentation
[Coke] masak: mainly that my laptop is slow, and to do the release, I had to build about 4 times, and fulltest 2x. 12:53
12:53 goksie left
[Coke] made everything bumpier. 12:53
mathw ouch
[Coke] (once in build dir, once from tarball, extra builds for stupidity and rebuilding the PBC files.) 12:54
still, it was all just following directions.
perhaps we could write a release bot. =-) 12:55
12:55 Kodi left
masak releasebot++ 12:58
[Coke]: now you've conceived it. the thought cannot be un-thunk :) 12:59
13:00 goksie joined
masak so, what's the plan for the next blog post to make reddit, after "Perl 6 10 years" and "Rakudo really really release ready"? :) 13:01
jnthn
.oO( is unthunking a type of optimization, like inlining? :-) )
mathw "Rakudo * Released"
masak we have time to squeeze one or two in before Rakudo Star releases.
daxim DOMINATE ME PERL 6 comes out of the closet?
masak daxim: I giggle each time I see that guy's comments.
it's immature and unnecessary, but I find it funny, too.
daxim it's a game of chicken who will lose his cool first 13:02
frettled masak: "Rakudo really released, like, really Perl 6, now" 13:04
13:04 smash__ joined
pmurias jnthn: removing thunks speeds the code up 13:04
frettled oops, forgot the star.
smash__ hello everyone
masak frettled: you mean for tomorrow? that feels slightly disingenious. 13:05
oh, star.
moritz_ smash__!
masak frettled: yeah, but before that?
13:05 dalek left
masak I want to whipe Reddit into a frenzy for Rakudo Star. :P 13:05
frettled masak: oh. "Rakudo development folds"?
masak smash__! \o/
13:05 goksie left
masak frettled: would that be like, small brochures, or a foldable table or something? 13:05
frettled masak: perhaps the wrong effext? ;) "How Rakudo * stole Christmas" 13:06
Americans love Dr. Seuss references, right?
smash__ masak++ # Perl 6 anniversary post 3tl5.sl.pt
masak smash__: thanks :)
frettled: I like the way you're thinking :) 13:07
13:07 goksie joined
tadzik oh, jnthn, folks on the workshop were asking: does Zavolaj work for C++? 13:08
jnthn masak: Did you mean whip? ;-)
masak jnthn: oops, yes. whip. 13:09
13:10 [particle]1 is now known as [particle]
jnthn tadzik: Well, it just knows how to look up symbols and call them. I guess the problem in C++ is they're name-managled. 13:10
tadzik mhm
jnthn tadzik: Anyway, I didn't try it and I'm not aware of anyone else who has.
tadzik: There's also the issue that I know rather little about C++ :-)
tadzik :) 13:11
jnthn masak: Wonder if a "Ten handy built-ins you can try out in Rakudo *" thing could work...like pick some interesting ones.
Like .pick, .classify, etc
Maybe too boring though 13:12
masak with the right spin, not too boring.
daxim check my reply for factual correctness: use.perl.org/comments.pl?sid=44971&cid=72181
masak but you'd need to call it something like "Why Perl 6 kicks butt: 10 builtins"
moritz_ maybe not ten... strains the average redditer's attention span too much 13:13
masak five :)
moritz_ pick, classify, sort (with its automagic translations...)
still 2 missing
13:13 uniejo left 13:14 hugme left
jnthn Worth mentioning with sort this breifly that min and max are also magical in the same way 13:14
sorear decides CIL - and with it having to do all type resolution myself - is too much work for too little gain
13:15 synth joined
sorear decides multisubs are necessary soon, in the name of infix:<~> 13:15
pmurias niecza: say 1+2 13:16
p6eval niecza 3aa3ff8: OUTPUT«error CS0006: cannot find metadata file `Kernel.dll'␤Compilation failed: 1 error(s), 0 warnings␤"gmcs /r:Kernel.dll /r:Setting.dll Program.cs" unexpectedly returned exit value 1 at (eval 445) line 13␤ at niecza_eval line 44␤»
au|irc praises decisive decisions in general :)
13:16 pmichaud left
sorear oh dear. 13:17
takadonet niecza: say 'omg'
p6eval niecza 3aa3ff8: OUTPUT«error CS0006: cannot find metadata file `Kernel.dll'␤Compilation failed: 1 error(s), 0 warnings␤"gmcs /r:Kernel.dll /r:Setting.dll Program.cs" unexpectedly returned exit value 1 at (eval 445) line 13␤ at niecza_eval line 44␤»
pmurias mildew: say 1
13:17 pmichaud joined
p6eval mildew: ( no output ) 13:17
pmurias :(
takadonet rakaudo: say 'plz work'
13:17 masonkramer left
pmurias sorear: how's you App::Persistent replacement doing? 13:18
13:18 au|irc is now known as au|zzz, wolverian left
masak moritz_: I really like max= 13:18
sorear pmurias: you've addressed the showstopper issues with App::Persistent, now I'm waiting for the non-showstoppers to be resolved
takadonet rakudo: say 'need to stop doing stupid mistakes....'
p6eval rakudo 10a258: OUTPUT«need to stop doing stupid mistakes....␤»
13:18 wolverian joined
masak moritz_: also, infix:<Z> and infix:<X>. 13:19
13:19 proller left
moritz_ masak: I kinda like Z=> 13:19
sorear moritz_: what's the most recent cron build error for niecza?
masak moritz_: oh, indeed.
moritz_: that's the operator we didn't know we needed :P
frettled moritz_: patches away 13:20
moritz_ masak: it was always available as >>Z<<, which was ugly
pmurias sorear: what are the non-showstoppers?
masak yet another blog post name suggestion: "Here's why you will drool over Perl 6: a couple of built-ins"
moritz_ frettled++
masak moritz_: er, >>[=>]<<, right?
moritz_ masak: right
frettled masak: s/Perl 6/Perl 6 and Rakudo */ ?
moritz_ sorear: it pulled, had some upated, then
masak frettled: right, thanks.
moritz_ gmcs /target:library /out:Kernel.dll Kernel.cs 13:21
Already up-to-date.
gmcs /target:library /out:Kernel.dll Kernel.cs
masak frettled: and we end with "it ships Tuesday".
moritz_ re-running make now
masak wow, that's a pretty nice concept actually. almost not works, just code examples for each cool thing. and at the bottom, "it ships Tuesday".
jnthn I hope it works. :P
masak we should totally check that. 13:22
jnthn masak: Sounds nice way to end it
And yes, code focus
frettled masak: yep, really nice concept
masak writes it
jnthn masak++
frettled (++)++
masak recursion++
smash__ recursion can be evil
13:23 Juerd left, Juerd joined, whiteknight left
moritz_ there's nearly nothing that can't be evil 13:24
13:24 su_penguin joined
masak smash__: I think recursion has a mostly bad rep because of the possible infinity. people don't like looking down a well and seeing the Infinite stare back at them. 13:24
[Coke] strokes his goatee.
13:25 Maddingue left 13:26 su_penguin_ joined
smash__ masak: true 13:26
13:26 nothingmuch joined, dalek joined 13:27 rgrau_ left
frettled masak: sub recursion() { recursion++ } 13:27
masak frettled: :) 13:28
13:28 Maddingue joined
masak frettled: so *that's* why recursion never got any karma... 13:28
frettled Exactly!
moritz_ niecza: say 1 + 2 13:29
p6eval niecza 4aabaad: OUTPUT«3␤»
13:29 tadzik left 13:30 su_penguin left
sorear moritz_: Huh. Is it something I could fix? 13:30
moritz_ sorear: no idea. I pulled again, ran make again, it worked. 13:31
13:31 dalek left 13:32 knewt2 left
mathw likes recursion, but then he did learn it as a Haskell programmer 13:32
masak dan++ in Januray 2003: "the big problem is the rebirth of Threads That Will Not Die on perl6-language, rising from the slightly damp outline of the horse pounded into the pavement." www.sidhe.org/~dan/blog/archives/000116.html 13:33
mathw :) 13:34
Mind you, back then I probably wasn't helping
I remember some discussions about the thing that eventually ended up being <...> and «...»
masak <...> and «...» have that "strangely consistent" feel to it. they parallel ' and ", and q[] and qq[]. 13:35
13:37 dalek joined
moritz_ should we force uniform URLs for perl6.org, ie redirecting www.perl6.org to perl6.org (or the other way round)? 13:37
masak moritz_: what's the disadvantage of not doing that?
sorear What about sandbox.rakudo.de? 13:38
moritz_ masak: nothing drastic, just not having a 1-to-1 mapping for URL and content 13:39
mathw masak: yes I remember liking that parallel very much at the time. I still do :)
moritz_ sorear: try.rakudo.org is more or less being worked on
13:39 ash_ left
masak if I have %h = foo => [1, 2, 3], bar => [4, 5, 6], baz => [7, 8, 9]; and I do %h{*}[1], what should I get? 13:40
daxim yes, set up such a redirect, and the "other way around", please; i.e. get rid of www.
moritz_ masak: a dispatch error, probably 13:41
I kinda expect %h{*} to return the whole hash
not jus the values
13:42 liev joined
masak right, so there's no XPath-like branching of indexing going on. 13:42
moritz_ maybe that expectation is wrong, though
liev is Juerd
(abusing a bot)
masak same for arrays I guess.
liev Does anyone currently have a shell on feather? I can't log in and wonder what's going on.
moritz_ not 13:43
13:43 tadzik joined
moritz_ masak: might be worth checking S09 (and/or TimToady) though 13:43
13:43 uniejo joined
moritz_ liev: looks like high system load 13:43
masak moritz_: nod.
[Coke] liev: I got prompted for a password on ssh... and mistyped it and now it's hanging.
liev How high? :)
[Coke]: That's about as far as I get, only I used the right password ;) 13:44
moritz_ used ssh key, and is also hanging on login
which is what typically happens if there's much disc IO going on
liev I left it running with the rm -rf of audreyt's Maildir, and a tar
13:44 knewt2 joined
liev It's pretty broken if it can't handle even that 13:45
sorear Wait.
According to STD, ~ has list associativity
How does multi dispatch work for a call like that?
masak moritz_: seems the implicit rule in S09 is that there might only be a run of * indexings at the very end of a chain of indexings.
moritz_: and it's unclear whether this goes only for [;;;] or for [][][] too. 13:46
moritz_ masak: ... unless you use **, presumable
masak right.
moritz_ s/e$/y/
frettled liev: ouch, I logged out earlier, although I usually stay logged in. 13:47
liev: I get the MOTD, but it's not provided me with a prompt yet.
liev My ssh just gave up
Write failed: Broken pipe
But my irssi is still running and replies to pings.
mathw rakudo: my @a = <a b c>; my @b = <1 2 3>; my @c = <A B C>; (@a Z @b Z @c).perl.say; 13:48
p6eval rakudo 10a258: OUTPUT«No applicable candidates found to dispatch to for 'infix:<Z>'. Available candidates are:␤:()␤:(Any $lhs, Any $rhs)␤␤ in main program body at line 22:/tmp/MBMl4IO1_K␤»
mathw Q: is that supposed to work, if it's not, is it known?
liev Quick poll: should I reboot feather?
moritz_ masak: yes
liev: I don't mind. The subversion is still responsive 13:49
liev The current problem is so weird :)
Some things work, some don't.
frettled maybe the root disk is flaking out 13:50
Nothing's happened with my ssh login in four minutes.
liev frettled: feather1 is a virtual machine. It runs on feather0, which still works perfectly 13:51
It's not even doing that much with its disks at the moment.
It's reading at about 1.5 MB/s and writing at 0.5 MB/s
frettled liev: was that a xen based thingy? I've seen xen flaking out like that occasionally here, too.
liev Yes
frettled It's one of the reasons I've never put it into production.
liev I've never seen something like this before
frettled It happens once every few months with the remaining VM I'm running. 13:52
13:52 dalek left
liev Hm 13:54
13:54 snarkyboojum left
takadonet rakudo: my @a = <a b c>; my @b = <1 2 3>; (@a Z @b).perl.say; 13:54
liev Okay, dalek's ping timeout convinces me to reboot feather
p6eval rakudo 10a258: OUTPUT«("a", "1", "b", "2", "c", "3")␤»
liev /dev/xvda2 has gone 280 days without being checked, check forced. 13:55
moritz_ fun. 13:56
frettled heh
liev: perhaps a minor tune2fs -i 0 -c 0 is appropriate ;)
liev Nah, these checks exist for a reason
frettled yes, to delay boot times ;)
liev I think that's okay, once every this many days. 13:57
13:57 pmichaud left
liev /dev/xvda3 has gone 280 days without being checked, check forced. 13:57
frettled But that's one of the really nice things about VMs: you can fsck a copy of the disk image while the image is running elsewhere.
liev That *could* be done, yes.
13:58 felliott left, Juerd left 13:59 dukeleto left, PerlJam left
liev frettled: fsck found errors and corrected them. The check is useful. 14:00
14:00 pmichaud_ joined
pmichaud_ good morning, #perl6 14:00
liev Hi pmichaud_
mathw oh hai
colomon o/
liev I'm Juerd, abusing an irc bot.
colomon double gather!!!! \o/ 14:01
mathw rakudo: my @a = <a b c>; my @b = <1 2 3>; my @c = <A B C>; (@a Z @b Z @c).perl.say;
moritz_
.oO( is bot abuse a criminal offense in .nl? )
liev pmichaud_: feather crashed under heavy load; exact cause is unknown. It's fsck'ing now.
p6eval rakudo 10a258: OUTPUT«No applicable candidates found to dispatch to for 'infix:<Z>'. Available candidates are:␤:()␤:(Any $lhs, Any $rhs)␤␤ in main program body at line 22:/tmp/XkcSJs7NTU␤»
frettled liev: depends on the circumstances. When you have a filesystem that needs to be running all the time, there is no time for an fsck during reboot, unless it's a very small filesystem.
liev frettled: This is not the case.
pmichaud_ liev: I figured something like that was the case. 14:02
frettled liev: not in the case of feather, no, but in the case of multi-terabyte filesystems, fsck can take _days_ to complete
…so I personally prefer filesystems where the consistency checks are not based on fsck. Unfortunately, I don't get to play with them. :( 14:03
sorear no such beast exists
frettled sorear: WAFL and ZFS
colomon rakudo: my @a = <a b c>; my @b = <1 2 3>; my @c = <A B C>; ((@a Z @b) Z @c).perl.say;
p6eval rakudo 10a258: OUTPUT«("a", "A", "1", "B", "b", "C")␤»
sorear frettled: if you think they don't use fsck, you're misunderstanding it 14:04
modern file systems do not need fsck *after power failures*
frettled sorear: They don't use fsck as we understand it with ext{2,3}, no.
sorear if you want to get a disk running after uncharacterized data corruption? yes, fsck time
your fs driver is crashing and you suspect data corruption? fsck 14:05
frettled ZFS doesn't have an fsck-like utility.
ZFS does, however, perform online autocorrection for some categories of data corruption. 14:06
For more info, see e.g. hub.opensolaris.org/bin/view/Commun...ikeutility
sorear autocorrection and consistency checks are not the same thing at all 14:07
frettled But as opposed to what we normally understand with "fsck", ZFS' "scrub" doesn't need to take the filesystem offline.
sorear: quite.
The point is that WAFL and ZFS are different beasts from those filesystems we run "fsck" on. 14:08
14:08 dalek joined 14:12 PerlJam joined
pmichaud_ verifies that he did land in #perl6 and not #fswars 14:12
frettled (and sure, there are tools for WAFL to run a more or less complete filesystem integrity check, which was used to be called wack, now wafl_check or something like that)
14:12 tylercurtis joined
frettled pmichaud_: there's a war? :) 14:12
moritz_ just an armed negotiation :-) 14:13
14:13 roy_ joined
liev Geen idee wat de hostname voor 0x77270588(119.39.5.136) is 14:13
frettled Why, there is hardly any threat of mutual total destruction at all. 14:14
liev: inetnum: 119.39.0.0 - 119.39.255.255
netname: UNICOM-HN
descr: China Unicom HuNan province network
e-mail: [email@hidden.address]
</spam>
14:15 roy_ left
sorear hmm. builds are taking much longer now, not sure when this started. 14:17
14:17 Juerd joined
Juerd frettled: Multi-terabyte filesystems are a flawed design. 14:18
frettled Juerd: maybe :) 14:19
14:20 liev left
Juerd Oh. 14:20
Did I just start irssi without screen? :(
dalek ecza: 5e3712d | sorear++ | (3 files):
Move RAWCREATE to CgOp for a considerable improvement in lazy list speed
14:20 Juerd left, Juerd joined 14:22 plainhao joined
Juerd Apparently, deleting files is Hard. 14:23
185k files left to delete 14:25
frettled It's not hard, but it's one of the more resource consuming operations in ext3.
moritz_ it's even worse on xfs, IME
frettled IIRC, ReiserFS touted quick file deletion. 14:27
The problem in ext3 and XFS is — again, IIRC — that file deletion is a forced synchronous operation. 14:28
ext4 is supposed to have a more efficient inode organization, which also allegedly speeds up file deletion. I haven't tested it yet. 14:29
Juerd ext4 is faster for several operations
But I won't use it in production until dump supports it.
frettled See, now, there's an advantage to using rsync-based backups ;) 14:30
Juerd Yes, it works with any filesystem.
frettled almost any :)
Juerd That flexibility is expensive
14:31 pmichaud_ left
Juerd dump accesses the raw device 14:31
frettled if you have a raw device, that is 14:33
At work, we use rsync because of needed flexibility: the ability to more or less easily restore individual files, or sets of individual files.
Juerd Block device, not the actual bare metal :)
frettled And the backup server handles roughly 90 million inodes in 7.5 hours from three different fileservers without any performance hiccup on the fileservers. 14:34
Juerd I make a feather backup every 6 hours :)
frettled but of far fewer inodes than 90 million, I imagine
PerlJam rakudo: say 3 ~~ 0...4; 14:35
moritz_ at $previous_work we used an IBM storage manager for backup. Because... dunno. You didn't ask such questions $previous_work :-)
p6eval rakudo 10a258:
..OUTPUT«011111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111…
moritz_ PerlJam: watch your precedence
Juerd frettled: Yes.
frettled moritz_: heh
PerlJam moritz_: aye. But surely that result is a bug
moritz_ PerlJam: I kindly disagree. It behaves exactly as specced
might be specbug, though 14:36
it's a False as first argument
calls .succ on it
gets True
calls .succ on it
gets True
etc.
and each time it compares with cmp, and finds that it's smaller than 4
so it continues, faithfully
frettled Juerd: but I'd really prefer to do it with COW :) 14:37
sorear well, there's a specstupid here in that Bool as an enum silently coerces to Int
14:37 baest left
moritz_ no, it does not 14:37
it just compares like an Int
frettled Aha, so precedence is, pseudo-ish, like this: say (3 ~~ 0)...4 14:39
PerlJam frettled: yep
3 ~~ 0 is a Bool, and all of what moritz_ said happens
frettled That's a nasty precedence surprise.
masak decommute & 14:40
14:40 masak left
moritz_ frettled: not really. How often do you smart-match against a series, which doesn't do what you want anyway? 14:40
ok, nasty, but not often occuring 14:41
PerlJam moritz_: how easy is it to confuse ... with .. ?
14:41 mmcleric_ joined
moritz_ PerlJam: I don't. I don't know about others. 14:41
14:41 tylercurtis left
moritz_ it's like, not the same thing to me 14:41
PerlJam moritz_: sure ... but you know what you're doing :) 14:42
moritz_ I know that perl 5 was more forgiving in this respect
14:42 mmcleric_ left
moritz_ PerlJam: that's news to me :-) 14:42
14:42 mmcleric_ joined 14:43 mmcleric left, mmcleric_ is now known as mmcleric
frettled The surprise is probably in that .. has precedence over ~~, which has precedence over ... 14:43
PerlJam or, as I see it, from a newbie's perspective, the difference between 3 ~~ 0..4 and 3 ~~ 0...4 is *quite* surprising.
frettled …and I now see that the HTML cheatsheet draft somehow has lost the ~~
14:43 paul1234 left
PerlJam This is one of those "different things should look different" areas for me. (And a single extra dot isn't different enough) 14:44
moritz_ PerlJam: welll, even 3 ~~ (0...4) is going to surprise them
TimToady ahem :)
it surprised me
moritz_ also 3.4 and 3..4 is quite different
PerlJam TimToady: indeed! :)
moritz_ and it's also just one extra dot 14:45
TimToady nevertheless, I don't see how it can change from what it is
.. operators on two scalars
PerlJam moritz_: you got me there :)
TimToady ... operates on two lists
moritz_ it's programming. Every character counts. Period.
Juerd moritz_: Whitespace 14:46
moritz_ Juerd: also counts. Good point.
Juerd moritz_: But *more* whitespace doesn't do anything.
(Fortunately!)
sorear TimToady: Should ~ work on Cats?
moritz_ except when it does
like, in quotes
Juerd moritz_: It doesn't. One or five hundred spaces, it's the same thing.
moritz_: Whatever is in quotes, has hardly anything to do with programming.
14:47 dalek left
TimToady sorear: anything you do on a string that doesn't require knowing where the end is should work on a Cat 14:47
Juerd moritz_: It's just data that you never bothered to put elsewhere :)
sorear TimToady: STD specs that ~ has list associativity... how would that look as a Str/Cat overload?
cono TimToady: add please time methods to Int class, like in ruby :) 14:48
rakudo: use MONKEY_TYPING; class MyTime { has $!time; method ago { time-$!time }; }; augment class Int { method minutes { MyTime.new(time=> self*60 ) }; }; my Int $x = 5; say 5.minutes.ago
TimToady fortunately ~ is one of those operators where left assoc and list assoc come out to the same thing
p6eval rakudo 10a258: OUTPUT«1279722205␤»
pugssvn r31781 | jani++ | ~~ had mysteriously transformed into ~, fixified
wolverian is annoyed that he can't link to e.g. the infix:<...> in S03 directly
TimToady so if you see a cat in the list, you just go lazy, I suspect
moritz_ Juerd: (iirc) more whitespace counts in the closing delimiter of a heredoc
sorear TimToady: so, type dispatch inside the slurpy-loop? 14:49
TimToady or just allow create a cat of cats/strs
Juerd moritz_: That's still within quotes as far as I like to interpret it.
sorear TimToady: oh, and always return a cat?
moritz_ Juerd: we could spend hours discussing that point
14:50 knewt2 left, knewt2 joined, dalek joined
avar Are those test suite -> synopsis link thingies still being maintained (what are they called?) 14:50
TimToady sorear: if our strings were implemented as ropes, that's how it'd all work out anyway 14:51
avar there was a webapp somewhere that generated the synopsis with those backlinks, is that still up?
moritz_ avar: smartlinks. MOnstly maintained
avar: perlcabal.org/syn/
TimToady shower &
moritz_ ie once every few month I update the let
frettled shower duck?
avar ah, thanks 14:52
frettled heads home, but idles loyally. 14:53
14:55 mmcleric_ joined, mmcleric left, mmcleric_ is now known as mmcleric 14:57 zulon joined
PerlJam the precedence problem with 3 ~~ 0...4 would be more obvious I think if the LHS of ... needed at least 2 items. 3 ~~ 0,1...4 (at least the comma makes me want to ask about the precedence or put parens in to force it) 14:58
sorear TimToady: Are &infix:<~> and &cat synonymous? 14:59
15:00 felliott joined 15:02 alester joined 15:05 stepnem left 15:06 justatheory joined, kensanata left
Juerd moritz_: Definitely 15:06
tadzik how come "Method 'postcircumfix:<{ }>' not found for invocant of class 'Proxy'" appears after changes in the grammar? 15:07
TimToady sorear: I suppose they could be
15:07 justatheory left
moritz_ tadzik: probably an array or hash lookup failed 15:08
TimToady sorear: you have to understand that Cat was a massive handwave (and the rest of is wasn't, he asks? :)
tadzik ah, ok
Juerd Oh, .co was opened up 15:10
TimToady PerlJam: we can probably outlaw boolean tests on unparened list infixes, and catch most of those errors
Juerd Prepare for a new wave of phishing
(example.co/mindex.asp)
15:12 pmurias left 15:13 cono left
tadzik token dummyline { \s* <comment>? \n } -- shouldn't '\ 15:13
…shouldn't '\n' be fitting this?
moritz_ rakudo: say ?("\n" ~~ / \s* <alpha>? \n/ ) 15:14
p6eval rakudo 528bf6: OUTPUT«1␤» 15:15
PerlJam tadzik: paste the whole code?
moritz_ and it does
tadzik nopaste.snit.ch/22193 15:16
in token toplevel, if I change [ <dummyline> | \n ]+ parsing starts to fail
…if I change to <dummyline>+
sorear TimToady: that handwaveness is starting to become clear. I can definitely make it run, but I'm not sure I can make it run quickly without a lot more thought, so I'll shelve it for now
tadzik PerlJam: any ideas? 15:19
PerlJam tadzik: I don't have a clue about that at the moment, but "token keyval" looks like it really wants to be "rule keyval" and be rid of those \s*
moritz_ <![;]> looks suspicious - should be '-' instead of '!' 15:20
and looks like you should put dummyline and comment into a custom ws token 15:21
tadzik moritz_: <![;]> is 0-width, no? 15:22
moritz_ std: /<![;]>/ 15:23
p6eval std 31781: OUTPUT«ok 00:01 116m␤»
moritz_ tadzik: yes, but not a character class... uhm, I'm surprised
tadzik pmichaud told me about this yesterday
moritz_ hm
tadzik and what do you mean, custom ws token?
moritz_ maybe I'm wrong after all
if you have a 'rule something { ... }', all the whitespaces in that rule are notionally replaced to a call to <.ws> 15:24
the default ws token is { <!ww> \s* }, where ww means "within word"
tadzik hmm 15:25
sorear TimToady: What's the difference between WHO and HOW?
moritz_ but in a grammar, you can provide your own ws rule, matchinig spaces, comments etc.
tadzik comments can't appear before keys, so they're not so good as ws tokens
moritz_ so
[section]
#foo 15:26
bar = baz
is forbidden?
erm, s/#/;/
tadzik nope. But ;foo bar = baz cannot be
moritz_ tadzik: then change your comment rule to include the newline
tadzik at the end?
moritz_ yes
tadzik hmm, makes sense
moritz_ token comment { \; \N* \n }
or ';', whatever you prefer 15:27
tadzik I can get rid of dummyline eventually
PerlJam tadzik: I'd probably make that one a rule too
(comment)
tadzik ETOOMANYCHANGES, lemme fix this 15:29
PerlJam (but that's assuming you don't go with the custom ws rule like moritz_ said)
moritz_ it's exactly what custom ws rules are for :-)
tadzik ah snap, I was running tests with old rakudo 15:30
hope it didn't change much
jnthn back 15:31
moritz_ welcome back jnthn
jnthn: did you have any success with zavolaj? 15:32
jnthn moritz_: No - last night I needed to work on some urgent-ish $dayjob things. 15:33
moritz_: Can look this evening.
moritz_ ok
colomon just needs to keep telling himself the purpose of p6l is to keep the dreamers from actually touching the language.... 15:34
jnthn lol! 15:35
15:36 hugme joined
moritz_ hugme: add kthakore to ilbot 15:36
hugme hugs kthakore. Welcome to ilbot!
Juerd Just so you know: backups have been disabled on feather1
So be careful ;) 15:37
They'll be re-enabled after migration
sorear so I need to remember not to sudo rm -rf /
gotcha
15:37 sorear sets mode: +ov Juerd hugme
Juerd Interesting way of shooting the messenger... +o... 15:38
15:40 proller joined 15:41 zulon left 15:47 macroron joined
colomon rakudo: say (1 ... *) Z~ ('a' ... 'z') 15:55
p6eval rakudo 528bf6: OUTPUT«1a2b3c4d5e6f7g8h9i10j11k12l13m14n15o16p17q18r19s20t21u22v23w24x25y26z␤»
colomon \o/ # still happy that works now 15:56
takadonet wow 15:57
moritz_ too 15:59
and my favorite operator:
my %h = ('a' ... 'z') Z=> (1 ... *); say %h.perl 16:00
rakudo: my %h = ('a' ... 'z') Z=> (1 ... *); say %h.perl
p6eval rakudo 528bf6: OUTPUT«{"f" => 6, "g" => 7, "h" => 8, "i" => 9, "j" => 10, "k" => 11, "l" => 12, "m" => 13, "n" => 14, "o" => 15, "p" => 16, "q" => 17, "r" => 18, "s" => 19, "t" => 20, "u" => 21, "v" => 22, "w" => 23, "x" => 24, "y" => 25, "z" => 26, "a" => 1, "b" => 2, "c" => 3, "d" => 4, "e" =>
..5}␤»
moritz_ rakudo: my %h = ('a' ... 'z') Z=> (1 ... *); say 'f o o'.subst(/<alpha>/, { %h{~$_} }, :g); 16:01
p6eval rakudo 528bf6: OUTPUT«6 15 15␤»
jnthn rakudo: ([>>R~<<] ['a' .. 'z'], [ 1..26 ]).perl.say # because I can, dammit
p6eval rakudo 528bf6: OUTPUT«["1a", "2b", "3c", "4d", "5e", "6f", "7g", "8h", "9i", "10j", "11k", "12l", "13m", "14n", "15o", "16p", "17q", "18r", "19s", "20t", "21u", "22v", "23w", "24x", "25y", "26z"]␤»
moritz_ lol 16:02
colomon sure, grandpa, just keep on using those old hyper ops....
moritz_ if you do a R* in the operator...
takadonet so everyone is showing off their Perl 6 Kung fu?
jnthn colomon: :P
moritz_ takadonet: feels more like show dance to me
Juerd R?!
moritz_ reverse
rakudo: say 2 R- 5
p6eval rakudo 528bf6: OUTPUT«3␤» 16:03
takadonet ?
colomon rakudo: say 2 R~ 5
p6eval rakudo 528bf6: OUTPUT«52␤»
takadonet ah
Juerd Is this useful?
colomon yes
PerlJam Juerd: yes!
takadonet rakudo: say 2 R+ 5
p6eval rakudo 528bf6: OUTPUT«7␤»
moritz_ Juerd: we had a use case when we first introduced it :-)
Juerd Was that recorded? :)
moritz_ yeah; check the IRC logs :-) 16:04
PerlJam Juerd: Do you think random stuff gets added to Perl 6 for no reason? ;)
takadonet PerlJam: sometimes :P 16:05
colomon if nothing else, it can be really handy if you have two complicated expressions with an operator in the middle and want to see what happens if you quickly reverse them.
moritz_ we're far too post-modern to require reasons :-)
colomon it's also nice in conjunction with Xop
rakudo: say 'a' ... 'e' X~ 'A' ... 'E' 16:06
p6eval rakudo 528bf6: OUTPUT«abcdeeBeCeDeE␤»
colomon rakudo: say ('a' ... 'e') X~ ('A' ... 'E')
p6eval rakudo 528bf6: OUTPUT«aAaBaCaDaEbAbBbCbDbEcAcBcCcDcEdAdBdCdDdEeAeBeCeDeE␤»
colomon there we go
TimToady rakudo: say [R~] 'a' ... 'z' 16:07
p6eval rakudo 528bf6: OUTPUT«zyxwvutsrqponmlkjihgfedcba␤»
moritz_ is that because R~ is right-assoc?
Juerd PerlJam: Yes, absolutely. I am often left with that impression :)
;) 16:08
TimToady no, R specifically doesn't change the associativity
you can use reverse for that :)
colomon rakudo: say ('a' ... 'e') XR~ ('A' ... 'E') # R lets you switch where the capital goes without switching the fact that you handle all the 'a' pairs first
p6eval rakudo 528bf6: OUTPUT«AaBaCaDaEaAbBbCbDbEbAcBcCcDcEcAdBdCdDdEdAeBeCeDeEe␤»
colomon versus 16:09
rakudo: say ('A' ... 'E') X~ ('a' ... 'e')
16:09 zulon joined
p6eval rakudo 528bf6: OUTPUT«AaAbAcAdAeBaBbBcBdBeCaCbCcCdCeDaDbDcDdDeEaEbEcEdEe␤» 16:09
PerlJam I can tell you some of these meta-ops initially make me think "why would I ever need that?" and then a few days later I'll be doing something and go "aha! I could use the R meta-op to solve this problem easily here"
s/make/made/
colomon which is pretty much the sort of thinking that got the Z meta-op added. :)
moritz_ PSA: the IRC logs now support newest-first ordering for the plain-text view, for example irclog.perlgeek.de/text.pl?channel=...;reverse=1 16:10
TimToady it helps that I'd been thinking about adding it for months though :)
moritz_ to safe the poor phone users from scrolling
colomon TimToady: ;) 16:11
16:12 cono joined 16:13 pmichaud joined
pmichaud good re-morning, #perl6 16:15
moritz_ rewb, or so :-)
16:16 cdarroch joined, cdarroch left, cdarroch joined
jnthn o/ pmichaud 16:16
.oO( I think I missed the unre-morning )
pmichaud it's possible I didn't send it with the feather issues.
jnthn pmichaud: Also, I was probably either sleeping, at language class or distracted by $dayjob. :-) 16:17
16:20 timbunce joined
jnthn pmichaud: How's OSCON? You speaking soonish/spoken yet? :-) 16:22
16:22 eternaleye joined
pmichaud oscon is good so far. I'm speaking in four hours. I suspect I should at least update my slides in that time. :) 16:22
jnthn :-) 16:23
About Rakudo Star?
pmichaud also, $dayjob took away some tuits last night and this morning.
tadzik token sheader { '[' (\w+) ']' } -- any idea how to make $match<sheader> return "foo", not "[foo]"?
pmichaud tadzik: nyi, but eventually token sheader { '[' <( \w+ )> ']' } 16:24
tadzik so far I'll have to regexp-extract it?
pmichaud jnthn: today is the "cool perl 6 stuff" talk. Rakudo Star is friday's talk.
moritz_ you already have it in $match<sheader>[0]
pmichaud tadzik: you can get to it with $match<sheader>[0]
tadzik pmichaud: will slides be available?
pmichaud tadzik: definitely 16:25
tadzik: you can see the yapcna version at pmichaud.com/2010/pres/yapcna-perl6/
moritz_ tadzik: but it's generally a good idea to build the desired data structure in action methods, so that you don't have to extract everything from the match tree
pmichaud (note that the actual talk only goes through the first section of slides -- I have far more slides than time for talking)
moritz_ tadzik: see the grammars/parsing json example in the book
tadzik yeah, I'll have to go through this eventually. Is grammars chapter ok in the last build? 16:26
[Coke] so perl6 has cats, monkeys, and cows? freaky.
pmichaud [Coke]: and rats
moritz_ [Coke]: and kitchen sinks
tadzik: should all work, yes
[Coke] Juerd: safe to unzip my sandbox and clean it out now? 16:30
tadzik hmm. If my grammar has token TOP { <something>* }, $match<something> will be an array. But why is it an array if I have TOP { <something>? }? 16:31
moritz_ because ? is also a quantifier
tadzik oh, ok
16:31 ashleydev joined
daxim software.opensuse.org/search?q=rakudo 16:32
looks like at least for 11.3 there are fresh packages
tadzik \o/ # Config::INI can now parse my .gitconfig 16:33
16:34 wallberg left 16:36 ashleydev_ joined, cono left 16:38 mberends left 16:39 ashleydev left, ashleydev_ is now known as ashleydev 16:41 pmichaud left
moritz_ \o/ indeed 16:43
tadzik: if it comforts you, I've gone through several "wtf doesn't this grammar work?" stages already :-)
debugging grammars must be learned, just like debugging code 16:44
16:44 pmichaud joined
tadzik that's right 16:44
I feel tempted to write some other parser, just for practice
[Coke] moritz_: yah, but a "how to debug grammers" would be a great article. =-)
moritz_ [Coke]: good idea
tadzik [Coke]: shotgun programming is a nice method ;)
[Coke] tadzik: how about a parser for tcl's [binary] syntax? =-)
moritz_ tadzik: I did that too. Was fun.
tadzik [Coke]: sounds like fun! I may be able to finish it before Perl 7 :) 16:45
[Coke] www.tcl.tk/man/tcl8.5/TclCmd/binary.htm and github.com/partcl/partcl-nqp 16:46
tadzik parrot's Languages page needs more up-to-date implementations 16:47
most of them are beginned, and put out few years ago
(began?)
16:47 daxim left
[Coke] tadzik: I'm working on it. help me out with partcl, we'll get it done faster. =-) 16:48
it's (nearly) all written in NQP, so you'll get to use Perl6. =-)
tadzik I don't know tcl at all :)
[Coke] oh, that's ok, neither do i! 16:49
PerlJam [Coke]++
moritz_ off to volleyball 16:51
[Coke] ooh, fun.
[Coke] misses volley (and walley) ball.
16:52 perimosocordiae joined, su_penguin_ left
pragma_ volleyball bores me to tears, especially when playing a casual social game. pro games are only slightly less boring. 16:53
now, basketball is a nice fast paced game that requires skill.
tadzik I don't fancy volleyball either, but I wouldn't mind going to play some ball instead of sitting home looking at the display 16:54
pragma_ volleyball is all the same one-two-spike moves over and over, unless you're playing a social casual game -- in which case, it's usually morons whacking the ball in random directions.
basketball, on the other hand, has fluid and shifty dynamics where you have to ultimately focus on team coordination to pass and run around defenses 16:55
16:56 ashleydev left
[Coke] pragma_: wow, you're right, I'm a tool! =-) 16:56
tadzik well, I don't like volleyball just because of its repeatidness, catch the ball, bump, smack to the opponents' side. However, table tennis is even more repeating and I like it
pragma_ to watch table tennis or to play i? 16:57
16:58 dakkar left
tadzik to play 16:58
watching might be boring
(hmm, so maybe playing voleyball is fun too)
16:59 ashleydev joined 17:01 ab5tract joined 17:03 dukeleto joined, ashleydev_ joined 17:04 jql joined 17:05 thebird left 17:07 ashleydev left, ashleydev_ is now known as ashleydev 17:09 timbunce left, jmanjohn61 joined
jmanjohn61 hello 17:09
tadzik hey 17:10
takadonet yo 17:11
jmanjohn61 What is going on here
tadzik We're writing stuff :) 17:12
17:12 goksie left
jmanjohn61 I have to type:) 17:12
tadzik Is there some way to check the corectness of an embeeded Pod6? 17:13
pmichaud exit
ww
17:13 jmanjohn61 left
colomon pmichaud: as long as you're here, what's the status of your series operator update? 17:14
17:14 pragma_ is now known as _pragma
_pragma I thought we were discussing balls, actualy. 17:25
colomon for 'Y'..'b' -> $i { $i.say } 17:26
rakudo: for 'Y'..'b' -> $i { $i.say }
p6eval rakudo 528bf6:
..OUTPUT«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␤AZ␤BA␤BB␤BC␤BD␤BE␤BF␤BG␤BH␤BI␤BJ␤BK␤BL␤BM␤BN␤BO␤BP␤BQ␤BR␤BS␤BT␤BU␤BV␤BW␤BX␤BY␤BZ␤CA␤CB␤CC␤CD␤CE␤CF␤CG␤CH␤CI␤CJ␤CK␤CL␤CM␤CN␤CO␤CP␤CQ␤CR␤CS␤CT␤CU␤CV␤CW␤CX␤CY␤CZ␤DA␤DB␤DC␤DD␤
jnthn Y b it doing dat?
_pragma Needs less unicode. 17:27
jnthn I see no unicode.
Looks like it's not caring about string length of something though, which I thought it may have done.
colomon it be broken.
17:27 tylercurtis joined
colomon but it be somewhat fixed locally. 17:27
> ~'Y'..'b' 17:28
Y Z [ \ ] ^ _ ` a b
..^ or ^..^ isn't fixed yet. 17:29
(locally, I mean)
wondering how many (no longer up to spec) tests this will break...
17:29 zulon left
_pragma jnthn: looks like this for me: i31.tinypic.com/dpes1j.jpg 17:34
jnthn _pragma: your PuTTY needs a tweak. ;) 17:36
17:36 gbacon joined 17:38 envi^home left, stepnem joined
Tene .u ␤ 17:38
phenny U+2424 SYMBOL FOR NEWLINE (␤)
_pragma Yeah, this shell I'm ssh'd into doesn't have unicode support and I'm not root. Out of the 18 or so channels I'm in, this is the only one that has bots that use unicode. Oh well. 17:40
17:41 smash__ left 17:43 Kodi joined
jnthn _pragma: Yeah, I remember having to do a few things to get it to work cleanly for me. 17:46
[Coke] see, my putty is showing cammy in the topic, but I get a square for 2424. 17:47
TimToady font issue, likely
[Coke] lesse, there's a box with a question mark... 17:48
_pragma jnthn: hmm, looks like this now: i26.tinypic.com/6qim8g.jpg 17:49
I went to Settings -> Window -> Translation and changed 'Input data assumed to be in' from some ISO thing to UTF-8 17:50
Certainly an improvement. 17:51
[Coke] any recommends for a putty font?
jnthn _pragma: Yup, that's now matching what I see.
_pragma I'm ussing PuTTY-Tray, by the way. Much better than the vanilla PuTTY.
PerlJam is it just me or has the discussion of .. on p6l jumped the shark? 17:52
jnthn My font doesn't do the NL char either :-)
tadzik Term::ANSIColor is to be ported? 17:55
yep, looks so 17:56
jnthn I think somebody already ported it
Eevee I have NL but it's.. very teeny
jnthn Yeah, NL is tiny compared to DE.
17:56 pmurias joined
_pragma PerlJam: I rather think they've nuked the fridge. 17:57
pugssvn r31782 | pmurias++ | add UploadToCPAN to dist.ini, remove hardcode version number from smop
tadzik anything similar to AUTOLOAD in Perl6? 17:58
ingy morning
tadzik o/
ingy CAN HAZ OZKON!
18:00 tylercurtis left
[Coke] wonders how all you jokers can afford oscon. :P 18:00
jnthn [Coke]: Secret second career as stand up comedians. :P
[Coke] _pragma++ # putty tray is worth it for the clickable urls. 18:01
18:02 ashleydev_ joined
_pragma Heh, yeah, that was the main reason I started using it as well. 18:02
tadzik can macros be exported, just like functions?
18:04 ashleydev left, ashleydev_ is now known as ashleydev
jnthn szabgab++ # like the screencasts :-) 18:06
18:08 cjk101010 left 18:10 rurban joined
colomon rakudo: say 1, 2 ... 0 18:11
p6eval rakudo 528bf6: OUTPUT«␤»
18:17 ashleydev_ joined
colomon rakudo: say ~(1, 2 ... 0) 18:19
p6eval rakudo 528bf6: OUTPUT«␤»
18:19 ashleydev left, ashleydev_ is now known as ashleydev
tadzik I fail to understand S11, how do I use a module importing everthing that's exported inside? 18:21
18:22 Schwern joined
TimToady it's supposed to work that way if you add :ALL, but might be NYI 18:23
18:25 amkrankruleuen joined 18:26 timbunce joined
colomon rakudo: say ('a' ... Inf).munch(10) 18:28
p6eval rakudo 528bf6: OUTPUT«a␤»
colomon rakudo: say ('a' ... *).munch(10) 18:29
p6eval rakudo 528bf6: OUTPUT«abcdefghij␤»
tadzik TimToady: Confused at line 1, near "use Term::", looks NYI
any temporary way to export functions? 18:30
TimToady my &foo := &That::foo; if they are declared as "our" 18:31
or I guess = is also acceptable there
jnthn if you "use Foo" in Rakudo, everything that was marked 'is export' or 'is export(:DEFAULT)' should get exported. 18:32
At least that much works, or "use Test;" (which is all lexical subs) would not :-)
tadzik hrm 18:34
wklej.org/id/367342/ either doesn't seem so, or I'm doing something wrong again :) 18:37
18:39 pyrimidine joined
jnthn tadzik: ooc, if you use Term::ANSIColor 18:46
gah
if you use Term::ANSIColor; say BOLD, "foo"
On one line
does it work?
I think there's a ticket of sorts.
about tht bug
*that
PerlJam perl6 18:47
colomon rakudo: say "100" ... "102"
p6eval rakudo 528bf6: OUTPUT«100101102␤»
colomon rakudo: say ~("100" ... "102")
p6eval rakudo 528bf6: OUTPUT«100 101 102␤»
colomon rakudo: say ~("100.A" ... "102.B") 18:48
p6eval rakudo 528bf6: OUTPUT«100.A 101.A 102.A␤»
18:49 patspam joined, justatheory joined
TimToady I'm probably going to go with some kind of default semantics a bit closer to what ajs++ is recommending 18:50
simply because the ... operator is more aware of the final value than .succ is
so the current semantics would be more like "100.A", *.succ ... "109.A" 18:51
and the new semantics could do something saner column by column 18:52
though not necessarily as aware of Unicode props as ajs++ is proposing, if we can do it with filtering 18:54
but it'd be nice to at least get "000" ... "FFF" do do hex :)
colomon nooooooooo...... 18:55
tadzik jnthn: yes, that works
:ASD
colomon rakudo: my @hex = '0' ... '9', 'A', 'B', 'C', 'D', 'E', 'F'; say ~(@hex Z~ @hex) 18:56
tadzik and by the way, can macros be exported just as subs? I didn't see it in Specs
p6eval rakudo 528bf6: OUTPUT«00 11 22 33 44 55 66 77 88 99 AA BB CC DD EE FF␤»
colomon rakudo: my @hex = '0' ... '9', 'A', 'B', 'C', 'D', 'E', 'F'; say ~(@hex X~ @hex) 18:57
p6eval rakudo 528bf6: OUTPUT«00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F 10 11 12 13 14 15 16 17 18 19 1A 1B 1C 1D 1E 1F 20 21 22 23 24 25 26 27 28 29 2A 2B 2C 2D 2E 2F 30 31 32 33 34 35 36 37 38 39 3A 3B 3C 3D 3E 3F 40 41 42 43 44 45 46 47 48 49 4A 4B 4C 4D 4E 4F 50 51 52 53 54 55 56 57 58 59 5A 5B
..5C 5D …
colomon rakudo: my @hex = '0' ... '9', 'A', 'B', 'C', 'D', 'E', 'F'; say ~(@hex X~ (@hex X~ @hex))
p6eval rakudo 528bf6: OUTPUT«000 001 002 003 004 005 006 007 008 009 00A 00B 00C 00D 00E 00F 010 011 012 013 014 015 016 017 018 019 01A 01B 01C 01D 01E 01F 020 021 022 023 024 025 026 027 028 029 02A 02B 02C 02D 02E 02F 030 031 032 033 034 035 036 037 038 039 03A 03B 03C 03D 03E 03F 040 041 042 043 044
..045 04…
TimToady hmm, we need a way for users to define those ranges in a scope, such that ... can look up <0 f> and find (0...9),('a'...'f') 19:01
and then define that one by default, and maybe most of the major sequences that rangechars is already defined for
19:02 eternaleye left, justatheory left
rokoteko TimToady: what is 0..f doing currently? 19:02
colomon rakudo: say '0'..'f' 19:03
jnthn tadzik: Ugh. That suggests something is kinda broken with lexicals inthe REPL still. :-(
colomon rakudo: say '0'...'f'
p6eval rakudo 528bf6:
..OUTPUT«012345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913…
rakudo 528bf6: OUTPUT«0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdef␤»
tadzik jnthn: whew! Thank FSM it's just REPL :)
so, the question remains: can I export macros?
colomon rokoteko: the second of those is what it is spec'd to do. 19:04
rokoteko what .. is REPL a major Perl6 hack, or what on earth is it?
[Coke] it's what most sane dynamic languages give you when you invoke the compiler with no code.
kind of like perl5 -de1; 19:05
19:05 molaf joined
pmichaud ...repl bug? 19:06
example?
Juerd [Coke]: Yes
[Coke] Juerd: oh, good, because I did it, then accidentally deleted it, and am now about to do it again!
jnthn pmichaud: 19:07
> use Test; plan 1;
1..1
Juerd [Coke]: What did you delete?
jnthn works
but
> use Test;
_block64
> plan 1
Could not find sub &plan
:-S
pmichaud: Which is very odd given it's just installed in the lexpad. :-S
pmichaud ah, it's likely a problem with exporting.
[Coke] Juerd: the expanded sandbox/
i didn't lose anything.
cleaning up junk now...
jnthn pmichaud: Maybe, but I struggle to see why it'd go rong. 19:08
TimToady lunch &
[Coke] Juerd++ # all the feather admining.
rokoteko Juerd++
tadzik so :) (How) can macros be exported? :) 19:09
pmichaud lunch &
jnthn tadzik: When they're implemented, I'd imagine just with 'is export' 19:10
[Coke] tadzik: Do you mean per spec (I don't know) or in rakudo (probably NYI)
tadzik ah, ok
19:10 nimiezko left
rokoteko Juerd: I remember you from ircnet #perl. I found it bit silly that it's only americans that are actively listeneed for opinions on perl programming. some of use have joined freenode, as we feel it as the only way to really help perl people. I really hope for the sake of perl, that it doesnt lose it's amazing usage in europe. 19:11
19:12 amkrankruleuen left
[Coke] thinks this channel is full of europeans. 19:12
rokoteko </imho>
19:12 lue left
Juerd rokoteko: Are you referring to some conversation we have had in the past? 19:12
19:13 Guest78269 left
rokoteko Juerd: no. just the knowledge, especially on unicode you had with perl5. I think you are essentially good for perl6 :) 19:13
it was meant for mocking. I just miss some of the europeans who are not here as anyone hasnt even asked them here. personally I found the way here by myself and I havent even been very good at perl for very long. 19:14
19:14 plainhao left
rokoteko *it was not meant for mocking. 19:14
19:17 nimiezko joined
colomon thought we were outnumbered by the Europeans around here... 19:17
19:18 lue joined 19:19 stepnem left
jnthn I'm in yer #perl6, outnumberin' yer Americans. 19:20
rokoteko ok, I might sound bit childish, but how many from the US and how many from each country in europe? please dont mock me for this, Im trying to conversate. I certainly do miss some european people in pelr6 discussions.
19:20 Schwern left
rokoteko also, I dont know the history very well, so someone can point me wrong also :) 19:21
[Coke] if you miss someone specifically, by all means invite them in.
tadzik rokoteko: Poland here
Juerd rokoteko: I fail to see why this is important or even relevant. 19:22
[particle] i miss the martians that used to hang out here. they were good for perl, too! 19:23
rokoteko juerd: ton has left perl completely, afaik. mtve is not interested in perl6, I think he hasnt been invited to share his brilliancy and shmem also the same thing, alankila started programming java. ok I think I could invite them, but it would be more efficient from someone who truly has done perl6. 19:24
ohh.. and forgot tybalt89 also.
19:24 Guest78269 joined
rokoteko anyhow. see the people who mastered perlgolf. I think it's bit wierd that they arent asked here to share their very, very important opinions.. that should be default. 19:25
Im not trying to be offensive, I just know how good these people (and Juerd, how luckily is here) are..
Juerd rokoteko: So brilliant people leave Perl. That's going on everywhere, not just in the US or just in Europe.
rokoteko: Also, other people take their places.
[particle] and, this channel is open to all who wish to discuss perl 6 19:26
rokoteko Juerd: ahh.. ok. so maybe my problem is that I dont feel that Im able to replace these people.
Juerd rokoteko: It has always been like this in every community, for every language or piece of software.
rokoteko Juerd: thank you for explaining this to me. it's very important, because im relatively new to perl. was tkr on ircnet, if you remember me by that nick better. 19:27
Juerd Better than not at all, at least :)
19:29 stepnem joined
rokoteko well still very new compared to these people I mentioned. :) but ok. I hope no-one minds if Im sharing my problem about perl6 future here. 19:31
I honestly would wish that perl could keep going as I have just barely started to learn it and get paid relatively well for working with it. :)
19:31 Mowah left
sorear Hello pmichaud 19:32
rokoteko ok there's enough perl5 for me to keep on maintaining for the rest of my life. but I wouldnt mind developing some new feature in the future also. :) which is not very nearly expected for perl6 programmers at private sector. :)
frettled rokoteko: Job security in Perl is easy! ;)
rokoteko frettled: that was not my point at all. I wish future generations would also keep programming perl. 19:33
else we (the perl5 people) will be like cobol people in 30 years.
ok, I also happen to agree that it is quite easy to learn any programming language (.. functional languages might keep us entertained for a while) after learning perl. 19:34
sorear perl5 people *will* be like cobol people in 30 years 19:35
frettled Well, we don't know that, really. We'll see after 2038. 19:36
sorear tries upgrading to mono svn 19:38
19:38 ash_ joined
rokoteko sorear: really? you think there's no reason for us to learn perl6? 19:38
sorear: we are doomed?
what would you suggest instead, Ruby, Python, Haskell or something completely different? 19:40
Juerd rokoteko: Many businesses (at least in .nl) are searching for ways to get rid of Perl.
rokoteko: And new shops tend to pick other languages too. 19:41
rokoteko yes, that is because they think Java people ara graduating from colledge and the management expect them to be as competent as perl people.
Juerd No 19:42
19:42 achromic joined
Juerd They're moving towards Python and .Net, in most cases. 19:42
rokoteko which is just bullshit. Ive personally seen this fails. a seasoned perl hacker is so much more productive than a just graduated java programmer the the management has no idea about it.
Juerd Yes, but there's this weird and wrong idea that Perl is dead. 19:43
And it appears to be confirmed by the lack of Perl programmers.
rokoteko Juerd: that might be true. but see the java+xml consultants. I think its about as competent people advertising their languate.
Juerd (OTOH, a single company (Booking.com) seems to employ half of them...) 19:44
rokoteko perl5 wont be dead for atleast 100 years. but Im afraid perl6 will.
and I *do* love perl.
Juerd Perl 6 will be the greatest zombie ever!
rokoteko :)
Juerd rokoteko: In any case, there's no such thing as "now or never" 19:45
If Perl 6 will be good, and not too hard or too complex to learn, it will be as succesful as its predecessors were.
19:46 pradeep77 joined, pradeep77 left 19:47 mberends joined
sorear rokoteko: I said perl *5* people will be dinosaurs in 30 years 19:49
rokoteko: perl $current-version people won't be
thepler rakudo: say (1,2,3).Seq === (1,2,3).Seq 19:50
p6eval rakudo 528bf6: OUTPUT«0␤»
19:50 rgrau_ joined
sorear pmichaud: ping 19:51
pmichaud <suggestion> When we send someone to perl6advent.wordpress.com, it'd be really nice if there was a link to Day 1 immediately available.
sorear: pong
sorear pmichaud: can you explain in a nutshell how p6regex backtracking compilation works?
19:52 ash__ joined
sorear it seems to have something involving stacks of label addresses 19:52
pmichaud sorear: that's correct
a backtracking point mainly consists of a position to backtrack to, and the label address where to restart 19:53
sorear what about the current continuation?
19:53 ash_ left, ash__ is now known as ash_
pmichaud ...current continuation? 19:53
you mean, for restarting after a successful match?
sorear the CallContext PMC which assigns meaning to the label
rokoteko okey. <suggestion> why hasnt perl6 yet captured the windows programmers that use eclipse? I mean why isnt the oocumentatio the same quality as you started the whole thing from beginning? 19:54
19:54 Meldrake left
sorear rokoteko: because Java has been a mature environment for 10 years, Perl 6 for maybe -3 19:55
rokoteko Im starting to think it's mainly because the commercial people are thinking what happens if Timtoady dies. and that's why perl was started from scratch.
sorear do you understand the difference 13 years head start makes?
pmichaud sorear: I capture the current sub if a successful match occurs and there's a possibility of backtracking into the current match
rokoteko sorear: nods. I actually was programming java for a while. and the gurus on java said that perl is good because it has a very mature vm.
pmichaud otherwise, I don't capture the continuation at all. 19:56
sorear rokoteko: they meant perl 5. go to #perl, not here
rokoteko sorear: so perl6 started 13 years ago, or what are you trying to say?
sorear perl 6 isn't finished
it'll be a mature system about 3 years from now, I estimate
rokoteko sorear: really, Im already on #perl. you think I should leave #perl6, really?
sorear no, if you want to stay, you can stay 19:57
rokoteko for stating my opinions? Im willing to do that if you ask.
sorear I'm not asking you to leave for stating your opinions
I'm giving you directions because you look lost
rokoteko ok. good :) I was starting to get worried.
pmichaud hugme: hug sorear and rokoteko
hugme hugs sorear
pmichaud hugme: hug rokoteko 19:58
hugme hugs rokoteko
rokoteko thank you.. hugging is always nice. :)
mberends rakudo: say time; say pir::time__N(); 19:59
p6eval rakudo 528bf6: OUTPUT«1279741153␤1279741153.07107␤»
mberends misses those microseconds
rokoteko I was just worried, because I have mainly worked as a programmer for commercial perl providers. and what would perl be without these people?
ash_ mberends: didn't that just changed like last week?
rokoteko ok. Ill drop the discussion for now. :)
pmichaud rokoteko: fwiw, I didn't understand the original question. But I'm also a bit distracted :) 20:00
20:00 nimiezko left, exodist left, cxreg left, christin1 left, tyru left
mberends ash_: yes, and it broke the micro benchmarking in tools/test_summary.pl 20:00
Juerd sorear: Finished is a weird thing for software
sorear: qmail comes to mind.
pmichaud so does Perl 5. :-)
ash_ perl5 is still changing 20:01
Juerd pmichaud: Perl 5 is under heavy development
pmichaud Juerd: right
oh, sorry
Juerd pmichaud: Contrary to qmail, which had is last and final release in, what, 1993? :)
mberends ash_: so I'm considering patching Test.pm to use the pir:: alternative
pmichaud you said "qmail". I read "gmail" and thought "Google Beta"
Juerd Ah, haha
rokoteko pmichaud: nods. I decided to drop the discussion before I annoy more of the gurus. :) But we can continue if I feel it is still important next time I discussing perl future here.
Juerd From that perspective your comment makes a lot more sense :)
20:01 timbunce left
pmichaud I guess I need glasses, a bigger font, or both. 20:02
20:02 molaf left
Juerd pmichaud: No, just say "Rakudo makes me very creative" 20:02
You'll get away with anything :)
ash_ does DateTime have nano seconds? 20:03
rakudo: say DateTime.now.perl;
p6eval rakudo 528bf6: OUTPUT«DateTime.new(year => 2010, month => 7, day => 21, hour => 19, minute => 43, second => 12, timezone => 0)␤»
ash_ hmm
it gets seconds
colomon ponders a .grep-unless method
Tene colomon: what would that do?
ash_ not accurate enough for bench marking though
Juerd colomon: There's grep not. 20:04
Where not is in the condition :P
colomon Tene: take a test and return all the elements for which the test is false
Juerd: as far as I know, you cannot say .grep(!Int) (for instance)
Juerd .grep(none(Int)) then? :)
pmichaud .grep( * !~~ Int ) ?
sorear Why is there no syntax for anonymous multisubs? 20:05
Tene rakudo: my @a = 1, "foo", 3, "bar"; say @a.grep(Int).perl;
p6eval rakudo 528bf6: OUTPUT«(1, 3)␤»
Tene rakudo: my @a = 1, "foo", 3, "bar"; say @a.grep(* !~~ Int).perl;
p6eval rakudo 528bf6: OUTPUT«(1, "foo", 3, "bar")␤»
moritz_ std: anon multi foo() { }
p6eval std 31782: OUTPUT«ok 00:01 116m␤»
20:05 cxreg joined
colomon pmichaud: * doesn't form a whatever closure with ~~, does it? 20:05
pmichaud .grep( not (* ~~ Int) ) ?
Juerd moritz_: What's the "foo" part called?
sorear That's an anonymous multi candidate... not quite what I want
moritz_ Juerd: name
Juerd moritz_: Anonymous with a name? 20:06
sorear I'm speaking of something like a Haskell case statement
20:06 Schwern joined
ash_ std: my $a = anon sub (Int $b) { }; say $a; 20:06
p6eval std 31782: OUTPUT«Potential difficulties:␤ $b is declared but not used at /tmp/Wzwo95u1RX line 1:␤------> my $a = anon sub (Int ⏏$b) { }; say $a;␤ok 00:01 120m␤»
moritz_ sorear: my $x = anon proto foo { }; $x.push: anon mulit ...
Juerd: yes
pmichaud rakudo: my @a = 1, "foo", 3, "bar"; say @a.grep({ $_ !~~ Int}).perl;
sorear like a pointy block, but with several bodies, depending on signature
moritz_ Juerd: it's anon in the sense that it's not entered in any package table or lexical scope
ash_ -> Int $a { ... }, Str $a { ... }
moritz_ but you can still ask it for its name
Juerd moritz_: I see 20:07
jnthn sorear: Any reason not to use given/when?
pmichaud rakudo: say 'hello';
20:07 ashleydev_ joined
p6eval rakudo 528bf6: OUTPUT«hello␤» 20:07
sorear jnthn: given/when only does single dispatch
ash_ sorear: any suggestions on how to write that?
jnthn sorear: Capture ~~ Signature lets you determine the cases
colomon pmichaud: your last works locally 20:08
jnthn sorear: Yeah, I was meaning more you have like given $capture { when sig { ... } } etc
Tene I expect you could do: -> |$_ { when ... {}; when ... {}; }
20:08 exodist joined
ash_ my $foo = -> Int $a { say 'int' }, Str $a { say 'Str' }; $foo(4); $foo('test'); 20:08
Tene signature is what, :()?
pmichaud colomon: okay, good.
jnthn Tene: aye
sorear Tene: That would be *awesome* if it also bound variables in said signatures. 20:09
Tene when :(Str $n, Int $x) { ... }
yes?
jnthn sorear: Yes, true. I think there's a form that maybe does that
Tene: Yeah but it only checks the signature could bind
pmichaud colomon: yes, there have been times when I've wanted a "when't". I think we even discussed it briefly at YAPC::NA the day-after-the-conference, and TimToady++ had some obvious answer that I've forgotten now :-|
it might've been none(...)
jnthn Tene: RAther than actually giving you the variables.
colomon pmichaud: I remember the discussion, don't remember the answer.
20:09 ashleydev left, ashleydev_ is now known as ashleydev
pmichaud rakudo: my @a = 1, "foo", 3, "bar"; say @a.grep(none(Int)).perl; 20:09
Tene binding is assigning to the sig, then? 20:10
pmichaud p6eval doesn't like me.
sorear I think I'll implement binding signatures as a syntactic special case of when() in niecza
and see how it works
colomon pmichaud: that one also works (correctly) locally
pmichaud: it also makes my head hurt
pmichaud anyway, time for me to go get set up for my talk.
colomon pmichaud++
jnthn Go pmichaud! \o/
Tene sorear: although, I could certainly see what you originally asked for as very reasonable. 20:11
jnthn looks forward to seeing pmichaud talks at YAPC::EU
20:11 tyru joined 20:13 christine joined
pmichaud talk slides are at pmichaud.com/2010/pres/oscon-perl6 . Mostly the same as the yapc::na talk, a few updates and improvements to the slides. 20:13
okay, gone for a while.
bbl
jnthn sorear: I had vague memories of a when -> $foo, @bar { ... } form that entered the block if it could bind $_ 20:14
sorear: But I don't see it in the synopses
20:14 Schwern left, takadonet left
jnthn sorear: Maybe I dreamed it. :-) 20:14
Tene I had a vague memory of a -> form with multiple sigs and bodies, but I can't find any evidence of it existing. 20:15
You think we dreamed the same platonic ideal spec? ;)
ash_ does nqp have given/when? i don't think it does... 20:18
and multi sig can't take constants in nqp :-(
nqp: multi f(3) { say '3'; }; multi f('4') { say '4'; }; f(3); f('4');
p6eval nqp: OUTPUT«Routine declaration requires a signature at line 1, near "(3) { say "␤current instr.: 'parrot;HLL;Grammar;panic' pc 552 (src/cheats/hll-grammar.pir:205)␤»
ash_ rakudo: multi f(3) { say '3'; }; multi f('4') { say '4'; }; f(3); f('4');
p6eval rakudo 528bf6: OUTPUT«3␤4␤» 20:19
jnthn ash_: NQP is meant to be fairly small. :-)
ash_ i know
jnthn ash_: And not a nightmare to port to other backends.
ash_ is given when that difficult though? since it already has ~~
just wondering
jnthn ash_: Not sure how far ~~ works in NQP to be honest
But to the degree it does, given/when could be made to work I guess. 20:20
ash_ am i wrong in feeling that given/when is mostly syntactic sugar for ~~ and some if/else's ?
okay, maybe a bit more complicated, but still
is there a suggested way of handling a switch in nqp? should i just if/else a bunch?
moritz_ arnsholt had a nqp-rx branch that implements given/when
Tene ash_: That's mostly correct, yes. 20:21
cxreg bad git config alert: Author: Kodi Arfer <hippo@Thoth.(none)>
Kodi Eh?
cxreg user.email isnt set to something sane 20:22
moritz_ right
ash_ git config --global user.email [email@hidden.address] 20:23
will set it globally
or you can do it per-repo
tadzik github.com/tadzik/perl6-Term-ANSIColor 20:25
not everything implemented, but it's alredy fun :)
cxreg moritz_: i can flail helplessly against zavolaj, but it's probably a good idea if someone competent looks at it once more before R* ships
moritz_ cxreg: jnthn++ plans to do it 20:26
cxreg ok, cool
20:27 nimiezko joined, justatheory joined
cxreg should ingy's test thingy be added to star? 20:28
20:28 cono joined
moritz_ yes 20:28
[Coke] +1
moritz_ feel free to add it to the wiki
jnthn If anyone thinks github.com/jnthn/test-mock/ is good enough, they may also feel free to suggest it for R* inclusion. 20:29
[Coke] I mock your tests. 20:30
20:30 molaf joined
moritz_ feels so 20:30
jnthn Aww. My tests need hugs now.
20:31 Guest78269 left
cxreg looks like ingy's urls are github.com/ingydotnet/yaml-pm6 and github.com/ingydotnet/testml-pm6 20:31
moritz_ hugme: hug jnthn's tests
hugme hugs jnthn's tests
tadzik can someone review Term::ANSIColor?
moritz_ what kind of review do you want?
tadzik either hapiness or criticism I guess :) 20:32
it's listed in wiki.github.com/rakudo/rakudo/perl-...-to-perl-6
moritz_ tadzik: I like it. It works, and the code is simple 20:35
20:35 tylercurtis joined
tadzik I'm glad 20:35
moritz_ tadzik: just needs a README, and a licence
tadzik oh sure
20:35 nimiezko left
tadzik not sure how the tests are ought to look. I took a look at CPAN's Term::ANSIColor and they look like just another possibility of making a typo breaking everything 20:36
tylercurtis Yay! My power and internet are both working again. Hopefully the combination will last for more than five minutes. Hello, #perl6! 20:37
tadzik o/
moritz_ \o 20:38
tadzik: as a future plan, you could make an enum with colors and other modes
20:39 nimiezko joined, supernovus joined
tadzik moritz_: enum will imply I'll have to generate control sequences in runtime, no? 20:39
colomon rakudo: say ~(1, 2, 4 ... 100)
p6eval rakudo 528bf6: OUTPUT«1 2 4 8 16 32 64␤»
moritz_ tadzik: no
tadzik moritz_: how would it look like then?
moritz_ enum Attrs reset => "\e", bold => "\e", ... 20:40
tadzik how it would be different from a hash then?
moritz_ and then "is export" (when rakudo implements it) 20:41
tadzik not computed in runtime?
moritz_ which has the advantage that you can say color(blue), and get compile-time checking
the enum initialization runs at compile time
tadzik hmm
will note it and think about it
moritz_ but currently rakudo can't export enums :(
that's why I said future project :-) 20:42
tadzik ok :)
szabgab rakudo: for 1..3 -> $a, $b { say $a } 20:45
p6eval rakudo 528bf6: OUTPUT«1␤3␤»
szabgab :(
diakopter .u 20:46
phenny U+0007 (No name found)
supernovus Kodi: So, DateTime is going immutable. I'd like a method to take a DateTime object in any timezone and return a new DateTime in a different timezone, using the offset format from the ISO string (i.e. say DateTime.now().to-timezone('-0800'); ) I'd be willing to write the method myself, in which case I'll wait for your immutability patch to roll in.
phenny diakopter: 08:06Z <sorear> tell diakopter Cecil appears to be a .NET assembly. I can only use tools with file-based interfaces pre-bootstrap (since I'm running on the p5vm), and ilasm seems to beat gmcs
tylercurtis If I have "has @.children where SomeConstraint", does SomeConstraint constrain the container or the elements?
szabgab is anyone going to fix this any time soon?
tylercurtis szabgab: What's to be fixed?
moritz_ szabgab: nope. In the long run it will need a spec change
tylercurtis rakudo: for 1..4 -> $a, $b { say "$a $b"; } 20:47
szabgab oh, so is this now the correct behavior?
p6eval rakudo 528bf6: OUTPUT«1 2␤3 4␤»
Kodi supernovus: Do me a favor and don't touch any Temporal stuff for a day or so. I'm deep into hacking the spec, the test suite, and Temporal.pm simultaneously. Immutability is the major change.
moritz_ we need a spec for partially binding signatures
szabgab: no
supernovus Kodi: That's why I said I'd wait until your new patch lands :-)
szabgab tylercurtis: I was expecting an exception there
20:47 eternaleye joined
moritz_ szabgab: I want to say that the things we could do now to tackle the problem are all fragile 20:47
tadzik moritz_: TBH, I don't see any module on proto containing a license
szabgab as it used to be
moritz_ tadzik: that's bad
tylercurtis tadzik: Bennu does, IIRC.
supernovus I hope the changes make it for R* 20:48
moritz_ phenny: tell masak tadzik++ noticed a lack of license in proto... care to add the AL2?
phenny moritz_: I'll pass that on when masak is around.
tadzik yeah, Bennu has
Kodi supernovus: Well, in-timezone, which is basically what you're talking about, ought to do the same thing.
tadzik stars adding LICENSEs
Kodi supernovus: We can talk about it once I'm done here.
supernovus supernovus: Sounds good. in-timezone() sounds like exactly what I was thinking of. I won't disturb you further :-) 20:49
tylercurtis szabgab: I thought it was correct, but moritz_ disagrees, so I'd strongly recommend listening to him.
supernovus gah, that last message was for Kodi, I'm not talking to myself ;-)
Kodi supernovus: Heh.
moritz_ moritz_: why not? talking to yourself is very natural 20:50
Kodi supernovus: Ja, in-timezone is just like your to-timezone, but it takes an offset in seconds.
tylercurtis moritz_: Why isn't that correct behavior, by the way?
Kodi supernovus: Offsets in seconds now being The Standard Way to think about timezones. 20:51
moritz_ tylercurtis: because silently dropping information is bad[tm]
colomon tylercurtis: and if you want to drop, you can do -> $a, $b? { ... }
tylercurtis moritz_: oh. right. 20:52
moritz_ or pad your list to an even size
tylercurtis misunderstood the problem.
supernovus Kodi: Okay, maybe there should be something to convert between HHMM offsets and Offsets-in-seconds. I guess it could be a helper method or subroutine. Maybe DateTime::strftime should become DateTime::Utils and have a few "helper" methods in it.
methods=>subroutines 20:53
szabgab what is the difference between 1..Inf and 1..* ?
moritz_ 2 characters :-)
20:53 molaf left
szabgab :) 20:53
moritz_ should be the same
Kodi supernovus: Maybe. I've just been taking the no-parsing-in-Temporal-except-for-an-entire-ISO-timestamp philosophy as far as I can.
tadzik moritz_: my modules now have licenses
moritz_ tadzik++ 20:54
supernovus Kodi: That sounds good. I think the module currently called DateTime::strftime is a better place for a offset-to-seconds() subroutine anyway.
or offset-in-seconds() 20:55
colomon rakudo: say (1..*).perl 20:56
p6eval rakudo 528bf6: OUTPUT«1..Inf␤»
colomon ;)
ingy au|zzz: www.pegex.org/ (thanks for the advice :)
supernovus Kodi: Speaking of which, will you be making changes to the DateTime::strftime module in this patch? 20:57
pugssvn r31783 | colomon++ | [t/spec] Simple tests on the result types of intuited arithmetic / geometric series.
Kodi supernovus: None.
szabgab what is the name of ... ?
20:57 perimosocordiae left
tylercurtis rakudo: my Int @a where { $_ % 2 == 0 } = 2, 4, 6; say "@a[]"; 20:57
p6eval rakudo 528bf6: OUTPUT«===SORRY!===␤Confused at line 22, near "my Int @a "␤»
supernovus Kodi: I'm almost of the opinion that DateTime::strftime should actually be moved out of the Rakudo tree and become it's own project that can be installed using proto/pls. It could be included with Rakudo * as one of the "bundled modules". 20:58
szabgab is there a bot that would look up my questions in the spec and paste them to me in a private channel?
Kodi supernovus: +1
supernovus: If you do that, just make sure you don't forget to move DateTime-strftime.t out of pugs. 20:59
[Coke] szabgab: don't think so. the closest I've found is the indices on the perlcabal site.
20:59 achromic left
tylercurtis rakudo: class Foo { has Int @.a where { $_ % 2 == 0 }; }; Foo.new(:a(2, 4, 6)).a.perl.say; 21:00
p6eval rakudo 528bf6: OUTPUT«===SORRY!===␤Unable to parse blockoid, couldn't find final '}' at line 22␤»
tylercurtis std: class Foo { has Int @.a where { $_ % 2 == 0 }; }; Foo.new(:a(2, 4, 6)).a.perl.say;
p6eval std 31782: OUTPUT«ok 00:01 119m␤»
szabgab so is ... the yadda, yadda in perl 6 as well?
Tene Yes. 21:01
tylercurtis rakudo: ...
moritz_ as a term, yes
p6eval rakudo 528bf6: ( no output )
moritz_ as an infix, it's the series operator
tylercurtis rakudo: sub foo {...}; foo
p6eval rakudo 528bf6: ( no output )
TimToady not "as well", "originally" :)
szabgab ok, I was thinking as infix
TimToady infix:<...> is completely different
szabgab TimToady: :) 21:02
supernovus Kodi: I'll start a new github repository for DateTime::Utils. move the test out of the official spec tests and figure out how to grant commit bits to you and masak.
TimToady std: 1,2,3, ... 10; # accidental comma before ... make it yada
p6eval std 31782: OUTPUT«Potential difficulties:␤ Comma found before apparent series operator; please remove comma (or put parens␤ around the ... listop, or use 'fail' instead of ...) at /tmp/qotHhInQZi line 1:␤------> 1,2,3,⏏ ... 10; # accidental comma before ... ␤ok 00:01 117m␤»
szabgab I was thinking on how it is called in 1,3...10
21:02 ashleydev left
moritz_ "series" 21:02
szabgab and 1,3..10 is range, right? 21:03
moritz_ yes
szabgab thanks
colomon no
tylercurtis rakudo: (1,3..10).WHAT
p6eval rakudo 528bf6: ( no output )
TimToady 3..10 is a range
tylercurtis rakudo: (1,3..10).WHAT.say
p6eval rakudo 528bf6: OUTPUT«Parcel()␤»
Tene No, .. is range, ... is series
colomon 1, 3 .. 10 is an Int followed by a Range
TimToady .. only takes two scalars, not two lists like ....
colomon in a Parcel. 21:04
cxreg hacked badge: twitter.com/mmmpork/status/19104875010
jjore_ lol 21:05
szabgab right so in 1,3..10 the 1 is desregarded by .. but if iterating over the whole thing then it is included
moritz_ rakudo: .say for 1, 3..10 21:06
p6eval rakudo 528bf6: OUTPUT«1␤3␤4␤5␤6␤7␤8␤9␤10␤»
colomon what am I doing wrong here? gist.github.com/485140 21:07
Non-declarative sigil is missing its name at line 795, near "&& $factor"
21:08 [bjoern] joined
Kodi rakudo: 1/2 ~~ Rat 21:08
p6eval rakudo 528bf6: ( no output )
moritz_ colomon: precedence?
Kodi rakudo: say 1/2 ~~ Rat
p6eval rakudo 528bf6: OUTPUT«1␤»
moritz_ I'd try parens around the two conditions
jnthn The erorr is still odd 21:09
[bjoern] I think `regex SP { <[\x[0020] .. \x[0020]]> }` used to be okay, now I get syntax errors. What's the right syntax these days? (The regex simply matches one space)
moritz_ aye
jnthn I know where that error is because I added it recently from STD.
[bjoern] (used to be as in, a year ago)
moritz_ [bjoern]: backslash escapes in character classes are currently broken :(
so I'd try regex SP { ' ' } instead 21:10
[bjoern] any alternative that works for any unicode code point?
jnthn I'm bewildered as to why it's triggering though.
moritz_ [bjoern]: outside of char classes, \x[thing] should work
inside, you need to use the actual character :(
[bjoern] Thanks. 21:11
colomon moritz_: must be. bizarre
with parens, get a new error when it is run: Could not find sub &Rat 21:12
moritz_ colomon: use ::Rat instead
21:12 uniejo left
moritz_ it's probably defined later in the setting 21:12
colomon you sure? that's a detail I've never understood
moritz_ or you can pre-declare: class Rat { ... } # literal three dots
colomon (versus class Rat { ... } )
moritz_ the only thing there ::Rat doesn't work is in signatures (it's a type capture there) 21:13
s/there/where/
21:13 athomaso1 is now known as athomason
jnthn Oh...I know how on earth it got to that error. 21:15
moritz_ rakudo: & 21:16
p6eval rakudo 528bf6: OUTPUT«===SORRY!===␤Non-declarative sigil is missing its name at line 22, near "&"␤»
colomon moritz_++ # explaining to me what I had never gotten
jnthn std: my $factor; if $factor ~~ SomeUnknownType && $factor.denominator == 1 { }
colomon groovy, bug fixed.
p6eval std 31783: OUTPUT«===SORRY!===␤Non-declarative sigil is missing its name at /tmp/C1aRfuzVQ2 line 1:␤------> $factor; if $factor ~~ SomeUnknownType ⏏&& $factor.denominator == 1 { }␤Undeclared name:␤ 'SomeUnknownType' used at line 1␤Check failed␤FAILED 00:01
..120m␤»
jnthn Ah, OK. Rakudo is following STD there at least.
std: &
p6eval std 31783: OUTPUT«===SORRY!===␤Non-declarative sigil is missing its name at /tmp/WABl8Ek5J0 line 1:␤------> <BOL>⏏&␤Preceding context expects a term, but found infix & instead at /tmp/WABl8Ek5J0 line 1:␤------> <BOL>⏏&␤Parse failed␤FAILED
..00:01…
jnthn And there. 21:17
moritz_ shouldn't it complain about finding an infix in term position?
jjore_ In the #perl6 channel topic, what on earth is this part supposed to be? \x{08bb}\x{08f6}\x{08ab}
jnthn I agree it's sub-optimal though.
moritz_ std: ~~
p6eval std 31783: OUTPUT«===SORRY!===␤Expecting a term, but found either infix ~~ or redundant prefix ~␤ (to suppress this message, please use space between ~ ~) at /tmp/q8dvazWYr1 line 1:␤------> ~~⏏<EOL>␤Parse failed␤FAILED 00:01 115m␤»
tadzik x
jjore_: ascii camelia maybe?
jnthn moritz_: No, see token variable
Tene jjore_: text version of camelia
jjore_ It's not utf-8. I can't find those characters in the Unicode database.
colomon std: my $factor; if $factor ~~ Int && $factor.denominator == 1 { }
tadzik ah, not ascii ;)
moritz_ jnthn: it is UTF-8
p6eval std 31783: OUTPUT«ok 00:01 117m␤»
Tene .u »ö«
phenny U+00BB RIGHT-POINTING DOUBLE ANGLE QUOTATION MARK (»)
U+00F6 LATIN SMALL LETTER O WITH DIAERESIS (ö)
U+00AB LEFT-POINTING DOUBLE ANGLE QUOTATION MARK («)
moritz_ erm, meant jjore_
Tene jjore_: that's what the characters are
jnthn moritz_: It's meant to catch things like 21:18
jjore_ Oh, well, hmm. But I said \x{08bb}\x{08f6}\x{ab}, not \x{bb}\x{f6}\x{ab}
TimToady infix where term expected is kind of a last-ditch error if something else doesn't panic first
jnthn std: say $;
p6eval std 31783: OUTPUT«===SORRY!===␤Unsupported use of $; variable; in Perl 6 please use real multidimensional hashes at /tmp/BxKP4UHLrV line 1:␤------> say $;⏏<EOL>␤Parse failed␤FAILED 00:01 115m␤»
jnthn oh arse
std: say $
p6eval std 31783: OUTPUT«===SORRY!===␤Non-declarative sigil is missing its name at /tmp/RMkdWC6qRd line 1:␤------> say ⏏$␤Confused at /tmp/RMkdWC6qRd line 1:␤------> say $⏏<EOL>␤ expecting twigil␤Other potential difficulties:␤ Unsupported use of
..b…
jnthn There
Or
moritz_ jjore_: there's no \x{08bb} in the channel topic
jjore_ There is.
jnthn std: my @x; ($, $) = @x;
p6eval std 31783: OUTPUT«===SORRY!===␤Unsupported use of $, variable; in Perl 6 please use .join() method at /tmp/9SRIdZLrm2 line 1:␤------> my @x; ($,⏏ $) = @x;␤Parse failed␤FAILED 00:01 116m␤»
moritz_ jjore_: if you see it, your client doesn't properly decode the UTF-8
Tene jjore_: it's UTF-8 encoded
jnthn heh heh
Tene jjore_: utf-8 bytes != unicode codepoints 21:19
jnthn TimToady: Well, I know what it's meant to catch, but... :-)
moritz_ the byte sequence is c2 bb c3 b6 c2 ab
which decodes perfectly fine as UTF-8
21:20 snarkyboojum joined
jjore_ sigh. 21:20
I'm not fond of utf-8.
moritz_ well, we use it here pretty heavily
irclog.perlgeek.de/perl6/today should work in your browser
Tene jjore_: That's perfectly understandable. I wouldn't be fond of it either if I had to use software that didn't handle encodings properly. 21:21
colomon rakudo: say (1, 2, 4 ... 100).perl 21:22
jjore_ I'm told www.emacswiki.org/emacs/ErcConfiguration#toc11 but well...
p6eval rakudo 528bf6: OUTPUT«(1, 2, 4, 8/1, 16/1, 32/1, 64/1)␤»
colomon > say (1, 2, 4 ... 100).perl
(1, 2, 4, 8, 16, 32, 64)
moritz_ \o/
moritz_ -> out
colomon \o 21:23
21:23 justatheory left
pugssvn r31784 | novus++ | Removed DateTime-strftime.t as it is moving to an external project. 21:25
Tene jjore_: there's not much emacs usage mentioned in here. I did see some perl6 support files for emacs in the pugs repo, I think, but I expect they haven't been maintained. That's a little unfortunate.
21:25 cuesta joined 21:26 cuesta left
tylercurtis Tene, jjore_: From my experience, the cperl-mode.el in the pugs repo works fine except for sometimes failing to detect Perl-6-ness, total failure to support recognize the end of =begin/=end style POD, and sometimes having weird indentation for pointy-blocks(usually related to the first problem). 21:28
dalek kudo: 1d4ba47 | (Martin Berends)++ | Test.pm:
[Test.pm] use pir::time__N for the fractional seconds removed from time
jjore_ I haven't even got that far. I'd just like to be able to talk to you folks.
wolverian jjore_: what version of emacs are you running that erc doesn't grok utf-8 automatically? 21:29
Tene jjore_: We're glad to have you. :)
jjore_ Apparently emacs 22.2.1. 21:30
supernovus Hmm, This Parrot cannot read bytecode files with version 8.0?
jjore_ Whatevs. 21:31
wolverian jjore_: upgrading to 23 might help. I'm not sure though.
tylercurtis jjore_: I think I've seen references to erc in someone's quit messages. I'll try searching to see whom it was.
jjore_ Supposedly all this is supposed to "just work" but since it doesn't, srsly, whatever.
wolverian yeah. annoying 21:32
[bjoern] Where would I find documentation of all the members of Regex::Match? 21:35
21:36 skids left
tylercurtis [bjoern]: NQP-rx Regex::Match or Perl 6 Match? 21:37
21:37 tadzik left
[bjoern] The latter 21:38
tylercurtis perlcabal.org/syn/S05.html#Return_v...om_matches is the spec.
[bjoern] Yeah that doesn't quite say "has method x and attribute y and method z" in a digestable form 21:39
tylercurtis github.com/rakudo/rakudo/blob/maste...e/Match.pm is Rakudo's implementation thereof, which inherits from NQP-rx's Regex::Match iiuc, Regex::Match being located at github.com/perl6/nqp-rx/blob/master.../Match.pir
jnthn rakudo: say Match.^methods(:local).join(', ') 21:40
p6eval rakudo 528bf6: OUTPUT«Str, list, at_key, hash, at_pos, caps, ast, chunks, Bool, defined, perl, create, of␤»
Tene rakudo: say Match.^attributes.perl
p6eval rakudo 528bf6: OUTPUT«Method 'attributes' not found for invocant of class 'P6metaclass'␤ in main program body at line 22:/tmp/Y2PLUHI6Cj␤»
[bjoern] Didn't .perl use to give a perl representation of the match or something like that?
21:40 justatheory joined
Tene [bjoern]: it still should 21:40
jnthn rakudo: 'omg a flying elephant' ~~ /<[aeiou]>/; say $/.perl 21:41
[bjoern] say $foo.perl gives me "Any()"
p6eval rakudo 528bf6: OUTPUT«Match.new(␤ # WARNING: this is not working perl code␤ # and for debugging purposes only␤ from => 0,␤ orig => "omg a flying elephant",␤ to => 1,␤)␤»
[bjoern] My version is from april apparently 21:42
jjore_ So I straced my irc client and watched the server send me the bytes "\302\273\303\266\302\253" 21:45
Trying that even in a plain shell doesn't even work nicely. So maybe it's something about my ludid ubuntu
Tene rakudo: sub handle(Match $m (:$from)) { say $m.perl; }; handle('foo'~~/f/);
p6eval rakudo 528bf6: OUTPUT«Method 'attributes' not found for invocant of class 'P6metaclass'␤ in 'Mu::Capture' at line 1196:CORE.setting␤ in 'handle' at line 1:/tmp/rZ2ZT0w8rL␤ in 'handle' at line 22:/tmp/rZ2ZT0w8rL␤ in main program body at line 22:/tmp/rZ2ZT0w8rL␤»
21:45 ashleydev joined
[bjoern] That's C2 BB C3 B6 C2 AB 21:46
Which is UTF-8
for the string in the topic
jnthn mberends: ping?
jjore_ yeah, so like I said, maybe it's an ubuntu or bash or xterm thing 21:47
Tene jjore_: echo -e '\xC2\xBB\xC3\xB6\xC2\xAB'
cono I have an error: PackFile_unpack: This Parrot cannot read bytecode files with version 8.0.
jjore_ I assume that's the same thing but in hex? I already ran echo $'\302\273\303\266\302\253' 21:48
cono just git pulled and rebuild perl
for any cod
jjore_ which comes out poorly.
cono code*
Tene Yeah, your version works fine for me too.
So, sounds right.
jnthn cono: Few people have mentioend that today. I think somebody mentioned nuking their Parrot checkout and getting a fresh checkout of that helped. 21:49
oh man...Zavolaj is...yeah...hosed. :/
cono jnthn: thanks
[bjoern] Ah .perl works with 2.6.0
supernovus Kodi: What is your username on github? 21:50
Kodi supernovus: KodiB.
21:50 Schwern joined
jjore_ Oh hey, telling *putty* to be in UTF-8 was also important. 21:50
jnthn pmichaud: ping, when you're back from talking :-) 21:51
pmichaud jnthn: pong
supernovus Kodi: Okay, you and masak have commit bits on the temporal-utils project, which now has DateTime::Utils, formerly DateTime::strftime. I'll submit a patch to have it removed from Rakudo's tree, and a request to have it as a "bundled module" in Rakudo *
Kodi Nifty. 21:52
jnthn pmichaud: Wait, I may not need you...I was previously doing Zavolaj by setting the $!do and that was not ending well after the various changes you did for closures. But it may be that .wrap works. 21:53
pmichaud jnthn: glad if I'm not needed :) 21:54
jnthn pmichaud: ah no, .wrap doesn't work etiher :-(
rakudo: sub foo() { say 41 }; &foo.wrap({ say 42 }); foo() 21:55
p6eval rakudo 528bf6: OUTPUT«42␤»
Kodi phenny: tell masak I implemented immutability for DateTimes and edited the spec and tests appropriately, and then, since I was on a roll, I did the same for leap-second validation. All that remains is some cleanup, and then I'll have a gist for you to look at.
phenny Kodi: I'll pass that on when masak is around.
jnthn pmichaud: OK, trait mods are invoked with the non-closure versions of the sub. (the static one)
pmichaud: I then replace the $!do in this in the current version. .wrap also replaces $!do
pmichaud: However, that doesn't seem to influce closures made from the block. 21:56
jjore_ So why are we so utf-8 happy when the world of editors and consoles and such *isn't* generally ok with utf-8?
pmichaud $!do is a property?
jnthn pmichaud: Which somehow seem to end up calling the same inner thing.
supernovus Kodi+=10
jnthn pmichaud: attribute last I had it
21:56 pmurias left
jnthn pmichaud: It's the Parrot sub, or at least was. 21:56
pmichaud jnthn: okay, attribute should work.
jnthn Let me check how you changed things :-)
pmichaud I don't think I changed that.
tylercurtis jjore_: because ASCII is culturally imperialistic. :)
jjore_ but it is what *works*
jnthn pmichaud: I didn't think so either. Something has changed enough though... 21:57
Kodi supernovus: You are very kind. :)
jnthn pmichaud: What are those !get_closure methods defined on?
pmichaud parrot;Sub, iirc
21:57 Kodi left
cono jnthn++ works ! :) 21:57
jnthn I do occasionally, yes. 21:58
Oh, you meant the Parrot suggestion :-)
pmichaud jnthn: yes, they're methods on parrot;Sub
jnthn pmichaud: ooh... hmm.
pmichaud: Ah...let me see if I follow this right.
cono jnthn: I mean mine p6 works after your helping :)
jnthn pmichaud: The Parrot sub is the center of attention now.
pmichaud jnthn: correct, because it's the only thing that has a unique identity 21:59
(at least, it's the easiest key)
jnthn cono: \o/ отлично!
tylercurtis jjore_: for some things, it does.
cono jnthn: I shocked!
jnthn pmichaud: Right, I'm just not too sure how to do .wrap now properly... 22:00
pmichaud where's .wrap defined?
jnthn pmichaud: Routine.pir 22:01
pmichaud: I haven't really re-done it properly yet for master or since the closure changes
pmichaud: It's kinda still "to do"
pmichaud yeah
jnthn pmichaud: I was faking it in Zavolaj by just replacing $!do
Which is kidna what I envisioned .wrap doing too 22:02
slavik jnthn: что происходит? 22:03
pmichaud replacing $!do on a clone is probably okay
Tene jnthn: while you're thinking about it, it'll be nice if you can get it working from a sub trait handler, too, btw.
jnthn Tene: That's _exactly_ what Zavolaj needs.
Tene: So yes :-)
22:03 cdarroch left
pmichaud jnthn: also, I suspect that you could turn your helpers into closures :-) 22:03
mberends jnthn: pong!
jnthn mberends: oh no Makefile fail! 22:04
mberends: namke is not at all happy about $(shell ... )
pmichaud: Yeah but in trait mods we don't have a clone.
mberends: I don't have enough Makefile-fu to really know what else to try there. 22:05
mberends: I can see what the aim is.
22:05 pyrimidine left
pmichaud jnthn: I think I have to refresh my .wrap memory to be of much help 22:06
jnthn pmichaud: OK
pmichaud: Anyway, I can best fix Zavolaj by making .wrap work sufficiently from trait_mod
tylercurtis O.o... you can have scripts inside block-quotes in HTML.
jnthn Can't you have scripts inside anything in HTML? :-) 22:07
pmichaud where does trait_mod invoke wrap, ooc?
jnthn pmichaud: Zavolaj has a trait_mod that currently does a pir::setattribute($routine, '$!do' thingy) 22:08
pmichaud: I'm looking to replace that with $routine.wrap(thigy);
pmichaud: It wouldn't actually call the original
pmichaud: In native call we just ignore the Perl 6 sub body. 22:09
22:09 alester left
TimToady sorear: there's already a parameter binding form of when: see S03:3616 22:10
tylercurtis jnthn: I suppose anything that allows inline. But it just seems that blockquote would have a specific exception: "you can have any block element, or scripts, in here".
jnthn huh, s03? :-)
22:10 jferrero joined
jnthn went looking in S04 :-) 22:10
supernovus May I request that someone with a proto commit bit add github.com/supernovus/temporal-utils to the modules list ? It's where I've moved the DateTime::Utils module providing strftime (and shortly, offset-in-seconds) 22:11
TimToady helps in grepping to know what it already looks like: when * -> $a, $b {...}
jnthn TimToady: oh, I was looking for "when ->" :-) 22:12
TimToady that would mean something else
that would be pattern matching with a lambda, and require another block after it 22:13
jnthn *nod*
TimToady: aye, makes sense
TimToady mind, that'd have roughly the same effect, if you put an empty block afgter
pmichaud jnthn: I can't think of any reason off the top of my head why assigning to $!do would no longer work. 22:14
jnthn pmichaud: because in !get_closure it does 22:15
do = clone self
Which assumes the original Parrot sub is being cloned
pmichaud okay, I'm just confused.
jnthn pmichaud: Unless by assign by mean like pir::copy 22:16
pmichaud I don't know nearly enough about Zavolaj or the wrap implementation to be of much help, I fear.
jnthn Rather than a setattribute on the $!do, which I guess is a bind
pmichaud: OK, let's step back from those.
pmichaud: Here's what I need to do.
pmichaud: We have some sub foo() { }
pmichaud: That compiles down to a Parrot Sub and we do !get_code on it to get the static code object, and !get_closure on it to get the dynamic one 22:17
pmichaud okay so far.
jnthn pmichaud: OK, so far wrap when somebody does foo() we need to not run the original Parrot sub
pmichaud: We need to run some new thing. 22:18
pmichaud so far so good. 22:19
jnthn OK, so my question is how do I specify that, when I make a call on foo() - the wrapper - then I should end up running some other Parrot sub instead of the original Parrot Sub?
22:20 Schwern left
pmichaud if I do &foo.wrap({ ... }), am I modifying the static code object or the dynamic one? 22:20
I think it must be the dynamic one.
cono Where can I find Buf class implementation ? 22:21
src/core/Buf.pm contain only a role
jnthn pmichaud: Potentially either. (more)
cono: There is just the role - it gets punned into a class when needed. 22:22
pmichaud: in the trait_mod, we are given the static code object.
22:22 justatheory left
jnthn pmichaud: Wrapping that should certainly affect all dynamic versions down the line. 22:22
cono jnthn: bug IO.read returns Buf.new
pmichaud I don't understand the trait_mod case. example or code, please?
cono but*
jnthn rakudo: multi trait_mod:<is>(Routine $r, :$native!) { $r.wrap({ say "native call" }); }; sub foo is native { say "oh noes" }; foo() 22:23
p6eval rakudo 528bf6: OUTPUT«===SORRY!===␤No applicable candidates found to dispatch to for 'trait_mod:<is>'. Available candidates are:␤:(Mu $child, Role $r)␤:(Routine $r, Any :default($default)!)␤:(Code $block, Any $arg?, Any :export($export)!)␤:(Mu $child, Mu $parent)␤:(Mu $type where ({ ... }), Any
..:rw($rw)…
jnthn rakudo: our multi trait_mod:<is>(Routine $r, :$native!) { $r.wrap({ say "native call" }); }; sub foo is native { say "oh noes" }; foo()
p6eval rakudo 528bf6: OUTPUT«oh noes␤» 22:24
jnthn pmichaud: ^^
cono: Yes. If you try to call a method on a role, it automatically generates a class that has the role composed into it.
cono: And then calls the method on the class.
cono wow
jnthn: ic, thanks )
jnthn rakudo: role Foo[$val] { has $.x = $val; }; say Foo[42].x; say Foo['pivo'].x 22:25
p6eval rakudo 528bf6: OUTPUT«Type objects are abstract and have no attributes, but you tried to access $!x␤ in main program body at line 22:/tmp/wC9Nw8VyCO␤»
jnthn oops!
rakudo: role Foo[$val] { has $.x = $val; }; say Foo[42].new.x; say Foo['pivo'].new.x
p6eval rakudo 528bf6: OUTPUT«42␤pivo␤»
jnthn Still have to instantiate it ;-)
:-)
pmichaud: Did you follow the example? 22:26
pmichaud jnthn: I'm working through it.
cono cool
pmichaud in this case, I think that trait_mod:<is> should be called with the static code object
yes?
jnthn pmichaud: I believe it is being yes
pmichaud so .wrap should be replacing the $!do of the static code object
jnthn I think we decided it had to be that way during the refactors.
pmichaud: Yes, it is. 22:27
pmichaud okay
I think I see the fix
just a second
jnthn pmichaud: The trouble is that replacing the $!do in the static code object does not influence the $!do of the dynamic code object.
k :-)
pmichaud did you try changing 22:28
do = clone self
to instead clone the $!do of the static code object
(in !get_closure) ?
in this way, the parrot Sub continues to be the handle to get static/dynamic code objects, but the cloning always comes from the static code object 22:29
cono rakudo: my @arr = 1,2,3; Buf[Str].new(@arr).[0].WHAT.say
p6eval rakudo 528bf6: OUTPUT«Int()␤»
pmichaud (which can have its $!do replaced)
22:29 rgrau_ left
cono It's because attribute typing is nto working? 22:29
jnthn cono: Yes
pmichaud: I didn't - that was the line I mentioned a few screenfulls back, but with little idea if I was being sane back then. :-) 22:30
pmichaud: The fact you've got there too suggests that maybe yes :-)
pmichaud jnthn: I suggest try that and see what happens. I *think* it should work.
22:31 jaldhar left
jnthn pmichaud: Compiling. 22:31
22:31 jaldhar joined
tylercurtis cono: Buf stuff probably will not work anything like you expect for Buf[Str]. You want to pass in some kind of integral type to Buf. 22:32
pmichaud jnthn: have a diff I can look at real quick to see if I see anything odd? 22:33
(a diff for !get_closure)
22:34 gbacon left
jnthn pmichaud: gist.github.com/485246 22:34
tylercurtis Is Buf supposed to be a role or a class?
pmichaud jnthn: yeah, that looks reasonable. 22:35
jnthn tylercurtis: It's type-parametric I think, so role is sane.
pmichaud jnthn: I hope that works. It doesn't set off alarm bells in my head, and I agree that the do = clone self isn't going to work out.
22:35 zamolxes joined
pmichaud just make sure whatever you stick in the $!do is reliably clone-able :) 22:35
jnthn pmichaud: looks promising 22:36
tylercurtis S32/Containers says class, but S02 says role.
22:36 Schwern joined, jaldhar left
jnthn pmichaud: With that patch, Zavolaj works again without changes. \o/ 22:37
tylercurtis jnthn++, pmichaud++ 22:38
jnthn pmichaud++ # thanks! :-) 22:39
.wrap doesn't quite work but I know .wrap is generally a bit busted anyway
22:39 colomon left
jnthn So that's maybe not even related 22:39
pmichaud .wrap should be fixable along the same lines now, though.
jnthn pmichaud: Right.
pmichaud anyway, glad to help on short notice. 22:40
jnthn pmichaud: Will spectest and push if this works.
pmichaud +1
jnthn++
jnthn er, if it passes
:-)
Anyway, that fixes Zavolaj up, hopefully.
pmichaud as I said, I can't think of any alarm bells for it.
so, I'm pretty comfortable with the change.
jnthn pmichaud: Yes, was a little less than keen to touch that code without running things by you first though. It's still quite new. 22:41
pmichaud it's also good for me to know that change was made (and why, and what it means overall)
I didn't have the use case in my head until this conversation :)
it's snack time here, so I'll bbiaw 22:42
jnthn kk
cono tylercurtis: What integral types besides Int? 22:43
tylercurtis cono: mostly the native types, I think.
jnthn Aye
int8, int16, etc. 22:44
Not implemented just yet.
tylercurtis jnthn: Although probably uint8, uint16 is usually what is desired for Buf.
cono :(
jnthn tylercurtis: aye 22:45
I expect to implement them in the next few months.
cono pack needs Buf, Buf needs integral types and method types which are not implemented... 22:46
ok, I guess I can emulate pack by doing ~|, ~& ... 22:48
22:48 jaldhar joined
jnthn cono: If you're interested in pack, also talk with masak, who is very interested in working on that too. 22:51
cono ok, thanks, I will :) 22:53
22:55 justatheory joined
jnthn afk for a bit 23:00
supernovus DateTime::Utils now has a iso-offset() function, that lets you do things like: DateTime.now(:timezone(iso-offset('-0800'))); 23:03
23:03 justatheory left 23:04 Schwern left, justatheory joined 23:05 supernovus left 23:23 nimiezko left 23:29 zamolxes left 23:32 justatheory left 23:35 timbunce joined, felliott left 23:36 zamolxes joined 23:39 justatheory joined 23:40 justatheory left 23:41 justatheory joined 23:42 justatheory left 23:43 tadzik joined 23:45 justatheory joined, justatheory left
tylercurtis Is there a "is required" or similar trait for attributes? 23:48
23:51 Schwern joined
tadzik I don't think so 23:51
you can have $.attr = die "attr is required"
hmm, I've ported File::Find but the usage is a bit different than Perl5's one 23:54
tylercurtis std: class Foo { has $.attr = die "attr is required" }
p6eval std 31784: OUTPUT«ok 00:01 118m␤»
tylercurtis rakudo: class Foo { has $.attr = die "attr is required" }; Foo.new; say "alive"
p6eval rakudo 1d4ba4: OUTPUT«attr is required␤ in <anon> at line 22:/tmp/WJSJJY6NhU␤ in main program body at line 22:/tmp/WJSJJY6NhU␤» 23:55
tylercurtis rakudo: class Foo { has $.attr = die "attr is required" }; Foo.new(:attr(5)); say "alive"
p6eval rakudo 1d4ba4: OUTPUT«alive␤»
tylercurtis tadzik++, thanks.
tadzik you're welcome
tylercurtis: ever used Perl 5's File::Find?
tylercurtis tadzik: No; I haven't done much Perl 5 at all. 23:56
tadzik I see
23:57 Psyche^ joined
cono I used much, but never used File::Find :) 23:57
tadzik :) Wanna share thoughts? 23:58
cono about? 23:59
tadzik Perl 5's File::Find fires a callback on every file it found. The callback takes no arguments, but can get the current filename, path, and directory name from external variables. My version just passes the whole path to the callback
also it does not chdir(). I wonder how bad it is, and what advantages does original approach have