»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, or /msg camelia p6: ... | irclog: irc.perl6.org or colabti.org/irclogger/irclogger_logs/perl6 | UTF-8 is our friend!
Set by moritz on 22 December 2015.
brokenchicken m: sub infix:meow<foo>sym«bar» {} 00:03
camelia rakudo-moar cfae23: OUTPUT«===SORRY!===␤Cannot find method 'wanted' on object of type NQPMu␤»
00:04 lukaramu left
brokenchicken :sym<> is colonpair! 00:05
00:08 dfcarpenterak joined 00:12 jsimonet left 00:14 girafe left, pyrimidi_ left, pyrimidine joined 00:20 espadrine_ left 00:27 dfcarpenterak left 00:32 wamba joined 00:39 cdg joined 00:46 pecastro left, aborazmeh joined, aborazmeh left, aborazmeh joined 00:55 Cabanossi left 00:58 Cabanossi joined, dontbe^2 left 00:59 cibs left 01:01 cdg left, cibs joined 01:03 pecastro joined 01:09 telex left 01:10 telex joined 01:11 kybr left 01:12 kybr joined 01:17 itcharlie1 left 01:29 bjz left 01:32 bjz joined 01:37 rindolf left 01:42 Cabanossi left 01:43 Cabanossi joined
brokenchicken This word game I got is weird... Lets you use "yolo", "rape", and "porn", but tells you "shit" is not a word! 01:49
This one: store.steampowered.com/app/373970/ good to pass time while spectesting :) 01:50
MasterDuke hm, i feel like i could spend more time than i should in that game 01:51
brokenchicken It's pretty good. 01:52
MasterDuke i play/have played lots of word games 01:54
01:57 cpage_ joined 01:58 bjz left 02:00 bjz joined 02:07 wamba left, pyrimidine left 02:08 pyrimidine joined, hartenfels joined
Geth pecs: d98ee5412c | (Zoffix Znet)++ | v6d.pod
Add reminder for 6.d

To properly reserve all C<< :sym<> >> colonpairs on subroutines Impl[^1] (commented out) and tests[^2] (fudged) already exist.
  [1] github.com/rakudo/rakudo/commit/48abeeef26
  [2] github.com/perl6/roast/commit/53d6e8491d
