»ö« | perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:, alpha:, pugs:, std:, or /msg p6eval perl6: ... | irclog: irc.pugscode.org/ | UTF-8 is our friend!
Set by moritz_ on 25 June 2010.
00:04 redicaps joined 00:07 jaldhar joined, lest_away is now known as lestrrat
dalek meta: r353 | stefa...@cox.net++ | trunk/vicil/Kernel.cs:
[vicil] Fix numerous syntax errors. Modernize implementation of &die.
00:09
00:14 amkrankruleuen joined 00:20 redicaps left 00:26 lkk- joined 00:31 songmaster left 00:37 amkrankruleuen left, amkrankruleuen joined
dalek meta: r354 | stefa...@cox.net++ | trunk/vicil/Kernel.cs:
[vicil] Add a bunch of stubs using the new KernelSetting.Die
00:44
00:48 yinyin joined 00:49 yinyin left 00:54 Ambiguity left 01:01 sftp left
frew can anyone explain to me how to use the <?> regex directive? 01:01
patrick explained it to me once and it seemed helpful, and I think I can use it now, but I can't recall what it does 01:02
a link to what/where to look for doc would be good too
it seems like some way to sprinkle some kind of anchor like things in your document, but I don't really understand 01:03
sorear <?> does absolutely nothing
frew sorear: so why use it?
sorear because a regex with no text in it is illegal as a probable error 01:04
<?> makes clear that you actually wanted to match nothing
"" is the same effect
frew ok, so why would you want to match nothing I guess I'm asking
sorear anchoring common actions is a common thing 01:05
token foo { <?> }
whenever <foo> appears, Actions.foo is called
frew ooh
sorear but <foo> matches nothing and doesn't affect the parse in any way
frew ok, so for actions
that makes sense
that makes it make perfect sense
thanks sorear++
I forget how actions tie in since I haven't used that much yet 01:06
sorear it's also occasionally useful in conjunction with the more unusual quantifiers
[ foo | <?> ] is the same as [foo]?
but there's no similar simplification of <?> ~ ')' foo
frew ah, interesting 01:07
what's that last one do?
sorear matches foo followed by ')', treating ')' as a closing delimiter for parse erors 01:08
frew hm, less dense than the regex, but I still don't understand :-) 01:09
sorear it *is* a pretty unusual quantifier
frew well, leave it for now :-)
sorear it's mostly intended for use in STD.pm6
frew sure
sorear stuff like '(' ~ ')' <EXPR>
01:10 Schwern joined
Schwern I have a question about pick(). If I say @picks = @list.pick(2) am I guaranteed to get two *different* items? 01:10
Or is pick sugar for @picks = map { $list[rand @list] } 1..2 (perl5 style) ? 01:11
frew Schwern: looks like either 01:12
Schwern: look at svn.pugscode.org/pugs/docs/Perl6/Sp...ainers.pod 01:13
Schwern: search for pick
Schwern Yeah, its not clear in the synopsis
frew Schwern: but the default is different it seems
Schwern What replace doesn't isn't clear either
And there's no illustration of what @values does. 01:14
frew I thought replace was the statistical term for that
Schwern <-- not a statistician.
Or C programmer. Or Lisp programmer.
frew Schwern: heh
Schwern: svn.pugscode.org/pugs/t/spec/S32-list/pick.t <-- examples? 01:15
Schwern ok ~(@arr.pick(4)) eq 'z z z' implies you get different items 01:16
And @values are used to replace the items picked? 01:17
In order?
Apparently not 01:19
How do I go about correcting/clarifying this 01:20
sorear I don't understand what you mean by "@values are used to" 01:21
(1..6).pick(3) # never returns the same value twice 01:22
(1 xx 6).pick(3) # always returns 1 1 1
(1..6).pick(3, :replace) # can return the same value twice
Schwern Oh, I got confused by the fact that pick() appears to be both a method and a function
sorear (1..6).pick(*) # Shuffles the list
Schwern Which is... why is that? 01:23
sorear A lot of Perl 6 methods have function aliases which use the first argument as the invocant
push @foo, 1, 2, 3; is an alias for @foo.push(1, 2, 3)
01:23 redicaps joined
sorear same with pick 01:23
Schwern Except pick is backwards
our multi pick ( Int $num, Bool :$replace, *@values )
dalek meta: r355 | stefa...@cox.net++ | trunk/vicil/Kernel.cs:
[vicil] Many miscellaneous fixes.
01:24
Schwern And it seems silly to pollute the global namespace when you have methods.
sorear Rakudo's definition is that pick $num, $a, $b, $c = ($a, $b, $c).pick($num) 01:25
Schwern sorear: The function version of push appears to be missing from S32/Setting/Containers.
Unless "is export" handles that?
sorear don't trust anything you read in S32
ah
is export handles the non-reversed form 01:26
so S32 defines a function pick, but the wrong one
but that's ok; S32 isn't right about very much else
Schwern Joy
And "replace" is a weird name for "don't pick the same item twice" 01:27
sorear as the synopsis numbers increase, they become more fantastical and less wedded to implemented or thought
Schwern How can I bitch about this productively?
sorear replace means *allow* picking the same item twice
imagine a deck of cards.. if you pick two, you won't pick the same one twice
but if you pick one, replace it back in the deck, then pick another one, you could get two of the same 01:28
Schwern Sure. Its link to "replace" is a stretch.
I guess "pick one then REPLACE it in the deck"
Which is not what I'd think. I thought it was "pick one and replace it with something else"
sorear it's established statistics jargon. I can see adding allow-dup as a synonu,
synonym
Schwern That would be nice 01:29
Tene IME, that tends to be an evil road to go down.
sorear What?
Tene Having multiple completely-identical names for one thing.
Schwern Tene: Well, we're not all statisticians.
Or awk programmers. Or C programmers. Or <pick implied background knowledge here> 01:30
Tene Right, but nobody is actually expecting you to guess the API. There's always some learning curve to an API, and adding "You can call it by any of these N names" is going to make things more difficult. 01:31
If you see one name in one place and the other name in another place, you're going to assume they mean different things.
If you only know one name, and you search for all instances of it, you'll miss uses of the other name.
etc.
It increases the number of things to be learned, for (IMO) negligible benefit. 01:32
01:35 ashleydev left
frew so for protoregexen, is the <...> what the ..implemenetation? regexen slot into? 01:35
so I could do proto token foo { a<...> }; token foo:sym<a> { a }; token foo:sym<b> { b }; to mean aa | ab? 01:36
01:38 meppl left
Schwern Tene: In that case, one should pick the one that means something to the layman rather than the technical term. 01:38
01:39 plobsing joined, Ambiguity joined
Schwern Anyhow, how can I do something productive about this? 01:40
01:41 alester left 01:42 ruoso left
frew Schwern: well, obvious the top man to talk to would be TimToady 01:42
Schwern: there's also the Mailing list
Schwern: well, there's three mailing lists, I htink you want p6-lang 01:43
Schwern Ok, thanks. 01:44
sorear I'd start with TimToady 01:56
01:58 redicaps left 01:59 whiteknight left 02:16 felliott joined 02:22 ciphertext joined 02:23 agentzh joined 02:24 felliott left 02:30 felliott joined 02:34 patspam left 02:36 amk joined, amk left 02:37 songmaster joined 02:39 amkrankruleuen left 02:41 Guest99621 left 02:42 TiMBuS joined
dalek meta: r356 | stefa...@cox.net++ | trunk/vicil/Kernel.cs:
[vicil] Flesh out the concept of user-definable classes
02:43
02:55 prammer joined 03:03 masonkramer left 03:04 masonkramer joined 03:18 prammer left 03:32 felliott left 03:34 rv2733 joined
frew how do I make a regex that doesn't backreference at all? 03:42
sorear That word does not make sense in that context. 03:43
frew hehe
ok
so I have a grammar 03:44
tylercurtis frew: Do you mean, backtrack?
frew yes
I want to know if it matched
but not the value of the match
does that make sense?
sorear yes 03:45
the word you are looking for is "capture"
frew what words should I use next time, and how do I tell perl?
ah
ok
non-capturing regex
sorear well, there's no way to globally say "no captures here"
and I'm a little suspicious of your reason to want such a thing 03:46
frew fine, so inside the regex then I guase?
sorear captures are things you put into a regex; if you don't want them, don't use them
frew eh, no reason not to want it really, mostly I just don't need it
but sure, I'll defer to your judgement for now :-)
sorear then don't use () or <foo>
instead, use the non capturing forms [] and <.foo> 03:47
frew ok, I must be confused
when I print out the generated ast it has the values inside
ok
I get it
sorear print out the ast? you mean perl6 --target=past?
frew I'm actually using nqp
but yes
that
tylercurtis frew: can you give us an example of what's happening? 03:50
03:52 Guest3330 left 03:54 sftp joined
ash_ :ratchet in perl6 causes regex's to not backtrack 03:57
rule/token have :ratchet enabled
sorear but that's not important right now
ash_ sorry, backlogging 03:58
i should finish reading before commenting
03:59 sftp left
frew I'm just curious is all 04:12
it's a regex matvhinbg a single char, so I figure why capture it?
sorear what char 04:14
04:15 tedv left
frew 'd' ? 04:15
'x'
etc
it's a grammar for vi 04:17
so... 04:18
04:19 ash_ left 04:20 ash_ joined, ash_ left
sorear when you said "regex" I thought you were talking about / SOMETHING HERE ? 04:20
04:21 ash_ joined
sorear / 04:21
please explain what you were actually talking about
frew well 04:22
when I said grammar I thought that explained it
a grammar is a group of regexes right?
ash_ yeah
frew so...
that :-)
ash_ kinda how an object is a group of properties and methods (or just properties if you consider methods variables), a grammar is just regex's 04:23
frew right
so I have a TOP on it, ofc
and I pass it a string
(automatically, with the nqp compiler stuff) 04:24
and it parses to a tree
and I was wondering if I could just have the regexen say that they matched, and not specifically wat, since they can only match a single char anyway
sorear regexen never say what they match 04:26
04:26 rv2733 left
frew so tokens do? 04:26
sorear they only say where they match, and the .Str is created on demand
frew is using the token keyword
sorear um, tokens and regexes are exactly the same thing
frew sorear: note that I called them regexes, I was just clarifying :-) 04:27
paste.scsys.co.uk/45298 04:28
ash_ rakudo: say ?('a' ~~ /./), ' and ', ?('b' ~~ /a/); # like sorear said, they tell you if they matched 04:29
p6eval rakudo d18b5e: OUTPUT«1 and 0␤»
ash_ in nqp and perl6 you can add actions to your regex's too 04:31
if you want
frew that's step twpo 04:32
ash_ rakudo: 'a' ~~ /a { say 'got an a'; }/
p6eval rakudo d18b5e: OUTPUT«got an a␤»
ash_ 3dd is delete 3 lines in vi right? 04:33
frew ash_: yeah 04:34
sam as d3d
and d2j
my plan is to make a thing that can hook into vim and somehow set up an achievements system for vi
since that would be the funnest thing ever
obv the hard part is hooking in
like, there's no mechanism in vim to do it, and using a keylogger is gross for a million different reasons 04:35
04:36 lrnperl6 joined
ash_ you want vim to hook into vi? 04:36
i don't think i understood that correctly ><
04:40 araujo left, redicaps joined
frew heh 04:40
no, I just want to hook into vim
and somehow get EVERY command the user types
including hjlk etc 04:41
ash_ isn't there a command buffer?
frew so that I can make a game out of it; where if you use arrow keys or w/e you lose points
not that I could find
ash_ although that might not include moving the curious...
frew some guys in #vim are interested in adding the hooks for me 04:43
I figure I'l work on the parser for now, since it's fun and easy
04:43 plobsing left 04:45 lrnperl6 left
ash_ have you looked at the viminfo file? :help viminfo in vim 04:46
viminfo can store "- The input-line history." (which sounds similar to what you want) /shrug 04:47
ciphertext frew: potentially useful vim commands: 04:49
:noremap {lhs} {rhs} <-- override/define {lhs} to do {rhs}, without recursively looking up {rhs} for mappings; e.g. ":noremap j jj" would make typing 'j' move down two lines
:function
for instance: 04:50
:function Game_cmd(cmd) 04:55
: echo a:cmd # replace this with something that calls your script, e.g. :exe
:endf
:noremap j :call Game_cmd(j)<cr>j
* should be :call Game_cmd("j")<cr>j 04:56
04:57 ash_ left
frew zomg 04:59
ciphertext: the only problem there is that I'd need to remap every single thing to that thing somehow
but I'll look at that and viminfo both
ciphertext++, ash_++ # more helpful than #vim 05:00
05:06 araujo joined 05:17 Mowah joined
dalek meta: r357 | stefa...@cox.net++ | trunk/vicil/Kernel.cs:
[vicil] Turn Sub and ScalarContainer into ordinary classes in the P6 metamodel
05:26
sorear next, I'm going to start getting the compiler into shape 05:28
the vicil Kernel already supports lexical scope, full protolexpad semantics, binding, readonly binding, custom containers, resumable exceptions, and CATCH skipping 05:30
05:31 hercynium left
diakopter vicil: vicil: ++sorear; goto vicil; 05:36
tylercurtis Does the spec actually say anything in detail about $*ARGFILES? lines() defaults to it. It's the magic command-line input handle. It defaults to $*IN. Anything else at all? 05:38
sorear Like P5 unless notes 05:39
noted
see "I/O Operators" in perlop(1)
and the magic ARGV filehandle
note that some guy already posted an $*ARGFILES implementation to p6l or p6c 05:40
05:40 kaare joined 05:41 kaare is now known as Guest51225
tylercurtis sorear: mine's more feature complete(and I already had it mostly done by the time I saw that post). I just want to see if there's any other useful methods I should implement. 05:41
sorear: thanks for pointing me to perlop, by the way. 05:44
05:45 tylerni7 left 05:47 tylerni7 joined, Guest51225 is now known as kaare_
kaare_ I wrote about yesterday, blogs.perl.org/users/kaare/2010/06/...-code.html 05:49
05:52 justatheory left
sorear kaare_: that code there will be far more efficient than FakeDBI 05:55
what makes FakeDBI "fake" is that it doesn't actually connect to any databases. It forks a DB client shell 05:56
rcsheets oh hey i did that once with sybase, but by hand and in perl5. it was horrible.
diakopter interesting 05:57
kaare_ sorear: I hope to be able to work more on FakeDBI. But not sure. I have vacation starting Friday 05:58
rcsheets kaare_: the "ING" of RETURNING on your next-to-last line is cut off in my browser, if you care.
kaare_ rcsheets: It's the styling of blogs.perl.org, if you select it, it's there. 06:00
select it with the mouse, that is. 06:01
rcsheets yeah, i could tell it was there. didn't realize it was a site-wide problem. sorry.
kaare_ I just put a pair of <pre></pre> around. If I can do it better, it would be great. 06:02
rcsheets seems reasonable to me
kaare_ I know that cxreg has been working on a FakeDBD::Pg. I hope he will share his code. Perhaps we could work something out. 06:03
06:05 Su-Shee joined
cxreg kaare_: ive got some code, but it died on a missing thunk 06:35
because i was using PQsetdbLogin instead of PQconnectdb 06:36
needs some work to use PQconnectdb which has a simpler signature, but requires some finessing to get the connect string set up
im happy to push to github 06:37
06:37 redicaps left, eternaleye joined
tylercurtis cxreg: I think ash_'s libffi NCI work is coming along pretty well, so that might fix your problem whenever it gets merged into Parrot trunk. 06:38
kaare_ cxreg: Please do. Don't know if I can help, but it can't hurt.
06:39 jhuni joined
cxreg tylercurtis: that'd be nice 06:39
tylercurtis cxreg: I don't know for certain that it will(not sure exactly of the scope of it, but I'm pretty sure libffi has support for runtime generation of functions(which could be used to generate missing NCI thunks)), nor do I know that it will be merged soon, but it might and it might be. 06:41
cxreg looks like PQconnectdb is super easy anywa 06:42
im testing it now
06:43 literal left 06:45 eternaleye left 06:46 literal joined 06:49 eternaleye joined 06:50 JimmyZ joined 06:53 songmaster left
moritz_ oh, btw I have some untested DBD::Pg lying around here 07:02
from yesterday's train ride :-)
I'll paste it
maybe it's useful to somebody
nopaste.snit.ch/21655 07:03
hugme: add moritz to zavolaj 07:06
hugme moritz_: sorry, I don't know anything about project 'zavolaj'
07:07 foodoo joined 07:08 JimmyZ left 07:11 lkk- left
moritz_ phenny: tell mberends that currently 'use FakeDBI' requires NativeCall and libmysql even when the mysql fakedbd isn't loaded 07:14
phenny moritz_: I'll pass that on when mberends is around.
dukeleto what does Nil inherit from? 07:21
moritz_ Nil is an empty Parcel
rakudo: say Parcel.^parents
p6eval rakudo d18b5e: OUTPUT«Iterable()Cool()Any()Mu()␤»
moritz_ rakudo: say Nil.^parents
p6eval rakudo d18b5e: OUTPUT«Iterable()Cool()Any()Mu()␤»
sorear rakudo: say Nil.WHAT 07:22
p6eval rakudo d18b5e: OUTPUT«Parcel()␤»
dukeleto moritz++, sorear++ 07:24
dukeleto just made good progress on PL/Perl6 07:27
mathw Morning 07:28
dukeleto mathw: good $localtime 07:29
07:30 agentzh left 07:32 agentzh joined
kaare_ dukeleto: cool. 07:34
dukeleto kaare_: yes, after taking a break for a while, the problem I was having dissolved away, which is very nice indeed 07:36
07:41 azawawi joined
azawawi hi 07:41
sorear: ping
sorear Hello
Pong
azawawi wow
:)
realtime response
kaare_ dukeleto: What's the status / timeframe of the project? 07:42
07:42 Ross joined
kaare_ It's not connected to PL/Parrot, I suppose? 07:42
07:42 sorear sets mode: +vvv hugme ilogger2 buubot
dukeleto kaare_: it is part of PL/Parrot 07:42
azawawi sorear: I noticed that we have lib6 and syml. should these be in PERL6LIB? 07:43
sorear: as a result of make dist (STD.pm6)
dukeleto kaare_: it is in constant development. I would like to have a working PL/Perl6 when Rakudo* comes out. It works reasonably well as of tonight, it needs a bunch more tests and docs 07:44
sorear lib6 should be in PERL6LIB, but I don't think there's anything in it yet
oh
yes
07:44 mberends joined
sorear syml should get sent to whatever your tmp_prefix dir is 07:45
azawawi sorear: aha ok
sorear (yes, it's not a very temporary file. LTA.)
azawawi is updating S:H:P6
kaare_ dukeleto: Is it on github or anywhere else? 07:46
dukeleto kaare_: github.com/leto/plparrot 07:47
07:48 mjk joined
dukeleto kaare_: also check out pl.parrot.org 07:48
07:48 mj41 joined
mberends moritz_: good point. I wanted to avoid separate installs of DBI and DBDs for a while but this kind of issue might make it inevitable. 07:54
phenny mberends: 07:14Z <moritz_> tell mberends that currently 'use FakeDBI' requires NativeCall and libmysql even when the mysql fakedbd isn't loaded
kaare_ dukeleto: cool++
07:55 lkk- joined 08:01 lestrrat is now known as lest_away
kaare_ dukeleto: If you, or anyone else, has any control over parrot's Pg.pir (or rather the original), it would be nice to add an array and a hash return option for the result class. 08:02
dukeleto kaare_: are you using Pg.pir ?
moritz_ does
dukeleto can happily apply patches to Pg.pir, but hasn't worked on it directly 08:03
08:06 thebird joined
dukeleto Here is a gist of PL/Perl 6 in action: gist.github.com/456954 08:06
08:09 sftp joined
moritz_ wow, .finish on a Pg handle segfaults 08:13
dukeleto moritz_: feel free to open a TT for that, with a code snippet and backtrace, if you can
moritz_ dukeleto: I'm trying to reproduce in pure PIR first 08:14
08:17 eiro left 08:18 flw joined, flw left, mjk left
kaare_ dukeleto: Currently just for fun. Perhaps cxreg could use it for FakeDBD::Pg. 08:19
moritz_ dukeleto: trac.parrot.org/parrot/ticket/1695 08:23
dukeleto moritz++ # that is some epic fail 08:25
moritz_ it shows how many users the Pg library has :/ 08:26
08:28 rcsheets left
tylercurtis dukeleto, moritz_: glancing at Pg.pir(although my trunk checkout is a day or two old), .finish doesn't appear to check that the 'con' attribute is valid before calling the PQfinish function on it. 08:28
moritz_ tylercurtis: I've noticed that too, but I wasn't sure if that's the actual problem, or only a symptome of it 08:32
tylercurtis Probably at least an actual problem, if not the actual root problem in this case. 08:36
moritz_ tylercurtis++ # $*ARGFILES patch
08:39 agentzh left, lest_away is now known as lestrrat
tylercurtis moritz_: I'm not 100% sure the *patch* will work. When I did "patch argfiles.patch", it didn't seem to do anything for a very long time. I'm not sure if I was using patch correctly though. Nor if I was creating the patch correctly("git diff HEAD >argfiles.patch"?). But the code will work, as far as my testing indicates. I previously had a .getc method implemented, but it caused a parrot assertion failure when I tested it and I didn't feel like debuggin 08:40
that this late.
sorear the correct way to make a patch with git is git format-patch -1 08:43
08:44 Ross left, yinyin joined
tylercurtis On a very unrelated note, I'd love to get some eyeballs on a little project I've been working on this weekend: perlmonks.org/?viewmode=public;node_id=846756 it's basically a conversion of the paper "Notation as a Tool of Thought"(written in APL) to Perl 6, where possible(so far, the only lacks have been specifying the axis on which operations on multi-dimensional arrays work and built in mixed base arithmetic). Well, the beginning of a conversio 08:45
said paper. The repo with the source that generated it is linked there, as is the original paper.
sorear++, thanks. I'll send a proper patch then.
moritz_ tylercurtis: application works as 'patch -p1 < argfiles.patch' 08:48
patch reads from STDIN by default
tylercurtis moritz_: I've sent properly-created patches to the list now. But now I shall go to bed. Good night, folks. 08:54
moritz_ tylercurtis: too late, already pushed it :-)
sorear out 08:56
tylercurtis One last thing: I don't know how $*ARGFILES is an acceptable default argument for lines(since it "is" not IO), but it works.
dalek kudo: 68852e4 | tcurtis++ | (5 files):
Implement $*ARGFILES, and make it the default handle for lines()
08:57
meta: r358 | stefa...@cox.net++ | trunk/vicil/Compiler.pm:
[vicil] Start prototyping the Perl code generator
08:58
08:58 lkk- left 09:03 tylercurtis left
dukeleto perl6: my $r = sub { @_[0].WHAT }; $r.() 09:06
p6eval pugs, rakudo d18b5e: ( no output )
..elf 31494: OUTPUT«Global symbol "$a__" requires explicit package name at (eval 123) line 5.␤ at ./elf_h line 5881␤»
dukeleto perl6: my $r = sub { say @_[0].WHAT }; $r.() 09:08
p6eval pugs: OUTPUT«Scalar␤»
..rakudo d18b5e: OUTPUT«Proxy()␤»
..elf 31494: OUTPUT«Global symbol "$a__" requires explicit package name at (eval 124) line 5.␤ at ./elf_h line 5881␤»
pugssvn r31495 | moritz++ | [evalbot] remove elf from perl6: target
dukeleto who is right? should it be a Scalar or a Proxy or neither? 09:09
09:09 timbunce joined
dukeleto timbunce: howdy! 09:10
timbunce dukeleto: howdy! 09:11
dukeleto timbunce: i just got the basics of PL/Perl 6 working. it can return ints/floats and strings back to Postgres
rgrau rakudo: <keep it simple stupid>.map: {/^./}
p6eval rakudo d18b5e: ( no output )
timbunce dukeleto: great!
dukeleto timbunce: still figuring out how to data marshall from Rakudo to PG
rgrau rakudo: (<keep it simple stupid>.map: {/^./}).say 09:12
p6eval rakudo d18b5e: OUTPUT«_block59_block59_block59_block59␤»
timbunce dukeleto: worth spending time to get that right.
dukeleto timbunce: yes, and getting things right is usually correlated to having slept ;) 09:13
dukeleto should do some of that
09:13 masak joined
masak oh hai, #perl6! 09:13
arnsholt It's you! 09:14
dukeleto masak: hai and bai :)
masak 百百
rgrau Am I doing something wrong here? 09:18
rakudo: say <keep it simple stupid>.map: {/^./}
p6eval rakudo d18b5e: OUTPUT«_block59_block59_block59_block59␤»
mathw oh hai masak 09:19
masak rakudo: say <keep it simple stupid>.map: {$_ ~~ /^./} 09:20
p6eval rakudo d18b5e: OUTPUT«kiss␤»
rgrau yay! thanks masak
masak bows
moritz_ is there a #phasers today? 09:23
09:23 azert0x joined
masak guesses so 09:23
I can't make it today. :/
moritz_ I'm not sure if I can 09:24
azawawi sorear: ping
moritz_ 10:56 * sorear out
that was half an hour ago
azawawi moritz_: so the old lex/ directory is now pre-compiled into a pmc file, right?
moritz_ azawawi: I have no idea 09:25
azawawi moritz_: thx 09:26
09:35 synth left 09:39 Sarten-X left
timbunce dukeleto: you're probably aware of this prior art, but just in case python.projects.postgresql.org/pldo...thon3.html 09:42
masak moritz_: your physical-modeling blog post was mentioned in a Japanese tweet: twitter.com/1VQ9/status/17293317782 09:44
moritz_ masak: \o/ and thanks for letting me know. 09:45
rakudo: say (-5 ... ^5).perl 09:47
p6eval rakudo d18b5e: OUTPUT«((-5, -4, -3, -2, -1, 0), [1, 2, 3, 4])␤»
IllvilJa o/
masak IllvilJa: \o
moritz_ rakudo: say (^5).perl
p6eval rakudo d18b5e: OUTPUT«0..^5␤»
moritz_ rakudo: say (^5).list.perl
p6eval rakudo d18b5e: OUTPUT«(0, 1, 2, 3, 4)␤»
moritz_ rakudo: say (-5 ... ^5).flat.perl
p6eval rakudo d18b5e: OUTPUT«(-5, -4, -3, -2, -1, 0, 1, 2, 3, 4)␤»
IllvilJa how's things going in the land of perl6? 09:48
moritz_ quite well, I'd say
we now have $*ARGFILES, which is the same as the magic empty file handles known from Perl 5: while (<>) { ... } 09:49
IllvilJa cool!
moritz_ is now in Perl 6: for lines() -> $l { ... }
IllvilJa I've had too little time to "play around" with programming for the last few months... so I've lost track of what's happening with Perl 6.
moritz_ last month? 09:50
oh, then there's more news :-)
IllvilJa I can imagine :-)
moritz_ rakudo has proper lazy lists and arrays
rakudo: my @a = 1 ... *; ;say @a[5];
IllvilJa \o/
moritz_ prais it acutally works :-)
p6eval rakudo d18b5e: ( no output )
cono :D
moritz_ rakudo: my @a = 1 .. *; ;say @a[5];
p6eval rakudo d18b5e: ( no output )
moritz_ it works locally heere 09:51
IllvilJa did a 'git pull' for rakudo recently and quite a LOT of code were altered, so I expected quite some progress.
moritz_ seems p6eval is too oold
cono rakudo: my $a = 1 ... *; say $a[5];
masak rakudo: say (1..*)[5]
p6eval rakudo d18b5e: OUTPUT«Method 'postcircumfix:<[ ]>' not found for invocant of class 'Int'␤ in main program body at line 1␤»
rakudo d18b5e: OUTPUT«6␤»
hejki cono: hehe. perl5 just owned you ;>
cono rakudo: my $a = 1 .. *; say $a[5]; 09:52
p6eval rakudo d18b5e: OUTPUT«6␤»
cono hejki: p6 works too :p
moritz_ anyway, the array version works locally here 09:53
other news: we have proper MAIN subs
09:54 zakame left, zakame joined
hejki whot :O 09:54
09:55 azawawi left
pugssvn r31496 | moritz++ | [t/spec] test for RT #75698, -5 ... ^5 should contain only one 0 09:57
r31497 | moritz++ | [t/spec] test for RT #75950, my ($x) = grep $early_hit, @long_range 10:01
masak std: / <?> / 10:03
p6eval std 31495: OUTPUT«ok 00:01 111m␤»
moritz_ masak: ha, rt.perl.org/rt3/Ticket/Display.html?id=75950 10:05
masak moritz_: what about it? :)
moritz_ masak: your bug was more persistent than pmichaud++ thought :-) 10:07
masak so it would seem :) 10:10
10:10 lestrrat is now known as lest_away
masak wonder why it matters whether the declaration is there or not. 10:11
10:12 pragma_ is now known as pragma|t 10:14 pragma|t is now known as pragma_, pragma_ is now known as pragma|t
bbkr rakudo: my $i = 0; $i++ for \[1,2,3]; say $i; # is it the right output? 10:16
p6eval rakudo 68852e: OUTPUT«1␤»
bbkr rakudo: (\[1,2,3]).WHAT.say # "for" should iterate over it 3 times? 10:18
p6eval rakudo 68852e: OUTPUT«Capture()␤»
10:18 pragma|t is now known as pragma_ 10:19 pragma_ is now known as pragma|t 10:21 pragma|t is now known as pragma_
masak bbkr: no, I think one iteration is right there. the prefix:<\> probably puts it in item context. 10:23
bbkr masak: cool, then rt.perl.org/rt3/Ticket/Display.html?id=73400 can be closed after tests 10:24
rakudo: my $i = 0; $i++ for [1,2,3]; say $i; # how about this one? looks correct, shouldn't flatten IMO, right? 10:25
p6eval rakudo 68852e: OUTPUT«1␤»
moritz_ that's correct 10:28
pugssvn r31498 | moritz++ | [t/spec] test for RT #75794 - take() with multiple arguments
moritz_ should only flatten with .flat or @([1, 2, 3])
bbkr moritz_: thanks, then rt.perl.org/rt3/Ticket/Display.html?id=73398 can also be closed. i'll add tests to both today. 10:29
moritz_ bbkr: do you have an RT account? 10:30
bbkr ofc
moritz_ what's your nick there?
bbkr bbkr
masak 'for [1, 2, 3]' doesn't flatten, but 'for @a' flattens even when @a eqv [1, 2, 3] 10:31
moritz_ phenny: tell pmichaud to please give 'bbkr' (same RT nick) privileges for the perl6 RT queue. Thanks!
phenny moritz_: I'll pass that on when pmichaud is around.
moritz_ bbkr: you can soon close the tickets yourself :-)
moritz_ likes to delegate work
bbkr moritz_: I already have priviledges for RT and I'm closing tickets :) 10:32
privileges*
moritz_ oh 10:33
sorry, I mis-interprted what you said
I thought you didnt' have privs, which is why you wanted me to close them 10:34
phenny: tell pmichaud never mind, has already happened
phenny moritz_: I'll pass that on when pmichaud is around.
bbkr moritz_: no problem :) I've checked 50% RT queue on Kiev build, will finish all by the end of the week. 10:38
moritz_ bbkr++ # going wild on RT queue
it would be kinda cool to have a 'I've checked this ticket, still fails' button 10:39
which would then store a timestamp
and then one could generate a report ordered by last-checked-date 10:40
bbkr moritz_: indeed, good idea. 10:41
arnsholt An approximation of that might be to sort by timestamp of last comment? 10:43
moritz_ yes, but people don't comment with "nothing changed" 10:45
too much effort
10:46 lrnperl6 joined
moritz_ anywy, it feels good not to be the only one working on tests for RT tickets 10:46
lrnperl6 hi moritz_ 10:47
moritz_ hi lrnperl6 10:50
10:51 azert0x left
lrnperl6 I was browsing ruby-lang.org other day and found this: www.ruby-lang.org/en/documentation/...languages/ 10:55
10:55 eiro_ joined
lrnperl6 i think it will a good 5 mins introduction to perl6 10:55
masak tylercurtis++ # perlmonks.org/?viewmode=public;node_id=846756 10:56
moritz_ lrnperl6: having something like that for Perl 6 would be really great 10:57
lrnperl6 masak: Anonymous users can't see the scratchpads, sorry 10:58
moritz_: trouble is I don't know perl6 to contribute there 10:59
bbkr t/spec/S03-operators/series.t goes into infinite loop somewhere. how can i execute it with --fudge and see output for separate tests to find the faulty one?
11:00 charsbar left, charsbar_ joined
moritz_ lrnperl6: then learn first, and contribute then :-) 11:00
lrnperl6 moritz_: that's the plan :) 11:01
moritz_ bbkr: when I run fudge, I usually just kill processes running too long
jnthn hi all
moritz_ erm
wait
jnthn I may not be able to make #phasers today - sorry
(Got work evening out.) 11:02
masak jnthn! \o/
moritz_ bbkr: sorry, was confused, ignore me
jnthn s/may/likely/
masak! \O/
moritz_ bbkr: if you run the .rakudo file, you see the last successful test
jnthn I'd pre-post a report but I didn't do a lot this last week. :-/ 11:03
Vacation and all that.
ooh, I probably need to pay attention to work meeting again now :-)
masak jnthn: use.perl.org/~masak/journal/40422
bbkr moritz_: this test doesn't have .rakudo version in Pugs repo, can this be auto-generated somehow?
masak (my last GSoC status report)
moritz_ bbkr: when you run 'make t/spec/S03-operators/series.t' a .rakudo file is generated 11:04
at least if there's a fudge directive in the file
it is, in this case
jnthn masak: I readed it last night I think
masak oki :)
jnthn You had to synch with me 11:05
But can't do that right now :-)
masak that's ok. :)
we'll meet up Friday at the latest :)
jnthn Yes, exactly.
masak \o/
jnthn Yay...hackathon med masak!
masak yay
bbkr moritz_: found it, thanks! 11:06
masak хакмит с jnthn! :)
jnthn \o/ 11:08
bbkr rakudo: (1, 2 ... 0)
jnthn afk, work
p6eval rakudo 68852e: ( no output )
moritz_ rakudo: say (1, 2 ... 0)
11:08 lrnperl6 left
p6eval rakudo 68852e: 11:09
..OUTPUT«123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130…
11:10 mjk joined
bbkr rakudo: use Test; is (1, 2 ... 0), Nil; # this one is already reported? 11:10
p6eval rakudo 68852e: ( no output )
11:12 yinyin left
masak thinks it's already reported 11:12
bbkr masak: thanks, i'll find this ticket and fudge those tests in series.t to make it usable again. 11:14
masak ++bbkr
11:14 lest_away is now known as lestrrat
moritz_ btw, this week's contribution was a huge success again 11:15
I posted it before going to bed
and when I woke up, I had two high-quality submissions 11:16
dalek kudo: 6f66e96 | moritz++ | src/core/IO.pm:
$*ARGFILES as default for get()
kudo: 871e2fb | moritz++ | src/core/IO/ArgFiles.pm:
IO::ArgFiles is IO
kudo: 1576d48 | moritz++ | tools/ (2 files):
[autounfudge] run perl6 process with time and memory limit; evil, unix-only hack
moritz_ one of them is in rakudo already
masak moritz_: clearly those challenges help fill a void of some kind.
it's heartening to know that not only is there that kind of support from non-core people, it's even strong enough that people jump at helping when they get the chance. 11:17
moritz_ so we need to try to activate this potential as good as possible 11:18
masak I wonder what's the biggest driving force; the promise of a t-shirt, or the chance to contribute? 11:19
moritz_ this week came without the promise of t-shirts 11:20
Su-Shee masak: telling people something concrete, tangible to do instead of leaving it to them "well contribute something, if you like.."
masak Su-Shee: aye, point.
Su-Shee masak: you can easily decide "oh, yes, I can do _that_" (and it's specifically ask for, so you don't add feature blindfolded.) 11:21
11:21 azert0x joined
masak indeed. 11:21
lunch &
moritz_ I found that hard to do
because it looks like it goes contrary to the "do what you want, have fun" paradigm 11:22
and the general truth that you can't tell volunteers what to do
fact is, you can. Within limits. 11:23
mathw depends on the type of volunteer
but it's good to present to people a project they can do
arnsholt Depends on how you tell them too
Su-Shee actually in my experience it's totally wrong that you can't volunteers tell what to do.. also, there plenty of possiblities _how_ to tell..
moritz_ arnsholt: that too
11:24 azert0x left
arnsholt This initiative of "Wanna help? Try starting here!" is awesome 11:24
11:24 azert0x joined
Su-Shee some do well with "I do what I like and think is good for the project". Other like to pick from a list of items and do those. other like concrete tasks where they feel they do something needed and useful. 11:24
arnsholt One of the hardest things when trying to contribute to a large projects is figuring out what to do and where to start 11:25
Su-Shee exactly.
and telling people how they should write their code and refactor this or that is also a pretty massive "telling volunteers what to do". even IF someone codes what he wants, he usally gets reviewed by peers and has to stay within the project's code culture. (some are anal, others are more liberal..) 11:27
moritz_ rakudo: 'blah foo blah' ~~ / foo { make 'bar' } /; say ?$/ 11:28
p6eval rakudo 68852e: OUTPUT«1␤»
11:29 azert0x left 11:30 mjk left, mjk joined 11:31 azert0x joined 11:33 timbunce left 11:36 Chillance joined 11:44 eiro_ is now known as eiro 11:52 timbunce joined 11:56 daxim joined
daxim I managed to crash rakudo: stackoverflow.com/questions/3135673#3136410 11:58
takadonet morning all 12:00
12:01 mjk left, mjk joined 12:03 envi^home joined 12:07 felliott joined 12:10 ruoso joined
masak takadonet: \o 12:10
takadonet masak: how are you? 12:12
masak takadonet: a bit too busy, but otherwise very good. and you?
takadonet masak: about the same
masak daxim: huh? where does the 'Divide by zero' come from? you're not doing any divisions in the script... 12:13
pugssvn r31499 | bbkr++ | t[t/spec] tests for RT #75832 fudged tests that cause infinite loops because of lack of stop at wrong end point in series 12:14
daxim masak, paste.scsys.co.uk/45302 12:15
masak daxim: I try and reproduce it here. the script outputs nothing for me. it doesn't give an error. 12:16
daxim: the gdb output unfortunately doesn't tell me much. maybe it'll tell someone else on the channel more. or someone on #parrot. 12:17
daxim it used to work 1½ years ago
masak it looks like it should work.
pugssvn r31500 | bbkr++ | t[t/spec] tests for RT #75316 1...1..0 keeps Rakudo on 100% CPU usage 12:23
12:30 skids joined
pugssvn r31501 | bbkr++ | [t/spec] tests for RT #73508 Rakudo doesnt print anything on "say (1,2,4...*)[10]" 12:30
masak moritz_: I pasted your starry obfu at perlgeek.de/blog-en/perl-6/starry-obfu.html into a file and did 'perl6 obfu'. it prints nothing. :/ 12:34
oh wait. it uses the old * semantics... 12:35
maybe add a little comment about that, anyway.
12:39 mjk left
pugssvn r31502 | bbkr++ | [t/spec] tests for RT #72914 Rakudo doesnt treat ^$n at the end of an infix:<...> 12:41
moritz_ masak: yep, it also assumes that ** isn't a term (it's HyperWhatever by current spec) 12:44
12:48 proller left 12:49 proller joined
jnthn oh heh 12:50
that backtrace looks like it crashes while trying to produce a backtrace or something
12:51 masonkramer left 12:52 rv2733 joined
pugssvn r31503 | bbkr++ | [t/spec] tests for RT #73400 Cannot loop over Capture object in Rakudo 12:54
12:54 proller left 12:57 bluescreen joined, masonkramer joined, bluescreen is now known as Guest7877
dalek kudo: adf0342 | moritz++ | t (2 files):
run more test files
12:58
13:00 proller joined 13:04 kaare_ left
moritz_ urks 13:05
68852e4e7b0fa5c7845540ad261c14c449d9667b broke main-usage.t 13:06
13:11 rgrau_ joined 13:15 timbunce left 13:16 macdaddy joined, macdaddy is now known as Guest64221 13:18 mmcleric joined
pmichaud good morning, #perl6 13:19
phenny pmichaud: 10:31Z <moritz_> tell pmichaud to please give 'bbkr' (same RT nick) privileges for the perl6 RT queue. Thanks!
pmichaud: 10:34Z <moritz_> tell pmichaud never mind, has already happened
moritz_ good morning pmichaud
masak morning, pm! 13:20
daxim sent pull request to github user rakudo for github.com/daxim/rakudo/commit/1fea...3402e8e431
13:20 timbunce joined
colomon o/ 13:22
moritz_ daxim: I'll cherry-pick it if nobody else beats me to it (currently working on some other mess, have to wait until my working tree is clean again) 13:23
pmichaud daxim: applied, thanks! 13:25
daxim that went quick
cono moritz_: git stash :)
moritz_ cono: I know about it, but it still means I have to get back to that commit I was working on (which isn't a branch right now...) 13:26
daxim git stash pop does that
moritz_ it does? cool, didn't know that
daxim what good is stashing without unstashing?
moritz_ I knew it applied the patch 13:27
which is already helpful
but that alone doesn't restore my position in the commit tree
dalek kudo: f008ccd | (Lars Dɪᴇᴄᴋᴏᴡ 迪拉斯)++ | Configure.pl:
clarify --parrot-config
pmichaud ....looking at the series code makes me cringe. 13:28
masak that's not a good sign.
std: / $<foo> = [ foo ] /
p6eval std 31503: OUTPUT«ok 00:01 113m␤»
masak std: / $<foo><bar> = [ foo ] / 13:29
p6eval std 31503: OUTPUT«ok 00:01 110m␤»
masak rakudo: "foo" ~~ / $<foo><bar> = [ foo ] /; say $<foo><bar>
p6eval rakudo 1576d4: OUTPUT«===SORRY!===␤Confused at line 11, near "\"foo\" ~~ /"␤»
pmichaud rakudo doesn't know how to do captures like that yet 13:30
masak but it's spec'd?
pmichaud I suspect it is.
masak ok.
moritz_ don't think it's specced for the nested case
masak submits rakudobug 13:31
moritz_: STD parses it, at least.
ciphertext pmichaud: colomon and i were working on series this weekend. I sent him a final update: nopaste.snit.ch/21663 but I don't think he ever saw it...
masak so it's some sort of spec.
pmichaud ciphertext: yes, I'm looking at the commits in the fork queue on github 13:32
it looks to me as though the implementation is doing *way* too much special-case consideration
13:33 mjk joined
ciphertext what do you mean? 13:34
pmichaud shouldn't need to do all of that testing for numeric versus string
a variety of other things
bbkr rt.perl.org/rt3/Ticket/Display.html?id=73162 - in which file should I put test for that? 13:36
moritz_ takes a look 13:37
bbkr rakudo: my @a=0..*; @a[Inf]=3; say @a[Inf];
moritz_ bbkr: S02-builtin_data_types/whatever.t
bbkr moritz_: thanks 13:38
p6eval rakudo 1576d4: ( no output )
moritz_ bbkr: because the * in there is a Whatever star
13:38 felliott left
pmichaud part of me really wishes that S02-builtin_data_types/ was S02-builtin-data-types/ or S02-builtin-types/ or S02-types/ :-) 13:38
moritz_ pmichaud: can be done in a few minutes 13:39
[particle] death to underscore!
moritz_ bbkr: if you find tickets where the problem is gone, but you don't know how to test, feel free to assign them to me
(or ask here, of course)
bbkr moritz++ 13:41
moritz_ pmichaud: btw did you look at my commits to the 'star' repo? 13:44
bbkr rakudo: WhateverCode; 13:45
p6eval rakudo 1576d4: ( no output )
pmichaud moritz_: not yet, will do that today.
moritz_ it's not much yet, so far only the code to download stuff into a dist/ dir
I kinda don't like the idea of keeping a copy of everything
bbkr rakudo: $x = *-1; $x ~~ WhateverCode;
p6eval rakudo 1576d4: OUTPUT«===SORRY!===␤Symbol '$x' not predeclared in <anonymous> (/tmp/SQLsnq0aJJ:11)␤»
bbkr rakudo: my $x = *-1; $x ~~ WhateverCode; 13:46
13:46 felliott joined
p6eval rakudo 1576d4: ( no output ) 13:46
moritz_ rakudo: my $x = *-1; say $x ~~ WhateverCode
p6eval rakudo 1576d4: OUTPUT«1␤»
13:46 synth joined 13:47 synth_ joined
moritz_ keeping a copy checked into the repo, that is 13:47
13:47 synth_ left
bbkr rakudo: use Test; my $x = *-1; isa_ok $x, WhateverCode; 13:47
p6eval rakudo 1576d4: OUTPUT«ok 1 - The object is-a 'WhateverCode()'␤»
bbkr weird, i get "Could not find sub &WhateverCode" while running S02-builtin_data_types/whatever.t on this test 13:49
moritz_ pmichaud: don't know how much backlog (or p6c reading) you have done, but we have two submission for the $*ARGFILES implementation already, and one of them is in rakudo already
bbkr: your rakudo is too old :-)
pmichaud moritz_: Win!
moritz_ pmichaud: indeed
pmichaud moritz_: haven't backlogged yet
I'm looking at &infix:<...> to see if it bugs me enough to refactor :)
13:51 felliott left
pmichaud $is-geometric-switching-sign = Bool::True if (@lhs[*-2] * @lhs[*-1] < 0); 13:52
argggggggh
:-) 13:53
masak wtf
pmichaud oh, maybe not. Still, weird. 13:54
moritz_ what's wrong with it?
masak parens.
doesn't use ||= :)
dalek kudo: 4e69c43 | moritz++ | src/core/IO/ArgFiles.pm:
avoid modifying @*ARGS in setting up $*ARGFILES; unbreaks USAGE subs
moritz_ I mean, it can probably be simplified to is-geometric-switching-sign = (@lhs[*-2] * @lhs[*-1] < 0); # or with ||=, depending on context
pmichaud it's not part of a loop, so one could s/Bool::True if//
masak right. 13:55
hejki ||= works same as in perl5?
masak hejki: sure.
hejki aww <3
masak on the REPL, when I write 'role R {}', it prints 'R()'. but when I do 'class C {}', it prints '!class_init_36'. I'm guessing there's a metamodel explanation for that, but it feels Less Than Pretty. 13:57
pmichaud I'm guessing the class code is returning the closure instead of the class. That's likely a bug. 13:58
moritz_ rakudo: my $x = class C { }; say $x.WHAT
p6eval rakudo 1576d4: OUTPUT«Code()␤»
moritz_ there you go
pmichaud yes, exactly.
moritz_ same bug without REPL
masak submits rakudobug
14:00 mjk left
masak you guys have been fixing bugs so fast lately, I almost can't keep up! :) 14:00
pmichaud masak: isn't that the point? ;-) 14:01
moritz_ masak: hey, cognominal is helping you, don't complain :-)
masak :)
we're down to 634 new/open tickets in RT. 14:02
cognominal I am seeing XCode 4, now we need tools!! 14:03
bbkr on HEAD Rakudo build why I run from rakudo dir "perl t/harness --fudge --keep-exit-code --icu=0 --jobs some_test_file.t" I get Can't open perl script "t/spec/fudgeall" error, something has changed here?
moritz_ bbkr: did you run 'make spectest' or 'make testable'? 14:04
bbkr moritz_: "make test", trying "make spectest" right now 14:05
cognominal C ObjC, OObjC (appaenently some even more OO ObjC), C++ suck but XCode 4 is the first IDE I ever wanted to try. No available yet. But the demos (need a Apple Developer account to see them) are great.
moritz_ bbkr: 'make spectest' or 'make testable' will download the pugs repo for you 14:06
bbkr moritz_: thanks, works now. few tickets more will bite the dust :)
moritz_ without it, no t/spec/$anything exists
cognominal Maybe some guy will be able to adapt LLVM for Perl 6 because Apple built an impressive toolchain around it.
moritz_ cognominal: there are plans to use the LLVM for JIT-compiling parrot 14:07
cognominal that's great, but JIT is only a late stage. 14:09
moritz_ cognominal: and I think one GSOC project prepares configuring stages for parrot already
and you can already compile parrot with clang
cognominal lines 80-85 of src/core/Signature.pm seems very suspicious to me 14:12
moritz_, parrot with clang? that's great
moritz_ these lines are for paramter renaming 14:13
cognominal If many named parameters, that can't work
moritz_ rakudo: say :(:a(:b($c))).perl
p6eval rakudo 1576d4: OUTPUT«:(Mu :b(:a($c)))␤»
masak nice. 14:14
pugssvn r31504 | bbkr++ | [t/spec] tests for RT #73162 Rakudo cant parse "{*.{}}()" (but STD.pm can)
moritz_ nothin' wrong with it
cognominal hum, apparently I need to thing harder.
mathw cognominal: there has been talk of an implementation using viv and LLVM. Just talk, as far as I'm aware, though.
moritz_ mberends++ started vill, which compiled to LLVM 14:15
bbkr rakudo: say 0xFFFFFFFFFFFFFFFF
p6eval rakudo 1576d4: OUTPUT«-1␤»
moritz_ but afaict it's pretty much stalled, due to different priorities
cognominal ho, I missed the x +@names, I still think in term of loops. Silly me.
bbkr rakudo: sub foo() { try { return 42 }; return 5 }; say fo 14:16
p6eval rakudo 1576d4: OUTPUT«Could not find sub &fo␤ in main program body at line 11:/tmp/P5HiPgGrY9␤»
moritz_ cognominal: it took me a third look to find them too 14:17
bbkr rakudo: sub foo() { try { return 42 }; return 5 }; say foo
p6eval rakudo 1576d4: OUTPUT«5␤»
hejki :O
arnsholt hejki: return (and some other things) is actually throwing a control-flow exception 14:18
masak still, that's wrong.
(and known)
arnsholt True, true 14:19
14:19 Guest64221 left
bbkr rakudo: sub foo($v, $w?, $x?, $y?){ say $v~"|"~$w~"|"~$x~"|"~$y}; 14:23
p6eval rakudo 1576d4: ( no output )
bbkr rakudo: sub foo($v, $w?, $x?, $y?){ say $v~"|"~$w~"|"~$x~"|"~$y}; foo(1,,3,);
p6eval rakudo 1576d4: OUTPUT«1|3|Any()|Any()␤»
masak std: sub foo($v, $w?, $x?, $y?){ say $v~"|"~$w~"|"~$x~"|"~$y}; foo(1,,3,); 14:24
p6eval std 31503: OUTPUT«===SORRY!===␤Preceding context expects a term, but found infix , instead at /tmp/5ifHYwLneY line 1:␤------> ?){ say $v~"|"~$w~"|"~$x~"|"~$y}; foo(1,⏏,3,);␤Parse failed␤FAILED 00:01 116m␤»
moritz_ ,, should parsefail
14:25 shade_ is now known as shade\
bbkr i know, not fixed yet... 14:31
rakudo: my @b= 5, 1, 2; if(@b>2) {say 'yes';}
p6eval rakudo 1576d4: OUTPUT«yes␤»
masak right. should fail because &if hasn't been declared.
14:31 mmcleric left, mmcleric joined
masak ...and two terms in a row :) 14:31
bbkr rakudo: say all(42) ~~ Int 14:33
p6eval rakudo 1576d4: OUTPUT«0␤»
14:34 gbacon joined
bbkr rakudo: multi f(Num $x) { say "Num" }; multi f(Int $x) { callsame; say "Int" }; f(42) 14:36
p6eval rakudo 1576d4: OUTPUT«Null PMC access in clone()␤ in 'f' at line 1␤ in main program body at line 11:/tmp/7rgKi5UAy1␤»
masak rakudo: .say for grep { $_ % all 2..$_/2 }, 2..* 14:37
p6eval rakudo 1576d4: OUTPUT«2␤3␤5␤7␤11␤13␤17␤19␤23␤29␤31␤37␤41␤43␤47␤53␤»
masak \o/ 14:38
14:38 JimmyZ joined
pmichaud $_/2 could be .sqrt 14:39
bbkr rakudo: 1.0.WHAT.say # this should be Num or Rat according to the Spec?
p6eval rakudo 1576d4: OUTPUT«Rat()␤»
pmichaud bbkr: Rat.
bbkr pmichaud: thanks, then tests in rt.perl.org/rt3/Ticket/Display.html?id=69869 are no longer valid... fixing...
masak rakudo: .say for grep { $_ % all 2.. .sqrt }, 2..*
p6eval rakudo 1576d4: OUTPUT«2␤3␤5␤7␤11␤13␤17␤19␤23␤29␤31␤37␤41␤43␤47␤53␤59␤61␤67␤71␤73␤79␤83␤89␤97␤101␤103␤107␤109␤113␤127␤131␤137␤139␤149␤151␤157␤163␤167␤173␤179␤181␤» 14:40
masak that got us a bit further. pmichaud++
can probably be sped up even more by breaking ASAP.
rakudo: .say for grep { my $p = 1; for 2.. .sqrt -> $d { if $_ %% $d { $p = 0; last } }; $p }, 2..* 14:43
p6eval rakudo 1576d4: OUTPUT«2␤3␤5␤7␤11␤13␤17␤19␤23␤29␤31␤37␤41␤43␤47␤53␤59␤61␤67␤71␤73␤79␤83␤89␤97␤101␤103␤107␤109␤113␤127␤131␤137␤139␤149␤151␤157␤163␤167␤173␤179␤181␤191␤193␤197␤199␤211␤»
masak rakudo: .say for grep { my $p = 1; for 2, (3, 5 ... .sqrt) -> $d { if $_ %% $d { $p = 0; last } }; $p }, 2..*
p6eval rakudo 1576d4: OUTPUT«3␤5␤7␤29␤31␤37␤41␤43␤47␤53␤59␤61␤67␤71␤73␤79␤83␤89␤97␤101␤103␤107␤109␤113␤127␤131␤137␤139␤149␤151␤157␤163␤167␤173␤179␤181␤191␤193␤197␤199␤211␤223␤227␤229␤233␤239␤241␤251␤257␤263␤269␤271␤»
masak :)
might be slightly faster if one doesn't use grep and infix:<...> and all that, but that's enough micro-optimisation for now. 14:44
bbkr rakudo: "".subst(/x/, "").trans()
p6eval rakudo 1576d4: ( no output ) 14:45
14:45 molaf joined, timbunce_ joined 14:46 redicaps joined
JimmyZ rakudo: .say for grep { my $p = 1; for 1,(2, 3, 5 ... .sqrt) -> $d { if $_ %% $d { $p = 0; last } }; $p }, 2..* 14:47
14:47 timbunce left, timbunce_ is now known as timbunce
p6eval rakudo 4e69c4: OUTPUT«===SORRY!===␤Unable to parse blockoid, couldn't find final '}' at line 11␤» 14:47
JimmyZ wrong channel
14:48 Gruber is now known as Grrrr
masak JimmyZ: don't put the 1 there. it makes the %% condition rather superfluous. 14:49
JimmyZ rakudo: .say for grep { my $p = 1; for 2, (3, 5 ... .sqrt) -> $d { if $_ %% $d { $p = 0; last } }; $p }, 2..*
p6eval rakudo 4e69c4: OUTPUT«===SORRY!===␤Unable to parse blockoid, couldn't find final '}' at line 11␤»
JimmyZ doesn't work for me ? 14:50
masak missing one }, I think.
grap/for/if. three }s
oh wait.
rakudo: .say for grep { my $p = 1; for 2, (3, 5 ... .sqrt) -> $d { if $_ %% $d { $p = 0; last } }; $p }, 2..* 14:51
p6eval rakudo 4e69c4: OUTPUT«===SORRY!===␤Unable to parse blockoid, couldn't find final '}' at line 11␤»
JimmyZ I copy your code
masak I pressed 'up' in the IRC history.
something just broke.
14:54 rv2733 left, felliott joined
bbkr rakudo: class PrivateDemo { method !private($str) {say "you takling to me?"}; }; PrivateDemo.new()!private("abc"); 14:57
p6eval rakudo 4e69c4: OUTPUT«you takling to me?␤»
bbkr std: class PrivateDemo { method !private($str) {say "you takling to me?"}; }; PrivateDemo.new()!private("abc");
p6eval std 31504: OUTPUT«ok 00:01 114m␤»
bbkr this should not parsefail?!?!
masak bbkr: no, why? 14:58
where's the syntactic error? 14:59
the *syntactic* error. :)
bbkr masak: private method should be seen outside class scope?
masak I guess they could, if a class trusted another class. 15:00
15:01 am0c joined, pmurias joined
masak I'm so used to things having to do with methods being late-bound, that I don't think it's odd at all that the above parses. 15:01
15:02 mberends left
bbkr masak: then what is the difference between public and private method then, if both can be called on object instance from outside this object? 15:02
masak *syntactic*.
is this on? 15:03
arnsholt The Rakudo behaviour is still wrong, though, isn't it?
masak oh yes. 15:04
arnsholt Then we're in perfect agreement =)
bbkr masak: thanks. this is a bit counterintuitive, because for example in C private method called this way gives compile time error.
bbkr gets back to checking RT 15:05
masak bbkr: I see. I guess it could be done even in Perl 6.
arnsholt Remember that Perl is a dynamic language, which means that names can come and go quite a bit more than in C 15:06
masak maybe someone augments a class in an eval string to trust things at runtime... :)
15:06 dakkar joined
arnsholt Exactly 15:07
15:08 hercynium joined
bbkr it falls into "enough rope" philosophy, however decreases security. method is private for a reason - it's not intended to be called from outside class scope because bad things may happen :) 15:10
masak indeed. in a similar vein, people shouldn't use 'trusts' at all. 15:13
JimmyZ masak: Is it rakudo bug?
masak is what?
JimmyZ: I think bbkr is currently going through open RT tickets. so, yes. :) 15:14
JimmyZ I copied your code
masak JimmyZ: oh, that one.
JimmyZ: I think p6eval broke.
JimmyZ oh
rakudo: say 'hi' 15:15
p6eval rakudo 4e69c4: OUTPUT«hi␤»
masak that's my buest guess. but it seems only to trigger on the prime code so far.
s/buest/best/ 15:16
15:16 pmurias left, Ross joined 15:17 patrickas joined
cognominal how I declare the type of integers belonging to a span? 15:19
patrickas hello
cognominal hum, /me ack subset
patrickas I think p6eval is a few days behind even if the version reported is the latest.... can someone confirm / fix ? 15:20
JimmyZ std: .say for grep { my $p = 1; for 2, (3, 5 ... .sqrt) -> $d { if $_ %% $d { $p = 0; last } }; $p }, 2..* 15:25
p6eval std 31504: OUTPUT«ok 00:01 115m␤»
JimmyZ :( 15:26
masak rakudo: my $min = 5; my $max = 42; subset Span of Int where $min..$max; say 5 ~~ Span; say 43 ~~ Span 15:27
p6eval rakudo 4e69c4: OUTPUT«1␤0␤»
patrickas rakudo: .say for grep { my $p = 1; for 2, (3, 5 ... .sqrt) -> $d { if $_ !% $d { $p = 0; last } }; $p }, 2..* 15:28
p6eval rakudo 4e69c4: OUTPUT«29␤31␤37␤41␤43␤47␤53␤59␤61␤67␤71␤73␤79␤83␤89␤97␤101␤103␤107␤109␤113␤127␤131␤137␤139␤149␤151␤157␤163␤167␤173␤179␤181␤191␤193␤197␤199␤211␤223␤227␤229␤233␤239␤241␤251␤257␤263␤»
xinming @_@ perl6 sucks.
pmichaud ...I think I need to make a hard-and-fast rule that we do *not* put helper subs into the core setting. 15:29
patrickas hugs xinming, it's OK.
JimmyZ xinming: 晚上好
xinming JimmyZ: 你好
Well, don't talk Chinese here.
masak 为什么? :) 15:30
15:30 ashleydev joined
patrickas @pmichaud you mean like main_helper ? 15:31
15:31 songmaster joined
JimmyZ 呵呵 15:31
xinming masak: Because, when we talk too much Chinese, people start thinking in Chinese and ignore the higher priority job. :-)
masak sometimes what you need to solve a problem is to think in Chinese :) 15:32
it's a bit like doing a Fourier transform. some things get easier. :P
JimmyZ I don't think people will pay much attention on chinese. 15:33
arnsholt Well, I won't, seeing how I don't understand it =) 15:37
masak rakudo: sub 你好($greetee) { say "你好, $greetee!" }; 你好("世界")
p6eval rakudo 4e69c4: OUTPUT«你好, 世界!␤»
15:37 ashleydev left
masak rakudo: say "我不是中国人".trans("我" => "你") 15:40
p6eval rakudo 4e69c4: OUTPUT«你不是中国人␤»
masak \o/
15:41 ashleydev joined 15:44 amkrankruleuen joined
cognominal is there an Discrete Ordered role with a succ and prec method? 15:44
amkrankruleuen Hello.
masak amkrankruleuen: hi!
patrickas hello amkrankruleuen
masak I find that reading the RFCs is a very good way to gain appreciation of the current design of Perl 6. :) 15:47
s/of/for/
15:49 eternaleye left
cxreg masak: Perl 6 is sentient and self-designed. Of the Perl 6, by the Perl 6, and for the Perl 6 15:50
xinming masak: Is syopsis stablized for first 6.0 release? :-)
masak cxreg: careful -- on the Internet, not everyone understands hyperbole. :P 15:51
ingy hi masak!
xinming or, lwall is still changing it, and implementation designer only choose one version of it?
masak ingy: hi!
patrickas "Could not find sub ARGFILES_CREATE in main program body at <unknown line>" for an empty program ...
masak xinming: I'm not sure it works like either of those two questions imply. :) 15:52
patrickas Oh is that the reason for @pmichaud's hard-and-fast rule ?
ingy masak: would you like to take some time to pair with me on TestML.pm6?
patch and I got it almost ported
masak ingy: not sure I can spare the time right now, unfortunately.
ingy: but it does sound very alluring.
ingy but we are a little stuck on grammar stuff
PerlJam xinming: Perhaps at the 6.0 release, all of the Synopses will be tagged in some way so that we know what version of the S corresponds with Perl 6.0
ingy is there a good time for you? 15:53
masak hm.
ingy it would only be ~30 mins
xinming PerlJam: Is it the "almost" final stage now?
masak ingy: oh, in that case, let's go for it.
xinming I mean for languag.
masak ingy: I might get pulled away, but that's always a risk.
ingy masak: join #testml 15:54
PerlJam xinming: um ... sure.
masak xinming: it's changing more than any implemented language I know. but it's more stable than it's ever been.
people who are wary of change should perhaps... wait a bit still. 15:55
PerlJam masak++ an excellent synopsis
masak but core things are increasingy stable.
15:56 daxim left
masak the current set of people invited are usually label'd "early adopters". those are the ones that can take a little pain to get a lot of cool stuff before everyone else. :) 15:56
15:57 amkrankruleuen left 15:58 uniejo joined
JimmyZ good night 16:00
16:01 tadzik joined 16:03 justatheory joined
masak JimmyZ: 晚安! 16:03
JimmyZ masak: :)
thanks
16:04 JimmyZ left 16:06 uniejo left, am0c left
pmichaud 15:29 <pmichaud> ...I think I need to make a hard-and-fast rule that we do *not* put helper subs into the core setting. 16:10
yeah, I was referring to ARGFILES_CREATE. But there are a lot of others as well.
What is happening is that people see that others are doing it, and using that as a pattern for their own patches. 16:11
xinming masak: I wish start writing perl 6 as before. I mean write some of my scripts into perl 6. But afraid of rewriting them again. :-) 16:12
patrickas what is the right pattern ? 16:13
masak xinming: neither I nor anyone else can promise you that nothing will change from now on.
16:13 meppl joined
masak xinming: our goal right now isn't keeping things extremely stable, it's putting out a good, consistent Perl 6. 16:13
16:14 gbacon left
cxreg at least if you have to make changes later, they wont likely need to be huge ones 16:16
masak I'd characterise the changes needed for the app cheese to transfer from alpha to master as "huge ones". based on that, I'd be wary of making promises about the immediate future. :) 16:19
pmichaud iirc, $*ARGFILES is supposed to directly manipulate @ARGS 16:20
(albeit lazily)
masak what's the downside of sending the type object of an action class, rather than an instance? 16:21
pmichaud masak: none that I know of. In fact, that's pretty much canonical nowadays, at least for the code I write.
masak ok.
16:23 macdaddy joined, macdaddy is now known as Guest63979
pmichaud moritz_: ping 16:23
songmaster rakudo: class A {has $.v; method set($v){$.v=$v}}; my $a=A.new;$a.set(1) 16:24
p6eval rakudo 4e69c4: OUTPUT«Cannot assign to readonly value␤ in '&infix:<=>' at line 1␤ in 'A::set' at line 11:/tmp/4rZsVl5eQG␤ in main program body at line 11:/tmp/4rZsVl5eQG␤»
dalek kudo: 6ea4d0c | pmichaud++ | src/core/Block.pm:
Refactor Block.arity and Block.count; make .count return Inf.
kudo: 451b409 | pmichaud++ | src/core/IO/ArgFiles.pm:
Merge branch 'master' of github.com:rakudo/rakudo
songmaster Where does rakudo get the idea that $.v is readonly? 16:25
pmichaud songmaster: ....from the spec? ;-)
songmaster Ok, where did I *say* it's readonly? 16:26
pmichaud by not specifying 'is rw'
same with parameters
they default to readonly unless you explicitly make them rw
songmaster Isn't that for external access though? A::set is a method...
pmichaud internally, a method uses $!v 16:27
if a method uses $.v, it's using the public method interface
if the method uses $!v, it's accessing the attribute directly
songmaster Ahhhhh. I don't remember seeing that written down, but I didn't study twigils very much. Thanks.
pmichaud opinion request: should I file a bug report against the IO::ArgFiles implementation or should I just fix it myself? 16:28
xinming masak: Yes, I know, So I think I need to wait a bit more. Still many things to do in real life. 16:29
[particle] pmichaud: file the bug report with a patch, and apply it?
16:29 timbunce left
pmichaud [particle]: if I'm applying, I should just fix and bypass the bug report. 16:30
[particle] that seems a little like busywork
i don't think anyone will get upset with you advancing things on your own initiative
pmichaud my question is more whether it's better to say "this needs fixing" and let someone else pick up the ball, or to just fix myself.
I'm not worried about upset-ness as much as opportunity-for-others-to-develop
[particle] ah, well i've seen people asking for LHF 16:31
if it's not an urgent fix, it's an opportunity for that
patrickas pmichaud I am worried that not too many people know how to create the HELPER the right way
pmichaud patrickas: me also.
patrickas so I would suggest fixing it this time and adding an RT for other places like it 16:32
I suspect MAIN_HELPER is in the same case .. so someone could pick that up
even though it feels bad taking time from the only pmichaud we have for such things :-( 16:34
16:35 timbunce joined 16:37 alester joined
pmichaud gist.github.com/457450 # $*ARGFILES fail 16:39
16:40 mberends joined 16:47 Sarten-X joined 16:52 patrickas left 16:55 ash_ joined, molaf left, whereischewacca joined
whereischewacca hello 16:55
16:58 whereischewacca left 17:06 thebird left 17:09 uniejo joined
[Coke] pmichaud: you should let other people fix it. Your tuits are very specially shaped. =-) 17:10
17:15 foodoo left 17:16 cdarroch joined, cdarroch left, cdarroch joined, ashleydev left 17:18 songmaster left 17:29 masak left
pmichaud [Coke]: I think that assumes that it takes less tuits to mentor someone through the problem than it does to solve it :-) 17:29
PerlJam pmichaud: or that mentoring is more important that just solving it. (community building and all that) 17:30
17:31 amkrankruleuen joined
pmichaud PerlJam: right, thus my question 17:40
where do we want the priority in this particular case? ;-)
(and others like it that occur over the next few weeks)
PerlJam ah .. I didn't even look at the scrollback this time and so didn't see the question 17:42
17:42 gbacon joined
PerlJam The rule of thumb that I might use would be if it's easyish for you to fix and it would cause some annoyance to R* users if it were not fixed, fix it yourself. 17:43
17:45 ashleydev joined, TiMBuS left 17:48 justatheory_ joined 17:49 justatheory left, justatheory_ is now known as justatheory
sorear hello #perl6 17:52
colomon o/
cxreg is ^10...^10 supposed to be an infinite series? 17:53
it seems to be, but i'm not sure why
pmichaud that would be the same as (0..9)...^(10) 18:01
which should just be 0..9
18:02 uniejo left
colomon no 18:03
it should be treated like 7, 8, 9 ... 0
pmichaud why is that? 18:04
colomon errr... okay, maybe pmichaud is right here.
if there's no generator, you look at the last three numbers on the LHS
pmichaud right. :) 18:05
which would be 7, 8, 9
which would make the next item in sequence a 10
which isn't less than 10
so we stop :-)
colomon less than 10 doesn't enter into it.
but actually, the sequence is
0, 1, 2, 3, 4, 5, 6, 7, 8, 9 ... 0
pmichaud why 0?
colomon which should be just 0
pmichaud that's what I don't understand
where are you getting that last 0 from? 18:06
colomon sorry, was parsing it as ... ^10
pmichaud right, it parses as ...^ 10
colomon if it's ...^ 10, then you're absolutely right.
pmichaud even if it's the other way, I'm absolutely right :)
because then it's 18:07
(0..9) ... (0..9)
which ends up acting like
colomon pmichaud++
pmichaud (0..9) ... 0, (1..9)
which ends up being 0..9
colomon that's kind of freaky, actually.
pmichaud unless that ... 0 ends up making an infinite series
but I think not, since we have an exact match
colomon it might at the moment, but it definitely shouldn't. 18:08
18:22 patrickas joined
patrickas about ^10 ... ^10, shouldn't it be null ? 18:23
i mean Nil
18:26 songmaster joined
colomon nope. pmichaud explained why very nicely 18:27
patrickas colomon I either did not understand or do not agree :-)
colomon okay, do you agree it would be the same as
(0...9) ... (0...9) ? 18:28
(assuming space between ... and ^ here)
patrickas the first series ends in 7,8,9 and the second one starts with 0
18:29 gbacon left
patrickas zero is on the "wrong" side of 7,8,9 ( arithmetic increasing) 18:29
colomon it doesn't matter what the first one ends with in this case. only what it begins with
patrickas so it shoudl be Nil
you mean : 7,8,9 ... 0 is not Nil ? 18:30
colomon oooh, you're right.
I think the spec is broken there.
but in that case, the series is 1...9
mberends #phasers in 30 minutes, right? 18:31
patrickas I am not sure 18:32
pmichaud I'll walk through it 18:33
(0..9) ... (0..9)
is the same as
(0, 1, 2, 3, 4, 5, 6, 7, 8, 9) ... (0, 1, 2, 3, 4, 5, 6, 7, 8, 9)
is the same as
( (0, 1, 2, 3, 4, 5, 6, 7, 8, 9) ... 0), 1, 2, 3, 4, 5, 6, 7, 8, 9 18:34
now the only question is what happens to that first series
patrickas the spec says Nil
pmichaud no 18:35
colomon "For intuited numeric generators that don't involve geometric sign changes, all values are assumed to be monotonically increasing or decreasing, as determined by the (up to) three values used above; if a supplied limit value is on the "wrong" side of the first of those values, Nil is returned"
pmichaud in this case, the supplied limit value is not on the "wrong" side of the first of the values 18:36
colomon I think patrickas is reading the spec correctly, but the spec is pretty clearly broken.
the first of the values is 7
pmichaud the supplied limit value *is* the first of the values, which I would interpret as meaning "exact match"
I think it's the zero.
not the 7.
although the spec seems to indicate it's the 7, yes. 18:37
colomon I think it's intended to be the 0, for sure, but I don't think it reads that way.
pmichaud if it's just the 7, then the resulting sequence would be
(0, 1, 2, 3, 4, 5, 6), 1, 2, 3, 4, 5, 6, 7, 8, 9
and I think that doesn't make much sense. :-) 18:38
patrickas :-)
colomon is TimToady around atm?
pmichaud likely not, I think he would've chimed in already. :)
patrickas I think the three values talked about in the spec are the last three numbers in the rhs
i mean lhs :-)
pmichaud I think it probably means the entire lhs 18:39
because if I write 1, 2, 3, 4, 5, ... $n
I think it should be smart enough to stop at 2 when $n is 2.
colomon absolutely agreed, I will attempt to patch the spec. ;)
pmichaud more to the point 18:40
if I have
@a ... $n
then it should figure out the sequence from @a, but still be smart enough to stop at $n
lue ohai 18:41
colomon I think it's just a matter of clarifying that sentence.
patrickas yes that would make sense ... but I was already bitten by this earlier and I think I was told "that's not what the spec says" :-) 18:42
18:45 tylercurtis joined
colomon For intuited numeric generators that don't involve geometric sign changes, all 18:47
values are assumed to be monotonically increasing or decreasing, as determined
by the (up to) three values used above; if a supplied limit value is on the
"wrong" side of the first value of the full left list, Nil is returned....
does that seem okay?
pmichaud seems okay to me.
pugssvn r31505 | colomon++ | [Spec] Clarify when to return Nil from the series operator. 18:49
18:53 hudnix joined 18:56 mmcleric_ joined, mmcleric left, mmcleric_ is now known as mmcleric
sorear #phasers this week? 19:00
pmichaud yes, afaik 19:01
lue
.oO(phasers?)
19:04
patrickas back 19:11
so colomon, pmichaud how according to the new clarification (0..9) ... 0 should be 0 and not Nil ? 19:13
s/how/now/
pmichaud yes. 19:14
although (1..9) ... 0 would be Nil
patrickas ok thanks 19:15
lue it doesn't count backwards? Must be that extra . :) 19:16
patrickas lue (0,9),8,7 ... 0 should do that 19:17
lue I thought it could go 1,2,3,4,5…9,8,7,6,5,4,3,2,1,0. But I see why it returns Nil. 19:18
colomon lue: Range doesn't count backwards.
19:18 hudnix left
colomon lue, 1 ... 9 ... 0 should do that. but I don't think it works yet. 19:18
19:19 Guest23195 joined
lue would series (..) do that? 19:20
patrickas colomon is ... right associative ?
colomon patrickas: good question. 19:21
moritz_ pmichaud: pong
patrickas hello moritz_, I think p6eval is acting up again 19:22
pretending to be up to date when it is actually a few days old 19:23
moritz_ pmichaud: the rakudo target?
patrickas yes
moritz_ erm sorry, meant patrickas :-) 19:24
patrickas :-)
moritz_ rakudo: say 9 %% 3
p6eval rakudo 451b40: OUTPUT«===SORRY!===␤Confused at line 11, near "say 9 %% 3"␤»
patrickas rakudo: say 9 !% 3 19:25
p6eval rakudo 51b40: OUTPUT«1␤»
moritz_ trying to trigger a new rebuild
patrickas the same thing hapened a few weeks ago... one of the two builds was acting up 19:26
lue even the revision numbers are acting up (look up) 19:29
moritz_ lue: I've manipulated the version number to trigger a rebuild 19:31
lue ah, that's what it is. 19:33
19:35 ash_ left
moritz_ rakudo: say 9 %% 3 19:39
p6eval rakudo 451b40: OUTPUT«1␤»
moritz_ rakudo: my @a = 1..*; say @a[5]
patrickas thanks :-)
p6eval rakudo 451b40: OUTPUT«6␤»
19:39 mmcleric left
colomon \o/ 19:40
moritz_ triggering another rebuild to update the second copy
19:45 ash_ joined 20:00 justatheory left, envi^home left 20:04 Mowah left 20:17 kensanata joined 20:19 ruoso left
lue afk 20:22
Tene It really makes me sad to see people talking about things that I put on my todo list ages ago, and never got around to.
My todo list is looking more and more like a graveyard of burned-out ideas, lately.
20:26 Su-Shee left
mberends Tene: you have all my sympathy. It's a familiar feeling :/ 20:28
arnsholt I suspect everyone has that feeling 20:30
Having ideas is a lot easier than actually doing them =) 20:31
tylercurtis And starting them is also a lot easier than actually finishing them.
arnsholt Oh definitely 20:33
20:33 dju left
mberends .oo( finishing Perl 6 is the hardest thing of all ) 20:34
arnsholt That's why it's a collective effort
We take turns procrastinating =)
mberends moritz_: I think I have solved your problem of building FakeDBI without FakeDBD::mysql, by wrapping the potentially failing code in an eval() 20:37
pugssvn r31506 | lwall++ | [STD] don't complain on anonymous package 20:48
20:53 justatheory joined 20:56 japhb left
patrickas rakudo: (1...3).batch(5).join(',').say 20:57
p6eval rakudo 451b40: OUTPUT«1,2,3,Any(),Any()␤»
20:59 songmaster left 21:01 dakkar left 21:06 japhb joined 21:10 felliott left 21:12 Guest23195 left, felliott joined 21:21 pmurias joined, songmaster joined 21:23 timbunce left 21:26 pmurias left 21:27 tadzik left 21:28 timbunce joined 21:30 gbacon joined, kensanata left 21:45 Guest7877 left
colomon wow, $*IN.slurp.words is shockingly more efficient than $*IN.lines.split(/\s+/) 21:45
sorear why shocking? many less syscalls 21:46
colomon on the same 100 line test file, lines.split takes 69 seconds, slurp.words 2.5.
pmichaud what about .lines.words, ooc? 21:47
colomon It's only 100 line file, it definitely should not make that much of a difference.
sorear try stracing both
slavik pmichaud: I think .words is a bad idea
pmichaud: unless you mean to say split /\W/
colomon lines.words is 20 second 21:48
pmichaud that makes more sense
using .split is definitely p5-think.
and it's far easier to capture what you ask for than to capture what you ask to exclude :-)
slavik pmichaud: I mean if .words is the same as split /\W/
pmichaud slavik: it's not.
slavik because .words can be different depending on the language/context 21:49
pmichaud .words is more like .comb(/\S+/)
slavik like numbers or something
masonkramer what is .words doing under the hood that makes it better than split?
slavik masonkramer: not what it does, but what it means
pmichaud split says what you don't want. It has to compute captures for the things between the matches.
slavik pmichaud: right
pmichaud comb (and thus .words) says what you do want. 21:50
slavik I see
21:51 masak joined
masak o/ 21:51
got an envelope from Google today. \o/
jnthn \o/
21:51 dju joined
masak I must say, pretty motivating to get that. 21:52
I'm glad the grant's going pretty well. if anything, this'll make me shift up a gear. 21:53
jnthn looks forward to seeing the next round of commits on binary files :-)
colomon \o/
21:53 dju left
masak we figured out the grand scheme of things on #parrot yesterday. 21:53
if I don't get to it before the weekend, surely I'll do it during. :) 21:54
colomon pmichaud: I was worried performance might be pretty bad on combining the array of strings from .lines into one string to feed to .split. Maybe an n^2 issue? but I don't have time to drill down atm, off for noms.
21:54 dju joined
jnthn masak: :-) 21:55
21:56 Ross left, kensanata joined
pmichaud in S03, on the series operator, we have: 21:59
If no closure is provided, and the sequence is numeric, and is obviously
arithmetic or geometric (from examining its I<last> 3 values), the appropriate function is deduced:
when it says "the sequence is numeric", is that testing only the last three values, or the entire sequence? 22:00
masak the last three values. more flexible, and easier to grok.
pmichaud so it should probably read 22:01
"If no closure is provided, and the last three values are obviously arithmetic or geometric, ...
s/,//
also, the spec doesn't seem to be clear about what happens if we have three numeric values that aren't obviously geometric nor arithmetic 22:04
for example
1, 3, 7 ... *
masak xinming: I respect those people who say "Perl 6 is still too volatile, let me wait just a bit for it to settle down". there should still be plenty of people who are willing to trade a bit of risk for the opportunity to test-drive Perl 6 as it comes in for a landing. :)
pmichaud: I'd as 22:05
oops
pmichaud: I'd say error,
with the opportunity to overload with multies.
pmichaud overloading with multis is likely to be hard, since &infix:<...> is list associative
masak in general, it'd be nice if the series operator were dispatched through multies... :)
pmichaud see last irc line.
22:06 amkrankruleuen left
masak why does list associativity make overloading hard? 22:06
probably does, but I don't immediately see it.
pmichaud the general signature for &infix:<...> is likely multi sub infix:<...>(**@lists)
I suppose that could be broken down into multiple binary cases 22:07
and mmd on the binary case
masak yes.
pmichaud doing this with mmd might be.... very interesting. 22:08
I'll try that :-)
masak pmichaud++
pmichaud although the where clauses get really ugly 22:09
jnthn pmichaud: What are you trying to dispatch based on? 22:10
masak pmichaud: turn the where clauses into subtypes or subroutines or something.
pmichaud jnthn: I'm disliking the current implementation of &infix:<...>
jnthn pmichaud: That is, what seperates the things in question?
masak **@lists where ArithmeticSequence
pmichaud so, there are a few cases
the basic pattern is multi sub infix:<...>(@a is copy ... , $limit)
where we're looking for certain patterns in @a 22:11
so
@a >= 3 && @a[*-2] - @a[*-3] == @a[*-1] - @a[*-2] && @a[*-2] != @a[*-1] .... 22:12
but perhaps a subroutine makes more sense here 22:13
I'll try that.
masak eew
.[*-2] - .[*-2] etc given @a
:)
er, *-3
pmichaud still too ugly for my taste. 22:14
masak but probably a lexical subroutine will help as well.
that's what immediate blocks were made for :)
jnthn
.oO( infix:<...>(@a is copy [$a, $b, $c where $a - $b == $c - $b], ... ) )
pmichaud jnthn: has to be the last three elements of @a
jnthn Not quite sure you can twist what you wnat out of nested signatures.
patrickas i got a local patch that fixes (1..9) ... 5
jnthn Ah
:/
patrickas who can I ask for review ? 22:15
jnthn Then you can't.
patrickas with a warning that it might lead to hair loss (or hair pulling) :-)
masak .oO( @a.reverse is copy )
jnthn :P
though
pmichaud patrickas: you can post it to a ticket or something. But I really am planning to refactor all of &infix:<...> fairly significantly, so most patches are likely to be rendered obsolete.
masak man, that'd be a great extension of siggies! @a.sort is copy! @a>>.uc is copy! 22:16
22:16 kensanata left
jnthn @a is copy where .reverse ~~ :([$a, $b, $c where ... ]) 22:16
;-)
masak hugme: hug #perl6
hugme hugs #perl6
jnthn Or to modify it I guess where .= reverse 22:17
maybe
;-)
pmichaud masak: (error on series not able to determine progression) -- that seems to go against the way much of the rest of series is defined
jnthn rakudo: sub foo(@a is copy where .= reverse) { say @a }; foo([1,2,3]);
p6eval rakudo 451b40: OUTPUT«===SORRY!===␤Unable to parse postcircumfix:sym<( )>, couldn't find final ')' at line 11␤»
jnthn rakudo: sub foo(@a is copy where {.= reverse}) { say @a }; foo([1,2,3]);
p6eval rakudo 451b40: OUTPUT«===SORRY!===␤Unable to parse blockoid, couldn't find final '}' at line 11␤»
jnthn rakudo: sub foo(@a is copy where {.=reverse}) { say @a }; foo([1,2,3]); 22:18
masak pmichaud: then maybe default on arith on the last two terms?
p6eval rakudo 451b40: OUTPUT«Cannot assign to readonly value␤ in '&infix:<=>' at line 1␤ in <anon> at line 11:/tmp/4KqkpxNkPw␤ in 'Block::ACCEPTS' at line 4985:CORE.setting␤ in 'foo' at line 1:/tmp/4KqkpxNkPw␤ in 'foo' at line 11:/tmp/4KqkpxNkPw␤ in main program body at line 11:/tmp/4KqkpxNkPw␤»
ash_ std: sub foo(@a is copy where {.=reverse}) { say @a }; foo([1,2,3]);
pmichaud masak: yeah... not really sure about this one.
p6eval std 31506: OUTPUT«ok 00:01 117m␤»
jnthn rakudo: sub foo(@a is copy where -> @x is rw { @x.=reverse }) { say @a }; foo([1,2,3]);
p6eval rakudo 451b40: OUTPUT«Cannot assign to readonly value␤ in '&infix:<=>' at line 1␤ in <anon> at line 11:/tmp/ghfWIaPJen␤ in 'Block::ACCEPTS' at line 4985:CORE.setting␤ in 'foo' at line 1:/tmp/ghfWIaPJen␤ in 'foo' at line 11:/tmp/ghfWIaPJen␤ in main program body at line 11:/tmp/ghfWIaPJen␤»
jnthn aww!
I think you hit an ordering problem there though
masak ash_: that's cool, but it'll disallow empty arrays :)
jnthn It doesn't make the copy until later
masonkramer from the p5->6 guide, newb question about this line: 22:19
ash_ i was just checking jnthn to see if that was valid
masonkramer doit(:when<noon>, :what('more stuff')); # what's the difference between <> and ('') here?
jnthn rakudo: subset reverse; sub foo(@a as reverse) { say @a }; foo[1,2,3]; # please don't work...
p6eval rakudo 451b40: OUTPUT«Not enough positional parameters passed; got 0 but expected 1␤ in 'foo' at line 11:/tmp/ztgRzX6OUY␤ in main program body at line 11:/tmp/ztgRzX6OUY␤»
pmichaud masonkramer: in that particular example, not much
jnthn rakudo: subset reverse; sub foo(@a as reverse) { say @a }; foo([1,2,3]); # please don't work...
p6eval rakudo 451b40: OUTPUT«Unable to coerce value for '@a' from Array to Any; no coercion method defined␤ in 'foo' at line 11:/tmp/jt7Bsg0K53␤ in main program body at line 11:/tmp/jt7Bsg0K53␤»
pmichaud masonkramer: however, note that :what<more stuff> doesn't do the same as :what('more stuff')
jnthn heh :-)
ash_ masonkramer: <a> = ('a'); but <a b> = ('a', 'b') 22:20
jnthn rakudo: class reverse { }; sub foo(@a as reverse) { say @a }; foo([1,2,3]); # please don't work...
masonkramer <> is qw() ?
p6eval rakudo 451b40: OUTPUT«321␤»
jnthn omfg.
pmichaud masonkramer: yes.
masonkramer love it
jnthn (Don't ever do what I just did in your code. :-))
masak jnthn: wtf? 22:21
patrickas here is the diff but I suppose it won't bee needed since pmichaud++ will refactor anyway! github.com/patrickas/rakudo/commit/...590ec66bb5
masak jnthn: I should throw *you* into RT! :)
jnthn masak: The default implementation of coercion is .TypeName
masak: If you declare a type that has the same name as a method on the object, it'll get called. :-)
masak jnthn: wow. that's actually correct then. 22:22
pmichaud patrickas: yes, defining a flag like "$early-exit" is almost certain to be rejected by the pumpking.
patrickas jnthn WHOA!
jnthn masak: Er, I fear so. :-)
masak jnthn: just... really twisted.
jnthn masak: Though maybe not.
masak: I can't think why it's wrong though.
masak jnthn: perhaps the above code is horrid enough for us to convince TimToady that a special syntax is needed for this. :)
sub foo(@a as .reverse) would fly, maybe. 22:23
jnthn Even when we do coercion more properly I'd still expect us to hit the default of "call .TypeName" in this cae.
*case
ingy q: is using 'ast' in grammars just a convention?
moritz_ ingy: nope
jnthn ingy: No
moritz_ ingy: make() sets the .ast
jnthn ingy: It gets what was stored by make
patrickas pmichaud it's ok ... I guess I won't be cleaning it though if you are going to refactor the whole thing anyway...
moritz_ and $() defaults to $/.ast if it exists
jnthn gah, moritz_++ beats me twice. :-)
masak I'm having lags, so if my jokes are not on time, that's why. totally.
ingy haha 22:24
thanks guys
masak ingy: I suspected as much. so maybe calling .ast will solve your problem.
ingy one more q: how do I access [ ] groups from a action routine? 22:25
moritz_ you don't
they don't capture
use ( ) if you want captures
ingy masak: ashleydev has been helping me
pmichaud you can also alias
$<xyz>=[ ... ]
ingy moritz_: btw, been studying your excellent JSON::Tiny
moritz_ rakudo: $()
p6eval rakudo 451b40: ( no output ) 22:26
masak ashleydev++
ingy moritz_++
pmichaud use an alias to grab whatever is inside of [...]
moritz_ ingy: glad it's useful
ingy ossum!
masak rakudo: "foo" ~~ /foo/; say "What kind of $()l am I?"
p6eval rakudo 451b40: OUTPUT«What kind of l am I?␤»
masak hm, shouldn't that say 'fool'? 22:27
pmichaud no
spec was changed
.ast is undef if not set.
ingy so how do I access ( ) groupings from inside an Action method?
pmichaud (it used to be .Str if not set)
masak ahah
right.
pmichaud ingy: $/[0] $/[1] $[2]
moritz_ pmichaud: $() should be $/.ast // $/.Str iirc
pmichaud er, $/[2]
masak good. that's separation for you.
ingy thanks
pmichaud moritz_: oh, that's possible, yes.
22:27 meteorjay left, drbean left
masak rakudo: "foo" ~~ / foo {make "foo"} /; say "What kind of $()l am I?" 22:27
moritz_ S05:2577:C<$()> is a shorthand for C<$($/.ast // ~$/)>.
p6eval rakudo 451b40: OUTPUT«What kind of l am I?␤»
ingy <3
masak pmichaud: what about that? 22:28
pmichaud masak: that looks buggish.
masak submits rakudobug
pmichaud: also, what moritz_ said.
moritz_ $() is just coercion to item
pmichaud rakudo: 'foo' ~~ / foo { say $/ } /
p6eval rakudo 451b40: OUTPUT«foo␤»
moritz_ in rakudo
pmichaud ah
jnthn I think make not done inside an action method has always been buggy, fwiw.
pmichaud I think make is just broken in rakudo
masak so, two bugs.
jnthn pmichaud: Yes, that matches my experience. 22:29
masak submits the other rakudobug
pmichaud nqp: 'foo' ~~ / foo { make 'foo' } /; say($/.ast);
p6eval nqp: OUTPUT«Symbol '$/' not predeclared in <anonymous>␤current instr.: 'parrot;PCT;HLLCompiler;panic' pc 152 (compilers/pct/src/PCT/HLLCompiler.pir:109)␤»
22:29 drbean joined
pmichaud nqp: say(('foo' ~~ / foo { make 'foo' }/).ast) 22:29
p6eval nqp: OUTPUT«␤»
pmichaud hmmm.
22:29 skids left
pmichaud okay, I'll look at that one. 22:29
but I do suspect a bug in rakudo's &make 22:30
moritz_ tries to patch $()
pmichaud as in, it appears that rakudo doesn't have one.
masak pmichaud: sometimes when you respond quickly to things, I feel I'm breaking your focus. weren't you fixing the infix:<...> operator just now? :)
pmichaud masak: yes, but I need to think about it a bit more
masak ok, good. 22:31
pmichaud so the topic switch isn't really a distraction
masak just checking. :)
pmichaud and it's not nearly as distracting as the various background noises here at the house :-(
jnthn rakudo: say class C {} 22:32
p6eval rakudo 451b40: OUTPUT«!class_init_11␤»
jnthn rakudo: say anon class C {}
p6eval rakudo 451b40: OUTPUT«C()␤»
jnthn rakudo: say my class C {}
p6eval rakudo 451b40: OUTPUT«C()␤»
jnthn rakudo: say our class C {}
p6eval rakudo 451b40: OUTPUT«!class_init_11␤»
22:33 meteorjay joined
jnthn ...who on earth implemented this... 22:33
diakopter someone on earth?
masak someone in a country starting with an S? 22:34
jnthn
.oO( Looks like it came out of Uranus )
22:34 amkrankruleuen joined
jnthn adds it to his open RT tickets to deal with 22:35
cxreg FakeDBI Pg support: github.com/cxreg/fakedbi/commit/b4f...e3a8d120b7 22:37
implementing only what was already in mysql.pm6
lots more needed, certainly
mberends: ping
jnthn cxreg++! 22:38
moritz_ cxreg++
22:38 patrickas left
jnthn phenny: tell mmcleric Thanks for the whatevercode patch - bit too tired to review it tonight, but will give it a proper look tomorrow. :-) 22:38
phenny jnthn: I'll pass that on when mmcleric is around.
jnthn Tack, phenny.
moritz_ hugme: add cxreg to fakedbi
hugme hugs cxreg. Welcome to fakedbi!
cxreg i need to write a test 22:39
masak we all do :)
cxreg database driver tests are an interesting challenge
cuppe I'm looking for a reference for the List type, having trouble finding one
cxreg to where? as whom? 22:40
tylercurtis cuppe: perlcabal.org/syn/S32/Containers.html#List ?
cuppe thanks. was looking through synopses 22:41
masak cuppe: don't believe everything you read in S32. they're less clairvoyant than many of the lower-number synopses. 22:43
pugssvn r31507 | jnthn++ | [t/spec] Tests for [&&] and [and]. Patch courtesy of (Alex Kapranoff)++.
moritz_ it seems that the patch for $() is a bit too much for nearly 1AM 22:44
jnthn :-)
moritz_ rakudo: ::()
p6eval rakudo 451b40: OUTPUT«===SORRY!===␤ResizablePMCArray: Can't pop from an empty array!␤»
moritz_ masak: want to report? :-)
rakudo: class A { method item { 'foo' } }; say ::(A.new) 22:45
p6eval rakudo 451b40: OUTPUT«===SORRY!===␤Indirect name lookups not yet implemented at line 11, near ""␤»
jnthn Well, that's more helpful. ;-) 22:46
pmichaud cuppe: I'm in the midst of rewriting the List docs. 22:47
cxreg i wonder what the interface to libclntsh.so looks like
dalek kudo: 36998b8 | jonathan++ | src/core/operators.pm:
Make [&&] and [and] work. Patch courtesy of (Alex Kapranoff)++.
cuppe pmichaud: cool 22:48
masak submits ::() rakudobug 22:49
22:50 tedv joined, ashleydev left 22:53 gbacon left 22:55 ashleydev joined 22:56 hairykary joined
dukeleto std: my $r = sub { say @_[0].WHAT }; $r.() 22:56
p6eval std 31506: OUTPUT«ok 00:01 114m␤»
masak rakudo: say "alive"; ::() 22:57
p6eval rakudo 451b40: OUTPUT«===SORRY!===␤ResizablePMCArray: Can't pop from an empty array!␤»
masak at compile time.
22:59 lestrrat is now known as lest_away 23:00 whiteknight joined 23:02 hugme left 23:03 dukeleto left, Juerd left, pmichaud left, PerlJam left 23:04 hatsefla1s left, pugssvn left, Util left, dalek left
diakopter waves to feather 23:05
23:05 Juerd joined, pmichaud joined, hatseflats joined
cxreg i can't find the take-away from that earlier discussion about ^10...^10, but it sounds like it should probably not be the same as 0..Inf? :) 23:06
the whole thing is a mindfsck
moritz_ it's a sign of too much magic in too little space :-) 23:07
masak cxreg: if you find yourself *writing* ^10...^10, take a step back and review your objectives :)
cxreg :-)
it's certainly off the deep end, but the result was surprising 23:08
diakopter rakudo: say ^10...^10
p6eval rakudo 451b40:
..OUTPUT«012345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913…
23:09 amkrankruleuen left
diakopter oh. 23:09
okay.
23:10 dukeleto joined, Util joined, PerlJam joined 23:13 ruoso joined
ash_ ^10 is 0...10 23:14
masak ash_: and v10 is 10..0 :)
ash_ it is? neat, didn't know that one
rakudo: say v10
p6eval rakudo 451b40: OUTPUT«Could not find sub &v10␤ in main program body at line 11:/tmp/NtJQwV5klJ␤»
moritz_ ^10 is actually 0..^10
masak right. then v10 must be 10v..0 23:15
ash_ ah, oops, it doesn't do 10? only 10 digits?
rakudo: my $a = 4; say ^$a;
p6eval rakudo 451b40: OUTPUT«0123␤»
ash_ cool
masak rakudo: my @a = <a b c d>; .say for ^@a 23:16
p6eval rakudo 451b40: OUTPUT«0␤1␤2␤3␤»
sorear ok, best not to commit anything until dalek resurfaces
tylercurtis rakudo: say (0..9)..(0..9)
23:16 sorear sets mode: +oo masak ash_
p6eval rakudo 451b40: OUTPUT«0 1 2 3 4 5 6 7 8 9␤» 23:17
masak sorear: I'm just leaving :P
23:18 dju left
masak 'night, #perl6! 23:19
23:19 dju joined 23:20 masak left
ash_ nqp: say(:min-depth(4)); 23:21
p6eval nqp: OUTPUT«␤»
jnthn ash_: iirc nqp does nee recognize - in identifiers. 23:22
pmichaud it does now
say doesn't recognized any named arguments.
jnthn oh \o/
*nod* 23:23
pmichaud *recognize
jnthn pmichaud++ # fixing the - thingy
pmichaud rakudo: say(:min-depth(4))
ash_ yeah, i was more seeing if it complained about the syntax than being useful
p6eval rakudo 451b40: OUTPUT«Unexpected named parameter 'min-depth' passed␤ in 'say' at line 4637:CORE.setting␤ in main program body at line 11:/tmp/fFpyGinbsb␤»
ash_ rakudo: say :min-depth(4) 23:24
p6eval rakudo 451b40: OUTPUT«Unexpected named parameter 'min-depth' passed␤ in 'say' at line 4637:CORE.setting␤ in main program body at line 11:/tmp/LS6oP6X7Ua␤»
ash_ i thought that made a pair, oh well
pmichaud it's a named argument to say
rakudo: say (:min-depth(4))
p6eval rakudo 451b40: OUTPUT«min-depth 4␤»
pmichaud that one is a pair :-) 23:25
ash_ ah, k, i see the difference now
Tene say((:min-depth(4)))
nqp: say((:min-depth(4)))
p6eval nqp: OUTPUT«␤»
Tene rakudo: say((:min-depth(4)))
pmichaud Parrot doesn't have pairs, so nqp doesn't support them.
p6eval rakudo 451b40: OUTPUT«min-depth 4␤»
Tene rakudo: say (:a(:b(:c(:d(:cons-list(:tail)))))) 23:26
p6eval rakudo 451b40: OUTPUT«a b c d cons-list tail 1␤» 23:27
pmichaud rakudo: say (:a(:b(:c(:d(:cons-list(:tail)))))).perl
p6eval rakudo 451b40: OUTPUT«"a" => "b" => "c" => "d" => "cons-list" => "tail" => Bool::True␤»
pmichaud rakudo: say (:a(:b(:c(:d(:cons-list(:tail)))))).value
p6eval rakudo 451b40: OUTPUT«b c d cons-list tail 1␤» 23:28
pmichaud rakudo: say (:a(:b(:c(:d(:cons-list(:tail)))))).key
p6eval rakudo 451b40: OUTPUT«a␤»
pmichaud sooner or later, everything becomes Lisp.
ash_ lol
if perl6's syntax fit on a note card... 23:29
pmichaud how small can I make the font?
or, how big can I make the note card? 23:30
ash_ both good points
23:33 songmaster left
ingy make $<quoted_string>.ast // $<unquoted_string>.ast; fails because quoted_string has no ast. fix? 23:33
pmichaud make $<quoted_string> ?? ... !! 23:34
ingy k
pmichaud or
make $<quoted_string>.?ast || $<unquoted_string>.ast # if you know that .ast always returns a non-false value 23:35
23:36 hairykary left
ingy is "0" false? :) 23:36
pmichaud yes.
ingy anyway first thing works great, pmichaud++
thx!
your patience will pay off, I promise :) 23:37
23:39 redicaps left
ashleydev cool 23:42
23:43 rv2733 joined 23:46 timbunce left, cdarroch left 23:49 rv2733 left 23:54 gbacon joined, Psyche^ joined
ingy how do I write a universal method like .perl ? 23:54
23:55 Patterner left, Psyche^ is now known as Patterner
[Coke] at a guess, monkey patch something near the top of the hierarchy, like Cool? 23:55
.perl is probably written in Perl 6 in the setting, so you can probably do what it did.
ingy wants to write .json .yaml and .jsync methods 23:56