»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:, niecza:, std:, or /msg p6eval perl6: ... | irclog: irc.perl6.org/ | UTF-8 is our friend!
Set by sorear on 4 February 2011.
gfldex moritz, japhb: i had my own shot at search for doc using some fancy html5 stuff: github.com/gfldex/perl6-doc 00:08
you may want to nick some ideas
lichtkind gfldex: i will steal all your good docs !!! 00:10
gfldex but but but i did not do any doc stuff!
but if i did you could search for them in a fancy html5 way :) 00:11
and i learned a relyable way to crash firefox :D
var worker = new Worker; console.log(worker); 00:12
lichtkind gfldex: is that some special ff functionality?
gfldex: hwat you mean search in html 5 way?
sinc etablets are mostly html now i could use that 00:13
gfldex lichtkind: developer.mozilla.org/en/Using_web_workers 00:14
does that mean i could crash your fancy tablet? :->
lichtkind gfldex: its just a webpage 00:16
gfldex if your OS is a brower crashing that browser (see Chrome OS) becomes fairly annoying 00:17
lichtkind i see thanks
gfldex: i switched to mint
and use only ff and opera
gfldex: i check you project later or you maybe can write a blog post when you have results 00:22
gfldex i love to make propaganda, will do that tomorrow 00:23
00:37 crab2313 left
lichtkind gfldex: good and good night 00:48
00:50 sudokode left 00:55 Chillance left 00:58 am0c joined 00:59 lichtkind left 01:28 Guest62034 left 01:40 woosley joined 01:59 am0c left 02:00 am0c joined 02:07 cognominal__ left, cognominal__ joined 02:08 plutoid joined 02:10 orafu left 02:15 orafu joined 02:17 _jaldhar left 02:28 jaldhar joined
dalek ast: e008bab | coke++ | S03-operators/short-circuit.t:
pugs fudge
02:36
02:37 Psyche^ joined 02:38 libertyprime left, UncleFester6 left 02:39 dayangkun joined 02:40 Patterner left, Psyche^ is now known as Patterner, tokuhiro_ left 02:41 tokuhiro_ joined 02:45 tokuhiro_ left 03:04 crab2313 joined 03:06 crab2313 left 03:16 sudokode joined 03:35 pupoque left 03:42 plutoid left 03:59 Tene left 04:13 crab2313 joined 04:22 crab2313 left 04:23 plutoid joined 04:25 daniel-s left, daniel-s joined 04:29 alvis left
moritz \o 04:46
04:50 daniel-s__ joined 04:53 daniel-s left 04:55 kaare_ joined
diakopter o/\ 05:02
moritz gfldex: I've given you commit access to perl6/doc/, I'm too lazy to maintain forks :-)
flussence: will look at your search stuff soon 05:03
sorry, meant gfldex again 05:10
sorry, meant gfldex againä
moritz not quite awake
gfldex: btw it's OK to depend on JSON::Tiny in htmlify 05:14
r: module A { our sub f { } }; say &A::f.package 05:22
p6eval rakudo 3ac8c7: OUTPUT«A()␤»
05:33 crab2313 joined 05:41 birdwindupbird joined 05:47 kaleem joined 05:57 Ex left, nodmonkey joined 06:00 adu joined 06:01 raiph joined
moritz fwiw the test summary from the toqast spectest still doesn't fit on a single screen page here 06:03
so I'm a bit surprised people are already module-smoking with it 06:04
tadzik the smoke results aren't too bad 06:05
tjs.azalayah.net/index.html
moritz that's the really surprising part :-) 06:09
06:09 nodmonkey left
benabik Perhaps it means we've only scratched the surface of the true power of perl 6? :-D 06:09
06:10 raiph left, DarthGandalf left 06:11 wtw joined 06:17 zhutingting joined 06:18 DarthGandalf joined 06:27 kresike joined
kresike good morning all you happy perl6 people 06:27
tadzik hey hey kresike
kresike hello tadzik o/ 06:28
tadzik commutees 06:30
06:35 dbr joined 06:36 GlitchMr joined 06:43 zhutingting left 06:50 Ex joined 06:52 pmurias left 06:55 cognominal__ left, cognominal joined 07:00 snearch joined 07:03 kurahaupo left 07:07 pjcj left 07:14 SamuraiJack joined
dalek c: bc2f16f | raiph++ | lib/Complex.pod:
fix typos
07:20
c: 530ae1a | raiph++ | lib/Cool.pod:
typos
07:23
07:26 pjcj joined 07:27 raiph joined
dalek c: ff444c5 | raiph++ | lib/Duration.pod:
grammaros
07:32
07:32 dalek left 07:33 dalek joined, ChanServ sets mode: +v dalek 07:34 crab2313 left 07:35 plobsing left, plobsing joined 07:36 nodmonkey joined 07:37 mattp_ left
dalek c: 6a5c446 | raiph++ | lib/EnumMap.pod:
typos
07:38
07:40 drbean left
dalek c: d6d28f0 | raiph++ | lib/Exception.pod:
typo
07:40
07:40 hoelzro|away is now known as hoelzro 07:42 drbean joined 07:43 fgomez left 07:51 cosimo_ joined 07:52 cosimo_ left
dalek c: ed534a5 | raiph++ | lib/Hash.pod:
typos (did "literal string keys" <> fix work?)
07:52
07:54 drbean left 07:55 drbean joined 07:56 daxim joined 07:57 drbean left 07:58 larks left, drbean joined 07:59 larks joined, snearch left 08:03 nodmonkey left
jnthn morning o/ 08:06
08:06 zhutingting joined
am0c morning! 08:07
jnthn hi am0c! :) 08:08
am0c hi jnthn! o/
dalek c: 9ad3bd4 | raiph++ | lib/IO.pod:
typos, grammaros, more consistent filetest list.
08:16
moritz \o 08:19
raiph++ # doc editing
08:21 raiph left
jnthn moritz: I'm curious to see the test output you get, to check it against mine. 08:32
moritz: It's more than one page here also. But a lot of test files have just one or a small number of tests failing. 08:33
masak morning! o/ 08:40
masak .oO( man, I wake up after jnthn... what's the world coming to? ) :P
arnsholt jnthn: Mind if I change the void * pointers in the rf of REGISTER_DYNAMIC_REPR to the correct function pointer types? 08:51
I'm trying to squash as many warnings as possible =) 08:52
08:52 fhelmberger joined
jnthn arnsholt: Should be fine. 08:55
09:07 bbkr joined 09:10 dayangkun left 09:12 adu left
arnsholt Cool 09:13
I'll typedef the types, so it should simplify the types of the wrap_object/create_stable pointers in the REPRs as well 09:14
moritz jnthn: the beginning isn't in my scroll buffer anymore, rest is at perlpunks.de/paste/show/500d1738.5257.1dc 09:20
09:24 crab2313 joined
jnthn Oddness... t/spec/S32-io/IO-Socket-INET.t and t/spec/integration/error-reporting.rakudo pass here. 09:24
09:27 dakkar joined
masak .oO( t/spec/S32-io/IO-Socket-INET.t *passing*? yeah, something must be wrong then ) 09:31
jnthn masak: Huh? It's tended to be a reliable pass on Windows for ages. :) 09:33
moritz jnthn: I have occasional failures in that test file on that machine, so nothing to worry about yet 09:35
masak yeah, I was on a slight hyperbola.
jnthn You're ALWAYS on a slight hyperbola!
moritz jnthn: perlpunks.de/paste/show/500d1b1c.18ac.2d8 09:36
jnthn oh...it's line numbers. 09:37
Ah...yeah, I'm not passing annotations on down to POST yet, no wonder... :)
masak jnthn: I'm unsure whether to take that as a scathing insult or a heartfelt compliment :P
since I'm on a hyperbola anyway, I'll do both.
moritz jnthn: and those tests still pass on your machine?
masak asymptotically approaches some infinities 09:38
jnthn moritz: Oh, it doesn't pass here.
moritz: It doesn't *run* here 'cus it is marked as #icu
moritz jnthn: ah 09:39
jnthn moritz: I really meant "it's not in my list of failing tests"...from the name it didn't seem likely to be a #icu one. :)
masak: It was a crappy attempt at an autopun akshually :P
masak oh! 09:40
:)
mathw approves at jnthn blog mentioning bubble contexts
masak++ is Zeno's hacker 09:41
09:42 Guest61847 joined
Guest61847 hi 09:42
masak hi, Guest61847.
mathw: url? 09:43
moritz mathw: which blog?
oh, blog.edument.se/2012/07/23/insights...12-part-2/ 09:44
twitter to the rescue
masak oh! haven't read that one yet.
Guest61847 just a fast question how do I extract matches in perl6 (ie perl5's m/(whatever)/ that goes in $n) 09:45
masak .oO( it's in a different bubble context to this channel ) :)
hoelzro Guest61847: try $/
masak r: my $x = "foo"; $x ~~ /(fo)/; say $0
p6eval rakudo 3ac8c7: OUTPUT«q[fo]␤␤»
masak Guest61847: like that.
hoelzro it's the "last match" variable
oh, I didn't realize that $N were still around 09:46
jnthn Yes, but they start at 0 like every other array index in Perl 6. :)
masak hoelzro: it's just an alias for $/[N]
09:47 mattp_ joined
moritz so you can say $/[*-1] for the last submatch 09:48
Guest61847 thanks :D 09:49
masak and if you have nested parentheses, the matches will end up nested in $/ 09:50
mathw r: my $x = "foo"; my $m = $x ~~ /(fo)/; say $m.WHAT; say $m[0];
p6eval rakudo 3ac8c7: OUTPUT«Match()␤q[fo]␤␤» 09:51
mathw ooh
masak r: my $x = "abcdef"; $x ~~ /ab(c(de)f)/; say $/[0]; say $/[0][0]
p6eval rakudo 3ac8c7: OUTPUT«q[cdef]␤ 0 => q[de]␤␤q[de]␤␤»
masak r: my $x = "abcdef"; $x ~~ /ab(c(de)f)/; say ~$/[0]; say ~$/[0][0]
p6eval rakudo 3ac8c7: OUTPUT«cdef␤de␤»
mathw r: my $x = "foo"; my $m = $x ~~ /(fo)/; say $m.WHAT; say ~$m[0];
p6eval rakudo 3ac8c7: OUTPUT«Match()␤fo␤»
mathw Guest61847: and you can save the Match object in another variable if you want to keep it around. 09:52
09:52 zhutingting left
moritz woah, perl6maven.com/introduction-to-perl6/ looks quite impressive 10:03
jnthn wow! 10:06
BinGOs but is is finished *duck* 10:07
jnthn maybe not, but it still looks useful *goose* 10:08
BinGOs >:)
GlitchMr perl6maven.com/authors
masak *swan*
GlitchMr wait... why I am in authors?
BinGOs Show me on the doll where Perl6 touched you. 10:09
GlitchMr And why this list is not sorted case insensitive
masak GlitchMr: maybe you contributed three dots somewhere or other.
tadzik I am there too, and looks like it's because the site links to my code: perl6maven.com/a/tadzik
perl6maven.com/projects
GlitchMr Is it based on GitHub nick? 10:10
masak looks like.
GlitchMr Also, I think I made two modules, but whatever
mathw even I'm there, presumably because I wrote form 10:11
tadzik we're famous!
mathw must add something to that again soon, but I'm in Perl 5 mode at the moment
hard enough to remember to put the parens around if conditions as it is 10:12
tadzik I'm more in Perl 5 mode these days too, but context switching isn't that bad :)
flussence just make them all postfix :)
GlitchMr Also, heh, I'm one of those guys which have uppercase characters in names
mathw had a weird bug last week, turned out to be caused by me putting hyphens in an identifier. It's not like I know any other languages that allow you to do that, but Perl 6 has baked itself so much into my head
moritz these days I usually remember to use the $ sigil in p5 when accessing elements of a hash, and then try to write $h<foo>;
tadzik perl6maven.com/introduction-to-perl6/perl6-proto -- this probably needs to be reviewed 10:13
mathw moritz: I've been trying to use pointies too
masak context-switching gets easier the more one does it.
GlitchMr I have it other way. In Perl 6, I usually type $hash<abc> when I want %hash<abc> :P
mathw masak: true. Also true in music.
masak and in a way it's useful to stumble on the differences between Perl 5 and Perl 6. it informs one's use of both. :)
GlitchMr: why you store your hash in a scalar... oh.
mathw yeah but then I get annoyed that I can't write "if $magic-fairies-count > 4"
masak is there a source filter yet that allows dashes in Perl 5 code? :P 10:14
mathw "if ($magic_fairies_count > 4)" clunky
GlitchMr Well, there is always ${'magic-fairies-count'} hack, but 10:15
1) It's a hack
2) It doesn't work under "use strict"
moritz I slowly realize that I want a statically typed sister language to Perl 6 10:16
one that allows me to use roles and grammars and meta ops
but with much more type safety than perl 6 is designed to provide 10:17
and maybe less type dwimmery (no list methods in Any etc.)
gfldex i'm building rakudo under cygwin and got a strange error message 10:18
0 [main] pbc_to_exe 3176 child_info_fork::abort: address space needed by 'os.dll' (0x160000) is already occupied
Can't spawn child process
any guesses what that could mean? 10:19
moritz hilights rurban who knows a lot about cygwin 10:20
10:22 seldon joined 10:26 not_gerd joined
not_gerd hello, #perl6 10:26
gfldex: welcome to the joys of Cygwin's fork emulation 10:27
you need to rebase your DLLs
10:29 mucker joined
mathw moritz: I might like such a language, but then I think actually why nhot just learn haskell 10:30
moritz mathw: I'd like that too, but somehow I'm having trouble with it every time I try 10:32
10:33 plutoid left
moritz mathw: I mean, it sounds all logical what the books write, and then they say that I don't need to understands monads early on to write some programs, just use them like *this*, and then I try with a similar example and get a type error 10:33
so I never got over the hump where you can actually start do solve problems (even simple problems) with haskell 10:34
and thus my motivation slowly fades away
and my daughter carries "Real World Haskell" to another corner of the room, and I forget about it 10:35
10:38 crab2313 left
moritz on a related note, on feeling stupid: jcs.biologists.org/content/121/11/1771.full 10:40
seldon Haskell is too pure to be useful, in my opinion. There are problems it can solve very elegantly, but there are also problems that cannot be solved in Haskell by people who value their sanity. Big tasks tend to include both types. 10:43
Give me grubby languages that look less pretty but have everything I need.
masak "too pure to be useful" could be said to be the core issue of LISP, as well. no doubt users of actual Lisps will disagree, though. 10:44
10:44 Guest61847 left
mathw The practicality of Haskell seems to go up a lot if you grok monads and applicative functors. 10:44
masak: lisp is pure syntactically, not semantically
seldon LISP compromises in the right places. 10:45
moritz one approach I take quite often is to build some functions which internally use mutable stable, but from the outside are pure
is there a nice encapsulation for that in Haskell? 10:46
mathw there are a handful of libraries which do that
unsafePerformIO :: IO a -> a
lets you do more or less anything you want
however
moritz however.
I meant, a proper solution
mathw 'unsafe' isn't put in trivially
the proper way is to use the IO monad
moritz mathw: the if I use the IO monad, my function looks differently from the outside, no? 10:47
mathw yes
moritz s/the/but/
but I don't want that. I only want to use the mutable state *INTERNALLY*
mathw you can't
moritz like, a hash table that never leaks to the outside
mathw introducing mutable state also introduces a dependency on ordering 10:48
pure Haskell code does not have a dependency on ordering
seldon init on first use kind of thing?
moritz seldon: more like "count the number of times each character is used in a string"
how'd you do it in perl?
masak mathw: I think I could make a case for Lisp being quite pure semantically... it has *seven* primitives with which you can define a full metacircular interpreter in half a page of code. 10:49
moritz sub c(Str $x) { my %chars; %chars{$_}++ for $x.comb; return %chars.pairs }
that's a pure function
but it relies pretty heavily on *internal* mutable state
mathw length $ filter (==c)
oh each character
hmm
have to think about that one a little longer 10:50
moritz and that's a pattern I'm very much use to
and I don't see a good reason why such a function should have a monad in its signature
mathw okay here's one way to do it 10:54
foldr (\l m -> insertWith (\n _ -> n + 1) l 1 m) (Data.Map.empty :: Map Char Int)
that's actually the same kind of thing going on, just with pure data structures 10:55
it returns a Data.Map of characters to character counts
Haskell requires you to think quite differently, I think that's where most people have serious trouble with it
Drives me up the wall sometimes, I'll admit 10:56
moritz mathw: so the answer is "you just have to find a different solution to your problem"? 10:58
mathw yes 10:59
moritz and, forgive me the heretic question, is the code efficient?
mathw that's the answer to most Haskell questions
moritz it looks like it just creates a new copy of the map for each character 11:00
mathw it does
theoretically anyway
seldon That's usual in FP. I'd be surprised if it weren't optimised away.
mathw in reality, the Map library is very smart and each 'copy' is just the same Map with a few nodes shifted around
and yes, the compiler's designed to optimise that sort of thing as much as it can 11:01
I'd be surprised if it was all that much worse than a mutable perl-style hash
it might even be faster 11:02
moritz that woud surprise me
perl 5's hashes are... quite fast 11:03
mathw yeah that's why I said 'might'
let's find out!
seldon You'd not actually need a hash for this, mind you.
not_gerd stackoverflow came up with toList $ fromListWith (+) [(c, 1) | c <- input] 11:04
mathw neat
that probably boils down to the same code I wrote
apart from the toList, that would give you a slightly different kind of answer 11:05
but it's just returning a list of pairs instead of the Map
moritz gist.github.com/3163118 11:08
I don't mind the exact output format
11:11 snearch joined
mathw okay 11:11
I'm having a slight delay while CPAN has a hissy fit (new system, my Perl environment isn't really right yet) 11:12
should've installed cpanminus already I know 11:13
flussence r: ([..] <a z>).roll(256).classify(*.ord).map({ $^c.key.chr => +$^c.value }).hash.perl.say 11:15
p6eval rakudo 3ac8c7: OUTPUT«("e" => 15, "i" => 12, "v" => 12, "z" => 11, "g" => 6, "c" => 10, "x" => 8, "n" => 9, "h" => 10, "l" => 14, "q" => 9, "o" => 10, "r" => 10, "f" => 14, "p" => 13, "t" => 7, "u" => 10, "a" => 10, "b" => 6, "j" => 9, "w" => 8, "y" => 11, "m" => 11, "d" => 8, "k" => 5,…
11:20 sergot joined
sergot hi o/ 11:20
masak sergocie! \o/
seldon moritz: That's 20 runs, do I read that correctly? 11:21
moritz seldon: yes 11:23
seldon That's pretty slow.
moritz and it's the contents of rakudo's README, repeated 100 times
so, 400k characters 11:24
seldon Yeah, but I get 5000 runs in the same time doing the same thing in C++.
arnsholt jnthn: Two questions. 1) Will box_funcs->get_str always return the same STRING * for our current Str type(s)? And 2) Parrot_str_to_encoded_cstring always return the same char *, given a STRING * and an encoding? 11:25
seldon codepad.org/hXZ9PYK0 <-- code for reference. Requires -std=c++11, tested with gcc 4.7 and -O3 11:27
It's much worse with a hashtable, but still 350 reps in the same time. 11:29
11:31 sergot left, sergot joined 11:33 Gesh joined
mathw okay my original way ploughs straight through the default stack size limits 11:34
but the variant not_gerd found on stack overflow behaves itself
although I just realised that it's probably doing the read-run-print cycle in 0.42 seconds because it's only actually counting the characters once 11:35
yes, changing it to only try once is precisely the same speed 11:36
I'm not actually sure how to persuade it to re-evaluate 11:37
the compiler's probably taking one look at the function call and saying "I know the answer to that, I did it just now"
jnthn arnsholt: What do you mean by "the same"? 11:38
seldon Can I see the code? I may have an idea.
jnthn arnsholt: Same chunk of memory, or same vaue?
*value
mathw should do some work really 11:40
arnsholt Good point. Same pointer, is what I'm after 11:41
jnthn arnsholt: I think 1 is certainly a "yes" though in so far as Str is immutable, so the underlying STRING* will not change.
arnsholt: 2 - I think it makes a new char* per call.
seldon mathw: xkcd.com/303/
arnsholt Right. That's a bit annoying
While killing warnings in the dyncall ops I've discovered that the CStruct and CArray write barrier functions don't actually handle the string case 11:42
11:45 JimmyZ joined 11:48 spider-mario joined
mathw seldon: yeah I know, but work is Perl today 11:48
seldon Oh. Carry on, then.
kresike bye all 11:49
11:49 kresike left 11:50 snearch_ joined, snearch_ left
mathw it's okay, I just landed a new feature, and will reward myself with lunch. 11:52
11:53 snearch left 12:00 skids left, gaber_ joined 12:01 gaber_ is now known as Guest13509
gfldex i solved my cygwin problem 12:06
masak \o/
gfldex cygwin comes with a script called rebaseall that wants to be run
12:09 daxim left, birdwindupbird left, erkan left, pyrimidine left, zb left, sorear left, shachaf left, lumi_ left, Exodist left, c1sung left, baest left, pnu left, zb joined 12:10 daxim joined, birdwindupbird joined, erkan joined, pyrimidine joined, sorear joined, shachaf joined, lumi_ joined, Exodist joined, c1sung joined, baest joined, pnu joined 12:16 xinming left, spider-mario_ joined 12:17 spider-mario left, spider-mario_ is now known as spider-mario, xinming joined 12:20 JimmyZ_ joined
gfldex r: gist.github.com/3163332 12:21
p6eval rakudo 3ac8c7: OUTPUT«===SORRY!===␤invoke() not implemented in class 'Capture'␤»
12:21 birdwindupbird left, erkan left, pyrimidine left, sorear left, shachaf left, lumi_ left, Exodist left, c1sung left, baest left, pnu left
gfldex i can haz line numbor? 12:21
n: gist.github.com/3163332
p6eval niecza v19-13-g442e075: OUTPUT«===SORRY!===␤␤Action method fakesignature not yet implemented at /tmp/iXUHzC0mJ6 line 1:␤------> multi a(&callback:(:$before, *@params⏏)) {␤␤Action method sigterm not yet implemented at /tmp/iXUHzC0mJ6 line 1:␤------> …
gfldex std: gist.github.com/3163332
p6eval std 3b49ac8: OUTPUT«Use of uninitialized value in string eq at STD.pm line 65720.␤Use of uninitialized value in string eq at STD.pm line 65721.␤Use of uninitialized value in string eq at STD.pm line 65720.␤Use of uninitialized value in string eq at STD.pm line 65721.␤===SORRY!… 12:22
12:22 JimmyZ left, JimmyZ_ is now known as JimmyZ
gfldex i feel a bit guilty now :) 12:22
12:22 birdwindupbird joined, erkan joined, pyrimidine joined, sorear joined, shachaf joined, lumi_ joined, Exodist joined, c1sung joined, baest joined, pnu joined
jnthn gfldex: The Rakudo error looks like you managed to explode the compiler. 12:23
gfldex r: gist.github.com/3163332 12:25
p6eval rakudo 3ac8c7: OUTPUT«===SORRY!===␤invoke() not implemented in class 'Capture'␤»
12:25 spider-mario_ joined
gfldex well, that typo was not the problem then 12:25
12:25 spider-mario_ left
moritz seldon: ah, while the hash tables are fast in perl 5, the loops are slow-ish compared to C/C++ 12:25
seldon *that* slow-ish? 12:26
12:26 spider-mario left
hoelzro masak++ 12:27
# for being brave enough to talk about Perl 6 on #ruby 12:28
tadzik {_ 12:29
:)
moritz seldon: yes 12:30
seldon Huh.
moritz seldon: there's a reason it's considered a valid optimization to rewrite tight loops in C
masak hoelzro: it's going rather well :) 12:31
those are nice people. 12:32
GlitchMr eval: say ([1, 2] => [3, 4]){[1, 2]} 12:33
buubot_backup GlitchMr: ERROR: syntax error at (eval 20) line 1, near "){"
GlitchMr perl6: ([1, 2] => [3, 4]){[1, 2]} 12:34
p6eval rakudo 3ac8c7: ( no output )
..niecza v19-13-g442e075: OUTPUT«Unhandled exception: Cannot use hash access on an object of type Pair␤ at <unknown> line 0 (ExitRunloop @ 0) ␤ at /home/p6eval/niecza/lib/CORE.setting line 354 (Any.at_key @ 9) ␤ at <unknown> line 0 (ExitRunloop @ 0) ␤ at /tmp/mEn43wyYvy line 1 (mainli…
GlitchMr perl6: say ([1, 2] => [3, 4]){[1, 2]}
p6eval niecza v19-13-g442e075: OUTPUT«Unhandled exception: Cannot use hash access on an object of type Pair␤ at <unknown> line 0 (ExitRunloop @ 0) ␤ at /home/p6eval/niecza/lib/CORE.setting line 354 (Any.at_key @ 9) ␤ at <unknown> line 0 (ExitRunloop @ 0) ␤ at /tmp/JxUNT3cFj2 line 1 (mainli…
..rakudo 3ac8c7: OUTPUT«3 4␤»
hoelzro masak: they tease a little bit, but they're not too bad, no =)
gfldex r: sub a(&callback:(@params)) {} 12:36
p6eval rakudo 3ac8c7: OUTPUT«===SORRY!===␤invoke() not implemented in class 'Capture'␤»
gfldex golfed :)
std: sub a(&callback:(@params)) {}
p6eval std 3b49ac8: OUTPUT«Use of uninitialized value in string eq at STD.pm line 65720.␤Use of uninitialized value in string eq at STD.pm line 65721.␤Potential difficulties:␤ callback:(@params):: is declared but not used at /tmp/BbSft47vkA line 1:␤------> sub a(&callback:(@params)) {}[…
gfldex the @param is optional too 12:37
GlitchMr perl6: my $pair = [1, 2] => [3, 4], [1] => [3]; say $pair{[1, 2], [1]}; 12:40
p6eval niecza v19-13-g442e075: OUTPUT«Unhandled exception: Cannot use hash access on an object of type Pair␤ at <unknown> line 0 (ExitRunloop @ 0) ␤ at /home/p6eval/niecza/lib/CORE.setting line 354 (Any.at_key @ 9) ␤ at <unknown> line 0 (ExitRunloop @ 0) ␤ at /tmp/sON_TykwY2 line 1 (mainli…
..rakudo 3ac8c7: OUTPUT«3 4 Mu()␤»
GlitchMr perl6: my $pair = [1, 2] => [3, 4], [1] => [3]; say $pair<1 2>;
p6eval niecza v19-13-g442e075: OUTPUT«Unhandled exception: Cannot use hash access on an object of type Pair␤ at <unknown> line 0 (ExitRunloop @ 0) ␤ at /home/p6eval/niecza/lib/CORE.setting line 354 (Any.at_key @ 9) ␤ at <unknown> line 0 (ExitRunloop @ 0) ␤ at /tmp/Ocu5qDN6J8 line 1 (mainli…
..rakudo 3ac8c7: OUTPUT«Mu() Mu()␤»
moritz note that hash keying only makese sense for value types 12:41
GlitchMr r: my $pair = [1, 2] => [3, 4], [1] => [3]; say $pair{'1 2'};
p6eval rakudo 3ac8c7: OUTPUT«3 4␤»
GlitchMr r: my $pair = [1, 2] => [3, 4], [1] => [3]; say $pair{'1 23'};
p6eval rakudo 3ac8c7: OUTPUT«Mu()␤»
GlitchMr ok...
moritz and pair doesn't necessarily stringify
gfldex closure paramters seam to be skipped by rakudo in the spec test. Is that intentional? 12:43
moritz gfldex: can you be more specific please? 12:44
gfldex github.com/perl6/roast/blob/master...s.t#L6-L73
says #?rakudo skip
moritz gfldex: that syntax is NYI 12:45
gfldex that makes me a little sad
moritz then implement it :-)
gfldex i'm afraid that's beyond my capabilities 12:46
GlitchMr perl6: print atan2 1 12:48
p6eval rakudo 3ac8c7: OUTPUT«0.785398163397448»
..niecza v19-13-g442e075: OUTPUT«0.78539816339744828»
gfldex p6: role BeforeCallback {}; sub cb1 does BeforeCallback {}; 12:49
p6eval rakudo 3ac8c7: OUTPUT«===SORRY!===␤Cannot call 'trait_mod:<does>'; none of these signatures match:␤:(Mu:U $doee, Mu:U $role)␤␤»
..niecza v19-13-g442e075: OUTPUT«===SORRY!===␤␤Unhandled trait does for this context at /tmp/H4mZYRa8RC line 1:␤------> allback {}; sub cb1 does BeforeCallback ⏏{};␤␤Potential difficulties:␤ &cb1 is declared but not used at /tmp/H4mZYRa8RC line 1:␤---…
gfldex std: role BeforeCallback {}; sub cb1 does BeforeCallback {};
p6eval std 3b49ac8: OUTPUT«ok 00:00 40m␤»
gfldex is std right in this case?
moritz gfldex: it's correct syntactically 12:50
gfldex: and that's the only thing that std checks
gfldex: but, a role isn't a trait
GlitchMr perl6: 40.chars
p6eval rakudo 3ac8c7, niecza v19-13-g442e075: ( no output )
GlitchMr Just wondering, why .chars is in Cool?
timotimo perl6: say 40.chars
p6eval rakudo 3ac8c7, niecza v19-13-g442e075: OUTPUT«2␤» 12:51
12:51 not_gerd left
timotimo well, it operates on strings, and anything in Cool can be treated as a string in some sensible manner 12:51
GlitchMr Actually, does any string coercing method make sense for anything else
20.sprintf is useless
12:51 PacoAir joined
moritz r: say 12345.split(3).perl 12:51
p6eval rakudo 3ac8c7: OUTPUT«("12", "45").list␤»
moritz r: say <a b c d e>.split('c').perl 12:52
p6eval rakudo 3ac8c7: OUTPUT«("a b ", " d e").list␤»
moritz depends on your definition of "sense"
GlitchMr But I guess that 2e300.uc has some sense
timotimo oh my, list.split could cause some confusion all right
r: say 2e30.uc 12:53
p6eval rakudo 3ac8c7: OUTPUT«2E+30␤»
timotimo r: say 0xff.uc
p6eval rakudo 3ac8c7: OUTPUT«255␤»
GlitchMr also you can split list... what?
WHAT?
timotimo no, you can't, it coerces into a string before that
GlitchMr I know it coerces, but still
tadzik it behaves like a Perl 5 scalar will do
masak garbage in, garbage out.
tadzik if you use string-ish functions, it becomes a string first 12:54
GlitchMr I mean, length %ENV in Perl 5 gives 5...
Probably to mark that this is Perl 5 or something
tadzik eval length %ENV
buubot_backup tadzik: 5
GlitchMr But probably it's some garbage 12:55
moritz eval scalar %ENV
buubot_backup moritz: 12/16
moritz now you know what's 5 characters long
perldoc perldata # if you want to know what those mean
jnthn It's very typical of Perl to have operations that have consistent semantics, coercing the operands if needed, rather than using types to overload multiple meanings on one operator. 12:56
GlitchMr Except in Perl 6 'abc' ~~ 'a.c' won't do what I mean... =~ in Perl 5 is fine
jnthn (And thus operator overloading is more about saying how a given type provides a semantic rather than giving alternative semantics for different types, as is typical in some other languages.)
moritz GlitchMr: but it does what I mean 12:57
GlitchMr Just something else
jnthn Smart-matching has very consistent semantics.
GlitchMr I know that in this case it's eq
moritz GlitchMr: because I say rx/a.c/ if I mean a regex
jnthn given LHS { RHS.ACCEPTS(LHS) } # or so
moritz "or so" is the interesting part 12:58
GlitchMr But what if I've string and I want to check if it matches regex
eval?
gfldex r: say 'abc' ~~ /a.c/;
p6eval rakudo 3ac8c7: OUTPUT«q[abc]␤␤»
moritz rx/ <?{ $str }> / iirc 12:59
I need it surprsingly seldom
GlitchMr perl6: my $regex = 'abc'; say 'abc' ~~ / <?{ $regex }> / 13:00
p6eval rakudo 3ac8c7: OUTPUT«q[]␤␤»
..niecza v19-13-g442e075: OUTPUT«#<match from(0) to(0) text() pos([].list) named({}.hash)>␤»
jnthn perl6: my $regex = 'abc'; say 'abc' ~~ / <$regex> / 13:01
p6eval niecza v19-13-g442e075: OUTPUT«#<match from(0) to(3) text(abc) pos([].list) named({}.hash)>␤»
..rakudo 3ac8c7: OUTPUT«q[abc]␤␤»
moritz oh
:-)
perl6: my $regex = 'a.c'; say 'abc' ~~ / <$regex> /
p6eval niecza v19-13-g442e075: OUTPUT«#<match from(0) to(3) text(abc) pos([].list) named({}.hash)>␤»
..rakudo 3ac8c7: OUTPUT«q[abc]␤␤»
13:09 daniel-s__ left, bluescreen10 joined 13:10 daniel-s__ joined 13:11 preflex_ joined 13:12 preflex left, preflex_ is now known as preflex
felher Hm. Whats the difference between 'nqp::unbox_someting' and 'nqp::p6decont'. I thought maybe 'decont' stands for 'decontainerize'. But isn't it the same as unbox, then? 13:13
jnthn No 13:14
unbox is object => native type
decontainerize means "remove the scalar container"
moritz think of a "container" like a reference or a pointer
13:19 kaleem left
felher What do i get, if i decont an object? it seems like i can still bind and assign it to whatever i want. 13:19
moritz you get the object :-) 13:20
what you had before might have been the object inside a container
my $x = 3; # $x is a container holding an Int of value 3
my $x := 3; # $x directly is the Int of value 3, you can't assign to it anymore 13:21
decont(my $x = 3) gives you the 3 without the container
jnthn r: my $x; $x = 3;
p6eval rakudo 3ac8c7: ( no output )
jnthn r: my $x; nqp::p6decont($x) = 3;
p6eval rakudo 3ac8c7: OUTPUT«Cannot assign to a non-container␤ in block <anon> at /tmp/n349vGrcXJ:1␤␤»
moritz jnthn++
r: my $x := 3; $x = 5 13:22
p6eval rakudo 3ac8c7: OUTPUT«Cannot assign to a non-container␤ in block <anon> at /tmp/AvdNUEh140:1␤␤»
jnthn Also that. :)
moritz r: my $x = 3; $x = 5; # modifies the container, not the 3
p6eval rakudo 3ac8c7: ( no output )
jnthn Basically, "my $x" allocates a scalar container. Assignment puts stuff into the container.
These containers "evaporate" in most operations.
But you can get at it. 13:23
r: my $x = 3; say $x.WHAT; say $x.VAR.WHAT;
p6eval rakudo 3ac8c7: OUTPUT«Int()␤Scalar()␤»
jnthn r: my $x = 3; say $x.WHAT; say $x.VAR.name
p6eval rakudo 3ac8c7: OUTPUT«Int()␤$x␤»
felher Ah okay. I think i got it now. Thanks :)
jnthn++, moritz++ 13:24
So unbox_i will return an native int and not a container with a native int in it? 13:27
Ah, seems like perl6 containers can only hold perl6 values. :) 13:28
moritz Int can box an int
and Str can box a str 13:29
but, an Int can also hold bigints that don't fit into int
so there are basically two differences: boxing is stricter typed than containering, and the boxing class can do much more than the containers we discussed earlier 13:30
also note that nqp::p6box_i is actually a shorthand for nqp::box_i($arg, Int) 13:31
you could box an int into other types too
13:31 skids joined 13:33 ggoebel left
felher Ah. And if i have a subroutine sub s($x) { ... } and i call it with s(nqp::unbox_i(3)), it automatically gets boxed into an Int and then assigned to $x? 13:35
moritz yes 13:37
felher great :)
13:37 Ex left
felher So my last question is: is this known to segfault? 13:37
r: my $x := nqp::unbox_i(3); $x = 4
p6eval rakudo 3ac8c7: OUTPUT«(signal SEGV)»
13:38 kaleem joined, pnu left, ggoebel joined
moritz no 13:38
but it's not a bug either 13:39
13:39 pnu joined
moritz if you use := and nqp:: ops, you'd better know what you're doing :-) 13:39
timotimo r: my $x := 3; $x = 4; say $x; 13:40
p6eval rakudo 3ac8c7: OUTPUT«Cannot assign to a non-container␤ in block <anon> at /tmp/OxQGhb_nq9:1␤␤»
timotimo mhm, mhm.
felher Yeah :) But why don't i get the message that timotimo got? <- this is not a critic. Just a i-want-to-understand-type-of-question.
* criticism 13:41
moritz felher: because 3 is an Int here, and nqp::unbox_i(3) is an int
well, 3 is a literal that can act polymorphically both as an int and Int
and it only acts as an int when we know at compile time that it's better that way
timotimo felher: you spelt your name wnorg! 13:42
felher timotimo: yeah, it is an erorr. 13:43
moritz: k, thanks :)
or mistkae
timotimo moritz: do you know any good examples where binding and compile-time binding (:= and ::= respectively iirc) are useful? 13:44
misskate, is that when you bring inline skates to a frozen lake?
felher :D 13:45
timotimo at first i thought "it's kind of like having constant values", but that's not true, since you can a) bind mutable data structures and b) bind other containers, like my $y ::= $x 13:46
moritz miss kate lives next, I think
*next door
timotimo: ::= is read-only binding like in signatures, iirc 13:47
timotimo i do recall, that it's the same mechanism that's used when a parameter of a function or method is declared "is rw" or when i return-rw
binding containers, that is
moritz timotimo: and := is very useful if you want to put something else than an Array into a @-sigiled var 13:48
my @a := (1, 2, 3); # not an Array
timotimo r: my @a := (1, 2, 3); my @b := [1, 2, 3]; say @a.perl, " ", @b.perl
p6eval rakudo 3ac8c7: OUTPUT«(1, 2, 3) Array.new(1, 2, 3)␤»
timotimo r: my @a := (1, 2, 3); my @b := [1, 2, 3]; say @a[0].perl, " ", @b[0].perl
p6eval rakudo 3ac8c7: OUTPUT«1 1␤»
timotimo r: my @a = (1, 2, 3); my @b = [1, 2, 3]; say @a[0].perl, " ", @b[0].perl 13:49
p6eval rakudo 3ac8c7: OUTPUT«1 [1, 2, 3]␤»
timotimo that's cute
moritz timotimo: and many things in the setting need to preserve the containerness of an object. So my $temp := something(); # now $temp is only a container if something() returned a container
timotimo what's an example of a non-container that something() could return? like nqp::unbox_i(3) in felhers example above? 13:51
hm, wouldn't return nqp::unbox_i(3) create a container implicitly?
rurban gfldex: address space needed by 'os.dll' (0x160000) is already occupied => An image base of 0x160000 is completely invalid for user dll's
13:51 MayDaniel joined
moritz timotimo: 3 13:52
timotimo: a simple Int value
timotimo: or a string
rurban I have to check the linker flags. Normally this may not happen.
gfldex rurban: thanks, i solved that riddle by running rebaseall
rurban if os.dll is handled by rebaseall it's good.
timotimo moritz: ah, so a non-container would be an "immutable value" in my intuition?
jnthn t: my $x := nqp::unbox_i(3); $x = 4 # curious 13:53
p6eval toqast : OUTPUT«Cannot assign to a non-container␤␤»
jnthn Well, there's one segfault toqast avoids us :) 13:54
moritz timotimo: yes, but it could be any user-supplied object too
13:56 cognominal_ joined 13:58 cognominal left, thou joined
timotimo moritz: i'm not sure i understand. what would the user-supplied object have to look like to be a container/non-container type value? 14:05
is it just a class in the hierarchy that i'd have to derive froms
14:07 am0c left
moritz for the purpose of n6p::p6decont, it would have to derive from Scalar or Proxy 14:11
to be a container ojbect
thou masak: hi! the july 21 blog post (too dark in here) has the wrong link for the 2nd commit; it should be: github.com/masak/crypt/commit/bc2b...d39c6f0d4e 14:12
moritz gives thou++ the title "reviewer of July" 14:13
thou :-) 14:14
14:18 nodmonkey joined 14:19 snearch joined
[Coke] thou++ 14:20
seen ingy?
aloha ingy was last seen in #parrot 20 hours 7 mins ago joining the channel.
[Coke] phenny: tell ingy I'm keeping pugs warm for him.
phenny [Coke]: I'll pass that on when ingy is around.
[Coke] p: say 20612/2 - 9206 # tests needed to get to 50% of niecza 14:21
p6eval pugs: OUTPUT«1100␤»
masak thou: thanks, will fix.
tadzik hihi. When pugs will be half niecza, it could be nicknamed "nic"
masak seems I have an insufficiently accurate process for adding those links...
thou yw
masak thou: could you find some bugs in the game, as well? there's a prize ;) 14:22
timotimo tadzik: i'd call it "niet"
tadzik hehe. But, contrary to popular belief, there's no "t" sound in the pronouncation of niecza :) 14:23
masak tadzik: says you :P
tadzik says me :)
that reminds me of the reason why X is the unknown in maths 14:24
masak you should heed the true experts in slavic-language phonology... :P
mathw if I have a string which is known to be a substring of another string how can I get a string which contains the extra bits which the superstring has that the substring doesn't?
tadzik "Because there's no ‘sz’ in Spanish"
[Coke] in p5: $oldstring =~ s/$substr//;
masak tadzik: I don't get it...
tadzik masak: let me find a link for you 14:25
that reminds me of the reason why X is the unknown in maths
erm
masak mathw: $str.subst($substr, '')
tadzik masak: www.ted.com/talks/lang/pl/terry_mo...known.html
[Coke] rakudo: my $a="schoolbus"; $a ~~ s/hool//; say $a;
p6eval rakudo 3ac8c7: OUTPUT«scbus␤»
tadzik 6 minute long video 14:26
masak tadzik: thanks. will watch after my $work shift :)
[Coke]: yes, but that destroys the old string...
r: my $a = 'schoolbus'; say $a.subst('hool', '')
p6eval rakudo 3ac8c7: OUTPUT«scbus␤»
[Coke] masak: so?
masak ...and my way is shorter :P
tadzik LEAVE NO SCHOOLBUS BEHIND
masak [Coke]: so? well, it's just that I tend towards mutating old variables when I can. 14:27
er, there should be an avoiding* in there.
thou: fixed. thou++
14:27 adu joined
[Coke] hey, should the default replacement string be "" ? 14:28
masak you mean make the second arument optional? 14:30
I don't believe that use case is common enough to merit that.
and .subst(/regex/) somehow doesn't read so well.
14:30 adu left
flussence r: say 'abc'.subst(/b/ => 'd') 14:31
p6eval rakudo 3ac8c7: OUTPUT«Cannot call 'subst'; none of these signatures match:␤:(Str , $matcher, $replacement, :ii(:samecase($samecase)), :ss(:samespace($samespace)), :SET_CALLER_DOLLAR_SLASH(:$SET_CALLER_DOLLAR_SLASH), *%options)␤:(Cool , $matcher, $replacement, *%adverbs)␤␤ in method sub…
flussence that looks like it should work :(
r: say 'abc'.subst(/b/, 'd')
p6eval rakudo 3ac8c7: OUTPUT«adc␤»
flussence r: say 'abc'.subst('b' => 'd')
p6eval rakudo 3ac8c7: OUTPUT«Cannot call 'subst'; none of these signatures match:␤:(Str , $matcher, $replacement, :ii(:samecase($samecase)), :ss(:samespace($samespace)), :SET_CALLER_DOLLAR_SLASH(:$SET_CALLER_DOLLAR_SLASH), *%options)␤:(Cool , $matcher, $replacement, *%adverbs)␤␤ in method sub…
masak flussence: you could easily define a multi sub or method to make it work in your code.
flussence yeah, I know... it just feels odd that .trans works that way but subst doesn't :) 14:32
r: say 'abc'.trans('b' => 'd')
p6eval rakudo 3ac8c7: OUTPUT«adc␤»
14:33 kaleem left
PerlJam flussence: I think it would be odd for it to work. 14:34
There's already enough conflation between tr/// and s/// and letting Pairs work for .subst would just add a little more IMHO 14:35
masak it would be a rather breaking change.
PerlJam (It's a "different things should look different" issue in my head) 14:37
14:56 birdwindupbird left 14:57 Guest13509 left 15:00 fhelmberger left 15:03 hoelzro is now known as hoelzro|away, nodmonkey left 15:11 JimmyZ left, tokuhiro_ joined 15:15 tokuhiro_ left 15:16 tokuhiro_ joined
pmichaud good morning, #perl6 15:18
masak pmichaud! \o/ 15:20
TimToady o/
TimToady is home again, is improving on the metapneumovirus, but now has pinkeye... 15:21
moritz TimToady: welcome back, and get better soon 15:22
moritz has hand-foot-mouth desease
jnthn hi pmichaud, TimToady 15:23
timotimo i thought that was for cows and pigs?
moritz timotimo: there's a human version, mostly affecting children
jnthn TimToady, moritz: Ugh...sounds un-fun...get well soon. 15:24
moritz timotimo: and that's spreading in all daycare facilities $here
timotimo reads up on it
moritz jnthn: thanks
TimToady or people newly in contact with children
moritz correct
masak TimToady! \o/
tadzik: heh, nice TED talk. :)
moritz well, I had half a day with shivers and fever, but that's long over. Now ands and feet are itching, but that's managable 15:25
*hands
masak sometimes suffers from foot-in-mouth disease, but the symptoms are quite different...
TimToady masak: about the only backlogging I've kept up on is your blog :)
masak TimToady: wow, cool. 15:26
pmichaud wb, TimToady. Hope you feel better soon!
moritz pmichaud: what's your ETA for a star release? 15:32
pmichaud moritz: Wednesday? 15:33
does it need to be sooner than that?
moritz pmichaud: no, just asking
pmichaud okay, Wednesday. :)
jnthn
.oO( And Maybe Some Installer ;-) )
15:34
pmichaud oh, yes, I was including the installer in that estimate :) 15:35
15:35 quietfanatic left
jnthn :D 15:35
15:35 hoelzro|away is now known as hoelzro
moritz installer... as in, windows? 15:36
jnthn Yes.
(Thus the MSI pun ;-)) 15:37
pmichaud I'm planning to have a .msi of the July release, and also to (perhaps) start an automated build system for it.
TimToady masak: my main question is why you don't use colon method form for all the "physical" calls like .connect(<hall cave>, 'down');
I tend to think .connect: <hall cave>, 'down'; looks a bit cleaner
especially if the final arg is a closure 15:38
then you can leave off the ); 15:39
pmichaud \o/ yapc::na 2013 will be in Austin, TX \o/ 15:40
PerlJam pm: yep, I'm already making my attendance plans :)
timotimo ); is such a sad smiley 15:42
maybe it should be ;) instead
can i modify the perl6 grammar to make that happen?
TimToady "All things are possible, but not all things are expedient." --the Apostle Paul 15:43
pmichaud ...what's the story with act.yapc.eu/ye2012/talks/tag/perl6, ooc? Did we all write insanely horrible talk proposals?
15:44 snearch left
timotimo "CJK UNIFIED IDEOGRAPH-8776", what does that even mean? :| 15:45
moritz pmichaud: I have no idea.
TimToady butterfly
15:45 tokuhiro_ left
moritz blogs.perl.org/users/moritz/2012/07...-2012.html 15:46
15:46 tokuhiro_ joined
timotimo oooh, that's cute and relevant to perl6 15:46
moritz corion has commented at the bottom
15:46 fgomez joined, fgomez left
moritz so it seems that the current list of talks was indeed supposed to be final-ish, and they are now re-investigating 15:47
15:47 fgomez joined
jnthn The difference in accepted talk count this year (56) is rather different from last year (143). 15:49
pmichaud actually, it's just 51.
at least by my count
jnthn had been assuming it was just delays in getting stuff accepted/rejected since the talk count still seemed low
moritz well, me too, until I read that blog post 15:50
jnthn Yeah. Oddness.
15:51 tokuhiro_ left
pmichaud yeah, yapcna had 90 talks this year. 15:51
TimToady maybe we can have a Perl 6 track in the linen cupboard
pmichaud I was thinking we might start our own p6 track :-) 15:52
moritz it would be nice if we didn't have to go guerilla :-)
jnthn pmichaud: Hmm. Austin means "really hot in summer", I guess? :) 15:53
pmichaud jnthn: it depends. and it's normally a fairly dry heat 15:54
so "hot" but not "horrible", at least in my experience.
jnthn Ah, that's not so bad then :)
pmichaud and june-ish is often not too bad; things normally start to get worse in the july/august-ish timeframe 15:55
indeed, right now the temperature in Austin is 87degF (30degC) 15:57
(that's just weird, imo; I would've never guessed a temp in the mid-80s.) 15:58
jnthn Nor would I, but that's 'cus I think in degC :) 15:59
pmichaud "low 30s" then :) 16:00
yapc::eu seems to have a total of 52 talks listed (24 @ 20mins, 28 @ 40mins), and three of the 40 minute talks are Lightning Talk sessions. 16:01
oddness. Oh well, we'll see if they work something out.
[Coke] looks like there's one perl6 talk accepted. 16:03
pmichaud lightning talk, Coke?
[Coke] act.yapc.eu/ye2012/talks/tag/perl6 (aye
moritz but it's not really about Perl 6 :-) 16:04
16:05 bbkr left 16:09 cognominal joined 16:12 cognominal_ left, wtw left
dalek kudo/toqast: 1599e25 | jnthn++ | src/Perl6/Actions.pm:
Fix indirect hyper dispatch.
16:16
kudo/toqast: 79e502e | jnthn++ | src/core/Buf.pm:
Make subbuf set up the resulting Buf properly.
16:17 zby_home_ joined 16:18 hoelzro is now known as hoelzro|away 16:19 vmspb joined 16:21 nodmonkey joined
masak TimToady: Larry gets the colon. I will change it thus and I have a feeling I will like it more. thanks for the suggestion. 16:27
huf well, at least someone gets it... clearly not long since the colon was a teenager. 16:29
16:29 Pleiades` left 16:30 mjflick left
masak moritz: clearly we need to find an autopun written in Perl 6 :) 16:30
16:30 mjflick joined
tadzik r: my @a = "hip" xx 2; say ~(@a, @a.WHAT.perl), "!" 16:31
p6eval rakudo 3ac8c7: OUTPUT«hip hip Array!␤»
masak :D
r: my @a = "hip" xx 2; say ~(@a, @a.^name), "!"
p6eval rakudo 3ac8c7: OUTPUT«hip hip Array!␤»
tadzik golf'd!
masak r: my @a = "hip" xx 2, "@a.^name()!"; say @a 16:32
tadzik r: my @a = "hip" xx 2; say (@a, @a.^name), "!"
p6eval rakudo 3ac8c7: OUTPUT«hip hip Array!␤»
masak wins
tadzik hm
masak well, that one clearly puts the mention *in* the use... :)
tadzik hehehe
masak r: say my @a = "hip" xx 2, "@a.^name()!" 16:33
p6eval rakudo 3ac8c7: OUTPUT«hip hip Array!␤»
huf there are no depths down to which you'll not sink, eh? :))))
masak that's us.
depthwise limitless. 16:34
16:34 Pleiades` joined
tadzik r: say my@a="hip"xx 2,"@a.^name()!" 16:35
p6eval rakudo 3ac8c7: OUTPUT«hip hip Array!␤»
jnthn r: say .keys, .^name, .values given { "don't make a " => " of it" }
p6eval rakudo 3ac8c7: OUTPUT«don't make a Hash of it␤»
masak ¬∃depth:¬we_will_sink(depth) 16:36
jnthn: :P
huf :)
[Coke] r: say my@a="hip"xx 2,@a.^name~"!" 16:37
p6eval rakudo 3ac8c7: OUTPUT«hip hip Array!␤»
[Coke] (which saves a space even if you ignore whitespace diffs)
pmichaud r: my $o = 'an option'; say (+$o).WHAT, " is not $o";
p6eval rakudo 3ac8c7: OUTPUT«Failure() is not an option␤»
masak r: sub marine($color) { say "we all live in a $color &marine.^name() &marine.name()" }; marine "yellow"
p6eval rakudo 3ac8c7: OUTPUT«we all live in a yellow Sub marine␤»
masak well, 16:38
r: sub marine($color) { say "we all live in a $color &marine.^name()&marine.name()" }; marine "yellow"
p6eval rakudo 3ac8c7: OUTPUT«we all live in a yellow Submarine␤»
TimToady
.oO(it's hard to write an auto pun in a language without an auto declarator...)
masak r: sub auto($thing) { say "I declare unto thee, $thing: you're a car!" }; auto "dog" 16:39
p6eval rakudo 3ac8c7: OUTPUT«I declare unto thee, dog: you're a car!␤»
masak probably the silliest thing I've done all day.
TimToady I've had a car that was a dog, but never had a dog that was a car. 16:41
jnthn .^name ~ .decode('utf-8') given Buf.new(102,121,32,116,104,101,32,118,97,109,112,105,114,101,32,115,108,97,121,101,114) # sorry :)
r: .^name ~ .decode('utf-8') given Buf.new(102,121,32,116,104,101,32,118,97,109,112,105,114,101,32,115,108,97,121,101,114) # sorry :)
p6eval rakudo 3ac8c7: ( no output )
jnthn r: say .^name ~ .decode('utf-8') given Buf.new(102,121,32,116,104,101,32,118,97,109,112,105,114,101,32,115,108,97,121,101,114) # sorry :)
p6eval rakudo 3ac8c7: OUTPUT«Buffy the vampire slayer␤»
jnthn \o/
[Coke] jnthn: you're like some kind of coding Angel. 16:42
masak TimToady: did you ever put a dog in your car that was a dog? :) and then go, "yo... dog" :P 16:43
TimToady perl6: 'golfed'.say
p6eval rakudo 3ac8c7, niecza v19-13-g442e075: OUTPUT«golfed␤»
masak dang, there's no unicode codepoint for something golf-related...
[Coke] .u club 16:44
phenny U+2663 BLACK CLUB SUIT (♣)
timotimo .u seal
[Coke] .u iron
phenny U+2E8B CJK RADICAL SEAL (⺋)
[Coke]: Sorry, no results for 'iron'.
diakopter .u 26F3 16:45
phenny U+26F3 (No name found)
TimToady .u 26F3
phenny U+26F3 (No name found)
timotimo i'm a mean person: ♣⺋
TimToady .u ⛳
phenny U+26F3 (No name found)
diakopter .u FLAG IN HOLE
phenny diakopter: Sorry, no results for 'FLAG IN HOLE'.
masak timotimo: :P
diakopter well, unicode 6.1 has flag in hole 16:46
TimToady according to www.fileformat.info/info/unicode/ch...index.htm, 5.2 16:47
pmichaud www.fileformat.info/info/unicode/ch.../index.htm 16:48
oh, TimToady++ beat me to it
masak declares a vim macro to convert the .method() form to .method: form, and gets a bit freaked out seeing it edit his file quickly and correctly
daxim ‭ �� U+1F6A9 TRIANGULAR FLAG ON POST 16:49
TimToady .u SNOWMAN WITHOUT SNOW
phenny TimToady: Sorry, no results for 'SNOWMAN WITHOUT SNOW'.
benabik .u SAD GIRL IN SNOW
phenny benabik: Sorry, no results for 'SAD GIRL IN SNOW'.
16:50 kaleem joined
diakopter I think it's in 6.1 also. I wasn't saying it first appeared in 6.1. that just happened to be the database I searched. 16:53
(for "golf") 16:54
GlitchMr .u CAMEL 16:57
phenny GlitchMr: Sorry, no results for 'CAMEL'.
masak .u GIMEL
phenny U+2137 GIMEL SYMBOL (ℷ)
masak .u MELON
phenny U+2F60 KANGXI RADICAL MELON (⽠)
TimToady .u ⚻ 16:58
phenny U+26BB QUINCUNX (⚻)
GlitchMr ,u EVERYTHING
.u EVERYTHING
masak you can't have everything.
phenny GlitchMr: Sorry, no results for 'EVERYTHING'.
masak (where would you put it?)
GlitchMr In <title>?
As infix operator? 16:59
masak you're not entitled to do that.
daxim
benabik .u ALL
flussence put it in itself!
phenny U+2200 FOR ALL (∀)
benabik That's kinda like everything.
masak .u EXISTS
phenny U+2203 THERE EXISTS (∃)
masak and that's kinda like (at least) one thing.
GlitchMr perl6: say **
p6eval niecza v19-13-g442e075: OUTPUT«Unhandled exception: Unable to resolve method postcircumfix:<( )> in type Any␤ at /tmp/FhFIvb3fP6 line 1 (mainline @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 3918 (ANON @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 3919 (module-CORE @ 562… 17:00
..rakudo 3ac8c7: OUTPUT«===SORRY!===␤HyperWhatever (**) not yet implemented. Sorry. ␤at /tmp/VLdV_YUc52:1␤»
dalek kudo/toqast: ddc68b3 | jnthn++ | src/Perl6/Actions.pm:
Fix final three S05 test failures.
17:01
[Coke] jnthn: ooh, how close are you to mergeback now? 17:02
jnthn tadzik: ^ may (or may not) fix URI.
[Coke]: Think it can land by next weekend.
masak \o/
jnthn [Coke]: Still some spectest failures to clean up; module space also had a couple of issues.
17:03 vmspb left
[Coke] rereads 6guts.wordpress.com/2012/07/20/the-...ng-nicely/ so he doesn't have to ask jnthn what the hell he's working on again. ;) 17:04
TimToady 有無問. <- Hamlet, golfed. 17:05
masak *lol*
masak could read that right off and feels proud 17:06
daxim :S
[Coke] pasted it into google translate, got a nice answer. clicked on "translate from japanese" and got a geekier one.
masak phenny: "有無問"? 17:07
phenny masak: "Whether to ask" (zh-CN to en, translate.google.com)
masak phenny: jp en "有無問"?
phenny masak: "Whether to ask" (zh-CN to en, translate.google.com)
masak phenny: ja en "有無問"? 17:08
phenny masak: "Question whether or not" (ja to en, translate.google.com)
masak \o/
jnthn r: my $x = 0; repeat until $x >= 10 { $x++ }; say $x
p6eval rakudo 3ac8c7: OUTPUT«10␤»
jnthn r: my $x = 0; repeat until $x >= 10 -> $foo { say $foo; $x++ }; say $x
p6eval rakudo 3ac8c7: OUTPUT«Mu()␤False␤False␤False␤False␤False␤False␤False␤False␤False␤10␤»
[Coke] masak: gt said "existence question" for ja-en.
masak weird. 17:09
we must've gotten different Googleputer servers.
masak .oO( Google's ultimate overlordhood is already here, it's just unevenly distributed... )
17:10 smash joined
jnthn r: my $x = 0; repeat { $x++ } while $x < 10; say $x 17:10
p6eval rakudo 3ac8c7: OUTPUT«10␤»
jnthn t: my $x = 0; repeat { $x++ } while $x < 10; say $x
p6eval toqast : OUTPUT«11␤»
jnthn Well. Oops. :)
smash hello everyone
[Coke] jnthn: >< close enough. 17:11
masak good news: toqast is coming along. bad news: it can't count worth a damn. :P
timotimo jnthn: amazing. how do you get that to be wrong? :D
jnthn So, who implemented repeat_while and repeat_until compilation... :P
masak >.>
jnthn :D
masak I... I didn't think it would go into *production*...!
you mean it wasn't all just an exercise!? 17:12
diakopter does phenny search NamesList.txt also
[Coke] niecza is failing one test. rakudo is failing 3.
daxim www.millionbook.net/wg/s/shashibiya/hmlt/003.htm # grep for 生存
jnthn masak: Curiously, the tests for it in t/qast/qast.t pass... :)
masak huh. 17:13
that's what I've been saying all along, I'm innocent! :P
it's reality that's wrong.
pmichaud I frequently find that reality is wrong. 17:14
jnthn It may be that the tests are wrong ;)
Oh, it's also possible to write a test that doesn't expose the bug. 17:15
17:15 Chillance joined
jnthn Is repeat_until not just until with a goto past the condition check on the first loop entry? 17:15
masak no, I don't think so.
the first iteration always runs. 17:16
jnthn Right, which is why you do a goto past the check for the first time.
goto start_it_anyway
loop_label:
if blah goto loop_is_over_with_now_bai 17:17
start_it_anyway:
pmichaud ...is that how PAST implemented it?
jnthn pmichaud: Hm, good question
pmichaud I would simply think it's
loop_label:
do whatever
unless $cond goto loop_label
with no initial "goto"
sorear good * #perl6
17:18 dakkar left
jnthn I know PAST factors all types of loops into one code generation path, which is what I'm gonna do here. 17:18
pmichaud and yes, PAST does the goto.
(just looked)
unless bodyfirst goto bodyfirst_done 17:19
ops.'push_pirop'('goto', redolabel)
bodyfirst_done:
jnthn pmichaud: No, it does the goto approach
I'm gonna do that for now.
17:22 pyrimidine left
arnsholt jnthn: Regarding the write-barrier problem I mentioned earlier, I think I see two possible solutions: 17:23
1) Always invalidate a string member in a struct or array when it's been passed into C. Runtime cost.
2) Cache STRING objects as well as PMC objects in the REPRs. Memory cost. 17:24
Any thoughts on which is better?
jnthn Caching stuff in...the REPR?
As in the object itself?
arnsholt Yeah, not the REPR as such, but the object body 17:25
jnthn ah, OK
arnsholt Bad choice of words =)
jnthn I think 1 sounds simpler?
tadzik jnthn: will recheck
arnsholt Yeah, 1 is dead simple
jnthn arnsholt: I'm fine with doing the simple, working thing for the time being. 17:26
pmichaud +1 to simple
arnsholt Cool. I'll do that then
In fact, it's so simple that it's what I sketched as a placeholder while thinking
17:31 mucker left, daxim left
dalek p/toqast: 66dae41 | jnthn++ | src/QAST/Operations.nqp:
Unify repeat_ style loop code-gen with while/until code-gen, unbusting it and giving it control exceptiony goodness along the way.
17:34
17:37 mucker joined 17:39 Tene joined, Tene left, Tene joined 17:43 Ex joined 17:48 Chillance left, thelazydeveloper joined, Chillance joined 17:54 cognominal left 17:55 cognominal joined 17:59 cognominal left 18:00 cognominal joined 18:01 bluescreen10 left
dalek p/toqast: 3c9b25f | jnthn++ | src/QAST/Operations.nqp:
Oops, diddle the correct register for the repeat with -> case.
18:05
18:07 kaleem left 18:09 bluescreen10 joined
dalek p: ba3362e | (Arne Skjærholt)++ | src/6model/reprs/CArray.c:
Remove warnings from CArray.c
18:16
nqp: 05b3d54 | (Arne Skjærholt)++ | src/6model/reprs/CStr.c:
nqp: Remove warnings from CStr.c
18:16 dalek left
arnsholt Ooops. ETOOMANYCOMMITS 18:16
18:16 dalek joined, ChanServ sets mode: +v dalek
moritz many commits are good :-) 18:16
benabik arnsholt++
jnthn arnsholt++ 18:17
arnsholt I've discovered that making lots of commits without testing and fixing any bugs with rebasing is a productive workflow for NQP hacking
dalek kudo/toqast: c0731e2 | jnthn++ | src/Perl6/Grammar.pm:
We're not in a block at the start of the program, so need a %*HANDLERS declared in compunit as well as blockoid. Fixes the one failing test in exceptions/misc.t.
arnsholt Saves a fair number of NQP/Rakudo/Zavolaj compile-test cycles 18:18
TimToady hmm, a bubble context is precisely how I evolved p4 into p5 18:19
moritz but you didn't have a cool name for it back then :-) 18:20
benabik arnsholt: That's a pretty effective git workflow in general. :-D
moritz I do that with setting hacking a lot, because compiling it takes so long
arnsholt Yeah, that makes sense 18:21
masak TimToady: could you say a bit more about that? that sounds fascinating.
arnsholt For my NQP hacking, I do check that the changes compile before committing, but that's because I know how to recompile just what I want and not all of NQP every time =) 18:22
TimToady there were intermediate forms (only seen at NetLabs, Inc) where both the p4 and p5 runloops thought they were running the show
masak ah, so asset capture.
TimToady with a translation scaffolding that let each runloop lie to the other one
benabik rebase -i is useful for that. If you name a commit "fixup! <old commit>" and use --autosquash (or rebase.autosquash), it'll automatically reorder the commits and apply the bug fixes.
masak www.martinfowler.com/bliki/Strangle...ation.html 18:23
tadzik jnthn: nope, URI still fails
but something is better, 51 modules ok, 55 not ok (106 total)
it was 49 yesterday, I think 18:24
TimToady yes, p5 successful strangled p4 :)
masak :)
moritz benabik oh, I didn't know about autosquash
arnsholt benabik: Yeah, I use --interactive for my rebasing. But fixup! sounds nifty as well. Useful for braino-type fixes 18:25
benabik arnsholt: I tend to use it for most bug fixes. Makes my commits look perfect the first time around. :-D
moritz: Following the git ML for years has taught me a few things.
jnthn tadzik: If you have time, please see if you can get it down to a small test case. 18:26
arnsholt Yeah, that's perhaps the awesomest part. I never make mistakes (that are seen by the outside world) =D
moritz wants gitmonks to go along with perlmonks
18:27 cognominal left
flussence and chipmonks, lest the hardware-hacking crowd feels left out 18:28
benabik flussence++
18:28 cognominal joined
masak heh :) 18:28
moritz t: say and die 42 18:29
p6eval toqast : OUTPUT«42␤␤»
benabik huh. That seems backwards.
moritz t: say and die 42; say "alive"; 18:30
p6eval toqast : OUTPUT«42␤␤»
moritz r: say and die 42; say "alive";
p6eval rakudo 3ac8c7: OUTPUT«===SORRY!===␤CHECK FAILED:␤Undefined routine '&and' called (line 1)␤»
benabik facepalm
moritz that's what the test wants
so, it's actually a parsing bug
t/spec/S03-operators/precedence.t 18:31
jnthn It's not
moritz the last one
jnthn It's that t doesn't complain about the "and" routine being undeclared yet
moritz oh
jnthn I haven't put back CHECK time missing routine detection.
flussence r: $*OUT.say: 1; $*ERR.say: 2;
p6eval rakudo 3ac8c7: OUTPUT«1␤2␤»
tadzik jnthn: I'll try
jnthn It compiles to an and(...) call, but die is the argument to it.
So it does first.
dinner, bbs :) 18:32
moritz ok
jnthn (gonna try and put the optimizer back together this evening, I think)
tadzik jnthn: fun fact: it fails ONE test :)
should be easy to find
moritz better than the old "URI just dies with a weird error message on loading" :-) 18:33
jnthn Tests where I've no clue at all what's going on that I'd love somebody else to look into: S02-types/version.t, S32-str/sprintf.t, S12-methods/method-vs-sub.t
tadzik not ok 47 - validating parser rejected bad URI 18:34
moritz jnthn: S02-types/version.t passes here
jnthn oddness 18:35
really dinner &
tadzik haha
Contextual %*HANDLERS not found
I guess I just need to git pull now 18:36
moritz jnthn: sprintf tests look like they should be fudged on rakudo... 18:37
$ perl t/harness --fudge t/spec/S32-str/sprintf.t 18:38
t/spec/S32-str/sprintf.rakudo .. ok
18:38 felher left, felher joined
moritz jnthn: maybe your t/spec/ is stuck or so? 18:39
tree.t misses two setting patches from nom 18:41
[Coke] when p6eval is run,is it under "nice" ? 18:48
(on feather-main)
ugh. maxed out at 95% CPU, 82% memory. ;) 18:51
(building rakudo, looks like)
18:55 supernovus joined
TimToady "One of the beautiful things about science is that it allows us to bumble along, getting it wrong time after time, and feel perfectly fine as long as we learn something each time." 18:56
we forgot to yell "Stand back!" twelve years ago...
PerlJam 20 years from now it won't make much difference probably. 18:58
supernovus Using zavolaj/NativeCall, is there a way to import C library constants into the Perl 6 namespace?
PerlJam (unless there's still widespread perception that Perl 6 "isn't here" or "isn't real" or whatever)
TimToady supernovus: anything is possible with BEGIN, assuming your compiler doesn't actively prevent it 18:59
PerlJam supernovus: something that parses C header files and outputs some appropriate Perl 6 code would be a Nice-To-Have 19:00
TimToady I dunno whether rakudo supports importing constants yet
19:01 GlitchMr left
TimToady you'd think it wouldn't be hard, since it already has to import types, which parse the same 19:01
perl6: module MyPi { constant mypi is export = 3 }; import MyPi; say mypi 19:02
p6eval niecza v19-13-g442e075: OUTPUT«===SORRY!===␤␤Action method statement_control:import not yet implemented at /tmp/pVDgdZJSWv line 1:␤------> nstant mypi is export = 3 }; import MyPi⏏; say mypi␤␤Unhandled exception: Unable to resolve method statement_le…
..rakudo 3ac8c7: OUTPUT«===SORRY!===␤CHECK FAILED:␤Undefined routine '&mypi' called (line 1)␤»
TimToady apparently not
masak submits rakudobug 19:04
masak submits nieczaissue
[Coke] npr: say "aa" ~~ /'a'/ 19:05
p6eval rakudo 3ac8c7: OUTPUT«q[a]␤␤»
..pugs: OUTPUT«Error eval perl5: "if (!$INC{'Pugs/Runtime/Match/HsBridge.pm'}) {␤ unshift @INC, '/home/p6eval/.cabal/share/Pugs-6.2.13.20120203/blib6/pugs/perl5/lib';␤ eval q[require 'Pugs/Runtime/Match/HsBridge.pm'] or die $@;␤}␤'Pugs::Runtime::Match::HsBridge'␤"␤*** Can't locate P…
..niecza v19-13-g442e075: OUTPUT«#<match from(0) to(1) text(a) pos([].list) named({}.hash)>␤»
[Coke] hurm. that is unfortunate for pugs.
moritz t: class A { our method b() { return self } }; say &A::b(A.new) 19:10
p6eval toqast : OUTPUT«A.new()␤»
19:12 mtk left
jnthn moritz: My spectests are up to date, so it can't be that. 19:12
moritz: Wonder if it's Windows specific. Also, I should check it it builds on master. 19:13
s/builds/passes/
s/master/nom/
moritz :-)
masak .oO( reading #perl6 is like coming home from IKEA. you have to put together the sentences from small pieces ) 19:14
moritz we could write a bot for it 19:16
masak IKEAbot
jnthn At least the sentences aren't missing a screw :P
moritz how does 'is export' is supposed to work? 19:17
jnthn moritz: The issue is that constant declarations don't apply traits yet.
moritz is there some kind of container on which it acts?
jnthn: but what would they apply to/on?
jnthn moritz: Well, export is easy since it just need to install the value somewhere. 19:19
TimToady a constant is just a very small type :)
jnthn moritz: It'd just get passed the value itself as the trait subject.
Or I think that was the answer last time I asked... :) 19:20
TimToady perl6: subset mypi of Int where 3; say 3 ~~ mypi; # :) 19:22
p6eval rakudo 3ac8c7, niecza v19-13-g442e075: OUTPUT«True␤»
TimToady r: module MyPi { subset mypi of Int is export where 3; }; import MyPi; say 3 ~~ mypi; 19:23
p6eval rakudo 3ac8c7: OUTPUT«True␤»
TimToady not so very different from that 19:24
19:26 ironcamel joined
moritz it's not clear to me how trait handler is supposed to learn about the name under which to export 19:26
masak chromatic++ # www.modernperlbooks.com/mt/2012/07/...ution.html
moritz will that be passed as an extra paramter to the trait?
jnthn moritz: Oh. Hmm. 19:27
masak wants a t-shirt with "Embrace the tautology" on it
jnthn moritz: Yes, that's a problem.
TimToady how does a subset know its name? 19:32
supernovus Where does zavolaj look for libraries (i.e. is there a way to change it's "search path")
moritz TimToady: from the type object 19:33
19:33 mtk joined
jnthn TimToady: 'cus it's a type, so you can do .^name on it. 19:33
moritz masak: when is your birthday? :-)
TimToady to the compiler, constants are types that are eventually optimizable to values, I think 19:34
19:34 birdwindupbird joined
TimToady immediately turning the name into a value is a premature optimization 19:34
masak moritz: what, you want to print me a t-shirt ;) 19:35
flussence supernovus: it's the system lib search path. `man ld.so` might be a good place to start
masak moritz: ...? ;)
supernovus flussence: thanks, I'll install the wrapper libs into /usr/local which should allow zavolaj to find them.
19:35 vmspb joined
jnthn TimToady: Guess it's doable...first time I've ever heard this suggestion though. ;-) 19:36
TimToady: How do they work out type wise?
TimToady: What does their .WHAT evaluate to?
19:50 cognominal left 19:52 zby_home_ left, cognominal joined
masak maybe 'import' should also be under "Module management" in perl6.org/compilers/features , what do you think? 19:57
jnthn Maybe 19:59
Seems use, need and require are 20:00
Does Rakudo still have yellow for use?
moritz rakudo does 'use' roughly as well as specced 20:01
except for the breakdown in primitives that S11 or so mandates 20:02
20:04 snearch joined
TimToady jnthn: presumably defers to the 'of' type, same as the value itself would return 20:10
dalek atures: 5aca171 | moritz++ | features.json:
rakudo implements "use"
20:13
moritz but then constant a is export = 3; would export Int, not a
TimToady how do you avoid exporting Sub when you export a sub? 20:15
jnthn There's a multi candidate for Routine.
You can call .name on it
.WHAT is *very* low level. That's not changing. It always refer to a type object. 20:16
I guess we can set up a type that lies about its type object.
I'm not sure it's a good idea though. :)
masak r: multi h($s, $, $t, 1) { "$s$t" }; multi h($s, $h, $t, $n) { h $s, $t, $h, $n-1; "$s$t"; h $h, $s, $t, $n-1 }; say h "a", "b", "c", 5
p6eval rakudo 3ac8c7: OUTPUT«ac␤»
masak hm.
r: multi h($s, $, $t, 1) { "$s$t" }; multi h($s, $h, $t, $n) { (h $s, $t, $h, $n-1), "$s$t", h $h, $s, $t, $n-1 }; say h "a", "b", "c", 5 20:17
p6eval rakudo 3ac8c7: OUTPUT«ac ab cb ac ba bc ac ab cb ca ba cb ac ab cb ac ba bc ac ba cb ca ba bc ac ab cb ac ba bc ac␤»
masak simple Hanoi solver :)
jnthn whoa
That's...short. 20:18
masak yeah.
20:18 cognominal_ joined
masak well, it's just base case and inductive case, really. so there's not much complexity to implement. 20:18
I built it to generate a quick walk-through paste for myself to paste into the adventure game :) 20:19
so dreary to solve the Hanoi game by hand... :)
20:21 cognominal left
masak I'm in the slightly amusing position that I "have to" make the Hanoi game work to the point of opening the connection to the next room in order to do today's blogging task :P 20:21
20:22 cognominal__ joined 20:25 cognominal_ left
dalek kudo/toqast: 81a7ade | jnthn++ | src/Perl6/ (2 files):
Start to bring back the optimizer. This re-enables the analysis (and thus catching of undeclared routines), but disables all the optimizations but private method call; they will be brought back and tested one by one.
20:26
20:28 kaare_ left
dalek Heuristic branch merge: pushed 20 commits to nqp/dyncall-callbacks by arnsholt 20:30
volaj/callbacks: 46d9cce | (Arne Skjærholt)++ | / (3 files):
Functionality and tests for callbacks.
20:33
TimToady wonders how far from running both runloops stackless... 20:36
*we are
.oO(.oO(bubble contexts))
jnthn ;-) 20:37
20:37 spaceships joined
moritz wonders if silicon valley is in bubble context 20:41
and if they simply can call wantbubble() to find out :-)
masak wow, what does .oO(.oO(...)) even *mean*? :)
there's an xkcd strip like this, by the way. 20:42
xkcd.com/248/
sirrobert heh 20:43
masak xkcd++ # making the world awesome to think in 20:44
dalek kudo/toqast: d1aef7e | jnthn++ | src/Perl6/Op (2 files):
Restore proto inlining optimization.
20:45
20:51 birdwindupbird left
arnsholt How do I get a floating point literal to be forced to a num? 20:52
TimToady e0 20:54
arnsholt Of course! Thanks
20:58 cognominal joined 21:01 cognominal__ left 21:03 mjflick left, mjflick joined
dalek d: d5bea92 | larry++ | STD.pm6:
a bit of undef proofing
21:05
21:22 SamuraiJack left, sergot left
dalek kudo/toqast: 678541a | jnthn++ | src/Perl6/Op (2 files):
Update compile time resolution of multis; this busts the setting if turned on, sadly...needs some more analysis.
21:27
kudo/toqast: 740312f | jnthn++ | src/Perl6/Optimizer.pm:
Start fixing up immediate block inlining.
kudo/toqast: bc246a5 | jnthn++ | src/ (2 files):
pir => nqp and void fix.
kudo/toqast: fae30cb | jnthn++ | src/Perl6/Optimizer.pm:
Re-enable inlining of immediate blocks optimization.
tadzik 'evening
jnthn hi tadzik
OK, that's enough optimizer hacking today. To do is figuring out the issue with compile time multi dispatch resolution, and then I need to re-do the routine inlining stuff. 21:28
Happily, it gets nicer and rather less restricted once I can do that :) 21:29
tadzik rebuilds and resmokes
21:29 Chillance left
jnthn tadzik: Mostly a few small gains here and there. 21:29
tadzik which may get interrupted by a sudden sleep
jnthn :)
tadzik oh, probably before I even build :) 21:31
but I see you're onto optimizations already :) 21:32
21:33 Chillance joined
jnthn tadzik: Well, getting the optimizer updated for QAST really. 21:34
Once I get everything working again, then it'll be time for optimizing stuff some more :)
21:34 skids left
tadzik I can't wait :] 21:35
masak lue: I just realized that 2012-07-29 is "verb synonyms". so you have until then to make another pull request, if you're still interested in helping. :) after that I'll get to it myself.
oh, and 2012-07-28 is movement synonyms. 21:36
dalek nda: b475cb2 | tadzik++ | / (38 files):
First shot at offline bootstraping; seems to work
nda: 22a494d | tadzik++ | b (2 files):
Ensure that DESTDIR is respected
nda: 9f3691d | tadzik++ | projects.json.bootstrap:
Oops, forgot the most important part
nda: 0de8b12 | tadzik++ | bin/panda:
Fix installing into the default location
tadzik moritz: I've merged panda/offline-bootstrap, if you notice any negative side-effects please shout at me :) 21:37
masak lol! I blog'd! \o/ strangelyconsistent.org/blog/july-2...y-the-fire 21:43
timotimo haha, how did that happen?
masak I'm as surprised as you are! 21:44
I'll say this. one month of once-a-day-blogging is fine. two months... no. not unless someone paid me. 21:45
:) 21:46
21:47 crab2313 joined, Bucciarati left 21:48 Bucciarati joined 21:49 BooK_ left 21:55 BooK joined, daniel-s__ left, daniel-s__ joined 22:00 vmspb left 22:09 awwaiid_ left, awwaiid joined 22:13 PacoAir left
lue hello world o/ 22:16
masak: now that I see you planned to do it, I'd be more interested in seeing how you would do it (as I've already made my way public) 22:17
masak up to you.
I plan to do it like I did it last year.
except maybe I'll put the movement synonyms into the Adventure::Engine itself -- following Postel's law a bit. 22:18
22:19 bluescreen10 left
jnthn
.oO( Going Postel )
22:19
jnthn looks up Postel's law :)
lue That would be a good spot (if only to serve as a convenient reminder to include that when extracting and splitting Adventure::Engine) 22:20
lue too
jnthn oh, I knew that, just didn't know the name.
masak Postel was some Internet pioneer or other.
I actually don't know what to think of his law.
jnthn It's always bothered me a bit form a security perspective. 22:21
masak HTML parsers in browsers are an excellent example of following it. and that was both a roaring success and a slightly worrying evolution.
supernovus Well, it's far from complete, but here's a quick working example of my latest perl 6 project -- huri.net/files/perl6-curl.txt -- when finished, it will have a nicer Perl 6 API, and we'll have a way of accessing https URLs from within Perl 6 itself. 22:23
masak ooh
bikeshedding suggestion: how about s/perform/transfer/ ? more specific. 22:24
lue masak++ another good blog post 22:26
masak \o/
22:26 Ex left
lue
.oO(I've been trying to find the crypt for a month now, it's about time I find some water!)
22:27
masak :P
supernovus masak: at the moment, I am implementing the curllib API as a 1-to-1 mapping of its C names to Perl 6 names. Then I'll make an easier to use API on top of that.
jnthn supernovus: Are you doing it using NativeCall?
supernovus jnthn: yes 22:28
jnthn supernovus: Nice \o/
masak supernovus: oh, that's a good reason.
jnthn supernovus: Is the code somewhere yet?
supernovus The "callbacks" branch of NativeCall will be very useful, so hopefully it gets merged back into master soon :-)
jnthn: not yet, I just started on it, it's currently very, very limited. 22:29
jnthn OK
Does Curl do HTTPS, ooc?
22:31 cognominal left
lue according to its man page, yes. (as well as the ol' gopher protocol) 22:31
22:32 cognominal joined 22:33 nodmonkey left
supernovus cURL does a whole whackload of protocols. It supports https via a choice of openssl, gnutls and nss. 22:36
22:36 seldon left
masak curl is teh awesome. 22:37
jnthn wow 22:38
sorear wasn't someone here from #sandiego.pm earlier trying to bind curl to perl6?
supernovus when the user friendly API is done, it'll look more like: my $c = WWW::Curl; my $response = $c->verbose->get($some_url);
err with . instead of -> stupid Perl 5 API docs
sorear ah yes, majrmovies 22:39
who logged out half an hour ago
so! we have two people independantly writing cURL bindings. I am thinking this is LTA.
masak supernovus: oh, I was going to propose a fluent interface like that. 22:40
sorear: indeed.
supernovus: I task you with contacting this person and figuring out a way to collaborate.
masak waves his magic community wand to make it so
22:41 MayDaniel left
supernovus I should do that, maybe they have a way of not having to write a custom C library to provide extra functionality. 22:41
22:42 Coleoid joined
diakopter wasn't someone including a C compiler into NativeCall or something? 22:44
22:52 skids joined
masak good night, #perl6 22:56
felher o/ masak 22:57
supernovus Hmm, I may have a way of avoiding the need for a custom library to query the various constants. A quick script and I can port all of the desired constants from the C header files into a generated Perl 6 module. 23:00
good night masak!
23:07 crab2313 left 23:25 thelazydeveloper left
jnthn 'night. #perl6 23:27
23:27 crab2313 joined
felher 'night, jnthn 23:29
23:29 snearch left 23:34 tokuhiro_ joined