| 2019-03-29 |
| ← llfourn left | 00:00 |
| → llfourn joined | 00:03 |
| ← llfourn left | 00:07 |
| → llfourn joined | 00:10 |
| ← llfourn left | 00:15 |
| ← netrino_ left | 00:15 |
|
Xliff
| ctilmes: LOL! Thinking about it. | 00:16 |
|
ugexe
| m: print((($_ eq "e") and uc($_) or $_)) for split("", "Perl Weekly Challenge"); # polyglot for the beginner challenge, too | 00:23 |
|
camelia
| rakudo-moar b5bf7cd4f: OUTPUT: «PErl WEEkly ChallEngE» | 00:23 |
| ← learningprogged left | 00:30 |
| ← zachk left | 00:34 |
|
ugexe
| m: my $count; print((($_ eq "e" and $count++) and uc($_) or $_)) for split("", "Perl Weekly Challenge\n"); print($count) | 00:37 |
|
camelia
| rakudo-moar b5bf7cd4f: OUTPUT: «Perl WEEkly ChallEngE5» | 00:37 |
|
ugexe
| m: my $count; print((($_ eq "e" and ++$count) and uc($_) or $_)) for split("", "Perl Weekly Challenge\n"); print($count) | 00:37 |
|
camelia
| rakudo-moar b5bf7cd4f: OUTPUT: «PErl WEEkly ChallEngE5» | 00:37 |
|
timotimo
| m: $_ = "perl weekly challenge"; say +tr/e/E/ | 00:40 |
|
camelia
| rakudo-moar b5bf7cd4f: OUTPUT: «5» | 00:40 |
|
timotimo
| m: $_ = "perl weekly challenge"; say +tr/e/E/; .say | 00:40 |
|
camelia
| rakudo-moar b5bf7cd4f: OUTPUT: «5pErl wEEkly challEngE» | 00:40 |
| → ^020d26 joined | 00:44 |
| ← ^020d26 left | 00:44 |
| ← leont left | 00:52 |
| → onefst250r joined | 00:53 |
| ← onefst250r left | 00:53 |
| → w_richard_w joined | 00:53 |
| → dau6 joined | 00:56 |
| ← dau6 left | 00:56 |
|
ugexe
| but mine is way faster | 01:07 |
|
| what if you had to run that 100000 times | 01:07 |
|
| and only had 2.5s | 01:07 |
|
| how would you scale this out? | 01:10 |
|
timotimo
| i'll multithread it on my swarm of 128-core machines | 01:13 |
| → MidCheck joined | 01:16 |
| → isomorphismes_ joined | 01:17 |
| → RamShadow11 joined | 01:18 |
|
isomorphismes_
| Perl 6 seems like the right place to put an end to ^ meaning "BEGINNING" and $ meaning "END" because of the (a) widespread sanity of the community (b) p6 grammars (c) support for unicode | 01:18 |
| ← RamShadow11 left | 01:18 |
|
ugexe
| we doubled down on it and have ^^ and $$ too | 01:18 |
|
isomorphismes_
| if I make some commits to rakudo making stuff like https://www.fileformat.info/info/unicode/char/2403/index.html, U+0004 (EOT), alias / synonymous for BEGIN and END, is that likely to be accepted? | 01:19 |
|
| ugexe: that's clearer imo | 01:19 |
|
ugexe
| its not quite the same thing | 01:19 |
|
isomorphismes_
| ugexe: ^^ and $$ are clearer to read. But so would END and BEGIN be. | 01:19 |
|
| yeah, there are a variety of candidates in https://unicode-search.net/unicode-namesearch.pl?term=END | 01:19 |
|
| like "syriac end of paragraph" (sounds likea good one) | 01:20 |
|
| U+220e (\xe2 \x88 \x8e), end of proof, could work too | 01:20 |
|
| ugexe: dollars aren't quite the same as EOL, either ... | 01:20 |
|
| I mean, unless there's going to be a lot of people wanting to match the capital strings BEGIN and END for very common $ and ^ functionality, might as well alias those ascii strings too .... no? | 01:21 |
|
ugexe
| BEGIN and END are already perl6 things | 01:21 |
|
isomorphismes_
| ah sorry | 01:22 |
|
| still learning the lang | 01:22 |
|
ugexe
| m: END say 2; BEGIN say 1; | 01:22 |
|
camelia
| rakudo-moar b5bf7cd4f: OUTPUT: «12» | 01:22 |
|
isomorphismes_
| thank you ugexe | 01:22 |
|
| https://unicode-search.net/unicode-namesearch.pl?term=START has U+2402 = \xe2 \x90 \x82 = ␂ | 01:24 |
|
| I just mean, "stuff like this" | 01:24 |
|
| Would it be worth the commit? Or no rakudo members will want to take it in? | 01:24 |
|
ugexe
| m: grammar MyGrammar { token XXX { ^ }; token ZZZ { $ }; token TOP { <XXX> foo <ZZZ> } }; say so MyGrammar.parse("fo"); say so MyGrammar.parse("foo"); | 01:27 |
|
camelia
| rakudo-moar b5bf7cd4f: OUTPUT: «FalseTrue» | 01:27 |
|
ugexe
| https://docs.perl6.org/language/regexes#Summary_of_anchors | 01:29 |
|
| if you want to propose something i would suggest coming up with something that can be applied and consistent across the other anchors (or most of them) | 01:30 |
|
MasterDuke
| isomorphismes_: you might be able to do it as a slang, which you could publish as a module first | 01:30 |
|
ugexe
| e.g. if ^ is "START UNICODE THING", then what is ^^? | 01:30 |
|
| figure that out for the other anchors, then come up with theoretical examples that demonstrate the added value to the user | 01:31 |
|
| making a module out of it is one way to do that | 01:32 |
| → kellabyte29 joined | 01:33 |
| ← kellabyte29 left | 01:33 |
|
isomorphismes_
| MasterDuke: thank you | 01:40 |
|
| ugexe: I was intending just to alias, not replace | 01:40 |
|
| see if there is any uptake besides myself | 01:41 |
|
| glad you guys use the .party TLD (tpm-regex.perl6.party) | 01:43 |
| → Guest41066 joined | 01:44 |
| ← Guest41066 left | 01:44 |
| ← ctilmes left | 01:44 |
|
Geth
| ¦ doc: 39b1b74399 | cfa++ | doc/Language/py-nutshell.pod6 | 01:45 |
|
synopsebot
| Link: https://doc.perl6.org/language/py-nutshell | 01:45 |
|
Geth
| ¦ doc: Fix typo. | 01:45 |
|
| ¦ doc: review: https://github.com/perl6/doc/commit/39b1b74399 | 01:45 |
| → robijkn11 joined | 01:57 |
| ← robijkn11 left | 01:57 |
| ← molaf left | 02:03 |
| → llfourn joined | 02:08 |
| ← llfourn left | 02:13 |
| ← aindilis left | 02:15 |
| → aindilis joined | 02:19 |
| → Ooze7 joined | 02:23 |
| ← Ooze7 left | 02:23 |
| ← ExtraCrispy left | 02:30 |
| → ExtraCrispy joined | 02:30 |
| → llfourn joined | 02:32 |
| ← llfourn left | 02:37 |
| → melezhik joined | 02:43 |
|
melezhik
| Hi! Has anyone experienced extremly slow zef install for one of their modules. I am stuck with performance issue - https://www.reddit.com/r/perl6/comments/b6hnog/first_perl_weekly_challenge_thoughts_perl5_and/ | 02:45 |
|
| and really don't know what to do with that | 02:45 |
|
| sorry wrong link | 02:46 |
|
| that's the one - https://www.reddit.com/r/perl6/comments/b6ilvx/how_to_improve_perl6_source_code_install/ | 02:46 |
| ← melezhik left | 02:53 |
| → llfourn joined | 03:10 |
| ← llfourn left | 03:15 |
| → ufobat__ joined | 03:22 |
| ← ufobat_ left | 03:25 |
| ← kst left | 03:51 |
| → kst joined | 03:52 |
| → teto1 joined | 03:57 |
| ← teto1 left | 03:57 |
| ← unicodable6 left | 04:57 |
| ← bloatable6 left | 04:57 |
| ← quotable6 left | 04:57 |
| ← undersightable6 left | 04:57 |
| ← reportable6 left | 04:57 |
| ← nativecallable6 left | 04:57 |
| ← coverable6 left | 04:57 |
| ← squashable6 left | 04:57 |
| ← statisfiable6 left | 04:57 |
| ← releasable6 left | 04:57 |
| ← benchable6 left | 04:57 |
| ← committable6 left | 04:57 |
| ← greppable6 left | 04:57 |
| ← bisectable6 left | 04:57 |
| ← notable6 left | 04:57 |
| ← shareable6 left | 04:57 |
| ← evalable6 left | 04:57 |
| → evalable6 joined | 04:58 |
| ChanServ set mode: +v | 04:58 |
| → squashable6 joined | 04:58 |
| → reportable6 joined | 04:58 |
| → releasable6 joined | 04:58 |
| ChanServ set mode: +v | 04:58 |
| → statisfiable6 joined | 04:59 |
| ChanServ set mode: +v | 04:59 |
| → greppable6 joined | 04:59 |
| → undersightable6 joined | 05:00 |
| → notable6 joined | 05:00 |
| ChanServ set mode: +v | 05:00 |
| → benchable6 joined | 05:00 |
| ChanServ set mode: +v | 05:00 |
| → bisectable6 joined | 05:00 |
| → committable6 joined | 05:01 |
| → unicodable6 joined | 05:01 |
| ChanServ set mode: +v | 05:01 |
| → quotable6 joined | 05:01 |
| ChanServ set mode: +v | 05:01 |
| → bloatable6 joined | 05:02 |
| → coverable6 joined | 05:02 |
| → nativecallable6 joined | 05:02 |
| ChanServ set mode: +v | 05:02 |
| → shareable6 joined | 05:02 |
| ← dustinm` left | 05:06 |
| → sauvin joined | 05:07 |
| → dustinm` joined | 05:10 |
| → llfourn joined | 05:11 |
| ← llfourn left | 05:16 |
| ← w_richard_w left | 05:54 |
| → domidumont joined | 06:24 |
| → aborazmeh joined | 06:34 |
| ← aborazmeh left | 06:34 |
| → aborazmeh joined | 06:34 |
| ← pistacchio left | 06:35 |
| → pistacchio joined | 06:36 |
| → molaf joined | 06:36 |
| → kurahaupo_ joined | 06:44 |
| kurahaupo_ → kurahaupo | 06:45 |
| ← mowcat left | 06:46 |
| ← cpan-p6 left | 06:48 |
| → cpan-p6 joined | 06:49 |
| ← cpan-p6 left | 06:49 |
| → cpan-p6 joined | 06:49 |
|
Geth
| ¦ doc: ff25568778 | (JJ Merelo)++ | doc/Language/classtut.pod6 | 07:03 |
|
| ¦ doc: Expands explanation on `is rw` trait | 07:03 |
|
| ¦ doc: | 07:03 |
|
| ¦ doc: With new examples, and a reference to `is rw` on the whole class. It | 07:03 |
|
| ¦ doc: was probably better where it is, in classtut, rather than in the | 07:03 |
|
synopsebot
| Link: https://doc.perl6.org/language/classtut | 07:03 |
|
Geth
| ¦ doc: typesystem, which didn't seem to have (at least now, 18 months after | 07:03 |
|
| ¦ doc: OP) a place for it. This closes #1572 | 07:03 |
|
| ¦ doc: review: https://github.com/perl6/doc/commit/ff25568778 | 07:03 |
|
| ¦ doc: 3ea709ac2f | (JJ Merelo)++ | doc/Language/phasers.pod6 | 07:03 |
|
synopsebot
| Link: https://doc.perl6.org/language/phasers | 07:03 |
|
Geth
| ¦ doc: Rephrases LAST explanation to clarify, closes #2701 | 07:03 |
|
| ¦ doc: review: https://github.com/perl6/doc/commit/3ea709ac2f | 07:03 |
| → |oLa| joined | 07:03 |
| ← |oLa| left | 07:03 |
| → llfourn joined | 07:11 |
| ← molaf left | 07:11 |
| ← domidumont left | 07:14 |
| ← llfourn left | 07:15 |
| → reach_satori_ joined | 07:22 |
| → |oLa| joined | 07:23 |
| ← reach_satori left | 07:23 |
| → domidumont joined | 07:29 |
| ← MidCheck left | 07:35 |
| → w_richard_w joined | 07:44 |
| ← |oLa| left | 07:52 |
| → |oLa| joined | 07:55 |
| ← |oLa| left | 07:56 |
| ← w_richard_w left | 07:56 |
| ← reach_satori_ left | 08:00 |
| ← nebuchadnezzar left | 08:13 |
| → nebuchadnezzar joined | 08:13 |
| ← aborazmeh left | 08:15 |
| → MidCheck joined | 08:19 |
| → ravenousmoose joined | 08:19 |
| ← dustinm` left | 08:20 |
| ← random_yanek left | 08:26 |
| → |oLa| joined | 08:28 |
| → netrino joined | 08:28 |
| → dustinm` joined | 08:29 |
| ← |oLa| left | 08:30 |
| → reach_satori_ joined | 08:41 |
| → rindolf joined | 08:44 |
| → robertle_ joined | 08:47 |
| ← squashable6 left | 08:48 |
| → squashable6 joined | 08:51 |
| ChanServ set mode: +v | 08:51 |
| → llfourn joined | 08:53 |
| → Actualeyes joined | 09:04 |
|
xinming
| For hyper method call operator, @array>>.meth(); Can I think it is almost the same as await @array.map: start { $_.meth() }; ?? | 09:07 |
|
masak
| xinming: by spec it's parallel like that, yes. I don't know that Rakudo actually parallelizes it. | 09:08 |
|
timotimo
| i'd probably expect it to be equivalent to @array.hyper.map(*.meth), in particular it'd probably batch many values together to one work unit | 09:12 |
| → hanzi joined | 09:14 |
|
hanzi
| loop { my $x; say ++$x; } | 09:14 |
|
| is this supposed to produce (output) a constant value of $x of 1? | 09:15 |
|
| in the documentation i was not able to find any mention of how my causes initialization in each looping of a loop | 09:16 |
| ← cgfbee left | 09:17 |
|
moritz
| hanzi: yes | 09:18 |
|
hanzi
| many thanks! | 09:19 |
|
moritz
| hanzi: and you didn't find any documentation because it's not different for loops than for any other block | 09:19 |
|
hanzi
| where can i find that info in the doc? | 09:19 |
|
| was not looking wrt loops, just in general, and did not find | 09:19 |
|
| looked in https://docs.perl6.org | 09:19 |
|
| and in https://perl6intro.com/ | 09:20 |
|
moritz
| I'd expect something in https://docs.perl6.org/language/variables | 09:20 |
| → cgfbee joined | 09:21 |
|
moritz
| if not, please open an issue according to https://github.com/perl6/doc/blob/master/CONTRIBUTING.md#reporting-bugs | 09:21 |
|
hanzi
| ok, thanks, in any case, i think this is rather fundamental info that should be present in the introduction of the my declarator | 09:23 |
| ← netrino left | 09:24 |
|
masak
| hanzi: you're not wrong. | 09:24 |
|
| though, as moritz++ points out, it's less to do about loops and more about blocks and block entry | 09:24 |
|
| m: sub foo { my $x; say ++$x }; foo() for ^3 | 09:25 |
|
camelia
| rakudo-moar b5bf7cd4f: OUTPUT: «111» | 09:25 |
|
masak
| same deal ^ | 09:25 |
|
moritz
| the problem is that everybody has different expectations about what belong into an introduction | 09:25 |
|
hanzi
| thanks, just to be clear, my example was not meant to focus on loops | 09:25 |
|
| was just an example, maybe not the best one | 09:25 |
|
moritz
| some people are familiar with how lexical variables are initialized in most programming languages, and Perl 6 behaves consistently with that | 09:25 |
|
masak
| part of the difficulty, I think, is that there's no good *word* for that thing in memory "behind" the lexical variable of which there's one per block entry/frame | 09:25 |
|
El_Che
| moritz: btw, I saw your fundamentals book in in O'Reilly's safari | 09:25 |
|
| not the 2nd one | 09:25 |
|
moritz
| others find the behavior so intuitive that they don't need an explanation | 09:26 |
|
| others want an explanation | 09:26 |
| → zakharyas joined | 09:26 |
|
moritz
| sure, you can add it, but there simply soooo many things that could be explained in an introduction | 09:26 |
|
| what I really want is some semi-interactive website that starts with something like: "Lexical variables are declared with `my`, like in `my $x` or `my $y = 42` | 09:27 |
|
| and then there's a small symbol that you click on, which expands to a more detailed explanation of how lexicals work | 09:27 |
| ← cpan-p6 left | 09:28 |
|
moritz
| I think sjn++ was working on a project for books that support something like this, though I don't know if it went anywhere | 09:28 |
| → cpan-p6 joined | 09:28 |
| ← cpan-p6 left | 09:28 |
| → cpan-p6 joined | 09:28 |
|
hanzi
| good info, thanks for the help | 09:31 |
| → molaf joined | 09:42 |
| → random_yanek joined | 09:49 |
| ← random_yanek left | 09:49 |
| → random_yanek joined | 09:50 |
| ← Black_Ribbon left | 10:03 |
| ← Harzilein left | 10:20 |
| → antoniogamiz joined | 10:26 |
| ← MidCheck left | 10:28 |
| ← Woodi left | 10:33 |
| ← pistacchio left | 10:34 |
| → pistacch_ joined | 10:35 |
| ← hanzi left | 10:45 |
| → Woodi joined | 10:46 |
| → pistacchio joined | 10:49 |
| ← pistacchio left | 10:51 |
| ← pistacch_ left | 10:52 |
| → pistacchio joined | 10:52 |
| ← domidumont left | 10:52 |
| → MidCheck joined | 11:07 |
| → andrzejku_ joined | 11:17 |
| ← andrzejku left | 11:19 |
| andrzejku_ → andrzejku | 11:19 |
| → pincher joined | 11:22 |
| ← nekomune left | 11:25 |
| ← pincher left | 11:25 |
| → nekomune joined | 11:29 |
| → leont joined | 11:40 |
| ← andrzejku left | 11:40 |
| ← kurahaupo left | 11:51 |
| ← pistacchio left | 11:53 |
|
gks
| what would be the easiest way in perl 6 to download a binary file over HTTP and saving it to a file (with a given name)? | 11:53 |
|
| basically i want `curl https://someurl.com > myfile` | 11:54 |
| → pistacchio joined | 11:54 |
| ← zakharyas left | 11:54 |
|
tbrowder
| ctilmes: your DB::SQLite module is excellent! thanks | 11:54 |
| → pecastro joined | 11:55 |
|
tbrowder
| for an easy-to-use module that eases sqlite use immensely. | 11:55 |
|
timotimo
| easier than using DBIish? | 11:56 |
| ← pistacchio left | 11:58 |
|
kawaii
| m: say so Nul; | 12:00 |
|
camelia
| rakudo-moar b5bf7cd4f: OUTPUT: «=== SORRY!=== Error while compiling <tmp>Undeclared name: Nul used at line 1. Did you mean 'Nil', 'Num'?» | 12:00 |
|
kawaii
| blah | 12:00 |
|
| m: say so Nil; | 12:00 |
|
camelia
| rakudo-moar b5bf7cd4f: OUTPUT: «False» | 12:00 |
|
kawaii
| $level = Nil, which is False, so why does this unless not work? https://www.irccloud.com/pastebin/y7ch9aCq/ | 12:01 |
|
tbrowder
| timotimo: for me, yes. but i haven't tried DBlish in a while and Curt's examples scratched an itch. | 12:05 |
| ← abraxxa left | 12:09 |
| → abraxxa joined | 12:09 |
|
lizmat
| m: my $a is default(42) = 666; say $a; $a = Nil; say $a | 12:16 |
|
camelia
| rakudo-moar b5bf7cd4f: OUTPUT: «66642» | 12:16 |
|
lizmat
| kawaii: ^^^ | 12:16 |
|
| oops, should have looked at the paste | 12:17 |
|
| m: my $a = ~Nil; say "foo" if $a | 12:17 |
|
camelia
| rakudo-moar b5bf7cd4f: OUTPUT: «Use of Nil in string context in block <unit> at <tmp> line 1» | 12:17 |
|
lizmat
| kawaii: not sure :-( | 12:19 |
|
kawaii
| bug, maybe? | 12:19 |
|
lizmat
| m: my $a = ~Nil; say "foo" unless $a # seems to work in this case | 12:20 |
|
camelia
| rakudo-moar b5bf7cd4f: OUTPUT: «Use of Nil in string contextfoo in block <unit> at <tmp> line 1» | 12:20 |
|
lizmat
| kawaii: do you see that warning as well in your code ? | 12:20 |
|
kawaii
| Yes, exactly as it says | 12:20 |
|
| so I'm certain $level = Nil | 12:20 |
|
| https://www.irccloud.com/pastebin/Opb7I2BD/ | 12:21 |
|
lizmat
| no, $level is "" | 12:21 |
|
kawaii
| lizmat: this code works fine | 12:21 |
|
lizmat
| stringification of Nil is "" | 12:21 |
|
kawaii
| ah | 12:21 |
|
lizmat
| without stringification of Nil, it would be Any | 12:21 |
|
| m: my $a = Nil; dd $a | 12:21 |
|
camelia
| rakudo-moar b5bf7cd4f: OUTPUT: «Any $a = Any» | 12:21 |
|
kawaii
| understood :) | 12:21 |
|
| m: say so ""; | 12:22 |
|
camelia
| rakudo-moar b5bf7cd4f: OUTPUT: «False» | 12:22 |
|
kawaii
| even so, it should still work :( | 12:22 |
|
lizmat
| yeah... | 12:22 |
|
| perhaps a "dd $level" before the unless to make doubly sure that $level contains what we think it should contain ? | 12:23 |
|
| perhaps it contains 1 for the number of elements ? | 12:23 |
| ← leont left | 12:26 |
| → sergot joined | 12:27 |
| → pistacchio joined | 12:29 |
|
kawaii
| lizmat: `List $level = $("",)` | 12:30 |
|
| dd result ^ | 12:30 |
|
lizmat
| m: say "foo" if $("",) | 12:31 |
|
camelia
| rakudo-moar b5bf7cd4f: OUTPUT: «foo» | 12:31 |
|
lizmat
| so you got a 1 elem list with a "" in it | 12:31 |
|
kawaii
| let me go look at the code we use to create $level... | 12:31 |
|
lizmat
| :-) | 12:32 |
| → ctilmes joined | 12:32 |
|
kawaii
| so this block here handles which routine each detected command runs, and we create $args-str to populate other values based on this... https://www.irccloud.com/pastebin/rpYODJkQ/ | 12:33 |
|
| I'm going to refactor this anyway, to support a cleaner command syntax i.e. `!level (add|rm|list)` instead of hyphenated commands so probably not worth fixing right now :) | 12:34 |
| → sena_kun joined | 12:37 |
|
kawaii
| lizmat: wrapping $level in () fixes it for now :) | 12:38 |
|
lizmat
| yeah, that it would | 12:38 |
|
kawaii
| thanks for your help debugging! | 12:39 |
|
lizmat
| yw :-) | 12:39 |
| → domidumont joined | 12:42 |
| ← pistacchio left | 12:49 |
| → pistacchio joined | 12:49 |
| ← reach_satori_ left | 12:50 |
| ← Sigyn left | 12:52 |
| → Sigyn joined | 12:53 |
| ← antoniogamiz left | 12:55 |
| ← jast left | 13:00 |
| → jast joined | 13:00 |
| → lucasb joined | 13:01 |
|
gfldex
| lolibloggedalittle: https://gfldex.wordpress.com/2019/03/29/conditional-whenever/ | 13:07 |
| ← MidCheck left | 13:08 |
|
sena_kun
| gfldex, "displays to much or to little" <- is it a pun? | 13:09 |
|
gfldex
| sena_kun: would you believe me it I would say „yes“? :-> | 13:09 |
|
sena_kun
| gfldex, as a non-native folk, I'll do my best. ;) | 13:10 |
|
timotimo
| gfldex: it look like there's no space between ".tap" and "on the parameter" | 13:11 |
|
lizmat
| gfldex: also wheneveralways | 13:12 |
|
| gfldex: also s/paramter/parameter/ | 13:13 |
|
gfldex
| the spaces are an wordpress editor artifact | 13:13 |
|
| I solved it by adding 3 spaces, move the cursor a little and then remove 2 | 13:14 |
|
lizmat
| gfldex: is that the new WP editor ? | 13:14 |
|
gfldex
| yes | 13:14 |
|
| otherwise it's really nice | 13:15 |
|
lizmat
| *phew* glad to be using the old one | 13:15 |
|
gfldex
| you can inline `code` and start a code block with ``` | 13:15 |
|
lizmat
| for me, it worked actively against my P6W workflow | 13:15 |
|
gfldex
| and lots other neat stuff | 13:15 |
|
SmokeMachine
| gfldex: is your script using this? https://github.com/FCO/JSON-Stream | 13:18 |
|
gfldex
| yes | 13:18 |
|
SmokeMachine
| :) | 13:18 |
|
| gfldex: how was it? many problems? | 13:19 |
|
gfldex
| the documentation is a bit sparce and it doesn't forward closed input streams | 13:19 |
|
SmokeMachine
| gfldex: would you mind to open issues? | 13:20 |
|
gfldex
| SmokeMachine: would not help, because it can't forward that the input Supply is closed without breaking other stuff. | 13:21 |
|
SmokeMachine
| gfldex: sorry, I didn't get it... | 13:23 |
|
gfldex
| SmokeMachine: you need something like https://github.com/gfldex/bin/blob/master/iostat.p6#L138 to react to the closed input Supply. But then any script using the module trying to do the same got a problem. Also, 90% of all tests stopped working when I tried to fix it myself. | 13:28 |
| ← abraxxa left | 13:31 |
| → skids joined | 13:38 |
| → leont joined | 13:38 |
| → zakharyas joined | 13:44 |
| → MidCheck joined | 13:45 |
|
cpan-p6
| New module released to CPAN! Acme::Cow (0.0.3) by ELIZABETH | 13:59 |
| → reach_satori_ joined | 14:01 |
| ← nekomune left | 14:01 |
|
woolfy
| I love all the puns on this channel. | 14:01 |
|
| While most puns make me feel numb, mathematics puns make me feel number. | 14:01 |
| ← molaf left | 14:03 |
| → cpage_ joined | 14:04 |
| ← cpage left | 14:06 |
| cpage_ → cpage | 14:06 |
|
gfldex
| woolfy: I agree. This is a puntastic channel! | 14:07 |
| → nekomune joined | 14:08 |
|
El_Che
| don't be a pun in the ass | 14:09 |
| ← leont left | 14:10 |
|
moritz
| you pundits :D | 14:12 |
| → AlexDaniel joined | 14:22 |
|
woolfy
| It was easy as pi | 14:26 |
|
ctilmes
| tbrowder: ty | 14:26 |
|
| timotimo: For DBIish, SQLite is good because it actually works (DBIish is broken for Pg and MySQL) | 14:27 |
|
| timotimo: DB:* are nice because they maintain a cache of handles and you can perform DB actions from different threads without worrying about stepping on simultaneous database actions | 14:27 |
| ← Guest46123 left | 14:28 |
| → success joined | 14:29 |
| success → Guest49515 | 14:29 |
| → aborazmeh joined | 14:33 |
| ← aborazmeh left | 14:33 |
| → aborazmeh joined | 14:33 |
| ← ravenousmoose left | 14:38 |
| → learningprogged joined | 14:43 |
|
AlexDaniel
| gks: there are a bunch of modules, I'm not even sure which one is best :) | 14:44 |
|
| gks: if you want it be as close to curl as possible, then there's Net::Curl and LibCurl… and my favorite: just doing `run <curl … …>` | 14:45 |
|
| gks: otherwise people nowadays prefer Cro, I think | 14:45 |
|
gks
| AlexDaniel: ok! i'm doing a thing partly as a way of learning perl6, so just running curl as a shell command felt counterproductive. I can write bash scripts all day long, but i wanna learn perl 6 :) | 14:47 |
|
| i'll look into Cro! | 14:47 |
|
jnthn
| Off the top of my head, `use Cro::HTTP::Client; my $resp = await Cro::HTTP::Client.get($url); spurt :bin $filename, await $resp.body-blob;` :) | 14:49 |
| → bb656 joined | 14:49 |
|
pistacchio
| hi, yesterday I asked if it's ok to post here snippets of perl6 to have them reviewed for learning purposes and check if there are idioms that i missed or best practices that i ignored. is there a recommended platform to share perl6 files or a github gist would suffice? | 14:50 |
|
lizmat
| github gist works for most people here :-) | 14:51 |
| → uzl joined | 14:51 |
|
pistacchio
| https://gist.github.com/pistacchio/9af8d01ad55771a9d76573971c135fbb | 14:51 |
|
uzl
| Hello #perl6! | 14:51 |
|
pistacchio
| @lizmat thanks. this is the link, if anyone would like to give me any tip | 14:51 |
|
uzl
| How do I circumvert circular dependency? I've a class in its own pm6 file (Git::Repository.pm6), which uses some utility functions from another pm6 file (Utils.pm6). However, the Utils.pm6 file has a function (repo-create) that instantiate the class from the first file. I could place this function to the same compilation unit (I think!) as the class but I want to keep all the utility functions in a single file. | 14:52 |
|
| Any idea on how to approach this? | 14:52 |
|
| http://sprunge.us/p7Pajr | 14:53 |
|
gks
| jnthn: thanks! | 14:53 |
|
lizmat
| pistacchio: and the question is exactly? Just about the idioms used ? | 14:53 |
|
pistacchio
| @lizmat yes. the code works of course, but i'd like to know if it uses idiomatic perl6 or if there is something i'm missing, like doing something in a more convoluted why while there are bits of the language that i don't know and that would turn out useful | 14:55 |
|
| it's just a way of learning the language, really | 14:55 |
| ← aborazmeh left | 14:55 |
| → mowcat joined | 14:56 |
| ← bb656 left | 14:59 |
| ← robertle_ left | 15:00 |
| → pistacchio_mob joined | 15:01 |
| ← pistacchio_mob left | 15:02 |
| → robertle_ joined | 15:02 |
| → antoniogamiz joined | 15:05 |
| → roguelazer joined | 15:05 |
|
| sjn wonders if it's possible to get a perl6 eval bot in another channel here on freenode | 15:10 |
|
moritz
| sjn: it is | 15:11 |
| ← roguelazer left | 15:18 |
|
| sjn looks at perl6/whateverable | 15:18 |
| ← pistacchio left | 15:18 |
|
AlexDaniel
| yeah, that is also possible :) | 15:19 |
|
| which channel are we talking about and how many bots do you want? :) | 15:19 |
|
moritz
| sjn: I can also send camelia to another channel if you want | 15:19 |
| → pistacchio joined | 15:20 |
|
sjn
| moritz: that would be cool :) | 15:21 |
| → AlexDani` joined | 15:23 |
|
uzl
| Is the `z` file tests enough to check if a directory is empty, meaning not even zero-sized files? Or should I rather `dir $path-to-dir` and then coerce to Int? | 15:23 |
| ← AlexDaniel left | 15:24 |
| ← sivoais left | 15:25 |
| → sivoais joined | 15:26 |
| ← camelia left | 15:26 |
| → camelia joined | 15:26 |
| ChanServ set mode: +v | 15:27 |
|
sjn
| p6: "BUTTERFLY".uniparse.say | 15:31 |
|
camelia
| rakudo-moar b5bf7cd4f: OUTPUT: «🦋» | 15:31 |
|
| sjn would have assumed a butterfly would be printed there | 15:31 |
|
| moritz sees a butterfly | 15:31 |
|
sjn
| hm. missing font here, then | 15:32 |
|
timotimo
| uzl: i'd expect a size based on the stat system call to always be the same for folders, or perhaps it depends on the filesystem in use | 15:33 |
| ← nekomune left | 15:35 |
|
lucs
| moritz: What terminal do you use? (urxvt here, no butterfly) | 15:35 |
|
uzl
| timotimo: The docs say "is dependent on the operating system". Do you think it's a safer bet then to list the files in the path and then coerce that to Int? | 15:35 |
|
timotimo
| that will give you the number of files in it (excluding . and .. by default) | 15:36 |
|
| where an empty file will also show up | 15:36 |
|
moritz
| lucs: the xfce terminal | 15:36 |
|
lucs
| Thanks, I'll look it up. | 15:36 |
|
uzl
| timotimo: I think I'll go with that then. | 15:36 |
|
moritz
| lucs: but it's typically not a matter of the terminal, but whether UTF-8 is properly configured, and then it's a question of available fonts | 15:36 |
|
uzl
| timotimo: BTW, do you mind looking at https://colabti.org/irclogger/irclogger_log/perl6?date=2019-03-29#l435? | 15:37 |
|
lucs
| moritz: I'm not too handy with all that, so thanks for the tip :) | 15:37 |
|
timotimo
| uzl: one way is always to use run-time module loading using "require", i think | 15:38 |
|
| if you need something that happens at compile time, though, that'll mean your "at run time" is actually during the compile time, and that'd be bad news | 15:38 |
|
kawaii
| Is it normal for Perl 6 applications to be distributed with META6.json files too? To list their dependencies and such? | 15:40 |
|
| Or does that only apply to modules? | 15:40 |
|
timotimo
| that makes them installable, and also a META6.json is required for it to "use" its own modules | 15:41 |
|
| and for modules to load each other | 15:41 |
|
kawaii
| great thanks :) | 15:41 |
|
timotimo
| unless you're into fiddling with paths manually and putting "use lib" in all your code | 15:41 |
|
| having scripts in a bin/ folder will get them installed to the system as launchers | 15:41 |
|
uzl
| timotimo: I don't understand all the intricacies ;-); I'll have to read the docs again. BTW, do you mean loading the class module into the utility module? Or could it be either way? | 15:42 |
|
timotimo
| it could probably work either way, you'll have to experiment, and tbh i haven't tried this yet either :S | 15:43 |
|
| BBL | 15:44 |
|
uzl
| I'll have to experiment then. Thanks! | 15:45 |
| ← ufobat__ left | 15:45 |
| ← learningprogged left | 15:46 |
|
uzl
| timotimo: One last question. There must be several ways but what's the closest thing of asserting something in P6? Using the Test module? Just checking for definedness or truthness? | 15:47 |
|
moritz
| Test modules works well for testing | 15:49 |
|
| there is no real assert statements, but a die "you are too old" if $age > 42; is quick to write | 15:49 |
|
| there are also PRE and POST phasers for routines | 15:50 |
|
| which you can use to check things at routine entry and exit | 15:50 |
| ← robertle_ left | 15:52 |
|
uzl
| moritz: I think a die statement will suffice here. I'm asking because I'm following along this Python implementation of a simple Git and the author uses assert. | 15:52 |
| → nekomune joined | 15:55 |
| → robertle_ joined | 16:04 |
| ← Guest5277 left | 16:07 |
| ← pistacchio left | 16:12 |
| ← antoniogamiz left | 16:17 |
| ← robertle_ left | 16:19 |
| → pistacchio joined | 16:20 |
| → andrzejku_ joined | 16:24 |
| andrzejku_ → andrzejku | 16:24 |
| ← squashable6 left | 16:24 |
| → squashable6 joined | 16:28 |
| ← reach_satori_ left | 16:28 |
| ← zakharyas left | 16:33 |
| ← domidumont left | 16:33 |
| ← AlexDani` left | 16:35 |
| ← andrzejku left | 16:41 |
| ← uzl left | 16:41 |
| → uzl joined | 16:41 |
| ← uzl left | 16:46 |
| → uzl joined | 16:48 |
| ← uzl left | 16:49 |
| ← pistacchio left | 16:53 |
| → pistacchio joined | 16:53 |
| → pistacch_ joined | 16:55 |
| ← pistacch_ left | 16:56 |
| → pistacch_ joined | 16:56 |
| ← pistacchio left | 16:57 |
| ← pistacch_ left | 17:02 |
| ← isomorphismes_ left | 17:11 |
| → reach_satori joined | 17:18 |
|
sjn
| huh. a few minutes with camelia in another channel, and we've found a security issue :) | 17:24 |
| → domidumont joined | 17:25 |
| → pistacchio joined | 17:35 |
|
El_Che
| sjn: there were some know ones, but I forgot what exactly | 17:45 |
| → ravenousmoose joined | 17:54 |
|
vrurg
| What short term is best to use when referring to the language specification (.c, .d)? Revision? | 17:57 |
| → adu joined | 18:05 |
| → natrys joined | 18:05 |
| ← squashable6 left | 18:09 |
| → squashable6 joined | 18:14 |
| ChanServ set mode: +v | 18:14 |
| ← ravenousmoose left | 18:19 |
| → stigo joined | 18:23 |
|
moritz
| vrurg: version | 18:25 |
|
| or simply say v6d | 18:25 |
|
vrurg
| moritz: But for the build process? Diwali is called 'language specification' | 18:26 |
|
| I mean, wouldn't we get teminology ambiguity somewhere? | 18:26 |
|
moritz
| vrurg: we might have a misunderstanding here, because what you say confuses me | 18:27 |
|
vrurg
| http://blogs.perl.org/users/zoffix_znet/2018/11/announce-raku-perl-6-diwali-6d-language-specification-release.html – here it is called 'language specification' | 18:28 |
|
| But let's assume we get another compiler. It would implement the specification. Yet, they would have versions like: v1.1 of compiler implementing v6.d | 18:29 |
|
| This is why I wonder wouldn't it be more correct to call .c and .d not version but specifications? | 18:30 |
|
| The reason I'm asking is because I'm redoing Configure.pl and would like to stick to a consistent terminology to avoid future confusions. | 18:31 |
| → zachk joined | 18:34 |
| ← adu left | 18:36 |
|
moritz
| rakudo says "Rakudo version 2019.04 [...] implementing Perl 6.d." | 18:38 |
|
| nothing ambiguous about that, IMHO | 18:38 |
| ← MidCheck left | 18:38 |
|
vrurg
| BTW – yes. So, it implements a spec and this is what I'll use. Thanks! | 18:39 |
| → netrino joined | 18:46 |
| ← squashable6 left | 19:14 |
| → __jrjsmrtn__ joined | 19:14 |
| → squashable6 joined | 19:19 |
| ChanServ set mode: +v | 19:19 |
| → snarkyboojum joined | 19:27 |
| → abraxxa joined | 19:29 |
| → AlexDani` joined | 19:30 |
|
TreyHarris
| Is there a unicode combining backspace? Or some other way to overprint two arbitrary glyphs on outputs that can support that without needing a single font glyph that matches? | 19:31 |
|
| (Context: I had a on-screen meter that I can show 9 out of 10 possible values via box characters, but the tenth doesn't exist; if I could print two of the others in the same space it would visually be the tenth) | 19:32 |
|
moritz
| not that I'm aware of | 19:34 |
|
| the best you can try is to find combining characters that make up the right shape of what you want | 19:34 |
| ← abraxxa left | 19:38 |
| ← cpan-p6 left | 19:39 |
| → cpan-p6 joined | 19:39 |
| ← cpan-p6 left | 19:39 |
| → cpan-p6 joined | 19:39 |
| → abraxxa joined | 19:42 |
|
timotimo
| TreyHarris: for that purpose i'll always just use reverse video | 19:43 |
| ← squashable6 left | 19:44 |
| ← zachk left | 19:48 |
| → zachk joined | 19:48 |
| → squashable6 joined | 19:49 |
| ChanServ set mode: +v | 19:49 |
|
kybr
| commaide.com/download says "The latest Comma Community release is 2019.3.0.1." but the available downloads are 2019.3.0---i tried on Windows and macOS. can someone confirm? | 19:57 |
|
timotimo
| sena_kun: -^ | 19:57 |
|
| perhaps the in-program updater will get it for you | 19:58 |
|
sena_kun
| kybr, well, 2019.3.1 was a fix for Windows. Others are still 2019.3.0, so that's correct. | 19:58 |
|
| Linux gives me 3.0, Windows gives me 3.1, all's nice. | 19:59 |
|
| there is indeed a bug that Linux version will say to you that 3.1 is ready... But you can just "Ignore this particular update". | 19:59 |
|
kybr
| ok. well, i submitted a ticket. on macOS, the internal updater claims there is a new version. ah. ok. so the bug is on macOS, FYI. | 20:00 |
| ← domidumont left | 20:14 |
| ← AlexDani` left | 20:14 |
| → xm joined | 20:16 |
| ← xm left | 20:16 |
| → Guest45628 joined | 20:17 |
| ← Guest45628 left | 20:17 |
| ← lucasb left | 20:20 |
|
ugexe
| sena_kun: any chance you can fix https://github.com/croservices/cro-openapi-routes-from-definition/issues/6 ? | 20:21 |
| → xm joined | 20:22 |
| ← xm left | 20:23 |
| → Guest91453 joined | 20:23 |
| ← Guest91453 left | 20:23 |
| → xm joined | 20:24 |
| ← xm left | 20:24 |
| → Guest10171 joined | 20:24 |
| ← Guest10171 left | 20:24 |
| ← snarkyboojum left | 20:31 |
| → patrickb joined | 20:34 |
| ← pistacchio left | 20:37 |
| → pistacchio joined | 20:37 |
| ← abraxxa left | 20:41 |
| ← natrys left | 20:42 |
| → MidCheck joined | 20:47 |
|
patrickb
| o/ | 20:55 |
| ← skids left | 20:57 |
|
patrickb
| Is there an easy way to iterate the chars of a Str? I currently use for `$str.split: '', :skip-empty -> $c {...}`, but I don't need to modify, just access. | 20:57 |
| → snarkyboojum joined | 21:02 |
|
lizmat
| m: say "foobar".comb | 21:02 |
|
camelia
| rakudo-moar e84f72706: OUTPUT: «(f o o b a r)» | 21:02 |
|
lizmat
| patrickb ^^^ | 21:02 |
|
| m: say "foobar".comb(2) # if you want two at a time | 21:03 |
|
camelia
| rakudo-moar e84f72706: OUTPUT: «(fo ob ar)» | 21:03 |
| ← snarkyboojum left | 21:06 |
|
patrickb
| lizmat: thanks! | 21:07 |
|
TreyHarris
| timotimo: thanks, reverse-video works, and lets me make what I already had look more consistent by making half reverse video, half regular | 21:11 |
| → molaf joined | 21:12 |
| → xm joined | 21:24 |
| ← xm left | 21:25 |
| → Guest12241 joined | 21:25 |
| ← Guest12241 left | 21:25 |
| → xinming-pad joined | 21:26 |
| ← xinming-pad left | 21:26 |
| → xinming-pad joined | 21:27 |
| ← xinming-pad left | 21:27 |
| → xinming-pad joined | 21:27 |
| ← xinming-pad left | 21:27 |
| → |oLa| joined | 21:30 |
| ← |oLa| left | 21:30 |
| ← ctilmes left | 21:31 |
| ← yht__ left | 21:36 |
| → |oLa| joined | 21:39 |
| ← molaf left | 21:39 |
| ← pistacchio left | 21:41 |
| → pistacchio joined | 21:41 |
|
sena_kun
| ugexe, I can't, but I certainly can ping jnthn. | 21:58 |
|
ugexe
| oh right... thats even mentioned in the issue | 21:58 |
|
jnthn
| Ah, that even looks like an easy thing to deal with... | 22:01 |
|
| sena_kun: Hm, the last commit there is a version bump; I'm guessing that a release with that simply never got shipped to CPAN? | 22:04 |
|
sena_kun
| jnthn, yeah | 22:04 |
|
| jnthn, I'd bet on it, at least. | 22:04 |
|
jnthn
| yeah, matches what I see | 22:05 |
|
| Sorry about that :( | 22:05 |
|
timotimo
| have more CI for this :) | 22:06 |
|
jnthn
| Uploaded now | 22:06 |
|
| timotimo: I think it's more CD that I need :) | 22:07 |
|
timotimo
| true | 22:07 |
|
| CI is at best a half-measure i suppose | 22:07 |
| ← isomorphismes left | 22:11 |
| → isomorphismes joined | 22:13 |
| → leont joined | 22:14 |
| ← pecastro left | 22:34 |
| → pecastro joined | 22:41 |
| ← __jrjsmrtn__ left | 22:53 |
| ← MidCheck left | 22:57 |
| ← agentzh left | 23:07 |
| ← camelia left | 23:10 |
| → camelia joined | 23:10 |
| ChanServ set mode: +v | 23:11 |
| ← camelia left | 23:14 |
| → Black_Ribbon joined | 23:14 |
|
guifa
| hmmm | 23:15 |
| → agentzh joined | 23:15 |
| ← agentzh left | 23:15 |
| → agentzh joined | 23:15 |
|
guifa
| p6: my @a = <a b c>; @a[0..1] = <x y>; say @a; | 23:15 |
|
evalable6
| guifa, rakudo-moar 507c3c37e: OUTPUT: «[x y c]» | 23:15 |
|
guifa
| p6: my @b = <a b c>, <a b c>; @b[0..1;0] = <x y>; say @b; | 23:15 |
|
evalable6
| guifa, rakudo-moar 507c3c37e: OUTPUT: «(exit code 1) Cannot modify an immutable Str (a) in block <unit> at /tmp/qaEWnYj4gs line 1» | 23:15 |
|
guifa
| p6: my @c = <a b c>, <a b c>, <a b c>; @c[0..1][0] = <x y>; say @c; | 23:16 |
|
evalable6
| guifa, rakudo-moar 507c3c37e: OUTPUT: «[(x y) (a b c) (a b c)]» | 23:16 |
|
stigo
| just fyi: #oslohackerspace was playing around with camelia and found out how to execute commands, I send the following command to it to shut it down to prevent anyone from actually causing any harm: qqx|chmod 0000 evalbot;kill `ps -o ppid= $*PID`| | 23:19 |
|
guifa
| oh actually it’s even more simple (though frustrating) issue | 23:20 |
|
| p6: my @a = <a b>; @a[0] = ‘x’; say @a; | 23:21 |
|
evalable6
| guifa, rakudo-moar 507c3c37e: OUTPUT: «[x b]» | 23:21 |
|
guifa
| my @b = <a b>, <a b>; @b[0;0] = ‘x’; say @b; | 23:21 |
|
| p6: my @b = <a b>, <a b>; @b[0;0] = ‘x’; | 23:21 |
|
evalable6
| guifa, rakudo-moar 507c3c37e: OUTPUT: «(exit code 1) Cannot modify an immutable List ((a b)) in block <unit> at /tmp/3ChKcRnbux line 1» | 23:21 |
|
timotimo
| stigo: yeah, it just lets you do that | 23:21 |
|
| the other evalbots, too | 23:21 |
|
guifa
| What am I missing for assignment in multidimensional arrays? | 23:26 |
| → aborazmeh joined | 23:32 |
| ← aborazmeh left | 23:32 |
| → aborazmeh joined | 23:32 |
|
Juerd
| guifa: The difference between multidimensional arrays, and arrays of lists | 23:35 |
| ← agentzh left | 23:35 |
|
Juerd
| m: my @b[2;2] = <a b>, <c d>; @b.perl.say; @b[1;0].say; | 23:36 |
|
evalable6
| Juerd, rakudo-moar 507c3c37e: OUTPUT: «Array.new(:shape(2, 2), ["a", "b"], ["c", "d"])c» | 23:36 |
|
Juerd
| m: my @b = <a b>, <c d>; @b.perl.say; @b[1][0].say; | 23:36 |
|
evalable6
| Juerd, rakudo-moar 507c3c37e: OUTPUT: «[("a", "b"), ("c", "d")]c» | 23:36 |
| → AlexDani` joined | 23:45 |
|
AlexDani`
| xD | 23:46 |
| AlexDani` → AlexDaniel | 23:46 |
| ← AlexDaniel left | 23:46 |
| → AlexDaniel joined | 23:46 |
| ← sena_kun left | 23:54 |
| ← netrino left | 23:58 |
| → agentzh joined | 23:58 |