»ö« 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.
00:12 wamba left, smash left 00:19 Guest4301 joined
Guest4301 hi 00:19
13 :) 00:20
13hello
TimToady we only talk about Perl 6 here
if you want to talk about Perl 6, then you're welcome to stay
if you want to talk about girls, go somewhere else please
or boys :) 00:21
benabik Colored text? 00:22
Guest4301 02I don t save 00:24
02what you say
02what??
00:25 ChanServ sets mode: +o diakopter
Guest4301 what?? 00:25
00:26 agentzh joined
TimToady can we arrange a general ban on chatmosphere? it's not getting any better, it would seem 00:26
diakopter maybe using the wildcard nick ban
Guest* 00:27
TimToady something to consider
will there every be an real interest in Perl 6 from a chatmosphere personage?
*ever
diakopter thought you said parsonage 00:28
TimToady this one doesn't even seem to be quite coherent
I suppose it could be a linguistic issue... 00:29
00:30 Guest4301 left 00:31 diakopter sets mode: -o diakopter 00:32 ChanServ sets mode: +o diakopter, diakopter sets mode: +q $r:*chatmosphere*
diakopter that will let them join but their messages will be unbroadcast. 00:33
er
oops, no
00:34 diakopter sets mode: -q $r:*chatmosphere*, diakopter sets mode: -q $x:*chatmosphere*
diakopter there we go 00:34
00:34 diakopter sets mode: -o diakopter
diakopter goes to test 00:35
00:36 chat84537 joined
diakopter oh wow 00:36
the java client doesn't proxy 00:37
chat84537 test
00:37 chat84537 left
diakopter I guess that won't block folks who use chatmosphere through the web browser Java client; but it will block Blackberry users I guess. 00:38
00:40 shinobicl_ joined 01:00 shinobicl_ left, shinobicl_ joined
[Coke] what does unbroadcast do? 01:00
we can see them, but not hear them? 01:01
diakopter I think so
non-broadcasted, I guess I should've said
ingy seen TimToady 01:21
aloha TimToady was last seen in #perl6 52 mins 26 seconds ago saying "I suppose it could be a linguistic issue...".
ingy seen rafl
aloha rafl was last seen in #perl6 58 days 16 hours ago leaving the channel.
diakopter ingy: you're speaking at SF PM next week? 01:24
01:24 replore_ joined
diakopter (I saw the meetup announcment mentioned pegex) 01:24
benabik seen rofl 01:26
aloha Sorry, I haven't seen rofl.
01:32 thou joined
ingy diakopter: correct 01:39
diakopter finding parking in the city always troubles me
ingy I'm at SFO now trying to locate rafl
diakopter: train?
diakopter eww 01:40
diakopter looks on a map
01:41 wolfman2000 joined 01:42 cyfi left 01:46 cyfi joined 01:56 whiteknight left 02:08 thou left 02:16 mkramer joined 02:18 mkramer1 left 02:20 uasi joined 02:22 mkramer1 joined 02:23 mkramer left 02:24 shinobicl_ left 02:32 uasi left 02:52 envi_ joined 03:03 donri left 03:06 ashleydev left 03:10 ashleydev joined 03:35 Sarten-X left
sorear good * #perl6 03:39
03:50 uasi joined 04:01 daniel-s joined 04:09 envi_ left 04:12 snoops joined 04:13 drbean left 04:14 satyavvd joined 04:29 am0c left 04:30 Sarten-X joined
masak morning, #perl6 04:37
PerlJam greetings masak
04:40 drbean joined 04:45 drbean left
sorear o/ masak 04:51
04:52 drbean joined
masak interesting point. mentions Perl 6 in passing: blog.fogus.me/2011/10/18/programmin...t-5-years/ 04:52
masak commutes 04:53
04:54 saaki joined 04:57 soh_cah_toa left 05:07 xinming left 05:15 orafu left 05:17 molaf joined, orafu joined
moritz mls_: it seems that nqp commit 15be997bb74148d9d85ca35408abf4733cde2c32 breaks exit() in rakudo 05:24
05:29 drbean left 05:36 drbean joined 05:45 wolfman2000 left, odoacre joined 05:51 dual joined 05:57 kaleem joined 06:03 snoops left 06:06 koban joined
masak s/point/post/ 06:06
06:07 wtw joined
moritz nqp: pir::exit(0) 06:15
p6eval nqp: OUTPUT«␤current instr.: '_block1000' pc 33 ((file unknown):37) (/tmp/ZPUfsdte6f:1)␤»
TiMBuS why the heck does par make like, 15mb files? 06:17
.. this is #p6 timbus.
06:33 dual left 06:39 wk left
dalek ecza/serialize: 893588d | sorear++ | / (3 files):
Try to implement {YOU_ARE_HERE} compilation
06:39
sorear sleep 06:40
06:42 SHODAN joined
moritz TiMBuS: because it contains the complete perl installation 06:47
TiMBuS man thats a lotta modules to explicitly exclude :/ 06:48
dalek kudo/nom: d7608c8 | moritz++ | src/Perl6/Metamodel/MROBasedMethodDispatch.pm:
speed up method cache creation. Patch by mls++
06:49
TiMBuS if it doesnt walk the dependencies why not just make it spit out an installer
06:50 wamba joined 06:59 wk_ joined 07:01 pmurias joined
pmurias diakopter: re targeting sprixel, doc/nam.pod documents some of the more important opcodes 07:06
07:07 mberends left
TimToady the nom build seems to be broken 07:08
gist.github.com/1297657 07:15
moritz TimToady: I forgot to bump PARROT_REVISION 07:18
pmurias diakopter: meant using niecza 07:20
07:23 interested joined 07:25 interested left
dalek kudo/nom: 36ebf15 | moritz++ | tools/build/NQP_REVISION:
bump NQP_REVISION
07:29
TimToady error: pathspec '2011.09-27-g1dccbcc' did not match any file(s) known to git. 07:30
masak <moritz> TimToady: I forgot to bump PARROT_REVISION
moritz: ...and then you bumped NQP_REVISION... 07:31
07:33 pmurias left 07:42 mj41 joined 07:52 wk_ left
diakopter phenny: tell pmurias I was talking about using niecza as a front-end, not targeting niecza. 07:52
phenny diakopter: I'll pass that on when pmurias is around.
moritz ... to an unpushed commit :( 07:56
dalek p: 87a9ffb | moritz++ | src/6model/sixmodelobject.h:
typo
07:57
p: c13964d | moritz++ | tools/build/PARROT_REVISION:
bump PARROT_REVISION
diakopter s/existant/existent/ in nqp too
dalek kudo/nom: 9c3d3d1 | moritz++ | tools/build/NQP_REVISION:
fix NQP_REVISION, moritz--
07:58
moritz next attempt 07:59
hopefully now TimToady++ can build nom again
masak TimToady++ # canary, coalmine 08:00
moritz is the mine gas
08:03 am0c joined
masak you can't build Rome overnight without breaking a few eggs. 08:04
s/overnight/in a day/ 08:05
moritz egg-breaking mine gas :-) 08:09
masak cowers and awaits Ultimate Punishment by metaphorbot
TiMBuS his punishments are like a car hitting you 08:13
08:16 wk_ joined
masak I pictured him as liking metaphors but not mixed ones. metaphorbot drinks his metaphor coffee black, no milk no sugar. 08:19
diakopter shaken not stirred
masak ;) 08:20
tadzik good morning 08:22
masak tadzik! \o/
tadzik masak: seen the non-blockingy fun yet? 08:23
masak no, I haven't!
tadzik gist.github.com/1296356 that reads from multiple connected clients simultaenously, or however you prononce it
erm, pronounce
moritz rubymonk.com/ 08:24
tadzik so A can stop writing, then B starts, then A continues, just works :)
moritz cool
where does .poll come from? rakudo patch? 08:25
tadzik moritz: yep. When I was about to fix Select, I noticed that Parrot Socket has .poll method, I wonder for how long
(which uses select() internally, benabik says) 08:26
TiMBuS oh my god 08:28
async IO. the day has come 08:29
tadzik checks for how long Parrot has .poll
moritz we should offer a nicer API for that (maybe as a module) 08:30
TiMBuS if only perl6 had a global event loop like that RFC what that asked for one.. asked 08:31
i broke english
im sorry :(
masak moritz: nice page. it's always cool to see the state of the art of online evaluators and jQuery-like web apps advancing.
moritz TiMBuS: don't worry, english recovers very quickly :-)
TiMBuS: and it was perfectly understandable to me
even without a global event loop we can offer one that just calls a callback whenever one handle is readable 08:32
TiMBuS can you pass continuations in perl6? it would be quite nice to yield to a global event loop 08:33
tadzik moritz: Still, it would be slightly LTA. The real poll() watches n sockets over t time. Our poll watches only one socket in the given time, so if we wanted to check n sockets, our time either grows in O(n), or we have to reduce the time spent on an individual socket
TiMBuS like a builtin coro
moritz tadzik: yes, I guess IO::Select is the better alternative 08:34
tadzik moritz: yeah, but it's horribly broken :)
moritz what's borken about it?
tadzik on a pir level or deeper. Segfaults randomly, behaves a bit like .WHY when we had GC bugs which affected it, stuff 08:35
the Select.can_read sometimes segfaults when fed with IO::Socket
TiMBuS :I 08:36
tadzik well, its $PIO of course
im2ee wrote a code which reproduces it quite reliably
as in, when trying for half an hour, it worked only once
moritz tadzik: .poll was added in 2009 by Tene++ 08:37
tadzik nice
moritz: I was wondering whether it's really desirable to implement every socket(), poll(), epoll() etc in Parrot. Maybe we could wait for NCI and implement it, or at least prototype it, in Pure Perl 6 08:38
TiMBuS it seems TimToady prefers passing blocks back instead of a continuation :<
Tene Yeah, I was rather dissatisfied with that. I planned to add a Select PMC that you could dd arbitrary FHs to for various sorts of polling, but never did.
moritz gather/take are basically continuations
08:39 dakkar joined
Tene It would be a pretty trivial task for anyone who wants to try hacking on Parrot, though. 08:39
moritz it exists now, afaict
that's what IO::Select warps
Tene Oh, right, someone did that.
tadzik yeah, but it acts a bit funny 08:40
I wanted to try how it works on pir/winxed level, to check if it really isn't Perl 6 problem, but then I found .poll
TiMBuS yeah moritz but i was thinking, along the lines of: sub callback { get_twitter_update(); wait_for_reply($this?); process_tweet() }; where the callback sub yields to other events until twitter.com replies
at which point it can just continue on by calling the continuation 08:41
coro style
moritz so you formulate it as
TiMBuS exteeemely handy for any event based application
moritz gather loop { sub wait_for_reply($?) { take 1 }; callback() } 08:42
or something along these lines
tadzik: do you have the code that reproduces the error? 08:43
tadzik moritz: yes, will paste it in a second
TiMBuS wait would i return that for the event loop to call or something
tadzik gist.github.com/1297750
08:44 mj41 left
tadzik moritz: fire up, telnet to localhost:8080, watch the world explode 08:44
tadzik afks for a sec
moritz needs to recompile rakudo first :( 08:45
mls_ morning! 08:46
moritz morning mls_
nqp: pir::exit(1)
p6eval nqp: OUTPUT«␤current instr.: '_block1000' pc 33 ((file unknown):26473805) (/tmp/7zJGcUua1S:1)␤»
mls_ yes, I saw then while backlogging
moritz great
I guess the fix won't be hard for you, so I didn't dig into it
08:47 c1sung_ left
mls_ I fear the only way to fix that is to copy the "rethrow_skip_nextctx" opcode to nqp ;( 08:47
there's currently no way in nqp to rethrow an exception
moritz but do you need to? Can't you just let control flow fall off the end of the CONTROL handler? 08:48
... in the case of an exit exception, that is
mls_ and then it'll loop
moritz why?
mls_ (wait, no, in nqp reaching the end means that it's handled, right?)
so it simply won't exit. 08:49
moritz still doesn't understand why
nqp: try { die "foo"; while 1 { } }; say("exiting now")
p6eval nqp: OUTPUT«Unable to parse blockoid, couldn't find final '}' at line 1␤current instr.: 'nqp;Regex;Cursor;FAILGOAL' pc 3863 (src/Regex/Cursor.pir:244)␤»
moritz nqp: try { pir::die("foo"); while 1 { } }; say("exiting now")
p6eval nqp: OUTPUT«exiting now␤»
mls_ hmm, yes, I could set an "exit now" var and redo the exit 08:50
moritz in what way is the the situation with pir::exit not similar to this one?
mls_ ok, i'll fix it that way
(ugly as hell)
moritz I still don't understand why you can't just let control flow fall off the end of the CONTROL handler 08:51
mls_ and then what?
moritz and then the program exits.
mls_ why?
moritz because it doesn't do anything after the CONTROL handler 08:52
or does it?
mls_ it returns from "command_eval". who knows what happens next ;)
moritz hm, ok
and the exit value wouldn't be preserved
so yes, needs an "ugly as hell" solution for now, it seems :( 08:53
mls_ but yes, I'll set an "$has_exit" var and redo the pir::exit()
some day I need to fix parrot's exception handling. The problem is that messing with handlers will be bad if an exception is resumed
(IMHO it should pop all handlers until the handler that caught the exception is reached, and magically restore them if the exception is resumed) 08:54
(of course perl6 needs completely different semantics) 08:55
Tene mls_: can't you just pir::rethrow or something? 08:56
moritz tadzik: it seems that I don't understand the TCP::Server::Simple code at all. For example in line 19 it calls $!sock.poll, but IO::Select doesn't have a poll method
Tene: then it would loop, because it's inside a handler
mls_ no, as it'll get caught again by the same exception handler
Tene moritz: responding to 01:47 < mls_> there's currently no way in nqp to rethrow an exception 08:57
tadzik moritz: ooh, that's probably because I hacked it to use poll to check if it works, sorry
moritz: I'll try to find the original
mls_ (that's why I added that "rethrow_skipnextctx" opcode)
Tene mls_: pir's rethrow picks up on the handlers list where it left off; there are tests for this in parrot and everything.
tadzik moritz: pastebin.com/C8EJw0KD that's the one 08:58
Tene unless nqp is doing something pretty broken...
08:58 mj41 joined
mls_ hmm, wait, you're right 08:58
I think I mixed that up with throwing an exception of the same kind 08:59
Tene t/op/exceptions.t
now, it's ALSO true that parrot's exceptions system needs significant work.
That's still the next item on my parrot TODO list... that hasn't been touched since about 2009... 09:00
mls_ See the "IMHO..." rant above
Tene mls_: I rather disagree; exceptionhandlers shouldn't be pushed and popped, they should be indicated through bytecode annotations 09:01
so rather than a single "the exceptionhandler stack", you've got the handlers in scope at whatever context you choose to look at 09:02
that's not quite the same angle you're talking about it at, though, I guess.
mls_ No, I also thought about that ;) 09:03
Tene Have you read whiteknight's blog posts about parrot's exceptions system, and his redesign plans?
masak url?
mls_ (Actually I think the lexpad/info system could also work with annotations) 09:04
Tene whiteknight.github.com/
mls_: sure, but that's a matter of caching 09:05
mls_ caching what?
Tene I guess that link doesn't go back that far; he must hav eblogged somewhere else before.
although whiteknight.github.com/2011/08/17/s...steps.html is significant
09:05 cognominal_ left
mls_ Theres an "All Posts" link on the page 09:06
09:07 cognominal joined
Tene yeah, but the oldest post there is relatively new, and more-recent than I remember his exceptions posts. 09:07
mls_ I read his "Parrot ExceptionHandlers Redux" post
Tene wknight8111.blogspot.com/2010/02/pa...ystem.html is probably somewhere in the sequence I'm thinking of
mls_ seems to be orthogonal to your "annotation" idea 09:08
Tene oh, I was looking at "recent posts"
09:09 Mowah_ joined
Tene see also, whiteknight.github.com/2009/09/14/e...right.html 09:10
09:10 koban left
moritz tadzik: two observations: 1) yes, it behaves funny 2) the line if $fh == $!listener cannot work 09:10
because $!listener is a IO::Socket::INET object 09:11
tadzik may be, I didn't examine im2ee's code really closely
09:11 mberends joined
moritz the failure mode does seem to be fairly random 09:11
mls_ exception_handlers_done_right seems to be from a time before the "finalize" opcode was added
moritz I got a few 'get_pmc_str not implemented' and a segfault now and then
tadzik I got get_pmc_keyed a number of times 09:14
did you try with GC disabled maybe?
(I didn't)
moritz no 09:15
mls_ rethrow seems to work. Tene++ 09:16
masak Tene: thank you.
tadzik moritz: w/o GC it fails reliably with No applicable candidates found to dispatch to for 'Numeric'. 09:18
that's probably connected to the comparison you pointed out as wrong
moritz it got there once or twice for me
tadzik and it segfaults with ms2 09:19
anyway, that looks like a gc bug or so
moritz it could still be a misuse on the p6 side
which corrupts memory, and only triggers if the GC accesses it 09:20
tadzik hmm
dalek p: 7baf769 | mls++ | src/HLL/Compiler.pm:
Simplify control exception handling by using rethrow, fixes pir::exit (what was I thinking?). Tene++
masak nom: say Date.new 09:21
p6eval nom 9c3d3d: OUTPUT«Date.new(Int, 1, 1)␤»
masak o.O
09:21 lumi_ joined
masak nom: say DateTime.new 09:21
p6eval nom 9c3d3d: OUTPUT«Use of uninitialized value in string context␤DateTime.new(year => , month => 1, day => 1, hour => 0, minute => 0, second => 0/1)␤»
masak folks, we have crappy constructors.
tadzik (: 09:22
masak nom: say Date.now
p6eval nom 9c3d3d: OUTPUT«Method 'now' not found for invocant of class 'Date'␤ in block <anon> at /tmp/4FKDhTrvy5:1␤ in <anon> at /tmp/4FKDhTrvy5:1␤»
masak nom: say Date.today
p6eval nom 9c3d3d: OUTPUT«Date.new(2011, 10, 19)␤»
masak nom: say Date.today - 31
p6eval nom 9c3d3d: OUTPUT«Date.new(2011, 9, 18)␤»
09:22 Vlavv` joined
masak nom: say DateTime.now 09:22
moritz so what should DateTime.new() return? same as DateTime.now ?
p6eval nom 9c3d3d: OUTPUT«DateTime.new(year => 2011, month => 10, day => 19, hour => 9, minute => 22, second => 54, timezone => $*TZ)␤»
masak moritz: maybe.
jnthn moritz: Busy now but any bt for the segfault would be helpful; I'll have tuits again pretty soon :) 09:23
masak moritz: the only other option I can see is Unix epoch.
nom: say DateTime.now - 31
p6eval nom 9c3d3d: OUTPUT«No applicable candidates found to dispatch to for 'Numeric'. Available candidates are:␤:(Mu, Mu %_)␤␤ in method Numeric at src/gen/CORE.setting:604␤ in sub infix:<-> at src/gen/CORE.setting:1959␤ in block <anon> at /tmp/q2XLfTZvZN:1␤ in <anon> at /tmp/q2XLfTZvZN:1…
09:25 Vlavv_ left
moritz jnthn: captured a bt... 09:25
jnthn moritz: Thanks. 09:26
jnthn will likely have Mon and Tue for Perl 6 stuff
moritz jnthn: gist.github.com/1297836
tadzik #2 0x00007ffff05de1ab in Parrot_Select_nci_can_read ()
eek
moritz tadzik: I have a few cosmetic improvements to IO::Select... do you want a pull request, or give me a commit bit? 09:28
tadzik moritz: you now have a commit bit 09:29
moritz tadzik: thank
OOHHH
nqp::unbox_i($mode)
missing decontainerizer, no?
jnthn unbox will decontainerize
It's only getattr and bindattr that do not
tadzik *relief*, I'm using it all the time :)
moritz ok
moritz wonders if we should have getattrdecont and bindattrdecont 09:30
tadzik neighbours, goddamnit. Sure, 9 AM is a perfect time to drill your walls for the next 3 hours and more 09:31
sure, when someone sits at home instead of sitting in an office, he's slacking off and deserves it
shame he's over me, so I can't flood him
09:32 miso2217_ left, miso2217_ joined
moritz cosmetic changes pushed 09:32
tadzik cool 09:33
09:33 daxim joined
moritz hm, they require a new-ish rakudo 09:33
09:34 wk_ left
mls_ (dumb question: shouldn't select.pmc have a mark function?) 09:36
tadzik mark, as in GC mark?
mls_ yes
moritz mls_: doesn't auto_attrs provide that automatically?
mls_ I don't know, that's why I wrote "dumb"
moritz lots osf PMCs use auto_attrs *and* provide mark() 09:37
*of 09:38
so it's probably not such a dumb question after all :-)
mls_ (I asked cause the backtrace showed a "FixedIntegerArray", but fd_map is supposed to be a Hash) 09:40
09:45 jaldhar left
moritz select.pmc line 228, why a VTABLE_get_pmc_keyed_int on a hash? 09:48
09:49 jaldhar joined
mls_ mortz: what's wrong with that? 09:50
moritz:
moritz mls_: don't you usually look up hashes by string, not int?
mls_ depends on the hash
(hmm, they should indeed turn it into an integer keyed hash for speed) 09:51
i.e. VTABLE_set_integer_native(INTERP, fd_map, Hash_key_type_int); 09:53
add that to select.pms's init() function 09:54
moritz let me see if I understood the select.pmc code (a bit at least) 09:56
fd_map is a hash keyed by file handle number
and as values has some PMC payload
mls_ seems so 09:57
moritz and if you call can_read, the payloads of all those things are returned where the corresponding file handle can read something
mls_ yes
09:57 cyri_ joined
tadzik random thought: if we ever wanted poll(), epoll() or whatever, the majority of select.pmc code will stay, no? 09:57
mls_ the interface would probably stay the same, yes 09:58
moritz so IO::Select should call $select_pmc.update($fh, $perl6_handle, $mode)
what it currently does with $!iter doesn't make sense to me
tadzik hrm
moritz it's not wrong, mind you 09:59
it's just an unnecessary level of redirection
tadzik Select pmc tests use $P1.'update'($P3, $P9, 5)
$P3 = new ['FileHandle'], $P9 = new 'String' 10:00
moritz but $P9 doesn't need to be a string
tadzik $!iter in IO::Select is just a random unique identifier
moritz you can just pass the Perl 6 level file handle object to update()
tadzik oh, cool 10:01
moritz changes and tests
tadzik that'd simplify lots of stuff
moritz even more than you think 10:02
tadzik I think it's exactly as I think :)
moritz it maeks $!pmc.can_{read,write} return RPAs of Perl 6 objects
which automagically get turned into Parcels
so get_handles can go away completely 10:03
tadzik oh, I didn't know they'd automagically convert
then yes, it simplifies more than I think
moritz slaughters tadzik++'s code
mls_ poor code...
tadzik fair enough :)
mls_ (I meant it's poor because it gets slaughtered, not that you wrode bad code) 10:04
wrote
moritz tadzik: return values from method calls automatically go through pir::perl6ize_type
tadzik I just subconsciously assumed, that the hash goes String->Filehandle
moritz and that maps RPAs to Parcals
tadzik hence the black arts in the code 10:05
moritz tadzik: me too at first
anyway, slaughterfest pushed :-)
tadzik :)
mls_ moritz: do you want to commit the two parrot changes (- add mark, set hash key type)? 10:06
tadzik the comments should go away as well now
I'll remove them
10:06 packetknife joined
moritz mls_: no, I'm not comfortable enough with the code yet. Feel free to do it if you feel comfortable though 10:07
mls_ but adding a mark function fixed the segfault?
or do you run with no GC?
moritz tadzik: and sure enough, my next two test runs with im2ee++'s code resulted in "No applicable candidates found to dispatch to for 'infix:<==>'."
tadzik great
moritz mls_: it seems the segfault is gone one way or another :-) 10:08
tadzik I hate those segfault, hiding in the bushes
moritz hm, not gone :(
tadzik when you hack together, they're gone, but just wait til you're alone and they catch you and bust your throat wide open
moritz just more seldom now
tadzik less code, less gc :P
moritz :-) 10:09
less code, fewer bugs on the p6 side
tadzik yep
10:11 wk_ joined
moritz wow, a for loop produces 7 routines in the stack trace 10:11
sub eager, 2x method eager, gimme, 3x method reify
masak tadzik: after that description of murderous segfaults, I'm afraid to sleep at night. 10:12
tadzik masak: don't worry, they're harmless when you're not hacking 10:15
moritz: now that's horrifying
moritz nom: for 1 { die } 10:18
p6eval nom 9c3d3d: OUTPUT«␤ in block <anon> at /tmp/br68xCgMZ6:1␤ in method reify at src/gen/CORE.setting:4045␤ in method reify at src/gen/CORE.setting:3952␤ in method reify at src/gen/CORE.setting:3952␤ in method gimme at src/gen/CORE.setting:4309␤ in method eager at src/gen/CORE.settin…
tadzik hah 10:20
10:29 agentzh left 10:35 eiro left 10:39 grondilu joined 10:41 kensanata joined
grondilu perl6: .say for (1, { [ 0, @^x Z+ @x, 0 ] } ... *)[^10] # perlgeek.de/blog-en/perl-6/pascal-t....writeback 10:42
p6eval niecza v10-58-gc851cf8: OUTPUT«1␤1 1␤1 2 1␤1 3 3 1␤1 4 6 4 1␤1 5 10 10 5 1␤1 6 15 20 15 6 1␤1 7 21 35 35 21 7 1␤1 8 28 56 70 56 28 8 1␤1 9 36 84 126 126 84 36 9 1␤»
..rakudo 9c3d3d: OUTPUT«1␤1␤1␤1␤2␤1␤1␤3␤3␤1␤»
..pugs b927740: OUTPUT«*** ␤ Unexpected "[^"␤ at /tmp/ff6GKq3CiA line 1, column 44␤»
grondilu rakudo flattens the lisst :(
perl6: .say for (1, { eager [ 0, @^x Z+ @x, 0 ] } ... *)[^10] # perlgeek.de/blog-en/perl-6/pascal-t....writeback 10:43
p6eval rakudo 9c3d3d: OUTPUT«1␤1 1␤1 2 1␤1 3 3 1␤1 4 6 4 1␤1 5 10 10 5 1␤1 6 15 20 15 6 1␤1 7 21 35 35 21 7 1␤1 8 28 56 70 56 28 8 1␤1 9 36 84 126 126 84 36 9 1␤»
..pugs b927740: OUTPUT«*** ␤ Unexpected "[^"␤ at /tmp/EQz0YdkWoQ line 1, column 50␤»
..niecza v10-58-gc851cf8: OUTPUT«===SORRY!===␤␤Undeclared routine:␤ 'eager' used at line 1␤␤␤Unhandled Exception: Check failed␤␤ at /home/p6eval/niecza/boot/lib/CORE.setting line 766 (CORE die @ 2) ␤ at /home/p6eval/niecza/src/STD.pm6 line 1136 (STD P6.comp_unit @ 36) …
tadzik interesting
grondilu niecza doesn't know eager ?? 10:44
10:44 replore_ left
tadzik it would seem so 10:49
grondilu nom: .perl.say for (1, {[$_, $_]} ... *)[^4]
p6eval nom 9c3d3d: OUTPUT«1␤1␤1␤[1, 1]␤»
grondilu nom: .perl.say for (1, {eager [$_, $_]} ... *)[^4]
p6eval nom 9c3d3d: OUTPUT«1␤[1, 1]␤[[1, 1], [1, 1]]␤[[[1, 1], [1, 1]], [[1, 1], [1, 1]]]␤»
grondilu it should not flatten, should it?
tadzik I don't know 10:51
masak it feels really odd that there should be a difference there. 11:06
tadzik: but... but... what if I hack in my sleep? o.O 11:07
grondilu masak: +1 When you put brackets in a list, you certainly don't expect them to be flattened.
masak agreed. 11:08
grondilu moreover, that's how LW intended it when he wrote his Pascal's triangle one-liner. 11:09
masak "JavaScript is not interpreted Java. Java is interpreted Java." -- (Douglas Crockford)++ 11:11
grondilu: I had to think several seconds before realizing who this "LW" fellow is :) 11:12
around here, he seems to go under the names TimToady (or TiMBuS if you mis-tab)
or $Larry.
grondilu ok, noted 11:13
masak heh, not correcting you -- just making fun of my own confusion ;)
grondilu actually I don't quite understand this relationship between laziness and flattyness. Why lazy list context should imply flattening? 11:18
masak perl6: say "there is more than one way to do it".words.map(*.substr(0,1)).join.subst("wtdi", "ady").trans("t" => "T") 11:19
p6eval niecza v10-58-gc851cf8: OUTPUT«␤Unhandled Exception: Unable to resolve method trans in class Str␤ at /tmp/jPPsLbfmUK line 1 (MAIN mainline @ 5) ␤ at /home/p6eval/niecza/lib/CORE.setting line 2176 (CORE C1040_ANON @ 2) ␤ at /home/p6eval/niecza/lib/CORE.setting line 2177 (CORE module-C…
..pugs b927740: OUTPUT«*** No such method in class Str: "&words"␤ at /tmp/5MtMHgxETb line 1, column 5 - line 2, column 1␤»
..rakudo 9c3d3d: OUTPUT«Method 'trans' not found for invocant of class 'Str'␤ in block <anon> at /tmp/aivvGh6elP:1␤ in <anon> at /tmp/aivvGh6elP:1␤»
masak b: say "there is more than one way to do it".words.map(*.substr(0,1)).join.subst("wtdi", "ady").trans("t" => "T") 11:20
p6eval b 1b7dd1: OUTPUT«TimToady␤»
masak grondilu: does lazy list context imply flattening?
that's news to me.
grondilu that's how I explain the case above, anyway 11:21
masak but the above case is wrong... 11:22
11:24 satyavvd left 11:25 amkrankruleuen left, amkrankruleuen joined 11:31 tokuhiro_ left 11:33 envi_ joined 11:34 whiteknight joined
moritz note that we already have a ticket for gather { take [...] } flattening the array 11:35
11:37 mberends left 11:38 Psyche^ joined
masak yeah. 11:39
mls_ back from lunch 11:41
11:41 Patterner left, Psyche^ is now known as Patterner
grondilu About lazyness and flattening, I was confused by a paragraph in S09: « All list contexts are lazy by default. They might still flatten eventually, but only when forced to. You have to use the "eager" list operator to get a non-lazy list context, and you have to use the "flat" operator to guarantee flattening. However, such context is generally provided by the eventual destination anyway, so you don't usually need to be explicit. 11:48
»
It seem to mix both concepts in a weird way
moritz it seems to me that .flat isn't eager 11:49
so they are distinct
grondilu is there an opposite of 'flat', anyway? 11:59
12:00 replore_ joined, replore_ left
moritz yes, it's called .tree 12:00
and is NYI in rakudo :(
grondilu perl6: say <2/6> # testing Rat literals 12:03
p6eval pugs b927740, rakudo 9c3d3d, niecza v10-58-gc851cf8: OUTPUT«2/6␤»
12:04 mj41 left
moritz masak: www.andymcm.com/csharpfaq.htm#6.8 somehow that reminded me of your p6l mail 12:06
masak peruses
ah, that p6l mail. :) 12:07
I've had some further thoughts since my last email in that thread.
most notably, it only makes sense to enforce constness when the relation between class and attribute is that between a container and a containee. 12:08
and that's by no means a guarantee.
12:08 Mowah_ left
moritz that's a strangely consistent insight :-) 12:08
masak so for aggregate/container-style classes, automatic constness would be great. for more graph-like object structures, it would suck.
and the difference seems to sit very much in design-space, not in code-space. 12:09
even in spoken language, we don't differentiate between container has-ness ("I have a liver") and graph-y has-ness ("I have two sisters") 12:11
12:11 bluescreen10 joined
mls_ ok, I pushed the select.pmc change 12:12
moritz right, "has" can mean possession or association (or many other things, I guess)
mls_++
mls_ I even added a test case ;) 12:16
masak moritz: which tells us that preemtive cloning probably shouldn't be a core language feature after all. 12:18
moritz masak: correct. I arrived by the same conclusion with the example of DB handles as attributes, but I wasn't able to summarize it so well 12:19
cognominal I have problem to follow "has" meanings :) 12:20
masak now you know why :P 12:21
moritz masak: now the question arises if there are cases that can't be clearly classified as either/or 12:22
12:22 pmurias joined
pmurias diakopter: that's what i meant 12:22
phenny pmurias: 07:52Z <diakopter> tell pmurias I was talking about using niecza as a front-end, not targeting niecza.
masak moritz: well, "container-y" is pretty clearly defined. I'm not sure "graph-y" is. 12:24
if you define it as "everything else", there's no third option ;)
moritz well, it could partially container-y 12:25
that's my question at least, if there are "partially container-y" cases
pmurias diakopter: i assume you will want to use make sprixel interpret the opcodes rather then take the AST itself and do the normalisation by yourself 12:26
12:28 jaldhar left, DarthGandalf left 12:29 grondilu left 12:31 DarthGandalf joined, DarthGandalf left, DarthGandalf joined
masak moritz: a db handle could definitely be container-y. it's not so much about the type of the object as it is about the exclusiveness of the 'has' relation. 12:34
12:34 benabik left
masak (...so I should have said "a 'has $.db_handle' relation could definitely be container-y") :) 12:35
moritz a db handle is also something that can't be cloned in the general case 12:36
masak right. probably won't survive a serialization winter either. 12:37
12:37 am0c left
masak that's why the example felt familiar ;) 12:37
moritz a db handle is also something that is inherently mutable 12:38
so it doesn't make sense to expose it to the outside and have it write-protected
12:42 daxim left
masak so I'm finally in complete and utter accord with sorear: this is an intrinsically hard problem. there's no slap-on band-aid solution. 12:42
moritz interesting how it sometimes takes us mere mortals several days/weeks/months of pondering to arrive at such conclusions :-) 12:44
masak yeah. not many things beat Already Having Studied Stuff™. 12:49
and sorear++ seems to have done a fair bit of that.
moritz aye 12:50
colomon studying++ 12:51
masak I found this: javascript.crockford.com/tdop/tdop.html -- might be interesting for people who like parsing and defining languages. 12:54
I haven't read far enough to realize how similar its techniques are to Perl 6's optable parsing.
moritz I think mberends++ was carrying a printout of that thing around when we last met :-) 12:55
masak heh :) 12:59
no, it's fairly different to the shift-reduce that Perl 6's optable parser uses. 13:01
both appear to be non-backtracking, though. 13:02
moritz backtracking is a violation of the one-pass parsing rule, if you're strict 13:03
masak right, and the rationale for that rule is "it's the way humans read code". 13:04
13:05 tokuhiro_ joined
moritz and also "we have too bad experience with the other alternative" :-) 13:05
masak another good reason to drop backtracking as you graduate from regex to grammar/language is that it has really bad performance characteristics ;)
13:06 im2ee joined
moritz aye 13:06
im2ee Hello! :)
phenny im2ee: 18 Oct 21:42Z <tadzik> tell im2ee gist.github.com/1296356 is the best I've got, works with rakudo bed705e
im2ee thanks phenny :)
moritz we've also greatly simplified the IO::Select code, and found a bug in your TCP server code :-) 13:08
masak im2ee: hallo! :) 13:12
13:14 djanatyn left, djanatyn joined 13:16 pnu left 13:17 pnu joined
cognominal submitted a bug : rt.perl.org/rt3//Public/Bug/Displa...?id=101700 13:19
Apparently garbled by gmail :( 13:20
moritz cognominal: that happened a few times to me
cognominal readable anyway
moritz cognominal: the problem is that you don't return anything from the Q:PIR block (not assigning to %r), but you're using it as the last statement in a block, so it needs a return value 13:21
if Q:PIR was a specced feature, I'd say that it needs a better error message
as is, I'd just say "Q:PIR isn't meant for general consumption. Bad luck."
awwaiid TiMBuS, if you are interested in coro like stuff you might check in with nine, who is attacking it at the parrot level to start with 13:22
cognominal I would say, because it is not a specced feature it need a better error message or silently return some value. 13:23
13:23 DarthGandalf left 13:24 pnu left, pnu joined
moritz just put a 1; after it 13:25
seems to be the same bug as RT #101562 13:26
13:26 Holy_Cow joined 13:28 skangas joined 13:30 DarthGandalf joined 13:31 benabik joined 13:33 localhost left
moritz cognominal: anyway, thanks for your golfing attempts, it made me realize that the problem isn't related to --doc at all 13:33
13:34 localhost joined 13:35 djanatyn left 13:37 djanatyn joined, bluescreen10 left
masak the ternary operator C<?? !!> is like a golfed switch statement for Bool values. 13:38
cognominal masak: more like an huffmanization because all golfing is not an huffmanization 13:40
*not all 13:41
13:46 finanalyst joined
masak indeed. "a huffmanized switch" statement catches more exactly what it's about. 13:47
im2ee masak, how are You? :) 13:48
masak im2ee: I'm insanely busy, but (luckily) very healthy and happy and not too tired. :) 13:51
im2ee: any You, sir?
finanalyst hi. just updated rakudo. Process took so long at ./perl6 stage that I thought computer had hung 13:52
could a warning be inserted to say it will be a long time??? 13:53
im2ee masak, I'm busy too, i don't have enough time for p6.
masak :/ 13:56
im2ee: sometimes that happens.
13:57 thou joined
masak finanalyst: do you mean during 'make'? usually for me, building the 'perl6' executable isn't the heavy step. 13:57
finanalyst masak: hello and yes during 'make' 13:58
in the past the process did not stop for long at any one step. this time there was a very significant delay
so much delay, that I aborted the process, deleted the rakudo directory, cloned and started again 13:59
benabik masak: I think building the setting is the first step that starts with ./perl6
finanalyst that's right
14:00 pmurias left
finanalyst hence I am suggesting echoing a warning before the step to indicate it will be slow 14:00
benabik Would it be noticed if it was before the ./perl6? That's a particularly long command line. 14:03
14:03 toebu joined
finanalyst if the step was very slow, most people would look to see where the step started in order to report a bug 14:04
if the notification was in CAPITALS it should be noticed
benabik Point.
masak the step is kinda slow for people with enough memory. it's prohibitively slow for people with too little memory. 14:05
bonus points for making the warning be conditioned on how much free memory the user has.
benabik I thought I had made it hang during GSoC.
masak: Buh.
masak but maybe that's too brittle and platform-dependent.
finanalyst could the step be broken in to pieces? 14:06
14:06 kensanata left
finanalyst then some progress would be noticed 14:06
14:07 drbean left 14:08 finanalyst left
benabik I'd suggest building it in parts and using pbc_merge, but I somehow doubt that that works well with the serialization context. 14:09
14:09 Holy_Cow left
mls_ (also, pbc_merge drops all code annotations) 14:10
jnthn No, it can't be easily broken into parts. 14:11
masak finanalyst, benabik: it might come as no surprise at all to you that breaking that compilation step into pieces has been suggested many, many times. :) 14:12
benabik masak: Nope. :-D
jnthn Plus it's a bandaid
masak that, too.
jnthn We should spend time on solving the real issues.
benabik Not really. something broken into parts can be parallelized.
masak the setting *is* one single scope and needs to be compiled as one.
it's fundamentally not breakable into pieces. 14:13
benabik If it can be done sanely, it's a win. I'm not taking bets on if it can be done that way though. :-D
mls_: That's LTA. The Packfile PMCs seem pretty full featured. I wonder if a more sane pbc_merge could be made with them...
masak benabik: it's like saying "I'd be finishing this book much faster if I just read all the pages in parallel".
14:14 drbean joined
benabik masak: I'm just saying that breaking it into pieces is a permanent win, not a bandaid. I'm not saying that it's simple. :-) 14:15
14:15 Trashlord left 14:16 mj41 joined 14:17 Trashlord joined
masak benabik: and I'm just saying that it's not about simple/not simple, it's about what the compilation process allows in the first place. 14:17
you can't make sensible decisions about a lexical scope until you've compiled all of it.
14:18 envi_ left
masak I might be wrong about that -- there might be some insanely cool unification algorithm that I don't see -- but I doubt it. 14:18
and by the time we're talking about something like that, we're talking about a fairly expensive band-aid.
benabik I think you'll find me quite unwilling to declare something impossible. :-D People come up with stupid and clever things all the time. Perhaps instead of "not simple" I should have said "worth writing a paper on". 14:19
Although I think the problem of compiling a scope in pieces is similar to bounded serialization. Need to compile something that leave holes where the other pieces need to go. 14:21
14:21 envi_ joined
TimToady sounds like macros... 14:22
cognominal a work for masak? :)
jnthn benabik: Er, given the entire premise of bounded serialization is that the boundary is a compliation unit, I really don't think so. 14:23
Or at least, that's how I've always had it. 14:24
14:25 bluescreen10 joined
benabik Is there something that locks a lexical scope down that I'm unaware of? Something that makes adding to it impossible? 14:26
masak you mean apart from the fact that they're in a sense immutable?
benabik Yeah.
14:26 aindilis left
TimToady finishing compiling a block makes it immutable 14:26
14:27 skangas left
TimToady except for where CHECK needs to cheat to do optimizing/linking 14:27
masak then that's your insurmountable limitation.
[Coke] jnthn: nice trick would be to have a pre-compiled setting. 14:28
need more from the VM before that can happen, I think.
benabik It would be nice if PBC was a more stable format.
TimToady the setting is allowed to cheat, as long as it looks simple from the inside
masak afk
14:28 drbean left
tadzik ak 14:28
benabik What I'm discussing is somewhat mid-compilation… But I think this is a long drawn out discussion of theoretical compilation that it seems that people aren't interested in. I'll file it in the mental drawer labeled "research for another day" 14:30
benabik is a CS grad student with a focus in compilers, so is very unwilling to accept "impossible", only "insufficiently researched." 14:31
14:33 aindilis joined, aindilis left, drbean joined 14:42 kaleem left
frettled It is impossible to solve the travelling salesman problem within P with a compiler. 14:45
frettled flexes his impossible mental muscles. ;)
benabik frettled: Only if P != NP. If you can prove that, there's a few people who want to talk to you. 14:46
:-D 14:47
frettled benabik: feel free to disprove that statement :D
benabik frettled: Well, that would mean I could prove P = NP… In which case, I wouldn't have such a problem figuring out my thesis. :-D 14:48
[Coke] not as long as you could fold it properly.
14:49 SHODAN left
cognominal perl has solved that problem long ago 14:51
$ perl -E 'say P == NP'
1
:)
14:51 wtw left
frettled cognominal: damn, that was quick 14:51
Or, in expanded parlance: Problem equals no problem. 14:52
Problem is no problem.
[Coke] nom: say P==NP 14:53
p6eval nom 9c3d3d: OUTPUT«===SORRY!===␤CHECK FAILED:␤Undefined routine '&P' called (line 1)␤Undefined routine '&NP' called (line 1)␤»
14:56 kaare_ joined
cognominal call that a regression :) 14:56
frettled or a problem 14:57
sorear good * #perl6 14:59
cognominal: bareword literals need to stay dead, tyvm.
colomon \o 15:02
15:15 cyfi left 15:21 tokuhiro_ left 15:25 cyfi joined 15:28 drbean left 15:30 cyfi left, cyfi joined 15:31 smash joined
smash hello everyone 15:32
[Coke] hola, smahs 15:34
*smash
15:35 drbean joined 15:41 dual joined
sorear o/ smash 15:43
15:44 Spaceghost joined 15:49 Spaceghost left
jnthn back from $dayjob 15:54
gfldex Method 'nqpattr' not found for invocant of class 'Undef' in <anon> at src/stage2/QRegex.nqp:493 in CAPHASH at src/stage2/QRegex.nqp:492 in method MATCH at src/gen/CORE.setting:6540 15:57
what could that mean?
ohh, and that used to work a few days ago
15:57 mkramer1 left
gfldex rule alias { 15:58
<name> \h* '=' \h* <name> { %aliases{$/<name>[0].Str} = $/<name>[1].Str }
}
that's the line triggering it
16:11 MayDaniel joined 16:12 tlhiv_work joined, tlhiv_work left
dalek ecza/serialize: afac2df | sorear++ | lib/Kernel.cs:
Implement multi-sub compilation
16:17
16:21 whiteknight left 16:22 mj41 left 16:34 packetknife left, mikemol left 16:36 mikemol joined 16:38 envi_ left
dalek ecza/serialize: b292bdd | sorear++ | lib/CodeGen.cs:
Add missing unit_set_bottom
16:39
sorear \o/ 'make' now completes successfully
generating obj/CORE.dll and obj/CORE.ser
16:45 envi_ joined 16:46 kaleem joined 16:49 dakkar left 16:53 daniel-s left 16:54 cognominal left
masak sorear: \o/ 16:55
tadzik phasers in...? 17:02
colomon 28 mins?
moritz I will miss #phasers today 17:03
17:07 donri joined
sorear colomon: yes 17:08
17:15 im2ee left 17:16 MayDaniel left, whiteknight joined, im2ee joined, drbean left 17:22 drbean joined
[Coke] masak: /who/ is going to discuss your grant, as it's not the grants comittee... 17:23
karen and the board?
masak checks 17:27
I hope I'm allowed to discuss this... :)
[Coke] masak: you can tell me privately if you have concerns. I /am/ on the GC, if that makes you feel better. ;) 17:28
masak nodnod
something called the "TPF Board", apparently.
pmichaud normally Karen initiates a discussion among the TPF board for Hague grants 17:31
masak ah.
pmichaud when a consensus opinion is reached, they award (or decline) the grant 17:32
pmichaud reads some backscroll for context
jnthn pmichaud: Also see irclog.perlgeek.de/perl6/2011-10-19#i_4588897 :) 17:33
[Coke] pmichaud: I will now imagine you speaking with the voice of Patrick from Spongebob for the next hour or so!
pmichaud jnthn: I think I need a bit more detail than that line gives. 17:34
jnthn pmichaud: There's an example that triggers it down below 17:35
pmichaud I see the "alias" rule.
I don't see the text being matched.
jnthn pmichaud: From what I can see, CAPHASH uses nqpattr
pmichaud sure, CAPHASH uses nqpattr. 17:36
jnthn pmichaud: Which I'm guessing doesn't work out on Perl 6 subs, but now I look closer...that reasoning looks adrift as it was trying to do it on Undef.
gfldex: Got the input that pattern was being matched against?
pmichaud I'm guessing that something is expecting $!regexsub to be set 17:37
17:37 MayDaniel joined
pmichaud ah, I know what it is. 17:37
Hrm.
it's trying to build the slots for $/ and the current match object doesn't have $!regexsub set. 17:38
okay, I can fix.
jnthn yay :)
[Coke] pmichaud: how goes tuits?
pmichaud unpredictably. 17:39
I thought I would have a decent set of tuits over the last week but they never materialized (changes in chemotherapy scheduling and additional non-perl6 events) 17:40
17:46 envi_ left, ruoso left, ruoso joined 17:47 hillu left, hillu joined, sunnavy left, renormalist left, renormalist joined 17:48 carlin joined, sunnavy joined
[Coke] I hope everything goes well in the chemo department. 17:50
sorear niecza: if 1 { LEAVE { say 'x' }; die }; CATCH { say 'y' } 17:52
p6eval niecza v10-58-gc851cf8: OUTPUT«y␤x␤␤Unhandled Exception: Died␤ at line 0 (ExitRunloop @ 0) ␤ at /tmp/jtgfEOHPJx line 1 (MAIN C1_ANON @ 2) ␤ at /tmp/jtgfEOHPJx line 1 (MAIN mainline @ 1) ␤ at /home/p6eval/niecza/lib/CORE.setting line 2176 (CORE C1040_ANON @ 2) ␤ at /home/p6eval/nie…
pmichaud (chemo) we hope so also. :) 17:54
18:00 PacoLinux left 18:01 PacoLinux joined, mj41 joined 18:02 pnu left, pnu joined
gfldex jnthn: Mega = Megacyte\n 18:07
18:08 GlitchMr joined
gfldex jnthn: i would like to point out that there seams to be a problem with arithmetics on linux 32bit that may even come from parrot right now. I will boot in a bit and check if the bug pops up on 64bit too. 18:08
dalek p: d2d759f | pmichaud++ | src/QRegex/Cursor.nqp:
Restore old meaning of $!regexsub to support intra-regex usage of $/.
benabik gfldex: What's the arithmetic bug? 18:09
pmichaud that latest nqp commit should fix the regex bug; I'm re-spectesting rakudo against it now. 18:10
gfldex benabik: my Rat $sum = 0.Rat; $sum += 24537130 * 3.37; $sum += 5678 * 4.28; say $sum;
pmichaud I don't have a good test case for the regex bug
gfldex gives: -3184915.98
and that's a little small :)
gcc (Debian 4.6.1-15) 4.6.1
pmichaud nom: say 5678 * 4.28 18:11
p6eval nom 9c3d3d: OUTPUT«24301.84␤»
pmichaud nom: say 24537130 * 3.37
p6eval nom 9c3d3d: OUTPUT«82690128.1␤»
gfldex i had other problems before with the new GCC that got fixed already
pmichaud yeah, I'm guessing a 32-bit overflow in Rat calculations
gfldex is there a test box for parrot with 32bit? 18:12
benabik Rats are parrot int over parrot in?
jnthn yeah
benabik (Or P6 type that stores a pint.)
pmichaud right now all Int calculations are done in 'int' precision
I'm going to fix that.
benabik Oh, I have 64b box here. Bleh.
pmichaud (autopromote to Num/num)
jnthn I plan to deal with bigint support in the near future, now my tuit supply is recovering :) 18:13
benabik nom: say 2 ** 31 -1 18:14
p6eval nom 9c3d3d: OUTPUT«2147483647␤»
colomon jnthn++
benabik nom: say 826901281 > 2147483647
p6eval nom 9c3d3d: OUTPUT«Bool::False␤» 18:15
benabik nom: say 8269012810 > 2147483647
p6eval nom 9c3d3d: OUTPUT«Bool::True␤»
pmichaud actually, it'll be * 100 I suspect
82690128100
18:15 carlin left
benabik 82690128.1 * 100 = 8269012810, which is the second case I tried. :-) 18:15
pmichaud although the code might be using lcm
ahhh
off-by-one-decimal error for me
18:16 carlin joined 18:17 buubot_backup left
pmichaud gfldex: let me know if feb9401 fixes your regex bug. 18:24
(just pushed) 18:25
dalek kudo/nom: feb9401 | pmichaud++ | tools/build/NQP_REVISION:
Bump NQP_REVISION to get CAPSHASH/$!regexsub fix from nqp.
gfldex pmichaud: will do
pmichaud if not, I need a better test case to work with.
what sorts of bad things happen if I remove the "returns Int" from multi infix:<+>(Int:D \$a, Int:D \$b) returns Int { 18:29
?
(I'm not talking about removing the "returns int" from the native case)
or are those just decorative for now? 18:30
18:30 Entonian joined
pmichaud I'm surprised to see the "nqp::want" lines in the native case -- are those just temporary? 18:31
jnthn pmichaud: The optimizer loses out. 18:33
pmichaud: It can - in some cases - decide at compile time that this is the candidate that will be called.
pmichaud: If we have $a * ($b + $c) and it knows they're all Int:D, then it needs to know that $b + $c produces an Int, so it can resolve the call to infix:<*> 18:34
pmichaud: And if it does resolve these ones it can inline them.
pmichaud: Yeah, the "want" thingy deserves sugar. 18:35
pmichaud I think it mustn't be there.
it's wrong to declare 'returns int' on something that returns an Int
masak reads opendylan.org/books/drm/Hygiene with interest 18:36
[Coke] pmichaud: does it autocast the return of an Int to an int?
jnthn pmichaud: At the moment it's there for the benefit of the inliner. The real answer is that all the nqp:: ops know how to tag the generated PAST nodes with the return type.
pmichaud: But that felt like something to resolve in the migration to QAST. 18:37
pmichaud I'm saying that the inliner needs to decide that 'wants int' before it ever selects a 'returns int' candidate. 18:38
I'm okay if we have those nqp::wants in there as a temporary optimization, but the use of 'want' there seems like it cannot be at all a permanent solution (and I'm worried it'll become a pervasive incorrect pattern that gets replicated throughout the codebases) 18:39
jnthn pmichaud: I'm not quite sure the "knows it wants int" is right either; it probably boils down to some of the issues that mean we don't have "want" in Perl 6 any more. 18:40
pmichaud no matter what, I'm pretty sure that it's a fundamental error to have a function that declares "returns int" return anything that isn't an "int" 18:41
masak +1
(that's what 'returns' means!) 18:42
jnthn Aside from S12 says Perl 6 does autoboxing/autounboxing. :)
But yes, I don't think the current factoring is what we should end up with.
pmichaud yes, but declaring 'returns int' really means you're removing the "auto" from the boxing.
and any autoboxing/unboxing needs to take place outside of the function, not within it.
masak ...what pmichaud said. 18:43
jnthn That's fine but it means we need to work out what return looks like in the native case, for example. 18:45
Anyway, I agree it's not how it should be. 18:46
pmichaud sure thing. I'm just making sure that what exists there now isn't planned to be the basis of the solution, because I think it cannot work.
18:46 wk_ left
pmichaud going back to "returns Int" -- a couple of weeks ago I thought we had decided to temporarily auto-promote out-of-range Int values into Num 18:46
but I can't do that if we declare "returns Int" and code relies on the things actually being Int
jnthn pmichaud: OK. Those annotations landed with the merging of the optimizer branch. 18:47
If you want, you can remove them for a bit.
pmichaud wfm
I'm open for whatever path you (and others) want to take 18:48
we can leave them in and say "wait for bigint support" for 32-bit platforms, if that's preferred. But I think that's likely to be too big a regression.
jnthn pmichaud: OK, my take is: if somebody has tuits to implement the num auto-promotion, we can strip off the Int annotations to make it work out. If I get bigint in before anybody gets the num auto-promote in place, then we don't need to. :) 18:50
pmichaud wfm 18:51
num autopromotion is actually pretty straightforward
so I expect to be able to do it relatively soon
(but my expectations are bogus)
anyway, if I do the autopromote and need to remove the annotations, I'll do it -- if you beat me to the punch, I'll celebrate and buy you some beer
jnthn \o/ 18:52
18:58 mls joined
mls Speaking about int/Int autopromotion, I sometimes wonder if parrot shouldn't have a "generic" register type 18:59
i.e. a register that can store both an INT and a PMC 19:00
so an add op would be $R2 = $R0 + $R1 19:01
benabik mls: You do that by using Integer PMCs.
mls and an occuring overflow would convert to a PMC 19:02
I do not like Integer PMCs
benabik mls: Trying to have the register be both makes many other things confused.
mls PMC allocation costs quite a bit
pmichaud Parrot has some fundamental flaws in how it treats opcodes; this is one of them.
mls I want it to be as fast as INT for the standard cases
jnthn Also Parrot doesn't have a concept of references. 19:03
pmichaud Anyway, I doubt those choices are in the realm of being open to change at this stage.
benabik mls: If the register is both, how do you distinguish the cases for the garbage collector? What do you do with method calls on these?
mls the register would also hold a type 19:04
benabik mls: And if the register is just int/Int PMC, you slow down all int/int math by having to check to see if one of them is a PMC.
mls: Then you slow down _all_ math by the cost of checking the type.
jnthn mls: fwiw, in Perl 6 we always know statically when we have a native.
pmichaud "always"? or "often"?
benabik jnthn: There's some incomplete and poorly thought out stuff about proxies and the like. I'd love to rip it out and replace it with proper container semantics. 19:05
Our opcodes conflate setting registers and assigning to containers. I do not like.
pmichaud benabik: welcome to the choir. :-) 19:06
mls Native regs should stay native. I just don't see how we can implement Perl6's Int semantics without using PMCs for every operation
benabik pmichaud: I don't think it's "unlikely to change". I think it's not at the top of the list for fixing.
PerlJam mls: you can always come up with your own VM :)
pmichaud benabik: I did say "at this stage".
jnthn mls: Well, given Int really is potentially always a bigint, there's probably on escaping allocation in that sense. 19:07
s/on/no
mls Most of time time it's an error to restart from scratch ,)
Yeah, that's why I said we would need some different register type that's just potentially an PMC, but can stay a native int for most of the cases 19:08
benabik But then you have to check the type on every op. And that's slow.
That slows down the common case.
PerlJam mls: as long as you didn't repeat parrot's mistakes, this wouldn't be one of those cases.
;-)
mls ,)
pmichaud in some sense parrot itself was "restart from scratch", iiuc. :-)
mls oops, meant ;)
benabik Parrot's open to change.
jnthn mls: Yes, what I'm saying is that you don't always statically know which it's going to be. 19:09
pmichaud benabik: I don't think anyone here is claiming that Parrot isn't open to change.
benabik And, to some extent, we do want to restart some. The M0/6model work we want to do is something like b -> nom. We just don't have as prolific people as pmichaud and jnthn working on it.
jnthn mls: And doing the checks would not be so ideal.
mls: What would work out better here is the optimizer spotting such things and emitting two code paths 19:10
mls I don't really like the two code path solution
19:11 mj41 left
mls You would have the same type checks, but coded in parrot opcodes 19:11
pmichaud right
that's a two-code path solution also :)
that's just putting the two paths inside the opcode instead of in the things that call the opcodes :)
jnthn mls: The two code path solution works out better for the places where we care about such optimization, I think. 19:12
mls: e.g. tight loops
mls: Where we'd emit the loop twice and its optimal as it can be in each of the paths, rather than having to do the checks again and again. It's hard to optimize a check out of an opcode. 19:13
19:13 Sarten-X left
mls yes, maybe 19:14
19:15 uasi left 19:16 shi joined, shi is now known as ksi, whiteknight left
cotto benabik: what I really need to do is retire early. ;) 19:18
benabik cotto: +1 :-D 19:19
19:21 risou_awy is now known as risou 19:22 nebuchadnezzar left 19:24 Sarten-X joined, nebuchadnezzar joined, wk joined 19:26 zby_home_ joined 19:27 bluescreen10 left 19:28 mls left 19:29 Entonian left 19:30 whiteknight joined 19:31 skangas joined 19:32 bluescreen10 joined
im2ee Good night! :) 19:33
o/
19:33 im2ee left
masak 'branoc, imarcusthis 19:36
er argh, im2ee.
masak makes a mental note not to tab complete on people who already left the channel
19:38 wk left 19:41 [Coke] left
masak TimToady: jnthn just proved to me that in a quasi with placeholders, type registration can't happen at parse time. 19:41
TimToady: I guess we can still register the type "names" in some loose sense, but the actual types will have to be constructed at macro expansion time in the worst case.
19:43 [Coke] joined 19:45 alester joined 19:48 mj41 joined
masak sorear: which means that your 'quasi { has $.x is rw }' isn't a completely lost case, I guess. 19:48
19:50 risou is now known as risou_awy
tadzik masak: see irclog.perlgeek.de/perl6/2011-10-18#i_4585443 19:52
[Coke] (open to change) I wouldn't say parrot isn't open to change. 19:53
diakopter being open to and being able to are different things
masak tadzik: I blame imarcusthis. 19:55
benabik Parrot could change faster if more people would work on it.
masak benabik: as opposed to all those overstaffed open source projects out there :P 19:56
benabik masak: Sure, work on the ones you want to work.
imarcusthis masak: everybody blames me :/
what did I do this time? 19:57
masak imarcusthis: your nick starts with 'im'
benabik masak: But don't say F/OSS project X isn't changing fast enough. We're all volunteers and work when we can. It's a truism of all open source.
imarcusthis masak: asl?
19:57 wk joined
_sri blames imarcusthis too 19:58
gfldex pmichaud++: match problem gone
masak benabik: agreed. in return, please try not to treat us as a homogenous mass. not all of us are saying "hey parrot, hurry up!". 19:59
imarcusthis: does that mean "age/sex/location"? in that case, I'm a precocious teenage girl from Indonesia. 20:00
benabik masak: I'm making responses to comments as I see them, not trying to yell at #perl6 in general.
masak benabik: goodie. 20:01
benabik masak: Perhaps trying to dig through years old trac tickets is just making me grouchy. 20:02
imarcusthis masak: Then I'm not interested. Only looking for middleaged males from sweden.
masak dang.
[Coke] benabik: BWAHAHAHAHAHAHAHAHAHAHAA
benabik [Coke]: Yeah, eah.
20:02 GlitchMr left
[Coke] I've done more work on ticket queues on parrot and perl6 than... I've done a lot. ;) 20:02
I wish you luck, stout adventurer! 20:03
jnthn likes adventures involving stout :)
masak imarcusthis: actually, I'm really an autonomous bot from the year 2043, with built-in antigravity and a Singularity damper. 20:04
PerlJam masak: a perl 6 bot? 20:06
dalek p: 763b9c5 | benabik++ | src/HLL/Compiler.pm:
Use Hash.update for command line args
p: 05b7873 | benabik++ | src/HLL/Compiler.pm:
HLL::Compiler: Allow --target with -e

Prior to this, using --target with -e would just result in the compiler ending early with no output. Of course, this would be more useful if we taught _dumper how to deal with 6model objects.
Based on a patch from chrisdolan in Parrot TT366
masak PerlJam: actually, I have bad news about that. turns out it was PHP that won out in the end. 20:07
PerlJam: "worse is better" and all that stuff, you know.
PerlJam: my advice is to start liking \ as a package separator, sooner rather than later... 20:08
imarcusthis: also, who are you calling middle-aged, young whippersnapper? ;) 20:09
imarcusthis masak: I was born in 1976 =)
masak dang again :)
PerlJam masak: so ... the message is get worser faster? 20:12
As long as we can choose a different timeline from the one that masak-bot came from, we're good. 20:13
masak nooooo you'll violate causa^#%@NO CARRIER 20:16
20:24 zby_home_ left
masak moritz: ping 20:27
20:34 kaleem left 20:36 cyri_ left 20:37 localhost left 20:49 cyri_ joined 20:52 localhost joined
dalek kudo/nom: 973ebc9 | jnthn++ | src/Perl6/Actions.pm:
Fix return type check issue reported in RT#101364.
20:53
tadzik make spectest 2210.87s user 148.94s system 95% cpu 41:04.40 total 20:55
jnthn phenny: tell japhb Does your work on MAIN resolve rt.perl.org/rt3/Ticket/Display.html?id=92986 ?
phenny jnthn: I'll pass that on when japhb is around.
jnthn tadzik: 228 wallclock secs here ;) 20:56
Which is more than it has been in the past, but...more tests.
Still, I want better :0
*:)
tadzik jnthn: what worries me is that last value recorded is make spectest 1163.76s user 93.29s system 98% cpu 21:11.38 total
on 2011-09-17
jnthn oh, ouch. :S 20:57
That's practically a doubling. I've seen nothing on that order of magnitude.
20:59 alester left 21:05 Chillance joined 21:06 soh_cah_toa joined
masak hi people -- I've put together this little text about D4 and environs. gist.github.com/1293853 21:11
Tene Starts with "Heal the World"; ambitious.
masak partly to make it a bit more of a known quantity, partly to show that these things while non-trivial are definitely doable.
21:12 Trashlord left
masak much of the things outlined in there have fallen into place in the last month or so while I've been implementing macros. 21:12
I'd be interested to hear if Tene or sorear have considered the "We're not done yet, it gets worse" part. my guess is "yes", but it took me quite a while to see that bit. 21:13
masak posts the gist as a comment on the Hague Grant application blog post 21:14
21:15 soh_cah_toa left, wamba left, envi_ joined
Tene masak: Reading the post now. 21:16
21:19 kaare_ left 21:21 soh_cah_toa joined
masak augh, need to sleep. 21:24
'night, fireflies and butterscotch. 21:26
colomon o/ 21:27
mmmm, butterscotch
21:27 mkramer joined
colomon mmmmm, scotch 21:27
benabik mmmm, butter
21:27 mkramer left
tadzik mmmm, mmmmm 21:28
colomon benabik: good point. :)
nothing wrong with fireflies, either, but they're not tasty, as far as I know.
jnthn mmm...czech pivo :) 21:31
jnthn spectests a fix for another RT ticket
21:31 toebu left 21:32 smash left, mj41 left 21:33 mj41 joined
dalek kudo/nom: 07b9b00 | jnthn++ | src/Perl6/Grammar.pm:
Fix for RT#89208 (oddness when declaring a sub in a for loop that needs to get an implicit $_).
21:33
jnthn std: class A { has $.a, $.b; }; A.new(a => 1, b => 10) 21:34
p6eval std 580b69a: OUTPUT«===SORRY!===␤Variable $.b used where no 'self' is available at /tmp/nSsjx59v2C line 1:␤------> class A { has $.a, ⏏$.b; }; A.new(a => 1, b => 10)␤Check failed␤FAILED 00:01 124m␤»
jnthn std: class A { has $.a; has $.b = 2 * $.a; } 21:37
p6eval std 580b69a: OUTPUT«===SORRY!===␤Variable $.a used where no 'self' is available at /tmp/VmNOngw8a4 line 1:␤------> class A { has $.a; has $.b = 2 * ⏏$.a; }␤Check failed␤FAILED 00:01 122m␤»
jnthn std: class A { has $.a; has $.b = 2 * $!a; }
p6eval std 580b69a: OUTPUT«===SORRY!===␤Variable $!a used where no 'self' is available at /tmp/7FFsP6gn0Y line 1:␤------> class A { has $.a; has $.b = 2 * ⏏$!a; }␤Check failed␤FAILED 00:01 122m␤»
jnthn TimToady: ^^ 21:38
21:38 Trashlord joined 21:39 dorlamm joined
jnthn That looks a little hard to fix, given when we parse the RHS we probably don't know it's an attribute initializer and will be promoted to an anonymous method. 21:40
21:46 skangas left 21:48 mj41 left
jnthn Well, that's some more RTs either fixed or tagged testneeded :) 21:56
rakudo.org/testneeded always shows me zero tickets... :( 21:57
TimToady a good argument for my original view that declarators should parse = specially 21:58
I don't remember why I was argued out of that...
jnthn TimToady: Me either... 21:59
TimToady: But this is the nth time I wish you hadn't been.
TimToady: constant, our, has etc all end up needing a similar hack due to their non-usual initialization. 22:00
Oh, and state
TimToady perhaps it was to catch precedence errors like $a + new $b = $c
jnthn new? :) 22:01
TimToady my
jnthn phew!
.oO( what scope declarator did they add while I was away teaching?! )
TimToady sorry, lingering nap
jnthn :)
22:02 benabik left
jnthn phenny: ask [Coke] how do I find out how many tickets are tagged [testneeded]? 22:02
phenny jnthn: I'll pass that on when [Coke] is around.
TimToady okay, >>todo at least 22:04
jnthn Thanks.
jnthn decides to wait and see what STD does here
:)
TimToady too...
diakopter heh 22:05
TimToady well, in any case, it's probably more important to fix the = semantics than to catch the precedence error for now 22:06
so we'll probably move that direction
jnthn std: (use Foo)()
p6eval std 580b69a: OUTPUT«===SORRY!===␤Cannot locate module Foo at /tmp/qd_xEcKMIf line 1:␤------> (use Foo⏏)()␤Check failed␤FAILED 00:01 119m␤»
jnthn std: (use STD)()
p6eval std 580b69a: OUTPUT«ok 00:01 139m␤»
jnthn What does a use statement evaluate to?
(if anything...)
TimToady S06:2994 22:07
jnthn whoa! 22:08
TimToady that's been in there for years :) 22:09
jnthn Do...do you still want it implemented?
TimToady seems very handy, but I wouldn't worry about it too much for starters 22:10
jnthn Yeah; the issue is that at the moment it evaluates to...nothing at all...and the above explodes with an IMCC error.
TimToady
.oO(did I just claim that jnthn++ was just starting?)
jnthn wsa looking in S10/S11 :)
TimToady it also seems a bit difficult, insofar as 'use' has probably already imported stuff 22:11
jnthn Yeah
You'd kinda want to know you had to do it as you imported.
TimToady unless we assume that use returns something that does the import
jnthn Well, apart from the import needs to happen at compile time 22:12
And the method call would happen at runtime.
TimToady there's that too
well, modules will happen
jnthn Cute idea. Probably not quite the right factoring.
Anyway, I guess the answer is not "the use statement evaluates to the last thingy in the module". 22:13
TimToady no, if anything it's a sort of macro
a self-calling macro, constructed by agreement of the export and import data 22:16
but perhaps also explicitly overridable by the module in question to do questionable at use time
jnthn But that still doesn't really answer the question of "what's there by runtime"
TimToady I guess it would depend on what the macro put there as the return value, if anything 22:17
might be useful someday, so maybe we should keep the option open
it's no worse than BEGIN returning something 22:18
22:18 dorlamm left
jnthn *nod* 22:18
I'll just do Nil for now until we get to looking at that.
TimToady is fine for now 22:19
22:20 cognominal joined 22:23 apejens left 22:27 dual left 22:33 ksi left
dalek kudo/nom: 433839e | jnthn++ | src/Perl6/Actions.pm:
Ensure import, use and need return something (Nil for now), so we don't get IMCC errors if you try and use the result of the use statement for something.
22:35
22:35 buubot_backup joined, wolfman2000 joined 22:40 buubot_backup left
dalek kudo/nom: aa32037 | jnthn++ | src/Perl6/Actions.pm:
Fix (and greatly simplify) handling of 'use fatal' (doubt we actually look at it anywhere yet, but this at least gets us beyond 'use fatal' giving a weird error).
22:46
22:50 daniel-s joined 22:51 bluescreen10 left
dalek kudo/nom: a0c370d | jnthn++ | src/Perl6/Actions.pm:
Get require to work again, though no import lists yet.
22:59
atures: 11e3427 | jnthn++ | features.json:
nom now supports require, though without import lists yet (so it gets +-).
23:02 buubot_backup joined, [Coke] left 23:04 [Coke] joined 23:05 kfo joined 23:08 kfo_ left 23:09 [Coke] left 23:10 [Coke] joined
[Coke] jnthn: first, login to rt. then go to: 23:11
phenny [Coke]: 22:02Z <jnthn> ask [Coke] how do I find out how many tickets are tagged [testneeded]?
[Coke] rakudo.org/rt/testneeded
jnthn: 23:12
(91 tickets current block on needing tests.)
jnthn [Coke]: I am logged in and still when I go there I get 0 23:14
nom: say 714 - 91
p6eval nom aa3203: OUTPUT«623␤»
23:17 [Coke] left 23:19 [Coke] joined
jnthn sleep & 23:22
23:23 [Coke] left 23:24 aqz left 23:25 [Coke] joined 23:29 thou left 23:32 molaf_ joined 23:33 envi_ left 23:36 molaf left 23:38 Chillance left
[Coke] phenny: help 23:41
phenny [Coke]: Hi, I'm a bot. Say ".commands" to me in private for a list of my commands, or see inamidst.com/phenny/ for more general details. My owner is sbp.
[Coke] phenny: tell jnthn that to get the # of tickets iwth testneeded, to login to rt, then go to rakudo.org/rt/testneeded 23:42
phenny [Coke]: I'll pass that on when jnthn is around.