Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2017-12-27

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:01 cdg joined #perl6
00:02 wander joined #perl6
00:07 ggoebel joined #perl6
00:07 devmikey joined #perl6
00:10 cog_ joined #perl6
00:13 lookatme o/
00:16 g41j1n joined #perl6
00:25 wander \o
00:35 nebuchadnezzar joined #perl6
00:35 Guest11217 joined #perl6
00:58 yht joined #perl6
00:59 wander if I define "grammar G { token tok { ... } }", how can I refer tok outside G?
00:59 teatime G::tok ?
01:00 timotimo m: grammar G { token tok { . { say "hi!" } } }; grammar A { . <G::tok> { say "bye!"} } }; A.parse("fo")
01:00 camelia rakudo-moar 89d85baa4: OUTPUT: «5===SORRY!5=== Error while compiling <tmp>␤Unsupported use of . to concatenate strings; in Perl 6 please use ~␤at <tmp>:1␤------> 3tok { . { say "hi!" } } }; grammar A { .7⏏5 <G::tok> { say "bye!"} } }; A.parse("fo␤»
01:01 timotimo m: grammar G { token tok { . { say "hi!" } } }; grammar A { token TOP { . <G::tok> { say "bye!"} } } }; A.parse("fo")
01:01 camelia rakudo-moar 89d85baa4: OUTPUT: «5===SORRY!5=== Error while compiling <tmp>␤Unexpected closing bracket␤at <tmp>:1␤------> 3oken TOP { . <G::tok> { say "bye!"} } } 7⏏5}; A.parse("fo")␤»
01:01 timotimo m: grammar G { token tok { . { say "hi!" } } }; grammar A { token TOP { . <G::tok> { say "bye!"} } }; A.parse("fo")
01:01 camelia rakudo-moar 89d85baa4: OUTPUT: «hi!␤bye!␤»
01:01 timotimo wander: ^
01:02 wander It works. Thank you ^_^
01:02 cdg joined #perl6
01:03 timotimo YW
01:38 yht joined #perl6
02:10 mahafyi joined #perl6
02:15 dugword joined #perl6
02:54 eythian joined #perl6
02:55 ilbot3 joined #perl6
02:55 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!
02:56 cdg joined #perl6
03:17 unicodable6 joined #perl6
03:17 squashable6 joined #perl6
03:17 benchable6 joined #perl6
03:17 reportable6 joined #perl6
03:21 konsolebox joined #perl6
03:30 xcm joined #perl6
03:47 vichib joined #perl6
04:01 dugword joined #perl6
04:15 dugword joined #perl6
04:30 piojo I'm getting this error again: "MoarVM panic: Memory allocation failed; could not allocate zu bytes"
04:31 piojo I'm running Rakudo version 2017.12 built on MoarVM version 2017.12, and invoking as "perl6 --profile ./program.p6"
04:31 piojo *on Windows, and with plenty of memory
04:33 piojo The memory allocation is probably tricky, but the "zu bytes" is LTA
04:43 khisanth_ joined #perl6
04:46 konsolebox joined #perl6
04:46 dugword joined #perl6
04:48 geekosaur looks to me like someone dropped a %
04:49 geekosaur (%zu = (size_t) value as integer)
04:49 geekosaur oh, windows. uh.
04:50 geekosaur %zu is also glibc specific...
04:53 geekosaur hm, guess freebsd picked it up too. or maybe the standards orgs finally got a clue about not handling size_t at all
04:54 geekosaur but it's not portable to Windows
04:59 Cabanossi joined #perl6
05:04 geekosaur ugh. I think this is not only known but was rejected in the past, because it's an impossible situation
05:04 geekosaur in the absence of a supported %z modifier or some other way to specify that the corresponding value is a (size_t) or (ssize_t), there is *no* portable way to printf such values.
05:06 geekosaur of course. they'll be back with the same complaint, I'm sure.
05:07 geekosaur "and solve the halting problem while you're at it"
05:07 piojo joined #perl6
05:13 piojo geekosaur: oh, thanks, that's unfortunate. Can we use a 64-bit format type and still have it work on 32-bit systems?
05:13 geekosaur no, and under certain conditions that can even cause a core dump
05:14 geekosaur which is part of the reason why there's no portable way to do it
05:14 geekosaur this was actually a widespread criticism of C99 and later standards, that they provided no standard way to handle this case
05:16 geekosaur (unfortunately, real world standards tend to go with what vendors are willing to do... so just writing such into a standard does not mean e.g. Microsoft will adopt it. the ANSI C standard already has too many examples of that one as it is)
05:18 geekosaur (...but the other ones are at least compile time errors)
05:35 zakame joined #perl6
05:38 piojo geekosaur: and there are two popular compilation toolchains for Windows
05:39 piojo I'll file a MoarVM bug about this
05:39 geekosaur yes. I'd imagine this is MSC getting it wrong; msys2 would be using a modified glibc
05:39 geekosaur MSVC
05:40 geekosaur thing is, I seem to recall last time I ran into this was moarvm too, so I half expect any bug will be closed as WONTFIX / "get Microsoft to fix their damn toolchain"
05:40 piojo I compiled with GCC and strawberry perl
05:40 geekosaur don't know what that provides for a libc
05:41 geekosaur gcc itself is not involved, it's a question of what printf library is used. and there are gcc ports that use msvcrt for libc
05:52 piojo geekosaur: A test program works, so it looks like a flub rather than an incompatibility
06:05 piojo I don't see anything wrong with the MoarVM code, and can't reproduce it even when I almost exactly copy the function. (I tried using varargs and vfprintf but that doesn't show any problem)
06:07 xcm joined #perl6
06:24 piojo Oh! I was testing in c++, not c. Oops
06:52 aindilis joined #perl6
06:53 yht joined #perl6
06:53 someuser joined #perl6
06:57 piojo geekosaur: it's already special-cased for MS, but only for Visual Studio. I added another #elif case, and it's fixed. PR made.
06:57 darutoko joined #perl6
07:07 psychoslave joined #perl6
07:52 xcm joined #perl6
08:03 wamba joined #perl6
08:17 geospeck joined #perl6
08:18 geospeck joined #perl6
08:20 setty1 joined #perl6
08:21 geospeck joined #perl6
08:22 traxex joined #perl6
08:34 psychoslave joined #perl6
08:35 rindolf joined #perl6
08:36 xcm joined #perl6
08:41 astj joined #perl6
08:52 astj joined #perl6
09:14 scimon joined #perl6
09:26 traxex joined #perl6
09:29 xcm joined #perl6
09:35 lizmat_ joined #perl6
09:46 markong joined #perl6
09:54 devmikey joined #perl6
09:57 s0me0ne-unkn0wn joined #perl6
10:08 geospeck joined #perl6
10:19 pmurias joined #perl6
10:36 lizmat Zoffix: confusion around Mu ~~ * resolved
10:36 yoleaux 01:54Z <Zoffix> lizmat: why is the test wrong? (*) is Whatever:D and accepts everything, so it's True, while Whatever is Whatever:U and it's a type-check smartmatch, so it's False. Note, that along with the test there was a rakudo commit; you'll need it for test to pass
10:37 lizmat I was just in the middle of quite an extensive patch, when that test started to fail and it sent me on a goose chase for a bit
10:44 araraloren joined #perl6
10:46 rurban joined #perl6
10:47 pmurias joined #perl6
10:48 rurban left #perl6
10:55 mahafyi joined #perl6
10:56 rgrau joined #perl6
11:01 geospeck joined #perl6
11:02 synopsebot joined #perl6
11:12 rightfold https://en.wikipedia.org/wiki/Industrial-grade_prime
11:12 rightfold is-prime ^ :’)
11:13 rightfold Also reminds me of http://i0.kym-cdn.com/photos/images/facebook/001/288/951/12e.png
11:13 konsolebox joined #perl6
11:15 tadzik eyy, that's an Engie!
11:16 rightfold Not even bothering to round e up
11:16 rightfold Just truncate it
11:18 huf e, pi and 10/3 are all = 3? :)
11:40 geospeck joined #perl6
11:46 eliasr joined #perl6
12:10 cog__ joined #perl6
12:44 greppable6 joined #perl6
13:05 AlexDani` joined #perl6
13:08 astj joined #perl6
13:19 stmuk_ joined #perl6
13:43 AlexDaniel joined #perl6
13:51 cognominal joined #perl6
13:57 scimon Very interested in ValueObjAt sounds like it could be interesting.
14:18 xinming_ joined #perl6
14:19 Bucciarati joined #perl6
14:23 lizmat scimon: its implementation was very difficult:  class ValueObjAt is ObjAt { }  :-)
14:24 timotimo the smiley at the end is what adds all the necessary magic
14:24 yoleaux 10:10Z <Zoffix> timotimo: Can this branch be merged/deleted? https://github.com/rakudo/rakudo/tree/microoptimize_dont_divide_numbers  I may have did something to DIVIDE_NUMBERS a month ago that'd cause a conflict tho
14:24 rurban1 joined #perl6
14:24 rurban1 left #perl6
14:26 scimon :D
14:27 rurban2 joined #perl6
14:27 rurban2 left #perl6
14:27 rurban3 joined #perl6
14:28 rurban joined #perl6
14:28 rurban left #perl6
14:28 rurban4 joined #perl6
14:29 rurban5 joined #perl6
14:29 rurban5 left #perl6
14:29 rurban6 joined #perl6
14:34 lizmat wow, that's a lot or rurban!
14:35 timotimo ?
14:36 lizmat timotimo: check entrance and leave message just now  :-)
14:36 lizmat *messages
14:36 timotimo oh, now i see
14:36 timotimo i had the smart filter on
14:37 lizmat :-)
15:04 MasterDuke joined #perl6
15:06 bwisti joined #perl6
15:43 dmaestro joined #perl6
15:52 silug joined #perl6
16:00 lasse_ joined #perl6
16:01 cdg joined #perl6
16:05 coverable6 joined #perl6
16:05 nativecallable6 joined #perl6
16:05 quotable6 joined #perl6
16:05 releasable6 joined #perl6
16:05 statisfiable6 joined #perl6
16:05 committable6 joined #perl6
16:14 vichib joined #perl6
16:27 troys joined #perl6
16:53 cdg joined #perl6
16:57 khw joined #perl6
17:24 * moritz opened https://github.com/stmuk/pl6anet.org/pull/8
17:44 aindilis joined #perl6
17:45 dct joined #perl6
17:48 rgrau joined #perl6
17:59 stmuk_ moritz++ # thanks
18:09 domidumont joined #perl6
18:10 cdg joined #perl6
18:12 cdg_ joined #perl6
18:17 domidumont joined #perl6
18:30 wamba joined #perl6
18:48 cdg joined #perl6
18:49 geospeck joined #perl6
18:57 mspo moarvm is a stack machine, right?
19:06 MasterDuke mspo: no, register
19:12 cdg joined #perl6
19:16 imcsk8 joined #perl6
19:30 Spot__ joined #perl6
19:35 tbrowder joined #perl6
19:37 jnap_ joined #perl6
19:38 zostay joined #perl6
19:38 bisectable6 joined #perl6
19:38 bloatable6 joined #perl6
19:38 squashable6 joined #perl6
19:38 coverable6 joined #perl6
19:38 greppable6 joined #perl6
19:38 skaji joined #perl6
19:38 mithaldu_ joined #perl6
19:39 reportable6 joined #perl6
19:39 olinkl joined #perl6
19:41 mrsolo joined #perl6
19:41 parisba joined #perl6
19:41 lumimies joined #perl6
19:43 notbenh_ joined #perl6
19:43 jkva_ joined #perl6
19:43 PotatoGim joined #perl6
19:43 peteretep joined #perl6
19:43 eliasr joined #perl6
19:44 iviv joined #perl6
19:44 alexghacker left #perl6
19:44 alexghacker joined #perl6
19:44 SmokeMachine joined #perl6
19:44 timeless joined #perl6
19:46 BuildTheRobots joined #perl6
19:48 jhill_ joined #perl6
19:48 rightfold joined #perl6
19:51 clkao joined #perl6
19:54 kipd joined #perl6
19:55 scott joined #perl6
19:57 Aceeri joined #perl6
20:03 avar joined #perl6
20:03 avar joined #perl6
20:03 literal joined #perl6
20:11 andrzejku joined #perl6
20:15 andrzejku hey
20:15 andrzejku where can I find
20:15 andrzejku Perl6 grammar
20:16 MasterDuke andrzejku: https://github.com/rakudo/rakudo/blob/master/src/Perl6/Grammar.nqp
20:19 pilne joined #perl6
20:29 ChoHag joined #perl6
20:33 s0me0ne-unkn0wn joined #perl6
20:42 geospeck joined #perl6
20:51 aeruder m: say ((1..4).race.map({sleep 1; 1;}).list); say now - INIT now;
20:51 camelia rakudo-moar c10b8fe95: OUTPUT: «(1 1 1 1)␤4.01273257␤»
20:51 aeruder is there some reason why that isn't parallelized?
20:53 lizmat aeruder: the default value for :batch is 64
20:53 aeruder d'oh, that makes sense
20:53 lizmat m: say ((1..4).race(batch => 1).map({sleep 1; 1;}).list); say now - INIT now;
20:53 camelia rakudo-moar c10b8fe95: OUTPUT: «(1 1 1 1)␤1.0527615␤»
20:53 aeruder perfect, thanks
20:55 timotimo https://twitter.com/sarah_edo/status/946091648773013504 - anyone want to steal this?
20:55 espadrine joined #perl6
20:58 evalable6 joined #perl6
20:58 lizmat looks interesting  :-)
21:05 rgrau joined #perl6
21:09 cdg joined #perl6
21:20 chansen_ joined #perl6
21:21 pnu__ joined #perl6
21:33 rodarmor joined #perl6
21:33 ggherdov joined #perl6
21:46 moritz fwiw, in the last years, the Perl 6 advent calendar had a separate post with a table of contents/index of the posts of that year
21:47 moritz if somebody has some time to spare, creating such a post would be nice
21:47 vichib joined #perl6
22:04 lizmat it would be just a matter of copy-pasting parts of the last 4 p6weeklies
22:08 cdg joined #perl6
22:19 dct joined #perl6
22:33 mspo MasterDuke: interesting
22:41 Herby_ joined #perl6
22:41 Herby_ o/
22:41 Herby_ \o
22:46 jeff_ joined #perl6
22:53 ChoHag joined #perl6
23:02 timotimo o/
23:12 Herby_ Rookie question: Has the LWP::Simple library that ships with Rakudo Star not been updated in 2 years?
23:13 Herby_ Have there been improvements in p6 during that time that could improve a base library?
23:13 ChoHag joined #perl6
23:14 lizmat According to Matt Oates it has: https://perl6advent.wordpress.com/2017/12/16/
23:14 Herby_ Thats what I was thinking
23:14 cdg joined #perl6
23:15 Herby_ Not that I have a strong enough base of knowledge to improve it, just seemed odd that a base library for a rapidly improving language hasn't been updated in a while
23:16 timotimo we do have multiple http clients
23:16 timotimo there's also WWW and Cro::HTTP
23:16 Herby_ yeah, was about to mention that
23:16 timotimo and more!
23:16 timotimo one based on libcurl, too
23:16 Herby_ do one of those server the rakudo star package better?
23:17 timotimo dunno. we'd better only add to it and not subtract too fast
23:17 timotimo bbiab
23:17 Herby_ o/
23:32 vichib joined #perl6
23:39 lizmat sleep&
23:46 AlexDaniel squashable6: next
23:46 squashable6 AlexDaniel, Next SQUASHathon in 8 days and ≈10 hours (2018-01-06 UTC-12⌁UTC+14). See https://github.com/rakudo/rakudo/wiki/Monthly-Bug-Squash-Day
23:46 Perl6 joined #perl6
23:46 Perl6 How do I turn a string of numbers separated by commas into an array of those numbers?
23:46 yoleaux 25 Oct 2014 23:59Z <raiph> Perl6: to encourage someone to post a P6 version of the tiny reverse polish forthish "compiler" at http://www.reddit.com/r/perl/comments/2kb0c7/a_compiler_written_in_perl/ (I plan to have a go early next week if no one else gets to it and it's still in the top 10 on /r/perl)
23:46 yoleaux 12 Jan 2015 11:37Z <timotimo> Perl6: .new() isn't like __init__ or __new__, it's like python's .frob or .blubber or .yoink; also, new calls bless calls BUILDALL calls BUILD unlike what geekosaur said, and skids wrongly wrote bless(*, ...), but the * as first argument is wrong nowadays
23:47 geekosaur o.O
23:47 jnthn m: dd "1,2,5,42".split(",").map(+*)
23:47 camelia rakudo-moar c10b8fe95: OUTPUT: «(1, 2, 5, 42).Seq␤»
23:47 jnthn m: dd ["1,2,5,42".split(",").map(+*)]
23:47 camelia rakudo-moar c10b8fe95: OUTPUT: «[1, 2, 5, 42]␤»
23:48 Perl6 jnthn: Thanks! What does .map(+*) do by the way?
23:49 jnthn +* is a shorter way to write the closure { +$_ }
23:49 geekosaur the leading + coerces to a number
23:50 jnthn The + prefix operator means "numify"
23:50 geekosaur split gives you a Seq of Str-s, you then map numification over the Seq
23:50 jnthn And map is just "do this operation for each value and make a new sequence of the results"

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

Perl 6 | Reference Documentation | Rakudo