02:08
brokenchicken
.oO( why is that document in Perl 5 POD and not, say, Markdown... )
02:09 Geth left, user__ joined 02:10 Cabanossi left 02:11 Geth joined, ChanServ sets mode: +v Geth, bjz left 02:12 kalkin- left 02:13 Cabanossi joined 02:14 k-man left 02:16 k-man joined 02:27 ggoebel joined 02:36 agentzh left 02:39 k-man left 02:40 k-man joined 02:41 Cabanossi left 02:43 Cabanossi joined 02:44 ilbot3 left 02:47 ilbot3 joined, ChanServ sets mode: +v ilbot3, bjz joined 02:49 travis-ci joined
travis-ci Doc build errored. Antonio Quinonez 'more updates to regexes pod' 02:49
travis-ci.org/antquinonez/doc/builds/196063097 github.com/antquinonez/doc/compare...912f83e0f9
02:49 travis-ci left 02:50 travis-ci joined
travis-ci Doc build passed. Antonio Quinonez 'Merge remote-tracking branch 'upstream/master'' 02:50
travis-ci.org/antquinonez/doc/builds/196064952 github.com/antquinonez/doc/compare...a6f5acf98f
02:50 travis-ci left 03:07 travis-ci joined
travis-ci Doc build passed. Antonio Quinonez 'Merge branch 'master' of github.com/antquinonez/doc' 03:07
travis-ci.org/antquinonez/doc/builds/196066687 github.com/antquinonez/doc/compare...4de47095dc
03:07 travis-ci left 03:11 Cabanossi left 03:13 Cabanossi joined 03:34 cibs left 03:36 cibs joined 03:40 haxmeister joined 03:44 noganex joined 03:47 noganex_ left 03:57 Cabanossi left 03:58 Cabanossi joined 04:03 geraud left 04:07 Cabanossi left 04:08 cpage_ left 04:10 Cabanossi joined 04:14 cpage_ joined 04:44 labster left 04:45 khw left 04:47 dfcarpenterak joined 04:52 Cabanossi left 04:55 Cabanossi joined 04:58 dfcarpenterak left 05:01 pyrimidine left, perlawhirl joined 05:04 agentzh joined
haxmeister is it possible to go back to the previous command in perl6 repl? 05:06
05:06 Actualeyes left 05:09 agentzh left, Actualeyes joined
BenGoldberg m: sub postfix:<!>($n) { [*] 2..$n }; sub infix:<C>($n, $k) { $n! / ($k * ($n-$k)!) }; say 5 C 2 05:15
camelia rakudo-moar c6e37e: OUTPUT«10␤»
haxmeister eh? 05:17
05:29 bjz left
Geth oc: antquinonez++ created pull request #1166:
some more edits/re-writes
05:38
dj_goku haxmeister: try the up arrow? zef install Linenoise maybe too? 05:40
haxmeister up arrow just gives me codes.. not previous command 05:41
linenoise does this? 05:42
dj_goku I think so yes.
haxmeister ok ty
05:47 bjz joined 05:53 Cabanossi left 05:55 Cabanossi joined 05:58 pyrimidine joined 06:03 haxmeister left 06:04 Tonik joined 06:27 LeCamarade joined, agentzh joined
LeCamarade Hello, all; 06:28
Has anyone built Rakudo Star on FreeBSD 32-bit ARM
?
I get one last step failing thus: 06:29
linking libmoar.so
clang: error: no such file or directory: '3rdparty/dyncall/dyncallback/libdyncallback_s.a'
clang: error: no such file or directory: '3rdparty/dyncall/dynload/libdynload_s.a'
*** Error code 1
It dies there. So close, yet so far ... :-\ 06:30
06:30 labster joined 06:36 hartenfels1 joined 06:38 hartenfels left, hartenfels1 is now known as hartenfels 06:48 LeCamarade left, LeCamarade joined 06:50 ufobat joined 06:52 CIAvash joined 07:07 Cabanossi left 07:08 aborazmeh left 07:10 Cabanossi joined 07:12 domidumont joined
samcv is there a variable I can check to get the line in the source file my program is on? 07:12
07:18 domidumont left 07:19 domidumont joined 07:20 bwisti left 07:28 parv joined 07:30 BenGoldberg left
moritz m: say $?LINE 07:31
camelia rakudo-moar c6e37e: OUTPUT«1␤»
moritz samcv: ^^
samcv nice
07:32 bjz left 07:33 bjz joined 07:35 espadrine_ joined 07:37 bjz left 07:50 wamba joined 07:52 Cabanossi left
parv if moar vm (and/or nqp) is (are) installed extrernally, does the building rakudo phase require them to be present in $PATH, or could the respective install directories be given when starting Configure.pl? 07:54
07:55 Cabanossi joined
parv README.md on github does not say anythig in that regard. 07:55
08:04 CIAvash left
LeCamarade I think it requires them to be in --prefix. 08:04
When I give it a --prefix where they aren't, it complains when I also give it --backends=moar 08:05
08:08 agentzh left 08:10 bjz joined 08:12 RabidGravy joined
parv (reading Configure.pl) --sdkroot option could be used to provide alternate path (so that rakudo could be installed, via --prefix, in a separate dir). At least there is proper --with-nqp option for the path, but none for moar vm. 08:17
08:19 bjz_ joined, bjz left 08:22 toolforger joined
toolforger Hi everybody 08:22
What do I do when I see roast going into an endless loop on rakudo-j? 08:23
08:27 pyrimidine left
lizmat toolforger: you try to find out where the loop occurs and golf it down to a small piece of code you can put in a rakudobug report ? 08:34
parv does link to rlwrap -- utopia.knoware.nl/~hlub/uck/rlwrap/ -- tend to timeout? 08:35
toolforger parv: yes, for me it does (connecting from CH) 08:36
parv toolforger, thanks 08:37
toolforger lizmat: I have the name of the looping test somewhere, but my Perl knowledge is pretty limited so I'm not too sure about my ability to golf it down
Is there a simple way to run an individual test? 08:38
08:40 bjz joined
toolforger parv: utopia does not even react to pings. The host is probably not down but seriously misconfigured. 08:41
lizmat toolforger: do you mean a single test file ? or a single test inside a file?
toolforger lizmat: both :-)
lizmat the former is: make t/spec/foo/bar.t
08:41 bjz_ left
lizmat the latter is: comment out the lines you don't want to test and ignore the "incorrect number of tests" message :-) 08:42
toolforger lol 08:45
okay
sounds like a viable plan
how to I put in a rakudobug report?
lizmat email to [email@hidden.address] 08:46
toolforger that works :-) 08:47
I do not know which of the tests fail, there is no output apart from the test file name and the line of dots - is there a way to quickly converge on which line is actually looping? 08:48
lizmat you can run it directly as a script 08:49
perl6 t/spec/foo/bar.t
or if it has been fudged:
LeCamarade
lizmat perl6 t/spec/foo/bar.rakudo.jvm 08:50
and maybe perl6-j
toolforger oh, wait 08:51
I see that "make t/spec/..." gives me more detailed output
I am trying "make t/spec/S3*/*", which seems to emit some useless error messages but then I'm after an endless loop, not a specific error message 08:53
but it doesn't seem to run the tests on the jvm 08:54
unless it runs jvm after moarvm 08:55
no it doesn't :-( 08:58
lizmat which backends did you build ? 09:03
fwiw, I always keep 2 clones of the rakudo repo: one for jvm and one for moarvm
09:06 darutoko joined 09:08 agentzh joined, TEttinger left
toolforger I have backends=moar,jvm 09:10
lizmat ok, I have no (recent) experience with that setup :-( 09:11
toolforger I think I'll just rerun make spectest
I was under the impression I need a moarvm installation to build rakudo-j, that's why I was doing the two in one installation 09:12
09:13 agentzh left
lizmat ah, no, you don't need MoarVM to be able to build the JVM backend :-) 09:13
toolforger ok, I'll try that then
though it was helpful to have both 09:14
I wouldn't have noticed that rakudo-on-jvm is considerably slower than rakudo-on-moar
09:15 dfcarpenterak joined
toolforger oh right 09:17
I was running the internal commands as reported by make -n
to be able to skip the github updates, because I am offline a lot 09:18
Hmm... make -n tells me it runs both backends 09:19
09:19 pyrimidine joined
toolforger make -n t/spec/S22-package-format/local.t runs only --moar 09:20
09:20 dfcarpenterak left
toolforger it is also doing dubious things, like copying perl6-m over perl6 and chmodding it 755 09:20
running a test suite shouldn't touch the current installation, just on principle 09:21
lizmat agree 09:22
toolforger preparing a rakudobug for that
09:23 dfcarpenterak joined
lizmat toolforger++ 09:23
toolforger thx
09:24 pyrimidine left 09:27 Tonik left 09:28 Vynce joined
RabidGravy there are a lot of good things about travis-ci but when I find myself spending time working around the environment in the tests I do wonder 09:30
El_Che just a crazy idea, but the docker support is very nice if you're able to encapsulate the build. That is what I do for the built of rakudo packages: github.com/nxadm/rakudo-pkg/blob/m...travis.yml 09:33
09:34 bpmedley left 09:39 hartenfels left
RabidGravy yeah, actively considering that right now 09:45
El_Che ping me in case you need input 09:46
RabidGravy: github.com/nxadm/rakudo-pkg/blob/m..._rakudo.sh . That script is called from the container to download released tar balls. It's trivial to do a git checkout instead 09:48
09:48 Ven joined 09:54 Cabanossi left 09:55 Cabanossi joined 09:56 ShoaibJahejo joined, ShoaibJahejo left
RabidGravy with Audio::Liquidsoap there are multiple problems on travis, prime among them is that ubuntu packages a stupidly old liquidsoap and building one (it's written in ocaml) would be way too painful 09:57
09:58 ShoaibJahejo joined, ShoaibJahejo left 09:59 Vasyl joined, ShoaibJahejo joined, ShoaibJahejo left
El_Che you could build them using a ubuntu 16.10 build? 09:59
10:00 ShoaibJahejo joined, ShoaibJahejo left, ShoaibJahejo joined
RabidGravy wonders whether docker is being funny when it generates a container name "backstabbing_knuth" 10:01
El_Che haha
that's one of the better names so far 10:02
10:04 Ven left 10:06 Ven joined
moritz tkrt 10:13
toolforger lizmat, rakudobugs are in and confirmed
10:23 Cabanossi left 10:24 AlexDaniel joined 10:25 Cabanossi joined
lizmat toolforger: thanks 10:34
10:37 cpage_ left 10:39 cpage_ joined 10:40 toolforger left 10:43 labster left 10:45 cpage_ left
AlexDaniel samcv: you may also be interested in callframe 10:49
m: say callframe
camelia rakudo-moar 960a78: OUTPUT«<tmp> at line 1␤»
10:56 holyghost joined 11:06 rindolf joined 11:09 lukaramu joined 11:18 parv left 11:19 domidumont left 11:36 pyrimidine joined 11:40 Cabanossi left 11:41 Cabanossi joined 11:42 pyrimidine left 11:44 holyghost left 11:46 hankache_ joined 11:47 cpage_ joined, Ven left 11:50 Ven joined
RabidGravy bad fedora no cookie 11:50
11:52 wamba left, ChoHag left 11:53 hankache_ left 11:58 hankache joined 12:01 sammers left
dalek Iish: c8a3351 | (Kaare Rasmussen)++ | / (2 files):
If a pg type isn't found, it becomes an Any type. Can't typecast those.
12:05
Iish: 16d9a25 | RabidGravy++ | / (2 files):
Merge pull request #86 from kaare/master

Except Any types from casting, and add an enum example for PostgreSQL
yoleaux 24 Jan 2017 15:38Z <AlexDaniel> dalek: Please switch this bot to Geth
12:05 RabidGravy left, pmurias joined
AlexDaniel .tell dalek Please switch this bot to Geth 12:05
yoleaux AlexDaniel: I'll pass your message to dalek.
AlexDaniel who can change the settings of github.com/perl6/DBIish ?
12:06 RabidGravy joined
moritz AlexDaniel: I can 12:07
AlexDaniel Geth: help
Geth AlexDaniel, Source at github.com/perl6/geth To add repo, add an 'application/json' webhook on GitHub pointing it to geth.perl6.party/?chan=#perl6 and choose 'Send me everything' for events to send | use `ver URL to commit` to fetch version bump changes
AlexDaniel moritz: ↑
timotimo could this abizy thing just fucking stop >_< 12:08
moritz AlexDaniel: done; please test 12:09
AlexDaniel er, the only way to test it is to commit something I guess 12:10
let's see
Geth BIish/gethtest: 33bf0516fb | (Aleks-Daniel Jakimenko-Aleksejev)++ | testfile
Just testing Geth
12:11
AlexDaniel moritz: \o/
12:13 JJMerelo joined
hankache hello #perl6 12:13
12:13 sammers joined
lizmat hankache o/ 12:13
hankache hiya lizmat
12:13 wamba joined
JJMerelo This is probably a dumb question 12:14
yoleaux 27 Dec 2016 12:57Z <tbrowder> JJMerelo: i'm happy to use
27 Dec 2016 13:00Z <tbrowder> JJMerelo: i'm happy to make my fork more usable, but i am NOT a lisp-literate person, either; would be great to hear more from henrik about his plans
4 Jan 2017 15:57Z <tbrowder> JJMerelo: see new wiki
JJMerelo But why are number radices limited to 36?
lizmat JJMerelo: (0..9,"a".."z").elems = 36 12:15
JJMerelo github.com/rakudo/rakudo/blob/b548...r.pm#L1304
hankache windows users, what terminal do you use? Any alternative to cmd.exe?
JJMerelo OK, makes sense as long as you limit yourself to using those letters... 12:16
lizmat JJMerelo: right, so what would one use beyond 36 ?
JJMerelo @lizmat that's not so much an issue as actually using that expression instead of the number 36 12:17
Because in the "Exception.pm" the number 36 also shows up magically
github.com/rakudo/rakudo/blob/ee2e...n.pm#L1497 12:18
AlexDaniel JJMerelo: oh, so you mean the error message is LTA?
JJMerelo Sorry, no comprendo LTA
AlexDaniel Less Than Awesome
JJMerelo Hum, not really.
timotimo JJMerelo: did you see my tweet? 12:19
m: say :60[6,6,6]
camelia rakudo-moar 960a78: OUTPUT«21966␤»
JJMerelo More that maybe it would be better to have a constant, somewhere, saying ADMISSIBLE-CHARACTERS-IN-NUMBERS
@timotimo no, but that's awesome
And then have Str.pm and Exception.pm use that constant. It's more of a documentation issue, really, but only for the sake of avoding dummy questions such as my own. 12:20
lizmat JJMerelo: github.com/rakudo/rakudo/commit/9d0a6c00f7 12:21
JJMerelo @lizmat that's awesome :-)
12:28 ufobat left 12:35 domidumont joined 12:38 pyrimidine joined 12:39 Cabanossi left 12:40 JJMerelo left, domidumont left 12:41 Cabanossi joined 12:42 MasterDuke left 12:43 pyrimidine left 12:49 Ven left 12:51 z448 joined, dfcarpenterak left 12:55 Ven joined 12:57 Rawriful joined, Rawriful left 13:00 cibs left, Rawriful joined 13:02 cibs joined 13:04 z448 left, LeCamarade left 13:06 ocbtec joined 13:09 agentzh joined 13:14 agentzh left 13:17 MasterDuke joined 13:20 bpmedley joined 13:21 hankache left 13:24 Cabanossi left 13:26 Cabanossi joined, sena_kun joined 13:29 sammers left 13:30 bjz left 13:36 KotH left 13:39 itcharlie joined, cale2 joined 13:42 spider-mario joined 13:43 sammers joined 13:45 domidumont joined 13:54 KotH joined
Geth BIish: f4067d88cc | (Jonathan Stowe)++ | 9 files
Retab and fix indentation
13:56
BIish: 8e0cb3ea80 | (Jonathan Stowe)++ | lib/DBIish/CommonTesting.pm6
Use a Bool
13:58 KotH left 14:09 espadrine_ left 14:10 itcharlie left
timotimo actually, do y'all think the error in :60<123> should suggest using :60[1, 2, 3] syntax? 14:24
14:35 Ven left, pyrimidine joined 14:37 Ven joined 14:38 Tonik joined
RabidGravy [446/940] and I'm already concerrned about my laptop going on fire 14:40
Ardour is a great program but it's a behemoth 14:41
14:42 pyrimidi_ joined, pyrimidine left 14:46 Ven left, Ven joined 14:47 pyrimidi_ left
cale2 How up to date is this book: cloud.github.com/downloads/perl6/b....23.a4.pdf 14:47
Using Perl 6
I guess it says 2012 lol. Not sure if there is an updated version 14:48
14:49 sammers left
lizmat cale2: I think you can consider leanpub.com/perl6 an up-to-date reboot of that 14:50
AlexDaniel huggable: books 14:51
huggable AlexDaniel, "Perl 6 At A Glance" deeptext.media/perl6-at-a-glance/ (print only for now); "Perl 6 By Example": leanpub.com/perl6 (can order preview digital copies)
cale2 lizmat: That's not done yet :)
and none of the other ones are done either :)
AlexDaniel false
cale2 i'm not buying a print book, sorry
lizmat deeptext.media/perl6-at-a-glance # a print book
but done :-)
cale2 If there's a github for the Using Perl 6 book, I can go through it and update any code examples that don't work anymore 14:52
lizmat cale2++
MasterDuke github.com/perl6/book 14:53
cale2 thanks 14:58
15:02 sammers joined
brokenchicken m: :60<123> 15:05
camelia rakudo-moar a83294: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Radix 60 out of range (allowed: 2..36)␤at <tmp>:1␤------> 3:60<123>7⏏5<EOL>␤»
brokenchicken m: say :60[1, 2, 3]
camelia rakudo-moar a83294: OUTPUT«3723␤»
15:06 mr-foobar left
brokenchicken timotimo: not really :) 15:07
sena_kun by the way, what does the second line? 15:09
brokenchicken m: say 60²*1 + 60¹*2 + 3
camelia rakudo-moar a83294: OUTPUT«3723␤»
timotimo it does 30 + 2 * 60 + ... yeah
sena_kun hmm... okay, thanks. 15:10
timotimo m: say :100[1, 2, 3, 4, 5]
camelia rakudo-moar a83294: OUTPUT«102030405␤»
timotimo why did i write 30 + there and not 3 +? oh well
brokenchicken m: say 60²*1 + 60¹*2 + 60⁰*3 # even 15:11
camelia rakudo-moar a256ef: OUTPUT«3723␤»
15:12 kurahaupo joined 15:16 mr-foobar joined, cibs left 15:18 pyrimidine joined, cibs joined 15:22 pyrimidine left
RabidGravy okay a question of taste: Archive::LibArchive or Archive::Libarchive ? 15:23
15:24 Cabanossi left
brokenchicken LibArchive 15:24
sena_kun +1 for LibArchive 15:25
RabidGravy I think that's the one I prefer too but I keep flipping
timotimo lIBaRCHIVE 15:26
15:26 Cabanossi joined 15:27 curt__ left
RabidGravy m: say "libarchive".comb.map({ Bool.pick ?? uc $_ !! $_}).join("") 15:28
camelia rakudo-moar a256ef: OUTPUT«libaRChIVe␤»
15:42 Ven left 15:43 benchable6_ joined, ChanServ sets mode: +v benchable6_, benchable6_ left, dj_goku left 15:46 agentzh joined 15:47 dfcarpenterak joined 15:51 agentzh left 15:53 Cabanossi left 15:54 dj_goku joined, dj_goku left, dj_goku joined 15:55 Cabanossi joined 15:58 TEttinger joined
cale2 Is there an `in` operator that checks if an element is in a list? 16:07
returns true or false
brokenchicken sortof 16:08
m: say 42 ∈ ^100
camelia rakudo-moar a256ef: OUTPUT«True␤»
brokenchicken BUT
m: say 42 ∈ [<42>]
camelia rakudo-moar a256ef: OUTPUT«False␤»
16:08 curt__ joined
brokenchicken It cares much about object identity 16:08
See also .first
or junctions 16:09
m: say 42 == any ^100
camelia rakudo-moar a256ef: OUTPUT«any(False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, …»
brokenchicken m: say so 42 == any ^100
camelia rakudo-moar a256ef: OUTPUT«True␤»
cale2 hm... 16:10
I guess I could use a junction if the list is small, right?
can I convert a list of strings to a junction?
brokenchicken You can make a junction out of a list of string yes. Same as above
m: say "meow" eq any <foo bar meow moo> 16:11
camelia rakudo-moar a256ef: OUTPUT«any(False, False, True, False)␤»
brokenchicken m: say so "meow" eq any <foo bar meow moo>
camelia rakudo-moar a256ef: OUTPUT«True␤»
brokenchicken m: say so "meow" eq <foo bar meow moo>.any
camelia rakudo-moar a256ef: OUTPUT«True␤»
brokenchicken (there are also `one`, `none`, and `all` junctions, depending on your need)
16:11 itcharlie joined
cale2 This doesn't really seem very "make the easy things easy" if you ask me 16:13
brokenchicken Really?
cale2 `if elem in list`
now that's easy
brokenchicken `if elem ∈ list`
I don't see what the winge is here about
cale2 I'm working on updating the Using Perl 6 book. It's only the first chapter and I don't want to introduce Junctions 16:14
And I also don't want to explain why the reader can't type this bizarre character
brokenchicken if list.first: elem { ... }
`if elem (elem) list`
`if elem eq any list`
"I like the Python way and Perl 6 is yuky" is what I hear TBH 16:15
cale2 brokenchicken: You're really just writing off any criticism
`if elem ∈ list` that requires explaining how to type unicode for people that prob have never had to before 16:16
`if elem eq any list` that requires explaining junctions
profan there isnt a non-unicode equivalent to the character?
cale2 `if elem in list` requires explaining a for loop, which we already have done.
brokenchicken cale2: I already pointed out the (elem) Texas version
cale2: if elem in list requires explaining what sort of comparison `in` does. Is "42" in [42] ? 16:17
cale2: I may be dismissing critisism, but you're dismissing things you already understand as not requiring any explanation and therefore superior.
profan: It's (elem). All fancy ops have a Texas versions. docs.perl6.org/language/unicode_texas.html 16:18
profan right
cale2 Is "42" in [42] ? I don't know, you'd have to explain this in P6 as well.
16:19 perlawhirl left 16:24 Cabanossi left 16:25 Cabanossi joined 16:30 dfcarpenterak left
dalek line-Perl5: c125bfc | niner++ | / (2 files):
Rewrite publication of wrapper packages

Previously we relied on hacks and implementation details to get our wrapper packages into the user's namespace. This did not work all that well anymore after module loading became lexical in rakudo. This rewrite replaces those hacks with an implementation that uses the same mechanism that handles symbols from native Perl 6 modules.
16:36
yoleaux 12:05Z <AlexDaniel> dalek: Please switch this bot to Geth
16:37 pyrimidine joined
AlexDaniel nine: hey 16:37
Geth: help
Geth AlexDaniel, Source at github.com/perl6/geth To add repo, add an 'application/json' webhook on GitHub pointing it to geth.perl6.party/?chan=#perl6 and choose 'Send me everything' for events to send | use `ver URL to commit` to fetch version bump changes
AlexDaniel nine: ↑ ?
.tell dalek Please switch this bot to Geth
yoleaux AlexDaniel: I'll pass your message to dalek.
AlexDaniel can't do it myself unfortunately 16:38
ah, it's not even in perl6 org
nine AlexDaniel: updated. Thanks for the reminder! 16:39
16:42 pyrimidine left
cale2 brokenchicken: you can see my PR. I used the membership operator as it looks like Junctions are touched on much later. 16:48
brokenchicken sees no PRs 16:49
cale2 When is this page gonna be updated for the january release of R*? perl6.org/downloads/ 16:52
brokenchicken When it occurs 16:53
There was an RC recently, so I'd guess the release will happen soon
MasterDuke brokenchicken: github.com/perl6/book/pull/85 16:54
Geth nline-Perl5: 208f97d1d0 | (Stefan Seifert)++ | META6.json
Version 0.23
16:55
brokenchicken cale2: I invited you to perl6 org so you can merge that PR yourself. One note: the <...> don't assume everything inside are strings 17:01
m: dd <42 42e0 .5 1+0i>
camelia rakudo-moar 4e7ab2: OUTPUT«(IntStr.new(42, "42"), NumStr.new(42e0, "42e0"), RatStr.new(0.5, ".5"), ComplexStr.new(<1+0i>, "1+0i"))␤»
brokenchicken ^ they create allomorphs
m: dd <:16<FF>> # and have magics 17:02
camelia rakudo-moar 4e7ab2: OUTPUT«IntStr.new(255, ":16<FF>")␤»
cale2 brokenchicken: I'm wondering if we should link to the docs at times like that. I don't know how to create nice links in POD format though
brokenchicken L<some text|some.link>
cale2 thanks
17:04 khw joined 17:07 cdg joined 17:09 itcharlie left 17:13 bwisti joined 17:22 ChoHag joined 17:23 pyrimidine joined 17:28 pyrimidine left, mniip left
Geth hateverable: 962dc22caa | (Daniel Green)++ | Benchable.p6
Be smarter about the messages Benchable gives

  * Only say we're zooming/bisecting if there are in fact any performance
   differences found
  * Report the preliminary results before starting to bisect
  * Report any results so far if the total timeout is hit
Closes #38 and #62
17:35
cosystem: titsuki++ created pull request #293:
Add Algorithm::LibSVM to ecosystem
cosystem: e8291b3c53 | titsuki++ | META.list
Add Algorithm::LibSVM to ecosystem

See github.com/titsuki/p6-Algorithm-LibSVM
cosystem: f014dd3fc8 | (Itsuki Toyota)++ | META.list
Merge pull request #293 from titsuki/add-libsvm

Add Algorithm::LibSVM to ecosystem
17:37 Geth left 17:38 Geth joined, ChanServ sets mode: +v Geth
Geth ook: 9815903579 | Cale++ | src/basics.pod
Updated the Basics chapter (#85)

  * Add file extension to open('scores')
Did not compile without this.
  * Update basics.pod
Not sure if I formatted the text correctly. I just put in new lines when the line was getting too long.
  * Add links to docs
17:38
brokenchicken just re-delivered that one to ensure Geth bug got fixed
17:39 pyrimidine joined
cale2 One part of the book says that the <,> operator "constructs a Parcel, which is a sequence of objects". I think it's better to go with what the docs say. "Constructs a List from its arguments" 17:39
brokenchicken Yeah, Parcel is no longer a thing 17:40
RabidGravy gosh
I'd actually forgotten about Parcel
17:44 pyrimidine left 17:52 cflor joined 17:55 pyrimidine joined 17:58 BenGoldberg joined 17:59 pyrimidine left
cale2 How exactly is the POD format converted to PDF? 18:01
Can it also be converted easily to other formats?
18:01 BenGoldberg left
cale2 For example, I'm wondering if we could convert POD files to Markdown 18:01
brokenchicken whoa... metacpan.org got majorly logo-fied lol 18:02
18:02 wamba left
brokenchicken cale2: yeah. I'm guessing the book is written in Perl 5 pod? There's a whole bunch of converters: metacpan.org/search?q=Pod+to+pdf 18:03
buggable: eco pod
buggable brokenchicken, Found 12 results: Pod::To::HTML, Pod::Parser, Pod::Perl5, Pod::PerlTricks, Pod::Strip. See modules.perl6.org/#q=pod
brokenchicken And if it's Perl 6 pod, we have ::HTML and ::Markdown
18:03 BenGoldberg joined
brokenchicken The README has "To build the PDF version of this book...." section 18:06
And the README starts with "This repository is retained only for archival purposes. The project is currently considered dead..."
cale2 brokenchicken: If it's not possible to generate a new book file, then I won't bother. Otherwise I can keep updating 18:08
brokenchicken Presumable the instructions describe a way to build that's still works. 18:10
cale2: you could check with moritz++ if he is looking for any helping hands for his book instead. 18:12
(there's #perl6book that used to be for perl6/book but from what I understand now is for moritz's book) 18:13
18:14 domidumont left 18:15 espadrine_ joined, agentzh joined
cale2 ah good call 18:16
The example code from the operators chapter is a bit odd, to be honest.
m: my @scores = 'Ana' => 8, 'Dave' => 6, 'Charlie' => 4, 'Beth' => 4; say 1 + [max] @scores».key».chars; 18:17
camelia rakudo-moar 4e7ab2: OUTPUT«8␤»
cale2 I'm wondering why not just use a % for scores instead though...
m: my %scores = 'Ana' => 8, 'Dave' => 6, 'Charlie' => 4, 'Beth' => 4; say 1 + [max] %scores.keys».chars;
camelia rakudo-moar 4e7ab2: OUTPUT«8␤»
brokenchicken m: my @scores = 'Ana' => 8, 'Ana' => 42; dd @scores 18:19
camelia rakudo-moar 4e7ab2: OUTPUT«Array @scores = [:Ana(8), :Ana(42)]␤»
brokenchicken m: my %scores = 'Ana' => 8, 'Ana' => 42; dd %scores
camelia rakudo-moar 4e7ab2: OUTPUT«Hash %scores = {:Ana(42)}␤»
cale2 moritz: what do you think? Should I stop updating the old book and help proof yours instead? 18:20
18:20 Actualeyes left 18:23 agentzh left
cale2 brokenchicken: I guess Arrays don't dedup and they maintain their order. Perhaps it would be good to explain when to use each, idk. Difficulty is in having a strong focus on who the audience is 18:24
18:29 pyrimidine joined
TimToady m: say [1,2,42,3,4] ~~ (**, 42, **) # another way 18:32
camelia rakudo-moar 4e7ab2: OUTPUT«True␤»
brokenchicken m: say 2 ≤ 3 ≥ 1 ≠ 2 18:33
camelia rakudo-moar 4e7ab2: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Confused␤at <tmp>:1␤------> 3say 27⏏5 ≤ 3 ≥ 1 ≠ 2␤ expecting any of:␤ infix␤ infix stopper␤ postfix␤ statement end␤ statement modifier␤ …»
brokenchicken hehe... Perl 7 gives true for ^ that :P It's now officially more advanced than all the other Perls :P 18:34
18:34 pyrimidine left, Ven joined, Actualeyes joined
brokenchicken m: say 2 <= 3 >= 1 != 2 18:35
camelia rakudo-moar 4e7ab2: OUTPUT«True␤»
brokenchicken m: say 2 <= 3 >= 1 != 1
camelia rakudo-moar 4e7ab2: OUTPUT«False␤»
brokenchicken m: sub infix:<≤> { [<=] @_ }; say 2 ≤ 4 ≤ 5 18:37
camelia rakudo-moar 4e7ab2: OUTPUT«True␤»
brokenchicken m: sub infix:<≤> { [<=] @_ }; say 2 ≤ 4 ≤ 3
camelia rakudo-moar 4e7ab2: OUTPUT«True␤»
brokenchicken Close enough... :P
Ah, it ends up comparing Bool (which is 1) with 3 18:38
m: sub infix:<≤> is assoc('chain') { [<=] @_ }; say 2 ≤ 4 ≤ 3
camelia rakudo-moar 4e7ab2: OUTPUT«False␤»
brokenchicken m: sub infix:<≤> is assoc('chain') { [<=] @_ }; say 2 ≤ 4 ≤ 5
camelia rakudo-moar 4e7ab2: OUTPUT«False␤»
TimToady same problem really, we parse them as binaries when they should be processed as alternative values and functions
brokenchicken Ah, I see
m: sub infix:<≤> is assoc('chain') { dd @_ }; say 2 ≤ 4 ≤ 5
camelia rakudo-moar 4e7ab2: OUTPUT«[4, 5]␤[2, Nil]␤Nil␤»
TimToady though I guess it works there 18:39
oh, wait, it dint
brokenchicken m: sub infix:<≤> is assoc('list') { [<=] @_ }; say 2 ≤ 4 ≤ 5 18:40
camelia rakudo-moar 4e7ab2: OUTPUT«True␤»
brokenchicken m: sub infix:<≤> is assoc('list') { [<=] @_ }; say 2 ≤ 4 ≤ 3
camelia rakudo-moar 4e7ab2: OUTPUT«False␤»
brokenchicken yey
(though it'd break when other ops are mixed I think)
m: sub infix:<≤> is assoc('list') { [<=] @_ }; say 2 ≤ 4 > 3 18:41
camelia rakudo-moar 4e7ab2: OUTPUT«False␤»
brokenchicken yup
18:50 cflor left 18:51 notbenh joined, agentzh joined 18:54 Cabanossi left 18:56 Cabanossi joined 18:59 BenGoldberg left
moritz m: indir '/tmp' { say $*CWD } 19:05
camelia rakudo-moar 4e7ab2: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Unexpected block in infix position (missing statement control word before the expression?)␤at <tmp>:1␤------> 3indir '/tmp'7⏏5 { say $*CWD }␤ expecting any of:␤ infix␤ infix …»
moritz m: indir '/tmp', { say $*CWD }
camelia rakudo-moar 4e7ab2: OUTPUT«"/tmp".IO␤»
19:05 BenGoldberg joined
BenGoldberg m: sub infix:<≤> is assoc('list') { [<=] @_ }; say 2 ≤ 4 < 5; 19:07
camelia rakudo-moar 4e7ab2: OUTPUT«True␤»
BenGoldberg m: sub infix:<≤> is assoc('list') { [<=] @_ }; say 2 ≤ 2 < 5;
camelia rakudo-moar 4e7ab2: OUTPUT«True␤»
BenGoldberg m: dd $/.VAR 19:08
camelia rakudo-moar 4e7ab2: OUTPUT«Invocant requires an instance of type Mu, but a type object was passed. Did you forget a .new?␤ in block <unit> at <tmp> line 1␤␤»
BenGoldberg m: my $introspect = $/.VAR; dd $introspect;
camelia rakudo-moar 4e7ab2: OUTPUT«Invocant requires an instance of type Mu, but a type object was passed. Did you forget a .new?␤ in block <unit> at <tmp> line 1␤␤»
BenGoldberg m: my $introspect = $/.VAR;
camelia ( no output )
BenGoldberg m: say $/.VAR;
camelia rakudo-moar 4e7ab2: OUTPUT«Nil␤»
BenGoldberg m: say $*/.VAR; 19:09
camelia rakudo-moar 4e7ab2: OUTPUT«5===SORRY!5===␤Unrecognized regex metacharacter ; (must be quoted to match literally)␤at <tmp>:1␤------> 3say $*/.VAR7⏏5;␤Unable to parse regex; couldn't find final '/'␤at <tmp>:1␤------> 3say $*/.VAR;7⏏5<EOL>␤␤»
BenGoldberg m: say $?/.VAR;
camelia rakudo-moar 4e7ab2: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Unsupported use of $? variable; in Perl 6 please use $! for handling child errors also␤at <tmp>:1␤------> 3say $?7⏏5/.VAR;␤»
brokenchicken What are you trying to do? 19:10
BenGoldberg I was looking at some old examples, one of which was examining default values by doing $foo.VAR.default; One of the examples was $/.VAR.default, which doesn't work, cause $.VAR is Nil. 19:15
perl6advent.wordpress.com/2013/12/...ial-state/ 19:16
19:18 raschipi joined
timotimo $.VAR will be a reference to self.VAR 19:19
moritz m: say $/.VAR.default
camelia rakudo-moar 4e7ab2: OUTPUT«Nil␤»
moritz loooks correct to me
a failed match returns Nil
m: my $x = 42; say $x.VAR.default 19:20
camelia rakudo-moar 4e7ab2: OUTPUT«(Any)␤»
19:21 ChoHag left, raschipi left
moritz m: say ('x' x int.Range.max + 1).chars 19:22
camelia rakudo-moar 4e7ab2: OUTPUT«0␤»
19:22 pyrimidine joined 19:23 Cabanossi left, kyan joined 19:25 sena_kun left 19:26 Cabanossi joined 19:27 labster joined, pyrimidine left 19:29 darutoko left
BenGoldberg m: dd Nil; 19:31
camelia rakudo-moar 4e7ab2: OUTPUT«Nil␤»
BenGoldberg m: dd int.Range
camelia rakudo-moar 4e7ab2: OUTPUT«-9223372036854775808..9223372036854775807␤»
BenGoldberg m: say int.Range.pick
camelia rakudo-moar 4e7ab2: OUTPUT«2413258564425961281␤»
BenGoldberg . o O (Next time someone says, pick a number, any number, ^ that's what i'll do ;)) 19:32
19:33 trnh joined, trnh left, trnh joined
TEttinger BenGoldberg: I pick phi. that is, the base-36 number where the digits are p, h, i 19:33
moritz m: say :36<phi> 19:35
camelia rakudo-moar 4e7ab2: OUTPUT«33030␤»
moritz not bad
BenGoldberg m: 'phi'.parse-base(36).say;
camelia rakudo-moar 4e7ab2: OUTPUT«33030␤»
TEttinger nice
BenGoldberg m: 'perl'.parse-base(36).say; 19:36
camelia rakudo-moar 4e7ab2: OUTPUT«1185537␤»
TEttinger do radices above 36 work somehow?
BenGoldberg m: 'perl'.parse-base(37).say;
camelia rakudo-moar 4e7ab2: OUTPUT«Radix 37 out of range (allowed: 2..36)␤ in block <unit> at <tmp> line 1␤␤Actually thrown at:␤ in block <unit> at <tmp> line 1␤␤»
TEttinger m: 'perl'.parse-base(30).say;
camelia rakudo-moar 4e7ab2: OUTPUT«688431␤»
TEttinger m: 'perl'.parse-base(28).say; 19:37
camelia rakudo-moar 4e7ab2: OUTPUT«560553␤»
TEttinger m: 'perl6'.parse-base(28).say;
camelia rakudo-moar 4e7ab2: OUTPUT«15695490␤»
19:38 KotH joined 19:45 mawkish__ joined 19:47 pyrimidine joined 19:54 pyrimidine left
agentzh i'm writing a perl 6 program with 8K LOC and 46 compilation units. the biggest hurdle i'm facing is that everytime i edit a single .pm6 file, it takes for total 6 ~ 12 sec to compile and load in rakudo :( 20:12
yoleaux 26 Jan 2017 02:34Z <MasterDuke> agentzh: according to timotimo, 'will probably have to "up" a few times until you find a frame that has "tc" in it', before the `print MVM_dump_backtrace(tc)`
agentzh MasterDuke: maybe it can be automated by a gdb python extension? like this? github.com/openresty/openresty-gdb-utils#lbt 20:13
i wonder if anyone has ever worked on a perl 6 (not nqp) project of this size. 20:14
the delay on compilation is unbearable i'm afraid.
my laptop is a mid-2015 15 inch macbook pro with the best CPU and biggest ram in that model. 20:15
without the .precomp cache, it takes more than 30 sec to compile and load everythign.
i have another perl 5 project of 16K LOC planned to be ported to Perl 6. but now it seems that even the current 8K LOC perl 6 project is not feasible for simple editing and hacking :( 20:17
will anyone give me some insights here?
RAKUDO_MODULE_DEBUG=1 shows that rakudo is precompiling other unchanged compilation units. 20:18
gfldex Rakudo is far from fast yet, there is a lot of work to be done.
agentzh solely compiling the current edited compilation unit is fast enough.
gfldex also, you may have written your Perl 6 project in Perl 5.
brokenchicken agentzh: do the unchanged depend on the changed? 20:19
agentzh wondering if it's possible to convince rakudo to avoid recompiling other unchanged compilation units.
brokenchicken: yes.
brokenchicken agentzh: well, that's why it's recompiling them.
agentzh brokenchicken: can this be disabled?
brokenchicken: since i seldom or never change the API 20:20
brokenchicken agentzh: but you'd get broken then
*broken code
gfldex agentzh: do you code functional?
agentzh brokenchicken: wondering if it's possible to do API validation automatically.
in C, we have the header files for the API protocol.
so if the header files do not change, no need to recompile other cu.
gfldex: i use OO exclusively. 20:21
20:21 wololoooo joined
gfldex C got a linker while Perl 6 cant 20:21
agentzh just need suggestions to get over the compilation time hurdle.
it makes me feel like hacking on the oldest machine in the world :)
gfldex I try to avoid OO with Perl 6 because functional tends to be less self-entangling 20:22
brokenchicken agentzh: Have a preprocessor shove all of them into a single file before compilation?
agentzh gfldex: i can't avoid OO since the whole thing is a compiler that relies on OO for AST representation and transformation.
brokenchicken That's what we do with rakudo's files 20:23
agentzh turning it into functional style like in Haskell results in a lot of "copying rules" and code duplication which i learned from my haskell compiler.
brokenchicken: why a single file? 20:24
brokenchicken: i do not have a preprocessor.
gfldex Rakudo will scan quite a few directories every time you `use Module;` 20:25
agentzh gfldex: i don't think those scans can take several seconds will they? 20:26
i have a very fast PICe SSD.
gfldex the problem is not the storage system
agentzh tell me more :) 20:27
it seems to be CPU intensive.
100% of moar most of the time. 20:28
100% CPU
gfldex IO didn't get optimised much yet and the compiler isn't smart enough yet to avoid creating loads of objects just to thow them away after using them once
it's mostly memory bound actually
but a CPU waiting for the cache to deliver will wait 100% of the time 20:29
agentzh so the workaround is to concatenate everything into a single pm6 or p6 file?
gfldex yes
agentzh seems like i also need to rewrite "unit class foo" in my .pm6 file preprocessor :) 20:30
okay, i'll try.
thanks for the suggestion.
timotimo it'd be a lot of work to make our serialization scheme work with re-using old versions if "nothing changed"
well, really you want to have existing code work with new versions of their dependencies without recompiling the new thing
... i might be misunderstanding
but we essentially have a bunch of references to IDs of things rather than some identifier that might stay the same 20:31
agentzh timotimo: i just want rakudo only to recompile CUs that do not change since the last compilation. 20:37
timotimo: i just want rakudo avoid recompiling CUs that do not change since the last compilation. 20:38
timotimo right. when a CU doesn't change, it won't be recompiled
gfldex that's a lot harder then one might think
timotimo but if its dependency is no longer available, it has to change
gfldex for one you can't trust filesystem much
20:39 araujo left
timotimo well, we already check sha1sum i believe 20:39
gfldex GNU Make acutally tries to detect clock skews when running on nfs
20:39 araujo joined 20:40 azertus left
brokenchicken agentzh: OOC you don't have any extra dirs you add with `use lib` or -I, other than the dir that just has modules, right? 20:41
agentzh: for filysystem CUR, rakudo collects all the files in -I and shas them. That can be very slow if the path has lots of files in it 20:42
gfldex i wonder if Rakudo could steal gits sha1s 20:43
zfs and btrfs got them already too, but sadly they wont tell 20:44
20:45 pmurias left
agentzh brokenchicken: right, i only have -Ilib on the perl6 command line. and no use of "use lib". 20:48
20:56 ocbtec left
MasterDuke agentzh: could you compile with --profile-compile and see what exactly the slow parts are? 21:04
agentzh MasterDuke: --profile-compile leads to an infinite loop as reported here: rt.perl.org/Public/Bug/Display.htm...et-history 21:06
also checked with the latest git nom branch version, same result. 21:07
21:07 domidumont joined
agentzh seems like the all-in-one processor is trickier than i thought. 21:07
also need to take care of the dependency relationships in the CUs myself. 21:08
otherwise it's complaining about unknown parent classes.
cale2 I think I found a gap in the documentation
MasterDuke hmm, that sucks. how about a perf record of the compile?
cale2 m: say ~<hello world>.sort; 21:09
camelia rakudo-moar af4902: OUTPUT«hello world␤»
cale2 Can't find where it explains this
brokenchicken cale2: the precedence table should be it. 21:10
agentzh MasterDuke: oops, sorry, i forgot to remove the RAKUDO_MODULE_DEBUG=1 env on my side.
MasterDuke: now loading the profile html file in my chrome browser.
expected to take a long time due to the file size.
MasterDuke you might want to try the QT viewer 21:11
Geth ook: WildYorkies++ created pull request #86:
Update Preface and Operators
gfldex cale2: word quoting is explained here (kind of) docs.perl6.org/language/quoting#Wo...g:_%3C_%3E
Geth ook: 970a2c4722 | Cale++ | 2 files
Update Preface and Operators (#86)

  * Add file extension to open('scores')
Did not compile without this.
  * Update basics.pod
... (14 more lines)
gfldex cale2: prefix ~ is explained here docs.perl6.org/language/operators#prefix_~ 21:12
cale2 specifically the tilde on front though
gfldex and .sort comes from Any
cale2: postfix . is explained here docs.perl6.org/language/operators#postfix_. 21:14
cale2 No, putting the ~ in front of <>
and it automatically strings them together
gfldex that just prefix ~
cale2 G2G
gfldex we may be missing .Str tho 21:15
21:16 wololoooo left, domidumont left, wamba joined
gfldex we are 21:18
21:19 cale2 left
gfldex no we don't but it's not in the index 21:21
21:23 araujo left
Geth oc: 7d4cc9859b | (Wenzel P. P. Peppmeyer)++ | doc/Language/operators.pod6
link to method Str
21:23
21:26 agentzh left 21:28 agentzh joined 21:29 mawkish__ left
Geth oc: cd0f6ff9b2 | (Wenzel P. P. Peppmeyer)++ | doc/Type/List.pod6
- get a bunch of routines into the index
21:31
gfldex cale2++
21:34 bjz joined, MasterDuke left 21:35 cdg left, cdg joined 21:37 azertus joined 21:38 Cabanossi left, agentzh left 21:39 cdg left, MasterDuke joined 21:40 Cabanossi joined 21:44 pyrimidine joined 21:45 wamba left, wamba joined 21:55 trnh left, mawkish__ joined
samcv Parameter '$aliases' expected a writable container, but got Hash value 21:57
what is the weirdness of % sigil items? i cann't have my signature be: sub ($hash is rw and pass a hash in?
21:59 agentzh joined
gfldex samcv: did you try `\hash is rw`? 21:59
samcv nope. will try that
i know i've done this before hmm
Can only use 'is rw' on a scalar ('$' sigil) parameter 22:00
do i have to choose 'is rw' if the variable i'm passing to the sub is file scoped? 22:01
gfldex well, %-sigiled containers are never ro anyway
the error message is LTA tho 22:02
the Hash object is but it's mutator methods are not 22:03
so a rw on the outer container doesn't make much sense
samcv so what do I need to do?
gfldex either use %-sigiled containers in your sig or allow the container to be ro 22:04
the content of the Hash will never be ro
samcv allow the container to be ro? i don't understand that part
gfldex use a HashSet if you need immutable Hashy containers
22:05 mawkish__ left
gfldex or is it SetHash 22:05
`?
samcv it is a normal hash
22:05 mawkish__ joined
gfldex no wait SetHash is mutable 22:06
samcv: what do you actually want to achieve? 22:09
samcv i just want to be able to write to the hash inside the sub, write to the hash i pass through
so you are saying hash's never need to set rw, because they always are?
gfldex m: sub f(%h){ %h<a> = 1 }; my %h; dd f %h; 22:10
camelia rakudo-moar af4902: OUTPUT«1␤»
gfldex well, the inner containers are mutable and autovivifying, the outer container (%h in the sig) can not be rebound. 22:11
samcv what do you mean by can not be rebound? 22:12
gfldex %-sigiled and @-sigiles containers are always containers of containers. So you need to tell the compiler (and us) what containers you refer to
MasterDuke m: sub f(%h){ %h<a> = 1 }; my %h; f %h; dd %h # i think this is a little more obvious
camelia rakudo-moar af4902: OUTPUT«Hash %h = {:a(1)}␤»
gfldex m: sub f(%h){ %h := Hash.new; }; my %h; dd f %h;
camelia rakudo-moar af4902: OUTPUT«{}␤»
agentzh MasterDuke: --profile-compile result: The profiled code ran for 6813.8ms. Of this, 188.8ms were spent on garbage collection and dynamic optimization (that's 2.77%).
is that helpful?
gfldex huh? 22:13
m: sub f(%h){ %h := Hash.new; }; my %h = a => 1; dd f %h;
camelia rakudo-moar af4902: OUTPUT«{}␤»
gfldex :-|
MasterDuke agentzh: in the routines view, what on top if you sort by exclusive time?
brokenchicken doesn't see a problem
22:15 lukaramu left
brokenchicken samcv: Hashes/Arrays and ilk are objects. Subs making them read-only would mean some black magic that would freeze attributes and know which methods mutate things inside. Hence why $param doesn't need `is rw` if you're just modifying hash contents. Assigning to %foo or @foo would call methods on them so is rw doesn't make sense on them 22:15
jdv79 lets say i have a role that provides a private attr and i want another role to be able to access it
samcv kk
jdv79 how do i do that?
brokenchicken Whereas with $ assignment would change the container's value, and so `is rw` is there to controll that
samcv i understand it 22:16
agentzh MasterDuke: loading the routines view.
gfldex m: sub f($h is readonly){ $h<b> = 2 }; my %h = a => 1; f %h;
camelia ( no output )
agentzh hmm, the all-to-one preprocess also has to deal with exported subs in some CUs.
seems like we need to share such preprocessors :) 22:17
gfldex jdv79: jdv79 did you try `trusts`?
22:17 wamba left, wamba joined
brokenchicken jdv79: don't think you can (at least without nqp) 22:19
m: use nqp; role Foo { has $!x = 42; }; role Bar { method foo { nqp::getattr(self, ::?CLASS, '$!x') } }; class :: does Foo does Bar {}.new.foo.say 22:21
camelia rakudo-moar af4902: OUTPUT«42␤»
agentzh alas. exported functions are hard to deal with in the all-in-one script generator.
any tricks for this?
Geth oc: 3d3b2b8c29 | (Wenzel P. P. Peppmeyer)++ | doc/Type/Signature.pod6
doc is readonly
22:23
gfldex samcv++
samcv hmm?
brokenchicken gfldex: explicitely
gfldex In #perl6 you get bonus points for not knowing stuff and asking questions. 22:24
samcv ah.
Geth oc: 7e6e6d946a | (Wenzel P. P. Peppmeyer)++ | doc/Type/Signature.pod6
fix spelling
22:25 Cabanossi left 22:26 Cabanossi joined
MasterDuke gfldex: "To explicitly as for", should be "ask", right? 22:26
gfldex yes
i don't got much sleep last night
Geth oc: 7bac7a1053 | (Wenzel P. P. Peppmeyer)++ | doc/Type/Signature.pod6
fix more typos
22:27
22:28 wamba1 joined 22:29 wamba1 left
Geth oc/master: 17 commits pushed by gfldex++
review: github.com/perl6/doc/compare/7bac7...c122064ab7
22:32
22:37 pyrimidine left
jdv79 the way priv attrs are handled seems quite restrictive 22:38
aka annoying
let's say i have a class, A, that does 2 roles, B and C - is there no way for that trio to share a priv attr? 22:39
or do i have to combine B and C just for that reason?
gfldex I don't think they should. Private really means private. 22:40
jdv79 seems that would lead to god roles
gfldex don't make them private then
jdv79 private in this context to me is jut not accessble outside the instance
what mechanism is there for that then?
gfldex in that case you can overload the accessor method
jdv79 ok. seems hacky but that'll do. 22:41
22:41 rindolf left
gfldex m: class C { has $.a = 42; method a {!!!} }; say C.new; say C.new.a 22:41
camelia rakudo-moar af4902: OUTPUT«C.new(a => 42)␤Stub code executed␤ in method a at <tmp> line 1␤ in block <unit> at <tmp> line 1␤␤»
brokenchicken jdv79: what you're doing sounds hacky :) Your question framed differently: "how can I make a role that accesses an undeclared symbol that may or not be there when the role is composed" 22:43
jnthn Could also declare a private method, fwiw 22:44
agentzh MasterDuke: in the exclusive time sort view of routines, get SETTING::src/core/IO/Handle.pm:128 takes 88% of the time.
brokenchicken Ah, right! jnthn++
jnthn I'm generally glad of Perl 6's tight scoping rules on private attributes.
agentzh the 2nd ranked one is SET_BLOCK_OUTER_CTX gen/moar/stage2/NQPHLL.nqp:1213 which takes 0.57%.
22:45 mawkish__ left
agentzh it's strange that IO::Handle takes most of the time. 22:45
in the rakudo compiler.
22:45 mawkish__ joined
agentzh seems like a low hanging fruit for rakudo developers? 22:45
MasterDuke line 128 is get() 22:46
agentzh MasterDuke: yes
jdv79 brokenchicken: the role is composed where hte attr exists
well, it would be if that worked
MasterDuke which has been optimized at the rakudo level
agentzh err
brokenchicken agentzh: more like nqp/moarvm developers. That method is a pretty bare collection of nqp ops
agentzh where should i report it? 22:47
MasterDuke agentzh: it now needs work at the moarvm level, but there are fewer people who can do that
agentzh at #moarvm ?
22:48 mawkish__ left 22:49 mawkish__ joined 22:50 rindolf joined
jdv79 yeah, priv method might be better 22:51
jnthn: thanks
gfldex I just realised that I'm turning the docs from being holely to being holy. :-> 22:52
22:53 mawkish__ left, mawkish__ joined
gfldex I better go to bed before my sleep deprived mind gets me to start a new religion. 22:54
good * #perl6
brokenchicken night 22:55
22:58 zakharyas joined 23:04 espadrine_ left 23:05 wamba1 joined 23:07 wamba1 left 23:09 Tonik left 23:17 wamba is now known as wambash 23:24 lep-delete left, bjz left 23:27 lep-delete joined
RabidGravy on a quick test an RPi 3 compiles rakudo twice as fast as a RPi 2 23:34
23:35 avuserow left
jnthn RabidGravy: How long, ooc? 23:36
RabidGravy about 15 mins on the 3 23:37
23:38 Cabanossi left 23:39 travis-ci joined
travis-ci Doc build errored. Wenzel P. P. Peppmeyer 'Merge pull request #1166 from antquinonez/master 23:39
travis-ci.org/perl6/doc/builds/196228767 github.com/perl6/doc/compare/7bac7...22064ab7f0
23:39 travis-ci left 23:40 Cabanossi joined 23:42 zakharyas left, RabidGravy left 23:50 Rawriful left 23:51 pyrimidine joined 23:56 rindolf left, wambash left 23:59 saki joined, agentzh left