»ö« 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.
LlamaRider Hm, there is an error message I can't figure out: " Method 'STORE' not found for invocant of class 'Any' " 00:05
00:10 raiph joined
tadzik what did you do? 00:16
LlamaRider r: module example { my @a=<a>; our @b=<b>; }
p6eval rakudo 11157e: OUTPUT«No such method 'STORE' for invocant of type 'Any'␤ in block at /tmp/QfTutj8a5s:1␤␤»
LlamaRider the my works, but the our doesn't. I don't seem to understand how "our" should function in p6. 00:17
r: module example { my @a=<a>; our @b; }
p6eval rakudo 11157e: ( no output )
LlamaRider this is also interesting
lue r: my @a=<a>; our @b=<b>; 00:18
p6eval rakudo 11157e: OUTPUT«No such method 'STORE' for invocant of type 'Any'␤ in block at /tmp/ptpjBQIlDJ:1␤␤»
lue r: my @a; our @b; say @a.WHAT; say @b.WHAT 00:21
p6eval rakudo 11157e: OUTPUT«(Array)␤(Any)␤»
LlamaRider O_O
well that explains the problem... 00:22
lue r: my @a; our @b is Array; say @a.WHAT; say @b.WHAT
p6eval rakudo 11157e: OUTPUT«(Array)␤(Any)␤»
lue n: my @a; our @b is Array; say @a.WHAT; say @b.WHAT
p6eval niecza v24-31-g7d73dd1: OUTPUT«===SORRY!===␤␤Trait name not available on variables at /tmp/gnM61h5oAI line 1:␤------> my @a; our @b is Array⏏; say @a.WHAT; say @b.WHAT␤␤Unhandled exception: Check failed␤␤ at /home/p6eval/niecza/boot/lib/CORE.setting…
LlamaRider r: our %b; say %b.WHAT; 00:23
p6eval rakudo 11157e: OUTPUT«(Any)␤»
LlamaRider r: our $b; say $b.WHAT; 00:24
p6eval rakudo 11157e: OUTPUT«(Any)␤»
LlamaRider hey, at least it's consistent
n: our $s; our @a; our %h; say $s.WHAT; say @a.WHAT; say %h.WHAT;
p6eval niecza v24-31-g7d73dd1: OUTPUT«(Any)␤(Array)␤(Hash)␤»
LlamaRider rakudo bug ? 00:25
lue I would think so, unless there's some weird thing about our scope I haven't heard of.
LlamaRider Time for me to learn where to file rakudo bugs then... 00:26
lue email to [email@hidden.address] 00:27
LlamaRider: ^^^
LlamaRider fair enough. I thought there would be a public bug tracker. But email is just fine. 00:28
thanks!
r: our $s; our @a; our %h; say $s.WHAT; say @a.WHAT; say %h.WHAT; 00:29
p6eval rakudo 11157e: OUTPUT«(Any)␤(Any)␤(Any)␤»
lue LlamaRider: It is public, (at rt.perl.org/rt3), but email is the only way to file the bug 00:30
LlamaRider oh. I see.
lue r: our &c; say &c.WHAT; 00:31
p6eval rakudo 11157e: OUTPUT«(Any)␤»
LlamaRider filed :) Now I feel useful. 00:32
00:32 dayangkun joined
lue :) 00:33
LlamaRider curious that there are no "our" examples in the test suite, adding a few might be useful.
colomon LlamaRider: please do! 00:38
LlamaRider oh, I can also suggest test cases? 00:41
colomon you can create test cases. 00:43
LlamaRider By fork-ing github.com/perl6/roast and making pull request to the master? 00:47
colomon yes
LlamaRider got it. Will cook something up then, thanks. 00:48
00:58 thou left 01:00 anuby joined, araujo joined, araujo left, araujo joined 01:05 cognominal left 01:11 am0c joined 01:16 hypolin joined
dalek osystem: 86b7137 | mrhdias++ | META.list:
Adding Imlib2
01:18
osystem: 4522fa1 | (Matthew Wilson)++ | META.list:
Merge pull request #21 from mrhdias/master

