Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2016-10-10

Perl 6 | Reference Documentation | Rakudo

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:11 cowens joined #perl6
00:16 cowens Is Uni intentionally a read-only type?
00:18 awwaiid joined #perl6
00:33 timotimo yes
00:38 cowens So, any Uni method should return a new Uni?
00:38 cowens Which means methods like .chop are right out?
00:39 cowens or at least can’t work like their Str counterparts
00:41 MasterDuke .chop is non-mutating now
00:41 MasterDuke m: my $a = "ab"; $a.chop; say $a
00:41 camelia rakudo-moar 13f479: OUTPUT«ab␤»
00:41 MasterDuke m: my $a = "ab"; my $b = $a.chop; say $b
00:41 camelia rakudo-moar 13f479: OUTPUT«a␤»
00:42 pierre_ joined #perl6
00:43 cowens Ah, I missed that.  Must read more closely .
00:43 MasterDuke SourceBaby: help
00:43 SourceBaby MasterDuke, Use s: trigger with args to give to sourcery sub. e.g. s: Int, 'base'. See http://modules.perl6.org/dist/CoreHackers::Sourcery
00:43 MasterDuke s: Str, 'chop'
00:43 SourceBaby MasterDuke, Sauce is at https://github.com/rakudo/rakudo/blob/13f4798/src/core/Cool.pm#L111
00:44 MasterDuke s: "ab", 'chop'
00:44 SourceBaby MasterDuke, Sauce is at https://github.com/rakudo/rakudo/blob/13f4798/src/core/Cool.pm#L111
00:45 p3rln00b s: "ab", "chop", \()
00:45 SourceBaby p3rln00b, Sauce is at https://github.com/rakudo/rakudo/blob/13f4798/src/core/Str.pm#L78
00:45 MasterDuke p3rln00b++
00:46 MasterDuke cowens: ^^^
00:47 awwaiid joined #perl6
00:47 cowens nqp::isgt_i is > for integers?
00:47 p3rln00b Yes
00:47 cowens and nqp::sub_i is []?
00:48 p3rln00b cowens: subtraction of ints. See https://github.com/perl6/nqp/blob/master/docs/ops.markdown
00:48 cowens ah
00:48 cowens I was thinking subscript
00:50 MasterDuke nqp::atpos i beliebe
00:50 MasterDuke *believe
00:50 cowens makes sense
00:54 timotimo cowens: the nqp::blah stuff maps mostly 1:1 to stuff in MoarVM's src/core/interp.c (how exactly they map can be found in nqp's src/vm/moar/QAST/QASTOperationsMAST.nqp)
00:55 timotimo but i'm quite late for bed right now, so i can't help further than that :(
01:11 labster joined #perl6
01:12 awwaiid joined #perl6
01:16 pierre_ joined #perl6
01:18 awwaiid joined #perl6
01:29 Derperperd_ joined #perl6
01:33 dalek doc: a174105 | coke++ | doc/Language/ (2 files):
01:33 dalek doc: e.g., not eg
01:33 dalek doc: review: https://github.com/perl6/doc/commit/a174105733
01:34 pierre_ joined #perl6
01:34 dalek doc/spellcheck: 15346a5 | coke++ | doc/ (11 files):
01:34 dalek doc/spellcheck: use full word.
01:34 dalek doc/spellcheck: review: https://github.com/perl6/doc/commit/15346a5067
01:34 dalek doc/spellcheck: c83fe47 | coke++ | doc/Language/ (2 files):
01:34 dalek doc/spellcheck: standardize on regexes
01:34 dalek doc/spellcheck: review: https://github.com/perl6/doc/commit/c83fe47aab
01:34 dalek doc/spellcheck: 1429a85 | coke++ | xt/.aspell.pws:
01:34 dalek doc/spellcheck: moar words
01:34 dalek doc/spellcheck: review: https://github.com/perl6/doc/commit/1429a8558e
01:34 dalek doc/spellcheck: a174105 | coke++ | doc/Language/ (2 files):
01:34 dalek doc/spellcheck: e.g., not eg
01:34 dalek doc/spellcheck: review: https://github.com/perl6/doc/commit/a174105733
01:34 dalek doc/spellcheck: f80414d | coke++ | doc/Language/ (2 files):
01:34 dalek doc/spellcheck: Merge branch 'master' into spellcheck
01:34 dalek doc/spellcheck: review: https://github.com/perl6/doc/commit/f80414da71
01:35 rgrinberg joined #perl6
01:35 edenc joined #perl6
01:36 canopus joined #perl6
01:40 awwaiid joined #perl6
01:47 ilbot3 joined #perl6
01:47 Topic for #perl6 is now »ö« Welcome to Perl 6! | https://perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:,  or /msg camelia p6: ... | irclog: http://irc.perl6.org or http://colabti.org/irclogger/irclogger_logs/perl6 | UTF-8 is our friend!
01:58 bioduds joined #perl6
01:58 bioduds hi guys, sorry to disturb, what is this error telling me? Asked to remove 2 spaces, but the shortest indent is 0 spaces  in any descend at gen/moar/m-Perl6-Actions.nqp line 473
01:58 bioduds I didn't understand
02:01 geekosaur usually means you have an indented here document, but one line in  it isn't indented enough
02:06 bioduds yes, thanks
02:06 bioduds geekosaur : tx
02:08 p3rln00b bioduds: got code that produced that? It's LTA the error is referencing guts
02:09 bioduds p3rln00b : tx, solved with geekosaur hint :)
02:09 awwaiid joined #perl6
02:09 geekosaur yes, but p3rln00b is right, the error and the code that produced the error should probably be filed as an LTA ticket
02:09 p3rln00b m: q:to/x/;␤y␤  x
02:09 camelia rakudo-moar 13f479: OUTPUT«Asked to remove 2 spaces, but the shortest indent is 0 spaces␤  in any trim_heredoc at gen/moar/m-Perl6-Actions.nqp line 499␤»
02:10 geekosaur because that's a lousy error message
02:10 bioduds oh, so sorry, what should I do?
02:10 dayangkun joined #perl6
02:12 p3rln00b bioduds: submit a bug report, with the code that produce your error
02:13 bioduds yes, where, please?
02:13 p3rln00b bioduds: send an email to rakudobug@perl.org
02:13 huggable joined #perl6
02:14 bioduds ok, sent! :)
02:14 p3rln00b bioduds++ thanks
02:14 awwaiid joined #perl6
02:21 bioduds p3rln00b : much obliged :)
02:30 seatek gosh, i don't know what to think about class names and method names with dashes. but i love them. and don't like them too.
02:34 p3rln00b .oO( once you go kebab, you never go back )
02:39 seatek i'm so confused
02:40 p3rln00b the names with dashes is called "kebab case"
02:41 p3rln00b (or "kebob case")
02:43 seatek that's not what confused me. it's the fact that i'm liking them.
02:44 AlexDaniel I don't know what's so special about kebab case, but indeed, you never go back
02:44 p3rln00b The special is that you don't have to jam SHIFT a billion times a day while coding.
02:45 AlexDaniel nah, that's not it
02:45 AlexDaniel in fact, on my layout - is harder to press than _
02:45 seatek it's that it's so wrong. and so right.
02:45 p3rln00b And normal-looking words use hyphens and not underscores.
02:46 AlexDaniel yeah, that. It just looks so much better
02:46 geekosaur to me it reads more naturally (because ^) and easily (because thisIsHardToRead)
02:46 seatek yeah and underscores are awkward too
02:46 AlexDaniel geekosaur: yeah, but this_is_not_so_hard_to_read ?
02:47 AlexDaniel this-is-not-so-hard-to-read
02:47 seatek it's so good
02:47 AlexDaniel mhmmmm… kebab just looks significantly better
02:48 AlexDaniel I still find it weird that just moving the line a few pixels higher makes such a big difference
02:48 geekosaur the dashes one at least is something I will often encounter in normal reading
02:48 seatek it's like the continuity of the line, rather than being broken up into individual words
02:49 geekosaur neither is great, but there is no "great" solution really (there's also the SQL one, where you can put spaces in a symbol name if you double quote it)
02:49 AlexDaniel what about this'is'not'so'hard'to'read ?
02:49 seatek it's abrasive, like a cheese grater
02:50 BenGoldberg It's perl4!
02:50 geekosaur also especially bad here because I use a proportional font for IRC, so now it's squished
02:50 geekosaur or Ada
02:50 AlexDaniel seatek: not sure if you are aware:
02:50 seatek is that really perl4? i don't remembe rthat
02:50 AlexDaniel m: my $foo'bar'baz = 42; say $foo'bar'baz
02:50 camelia rakudo-moar c57a26: OUTPUT«42␤»
02:50 geekosaur perl 4 and earlier used ' as the namespace token (like :: in perl5)
02:50 BenGoldberg Before perl used :: to separate namespaces, it used '
02:51 noganex_ joined #perl6
02:51 seatek ahhh ok :)
02:51 seatek vague vague recollection there
02:51 AlexDaniel can you use ' today?
02:51 BenGoldberg It's actually still valid (in perl5), but only used for silly stuff, like making a sub named isn't
02:52 geekosaur but prints back out in error /warning messages with the ::
02:52 geekosaur pyanfar Z$ perl -e "use warnings; \$x'y = 1"
02:52 geekosaur Name "x::y" used only once: possible typo at -e line 1.
02:57 AlexDaniel m: my $thisˉisˉnotˉsoˉhardˉtoˉread = 42; say $thisˉisˉnotˉsoˉhardˉtoˉread # well, let's move it even higher?
02:57 camelia rakudo-moar 565b52: OUTPUT«42␤»
02:57 awwaiid joined #perl6
02:58 seatek i kinda like that one
03:01 AlexDaniel .oO( “upperscore case”? “overscore case” ?)
03:02 geekosaur I find that if I'm looking up, I'm expecting magic. this may be because Haskell (where ' in a non-Char context often indicates TH or type level shenanigans)
03:04 p3rln00b .tell El_Che JSON handler now fixed: https://rt.perl.org/Ticket/Display.html?id=129810
03:04 yoleaux p3rln00b: I'll pass your message to El_Che.
03:04 AlexDaniel m: my $f̅o̅o̅ˉ̅b̅a̅r̅ = 42; say $f̅o̅o̅ˉ̅b̅a̅r̅ # overline case? :o
03:04 camelia rakudo-moar 565b52: OUTPUT«42␤»
03:05 p3rln00b AlexDaniel: nope: http://i.imgur.com/0CjflhX.png
03:05 p3rln00b hah
03:06 p3rln00b Now every line in chat is showing "rline case? :o" at the end ~_~
03:06 p3rln00b :)
03:06 AlexDaniel p3rln00b: actually, this looks almost right
03:07 AlexDaniel p3rln00b: compare it with this: https://files.progarm.org/2016-10-10-060659_641x70_scrot.png
03:07 AlexDaniel this is completely wrong…
03:07 seatek that second is what i got
03:08 p3rln00b Terminal: http://i.imgur.com/5Gw1VR8.png
03:09 AlexDaniel seatek: why does it decide to put it on the character to the right?
03:09 AlexDaniel what is this? Why? Is there a bug report for that?
03:09 AlexDaniel This bug is there for more than 5 years I think
03:09 seatek AlexDaniel, you got me
03:10 seatek ugh. databases always make me do things i don't want to do.
03:12 AlexDaniel seatek: like?
03:14 seatek AlexDaniel, well, right now i have some nice discreet files doing tests on individual tables, but now with the logic of relations, it's easiest to combine those nice neat test files all together into one big giant thing
03:18 aries_liuxueyang joined #perl6
03:21 p3rln00b bioduds: in the future, it would be helpful if bug reports contained code that reproduces the issue, along with the version of information of Perl you're running
03:21 p3rln00b m: q:to/x/;␤y␤  x
03:21 camelia rakudo-moar 3b5ef0: OUTPUT«Asked to remove 2 spaces, but the shortest indent is 0 spaces␤  in any trim_heredoc at gen/moar/m-Perl6-Actions.nqp line 499␤»
03:22 p3rln00b bioduds: e.g. ^ that's a similar error, but it doesn't reference "descend" your error does. So I've no idea now how to produce *your* error.
03:23 p3rln00b bioduds: 'cause this is how it shows up on our end: https://rt.perl.org/Ticket/Display.html?id=129838#ticket-history
03:26 geekosaur I think it might? there's a text/plain inclusion before the message which may have gotten the source?
03:26 dayangkun joined #perl6
03:26 geekosaur oh, no, same thing :/
03:26 aries_liuxueyang joined #perl6
03:27 geekosaur so yes, the source that triggered it and the perl6 --version output
03:34 wamba joined #perl6
03:35 awwaiid joined #perl6
03:46 awwaiid joined #perl6
04:03 awwaiid joined #perl6
04:09 Derperperd joined #perl6
04:34 dayangkun joined #perl6
04:34 awwaiid joined #perl6
04:39 ilken joined #perl6
04:41 Derperperd joined #perl6
04:42 Xliff joined #perl6
04:42 robh2791 joined #perl6
04:50 Cabanossi joined #perl6
04:52 Derperperd joined #perl6
04:55 stmuk joined #perl6
05:02 Actualeyes joined #perl6
05:03 pierre_ joined #perl6
05:07 awwaiid joined #perl6
05:11 Derperperd joined #perl6
05:15 Derperperd_ joined #perl6
05:22 Actualeyes joined #perl6
05:23 cyphase joined #perl6
05:26 ewet joined #perl6
05:28 aries_liuxueyang joined #perl6
05:33 awwaiid joined #perl6
05:38 hrob2791 joined #perl6
05:41 hrob2791 joined #perl6
05:41 domidumont joined #perl6
05:45 awwaiid joined #perl6
05:46 dayangkun joined #perl6
05:47 domidumont joined #perl6
06:04 pierre_ joined #perl6
06:06 pierre_ joined #perl6
06:10 neuraload joined #perl6
06:10 awwaiid joined #perl6
06:14 domidumont joined #perl6
06:20 bpmedley joined #perl6
06:26 firstdayonthejob joined #perl6
06:30 Averna joined #perl6
06:39 domidumont joined #perl6
06:40 Lucas_One joined #perl6
06:41 awwaiid joined #perl6
07:00 darutoko joined #perl6
07:07 CIAvash joined #perl6
07:07 ufobat joined #perl6
07:11 awwaiid joined #perl6
07:18 awwaiid joined #perl6
07:20 cyphase joined #perl6
07:22 RabidGravy joined #perl6
07:24 awwaiid joined #perl6
07:29 awwaiid joined #perl6
07:32 pdcawley joined #perl6
07:33 brrt joined #perl6
07:37 cyphase joined #perl6
07:39 awwaiid joined #perl6
07:44 xinming_ joined #perl6
07:48 ccakes joined #perl6
07:49 eliasr joined #perl6
07:50 ocbtec joined #perl6
07:52 cyphase joined #perl6
08:04 awwaiid joined #perl6
08:15 cyphase joined #perl6
08:29 cyphase joined #perl6
08:30 awwaiid joined #perl6
08:36 ilken joined #perl6
08:39 gregf_ joined #perl6
08:44 ilken joined #perl6
08:45 Xliff_ joined #perl6
08:45 brrt1 joined #perl6
08:46 zengargoyle joined #perl6
08:46 dayangkun joined #perl6
08:47 ilken joined #perl6
08:47 labster joined #perl6
08:47 kent\n joined #perl6
08:48 dustinm`_ joined #perl6
08:49 f3ew_ joined #perl6
08:49 El_Che_ joined #perl6
08:49 Kaffe_ joined #perl6
08:49 TheDir_ joined #perl6
08:49 lucs_ joined #perl6
08:49 pecastro_ joined #perl6
08:50 Shozan joined #perl6
08:50 alnewkir1 joined #perl6
08:50 ChoHag_ joined #perl6
08:50 ilbelkyr_ joined #perl6
08:50 ilken joined #perl6
08:53 kmwallio_ joined #perl6
08:53 remmie2 joined #perl6
08:53 yossarian joined #perl6
08:53 skaji_ joined #perl6
08:53 gensym_ joined #perl6
08:54 yossarian joined #perl6
08:54 andrewalker_ joined #perl6
08:55 yossarian joined #perl6
08:55 awwaiid joined #perl6
08:56 revdiablo joined #perl6
08:59 rindolf joined #perl6
09:00 avuserow joined #perl6
09:01 sammers joined #perl6
09:01 melezhik joined #perl6
09:01 ewet joined #perl6
09:02 ilogger2 joined #perl6
09:02 akiym joined #perl6
09:02 raydiak joined #perl6
09:04 darutoko joined #perl6
09:10 silug_ joined #perl6
09:11 brrt1 left #perl6
09:21 * moritz enjoyed https://www.promptworks.com/blog/public-keys-in-perl-6
09:22 moritz m: say :100(1, 2, 3)
09:22 camelia rakudo-moar d03459: OUTPUT«This call only converts base-100 strings to numbers; value $(1, 2, 3) is of type List, so cannot be converted!␤(If you really wanted to convert $(1, 2, 3) to a base-100 string, use $(1, 2, 3).base(100) instead.)␤  in block <unit> at <tmp> line 1␤␤»
09:22 g4 joined #perl6
09:22 g4 joined #perl6
09:22 moritz m: say (1, 2, 3).base(100)
09:22 camelia rakudo-moar d03459: OUTPUT«No such method 'base' for invocant of type 'List'␤  in block <unit> at <tmp> line 1␤␤»
09:22 moritz m: say $(1, 2, 3).base(100)
09:22 camelia rakudo-moar d03459: OUTPUT«No such method 'base' for invocant of type 'List'␤  in block <unit> at <tmp> line 1␤␤»
09:22 moritz this seems LTA :/
09:41 rudolfochrist joined #perl6
09:41 moritz m: say <1 2 3>.reduce: { $^a + 100 * $^b}
09:41 camelia rakudo-moar d03459: OUTPUT«501␤»
09:41 moritz m: say <1 2 3>.reduce: { 100 * $^a + $^b}
09:41 camelia rakudo-moar d03459: OUTPUT«10203␤»
09:42 awwaiid joined #perl6
09:46 flexibeast joined #perl6
09:47 pierre_ joined #perl6
09:49 pierre_ joined #perl6
09:52 skids joined #perl6
10:08 bjz joined #perl6
10:18 gfldex m: say (1, 2, 3)».base(100)
10:18 camelia rakudo-moar d03459: OUTPUT«base argument to base out of range. Is: 100, should be in 2..36␤  in block <unit> at <tmp> line 1␤␤Actually thrown at:␤  in block <unit> at <tmp> line 1␤␤»
10:25 RabidGravy boom!
10:30 RabidGravy rebuilding rakudo on the faster of Raspberry Pi to test the RT #127194
10:30 synopsebot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=127194
10:30 RabidGravy it does appear that it has improved without the suggested fix though
10:44 RabidGravy yay, all good with FFI :)
10:46 bjz joined #perl6
10:56 canopus joined #perl6
10:58 rindolf joined #perl6
11:02 wamba joined #perl6
11:03 RabidGravy right, now re-building for a third time
11:05 bjz_ joined #perl6
11:06 RabidGravy Hopefully it will fix the infelicity in the https://github.com/jonathanstowe/RPi-Device-PiGlow whereby it doesn't light up all the LEDs
12:23 ssqq joined #perl6
12:31 salva0 joined #perl6
12:36 brrt joined #perl6
12:39 perlpilot joined #perl6
12:40 dalek doc: d714636 | (Tom Browder)++ | doc/Language/exceptions.pod6:
12:40 dalek doc: better grammar
12:40 dalek doc: review: https://github.com/perl6/doc/commit/d714636a1a
12:45 zakharyas joined #perl6
12:46 rindolf joined #perl6
12:46 [Coke] bduggan++
12:46 cowens p6: 1[1];
12:46 camelia rakudo-moar d03459: OUTPUT«Index out of range. Is: 1, should be in 0..0␤  in block <unit> at <tmp> line 1␤␤Actually thrown at:␤  in block <unit> at <tmp> line 1␤␤»
12:46 cowens p6: (1)[1];
12:46 camelia rakudo-moar d03459: OUTPUT«Index out of range. Is: 1, should be in 0..0␤  in block <unit> at <tmp> line 1␤␤Actually thrown at:␤  in block <unit> at <tmp> line 1␤␤»
12:47 cowens p6: (1,)[1];
12:47 camelia rakudo-moar d03459: ( no output )
12:47 cowens A better error message is probably needed in the first two cases.
12:47 rudolfochrist joined #perl6
12:49 jnthn What would you like it to say?
12:49 jnthn m: say 1[0]
12:49 camelia rakudo-moar d03459: OUTPUT«1␤»
12:49 jnthn m: say (1)[0]
12:49 camelia rakudo-moar d03459: OUTPUT«1␤»
12:49 jnthn The range it suggests is correct
12:49 cowens But it is likely an accident.
12:50 cowens Lots of the other error messages have suggestions like: perhaps you meant (1,)[1] or 1 is not a list
12:50 xinming joined #perl6
12:51 lizmat cowens: a scalar is like a shaped 1 element array
12:51 lizmat m: my @a[1]; say @a[1]
12:51 camelia rakudo-moar d03459: OUTPUT«Index 1 for dimension 1 out of range (must be 0..0)␤  in block <unit> at <tmp> line 1␤␤»
12:51 cowens Is there a valid use for that feature?
12:51 arnsholt m: say (1,)[1] # What does that return, though?
12:51 camelia rakudo-moar d03459: OUTPUT«Nil␤»
12:51 psch m: List.new[0].say
12:51 camelia rakudo-moar d03459: OUTPUT«Nil␤»
12:52 lizmat cowens: so you don't have to worry if something returns a scalar and you want to treat it as a list
12:52 lizmat m: say 42.elems
12:52 camelia rakudo-moar d03459: OUTPUT«1␤»
12:52 cowens hmm
12:52 AlexDaniel m: say +[42] # ;)
12:52 camelia rakudo-moar d03459: OUTPUT«1␤»
12:53 jnthn We do, I believe, have enough context at runtime to point out that the out-of-bounds happened on an item that was then treated as a 1-item list for the sake of the indexing operation
12:54 jnthn And it may well be helpful
12:54 cowens I stumbled into this when checking to see if strings had [] implemented
12:54 AlexDaniel ooh
12:54 jnthn No, a string is an item
12:54 cowens the error messages was . . . a bit confusing to say the least
12:54 jnthn So will be treated as a 1-item list
12:54 AlexDaniel sure, but I see why someody would try that
12:55 cowens Yeah, I figured that out
12:55 perlpilot jnthn: I think it would.  Especially in the case of my $a = 42;  $a[1];
12:55 AlexDaniel m: say "hello"[3]
12:55 camelia rakudo-moar d03459: OUTPUT«Index out of range. Is: 3, should be in 0..0␤  in block <unit> at <tmp> line 1␤␤Actually thrown at:␤  in block <unit> at <tmp> line 1␤␤»
12:56 lizmat perhaps we should implement a Str.AT-POS that dies with a more appropriate error message ?
12:56 cowens I did immediately try “foo”[0] and got back “foo”, so the error message worked, but only because I was in the REPL playing
12:56 jnthn lizmat: No
12:56 jnthn lizmat: But I'd be +1 to a patch to the AT-POS that does the item => 1-item list promotion giving a better error on out-of-range
12:56 cowens If that had been in a program, I would have spent a long time trying to figure out what went wrong with my string
12:57 lizmat jnthn: on it
12:57 jnthn Not quite sure how to word it.
12:57 AlexDaniel cowens: yeah, it is LTA
12:57 MasterDuke i think i recently had some discussion with TimToady about that error message
12:58 AlexDaniel generally, any complaint or even just misunderstanding can be turned into a LTA ticket :)
12:58 jnthn Maybe "Index out of range in Str treated as 1-item list." or so
12:58 cowens That sounds more reasonable
12:58 AlexDaniel “Did you mean .substr?”
12:59 cowens It gets the user thinking in the right direction
12:59 perlpilot AlexDaniel: and no extra hint for non-Str?
12:59 jnthn Hm, not so sure about special-casing the error when it's Str, but I guess we could
12:59 lizmat ok, leaving LHF for someone else
13:00 AlexDaniel sounds like something MasterDuke would do ;)
13:00 lizmat yeah... so looking forward to a PR or commit  :-)
13:03 Unavowed m: say @(Set.new: 1, 2, 3)
13:03 camelia rakudo-moar d03459: OUTPUT«(3 => True 1 => True 2 => True)␤»
13:04 lizmat Unavowed: yes, a set is a conceptually a List of True
13:04 jnthn uh
13:04 jnthn A hash whose keys are True, surely? :)
13:04 Actualeyes joined #perl6
13:04 jnthn *values
13:04 jnthn gah :)
13:05 jnthn m: say keys Set.new: 1,2,3
13:05 camelia rakudo-moar d03459: OUTPUT«(3 1 2)␤»
13:05 AlexDaniel RT #129843
13:05 synopsebot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=129843
13:05 lizmat ok, a Hash of True, which listifies as a list with Pairs of True values
13:05 jnthn Right
13:06 MasterDuke ahh, wasn't exactly the same situation, but a similar error https://irclog.perlgeek.de/perl6/2016-09-26#i_13285180
13:06 jnthn Which is to be consistent with things that do Associative
13:06 jnthn So if you refactor from my %h to my %h is Set or my %h is Bag then you won't get surprises.
13:07 jnthn Or even more importantly, if you write sub foo(%h) { for %h -> $pair { ... } } and somebody passes you a Set/Bag/Mix
13:08 MasterDuke jnthn: btw, i left you a question in #perl6-dev if you've got a minute
13:09 AlexDaniel MasterDuke: what does this leading : mean in tokens? :O
13:11 MasterDuke no real idea, but it seems to let you run code, so i take advantage of it
13:11 psch m: grammar G { token TOP { :my $x = "foo"; <{ $x }> } }; G.parse("foo").say
13:11 camelia rakudo-moar d03459: OUTPUT«「foo」␤»
13:11 MasterDuke i was just flailing wildly at the keyboard and it worked out
13:12 AlexDaniel damn I wonder how I've never noticed
13:12 psch it's just a "this is a %*LANG<MAIN> statement" marker i think
13:12 AlexDaniel is it something that only works with :my  ?
13:12 dalek doc/spellcheck: 6a24447 | (Tom Browder)++ | doc/Language/exceptions.pod6:
13:12 dalek doc/spellcheck: better grammar
13:12 dalek doc/spellcheck: review: https://github.com/perl6/doc/commit/6a24447990
13:13 psch m: grammar G { token TOP { :state $x = do { say "well, matching"; "foo" }; <{ $x }> } }; G.parse("foo").say
13:13 camelia rakudo-moar d03459: OUTPUT«well, matching␤「foo」␤»
13:13 jnthn Works with other declarators too, like :constant
13:13 AlexDaniel mmmhmm
13:13 jnthn It's a syntax for making declarations in vars
13:13 jnthn Used quite heavily in the Perl 6 grammar
13:13 jnthn Often for contextuals
13:13 psch right, only declarators, not all statements
13:14 jnthn MasterDuke: I think adding further methods to BOOTSTRAPATTR would be fine, or seeing if we can eliminate any of the users of it where it isn't absolutely needed
13:15 [Coke] one of the files in docs/ is causing a 'but got null' error in xt/aspell.t (on doc's spellcheck branch)
13:15 [Coke] gist at https://gist.github.com/coke/22c9c8af383b4e9dc3ab38cb44e70f58
13:16 MasterDuke adding methods is relatively straightforward, how would i eliminate users?
13:16 rudolfochrist joined #perl6
13:16 jnthn MasterDuke: See if there's anywhere that is using BOOTSTRAPATTER that could actually just use Attribute
13:16 jnthn (I don't know if there are any.)
13:16 p3rln00b .oO( a loaded machine gun would do... )
13:17 * [Coke] wonders where 'but got null' comes from, doesn't see it in source.
13:17 cygx joined #perl6
13:18 AlexDaniel [Coke]: it is low level, I think
13:18 bjz joined #perl6
13:19 [Coke] looked in nqp, moar, and rakudo.
13:20 rgrinberg joined #perl6
13:21 AlexDaniel [Coke]: maybe this? https://github.com/MoarVM/MoarVM/blob/2eedba88d2b0c08f94dd4426a60d0bc7f8effa13/src/strings/ops.h#L33
13:21 psch m: use nqp; class A { has str $!a; method BUILD { nqp::chars($!a) } }; A.new
13:21 camelia rakudo-moar d03459: OUTPUT«chars requires a concrete string, but got null␤  in method BUILD at <tmp> line 1␤  in block <unit> at <tmp> line 1␤␤»
13:21 psch there was something else that got a similar error, i forgot what though
13:22 psch [Coke]: that ^^^ is #126492 btw
13:22 synopsebot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=126492
13:22 [Coke] AlexDaniel, thanks.
13:29 pmurias joined #perl6
13:30 pmurias hi
13:30 DrForr Afternoon.
13:37 user9 joined #perl6
13:50 kaare_ joined #perl6
13:58 Possum joined #perl6
13:59 cowens_ joined #perl6
14:00 rudolfochrist joined #perl6
14:07 user9 joined #perl6
14:17 wamba joined #perl6
14:19 wamba joined #perl6
14:22 khw joined #perl6
14:23 dj_goku joined #perl6
14:23 dj_goku joined #perl6
14:30 [Coke] so, I think the root cause here is my run()'s - no matter what order I put the filesi n, I can only run 250 tests.
14:32 [Coke] is there a resource here that isn't getting claimed? https://github.com/perl6/doc/blob/spellcheck/xt/aspell.t#L25-L40 (wondering if I need to explicitly free up my run())
14:33 Derperperd joined #perl6
14:34 [Coke] ... if I just diag the exitcodes on the Proc's returned by those two runs, the test gets past 250 files. :|
14:35 dalek doc: b25a44a | (Luca Ferrari)++ | doc/Language/concurrency.pod6:
14:35 dalek doc: Explain the Promise available statuses.
14:35 dalek doc: review: https://github.com/perl6/doc/commit/b25a44a08e
14:35 dalek doc: d084947 | RabidGravy++ | doc/Language/concurrency.pod6:
14:35 dalek doc: Merge pull request #948 from fluca1978/master
14:35 dalek doc:
14:35 dalek doc: Explain the Promise available statuses.
14:35 dalek doc: review: https://github.com/perl6/doc/commit/d084947592
14:37 matt_ joined #perl6
14:37 ptolemarch joined #perl6
14:38 jast joined #perl6
14:38 matt| joined #perl6
14:41 lizmat [Coke]: open file handles ?
14:42 AlexDaniel [Coke]: what version of rakudo are you using?
14:42 AlexDaniel asking just in case
14:43 rindolf Hi all! This code is much slower with "perl6" from rakudobrew than it is with its python2/python3 equivalent (even without pypy, which is even faster) - https://github.com/perl6/perl6-examples/blob/master/categories/euler/prob551-shlomif.p6 . What can I do?
14:43 AlexDaniel mainly because :in → :out thing was broken before #129291
14:43 synopsebot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=129291
14:44 lizmat rindolf: lose the return statements that are not needed
14:45 El_Che lizmat: thx for fixing the JSON error output bug
14:45 yoleaux 03:04Z <p3rln00b> El_Che: JSON handler now fixed: https://rt.perl.org/Ticket/Display.html?id=129810
14:45 lizmat El_Che: Zoffix did that, so Zoffix++
14:45 El_Che oh, it was one of zoffix robots
14:45 El_Che :)
14:46 AlexDaniel lizmat: how much do you win by doing this?
14:46 AlexDaniel wasn't it optimized a it?
14:46 smls joined #perl6
14:46 rindolf lizmat: which ones?
14:47 lizmat m: sub a() { 42 }; for ^1000000 { a }; say now - INIT now
14:47 camelia rakudo-moar 6531ef: OUTPUT«0.20082102␤»
14:47 lizmat m: sub a() { return 42 }; for ^1000000 { a }; say now - INIT now
14:47 camelia rakudo-moar 6531ef: OUTPUT«0.503920␤»
14:47 [Coke] AlexDaniel: This is Rakudo version 2016.08.1 built on MoarVM version 2016.08
14:47 lizmat AlexDaniel: ^^^
14:48 lizmat rindolf: all the ones that are the last statement in a sub
14:48 rindolf lizmat: ah.
14:48 lizmat rindolf: add --> Nil to the signature for the ones with a bare 'return'
14:48 rindolf lizmat: what about the "return;" ones?
14:48 lizmat sub a(-->Nil) { ... no return needed }
14:48 [Coke] AlexDaniel: updating to .09
14:49 rindolf lizmat: what's the exact notation?
14:49 lizmat sub a(-->Nil) { ... no return needed }
14:49 rindolf lizmat: ah, and what if there are arguments?
14:49 AlexDaniel [Coke]: yeah
14:49 lizmat sub a($a, $b -->Nil) { ... no return needed }
14:50 lizmat actually, --> Nil would be better readable  :-)
14:50 AlexDaniel hm, it does affect it
14:58 girafe joined #perl6
14:59 bioduds how do I use a variable here?   my $dbh = DBIish.connect( "SQLite", :database<$db-name> );
14:59 bioduds on $db-name?
14:59 bioduds it is getting the literal of it
15:00 moritz bioduds: :database($db-name)
15:00 moritz the :name<...> form ie specifically for literals
15:00 moritz s/ie/is/
15:01 MilkmanDan joined #perl6
15:01 rindolf lizmat: thanks! But it's still very slow.
15:03 moritz rindolf: have you profiled it?
15:03 moritz perl6 --profile yourscript.p6
15:04 AlexDaniel rindolf: you can also try using native ints to see if it is going to help
15:04 AlexDaniel rindolf: these numbers are pretty small so it is proaly appropriate
15:04 lizmat rindolf: what AlexDaniel and moritz said
15:04 bioduds moritz : tx
15:05 bioduds as usual, I'm having problems interpolating vars with
15:05 bioduds withq
15:05 bioduds with q, sorry
15:05 moritz q doesn't interpolate
15:05 moritz that might explain it
15:06 hassoub joined #perl6
15:07 bioduds please, tell me how to do this? my $sth = $dbh.do( qq:to/STATEMENT/ );       DROP TABLE IF EXISTS $db-hashed     STATEMENT
15:07 bioduds qqw?
15:09 moritz bioduds: looks fine to me as is
15:10 bioduds weird, im getting this as error Use of uninitialized value $!last-sth-id of type Any in string context
15:11 moritz doesn't seem related to what you pasted here at all
15:11 * gfldex .oO( If you write a module, please consider :D )
15:11 moritz it's possible to have more than one error in the same file :-)
15:12 bioduds oh, I think I got it
15:12 bioduds cant start table name with number
15:14 moritz you probably have to quote it if you want to do that
15:14 AlexDaniel \o/
15:16 skids joined #perl6
15:18 [Coke] AlexDaniel: no love, still dies after 250.
15:18 * [Coke] tries HEAD
15:18 rindolf moritz: AlexDaniel : lizmat : here is the profile information - http://www.shlomifish.org/Files/files/text/profile-1476112183.18954.html
15:18 AlexDaniel [Coke]: sounds great!
15:18 AlexDaniel [Coke]: meaning that you've proably stumbled upon another run() bug!
15:18 AlexDaniel maybe
15:20 AlexDaniel [Coke]: I'm not sure, but maye you can try .close()-ing some handles
15:21 smls \o/
15:21 * smls finally nailed down an elusive concurrency-related data corruption bug in a Perl 6 script
15:21 AlexDaniel yay! sounds great too!
15:21 smls It appears that &dir and/or IO::Path is not quite thread-safe...
15:22 AlexDaniel smls: ummm… maybe you want to take a look at…
15:22 smls I have a golfed script, will RT shortly... :)
15:22 AlexDaniel smls: #129781 this?
15:22 synopsebot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=129781
15:23 smls AlexDaniel: In my case, concurrent `dir` sometimes gives me an internally inconsistent IO::Path
15:24 smls whose .Str representation disagrees with everything else (.gist, .perl, .absolute...)
15:24 moritz rindolf: there's nothing that stands out overly much from a cursory glance at the profile, and I don't have time to dig deeper
15:25 AlexDaniel smls: … yeah. Submit a ticket for sure
15:25 dj_goku joined #perl6
15:25 dj_goku joined #perl6
15:25 bioduds got it working, thanks :)
15:28 jonas2 joined #perl6
15:32 rindolf lizmat: what happened to the perl6 JVM backend? It is not mentioned anywhere in the README.md of rakudobrew
15:36 p3rln00b rindolf: Nothing happened to it. rakudobrew is a 3rd-party utility. See Rakudo's documentation.
15:36 p3rln00b rindolf: https://github.com/rakudo/rakudo/blob/nom/INSTALL.txt#L36
15:37 * p3rln00b starts to share the sentiment of avoiding suggesting people use rakudobrew
15:37 dataf3l joined #perl6
15:38 dataf3l p6: say 3
15:38 camelia rakudo-moar 92c092: OUTPUT«3␤»
15:38 dataf3l cool
15:38 dataf3l hey guys, after a weekend of google search and a bit of frustration, I come for help
15:38 dataf3l I’m a perl6 newbie
15:39 p3rln00b m: say ३३
15:39 camelia rakudo-moar 92c092: OUTPUT«33␤»
15:39 p3rln00b dataf3l: join the club! :)
15:39 dataf3l I’d like to know how to setup a perl6 webserver, like nodejs or perhaps golang, examples I found online mentioning the HTTP Simple package didn’t work
15:40 dataf3l I need to listen to a port and return json, you know, the simple stuff
15:40 dataf3l nothing fancy
15:40 dataf3l I was considerinf using apache and CGI, but somehow it feels wrong to do that.
15:40 p3rln00b dataf3l: what HTTP Simple package do you mean?
15:41 bioduds metaprogramming its own language is messy :)
15:41 RabidGravy HTTP::Server::Tiny is probably the easist
15:41 dataf3l this one
15:41 dataf3l http://szabgab.com/http-server-in-perl-6.html
15:42 p3rln00b That's... from 2011 :)
15:42 dataf3l yeah, that’s probably the reason :(
15:43 p3rln00b dataf3l: see https://github.com/tokuhirom/p6-HTTP-Server-Tiny and JSON can JSON portion can be done with modules.perl6.org/repo/JSON::Fast
15:43 RabidGravy It's literally "use HTTP::Server::Tiny;  HTTP::Server::Tiny.new.run(sub ($env) { return 200, [], ["something or other"] })"
15:43 dataf3l you mean this one, RabidGravy? use HTTP::Server::Tiny;
15:43 dataf3l https://github.com/tokuhirom/p6-HTTP-Server-Tiny
15:43 dataf3l ??
15:43 RabidGravy yes
15:44 dataf3l and I need to use panda to install it, correct?
15:44 RabidGravy or zef
15:45 dataf3l never heard of zef, “to the googles!”
15:45 rindolf p3rln00b: is there a better alternative to rakudobrew that is equally as convenient?
15:47 dataf3l installing zef...
15:50 dataf3l to be honest, I kinda expected a web server to be a part of the standard perl6 library, just like on golang or in python.
15:50 dataf3l I fear for my future
15:50 dataf3l what will happen 10 years from now, will this module still be arround?
15:51 dataf3l ok, I installed zef, but it looks like it “failed to update p6c”, no idea what that means, perhaps that module (HTTP::Server::Tiny) does not exist as a zef module?
15:53 dataf3l joined #perl6
15:57 [Coke] dataf3l: are you behind a corporate firewall, by chance?
15:57 dataf3l no, my friend, but my internet is sucky, do you think it may be a network failure?
15:58 [Coke] don't know. just reminiscent of issues I've had with panda when trying to go through the firewall here.
15:59 dataf3l I’m going to be honest, I moved to perl6 because golang didn’t offer the expressiveness I feel I need to write a specific type of sort-of-generic algorithm, however, I’m a little preoccupied by the size of the community.
15:59 dataf3l I’m honestly worried about a couple things: #1: jobs #2: libraries
15:59 [Coke] AlexDaniel: same failure with 2016.09-163-g92c0921
15:59 dataf3l should I worry at all, or should I wait, and in time, this will all be solved?
15:59 [Coke] dataf3l: sure, those are two very reasonable things to be worried about.
16:00 dataf3l I tried this command: panda install HTTP::Server::Tiny, it fails the unit tests.
16:00 dataf3l Result: FAIL
16:00 dataf3l The spawned process exited unsuccessfully (exit code: 1)
16:00 dataf3l in sub run-and-gather-output
16:00 [Coke] If I was hoping to make a living learning something, I'd probably make sure I could do that before spending the time.
16:00 dataf3l in sub run-and-gather-output at /usr/local/Cellar/rakudo-star/2016.07/share/perl6/site/sources/24811C576EF8F85E7672B26955C802BB2FC94675 (Panda::Common) line 85
16:00 dataf3l argh, all I needed was a simple webserver… :|
16:00 [Coke] dataf3l: what version of perl6 are you using?
16:00 [Coke] (perl6 --version)
16:01 dataf3l Felipes-MacBook-Pro:p6 a$ perl6 --version
16:01 dataf3l This is Rakudo version 2016.07.1 built on MoarVM version 2016.07
16:01 dataf3l implementing Perl 6.c.
16:01 [Coke] ok. two months old, but should still be ok.
16:01 dataf3l I just installed it using “brew install perl6” which is kinda the “normal” way of installing stuff on osx
16:02 [Coke] I prefer macports, but sure. ;)
16:03 dataf3l I’ll get the latest
16:03 [Coke] (trying to install HTTP::Server::Tiny here with panda on 2016.09)
16:05 [Coke] dataf3l: I just had it fail a bunch of tests here.
16:05 dataf3l you have the latest as well?
16:06 dataf3l I’m reading online about something called Bailador
16:06 dataf3l should I be using that instead?
16:06 [Coke] I've used bailador for a work project, I've been happy with it.
16:07 [Coke] I think my tests are failing locally because I'm going through the corporate http proxy for the 127.0.0.1 tests.
16:07 moritz that might be a bad idea, yes :-)
16:07 p3rln00b rindolf: yes,the Rakudo Star package which is what we ship for regular users' consumption: http://rakudo.org/downloads/star/ Rakudobrew is for using multiple rakudo versions at the same time and isn't something designed for regular users.
16:08 [Coke] this worked: http_proxy= GIT_PROTOCOL=https panda install HTTP::Server::Tiny
16:08 rindolf p3rln00b: I'm not a regular user.
16:08 p3rln00b rindolf: you sure sound like one.
16:08 [Coke] moritz: not sure how to whitelist certain hosts; think I got lucky that all the panda networking stuff is over https.
16:09 [Coke] so, dataf3l - the install did work here once I got the networking setup right.
16:09 dataf3l I’m installing Bailador
16:10 dataf3l looks closer to Sinatra
16:10 p3rln00b It is.
16:11 p3rln00b dataf3l: it's at a much earlier stage of development though. Last I tried it half a year ago, it wasn't able to even support concurrent connections.
16:11 dataf3l but will it support concurren connections now?! :)
16:11 p3rln00b dataf3l: check the commit history :)
16:12 dataf3l fails to install using panda
16:12 p3rln00b dataf3l: with you comparing Perl 6 to golang/python... keep in mind we're much younger (in terms of stability; we've just released last December) and the development is nearly entirely volunteer-driven (with no multi-billion company backing).
16:13 p3rln00b dataf3l: personally, I wouldn't use Perl 6 for anything web, at the moment. There's still a lot of work to do for optimization and memory leak hunting for it to be a suitable tool for the job.
16:14 p3rln00b Might be OK for a simple web service that serves JSON, but then, if you're writing something that simple, you won't get benefits of Perl 6's expressive power anyway.
16:14 MilkmanDan joined #perl6
16:15 moritz p3rln00b: a thing doesn't has to be simple, just because it spits out JSON
16:16 p3rln00b Sure. That's why I explicitly said for *simple* web service.
16:17 p3rln00b dataf3l: Bailador installs fine for me with zef on 2016.09-2-gc4fd9f5
16:18 p3rln00b dataf3l: zef being an alternate (and IMO better) installer: https://github.com/ugexe/zef
16:19 [Coke] dataf3l:(December release) focus this year from the perl6 devs is stability and performance improvements.
16:20 p3rln00b Yeah, we got more than twice faster since Dec.
16:20 bazzaar joined #perl6
16:20 bazzaar o/ perl6
16:20 wamba joined #perl6
16:21 p3rln00b \o
16:21 RabidGravy [Coke], was there actually a problem with HTTP::Server::Tiny or was it just your environment messing you up?
16:22 dataf3l joined #perl6
16:22 dataf3l ==> Successfully installed Bailador
16:22 p3rln00b \o/
16:23 dataf3l I kinda hoped to be able to do web development with JUST the standard library, I guess golang spoiled me...
16:23 p3rln00b heh
16:23 p3rln00b Well, you *can* :) It's just won't be super fun.
16:23 RabidGravy I actually switched the Audio::StreamThing to using HTTP::Server::Tiny the week and it's working swimmingly
16:23 bazzaar hi, in writing a bit of code to parse a jumbled mess of text, I noticed that a syntax error in regex substitution, resulted in an error message way down the code
16:24 bazzaar m: my $b = "dummy code"; my $a = Bazzaar; $a ~~ s/"i"/; $b = "dummer code"; my $c = "dummy cod"; my $d = "dumb koft"; say $a;
16:24 camelia rakudo-moar 92c092: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Variable '$c' is not declared␤at <tmp>:1␤------> 3r; $a ~~ s/"i"/; $b = "dummer code"; my 7⏏5$c = "dummy cod"; my $d = "dumb koft"; s␤»
16:24 p3rln00b bazzaar: 'cause it thinks you'
16:25 p3rln00b bazzaar: 'cause it thinks your code is part of the substitution string
16:26 [Coke] do we have a list of env vars that impact rakudo/moar?
16:26 dj_goku joined #perl6
16:26 dj_goku joined #perl6
16:26 [Coke] RabidGravy: just my env
16:26 RabidGravy cool
16:26 p3rln00b [Coke]: https://docs.perl6.org/programs/00-running#ENVIRONMENT_VARIABLES
16:26 bazzaar yes, understood, but maybe if the error message were to say that the substitution string included several semicolons, it could help debug
16:27 dataf3l I ran apache’s ab on Bailador’s helloworld, but I think performance may be acceptable, but I’m not sure if I should intepret the results as “can concurrently handle requests” or not...
16:27 dataf3l https://gist.github.com/dataf3l/2526fc1b18af60dfa66dfdb4c96afa1f
16:28 dataf3l I JUST ran it on my mac book pro, core i5
16:28 p3rln00b dataf3l: it's easy to test. Stick sleep 30 into a route and try to get a response on another route
16:28 dataf3l ok
16:28 [Coke] not sure if it's desirable, but you can wrap your route handling block in a start {} to make it run async.
16:28 p3rln00b [Coke]: how would you respond then?
16:29 [Coke] (just the block; wouldn't make the route handler -itself- concurrent if it's not)
16:29 [Coke] p3rln00b: in my case, it was for a github web hook - so I needed a quick response, and a long running async handler to do the heavy lifting.
16:29 [Coke] (not the normal case)
16:31 RabidGravy doesn't it take a Supply or a Channel as the response body?
16:31 dataf3l preliminary tests show in my machine it was not multi-threaded.
16:31 dataf3l I ean the test you recommended.
16:31 p3rln00b RabidGravy: wasn't when I tried in April, but I think ufobat was planning on fixing that
16:31 dataf3l single thread.
16:31 p3rln00b Not sure if they did already
16:32 dalek doc: a8e6e7d | titsuki++ | doc/Type/Attribute.pod6:
16:32 dalek doc: Fix the example of the Attribute.type method
16:32 dalek doc: review: https://github.com/perl6/doc/commit/a8e6e7ddb7
16:32 dalek doc: 9a5caec | titsuki++ | doc/Type/Attribute.pod6:
16:32 dalek doc: Merge pull request #951 from titsuki/fix-type
16:32 dalek doc:
16:32 dalek doc: Fix the example of the Attribute.type method
16:32 dalek doc: review: https://github.com/perl6/doc/commit/9a5caecc47
16:32 RabidGravy ah right, I knew there was a reason for using HST for the streaming server ;-)
16:32 p3rln00b :D
16:32 dataf3l so Tiny then?
16:37 bazzaar so my point was really to highlight the apparent 'un-relatedness' of the error message to the likely syntax error.
16:38 rudolfochrist joined #perl6
16:38 p3rln00b bazzaar: sure. It's even worse with heredocs: http://perl6.party/post/The-Awesome-Errors-of-Perl-6#heredoctheredoceverywheredoc
16:38 dataf3l HTTP::Server::Tiny worked correctly on my machine, after I cloned it from the repository
16:38 dataf3l now all I need to do is learn how to use it
16:39 RabidGravy nothing to learn really
16:39 dataf3l Thank you guys for your tremendous help, I feel this is an awesome community, hopefully, once I know more about Perl6, I’ll be able to contribute back! :)
16:39 RabidGravy use HTTP::Server::Tiny;  HTTP::Server::Tiny.new.run(sub ($env) { return 200, [], ["something or other"] });
16:39 p3rln00b bazzaar: I recall timotimo was trying to fix the heredoc problem, not sure if they succeeded. Similar issues may exist with s///
16:39 dataf3l I need to learn about routing and also about file uploads...
16:40 RabidGravy you probably want to look at Crust for routing with HST
16:40 timotimo oh
16:40 timotimo yes, there was some problems with the fix
16:41 timotimo and i couldn't come up with something satisfactory yet
16:43 bazzaar p3rln00b: nice article, nice blog, I do read it when something new is posted.
16:43 p3rln00b Yeah, the guy who writes it is super awesome.
16:45 timotimo yes
16:45 dataf3l I remember learning about go about a year ago or two, but I also remember trying out golang like, 5 years ago, I remember thinking “this isn’t ready”, and I also remember I dropped it back then. I kinda get the same feelings about Perl6 right now, I feel it quite isn’t ready for production, but If I wait 10 years for it to be, then I will have waited too long, I wonder If I should invest in Perl6 now, and see if it becomes popular in the future, or if I
16:45 dataf3l should wait a year or two for the dust to settle...
16:45 bazzaar timotimo: for s///, maybe the error message could report the number of lines of code tied up in the apparent substitution string?
16:46 timotimo bazzaar: the problem with my approach was that it put a worry into the list of worries, but it was unable to pop the worry off afterwards
16:46 timotimo so if there was an error due to a too-long heredoc, it'd show the worry as "potential issues" and it'd be fine
16:46 timotimo but if there was no error afterwards, it'd also show up, even if the rest of the program was just fine
16:47 p3rln00b dataf3l: if your time is limited, waiting a year sounds like a plan, try out some other lang. Also an option: join the core development effort :) Lots of stuff to do!
16:47 timotimo it's also possible to donate some money that can go into the core development fund which currently funds jnthn to do lots of very good work
16:47 timotimo i think it's about 50 euros per work-hour
16:48 dataf3l wow
16:48 timotimo if you're interested in the kinds of things jnthn does in those work-hours, check out https://6guts.wordpress.com/
16:49 AlexDaniel dataf3l: I have a slightly different recommendation: start using it today, report bugs
16:49 bazzaar timotimo: understood, a clean, efficient solution is what you want, so not easy to figure out the best way, unfortunately is beyond my level of experience
16:49 RabidGravy yeah, I'm with AlexDaniel
16:50 AlexDaniel dataf3l: basically, that's what I am doing. If I had to wait a year to start using it I'd kill myself
16:50 dataf3l I don’t think I know enough about it to contribute meaningfully, but I’ll consider it
16:50 timotimo i can imagine multiple solutions. one would be to mix in a role that lets you "defuse" a worry, and a function to throw out any defused worries before going on
16:50 dataf3l also
16:50 AlexDaniel for me, it's not production ready, yes. But with every bug report I file it is getting closer
16:50 timotimo i suppose i could also find the same worry in the list and just splice it out
16:51 timotimo (then i'd have to make sure that multiple worries can be handled at the same time for this)
16:51 skids joined #perl6
16:52 timotimo bazzaar: though i also think it's not so important for this solution to be extremely performant, since it'd only ever come into play when things get messed up
16:52 dataf3l joined #perl6
16:52 bazzaar dataf31: I'm a relative newby, but after using perl6 I wouldn't go back to perl5 (which I've used to solve data problems for nigh on 20 years)
16:52 AlexDaniel bazzaar: haha! Got you!
16:53 AlexDaniel bazzaar: it's l not 1 :D
16:54 FROGGS joined #perl6
16:54 FROGGS o/
16:55 p3rln00b \o
16:55 AlexDaniel dataf3l: and maybe this will help you consider my recommendation: I submitted over 150 tickets, half of them are resolved
16:55 AlexDaniel dataf3l: so perl 6 team is doing a great job actually
16:55 bazzaar AlexDaniel: ?sorry am a bit slow, not sure I follow, but I'm happy to agree I've been gotten :)
16:56 [Coke] AlexDaniel: aha: if I use MVM_SPESH_DISABLE=1, my program works fine.
16:56 AlexDaniel bazzaar: you wrote dataf31 when it is actually dataf3l
16:56 dataf3l that’s impressive, AlexDaniel
16:56 dataf3l sorry guys, everybody makes that mistake, but this is my handle, and I have to live with it.
16:56 AlexDaniel dataf3l: all that during the last year I think
16:57 [Coke] well, you're welcome to hang out here while you figure out if you like perl6 or not, we're happy to answer questions and fix bugs.
16:58 bazzaar AlexDaniel: I'm also a complete novice at typing and irc chat, apologies for my mistake :)
16:58 AlexDaniel that nickname is great. The only reason I noticed it is because it was not highlighted
16:59 AlexDaniel it's not just that l and 1 look similar, it's the fact that there's 3 in front of it
17:00 AlexDaniel maybe foobarl994 will have a similar effect?
17:01 * AlexDaniel still hopes that one day he will have enough free time to fix another half
17:04 maybekoo2 joined #perl6
17:07 dataf3l joined #perl6
17:09 lucasb joined #perl6
17:09 firstdayonthejob joined #perl6
17:13 bazzaar timotimo: yes for s///, apparently missing the final '/' before the first ';' is encountered in the code, is going to be a condition that is down to a coding bug most always. So building a flag for that condition would only impact performance for code development for the most part, I would say
17:13 matiaslina joined #perl6
17:16 jnthn bazzaar, timotimo: You might be able to build some error detection by noticing the code is inside a quote construct upon getting an undeclared variable error, and then doing some heuristics (is it on a different line and not a heredoc, for example)
17:23 dataf3l joined #perl6
17:23 bazzaar joined #perl6
17:24 AlexDaniel shouldn't it just say when s/// was started?
17:24 AlexDaniel m: #`{␤␤␤␤␤␤␤␤␤␤␤␤␤␤␤␤␤␤␤
17:24 camelia rakudo-moar f117a6: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Couldn't find terminator } (corresponding { was at line 1)␤at <tmp>:20␤------> 3<BOL>7⏏5<EOL>␤    expecting any of:␤        }␤»
17:25 rgrinberg joined #perl6
17:25 AlexDaniel ↑ notice how it says “corresponding { was at line 1”
17:25 AlexDaniel m: #`[[[[␤␤␤␤␤␤␤␤␤␤␤␤␤␤␤␤␤␤␤
17:25 camelia rakudo-moar f117a6: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Couldn't find terminator ]]]] (corresponding [[[[ was at line 1)␤at <tmp>:20␤------> 3<BOL>7⏏5<EOL>␤    expecting any of:␤        ]]]]␤»
17:25 jnthn AlexDaniel: Sure, but here we aren't missing a terminator, we're finding an undeclared variable because of the lack of terminator
17:25 p3rln00b It's not about finding the terminator, but about interpreting the code that isn't meant to be part of the replacement as part of it.
17:25 AlexDaniel ah
17:26 AlexDaniel right
17:26 jnthn So yes, we'd want to show the line where the quote started; I was just suggesting a way to guess when this situation is happening
17:26 jnthn So that s/foo/$ba/ does not trip it, for example
17:26 p3rln00b bazzaar: that isn't true, as you can have code bugs in strings. s/foo/bar{ some; code; }/ isn't as rare a condition as you imply.
17:26 jnthn (where $ba shoulda been $bar)
17:27 p3rln00b s/bugs/blocks/;
17:27 p3rln00b heh
17:27 dj_goku joined #perl6
17:27 bazzaar p3rln00b: I see
17:33 matiasli1a joined #perl6
17:35 bazzaar so maybe raise a flag if the s/// is not completed by the end of the outer block?
17:37 bazzaar s/outer/enclosing/
17:38 timotimo how do you figure out the outer block if it's inside the s///? :)
17:42 bazzaar I'm thinking the block that started prior to the s/// statement, it probably still wouldn't be ideal, as it might be a large block of code?
17:42 timotimo if you're parsing malformed code, there may not be such a thing as "the end of the outer block"
17:46 domidumont joined #perl6
17:49 bazzaar missing curly braces are easier to see than an embedded 's/regex/;' which on the face of it has a paired '/' and a terminating ';'
17:49 timotimo and probably also a newline
17:50 bazzaar yes
17:50 timotimo i can imagine wanting to replace something with the literal string ";\n}"
17:52 telex joined #perl6
17:55 DrForr Well, *this* is a new error... "class *mumble*::Directive does not support inheritance" - It's admittedly an empty class (not even an attribute), would that be why it's not allowed to be inherited from?
17:56 ufobat RabidGravy, p3rln00b that depends on the progress of the p6w/psgi draft. but in general of course there sould be propper concurrency
17:56 bazzaar so that would be the end of the enclosing block right there, without the terminating '/', so a flag could be raised in case of error being generated in subsequent code?
17:56 timotimo could be
17:57 timotimo are you interested in the code i've written so far so you can get a feel for what it could look like?
17:59 timotimo https://github.com/rakudo/rakudo/commit/d184fcd2f42a80551c60f3d56a6982656689d55c - this is the commit
18:00 bazzaar well I'd be happy to look, but it might be more than I can comprehend, but maybe I'd be able to ask the odd semi-pertinent question
18:01 bazzaar timotimo: I'll take a look, thanks for the link
18:01 timotimo it completely lacks the "throw out the worry if the heredoc turned out all right" logic
18:01 bazzaar understood
18:05 matiaslina joined #perl6
18:06 kam_r joined #perl6
18:16 lizmat rindolf: re http://www.shlomifish.org/Files/files/text/profile-1476112183.18954.html#/routines , looks like all of the top items are in Perl 6 itself, so it looks like not many improvements are possible (apart from using natives where possible)
18:18 rindolf lizmat: ah.
18:20 dataf3l joined #perl6
18:28 dj_goku joined #perl6
18:28 dj_goku joined #perl6
18:29 DrForr Okay, this is interesting. 'class Foo::Directive::If { also is Foo::Directive; }' throws the "class Foo::Directive cannot be inherited from" error, whereas "classs Foo::Directive::If is Foo::Directive {...}" doesn't.
18:31 bioduds $row[2] ~~ s/\n//;
18:31 bioduds this is how you remove \n from a string?
18:32 DrForr $row[2].chomp # more portable, I assume you want the trailing \n removed.
18:34 bioduds yes, I'm struggling to put a string back into json format
18:40 mniip joined #perl6
18:41 DrForr Then .chomp() should do it.
18:42 bioduds I'm getting this back: "[{ "database": "futs", "ID": 1, "tables": "[{\n \"name\": \"Técnicos\",\n \"hash\": \"1de95e02d872f5b7900e40e3733\"\n},{\n \"name\": \"Times\",\n \"hash\": \"38eefeeae76046601073b604900\"\n},{\n \"name\": \"Campeonatos\",\n \"hash\": \"2eee6323ffcac49a3adca8007d4\"\n}]" },{ "database": "general", "ID": 2, "tables": "[{\n \"name\": \"Estados\",\n \"hash\": \"422c3cc84c65d120d12ee5234bf\"\n},{\n \"name\": \"Cid
18:42 bioduds see the \n ?
18:42 bioduds also, it is bringing me \"
18:42 p3rln00b bioduds: what's the problem with it?
18:42 bioduds I only need "
18:42 bioduds it won't parse on JSON.parse back on javascript front
18:43 p3rln00b bioduds: have you actually tried?
18:43 bioduds yes
18:43 firstdayonthejob joined #perl6
18:43 bioduds SyntaxError: Unexpected token u in JSON at position 0
18:43 dataf3l joined #perl6
18:43 p3rln00b bioduds: and where are you getting this JSON from?
18:44 bioduds retrived from sqlite and using use JSON::Class;
18:44 DrForr Looks like someone's trying to nest a JSON file within a JSON key.
18:45 ptolemarch joined #perl6
18:45 bioduds exactly, trying to nest it, correct
18:45 DrForr Print the actual data you're getting back from SQLite, I think you're missing a from-json() call somewhere up the line.
18:50 bioduds using use JSON::Tiny; im doing now my $tables = from-json($row[2]).perl;
18:50 bioduds getting: "[{ "database": "futs", "ID": 1, "tables": "[{:hash(\"1de95e02d872f5b7900e40e3733\"), :name(\"Técnicos\")}, {:hash(\"38eefeeae76046601073b604900\"), :name(\"Times\")}, {:hash(\"2eee6323ffcac49a3adca8007d4\"), :name(\"Campeonatos\")}]" },{ "database": "general", "ID": 2, "tables": "[{:hash(\"422c3cc84c65d120d12ee5234bf\"), :name(\"Estados\")}, {:hash(\"153c87a219b89c36fa83ad71a53\"), :name(\"Cidades\")}, {:hash(\"1309d560c34
18:50 bioduds sorry, im a bit confused
18:52 girafe joined #perl6
18:52 DrForr Look at what $row[2] is, and I think that's a problem right there, shouldn't it be @row[2]? Or $row.[2] if it's a reference?
18:52 bioduds holly ghost, check this: "[{ "database": "futs", "ID": 1, "tables": "\"\\\"[\\{\\\\n \\\\\\\"name\\\\\\\": \\\\\\\"T\\\\u00e9cnicos\\\\\\\",\\\\n \\\\\\\"hash\\\\\\\": \\\\\\\"1de95e02d872f5b7900e40e3733\\\\\\\"\\\\n},\\{\\\\n \\\\\\\"name\\\\\\\": \\\\\\\"Times\\\\\\\",\\\\n \\\\\\\"hash\\\\\\\": \\\\\\\"38eefeeae76046601073b604900\\\\\\\"\\\\n},\\{\\\\n \\\\\\\"name\\\\\\\": \\\\\\\"Campeonatos\\\\\\\",\\\\n \\\\\\\"hash\\\\\\\": \
18:53 bioduds let me see DrForr
18:53 bioduds for @rows -> $row {     my $tables = to-json($row[2]).perl;     my $result = Result.new( ID=>$row[0], database=>$row[1], tables=>$tables );     @json.push( $result.to-json() );   }
18:53 bioduds I guess is $row[2] is correct
18:54 bioduds i didn't get this .perl yet
18:55 DrForr That still has the issue. What does '$row.gist' print? (preferably in a pastebin because it's going to get large.)
18:55 DrForr ANd I see '
18:55 DrForr Grr. '\u00e9' in there, that'll have to be converted to Perl 6 syntax before it can be displayed properly.
18:57 bioduds $row.gist : [1 futs [{   "name": "Técnicos",   "hash": "1de95e02d872f5b7900e40e3733" },{   "name": "Times",   "hash": "38eefeeae76046601073b604900" },{   "name": "Campeonatos",   "hash": "2eee6323ffcac49a3adca8007d4" }]] [2 general [{   "name": "Estados",   "hash": "422c3cc84c65d120d12ee5234bf" },{   "name": "Cidades",   "hash": "153c87a219b89c36fa83ad71a53" },{   "name": "Países",   "hash": "1309d560c348e2d300e695f3935" }]]
18:58 labster joined #perl6
19:00 DrForr That's an odd mixture there, I think I'd better see just $row.perl;
19:01 DrForr These days I'm in the habit of just writing a .dump method somewhere to get human-readable data out as I'm not *really* fond of .gist or .perl output, too dense for my taste.
19:03 bioduds perl6 dbs.pl  $[1, "futs", "[\{\n  \"name\": \"Técnicos\",\n  \"hash\": \"1de95e02d872f5b7900e40e3733\"\n},\{\n  \"name\": \"Times\",\n  \"hash\": \"38eefeeae76046601073b604900\"\n},\{\n  \"name\": \"Campeonatos\",\n  \"hash\": \"2eee6323ffcac49a3adca8007d4\"\n}]"] $[2, "general", "[\{\n  \"name\": \"Estados\",\n  \"hash\": \"422c3cc84c65d120d12ee5234bf\"\n},\{\n  \"name\": \"Cidades\",\n  \"hash\": \"153c87a219b89c36fa83ad71a53\"\n
19:04 bioduds these \" are making me uneasy
19:04 DrForr So your JSON comes out in column 2. from-json( $row.[2] ) # should return the data structure correctly.
19:04 bioduds :)
19:05 DrForr Why? It's just because the .perl output uses "", how else is it going to distinguish '"' in the string from '"' in the outer data structure?
19:06 bioduds from-json giving me "Type check failed in assignment to $!tables; expected Str but got Array ($[{:hash("1de95e02d87...) in sub MAIN at ../../../../../../scripts/dbs.pl line 32 in block <unit> at ../../../../../../scripts/dbs.pl line 16 "
19:07 bioduds should I structure all in a nested class and use to-json in it?
19:07 DrForr Yes, because $row is a scalar, and contains a *reference* to an array, not the array itself. '$row[2]' assumes that $row is an array, and rather oddly to my way of thinking.
19:08 DrForr I imagine 'say $row[2]' would return something starting with a '[' character which means that you're trying to treat an array reference as if it were an array.
19:09 lucasb DrForr: you are thinking Perl 5, right?
19:11 bioduds yes
19:11 bioduds should I remove the staring [ ?
19:11 DrForr lucasb: I'm aware of which channel I'm talking in :) If $row[] does automatic dereferencing now that's great, but the data structure and what he's displaying don't quite match, and that's what I'm getting at.
19:11 bioduds starting [
19:12 DrForr And I tyop'ed there, I meant 'say $row' would return...
19:12 lucasb I arrived in the middle of the conversation, so idk the details, sorry :)
19:13 dataf3l joined #perl6
19:13 DrForr Oh, I'm quite happy to be corrected, no worries.
19:14 bioduds say $row gets me [1 futs {   "name": "Técnicos",   "hash": "4a71c17e156070bab57d5f8c879" },{   "name": "Times",   "hash": "579c076ae1ac930b54caa4c37b" },{   "name": "Campeonatos",   "hash": "22c4addfafee958695d99716ab4" }]
19:14 DrForr Okay, so $row *is* a reference to an array, not the array itself. Which is as it should be.
19:15 bioduds great, now the smart approach would be to do what? parse the string?
19:15 bioduds but I can't remove the \" from it
19:15 bioduds at least I don't know how
19:16 DrForr You can't "remove" the \" from it because the \\ isn't actually there. As I said, it's just Perl's way of telling you that the string's *content* has '"' marks in it.
19:17 DrForr m: say 'hi "world" there'
19:17 camelia rakudo-moar f117a6: OUTPUT«hi "world" there␤»
19:17 DrForr Bad example :)
19:17 DrForr m: say ['hi "world" there']
19:17 camelia rakudo-moar f117a6: OUTPUT«[hi "world" there]␤»
19:17 DrForr m: say ['hi "world" there',1]
19:17 camelia rakudo-moar f117a6: OUTPUT«[hi "world" there 1]␤»
19:17 DrForr m: say ['hi "world" there',1].perl
19:17 camelia rakudo-moar f117a6: OUTPUT«["hi \"world\" there", 1]␤»
19:17 DrForr THere.
19:18 DrForr Sorry for the noise.
19:19 andrzejku_ joined #perl6
19:19 Derperperd joined #perl6
19:20 DrForr So what you need to do is find the actual string that you want to un-JSONify, and process *that*.
19:20 DrForr I'm a litte surprised that '$row[2]' works, but not very. However it's not giving you the result that you want, so it's time to look again.
19:20 andrzejku_ hello my friends
19:20 andrzejku_ :)
19:21 DrForr m: my $x=[1,'"json"']; say $x[1]; say $x.[1]
19:21 camelia rakudo-moar f117a6: OUTPUT«"json"␤"json"␤»
19:21 DrForr So it does autoderef, good to know.
19:23 DrForr So $row[2] = from-json($row[2]); # should convert the contents of the JSON string to a Perl 6 data structure and stuff it back into the arrayref.
19:24 DrForr (assuming you're using JSON::Tiny here.)
19:28 labster joined #perl6
19:30 bioduds sorry, making trials there
19:30 dj_goku joined #perl6
19:30 sjoshi joined #perl6
19:30 DrForr No worries, just pushing around code.
19:33 andrzejku_ DrForr, hello
19:34 DrForr Evenin'.
19:34 bioduds I can nest a class in Perl6 right?
19:35 andrzejku_ DrForr, how are you my friends?
19:35 DrForr Yeah, I'm looking at a 'my class Name { ... }' declaration right now as it happens.
19:35 DrForr Getting close to bedtime as it happens.
19:36 bioduds I'm goint to try to nest as a class and transform all with .to-json from JSON::Class
19:37 DrForr Feel free. Really I think you're just not decoding the right element.
19:40 DrForr Having said that I'll note I don't know much if anything about JSON::Class.
19:43 skids joined #perl6
19:51 ccakes joined #perl6
19:53 bioduds got it
19:53 bioduds finally
19:53 cstls joined #perl6
19:54 bioduds DrForr : if you're interested. To make it work I built the array with '[' ~ @futs.join(',') ~ ']'; and stored it as varchar on the db.
19:54 bioduds then to retrieve it
19:55 bioduds this here works   for @rows -> $row {     $row[2] ~~ s:g/\n//;     my $tables = from-json( $row[2] );     my $result = Result.new( ID=>$row[0], database=>$row[1], tables=>$tables );     @json.push( $result.to-json() );   }   print '[' ~ @json.join(',') ~ ']';
19:55 bioduds and is recognized back on the javascript
19:57 DrForr Still feels a touch odd to me, but if it works...
20:07 bioduds works :)
20:08 bioduds had to clean out the \n before using from-json
20:08 bioduds odd, agree
20:08 bioduds but does what it should
20:09 dogbert17 .tell rindolf change 'self.n._format_n;' to e.g. '0 x (30 - self.n.chars) ~ self.n'. sprintf is slow
20:09 yoleaux dogbert17: I'll pass your message to rindolf.
20:09 rindolf dogbert17: hi.
20:09 yoleaux 20:09Z <dogbert17> rindolf: change 'self.n._format_n;' to e.g. '0 x (30 - self.n.chars) ~ self.n'. sprintf is slow
20:11 cygx_ joined #perl6
20:12 dogbert17 rindolf: the difference should be noticable
20:15 ccakes joined #perl6
20:16 rindolf dogbert17: thanks! It is noticeable.
20:17 dogbert17 rindolf: cool
20:19 cstls joined #perl6
20:19 Xliff joined #perl6
20:25 dalek perl6-examples: 182078b | (Shlomi Fish)++ | categories/euler/prob551-shlomif.p6:
20:25 dalek perl6-examples: Optimize by removing explicit returns.
20:25 dalek perl6-examples:
20:25 dalek perl6-examples: Thanks to lizmat on #perl6.
20:25 dalek perl6-examples: review: https://github.com/perl6/perl6-examples/commit/182078b33a
20:25 dalek perl6-examples: 451dc9b | (Shlomi Fish)++ | categories/euler/prob551-shlomif.p6:
20:25 dalek perl6-examples: Major optimisation thanks to dogbert17.
20:25 dalek perl6-examples:
20:25 dalek perl6-examples: sprintf() is slow. ☹
20:25 dalek perl6-examples: review: https://github.com/perl6/perl6-examples/commit/451dc9b3c3
20:27 timotimo are explicit returns still very slow? i thought jnthn's recent-ish work gave them a decent boost?
20:30 lizmat timotimo: yes, they are definitely faster but:
20:30 lizmat m: sub a() { return 42 }; for ^1000000 { a }; say now - INIT now
20:30 camelia rakudo-moar f117a6: OUTPUT«0.967294␤»
20:30 lizmat m: sub a() { 42 }; for ^1000000 { a }; say now - INIT now
20:30 camelia rakudo-moar f117a6: OUTPUT«0.1990598␤»
20:30 timotimo wow
20:30 lizmat m: say (9672 / 1990)
20:30 camelia rakudo-moar f117a6: OUTPUT«4.860302␤»
20:30 timotimo that's certainly a difference
20:30 dj_goku joined #perl6
20:30 dj_goku joined #perl6
20:31 lizmat also, I think explicit returns are preventing inlining, are they not ?
20:31 jnthn Trouble is, the second one will have gotten a bunch faster too :P
20:31 sjoshi joined #perl6
20:32 * lizmat stops mucking with Str.match and starts working on the P6W
20:32 jnthn There's some inlining-related sub-optimality there
20:32 jnthn I forget whether it's that a won't be inlined or return won't be
20:37 Juerd Is there ever any difference in semantics between having 'return' or not having it, for the last statement of a sub?
20:37 Juerd If not, couldn't the optimizer just remove it?
20:38 jnthn I thought it actually did that at some point...
20:38 ocbtec joined #perl6
20:39 bjz joined #perl6
20:42 lizmat pretty sure it isn't anymore, otherwise we shouldn't see this difference in performance, no ?
20:43 jnthn Indee
20:43 jnthn *d
20:44 devmikey joined #perl6
21:05 moritz there can be difference, for a rw routine
21:05 moritz because explict return decontainerizes
21:12 yqt joined #perl6
21:17 bbkr joined #perl6
21:18 sjoshi joined #perl6
21:19 nicq20 joined #perl6
21:21 nicq20 hello!
21:21 DrForr Evenin'!
21:23 lizmat PSA: is there something important I missed the past week that should be mentioned in the Perl 6 Weekly?
21:26 nicq20 Not that I can think of, though I mostly check the Reddit page.
21:28 DrForr ORA did mention Ruth's interview with me in their newsletter.
21:28 MasterDuke moritz asking for book topic suggestions?
21:28 DrForr Dunno if it's worthwhile.
21:31 lizmat well, I mentioned Ruth's interview already 2 weeks ago in the P6W
21:31 DrForr Yah, I know.
21:31 dj_goku joined #perl6
21:31 DrForr I'm just sh*t at this self-promotion thing.
21:32 rindolf nicq20: hi.
21:32 dalek modules.perl6.org: 9f77cfe | (Martin McGrath)++ | templates/root/index.html.ep:
21:32 dalek modules.perl6.org: change 'not set up' repo URLs
21:32 dalek modules.perl6.org:
21:32 dalek modules.perl6.org: Change 'not set up' repo URLs to link to https://docs.travis-ci.com/user/languages/perl6
21:32 dalek modules.perl6.org:
21:32 dalek modules.perl6.org: https://github.com/perl6/modules.perl6.org/issues/47
21:32 dalek modules.perl6.org: review: https://github.com/perl6/modules.perl6.org/commit/9f77cfea3d
21:32 dalek modules.perl6.org: 30cc57d | (Martin McGrath)++ | templates/root/index.html.ep:
21:32 dalek modules.perl6.org: Update index.html.ep
21:32 dalek modules.perl6.org: review: https://github.com/perl6/modules.perl6.org/commit/30cc57dcd7
21:32 dalek modules.perl6.org: 90e6c3c | RabidGravy++ | templates/root/index.html.ep:
21:32 dalek modules.perl6.org: Merge pull request #62 from MartinMcGrath/patch-1
21:32 dalek modules.perl6.org:
21:32 dalek modules.perl6.org: change 'not set up' repo URLs
21:32 dalek modules.perl6.org: review: https://github.com/perl6/modules.perl6.org/commit/90e6c3c766
21:32 pdcawley joined #perl6
21:32 nicq20 rindolf: Hello there!
21:33 lizmat rindolf: it's a good thing I'm not on Facebook
21:34 smls bisect: sub t { say $*d }; my $*d = 1; await  do { start { t() } }
21:34 bisectable6 smls, Bisecting by exit code (old=2015.12 new=6531ef7). Old exit code: 1
21:35 bisectable6 smls, bisect log: https://gist.github.com/667d94f78e80294dd408e5f26c97010b
21:35 bisectable6 smls, (2016-08-19) https://github.com/rakudo/rakudo/commit/25e9fd76e85fabda20e263b6f87e27b0673f26e2
21:37 rindolf lizmat: ok.
21:37 rindolf nicq20: sup?
21:39 nicq20 Oh, not too much. Looking at some of the Hacktoberfest issues.
21:39 nicq20 Trying to get this one done: https://github.com/perl6/doc/issues/364
21:39 smls bisect: my $*A = 42; do { start { $*A++ } }; sleep 1; say $*A
21:39 bisectable6 smls, Bisecting by output (old=2015.12 new=6531ef7) because on both starting points the exit code is 0
21:39 labster joined #perl6
21:40 bisectable6 smls, bisect log: https://gist.github.com/6a55852f185c74929a35dfb5acdd3919
21:40 bisectable6 smls, (2016-08-19) https://github.com/rakudo/rakudo/commit/25e9fd76e85fabda20e263b6f87e27b0673f26e2
21:41 nicq20 rindolf: Any ideas?
21:43 donaldh joined #perl6
21:43 rindolf nicq20: don't know.
21:45 lizmat and another Perl 6 Weekly hits the Net: https://p6weekly.wordpress.com/2016/10/10/2016-41-the-answer-is-near/
21:47 rindolf lizmat: thanks!
21:47 cstls joined #perl6
21:55 smls bisect: [*] set(1,2,3),
21:55 bisectable6 smls, On both starting points (old=2015.12 new=6531ef7) the exit code is 0 and the output is identical as well
21:55 bisectable6 smls, Output on both points:
21:55 smls bisect: say [*] set(1,2,3),
21:55 bisectable6 smls, Bisecting by output (old=2015.12 new=6531ef7) because on both starting points the exit code is 0
21:55 bisectable6 smls, bisect log: https://gist.github.com/488ec128113552a10c3d8cb02c3c263e
21:55 bisectable6 smls, (2016-08-30) https://github.com/rakudo/rakudo/commit/b1c444f0622bc348a2e860a43faa6d72e9a11558
21:58 ccakes joined #perl6
22:04 AlexDaniel smls: the last one is related to #128758 I think
22:04 synopsebot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=128758
22:05 smls AlexDaniel: Yes, that's where I got it from... :)
22:06 smls I wanted to see if a special case was added to numify [*] args, or if single-arg reduce now calls the operator with one arg.
22:07 smls Apparently, the latter, thanks to TimToady++
22:08 smls I wonder why this still doesn't work though:
22:08 smls m: say [Z] <a b>,
22:08 camelia rakudo-moar f117a6: OUTPUT«((a b))␤»
22:08 AlexDaniel committable6: 2014.01 say [Z] <a b>,
22:08 committable6 AlexDaniel, ¦«2014.01»: No build for this commit
22:08 AlexDaniel committable6: 2014.02 say [Z] <a b>,
22:08 committable6 AlexDaniel, ¦«2014.02»: No build for this commit
22:09 AlexDaniel MasterDuke: /o\
22:09 AlexDaniel MasterDuke: I know why
22:10 smls why?
22:10 smls m: say &infix:<Z>.arity;
22:10 camelia rakudo-moar f117a6: OUTPUT«0␤»
22:10 smls say infix:<Z>( (<a b>,), )
22:10 smls m: say infix:<Z>( (<a b>,), )
22:10 camelia rakudo-moar f117a6: OUTPUT«((a) (b))␤»
22:11 smls ^^ Whis is what `[Z] <a b>,` should output.
22:13 AlexDaniel m: say zip (<a b>,)
22:13 camelia rakudo-moar f117a6: OUTPUT«((a) (b))␤»
22:13 AlexDaniel m: say zip <a b>,
22:13 camelia rakudo-moar f117a6: OUTPUT«((a b))␤»
22:14 AlexDaniel smls: I don't know how it should work. But I know why there is no build for 2014.01 :)
22:17 nicq20 AlexDaniel: So would the ^ twigle be considered a shortcut?
22:18 nicq20 AlexDaniel: Or is it just a feature that can be considered a shortcut (similar to »)?
22:20 AlexDaniel nicq20: well, instead of writing a proper signature (e.g. ï½¢sub foo($ticket, $order) { say $ticket, $order }ï½£ ) one writes ï½¢sub foo { say $^ticket, $^order }ï½£. Yeah, sounds like a shortcut that does not work
22:22 AlexDaniel we don't have » listed as a trap, don't we?
22:25 nicq20 AlexDaniel: Not that I could find with a search. What about the "Captures" section?
22:25 AlexDaniel nicq20: what about it?
22:26 nicq20 AlexDaniel: I was thinking it might fit under that subheading better... but it is not really a capture.
22:27 AlexDaniel not a Capture at all :)
22:27 AlexDaniel nicq20: yeah, create a new subheading I guess. “Shortcuts that don't work” or whatever, we can change it later
22:28 AlexDaniel nicq20: I think it's much more important to document the actual thing than to have this bikeshedding over the heading :)
22:28 nicq20 AlexDaniel: Yeah, it's not like it can't be changed. :)
22:32 dj_goku joined #perl6
22:35 bjz joined #perl6
22:39 bjz joined #perl6
22:41 AlexDaniel m: say (<30 50 60>, <3 4 5 6>)».&(*.elems)
22:41 camelia rakudo-moar f117a6: OUTPUT«((1 1 1) (1 1 1 1))␤»
22:41 AlexDaniel m: say (<30 50 60>, <3 4 5 6>)».elems
22:41 camelia rakudo-moar f117a6: OUTPUT«(3 4)␤»
22:41 AlexDaniel so in case of ».& it does deepmap
22:42 AlexDaniel ut for ». it simply does map
22:42 AlexDaniel committable6: releases say (<30 50 60>, <3 4 5 6>)».&(*.elems)
22:42 committable6 AlexDaniel, ¦«2015.10,2015.11,2015.12,2016.02,2016.03,2016.04,2016.05,2016.06,2016.07.1,2016.08.1,HEAD»: ((1 1 1) (1 1 1 1))
22:42 AlexDaniel committable6: releases say (<30 50 60>, <3 4 5 6>)».elems
22:42 committable6 AlexDaniel, ¦«2015.10,2015.11,2015.12,2016.02,2016.03,2016.04,2016.05,2016.06,2016.07.1,2016.08.1,HEAD»: (3 4)
22:42 AlexDaniel yeah… but why?
22:48 smls AlexDaniel: I think it has to do with whether the routine has the `is nodal` trait (though I don't quite understand that mechanism)
22:49 AlexDaniel .tell perlawhirl whyyyyyyyyy? https://irclog.perlgeek.de/perl6/2016-10-10#i_13374587
22:49 yoleaux AlexDaniel: I'll pass your message to perlawhirl.
22:49 smls I guess if you construct a custom WhateverCode, it doesn;t have that trait
22:49 smls whereas the method itself might
22:58 canopus joined #perl6
23:00 cstls joined #perl6
23:05 MilkmanDan joined #perl6
23:05 zacts joined #perl6
23:09 mattp_ joined #perl6
23:28 rgrinberg joined #perl6
23:29 dj_goku joined #perl6
23:30 cstls joined #perl6
23:31 BenGoldberg joined #perl6
23:49 bjz joined #perl6
23:49 ccakes joined #perl6

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

Perl 6 | Reference Documentation | Rakudo