Adding Imlib2
colomon woah, beat me to it! ;)
diakopter :)
01:24 ozmq joined 01:33 zby_home_ joined 01:36 ozmq left
diakopter ...YAWN 01:39
tadzik but the META.info is rong :) 01:40
diakopter oh.. 01:41
tadzik I've already sent the pull request
that's plenty of good code over there
mrhdias++ indeed
01:51 tokuhiro_ joined 01:56 zby_home_ left 01:57 fgomez joined 02:17 gdey left 02:18 lustlife joined 02:24 ozmq joined 02:33 erkan left 02:40 nebuchadnezzar joined 03:13 orafu left, orafu joined 03:19 gdey joined 03:32 gdey left 03:41 Uakh joined 03:53 xilo_ joined 03:56 xilo_ left 04:16 LlamaRider left 04:19 bonsaikitten joined 04:21 _sri joined 04:32 rafl joined 04:35 SamuraiJack joined 04:36 dayangkun left 04:37 nothing_ joined, hulu joined, nothing_ is now known as Guest4559 04:38 Guest4559 left 04:44 isomorphisms joined 04:45 hulu left 04:50 dayangkun joined 04:51 daniel-s joined 04:56 preflex_ joined 04:57 preflex left, preflex_ is now known as preflex 05:04 Gwyxx joined 05:11 dayangkun left 05:13 jaldhar_ joined 05:14 kbenson joined
kbenson Can someone help me figure out what the correct build environment is for Rakudo on Parrot for windows? 05:16
05:17 quester joined
kbenson I always get an error or two during the configure stage of a perl Configure.pl --gen-parrot, and it eventually errors out 05:21
05:22 xilo_ joined
kbenson Specifically, this test always seems to cause a "test_####.exe has failed" window to pop up: 05:23
auto::isreg - Does your C library have a working S_ISREG...........no.
05:26 xilo_ left 05:27 lorn joined 05:37 lorn left 05:38 lorn joined 05:43 ozmq left 05:45 SamuraiJack left 05:46 thou joined
diakopter kbenson: still around? 05:48
kbenson yeah, and I think I figured it out
diakopter cool. what compiler/perl ended up working?
kbenson Looks like mingw doesn't like parens in the %path% environ, and since I'm on a 64 bit machine, my path is littered with C:\Program Files (x86) entries 05:49
I'm looking to manually set a pared down path to see if that fixes it, but this stackoverflow entry seems to fit my error perfectly: stackoverflow.com/questions/1209011...-exception 05:50
05:52 ozmq joined 05:59 dayangkun joined 06:04 rindolf joined 06:05 wk left
kbenson yeah, that was it 06:11
Unfortunately it's a pain to work around since git is in a path with parens... 06:12
so I had to manually track down the build command to rakudo/nqp, and then manually run perl Configure.pl --with-parrot=..\install\bin\parrot.exe to generate the make file, then used perl to negative grep path entries with a paren, writ ethe set command to a batch file to run, and run it (since windows has horrible copy/paste semantics in the command prompt) 06:14
but it's building. :)
err, now that's an odd bug: 06:19
C:\Users\kbenson\rakudo>make 06:20
NQP is too old (2013.02.1-65-g2694596 required), run something like ...
but I built nqp. And if I check NQP's version:
C:\Users\kbenson\rakudo>install\bin\nqp.exe -v
This is nqp version built on parrot 4.10.0 revision RELEASE_4_10_0
somehow it doesn't know it's own version number 06:21
06:32 rindolf left
raiph kbenson: fwiw i googled for site:irclog.perlgeek.de/perl6 "This is nqp version built" -> irclog.perlgeek.de/perl6/2011-07-20#i_4143599 06:40
kbenson d'oh 06:41
raiph kbenson: does it shed any light on your situation?
kbenson It's using the git tag in the version number. Since git is in one of the bad paths I removed so gmake was happy, it's not available, and thus the portion that generates the version fails.
Thanks! That saves me some time. So now I either need to get a better make, or put git in a path that doesn't have parens. 06:42
06:45 xinming_ joined 06:49 xinming left
moritz maybe just having a 'git' shell script in PATH earlier helps 06:50
and that one just execs the one in the path with parens
kbenson probably
06:52 hulu joined
hulu helo 06:52
say ~<abstract Concrete>.sort:-> $a, $b { uc($a) leg uc($b) }; 06:53
kbenson I'll try that, but I have a feeling that there may be complications. I believe git likes to call out to a lot of other shell utils (which is one reason msysgit comes with a LOT of unix utils)
06:53 sqirrel joined
hulu what's means of say ~<abstract Concrete>.sort:-> $a, $b { uc($a) leg uc($b) }; 06:53
kbenson Depending on what git's actually used for, thay may also be expected to be in the path...
06:54 isomorphisms left
hulu who can help me 06:54
moritz has a deja-vu 06:56
diakopter :D 06:57
hulu i need help
kbenson looks like the new improved mklink in windows vista and later may be my savior
raiph r: say ~<abstract Concrete>.sort: -> $a, $b { uc($a) leg uc($b) }; 06:58
p6eval rakudo 11157e: OUTPUT«abstract Concrete␤»
raiph r: say <foo bar>.sort 06:59
p6eval rakudo 11157e: OUTPUT«bar foo␤»
hulu raiph, what diff between "say ~<abstract Concrete>.sort:-> $a, $b { uc($a) leg uc($b) };" "say ~<abstract Concrete>.sort; 07:00
"
raiph hulu: not much. shorter version uses default sorting logic. with the longer version you are providing the sort function. 07:02
07:02 tokuhiro_ left, tokuhiro_ joined 07:03 FROGGS joined 07:05 quester left
hulu raiph, thx 07:06
raiph, what's means sort :-> $a
raiph sort is a method
hulu :-> what's means 07:07
07:07 tokuhiro_ left
raiph following a method with : says you want to pass some args 07:07
note how the : follows the method name, and then there is a space 07:08
so it:-> 07:09
hulu { uc($a) leg uc($b) } is args?
raiph it's part of one arg
hulu what's one arg 07:10
raiph in this case the arg is -> $a, $b { uc($a) leg uc($b) } 07:11
hulu r: say ~<abstract Concrete kkk>.sort:-> $a, $b { uc($a) leg uc($b) }; 07:12
p6eval rakudo 11157e: OUTPUT«===SORRY!===␤Two terms in a row␤at /tmp/TQ6hKEaymk:1␤------> say ~<abstract Concrete kkk>.sort⏏:-> $a, $b { uc($a) leg uc($b) };␤ expecting any of:␤ method arguments␤ postfix␤ infix or meta-infix␤ …
hulu r: say ~<abstract Concrete kkk>.sort:-> $a, $b, $c { uc($a) leg uc($b) }; 07:13
p6eval rakudo 11157e: OUTPUT«===SORRY!===␤Two terms in a row␤at /tmp/BBj2jjKJob:1␤------> say ~<abstract Concrete kkk>.sort⏏:-> $a, $b, $c { uc($a) leg uc($b) };␤ expecting any of:␤ method arguments␤ postfix␤ infix or meta-infix␤ …
hulu r: say ~<abstract Concrete kkk>.sort:-> $a, $b, $c { uc($a) leg uc($b) leg uc($c)};
raiph hulu: you must put a space between the : and the arg (which starts with "->" )
p6eval rakudo 11157e: OUTPUT«===SORRY!===␤Two terms in a row␤at /tmp/UsddXWh_a_:1␤------> say ~<abstract Concrete kkk>.sort⏏:-> $a, $b, $c { uc($a) leg uc($b) leg u␤ expecting any of:␤ method arguments␤ postfix␤ infix or meta-infix␤ …
hulu r: say ~<abstract Concrete kkk>.sort : -> $a, $b, $c { uc($a) leg uc($b) leg uc($c)};
p6eval rakudo 11157e: OUTPUT«===SORRY!===␤Two terms in a row␤at /tmp/KJCwKrAwVV:1␤------> say ~<abstract Concrete kkk>.sort ⏏: -> $a, $b, $c { uc($a) leg uc($b) leg ␤ expecting any of:␤ method arguments␤ postfix␤ infix or meta-infix␤…
hulu raiph, not run
r: say ~<abstract Concrete kkk>.sort : -> $a, $b, $c { uc($a) leg uc($b)}; 07:14
p6eval rakudo 11157e: OUTPUT«===SORRY!===␤Two terms in a row␤at /tmp/3d4nyJEyNt:1␤------> say ~<abstract Concrete kkk>.sort ⏏: -> $a, $b, $c { uc($a) leg uc($b)};␤ expecting any of:␤ method arguments␤ postfix␤ infix or meta-infix␤ …
raiph hulu: and none between the method and the :
hulu r: say ~<abstract Concrete kkk>.sort : -> $a, $b, $c { uc($a) leg uc($b)};
p6eval rakudo 11157e: OUTPUT«===SORRY!===␤Two terms in a row␤at /tmp/_ldbFEBLEw:1␤------> say ~<abstract Concrete kkk>.sort ⏏: -> $a, $b, $c { uc($a) leg uc($b)};␤ expecting any of:␤ method arguments␤ postfix␤ infix or meta-infix␤ …
hulu raiph, not run
FROGGS r: say ~<abstract Concrete kkk>.sort: -> $a, $b, $c { uc($a) leg uc($b)};
p6eval rakudo 11157e: OUTPUT«Not enough positional parameters passed; got 2 but expected 3␤ in block at /tmp/NiKgu4WETi:1␤␤»
hulu r: say ~<abstract Concrete kkk>.sort : -> $a, $b, $c { uc($a) leg uc($b) }; 07:15
p6eval rakudo 11157e: OUTPUT«===SORRY!===␤Two terms in a row␤at /tmp/cYlDA_daJV:1␤------> say ~<abstract Concrete kkk>.sort ⏏: -> $a, $b, $c { uc($a) leg uc($b) };␤ expecting any of:␤ method arguments␤ postfix␤ infix or meta-infix␤ …
hulu not run
FROGGS r: say ~<abstract Concrete kkk>.sort: -> $a, $b { uc($a) leg uc($b) };
p6eval rakudo 11157e: OUTPUT«abstract Concrete kkk␤»
raiph hulu: sort: not sort : # no space between sort and :
hulu r: say ~<abstract Concrete kkk>.sort: -> $a, $b, $c { uc($a) leg uc($b) leg uc($c)};
p6eval rakudo 11157e: OUTPUT«===SORRY!===␤Operators 'leg' and 'leg' are non-associtiave and require parenthesis␤at /tmp/zW8jTvROhx:1␤------> sort: -> $a, $b, $c { uc($a) leg uc($b) ⏏leg uc($c)};␤ expecting any of:␤ postfix␤ infix or meta-in…
hulu raiph, not run 07:16
FROGGS hulu: read the error message
07:16 cognominal joined
FROGGS r: say ~<abstract Concrete kkk>.sort: -> $a, $b, $c { (uc($a) leg uc($b)) leg uc($c)}; 07:16
p6eval rakudo 11157e: OUTPUT«Not enough positional parameters passed; got 2 but expected 3␤ in block at /tmp/4JwA3DOBBj:1␤␤»
07:16 hulu left
FROGGS sort only gives two args 07:17
raiph hulu: doc.perl6.org/routine/sort # if you pass a function to the sort method, that function must accept either one or two args (the one you started with used two) 07:19
07:20 hulu joined
FROGGS <raiph> hulu: doc.perl6.org/routine/sort # if you pass a function to the sort method, that function must accept either one or two args (the one you started with used two) 07:22
hulu r: say ~<abstract Concrete kkk>.sort: -> $a, $b { (uc($a) leg uc($b)) leg uc($c)}; 07:23
p6eval rakudo 11157e: OUTPUT«===SORRY!===␤Variable '$c' is not declared␤at /tmp/VxKC7dzvOm:1␤------> > $a, $b { (uc($a) leg uc($b)) leg uc($c⏏)};␤ expecting any of:␤ postfix␤»
hulu r: say ~<abstract Concrete kkk>.sort: -> $a, $b { (uc($a) leg uc($b))};
p6eval rakudo 11157e: OUTPUT«abstract Concrete kkk␤»
hulu r: say ~<abstract Concrete kkk TGGG>.sort: -> $a, $b { (uc($a) leg uc($b))};
p6eval rakudo 11157e: OUTPUT«abstract Concrete kkk TGGG␤»
hulu FROGGS, how to pass function to sort 07:24
r: say ~<abstract kkk Concrete TGGG>.sort: -> $a, $b { (uc($a) leg uc($b))};
p6eval rakudo 11157e: OUTPUT«abstract Concrete kkk TGGG␤»
raiph hulu: do you see a private msg window i started with you? 07:26
hulu rafl, no
raiph, not
raiph type the following: /msg raiph hi
07:30 ozmq left 07:52 ObseLeTe joined 07:53 kbenson left 07:56 cognominal left, SamuraiJack joined
moritz r: say <abstract kkk Concrete TGGG>.sort: &uc 07:57
p6eval rakudo 11157e: OUTPUT«abstract Concrete kkk TGGG␤»
FROGGS r: say <abstract kkk Concrete TGGG>.sort: &chars 07:58
p6eval rakudo 11157e: OUTPUT«kkk TGGG abstract Concrete␤»
FROGGS morning moritz
moritz \o FROGGS
hulu r: say <abstract kkk Concrete TGGG>.sort: *.uc 08:02
p6eval rakudo 11157e: OUTPUT«abstract Concrete kkk TGGG␤»
hulu r: say <abstract kkk Concrete TGGG>.sort: *.chars 08:03
p6eval rakudo 11157e: OUTPUT«kkk TGGG abstract Concrete␤»
hulu moritz, what diff between &uc or *.uc 08:04
moritz hulu: &uc is a function, *.uc creates a function that calls a method on its argument 08:05
but in this case, in the end both do the same
08:05 cognominal joined
hulu what means calls a method on its argument 08:06
moritz which part are you having trouble with?
do you know what a method call is? 08:08
do you know the argument of a function is?
hulu moritz, no
moritz r: say sqrt(9) 08:09
p6eval rakudo 11157e: OUTPUT«3␤»
moritz the 9 is an argument that I pass to the function sqrt
ok?
hulu ok 08:10
who can say chinese 08:11
moritz if you need it said in chinese, it's not ok
hulu moritz, what's means "calls a method on its argument" 08:12
moritz hulu: did you understand what the argument is?
hulu i c 08:13
moritz a "yes" or "no" would be more helpful to me
hulu yes
moritz ok
en.wikipedia.org/wiki/Method_%28co...ramming%29 explains what a method is 08:14
hulu moritz, i c method
moritz then you have it all together now 08:15
hulu i don't know 'a function that calls a method on its argument' 08:16
moritz which part are you having trouble with? 08:17
you know what what an argument is
hulu what's on its argument
moritz a method is always called "on" something
in Perl 6, we call it its invocant
r: say "abc".uc 08:18
p6eval rakudo 11157e: OUTPUT«ABC␤»
moritz here "abc" is the invocant
and I call the method uc on the string "abc"
clear now?
hulu ic
*.uc creates a function that calls a method on its argument 08:19
* is invocant
moritz *.uc is like sub ($x) { $x.uc } 08:20
so * is the argument of the function, and the invocant for .uc
sorear Why don't we curry listops?
uc(*) 08:21
moritz because there are legitimate cases of passing * to listops
pick *, 1..10;
also uc(*) is just &uc
sorear $x = *;
1..*; 08:22
currying is already type-aware enough to make pick *, 1..10 work
hulu so * is the argument of the function, and the invocant for .uc --- why invocant for .uc
moritz because you call the method .uc on it
moritz feels his patience thinning out, and decides to leave the topic before becoming rude 08:23
sorear it just seems inconsistent and wrong that we don't allow substr("0123456789abcdef",*,1)
moritz sorear: currying is only type-aware for infixes, and only by name
sorear: it would be possible to do that if we dropped some of the specialness of * where it's not a curryier 08:24
sorear: I just think that as is, we are at the limit of how magic * can be without being totally confusing 08:26
or maybe we are a bit beyond that limit already 08:27
08:29 hulu left
raiph moritz: p6eval works in channel; /msg p6eval gets me a private p6eval; /msg foo gets me a msg tab shared between me and foo; is there a way i can have a msg tab i share AND use p6eval? 08:31
moritz raiph: you'd have to open a channel for that
raiph: I can make p6eval join other channels for you 08:32
raiph i'm thinking about the likes of hulu where it would be good to be able to jump away from #perl6 and do some messages and evals in private 08:34
moritz I thought so 08:36
but IRC offers only private discussion and channels
there's not much I can do
one thing I could do is to make p6eval follow /invite's
FROGGS #perl6-qa
or #perl6-help 08:37
or so
or #perl6-n00b :o)
moritz: this can be closed, right? rt.perl.org/rt3/Public/Bug/Display...l?id=76744 08:38
moritz FROGGS: when it's tested, yes 08:40
08:40 daxim joined
FROGGS how to test it? 08:40
moritz r: my token a { :dba('fancy name') '(' ~ ')' .* }; '(abc' ~~ /<&a>/
p6eval rakudo 11157e: ( no output )
moritz huh, I thought that one would die 08:41
r: '(abc' ~~ /'(' ~ ')' .*/
p6eval rakudo 11157e: OUTPUT«Unable to parse expression in ; couldn't find final ')'␤ in any FAILGOAL at src/stage2/QRegex.nqp:1084␤ in regex at /tmp/xlSE26SbHW:1␤ in method ACCEPTS at src/gen/CORE.setting:10799␤ in block at /tmp/xlSE26SbHW:1␤␤»
FROGGS r: my token a { :dba('fancy name') '(' ~ ')' .* }; say '(abc' ~~ /<&a>/
p6eval rakudo 11157e: OUTPUT«#<failed match>␤»
moritz r: '(abc' ~~ /:dba('foo') '(' ~ ')' .*/
p6eval rakudo 11157e: ( no output )
moritz oi
the presence of :dba causes the failure to be silent
that's bad
so no, cannot be closed :-)
FROGGS hehe 08:42
i c
moritz but a comment about the new failure mode in the ticket would be helpful
FROGGS I'll add it
08:42 thou left
moritz FROGGS++ 08:43
raiph moritz: thx 08:46
goodnight #perl6 08:47
08:47 raiph left, fhelmberger joined
FROGGS btw, within a month rakudo got about 90 more planned tests, 40 less skipped, 30 less todo, and 156 more passed tests 08:49
still 644 TODOs to go ó.ò
08:49 FROGGS left, FROGGS joined 08:52 marloshouse joined, xinming_ left 08:56 curtispoe joined 08:58 fgomez left 09:01 xinming joined 09:05 Tedd1^ left, hoelzro|away is now known as hoelzro, marloshouse left 09:10 felipe joined 09:11 cognominal left 09:15 not_gerd joined
not_gerd o/ 09:15
phenny: tell jnth I stumbled upon a compilation bug - see gist.github.com/gerdr/5106672 09:16
phenny not_gerd: I'll pass that on when jnth is around.
not_gerd phenny: tell jnthn I stumbled upon a compilation bug - see gist.github.com/gerdr/5106672 09:17
phenny not_gerd: I'll pass that on when jnthn is around.
not_gerd seen jnth
nwc10 is it known that t/spec/S32-num/rat.rakudo fails 4 tests on HEAD? 09:23
not ok 7 - eval Rat.new(1, 3).perl is Rat
# Actual type: Str
not ok 8 - eval Rat.new(1, 3).perl is 1/3
# got: '1/3'
# expected: '0.333333'
and something similar for the next pair which test 1/3 09:24
moritz suspect pmichaud's hand
09:25 ObseLeTe left
nwc10 it is not obvious to me whether the test or the code is more confused. 09:26
moritz it looks like the the first test is right, and the second is wrong 09:27
09:27 kaleem joined
moritz eval $something.perl should round-trip the type 09:27
but doing a string comparison on rats looks misguided to me 09:28
09:34 ObseLeTe joined, dayangkun left 09:38 fgomez joined 09:55 not_gerd left 09:58 dakkar joined 09:59 kivutar joined, Heather joined
Heather tadzik hi 09:59
for [\~] $name.split('/').map({"$_/"}) <- what is it :)
tadzik hello Heather
hm, let's see 10:00
we split $name by '/', getting a list
Heather snippet from panda mkdir
wait a minute... I'll back to it :)
tadzik then we add '/' after each part
and join it all into one big string
...or so I think :P
...I wrote that? :) 10:01
sorear mkdir -p ?
FROGGS this basically just adds a slash at the end if there is none
tadzik yeah, it would seem so 10:02
FROGGS one could write that cleaner I guess :o)
tadzik I don't see it in panda code though
yeah, that's a part of mkdir -p 10:03
I think I borrowed that code from moritz++ actually 10:04
it was shorter and more clever than my original solution
I have to admit I don't fully understand it though :) 10:05
r: say ([\~] <a b c d>).perl 10:06
p6eval rakudo 11157e: OUTPUT«("a", "ab", "abc", "abcd").list␤»
tadzik a-ha!
now that makes sense
10:08 anuby left
Heather here. 10:10
tadzik can I have a beer? 10:11
tadzik Heather: sure
Heather \o/
tadzik you got me there :)
moritz .u beverage
phenny U+2615 HOT BEVERAGE (☕)
moritz what about cold beverage? :-)
tadzik and now we need another Unicode Character Sheet
A PINT OF STOUT, A PINT OF LAGER, A PINT OF PORTER 10:12
Heather mmmm -_-' sweet virtual beer for my imagination o_O my favorite stuff
tadzik Heather: are you coming to Polish Perl Workshop?
Heather tadzik what is that :) 10:13
tadzik act.yapc.eu/plpw2013
a small conference we organize
Heather tadzik today is my first day I use perl
tadzik really? Wow
Heather yes )
tadzik well, no better way to start learning than to contribute to one of the central ecosystem modules :) 10:14
Heather tadzik I had found some masak 's gift on github and it was just cool and I desired to drop python and pick perl )
-_-' 10:15
tadzik welcome aboard :)
10:15 hypolin left
Heather I'm happy to 10:16
tadzik beware, this is Perl 6, still in development, not yet there in its final form
Heather tadzik I will start from it... Don't want to learn perl 5 then learn perl 6 >_<
bonsaikitten you see I'm flawless o_O 10:17
tadzik but I just wanted to write small tool to fill .gitignore or .ignore by using "ignore hello" :) 10:19
tadzik Heather: oh, it's definitely ready enough for that :) 10:20
Heather I wonder why there is still no something alike git ignore but I feel that someone already done this job I want to reinvent :) anyways, I think I need regex dir/fname to get $dir and $fname :)
tadzik when you do, don't hesitate to add it to the module ecosystem 10:21
Heather tadzik so util is not module :S
afk ~ minute
tadzik Heather: doesn't matter, we have plenty of those already 10:22
ufo, for example
it's a good place for applications as well
Heather tadzik yes I already use it -_-' and wrote an gentoo ebuild for it 10:24
tadzik awesome
Heather tadzik next I need to make ebuild for your panda and some other stuff
tadzik Heather: are you familiar with Rakudo Star?
Heather tadzik then I need to write some stuff to automate other stuff but it's later
tadzik no :) just yesterday bonsaikitten said me that I should use rakudo if I want perl6 because I were looking for perl-6 package 10:25
tadzik what is rakudo-star?
tadzik I saw it in gh organization 10:26
tadzik Heather: it's the distribution of Perl 6 containing the compiler plus some useful modules and utils
ufo, panda and more
Heather tadzik so it's alike haskell-platform or ocalm on steroids or .... I get it
*ocaml 10:27
tadzik I'm not sure about what panda can. Does it make most of stuff that cabal do for haskell?
tadzik Heather: I'm not too familiar with haskell, sadly. It makes it easy to install perl6 modules (and tools) 10:29
like 'panda install ufo', for example
it should be capable of installing them to a specified location too
Heather tadzik if so it should be correct to follow gentoo-haskell manner and make a project (later) for automate writing another to-ebuild porter
tadzik it resolves dependencies, runs tests etc
Heather I see then that's it 10:30
10:37 kresike joined
kresike hello all you happy perl6 people 10:37
tadzik hello kresike
kresike tadzik, o/
FROGGS hi kresike 10:42
kresike FROGGS, o/ 10:43
10:44 SamuraiJack left 10:46 labster left
Uakh I'm not a happy perl6 person, but hello nonetheless o/ 10:48
Heather tadzik does unlink remove files? :S 10:52
sorear it _should_ 10:54
10:54 mberends left
tadzik unlink() deletes a name from the file system, says the unix manualu 10:54
I'll trust that :)
Heather why command is called "unlink" 10:55
I mean it sounds not alike rm :) just wonder
sorear dunno, but it's ancient 10:56
Heather sorear I'll try to google history of this 10:57
tadzik Heather: well, why is print called print even though it displays stuff on a screen instead of printing it on a printer? :) 10:58
10:58 mberends joined
sorear as far as I know, the system call has been called unlink but the command has been rm since the beginning of time 10:58
(1970-01-01 :P)
tadzik: because originally it *did* print it on a printer.
Heather I see. 10:59
sorear unix predates video monitors
tadzik sorear: that's it. Hystorical reasons
sorear they used to use teletypes instead
Heather may I ask if understand it correct: find(dir => $path).map({ .Str }).reverse -> $f
I think I understand what it does but not sure if I understand how 11:00
sorear then again, en.wikiquote.org/wiki/Kenneth_Thom...Attributed nr 2
Heather we provide dir as path and then map to extract filename?
tadzik Heather: find() returns objects. If you want them to be strings, you map 11:01
like "turn all those objects into strings"
Heather so map just makes ToString 11:02
tadzik well, in this case it calles the Str() method on all elements 11:03
Heather I see but it ends / in the end of dir
puts /
$.dir ~ '/' ~ $.name
if we use only dir for find then we have no name 11:04
tadzik yes
Heather and we put / to the end of regular file?
tadzik um, no
every file has a name
Heather I mean when I call rm_rf(hello/notfolder)
then hello/notfolder will be passed as dir? 11:05
github.com/tadzik/perl6-File-Tools...and.pm#L27
tadzik nono
thing is, rm_rf can work equally well on plain strings as well as any other objects with .Str method 11:06
11:06 grondilu joined
tadzik for example File::Find::Result 11:06
or whatsitsname
.Str() on a string is a no-op
Heather tadzik then I don't understand how it should make it... 11:07
tadzik how it should make what?
it gets strings, and if not, it turns them into strings 11:08
Heather we make file from dir only, right?
tadzik it doesn't care for slashes, names or whatnot
it checks if it's a directory, with .IO.d
then decides what to do
Heather I see but when it creates result object (file) it's using only dir as constructor 11:09
tadzik isn't it?
tadzik are you talking about find() now, or rm_rf()? 11:10
11:11 not_gerd joined
Heather about find(dir => $path).map({ .Str }).reverse 11:11
tadzik also, I have to get some work done at $dayjob, so I may be a bit unavailable
Heather I understand :)
tadzik oh, find() is not a constructor itself
it gets a dir paramater, then scans the dir inside and produces complete objecs 11:12
you can peek into it, try find(...).perl.say
Heather tadzik what if I use long path to file?
tadzik I dunno, try :)
not_gerd on Rakudo's production-readiness: gist.github.com/gerdr/5107342 11:13
my personal take on it, that is
FROGGS r: $| = 1
p6eval rakudo 11157e: OUTPUT«===SORRY!===␤Unsupported use of $| variable; in Perl 6 please use :autoflush on open␤at /tmp/7gK14oNGNJ:1␤------> $|⏏ = 1␤»
FROGGS I love these hints
Heather unicode? 11:14
grondilu yeah but what if I actually want to use a variable named '$|' 11:15
?
r: my $| = 1; 11:16
p6eval rakudo 11157e: OUTPUT«===SORRY!===␤Unsupported use of $| variable; in Perl 6 please use :autoflush on open␤at /tmp/nZgMuxvVVg:1␤------> my $|⏏ = 1;␤»
11:16 mtk left
FROGGS grondilu: you dont have to want that :P 11:16
grondilu well, on second thought I doubt '|' is a valid variable name anyway. 11:17
FROGGS I believe variables are like / <ident>+ % <['-]> / 11:18
11:18 ObseLeTe left 11:19 mtk joined 11:28 rindolf joined 11:34 SamuraiJack joined 11:41 araujo left
Heather why m/[^\/]+$/ doesn't work :( 11:42
felher Heather: I didn't read the backlog so I might be just wrong about what you are trying to achieve, but in Perl 6, the notiation for character classes is '<-[\/]>' 11:44
not_gerd r: say "foo/bar/baz" ~~ /<-[\/]>+$/
p6eval rakudo 11157e: OUTPUT«「baz」␤␤»
Heather felipe I just want separate filename and path
^ should get last thing if I understand correct... 11:45
moritz regex syntax has changed 11:46
but why not use $path.split('/')[*-1]
felher Heather: it works as not_gerd++ showed: The '-' in front of the '[\/]' means to negate the character class '[\/
yeah, an what moritz said ^^ :) 11:47
moritz also I don't think you need to escape / in a char class
Heather what is [*-1]
-1 from end? 11:48
e.g. last
felher The first from the end, yes :)
moritz r: say IO::Path('/home/moritz/README.txt').basename
p6eval rakudo 11157e: OUTPUT«Could not find symbol '&Path'␤ in method <anon> at src/gen/CORE.setting:10517␤ in at src/gen/Metamodel.pm:2488␤ in any find_method_fallback at src/gen/Metamodel.pm:2476␤ in any find_method at src/gen/Metamodel.pm:925␤ in at src/gen/BOOTSTRAP.pm:895␤ in any …
moritz eeks, that doesn't work with the bot
because the bot removes all IO stuff
Heather moritz ah... there is .basename? 11:49
moritz but locally
> say IO::Path.new('/home/moritz/README.txt').basename
README.txt
Heather: in IO::Path, yes
Heather moritz that's what I miss :)
moritz (you don't need to load any modules to use it) 11:50
Heather now I understand more but still feel some confusion
moritz github.com/tadzik/perl6-File-Tools...ind.pm#L49 11:51
moritz may you explain where .basename cuts from $dir?
does .basename itself performs $dir change? 11:52
tadzik oh gods, my code written with tabs /o\
moritz Heather: no 11:53
Heather: IO::Path objects are stored as path + basename
Heather: and if you call IO::Path.new($file), then the method new splits $file, and stores them path and basename
Heather tadzik it's mixed tabs in one file and spaces in another file -_-' 11:54
tadzik even worse :|
moritz but dir() already returns IO::Path objects, so you don't have to care about that
Heather tadzik yep
moritz so dir cuts basename from dir? 11:55
moritz finally I get it :D
I hope... 11:56
but it's not looking very clear where filename goes from dir string :P 11:57
No, it fails : Failed to get the directory contents of 'ignore': readdir failed: Not a directory 12:00
tadzik seems like filename doesn't separate itself from directory with find(dir => $path) 12:01
felher Whats bad about tabs? I still prefer them over spaces. I don't see any problems with that, as long as you don't mix 'em :) 12:02
12:02 chee joined
Heather there are some problems with tabs... 12:02
12:02 wk joined
Heather felher general tabs trouble is they are the same lengh 12:03
kresike is curious about the problems with tabs too
arnsholt felher: I prefer spaces. That's what wrong with 'em =)
Heather felher with spaces I have much more freedom and safety
felher arnsholt: I don't like spaces because they tend to look the same in everybody's editor. But I like indention to be 8 spaces wide. Most other people use 4-spaces. If the code is indented via tabs, I can display tabs as 8 spaces, they can display tabs as 4 spaces. If they are real spaces, I'm stuck with 4 spaces wether I want or not :) 12:06
arnsholt: true, this isn't such a big deal. It's not that I just HATE spaces. I just prefer tabs when I can use them :)
arnsholt True. I like four spaces; eight is too much for me, but two (I'm looking at you lispers!) is way too narrow
Yeah, I'm not terribly dogmatic about it either 12:07
But mixed tabs and spaces are an abomination =)
felher arnsholt: yeah, indeed :)
Heather I will try to understand how IO Path works in evening :) For now, see you. 12:08
felher o/ Heather
Heather o/ 12:09
12:10 Heather left 12:13 SmokeMachine joined 12:18 araujo joined, araujo left, araujo joined 12:21 erkan joined, erkan left, erkan joined 12:25 dayangkun joined 12:27 woolfy joined 12:33 xinming left 12:35 robinsmidsrod left, xinming joined
FROGGS jnthn / moritz / pmichaud: how do I profile rakudo itself? 12:36
12:37 robinsmidsrod joined
moritz has no idea 12:37
FROGGS :/ 12:38
not_gerd FROGGS: there's --profile for P6-level profiling 12:40
for C-level profiling, you can use callgrind
FROGGS hmmm
and the levels between? *g*
not_gerd afaik both can be visualized with KCachegrind
not_gerd has never done so himself
FROGGS okay, callgrind might be an option then 12:41
thanks not_gerd
12:46 skids left 12:56 robinsmidsrod left, robinsmidsrod joined 13:05 gdey joined 13:11 Targen left 13:16 gdey left 13:24 Pompel left, stevan__ left 13:25 stevan_ joined, stevan_ left 13:42 Pompel joined 13:51 wtw joined 13:55 daxim left 13:57 daxim joined
colomon is pondering how much work it would be to port Python's matplotlib to p6.... 13:58
13:59 brrt joined
moritz quite some 14:00
14:00 kivutar left 14:03 kaare__ joined 14:08 Targen joined
colomon pugs: say 1.75.perl 14:10
p6eval pugs: OUTPUT«7/4␤»
colomon r: say 1.75.perl 14:11
p6eval rakudo 11157e: OUTPUT«1.75␤»
colomon r: say 1.752.perl 14:12
p6eval rakudo 11157e: OUTPUT«1.752␤»
colomon rn: say pi.Rat(1e-10).perl
p6eval rakudo 11157e, niecza v24-31-g7d73dd1: OUTPUT«<312689/99532>␤»
colomon rn: say 3.14.Rat.perl 14:13
p6eval rakudo 11157e, niecza v24-31-g7d73dd1: OUTPUT«3.14␤»
colomon rn: say pi.Rat.perl
p6eval rakudo 11157e, niecza v24-31-g7d73dd1: OUTPUT«<355/113>␤»
not_gerd r: gist.github.com/gerdr/2659460 14:14
p6eval rakudo 11157e: OUTPUT«42/1 = 42.0␤1/5 = 0.2␤-4/3 = -1.(3)␤19/12 = 1.58(3)␤1/97 = 0.(010309278350515463917525773195876288659793814432989690721649484536082474226804123711340206185567)␤»
14:15 PacoAir joined 14:17 bluescreen10 joined
dalek ast: 64b9d5f | (Solomon Foster)++ | integration/advent2009-day14.t:
Change tests to match current spec, unfudge Rakudo tests that now work (I think).
14:18
grondilu rn: say pi.Rat.perl # how does perl decide which rational approximation it should take?
p6eval rakudo 11157e, niecza v24-31-g7d73dd1: OUTPUT«<355/113>␤»
grondilu say pi, 355/113 14:19
rn:say (pi - 355/113)/pi
14:19 Uakh left
grondilu rn: say (pi - 355/113)/pi 14:19
14:19 Uakh joined
p6eval niecza v24-31-g7d73dd1: OUTPUT«-8.49136787674061E-08␤» 14:20
..rakudo 11157e: OUTPUT«-8.49136787674061e-08␤»
14:20 Gwyxx left
FROGGS rn: say pi 14:20
p6eval rakudo 11157e: OUTPUT«3.14159265358979␤»
..niecza v24-31-g7d73dd1: OUTPUT«3.1415926535897931␤»
FROGGS rn: say 355/113
p6eval rakudo 11157e, niecza v24-31-g7d73dd1: OUTPUT«3.141593␤»
grondilu I know 355/113 is a pretty good approximation of pi, but how does P6 knows it?
14:21 brrt left
grondilu is it hard coded or something? 14:21
colomon grondilu: not in the least
rn: say pi
p6eval rakudo 11157e: OUTPUT«3.14159265358979␤»
..niecza v24-31-g7d73dd1: OUTPUT«3.1415926535897931␤»
colomon rn: say pi.WHAT
p6eval niecza v24-31-g7d73dd1: OUTPUT«Num()␤»
..rakudo 11157e: OUTPUT«(Num)␤»
colomon hey, what? 14:22
14:22 Psyche^ joined
grondilu is confused 14:22
colomon hmmm, p6eval's niecza is significantly out of date
grondilu: p6 defines the constant pi to be a Num (ie floating point)
If you convert a Num to a Rat, it finds a nearby rational 14:23
rn: my @precs = .1, .01, .001 ... *; for @precs[^10] -> $prec { say pi.Rat($prec); }; 14:24
14:24 dayangkun left
p6eval niecza v24-31-g7d73dd1: OUTPUT«(timeout)» 14:24
..rakudo 11157e: OUTPUT«3.142857␤3.142857␤3.141509␤3.141509␤3.141593␤3.141593␤3.141593␤3.141593␤3.141593␤3.141593␤»
14:24 xinming left
colomon forgot the .perl 14:24
14:24 kaleem left
colomon rn: my @precs = .1, .01, .001 ... *; for @precs[^10] -> $prec { say pi.Rat($prec).perl; }; 14:24
rn: my @precs := .1, .01, .001 ... *; for @precs[^10] -> $prec { say pi.Rat($prec).perl; }; 14:25
p6eval niecza v24-31-g7d73dd1: OUTPUT«(timeout)»
..rakudo 11157e: OUTPUT«<22/7>␤<22/7>␤<333/106>␤<333/106>␤<355/113>␤<355/113>␤<103993/33102>␤<103993/33102>␤<103993/33102>␤<312689/99532>␤»
rakudo 11157e: OUTPUT«<22/7>␤<22/7>␤<333/106>␤<333/106>␤<355/113>␤<355/113>␤<103993/33102>␤<103993/33102>␤<103993/33102>␤<312689/99532>␤»
..niecza v24-31-g7d73dd1: OUTPUT«3.2␤<22/7>␤3.140625␤<333/106>␤<355/113>␤<355/113>␤<75948/24175>␤<100798/32085>␤<103993/33102>␤<312689/99532>␤»
colomon there we go
ever tighter rational approximations to pi
14:25 Patterner left, Psyche^ is now known as Patterner
colomon note that Niecza and Rakudo do not necessarily choose the same approximation 14:26
14:26 xinming joined
colomon rn say pi - pi.Rat(0.1) 14:26
rn: say pi - pi.Rat(0.1)
p6eval rakudo 11157e: OUTPUT«-0.00126448926734968␤»
..niecza v24-31-g7d73dd1: OUTPUT«-0.058407346410207062␤»
colomon rn: say pi - pi.Rat(1e-10) 14:27
p6eval rakudo 11157e: OUTPUT«-2.91433543964104e-11␤»
..niecza v24-31-g7d73dd1: OUTPUT«-2.9143354396410359E-11␤»
grondilu ok 14:32
14:40 dayangkun joined 14:41 dayangkun left, dayangkun joined 14:44 crab2313 joined, not_gerd left
dalek ast: 5a0824c | (Solomon Foster)++ | S0 (3 files):
Fudge for Niecza.
14:46
rjbs "Perl 6: Holy grail or utopia?" 15:01
Not such a bad choice!
15:01 LlamaRider joined
moritz graily utopia! 15:01
15:08 n0den1te joined 15:09 xilo left
masak rjbs: my thought, too. I went "hm, one of these should be the bad one, right. which one is it?" 15:12
I mean, there's nothing about the word "utopia" that says "doesn't exist", right? :P
n0den1te r: my @ppl = <moritz Heather hulu tadzik>; for @ppl -> $x { say "$x++"; }; # learning adventures++
p6eval rakudo 11157e: OUTPUT«moritz++␤Heather++␤hulu++␤tadzik++␤»
masak ooh, karma by evalbot. 15:13
n0den1te masak: that's not quite true - karma tracker still tracks it. :)
15:14 alester joined, n0den1te is now known as isBEKaml
masak sure. didn't want to imply it didn't. 15:15
moritz feels hilighted
isBEKaml felt happy watching the exchange on backlog today. 15:16
rjbs masak: I almost don't want to read the piece, because I like not knowing which is the bad one. 15:17
isBEKaml I still follow channel happenings on perl6 land, even as other stuff keeps me away. IR clogs are awesome. :)
heh. IR Clogs.
rjbs We'll have to switch to UV.
isBEKaml can't see a thing.
moritz you can switch to UV by prefixing your lines with [off] 15:18
geekosaur ir flipflops?
isBEKaml paddle - paddle
rjbs "Does Perl 6 support UV??"
isBEKaml we should have a bot like Lambdabot that does: "Does Perl6..." YES! 15:19
moritz no, we aren't ultra violent
isBEKaml ultra valent? :P
masak wow, heated newbie explanations in the backlog. 15:20
rjbs: the piece was surprisingly ok. tl;dr: author's hopeful.
isBEKaml masak: exactly. I don't see those often these days. :)
moritz which blog/article are you talking about? 15:21
(rjbs and masak)
rjbs twitter.com/perlbuzz/status/309679738631368706
masak kresimirbojcic.com/2013/02/24/perl-...topia.html
moritz: if you are already tired of hulu, may I suggest not encouraging him by helping him? it seems to upset you. :) 15:22
isBEKaml I can't speak for moritz, I was thinking he was frustrated by the language barrier more than anything else. 15:23
moritz masak: well, I stopped when I tired, so I kinda followed your advise already
masak yeah. I mean sooner than that.
15:24 FROGGS left
moritz probably, yes 15:24
15:25 xilo joined
isBEKaml wow, that article reads like the author intended to make some curry but wound up with something that looks vaguely like curry but tastes real bad! :P 15:25
masak <Heather> tadzik I had found some masak 's gift on github and it was just cool and I desired to drop python and pick perl )
wait what what? :)
isBEKaml (profuse apologies for the bad analogy)
masak my gift?
isBEKaml masak: s & f are so close. :P 15:26
masak isBEKaml: I kinda liked the article ;)
15:26 daxim left
masak isBEKaml: sure, it wasn't a masterpiece, but... 15:26
isBEKaml masak: well, I kinda get irritated when everyone feels like they have their authority to write opinion pieces but end up with fluff. :) 15:29
15:30 isomorphisms joined, Targen left
masak isBEKaml: Yeah, well, you know, that's just, like, your opinion, man. 15:30
;)
isBEKaml o.O(where did that Lebowski come from? ) 15:31
15:31 Targen joined
masak (apparently "The Big Lebowsky" turned 15 yesterday!) 15:31
that movie really tied the room together.
isBEKaml masak: that rug really tied the room together. I still don't know why I sat through that movie. :P 15:32
masak it's a hidden gem.
and probably an acquired taste, too. 15:33
isBEKaml milk dreams. :)
15:36 PacoAir left
LlamaRider I am wondering if porting P5 to P6 regexps that are not my own wasn't a huge mistake... I can still stop and use the compatibility mode... 15:38
15:38 Targen left
LlamaRider and it's hard to tell if I am improving them, since the new regexps are my own now, so clearly I understand them better 15:39
masak LlamaRider: you sound exactly like me back in 2005, porting my first CPAN module to p6. 15:41
LlamaRider masak: It's been THAT long?
masak en kol chadásh táchat hashámesh :)
heh, that phrase itself is thousands of years old... ;) 15:42
isBEKaml masak: millions :) 15:43
if you count the sun - he/she'd be weary by now. :) 15:44
masak: btw, was that hungarian or hebrew?
masak Hebrew, unfashionably rendered into Latin script.
no, the *phrase* isn't millions of years old. 15:45
isBEKaml masak: thought so, "hashamesh" didn't sound like hungarian, but google was confused between the two.
geekosaur doesn't think he's seen accents used for stress in hebrew transliteration before... 15:46
masak it was from wiktionary. 15:47
isBEKaml masak: (I know this gets old...) are you reviving WTOP? :)
15:49 isomorphisms left
isBEKaml should get to packaging an R* build for slackware. put on weekend task... 15:49
update parrot's and add rakudo too on SBo. 15:50
15:52 cognominal joined
masak isBEKaml: haven't thought about WTOP in a long time. I'm not sure it's so relevant any more. 15:54
isBEKaml: moritz has/had a project that got further, IIRC. 15:55
moritz perl6/wtop on github, iirc
isBEKaml I remember reading about it long time back and letting out an evil laugh. :) 15:56
masak moritz: nope.
moritz oh, moritz/perl6-wtop 15:57
isBEKaml r: sub circumfix:<begin end>($x) { say "$x - yay!"; }; begin"Hello"end;
p6eval rakudo 11157e: OUTPUT«Hello - yay!␤»
15:57 cognominal__ joined
isBEKaml masak: have you seen this? It blows up when you add a space. 15:57
15:57 cognominal left
isBEKaml r: sub circumfix:<begin end>($x) { say "$x - yay!"; }; begin "Hello" end; 15:57
p6eval rakudo 11157e: OUTPUT«===SORRY!===␤Two terms in a row␤at /tmp/jMCPH4Pqm2:1␤------> $x) { say "$x - yay!"; }; begin "Hello" ⏏end;␤ expecting any of:␤ postfix␤ infix or meta-infix␤ infix stopper␤ statement end␤ sta…
moritz long known, afacit 15:58
isBEKaml moritz: it was a recent bug filed #116739
15:59 kivutar joined
moritz where "long" is O(weeks) 15:59
isBEKaml moritz: :D # telling on my disappearances. 16:00
moritz: Okay, how do I go about fixing this? 16:01
moritz isBEKaml: 1) find out why it's misparsing it 2) fix it 16:02
kresike bye folks
dalek p: cb38e50 | (Arne Skjærholt)++ | src/6model/reprs/VMArray.c:
Clean up VMArray a bit.
16:02 kresike left
moritz n: sub circumfix:<begin end>($x) { say "$x - yay!"; }; begin "Hello" end; 16:02
p6eval niecza v24-31-g7d73dd1: OUTPUT«Hello - yay!␤»
moritz isBEKaml: look at niecza for inspiration :-)
isBEKaml moritz: so nobody knows? :)
moritz isBEKaml: well, most bugs require some debugging before fixing them 16:03
isBEKaml moritz: I tried to do it the day I sent out that mail - but my give-up-threshold was quite low. :(
masak "I don't want to understand the problem, I just want to fix it!"
16:03 FROGGS[mobile] joined 16:04 REPLeffect left
TimToady
.oO(cargo cult debugging...)
16:04
16:06 spider-mario joined
colomon cargo cult++ 16:07
FROGGS[mobile] btw, callgrind is pretty cool
isBEKaml wait, what? we espouse blind coding? :P
arnsholt Callgrind is flat-out fantastic
hoelzro what's the proper way to have a "dummy" argument in Perl 6?
in Haskell, one would use _
TimToady you mean a dummy formal parameter? 16:08
arnsholt std: sub($a, $, $b) { ... } # I think
p6eval std 692eb4f: OUTPUT«===SORRY!===␤Variable $a is not predeclared at /tmp/cTKArEMWWm line 1:␤------> sub(⏏$a, $, $b) { ... } # I think␤Unsupported use of $, variable; in Perl 6 please use .join() method at /tmp/cTKArEMWWm line 1:␤------> sub($a, $…
TimToady we usually reserve "argument" for the real values coming it
*n
arnsholt std: sub foo($a, $, $b) { ... } # I think
p6eval std 692eb4f: OUTPUT«Potential difficulties:␤ $b is declared but not used at /tmp/8TdFeKMWR4 line 1:␤------> sub foo($a, $, ⏏$b) { ... } # I think␤ $a is declared but not used at /tmp/8TdFeKMWR4 line 1:␤------> sub foo(⏏$a, $, $b) { ... } # I think…
arnsholt Apparently not 16:09
hoelzro yes
TimToady std: sub foo ($, @, %) {...}
p6eval std 692eb4f: OUTPUT«ok 00:00 43m␤»
arnsholt Oh, right. Those were unused variable warnings, not errors
TimToady it's not complaining about the...yeah
arnsholt That settles it. Time for me to go home =)
See you all later =)
TimToady is already home, having just got out of bed...
hoelzro also, I can have proto method manage-window(Window $w, Str $class, Str $name) { * } and multi method manage-window(Window $w, 'Firefox', Str $name) { ... }
16:10 stevan_ joined
hoelzro how would I define the equivalent multi method for proto method manage-window(Window $w, Str :$class, Str :$name) { * }? 16:10
there was a discussion in #perl on how no one writes window managers anymore, so I thought it might be a neat exercise =)
arnsholt multi method manage-window(:class<Firefox>) I think
But, going home 16:11
o/
TimToady o/ 16:12
you'd need the $w arg too
since it's not optional in the prototype
moritz \o TimToady
TimToady 's half brane that is awake waves back 16:13
the other side hit the snooze button
lesse, I waved with my left hand, so it must be my right brane that is awake 16:14
masak a yoga teacher I once had said that the half branes take turn being active in ~2 h periods during the day. 16:15
[citation needed]
TimToady was your yoga teach a porpoise?
*er 16:16
masak .oO( a question entirely without porpoise )
hoelzro multi method manage-window(Window $w ( $class )) # this should automatically alias $class to $w.class, right? 16:17
or am I doing it wrong?
masak TimToady: no. though he was a mammal.
TimToady was he finnish?
hoelzro: yer doin' in rwong
hoelzro I figured =( 16:18
TimToady multi method manage-window(Window $w, :class($class)) {...} # belike
hoelzro I'm trying to accomplish what this example does: sub traverse ( BinTree $top ( $left, $right ) )
I know I just switching the method signature, but I'm thinking that having $w and $class is redundant 16:19
TimToady multi method manage-window(Window $w, :$class) {...} # shorter, same thing
hoelzro and I'd like to see if I can use the signature binding stuff to work against just a window argument
TimToady doesn't know what's in $w 16:20
FROGGS[mobile] "uu"?
hoelzro so, I'm musing about a Perl 6 window manager
I thought it would be cool to define the config file as a role that implements certain hooks
TimToady certainly if $w contains something that can look like a capture, then you can unpack it with a subsignature 16:21
hoelzro one of which would be manage-window
TimToady but then I wouldn't use that proto, if the :$class is redundant
hoelzro ok, lemme paste what I have
TimToady most protos these days just use (|) to allow anything
the BinTree works because something inside $bin is Positional 16:22
hoelzro gist.github.com/hoelzro/5109267 16:23
o_O
maybe that gist will clarify what I'm trying to do...
TimToady okay, then you want something more like (Window $w ( :$class ))
a method can be subsigged, but it takes a named parameter, not a positional like BinTree 16:24
16:24 stevan__ joined
hoelzro ahhhh 16:24
16:25 Targen joined
TimToady I don't think we've specced literals there in a named arg (probably oughta) 16:25
LlamaRider Does anyone have a quick idea of the P6 equivalent of the regexp ['"] (in P5) ?
TimToady so (Window $w ( :$class where 'Firefox' ) ) might be as close as you can get currently
hoelzro ok, that's good enough
TimToady LlamaRider: in general, just add <> around it
so <['"]>
LlamaRider thanks! 16:26
TimToady if it's complemented, you hav emore work
so [^'
[^'"] turns into <-['"]>
hoelzro TimToady: do I have to make Window 'also does Positional' for that binding to work?
16:26 gdey joined
TimToady no 16:26
not unless you are implementing Array semantics
hoelzro hmm 16:27
this signature isn't cutting it: multi method manage-window(Window $w ( :$class )) {
TimToady maybe you've found a bug then
16:27 stevan_ left
hoelzro =) 16:28
cognominal__ masak: en.wikipedia.org/wiki/Nasal_cycle
masak cognominal__: yep. the nostrils were involved, too, I recall. 16:29
cognominal__ irrelevant to me due to my chronic rhinitis
masak :/ 16:30
hoelzro whence comes perl6.c? 16:37
is it part of the PIR -> exe?
TimToady looks to me like it's not successfully converting a Window to a Capture so it can bind the subsig
16:39 Gwyxx joined
TimToady either that, or something is busted in the subsig end of it; if I force the second sig to not match by adding a param, I get: 16:39
Cannot call 'manage-window'; none of these signatures match:
:(WindowManager : Window $w :(:class(:$class)), Mu *%_)
:(WindowManager : Window $w, Int , Mu *%_)
that subsig looks a little odd
16:39 gdey left
TimToady btw, with that same code, niecza reports "Unable to resolve method Capture in type Window" 16:40
hoelzro interesting 16:41
TimToady huh, if I bind the subsig as |subsig and print it out, it gives: 16:43
Capture.new( list => ().list, hash => EnumMap.new("name", "Firefox", "class", "Firefox", ))
which seems about right
16:44 not_gerd joined
not_gerd hoelzro: try multi method manage-window(Window $w ( :$class where 'Firefox', *% )) 16:44
TimToady that doesn't work either here
hoelzro not_gerd: that did it! 16:45
I wish that were implied
not_gerd it's implied in the top signature, but not in sub sigs
hoelzro hmm
why not? =)
not_gerd no idea 16:46
16:46 Targen left
not_gerd you end up writing things like ( $ (:$foo!, *%), *% where !*) 16:46
LlamaRider Ok, now I need to port (?!\d) to P6. That's a negative zero-width lookahead. Is that to become <?!before \d> ? 16:47
hoelzro I wish *% were implied for sub signatures 16:48
I have a feeling you can make it be implied, though =)
(at least for a subset of methods)
16:48 Targen joined
FROGGS[mobile] LlamaRider: <!before \d> 16:49
LlamaRider Hm... both <?!before \d> and <!before \d> work 16:50
TimToady got it; it wants :$name too
multi method manage-window(Window $w ( :$class where 'Firefox', :$name ) )
hoelzro ah
TimToady or a *% inside the ()
16:50 fhelmberger left
hoelzro so you *must* capture all of the fields 16:50
not_gerd hoelzro: in sub-sigs, yes 16:51
TimToady it doesn't automatically add the *% like it does at the top level
hoelzro damn
next step: figure out how to make Perl 6 add *%
;)
16:52 gdey joined
not_gerd does (Window $w (:$class where 'Firefox', |) work as well? 16:52
saves a char ;) 16:53
TimToady yes
so does making $!name private :) 16:54
LlamaRider Is there a simple difference between <?before> , <!before> and <?!before> ? I am reading S05 but I need to stare at it some more.
TimToady | also has the advantage of maybe doing less owrk 16:55
work, even
? contributes to (and terminates) LTM
! is transparent to LTM
so !! is like ? but transparent 16:56
16:56 skids joined
TimToady hasn't seen ?! in real life 16:56
16:56 gdey left, hoelzro is now known as hoelzro|away
TimToady doesn't see it in S05 either 16:56
LlamaRider ?! was a fruit of rewriting (?!\d) into something that still has ?! -- but it seems to behave just like <!before> although I don't have enough tests to claim that 16:57
FROGGS[mobile] write it down then :o)
TimToady sure, the ? is a no-op in that case
except for maybe terminating LTM
16:58 stevan__ left
TimToady oh wait, you're meaning (?! from p5 16:58
duh
that's just <!before...>, yeah
16:58 crab2313 left
LlamaRider I think I understood enough of that to be useful :> thanks. 16:59
TimToady in general the ? of (?...) goes away
it's just the p5 equivalent of the extensible <...> p6 syntax
16:59 SunilJoshi joined
TimToady needs more coffee... 16:59
17:00 stevan_ joined
TimToady either that, or breakfast, so I stop believing impossible things... 17:01
I think a good case can be made for always compiling in an implicit *% into a subsig match 17:06
otherwise you code becomes extremely prejudiced against derived classes that add members 17:07
not_gerd agrees 17:08
but I'd also like to see a shortcut for *% where !*
sometimes, I *don't* want the implicit *%
17:09 Targen left
TimToady I can see that; not sure what to do about it though, offhand 17:09
17:11 SmokeMachine left
LlamaRider Another gotcha for porting regexps is to -1 on each $1,$2 variable... hadn't noticed it until now. 17:12
TimToady std: $1; 17:13
p6eval std 692eb4f: OUTPUT«ok 00:00 41m␤»
17:13 Chillance joined
TimToady std: /()$1/ 17:13
p6eval std 692eb4f: OUTPUT«===SORRY!===␤Null pattern not allowed at /tmp/sYfm_b5Sg5 line 1:␤------> /(⏏)$1/␤ expecting any of:␤ regex atom␤ statement end␤ statement list␤Parse failed␤FAILED 00:00 41m␤»
TimToady std: /(x)$1/
FROGGS[mobile] LlamaRider: right
p6eval std 692eb4f: OUTPUT«ok 00:00 43m␤»
FROGGS[mobile] hmmm, this could warn
17:14 SmokeMachine joined
TimToady it's a bit hard, since, /(x)(y)$1/ i sfine 17:14
*is fine
17:15 lestrrat joined
FROGGS[mobile] well, you have to check how many () are there 17:15
TimToady should we spec a .permutations method to go with .combinations?
17:16 dakkar left
FROGGS[mobile] whats that? 17:16
colomon TimToady: +1
TimToady: have you looked at List::Utils::combinations yet?
TimToady nope
feel free to look at it for me :)
TimToady is still backlogging, y'see 17:17
(and not succeeding :)
TimToady already distracted himself with the backlog on RC...where he noticed 'permutations' 17:18
not_gerd ponders allowing prefix ? and ! on parameters as shorthand for `where ?*`/`where !*` 17:20
probably too confusing
colomon TimToady: err, I sort of wrote it, so my looking at it would not be particularly helpful. ;) 17:21
TimToady probably
colomon: :)
not_gerd
.oO( !$:foo? )
TimToady or worse, !$!foo! 17:22
colomon TimToady: I believe it's to spec (except for being a sub rather than a method). But I was hoping to get some feedback before I went and plopped it into a p6 compiler (or two?) and roast.
TimToady or worse, !:$!foo!
colomon: well, if you plop it first, you're probably a bit likelier to get feed back from #perl6 :P 17:24
not_gerd
.oO( more bang for the buck )
colomon TimToady: you're probably right.
TimToady is probably right by definition, probably... 17:25
17:25 pmurias joined
colomon TimToady: also my tests are probably too thorough for roast. need more smarts to figure out how to quickly check for correctness. 17:25
TimToady well, better too many tests than too few...
colomon TimToady: Also the code is slow in some cases. I got the appropriate Knuth after I wrote it, haven't had a chance to properly digest it. 17:26
are you implying I can get the best feedback results if I insert it into both niecza and rakudo at the same time, forcing everyone to live with my implementation or find something better?
TimToady part of the reason for defining these as builtins is so that the appropriate Optimization Hammer can be whacked upon them 17:27
nr: say [1,2,3].combinations
p6eval rakudo 11157e: OUTPUT«No such method 'combinations' for invocant of type 'Array'␤ in block at /tmp/MZpOHgl4Mt:1␤␤»
..niecza v24-31-g7d73dd1: OUTPUT«Unhandled exception: Unable to resolve method combinations in type Array␤ at /tmp/_1ag_6Udd8 line 1 (mainline @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4284 (ANON @ 3) ␤ at /home/p6eval/niecza/lib/CORE.setting line 4285 (module-CORE @ 581) ␤ …
TimToady I don't see how it's any worse than the current situation :)
also, my motivation is to make RC entries look snazzier, so it doesn't really matter if they're fast, for that purpose :) 17:28
the whole P6 store right now is 'lovely programmer API, and maybe fast someday too!' 17:29
*story
17:29 SunilJoshi left
LlamaRider r: my token foo { 'foo' } 'bar' ~~ /<-foo>/ ?? say "YES" !! say "NO" ; 17:29
p6eval rakudo 11157e: OUTPUT«===SORRY!===␤Two terms in a row␤at /tmp/jmYsqOjxpR:1␤------> my token foo { 'foo' } ⏏'bar' ~~ /<-foo>/ ?? say "YES" !! say "N␤ expecting any of:␤ scoped declarator␤ new name to be defined␤ single quotes␤ …
LlamaRider r: my token foo { 'foo' }; 'bar' ~~ /<-foo>/ ?? say "YES" !! say "NO" ;
p6eval rakudo 11157e: OUTPUT«No such method 'foo' for invocant of type 'Cursor'␤ in regex at /tmp/Eqse9bk6v5:1␤ in method ACCEPTS at src/gen/CORE.setting:10799␤ in block at /tmp/Eqse9bk6v5:1␤␤»
LlamaRider I am not supposed to negate tokens? 17:30
TimToady r: my token foo { 'foo' } 'bar' ~~ /<-&foo>/ ?? say "YES" !! say "NO" ;
p6eval rakudo 11157e: OUTPUT«===SORRY!===␤Two terms in a row␤at /tmp/zkaUOI_HWh:1␤------> my token foo { 'foo' } ⏏'bar' ~~ /<-&foo>/ ?? say "YES" !! say "␤ expecting any of:␤ scoped declarator␤ new name to be defined␤ single quotes␤ …
TimToady r: my token foo { 'foo' }; 'bar' ~~ /<-&foo>/ ?? say "YES" !! say "NO" ;
p6eval rakudo 11157e: OUTPUT«===SORRY!===␤Unrecognized regex metacharacter < (must be quoted to match literally)␤at /tmp/cicnoyugQV:1␤------> my token foo { 'foo' }; 'bar' ~~ /<-⏏&foo>/ ?? say "YES" !! say "NO" ;␤Unrecognized regex metacharacter - (must be …
TimToady you might have to put it into a grammar to get it to recognize <-foo> 17:31
17:31 isBEKaml left
TimToady I don't think the <-...> syntax admits &foo currently 17:31
LlamaRider Ok, I will try with a grammar then. Would be cool if modules had implicit grammars in their namespace :) 17:32
TimToady r: my token foo { 'foo' }; 'bar' ~~ /<!&foo>./ ?? say "YES" !! say "NO" ;
p6eval rakudo 11157e: OUTPUT«YES␤»
TimToady that works though
LlamaRider o_O
TimToady well <-...> is equivalent to <!...> with a . after
17:32 n0den1te joined, n0den1te is now known as isBEKaml
TimToady match one char that is not ... 17:33
17:33 chonky joined
TimToady and <&foo> is how you call a token that is defined as a 'sub' rather than a method in a grammar 17:33
LlamaRider just had an "aaahaaa" moment 17:34
cool!
I guess the next question is whether I should file a rakudobug, for <-foo>
TimToady <-foo> might work in a grammar 17:35
I wouldn't expect it to work where <foo> wouldn't work
which it shouldn't here
17:35 chonky left
TimToady r: my token foo { 'foo' }; 'bar' ~~ /<foo>/ ?? say "YES" !! say "NO" ; 17:35
p6eval rakudo 11157e: OUTPUT«NO␤» 17:36
TimToady hmm
was expecting it to blow up
r: my token foo { 'foo' }; 'foo' ~~ /<foo>/ ?? say "YES" !! say "NO" ;
p6eval rakudo 11157e: OUTPUT«YES␤»
TimToady it's a bug that that works :)
LlamaRider :>
I thought the idea was that you can match against tokens wherever, not only in a grammar 17:37
17:37 n0den1te joined
TimToady n: my token foo { 'foo' }; 'foo' ~~ /<foo>/ ?? say "YES" !! say "NO" ; 17:37
p6eval niecza v24-31-g7d73dd1: OUTPUT«===SORRY!===␤␤Ternary !! seems to be missing its ?? at /tmp/HteXRVM0Y8 line 1:␤------> foo' }; 'foo' ~~ /<foo>/ ?? say "YES" !!⏏ say "NO" ;␤␤Parse failed␤␤»
LlamaRider otherwise why would they be allowed to be declared outside of one?
17:38 thou joined
TimToady because maybe you want to define them as a sub and then poke them into a metaclass somewhere, I suppose 17:38
or you want to call them with <&foo> like a subroutine
17:38 Uakh_ joined
LlamaRider I see. I guess the <&foo> vs <foo> distinction isn't really implemented right now 17:38
17:39 Shozan joined
LlamaRider or at least not too strictly enforced 17:39
TimToady ooh, and rakudo seems to be botching the parse of ??!!
n: my token foo { 'foo' }; 'foo' ~~ /<foo>/ ?? say("YES") !! say("NO");
p6eval niecza v24-31-g7d73dd1: OUTPUT«YES␤»
TimToady say is a listop, so eats the !! 17:40
LlamaRider haha, so I took 2 bugs and made a feature :)))
17:40 SmokeMac_ joined
TimToady ??!! is not supposed to allow looser precedence ops inside, and say is looser on the right side 17:40
17:41 awwaiid joined, diakopte1 joined
TimToady nr: 42 ?? 43 or 44 !! 45 17:41
p6eval rakudo 11157e: OUTPUT«===SORRY!===␤Found ?? but no !!␤at /tmp/EvLj7cv4Of:1␤------> 42 ?? 43 ⏏or 44 !! 45␤Confused␤at /tmp/EvLj7cv4Of:1␤------> 42 ?? 43 ⏏or 44 !! 45␤ expecting any of:␤ postfix␤ infix or meta-infix␤…
..niecza v24-31-g7d73dd1: OUTPUT«===SORRY!===␤␤Precedence of or is too loose to use between ?? and !!; please use parens around inner expression at /tmp/YBIMkqgvhT line 1:␤------> 42 ?? 43 or⏏ 44 !! 45␤␤Parse failed␤␤»
TimToady r: my token foo { 'foo' }; 'foo' ~~ /<foo>/ ?? say("YES") !! say("NO"); 17:43
p6eval rakudo 11157e: OUTPUT«YES␤»
TimToady nr: 'foo' ~~ /<foo>/ ?? say("YES") !! say("NO"); my token foo { 'foo' };
p6eval niecza v24-31-g7d73dd1: OUTPUT«Potential difficulties:␤ &foo is declared but not used at /tmp/R045q8IClL line 1:␤------> ? say("YES") !! say("NO"); my token foo ⏏{ 'foo' };␤␤Unhandled exception: Unable to resolve method foo in type Cursor␤ at /tmp/R045q8IClL line 1 … 17:44
..rakudo 11157e: OUTPUT«No such method 'foo' for invocant of type 'Cursor'␤ in regex at /tmp/qE3YLv6zqU:1␤ in method ACCEPTS at src/gen/CORE.setting:10799␤ in block at /tmp/qE3YLv6zqU:1␤␤»
TimToady maybe we changed how that worked; brane fuzzy
TimToady checks the spec
17:45 isBEKaml left, SmokeMachine left, Uakh left, SHODAN left, awwaiid_ left, diakopter left, mattp_ left, phenny left 17:46 wk left
TimToady yes, S05:1476 gives preference to the lexically scoped name 17:47
in that case, it's a bug that <-foo> doesn't work
r: my token foo { 'foo' }; say 'bar' ~~ /<foo>/ ?? "YES" !! "NO" ; 17:48
p6eval rakudo 11157e: OUTPUT«NO␤»
TimToady r: my token foo { 'foo' }; say 'bar' ~~ /<-foo>/ ?? "YES" !! "NO" ;
p6eval rakudo 11157e: OUTPUT«No such method 'foo' for invocant of type 'Cursor'␤ in regex at /tmp/UeQxU9CDCL:1␤ in method ACCEPTS at src/gen/CORE.setting:10799␤ in block at /tmp/UeQxU9CDCL:1␤␤»
TimToady n: my token foo { 'foo' }; say 'bar' ~~ /<-foo>/ ?? "YES" !! "NO" ;
p6eval niecza v24-31-g7d73dd1: OUTPUT«Potential difficulties:␤ &foo is declared but not used at /tmp/thi3DlXG1d line 1:␤------> my token foo ⏏{ 'foo' }; say 'bar' ~~ /<-foo>/ ?? "YES␤␤Unhandled exception: Unable to resolve method foo in type Cursor␤ at /tmp/thi3DlXG1d line…
TimToady yeah, I'd call that a buglet in both n and r
nr: my token foo { 'foo' }; say 'bar' ~~ /<!foo>./ ?? "YES" !! "NO" ; 17:49
p6eval rakudo 11157e, niecza v24-31-g7d73dd1: OUTPUT«YES␤»
TimToady ? and ! are defined recursively back to <assertion>, but + and - apparently are not
nr: my token foo { 'foo' }; say 'bar' ~~ /<+foo>/ ?? "YES" !! "NO" ; 17:50
p6eval niecza v24-31-g7d73dd1: OUTPUT«Potential difficulties:␤ &foo is declared but not used at /tmp/mW5IPVYsCe line 1:␤------> my token foo ⏏{ 'foo' }; say 'bar' ~~ /<+foo>/ ?? "YES␤␤Unhandled exception: Unable to resolve method foo in type Cursor␤ at /tmp/mW5IPVYsCe line…
..rakudo 11157e: OUTPUT«No such method 'foo' for invocant of type 'Cursor'␤ in regex at /tmp/s5BgtWuOWS:1␤ in method ACCEPTS at src/gen/CORE.setting:10799␤ in block at /tmp/s5BgtWuOWS:1␤␤»
17:50 PacoAir joined, Uakh_ is now known as Uakh
TimToady they can't be recursively defined, since they have different terminators 17:50
but foo should act more like it does for a bare <foo> 17:51
17:51 sergot joined, mattp_ joined
TimToady especially since <-&foo> doesn't parse currently 17:51
[Coke] Speaking of different terminators, we'll be getting another one with arnold, I think. ;) 17:53
17:53 cognominal__ left
TimToady he said he'd be back 17:53
FROGGS[mobile] hehe
17:56 bluescreen10 left 18:03 diakopte1 is now known as diakopter
not_gerd is `?$!list || ?$!hash` the right thing to do in Rakudo's setting? 18:04
should I write that as `$!list || $!hash ?? True !! False`
LlamaRider ok, I have a P6 port of Lingua::EN::Sentence with 1 almost-working test case :> 18:06
\o/
not something anyone terribly needs, but it was a very nice warm-up module.
off to $dayjob, thanks for all the support 18:09
18:09 LlamaRider left
not_gerd github.com/rakudo/rakudo/pull/110 courtesy of the guthub web interface 18:10
18:12 wk joined
nwc10 jnthn: NQP-JVM still works (apart from the ICU test under parrot) on "my" machine at nqp HEAD (cb38e5059b9e2dba75b49ef23f5351857bcd53fe) 18:12
18:13 am0c left 18:16 cognominal joined 18:17 lichtkind__ joined
pmichaud (lexical scope regexes) we never actually resolved that issue, iirc. 18:19
I'll recheck the spec, though. 18:20
18:20 lichtkind_ left 18:22 fgomez left
pmichaud last I heard there was speculation of a braid for grammars, and that "my token ..." would derive a new grammar containing the lexically scoped token declarations... or something like that. 18:23
18:23 PacoAir left
pmichaud as written, S05 would mean that: my token foo { ... }; grammar G { token foo { ... }; token bar { <foo> } }; would have bar prefer the lexically-scoped rule to the one inside the grammar. 18:24
18:26 cognominal left
pmichaud TimToady: ^^^ 18:27
18:27 PacoAir joined, FROGGS[mobile] left 18:28 FROGGS[mobile] joined
TimToady pmichaud: in such a case you'd have to use <.foo> to disambiguate, I suppose 18:31
pmichaud or <foo=.foo> to do a capture?
TimToady yes, but it feels a lot like a DIHWIDT to me 18:32
one is supposed to have a certain amount of control over one's lexical environment :)
I suppose it could be argued that people will write crap like this and then expect it to read their minds... 18:33
diakopter nqp: sub fib($n) { $n < 2 ?? $n !! fib($n-1) + fib($n - 2) }; my $N := 29; my $t0 := nqp::time_n(); my $z := fib($N); my $t1 := nqp::time_n(); nqp::say("fib($N) = " ~ fib($N)); nqp::say("time = " ~ ($t1-$t0));
p6eval nqp: OUTPUT«fib(29) = 514229␤time = 2.62717294692993␤»
diakopter nqp-jvm: sub fib($n) { $n < 2 ?? $n !! fib($n-1) + fib($n - 2) }; my $N := 29; my $t0 := nqp::time_n(); my $z := fib($N); my $t1 := nqp::time_n(); nqp::say("fib($N) = " ~ fib($N)); nqp::say("time = " ~ ($t1-$t0));
p6eval nqp-jvm: OUTPUT«fib(29) = 514229␤time = 0.7400000095367432␤»
pmichaud I wonder if there's any surprise coming from importing a token declaration into the lexical scope and having subrules change as a result. 18:34
again, might be DIHWIDT for that too
TimToady well, exporting a token is probably right up there with moving your arm the wrong way 18:35
pmichaud any lexical sub in scope, or just those explicitly declared regex/token/rule? 18:36
TimToady at least importing a token into a grammar won't leak into the grammar's methods
so people won't be tempted to use importation over derivation etc
or delegation
well, it won't work if the signature is wrong in any case 18:37
so I'm inclined to say it's by name, not by ruleness
pmichaud my sub alpha() { ... }; grammar XYZ { token foo { <alpha> } };
TimToady kaboom, presumably
pmichaud that simplifies things a bit on the implementation side, then. 18:38
TimToady nr: my sub alpha() { ... }; grammar XYZ { token TOP { <alpha> } }; XYZ.parse("abc").perl.say 18:39
p6eval niecza v24-31-g7d73dd1: OUTPUT«Potential difficulties:␤ &alpha is declared but not used at /tmp/tTQVzuhPQC line 1:␤------> my sub alpha⏏() { ... }; grammar XYZ { token TOP { <a␤␤Match␤»
..rakudo 11157e: OUTPUT«Match.new(orig => "abc", from => 0, to => 1, ast => Any, list => ().list, hash => EnumMap.new("alpha", Match.new(orig => "abc", from => 0, to => 1, ast => Any, list => ().list, hash => EnumMap.new()), ))␤»
pmichaud at the moment rakudo doesn't make any attempt to connect <alpha> to &alpha, iirc.
TimToady nr: my token alpha() { ... }; grammar XYZ { token TOP { <alpha> } }; XYZ.parse("abc").perl.say 18:40
p6eval niecza v24-31-g7d73dd1: OUTPUT«#<match from(0) to(3) text(abc) pos([].list) named({"alpha" => #<match from(0) to(3) text(abc) pos([].list) named({}.hash)>}.hash)>␤»
..rakudo 11157e: OUTPUT«Match.new(orig => "abc", from => 0, to => 3, ast => Any, list => ().list, hash => EnumMap.new("alpha", Match.new(orig => "abc", from => 0, to => 3, ast => Any, list => ().list, hash => EnumMap.new()), ))␤»
TimToady nr: my token foo() { ... }; grammar XYZ { token TOP { <foo> } }; XYZ.parse("abc").perl.say
p6eval niecza v24-31-g7d73dd1: OUTPUT«#<match from(0) to(3) text(abc) pos([].list) named({"foo" => #<match from(0) to(3) text(abc) pos([].list) named({}.hash)>}.hash)>␤»
..rakudo 11157e: OUTPUT«Match.new(orig => "abc", from => 0, to => 3, ast => Any, list => ().list, hash => EnumMap.new("foo", Match.new(orig => "abc", from => 0, to => 3, ast => Any, list => ().list, hash => EnumMap.new()), ))␤»
pmichaud oh, perhaps I'm wrong then :)
TimToady nr: my token foo() { ... }; /<foo>/ 18:41
p6eval rakudo 11157e, niecza v24-31-g7d73dd1: ( no output )
TimToady nr: my sub foo() { ... }; /<foo>/
p6eval niecza v24-31-g7d73dd1: OUTPUT«Potential difficulties:␤ &foo is declared but not used at /tmp/DjZQuyjoha line 1:␤------> my sub foo⏏() { ... }; /<foo>/␤␤»
..rakudo 11157e: ( no output )
TimToady nr: my sub foo() { ... }; say 'abc' ~~ /<foo>/
p6eval rakudo 11157e: OUTPUT«No such method 'foo' for invocant of type 'Cursor'␤ in regex at /tmp/2tra_028r7:1␤ in method ACCEPTS at src/gen/CORE.setting:10799␤ in block at /tmp/2tra_028r7:1␤␤»
..niecza v24-31-g7d73dd1: OUTPUT«Potential difficulties:␤ &foo is declared but not used at /tmp/z896n1uxkE line 1:␤------> my sub foo⏏() { ... }; say 'abc' ~~ /<foo>/␤␤Unhandled exception: Unable to resolve method foo in type Cursor␤ at /tmp/z896n1uxkE line 1 (ANON @ …
TimToady it does there
oh wait 18:42
pmichaud no, it's doing it for the grammar but not for the bare regex
TimToady nr: my token foo() { ... }; say 'abc' ~~ /<foo>/
p6eval rakudo 11157e, niecza v24-31-g7d73dd1: OUTPUT«「abc」␤ foo => 「abc」␤␤»
pmichaud oh, hmm.
TimToady nr: my token foo() { xxx }; say 'abc' ~~ /<foo>/ 18:43
p6eval rakudo 11157e, niecza v24-31-g7d73dd1: OUTPUT«#<failed match>␤»
pmichaud okay, someone must've added that mapping in while I wasn't looking :)
TimToady nr: my token foo() { xxx }; grammar XYZ { token TOP { <foo> } }; XYZ.parse("abc").perl.say
p6eval rakudo 11157e: OUTPUT«Match.new(orig => "abc", from => 0, to => -3, ast => Any, list => ().list, hash => EnumMap.new())␤»
..niecza v24-31-g7d73dd1: OUTPUT«Match␤»
pmichaud ummmmmmmmmmm
I have no clue what's going on, then. 18:44
TimToady it did call the lexical there
which is why it didn't match
pmichaud oh
it returned a failed Match object. got it.
I'm used to seeing #<failed match> for some reason. 18:45
TimToady yes, and that's why we're changing it to return Nil instead of Match
pmichaud okay, I'm just behind on current implementation status, then. Not too surprising.
TimToady no problem, I was behind on spec status earlier today, and I *wrote* it 18:46
pmichaud I agree that <-foo> is a buglet, then.
is <.foo> always the method form?
TimToady yes, so maybe <-.foo> should also be allowed 18:47
18:47 skids left
pmichaud what's the non-capturing form of the lexical regex, then? 18:47
TimToady along with <-&foo>
pmichaud is it <&foo> ? 18:48
TimToady yes
pmichaud <.foo> # always method call
TimToady nodnod
pmichaud I should write up a table
writing.
TimToady yes, just rewrite the rest of S05 while you're there, if you don't mind :) 18:49
18:49 SamuraiJack left
TimToady suspects pmichaud++ won't mind me at all :) 18:50
pmichaud gist.github.com/pmichaud/5110668 # first start
colomon meant to write another blog post on parse, match, etc, but didn't get it done this morning, and is now engaged in a discussion of the finer points of the Battle of Hoth with a 4-year-old 18:51
diakopter Han shot first
colomon not in the Battle of Hoth! 18:52
TimToady He certainly shot first in the Raiders of the Lost Ark, where he was playing Harrison Ford 18:53
pmichaud no, I don't plan to rewrite the rest of S05. I'm still on the hook for S07.
colomon pmichaud: back above, it would have returned failed match, but there was a .perl in there. 18:56
pmichaud colomon: thanks
colomon++
I'm definitely way behind on some of the spec changes. Of course, that's always been true, but it's moreso than usual for me these days.
I'm still hoping for a tuit supply in the relatively near future
colomon rn: say "hello" ~~ /a/ 18:57
p6eval rakudo 11157e, niecza v24-31-g7d73dd1: OUTPUT«#<failed match>␤»
colomon rn: say ("hello" ~~ /a/).perl
p6eval rakudo 11157e: OUTPUT«Match.new(orig => "hello", from => 5, to => -3, ast => Any, list => ().list, hash => EnumMap.new())␤»
..niecza v24-31-g7d73dd1: OUTPUT«Match␤»
pmichaud maybe Match.perl should be adjusted there :) 18:58
time for me to depart again... bbl 18:59
TimToady o/
19:00 LlamaRider joined
arnsholt masak: You around? 19:02
masak arnsholt: yesish. 19:06
arnsholt: how may I serve you? 19:07
arnsholt Just a tiny Esperanto question =) 19:08
19:08 FROGGS[mobile] left
arnsholt I'd like to put "eighth lecture" on the front of my lecture slides. Could you translate for me? 19:08
19:08 FROGGS[mobile] joined
masak arnsholt: "Oka prelego" 19:09
arnsholt Brilliant. Cheers!
masak++ # .eo
masak arnsholt: ('ok'='eight', '-a' makes ordinals out of numerals, 'preleg-'='lecture', '-o'=noun ending) 19:10
19:11 stevan_ left
arnsholt That makes sense (which is the point, I believe =) 19:11
masak Esperanto is occasionally non-insane ;)
arnsholt Can preleg be decomposed into pre-leg as well?
19:11 stevan_ joined
arnsholt (The Indo-Europeanist in me wants that to be the case) 19:12
19:12 fgomez joined
masak not intrinsically, no. 'preleg-' is the root. 19:13
but 'legi' means 'to read', so clearly there's a relation, even though it's not through a prefix ;)
n0den1te arnsholt: there are eight *lectures* to go through? :) 19:15
gah...
19:15 n0den1te is now known as isBEKaml
masak I'm not sure what 'pre-' would mean here if t'were a prefix. 19:15
isBEKaml: and not until the eighth do they get to Esperanto... :P
isBEKaml masak: It'd be pointless if they were never exposed to .eo. :P 19:16
19:17 fgomez left
masak speaking of points, what's with the '.' before 'eo'? it's not a TLD :P 19:17
isBEKaml masak: I'm lazy. 19:18
arnsholt isBEKaml: Well, I went through the first seven the seven previous fridays =) 19:19
masak: Good point. Because reasons, I suppose =D
masak ;) 19:20
arnsholt: suddenly I want to see your lextures :D
isBEKaml first seven seven previous... lextures. hmmmm
arnsholt: I had to read that several times to understand. :P 19:21
arnsholt: talk of lectures, what would I know? :)
arnsholt masak: The lectures themselves aren't taped, but the slides are on www.uio.no/studier/emner/matnat/ifi...-sted.html =) 19:23
masak \o/ 19:24
19:24 sqirrel left
isBEKaml arnsholt: NLTK & python? nice.. :) 19:26
arnsholt Yeah, it's not too bad 19:27
Although I ran into a pile of annoyances when I wanted to deal with Unicode text
isBEKaml arnsholt: are you stuck on python 2.x? I have heard those mentioned only on 2.x versions.
arnsholt: looks like python folks have cleaned up their act in py 3.x versions. 19:28
arnsholt My students are in their first-year and mostly very new to programming, so any additional hurdles to cope with are kind of significant
Yeah, the University IT department hasn't moved over to Python 3, so none of that for me
19:29 fgomez joined
arnsholt Particularly annoying was \b in regexes applied to a Unicode string still having ASCII semantics 19:29
not_gerd TimToady: re signatures again, I can't really think of anything better besides using + and - as prefix instead of ? and !
forcing exact signature matches then would look like (..., -|)
isBEKaml arnsholt: new to programming and NLTK already? do they have any prior background in linguistics or anything like that?
TimToady how 'bout :| for a grim face :) 19:30
arnsholt New to programming (one semester of Java is all we can count on) and completely new to linguistics for the most part
Some students will have more experience with programming and/or linguistics, but for most of them we can't assume much
isBEKaml imagines arnsholt running after kids... 19:31
arnsholt I must admit that when I talk about my students with my colleagues, I do occasionally refer to them as "the kids" =) 19:32
isBEKaml arnsholt: :) - that they are 19:34
arnsholt You teach as well? 19:35
isBEKaml I never taught. 19:36
19:37 FROGGS[mobile] left
TimToady isBEKaml: the begin/end thing is probably a difference in tie-breaking between two different rules that match an identifier at the same length 19:37
the tiebreaking is supposed to pick a literal 'begin' over a \w+ thing, but maybe that's busted in rakudo
dalek rl6-roast-data: 2858d28 | coke++ | / (4 files):
today (automated commit)
19:38
isBEKaml TimToady: I'll check, thanks. 19:39
[Coke] niecza ticked up another failure.
rakudo clean, 4 days running.
isBEKaml [Coke]: do you run counts of how many days of 'cleanliness' we maintain? :P 19:40
arnsholt isBEKaml: It's interesting, but very challenging as well 19:44
isBEKaml arnsholt: NLTK or teaching? 19:45
arnsholt Especially introductory-level teaching I find is challenging in that you have to drop a lot of assumptions you can rely on when talking to more experienced people
Teaching. I don't really use NLTK in my work =) 19:46
isBEKaml arnsholt: Ah, teaching is always hard. Though I never taught, I occasionally held one-to-one sessions and found myself wishing I can see how much stuff they understood so I can calibrate what I give them. :) 19:47
arnsholt Oh, definitely that! 19:48
After a lecture, I really don't have any clue if they understood nothing at all or everything or something in between >.<
isBEKaml arnsholt: unfortunately, people are never straightforward with that stuff - so first attempts are always massive failures. :) 19:49
arnsholt: (even as I ask them "how much do you know/understand" - "I understand a fair bit" - "Vague") 19:50
arnsholt Yeah. And sometimes things need a bit of time to develop in your brain before you start to get it 19:51
And lectures are a bit crap for instilling knowledge anyways...
isBEKaml arnsholt: knowledge is an intensely inward process - how would it help if you just watched a video and suddenly you're an expert? :P 19:52
colomon rn: say %*ENV.gist 19:54
p6eval rakudo 11157e: OUTPUT«("PERLBREW_VERSION" => "0.42", "MAIL" => "/var/mail/p6eval", "USER" => "p6eval", "SHLVL" => "1", "HOME" => "/home/p6eval", "OLDPWD" => "/home/p6eval", "PERLBREW_ROOT" => "/home/p6eval/perl5/perlbrew", "PERLBREW_MANPATH" => "/home/p6eval/perl5/perlbrew/perls/perl-5.…
..niecza v24-31-g7d73dd1: OUTPUT«{"HOME" => "/home/p6eval", "LANG" => "en_US.UTF-8", "LD_LIBRARY_PATH" => "/usr/local/mono-2.10.1/lib", "LOGNAME" => "p6eval", "LS_COLORS" => "rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:su=37;41:sg=30;43:ca=3…
colomon rn: say %*ENV.perl 19:55
p6eval rakudo 11157e: OUTPUT«("PERLBREW_VERSION" => "0.42", "MAIL" => "/var/mail/p6eval", "USER" => "p6eval", "SHLVL" => "1", "HOME" => "/home/p6eval", "OLDPWD" => "/home/p6eval", "PERLBREW_ROOT" => "/home/p6eval/perl5/perlbrew", "PERLBREW_MANPATH" => "/home/p6eval/perl5/perlbrew/perls/perl-5.…
..niecza v24-31-g7d73dd1: OUTPUT«{"HOME" => "/home/p6eval", "LANG" => "en_US.UTF-8", "LD_LIBRARY_PATH" => "/usr/local/mono-2.10.1/lib", "LOGNAME" => "p6eval", "LS_COLORS" => "rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:su=37;41:sg=30;43:ca=3…
masak wow, that was pretty noisy. 19:56
LlamaRider Hm, can I do cool things like add methods to default types, such as Str? I want to do $s.sentences just like $s.words
masak LlamaRider: 'augment class Str { method sentences { ... } }'
jnthn home
masak jnthn! \o/
jnthn masak! \o/
Gee, it's a little windy here :) 19:57
masak here too. 19:58
LlamaRider: requires 'use MONKEY_PATCHING' first though. just so you know you're doing something bad.
isBEKaml what does this line mean: <?[<]> <quote_EXPR: ':q', ':w'> 19:59
what exactly does quote_EXPR stand for?
LlamaRider bad? But it's really cool! :> Also, how do I grab the actual string from within Str? Where can I expect the source of the Str class?
arnsholt jnthn: Given that VMArray supports native types, d'you think there's the potential for speed gains by using it in NQP/Rakudo?
LlamaRider inspect* not expect
jnthn arnsholt: Well, part of the goal of having it is to support native arrays... :) 20:00
isBEKaml: quote expression
isBEKaml: Rakudo doesn't use it, afaik, but NQP does.
isBEKaml jnthn: elaborate please? :)
masak LlamaRider: 'this'
isBEKaml jnthn: I'm actually looking at NQP.
moritz LlamaRider: nqp::unbox_s($StrObject) gives you the native string 20:01
arnsholt jnthn: Good point, good point =)
masak (but why would you need that for .sentences ?)
moritz LlamaRider: and the Str class is set up in src/Perl6/Metamodel/BOOTSTRAP.pm and in src/core/Str.pm
20:01 kst left
jnthn isBEKaml: Well, it's the thing that parses quotations. 20:02
arnsholt jnthn: Oh, and 'nother question: Do we need QRPA, once we have VMArray in place?
jnthn isBEKaml: 'foo', etc.
arnsholt: Once it's used widely enough, no
LlamaRider: Note that if you write such a method, the string itself is the invocant, that is, self. 20:03
isBEKaml jnthn: the ?< are regex lookaheads? and what do :q and :w play?
jnthn: where can I look these up/
(sorry, I'm asking too many questions today - 0130 hrs here :)
jnthn isBEKaml: HLL::Grammar implements these
src/HLL/Grammar.pm
LlamaRider jnthn: aha! 'self' worked, 'this' didn't
jnthn LlamaRider: this is not C#/Java ;) 20:04
LlamaRider jnthn: hey, it was masak's suggestion :)
jnthn oh! wat, masak? ;-)
LlamaRider also \o/ yay, I actually have a $s.sentences that works! awesome 20:05
arnsholt jnthn: Yeah, that's what I thought. Then I think I'll try to replace some uses of QRPA with VMArray in NQP to iron out most of the kinks in the implementation before I move on with using it in Rakudo =)
jnthn isBEKaml: The meanings of the letters are the same as in Perl 6 quotations.
isBEKaml: e.g. q:w
arnsholt: Well, thing is that we'll need an NQPArray type for that. 20:06
isBEKaml jnthn: great
jnthn arnsholt: Luckly, nqp-jvm has one, already :D
arnsholt Oh, great. Then I can steal that! =D
masak jnthn: this coder must be tired ;) 20:08
LlamaRider: sorry ;)
TimToady obviously you aren't selfish enough 20:09
LlamaRider masak: no worries, this is awesome :) my first test file works perfectly too. Who do I poke to ask for panda to index my module?
jnthn LlamaRider: There's a how to ecosystem page linekd from modules.perl6.org 20:11
20:12 gdey joined
dalek ast: 1816add | (Solomon Foster)++ | S02-magicals/env.t:
Change test to not rely on the direct form of the string generated by .gist or .perl.
20:12
LlamaRider jnthn: step 6 in that guide is "ping someone on IRC" 20:13
tadzik LlamaRider: where's the META.info?
LlamaRider tadzik: sec, let me order things 20:14
masak .oO( "waiter!" ) 20:23
not_gerd bye, #perl6 20:28
20:29 not_gerd left
lue [backlogging] oh, so it's changed from use MONKEY_TYPING ? 20:32
dalek ast: 72aff83 | (Solomon Foster)++ | S05-substitution/subst.t:
Fudge for niecza.
masak lue: no, I got that wrong too. 20:33
it used to be 'MONKEY_PATCHING', before it was 'MONKEY_TYPING'.
lue r: use MONKEY_TYPING; supersede class Str { method foo() { 42; }; }; say Str.foo 20:34
p6eval rakudo 11157e: OUTPUT«===SORRY!===␤Cannot use 'supersede' with class declaration␤at /tmp/oUau4JksmV:1␤------> use MONKEY_TYPING; supersede class Str ⏏{ method foo() { 42; }; }; say Str.foo␤ expecting any of:␤ scoped declarator␤ gener…
lue I forgot if there was an explanation for why one can't supersede classes. 20:36
masak something to do with bounded serialization, I think. 20:37
LlamaRider masak: Can I sanely compare two arrays using Test? with is_deeply or something of the sort? I am getting a huge dump of the array and I would like to see a diff of only the elements that don't match up. 20:39
masak LlamaRider: is_deeply will just give you match/not match. 20:40
LlamaRider: if you want to diff, maybe create your own subroutine that creates the diff, and then test for an empty diff? 20:41
(using 'is', which will output expected/actual if it flunks)
LlamaRider masak: fair enough, I'll do that
isBEKaml g'night, #perl6 20:42
20:42 isBEKaml left
LlamaRider I remember there was a neat trick to simultaneously step through 2 arrays in Perl6. Could anyone remind me of it? 20:42
I think it was one of the combinators
20:42 cognominal joined
jnthn LlamaRider: zip 20:42
for @a Z @b -> $a, $b { }
LlamaRider jnthn: exactly! thanks for the reminder 20:43
20:47 census joined 20:58 thou left, thou joined 21:05 woolfy left, rindolf left 21:06 kst joined, bimbo_ joined 21:07 cognominal left, cognominal__ joined 21:10 kaare__ left 21:14 moca joined, bruges_ joined 21:16 bruges left, Gwyxx left
[Coke] phenny: tell isBEKaml that the data is there, and I'm half done with a script that will report "X days of rakudo hacking with no accidents" 21:18
21:20 sizz_ left
colomon [Coke]: no errors testing niecza locally now, btw 21:22
21:28 census left
[Coke] colomon - is that with a bunch of changes that weren't in by noon EST? 21:29
colomon with a few, anyway 21:30
[Coke] If not, we may have a mono version mismatch, or need an env var set...
github.com/coke/perl6-roast-data/b.../niecza.sh has my "get a fresh copy of niecza and test it" script. 21:31
21:31 census joined
colomon how many errors did you get? 21:31
[Coke] github.com/coke/perl6-roast-data/b...s_rates#L3 - 155 errors. 21:32
listed here: github.com/coke/perl6-roast-data/b...ummary.out at the end.
japhb Two angles on the same question: 1) Is there an easy way to get a recursive dump of a Perl 6 object? (not .perl, an actual recursive dump of all attributes), or 2) how do you get the *value* of an attribute from an Attribute object gotten from $obj.^attributes ? 21:34
colomon [Coke]: oh, that's weird.
jnthn 2 - get_value method 21:35
colomon japhb: .perl should be an actual recursive dump... 21:36
LlamaRider tadzik: My META.info is at github.com/dginev/perl6-Lingua-EN-.../META.info
colomon [Coke]: S32-num/stringify.t has worked for days, so something is wrong here.
japhb jnthn, OOC, why .get_value rather than just .value?
jnthn japhb: Because there's a corresponding bind_value 21:37
[Coke] colomon: every day I blow away roast and niecza and check them both out fresh, so it should be a botched git pull/rebase.
Can you try running the spec tests with the command I pointed at earlier? see if it fails when you do that way instead of "make spectest".
colomon maybe? 21:38
github.com/sorear/niecza is getting me a "this tree took too long to generate" error on github 21:39
yeah, something is hosed 21:40
TimToady's got a commit on there (according to github) that I don't have on either of my machines.
wait, maybe that's just a pull issue?
21:41 bimbo_ left
tadzik LlamaRider: looks good, adding 21:42
[Coke] 7d73dd1 ? that's my last commit in the roast-data checkout
colomon is confused
japhb colomon, Mu.perl specifically skips private attributes, but I need to dump them. Annoyingly, Mu.DUMP is just { self.perl }. I'm thinking DUMP should show private attributes as well.
dalek osystem: c1f89c3 | tadzik++ | META.list:
Add Lingua::EN::Sentence
tadzik LlamaRider++ 21:43
LlamaRider: please remove backup files from the repo (Foo.pm6~)
LlamaRider tadzik: oops, sorry about that, they're gone now. 21:46
21:49 kst left 21:50 kst joined
tadzik awesome, thanks :) 21:51
colomon [Coke]: yeah, 7d73dd1, Huh. I've downloaded it and am spectesting now. 21:53
now I get the stringify failures. TimToady, what have you done?! 21:55
masak this is why we can't have nice things! 21:56
colomon rn: say 1797010299914431210413179829509605039731475627537851106401/1152921504606846976
p6eval rakudo 11157e: OUTPUT«1558657976916843360832062017400788597510.05883495394563551060␤»
..niecza v24-31-g7d73dd1: OUTPUT«1558657976916843360832062017400788597510.058834953945635510598466400011830046423710882663726806640625␤»
colomon that's the problem. TimToady made it more precise in Niecza.
21:57 labster joined
japhb Is there any reason that MapIter has a single 'method DUMP()' instead of a 'multi method DUMP(MapIter:D:)' like the other listy types? 22:02
22:03 lustlife left
japhb And why do the listy types all have DUMP (multi-)methods that show hidden attributes, but Mu just falls to .perl? Why not introspect and dump attributes in the same style as the listy types' DUMP methods do? 22:03
jnthn Is DUMP actually spec? 22:05
Or is it just there to help those of us working on Rakudo get a more guts-y view? 22:06
japhb Certainly feels like that functionality ought to be available; it's huge for debugging.
You really want it for user-defined classes.
22:07 kivutar left
japhb (I actually looked for that functionality in Rakudo::Debugger, because I expected that of all things would be sure to have it, but if it was there, I didn't see it.) 22:07
22:08 PacoAir left
jnthn You can certainly introspect attributes that are in scope, though 22:09
Even if they're private.
masak is beginning to think that Perl 5 had it right, and private attributes are a kind of premature encapsulation
jnthn Lack of them removes confidene when it comes to refactoring. 22:10
Unless you're lucky enough to have a really good bunch of unit tests.
Which sure, folks like us tend to. But the world is a scary place.
I *like* languages where I can fearlessly refactor the insides of my class, renaming attributes as I desire. 22:11
japhb I don't mind private attributes (still kinda like them, actually, for reasons that include jnthn's), but I really want an easy way to show them when I need to ... which is to say, when debugging (whether with the interactive debugger, or well-placed logging, or what have you). 22:12
jnthn Or, more important, eliminating them for different data structures...
japhb: I agree the debugger should have the ability to do it for sure.
japhb: And we need something for those who don't like having an interactive debugger too 22:13
japhb right
jnthn I'm fine if you have to use a use statement to get it though...
.oO( MONEKY_SEE ;) )
*monkey 22:14
japhb And I think DUMP is a decent way to address that. It just needs a couple tiny tweaks to DWIM.
jnthn nqp: say(1 +| 2)
p6eval nqp: OUTPUT«3␤»
japhb I'd accept having to MONKEY things to see the private attributes, especially if that's necessary for pessimizing optimizations that might alter or delete some private attributes. 22:15
(I don't particularly *want* to have to say that, mind you, but I understand the possible need there.) 22:17
22:18 autark joined
japhb In the mean time, does anyone object if I make the 'multi method DUMP' fix to MapIter, and change 'multi method DUMP(Mu:D:)' to do the non-hiding version of the algorithm used in perl(), with the formatting that the listy types use? 22:19
22:19 SmokeMac_ left
japhb Also, did anyone work on a pretty-printing/indenting version of .perl? 22:20
jnthn japhb: I don't object but I think it's worth pondering the specness of it 22:22
japhb jnthn, you mean, whether it should be specced? A quick 'git grep' showed it wasn't specced as such right now .... 22:23
jnthn japhb: yes, that.
japhb It kinda feels like it should be, but then perhaps more care needs to be taken about picking formatting rules that can apply to all implementations, as well as intentionally *not* specced bits that allow an implementation to e.g. DUMP VM-native data structures. 22:26
(As how currently RPA is handled in a special way by 'sub DUMP(|)')
jnthn Well, .perl's exact format isn't spec'd 22:27
So there's certainly precedent for that part
japhb jnthn, I thought the spec for .perl basically came down to "evaluatable Perl code that will recreate (a clone of) the data structure, assuming all the .perl methods play nice" 22:28
(That last bit being something that is proving more commonly absent than present.) 22:29
jnthn That's the goal. Thing with private attrs is that there ain't a way to set them from outside of the object short of .bindvalue 22:30
japhb nodnod 22:31
22:31 arlinius joined
sorear Data::Dumper in p5 handles circular data structures. is anything like that planned for p6? 22:31
22:33 lestrrat left 22:34 lestrrat joined 22:35 lestrrat left 22:36 lestrrat joined 22:37 isomorphisms joined
LlamaRider tadzik: does panda have an "update" command? Or is running install again sufficient? 22:43
22:45 lestrrat left 22:46 stevan_ left 22:47 lestrrat joined 22:49 LlamaRider left 22:50 thou left
masak 'night, #perl6 22:51
22:51 fgomez left
colomon \O 22:51
colomon has apparently developed a big head
dalek ast: 3f1b3ee | (Solomon Foster)++ | S32-num/stringify.t:
Tweak to follow latest change to spec. (Grumble.)
22:59
colomon TimToady++ # for changing Niecza along with the spec. 23:01
23:02 fgomez joined, Celelibi joined 23:07 sjohnson left, sjohnson joined 23:09 spider-mario left 23:11 census left 23:29 yoleaux joined
dalek kudo/md-nqp: e4cd4da | jnthn++ | src/Perl6/Metamodel/BOOTSTRAP.pm:
Start translating multi-dispatch to NQP.

Add an NQP version of the candidate narrowness comparator function.
23:35
kudo/md-nqp: 1018f7e | jnthn++ | src/Perl6/Metamodel/BOOTSTRAP.pm:
Port multi candidate sort algorithm to NQP.

Not used yet.
jnthn sleep & 23:39
23:44 LlamaRider joined 23:45 Chillance left 23:50 thou joined 23:51 xilo left 23:59 Targen joined