»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, or /msg camelia p6: ... | irclog: irc.perl6.org or colabti.org/irclogger/irclogger_logs/perl6 | UTF-8 is our friend!
Set by moritz on 22 December 2015.
00:04 ggoebel left 00:19 ggoebel joined 00:28 pierre_ joined 00:34 llfourn_ joined 00:37 llfourn left 00:54 pierre_ left 01:02 pierre_ joined 01:03 pierre_ left, pierre_ joined 01:07 _28_ria left 01:11 _28_ria joined 01:14 cpage_ joined 01:24 pierre_ left 01:27 pierre_ joined 01:37 _28_ria left 01:42 rodarmor left 01:43 rodarmor joined 01:52 aborazmeh joined, aborazmeh left, aborazmeh joined 01:55 rurban1 joined 01:58 rurban left 02:00 AlexDaniel left 02:01 AlexDaniel joined 02:17 leont left 02:45 ilbot3 left 02:47 ilbot3 joined 02:52 rurban1 left, notostraca joined 02:53 Lucas_One left 02:55 Lucas_One joined 03:02 noganex joined 03:03 pierre_ left 03:05 noganex_ left 03:06 AlexDaniel left 03:11 pierre_ joined 03:15 pierre_ left 03:16 pierre_ joined 03:17 Actualeyes left 03:18 Actualeyes joined 03:21 avuserow joined 03:25 notostraca is now known as TEttinger 03:45 skids left 03:50 khw left 03:59 noganex_ joined 04:02 noganex left 04:20 rindolf joined 04:22 BenGoldberg left 04:40 wamba joined 04:49 xinming left 04:51 xinming joined 04:54 perturbation left 04:56 canopus left 05:02 canopus joined 05:05 pierre_ left 05:07 snowman left 05:12 pierre_ joined 05:17 pierre_ left 05:25 brillenfux joined 05:35 aborazmeh left 05:37 Cabanossi left 05:40 Cabanossi joined 05:44 wamba left 06:14 brillenfux left 06:17 bjz joined 06:24 pierre_ joined 06:30 darutoko joined 06:33 bjz left 06:42 pierre_ left 06:46 bjz joined 06:49 pierre_ joined, RabidGravy joined 06:51 geekosaur left 06:52 geekosaur joined, sjoshi joined, paulmr joined 06:53 cognominal left 07:01 labster left
samcv hmm i'm getting a sequence back from comb, but i need to test for if there's anything in the sequence. defined shows that it is defined even if printing it out just gives me “()” 07:01
i guess i can use elems, but is there some other way to do it? 07:02
07:05 brillenfux joined 07:09 labster joined
[ptc] samcv: () should be False, so a boolean expression should be ok 07:10
m: if () { say 24 } else { say 42 }
camelia rakudo-moar 4fdf6d: OUTPUT«42␤»
samcv does this not coerce as boolean? say $var if $var; 07:11
that doesn't work at least
07:11 Tonik joined
seatek m: my @s = (); say "it's got something in it" if @s; 07:11
camelia ( no output )
samcv that works most of the time but
for some reason it will print out ones with 1 elements 07:12
seatek m: my @s = ['goofy']; say "it's got something in it" if @s;
camelia rakudo-moar 4fdf6d: OUTPUT«it's got something in it␤»
samcv unless i do my $v = $fh.comb(/regex/); print $v if $v.elems;
that's an array though not a Seq 07:13
07:13 neuraload joined
samcv sometimse Seq will evaluate as true, even with 0 elements 07:14
seatek m: my @s = ('goofy'); say "it's got something in it" if @s;
camelia rakudo-moar 4fdf6d: OUTPUT«it's got something in it␤»
seatek even if you use .elems or does elems always work?
m: my @s = (); say "it's got something in it" if @s; 07:15
camelia ( no output )
samcv no elems always works
07:15 sjoshi left
seatek must be sunspots 07:16
samcv possibly
seatek ;)
samcv or could be related to file encodings?
07:16 CIAvash joined
samcv or sunspots 07:16
07:16 CIAvash left
samcv it's not always reproducing... so 07:17
weird
seatek maybe something lingers in an element between tests?
samcv maybe
seatek are you clearing it out well?
samcv how should i be clearing it out? 07:18
seatek @s = () should work;
samcv well i'm doing it using await do 07:19
so i think it should be lexically scoped
seatek threaded stuff? you may be getting results from another thread then? 07:20
samcv vpaste.net/ZI542
this is what i'm doing
some reason it's printing out matches that like. have spaces in them 07:21
cry.nu/p/7qi9
this is what it prints out
even doing just $fh.comb( /<[ \x[00] .. \x[09] ]>/ ); 07:22
so it does only one range gets me this: cry.nu/p/ee7s/
07:23 Tonik left
samcv it shouldn't be finding anything since they're all unprintable characters 07:23
if i print without checking elems or what bool coerces to i get like thousands of () in addition to those. so idk what's going on 07:24
07:24 bjz_ joined
samcv maybe i don't understand comb? 07:24
07:25 bjz left
samcv if i do: my $string = $fh.comb( /<[abc]>/ ); i get cry.nu/p/il92 07:27
so that is only printing out places where the actual letters are occuring
07:29 RabidGravy left, firstdayonthejob joined
seatek well comb should only be returning what you tell it to return... if you're telling it to return non-printables... i don't know what it might look like when you try to print them 07:30
samcv well i'm 99% sure those don't exist in the files
also it doesn't actually print any unprintables
it just prints spaces 07:31
i've checked a hexviewer
07:31 CIAvash joined, CIAvash left
samcv yes i just double checked it. none of the files have any of those special characters 07:34
i checked all 'control characters' except for tab newline and carriage return
chr 0 - chr 27 and also chr 127; none of them have it 07:35
07:35 firstdayonthejob left
samcv ^those above except for \n \r and \t i mean 07:35
maybe there's something other than comb i can use to check the full file for those control characters other than comb? 07:36
i mean i could do it by line. but i was hoping for something more elegant
seatek well i'm not sure what the control structure around it is... but one weird thing, I just looked, and it says it's lazy, so if you iterate through it once, that's all you got unless you cache it i think 07:38
not sure it that could be related to what you're seeing. sorry, i'm insane myself right now with grammars, trying to get used to them 07:39
07:40 abraxxa joined
samcv hah k 07:40
seatek you can always read it into a proper array instead 07:41
of the scalar
samcv the whole file?
i could
seatek the comb
samcv oh
seatek @strings = $fh.comb... blah blah 07:42
samcv won't it stay lazy? or is a way to like
unlazy it. or will an array auto do that
07:42 abraxxa left
samcv also idk why calling is-lazy on it says it's not lazy 07:43
m: "abcd".comb(/z/).is-lazy.say
camelia rakudo-moar 4fdf6d: OUTPUT«False␤»
seatek honestly i don't know that. i have a feeling that reading it into an array would pull them all in 07:44
samcv says same thing when i do it on $fh.comb ...
seatek they would stick around between multiple iterations that way though if that's what your problem is 07:45
otherwise i think you have to do something with cacheing,
which i know nothing about yet 07:46
samcv maybe i will try it a few ways and see which is fastest 07:50
07:51 abraxxa joined 07:53 paulmr2 joined 07:54 pdcawley joined 07:55 paulmr left
nine samcv: if you only want to check if certain characters are there, why not just match it against a regex? 08:01
samcv isn't that what comb does?
it accepts a regex
but yes i can do that too
08:10 zakharyas joined 08:19 paulmr joined, seatek left 08:21 paulmr2 left 08:24 domidumont joined 08:25 wamba joined 08:26 vendethiel joined 08:28 domidumont left 08:29 rurban joined, domidumont joined, wamba left, pierre_ left 08:32 pierre_ joined 08:33 TEttinger left 08:34 domidumont left, domidumont joined 08:35 frank____ joined, frank____ left 08:39 pdcawley left 08:43 wamba joined 08:45 g4 joined, g4 left, g4 joined 08:55 pdcawley joined 08:59 wamba left 09:01 jonas1 joined 09:08 paulmr left 09:09 telex left 09:10 telex joined 09:11 domidumont left 09:14 dakkar joined
nine samcv: comb splits a string into individual characters (like running a comb through hair). Maybe the docs emphasize the usage with a pattern bit too much. 09:15
09:16 FROGGS joined
masak comb only splits into individual characters by default 09:16
but the analogy still holds up when you pass it a regex
that is, you "comb out" the interesting bits from the (hairy) string 09:17
FROGGS o/
09:17 pdcawley left 09:18 leont joined
samcv ah ok masak 09:22
someday maybe this will run as fast in perl 6 as in perl ;3 takes 0.7 secs in perl 5 and 10 seconds in perl 6. but 09:23
fastest was slurping the files and then using regex to check if it had those characters in it. but for some reason that's not any faster without doing await/do/start 09:24
though doing comb it goes from 20 secs to 12 secs doing it with/without await/do/start
it does spawn more processes though. so that is happening 09:25
well.. it is 1 second faster but a 10% speed improvement from using 8 more threads isn't anything. plus it uses more cpu for doing the same work 09:28
09:41 nadim joined 09:44 kjs_ joined, Roamer` joined
Roamer` hi, are there any known issues with using non-greedy * matches within a grammar? 09:45
in particularly, it always failing? :)
something like (sorry, somewhat long...) 09:47
m: grammar g { regex TOP {<b>*}; regex b {'H'<c>*}; regex c {<[A..Za..z]>}; }; class ac { method TOP($/) { make $<b>».made }; method b($/) { make $<c>».Str.join(", ") }; }; my $m = g.new.parse("HabcHdef", :actions(ac.new)); $m?? ("parsed:\n" ~ $m.made.perl).say!! "failed".say
camelia rakudo-moar 4fdf6d: OUTPUT«parsed:␤["a, b, c, H, d, e, f"]␤»
Roamer` m: grammar g { regex TOP {<b>*}; regex b {'H'<c>*?}; regex c {<[A..Za..z]>}; }; class ac { method TOP($/) { make $<b>».made }; method b($/) { make $<c>».Str.join(", ") }; }; my $m = g.new.parse("HabcHdef", :actions(ac.new)); $m?? ("parsed:\n" ~ $m.made.perl).say!! "failed".say
camelia rakudo-moar 4fdf6d: OUTPUT«failed␤»
Roamer` the only difference between the two is that regex b has *? instead of *
and, yes, I explicitly want to have <c> match something that should also be matched by the start of the next block; what I'm really parsing is weird that way :/ 09:48
okay, no, I don't want it to *match* it, I want it to *be able* to match it, but be stopped by the non-greedy match in <b> 09:49
09:56 araujo joined 09:59 kjs_ left 10:03 labster left 10:07 dwarring left 10:10 Rawriful joined 10:18 kjs_ joined
Roamer` I actually managed to do what I wanted with a [ <!before <blah> '' ] thing, but still is there a reason why *? doesn't work in grammars? :) 10:22
10:23 kjs_ left
moritz I guess some backtracking wonkiness 10:24
it should work, afaict
masak surely that example can be golf'd a little 10:37
jnthn What if you add an explicit $ at the end of TOP, ooc? 10:39
I *think* that .parse checks that your grammar really did eat the whole input
masak it does
jnthn But that's an after-the-fact check 10:41
It doesn't affect the matching behavior
It's on you to make sure your grammar reaches the string end
masak m: grammar G { regex TOP { x } }; say G.parse("xy") 10:42
camelia rakudo-moar feb7bc: OUTPUT«Nil␤»
jnthn m: grammar g { regex TOP {<b>*$}; regex b {'H'<c>*?}; regex c {<[A..Za..z]>}; }; class ac { method TOP($/) { make $<b>».made }; method b($/) { make $<c>».Str.join(", ") }; }; my $m = g.new.parse("HabcHdef", :actions(ac.new)); $m?? ("parsed:\n" ~ $m.made.perl).say!! "failed".say
camelia rakudo-moar feb7bc: OUTPUT«parsed:␤["a, b, c", "d, e, f"]␤»
jnthn Seems the $ does it
masak ok, so #notabug 10:43
jnthn Don't think so, no
masak glad to hear quantifier backtracking ain't busted :P
well, not by this, at least :P
jnthn Me too, 'cus I've already got enough to fix :P
masak .oO( quick, everyone stop finding more bugs! ) 10:44
jnthn :P 10:45
masak it's a well known fact that using software makes the software more buggy 10:46
I guess that... makes me Perl 6's public enemy #1 o.O
jnthn It doesn't make it more buggy, it just makes one aware how buggy it is :P 10:47
masak no, literally more buggy 10:48
it's like bitrot and blue smoke
jnthn ;)
masak the act of using the software also destroys it
often on a design level
this is why we have to keep writing new software all the time, because of its poor shelf-life
it also explains Schrödinbugs (that manifest in software only after someone notices that it never should have worked) 10:52
because it's the *attention* paid to the software that's the destructive influence
bonsaikitten I'd say the problem is the lack of upfront engineering 11:05
so we fix things by adding yet another layer of duct tape
but at some point the pipe will still leak, and rebuilding the pipe properly is too expensive 11:06
... and apparently adding another layer of tape isn't?
11:15 kurahaupo__ joined, kurahaupo__ left, kurahaupo__ joined 11:18 FROGGS[mobile] joined 11:19 kurahaupo__ left 11:30 pierre_ left 11:33 CIAvash joined 11:34 abraxxa left 11:44 leont left 11:59 paulmr joined 12:01 pierre_ joined 12:02 pierre_ left 12:03 pierre_ joined, abraxxa joined
dalek line-Perl5: 8e1b812 | niner++ | p5helper.c:
Remove obsolete arguments of p5_rebless_object

These arguments haven't been needed since "Simplify callback handling" and were no longer passed by Perl 6 code.
12:11
12:15 pierre_ left 12:16 nadim left 12:17 FROGGS[mobile]2 joined 12:18 FROGGS[mobile] left 12:21 wamba joined
dalek line-Perl5: f237dfc | niner++ | p5helper.c:
Factor out common code of callback XS functions
12:22
line-Perl5: 69f8827 | niner++ | p5helper.c:
Factor out common code of p5 call functions.
viki The Mac link on rakudo.org/how-to-get-rakudo/ is a 404 again 12:24
moritz :( 12:26
dalek line-Perl5: c14d79e | niner++ | lib/Inline/Perl5.pm6:
Remove unneeded variables.
12:27
viki And wiki still lists 2016.07 as latest. en.wikipedia.org/wiki/Perl_6 12:28
Stable Perl 6 is 9 months old. Time to call a midwife.
masak updating Wikipedia used to be part of the release guide 12:30
dunno if it still is nowadays 12:31
viki It still is, so I don't know if it was just missed or done on purpose.
masak hard to imagine the latter 12:32
maybe it's something to do with the new automated-release system?
just a guess -- I haven't been paying enough attention to know
viki Nope. Star doesn't have automated release systems.
12:34 wamba left
[Coke] this came up a few days ago: the open a ticket via the web link on RT was disabled due to a spam storm in the p5 queue. Needs to be spam proofed before it is re-enabled. 12:37
volunteers welcome on the spam proofing. 12:39
viki OK. Where's the code?
[Coke] no clue. I opened a ticket, that was the response I got from Robert Spier 12:41
12:45 pierre_ joined, pmurias joined
nine I now have a find_shadow_magic function in Inline::Perl5's C code and the name is actually proper and very descriptive. Sometimes I just love this :) 12:46
[Coke] (I am happy to put people in touch with Robert if they want to volunteer) 12:47
viki It's hard to volunteer without knowing any of the details. What's "spam proofing" to Robert? Sticking a reCAPTCHA on the new ticket form would be my idea. But is that suitable (or even possible), considering that introduces custom modifications to RT? 12:48
masak I've always been happy submitting via email. maybe I'm in a minority, but I wouldn't start using a button in the web interface just because one became available 12:56
12:57 AlexDaniel joined
[Coke] viki: you'd have to have a conversation with him. 12:59
viki masak: IME, email doesn't always work (I know at least one ticket of mine didn't go through). I also have to re-login from my regular account to my RT account each time I want to send an email :/ 13:02
masak I switch Gmail accounts all day. doesn't bother me much ;) YMMV 13:04
I don't recall RT tickets ever not registering when sending by email -- though I believe you when you say it happened to you
anyway, main point is it works fine for me, which is why I don't feel a big need for the button 13:05
viki I don't use gmail, but my own thing.... maybe that's why it didn't go through (got lost in spam)
masak I won't complain if someone goes through the motions of making the button work :) just won't use it
[Coke] initializator ?
dalek c: 41bb002 | coke++ | xt/aspell.t:
don't hardcode 'perl6'
13:07
c: 7cbfa39 | coke++ | doc/Language/variables.pod6:
fix typo
c: 873aa61 | coke++ | xt/code.pws:
new code word
13:14 wamba joined 13:15 wamba left 13:16 wamba joined 13:18 wamba left 13:29 skids joined, eliasr joined 13:33 nicq201 joined
nicq201 Hello! o/ 13:33
viki |o 13:34
masak m: say "hi, nicq201!"
camelia rakudo-moar fb0c64: OUTPUT«hi, nicq201!␤»
13:37 stux|RC-only left 13:40 cdg joined, stux|RC-only joined
dalek line-Perl5: 8a75fe7 | niner++ | / (2 files):
Lazily create Perl6 shadow object instead of overriding CORE::GLOBAL::bless

Even overriding CORE::GLOBAL::bless is not global enough, as it won't catch objects created by XS code. Also, slowing down all constructors by just loading Inline::Perl5 won't do wonders for our marketing.
Instead, create the Perl 6 shadow object lazily when one of the extension methods is accessed for the first time. The check if we need to do this should be dirt cheap and will probably not even be measurable.
13:41
nine mst: done ^^^ :)
13:45 CIAvash left 13:55 snowman joined 13:59 nicq20 joined 14:03 pierre_ left 14:05 wamba joined 14:10 wamba left
dalek modules.perl6.org: 01324eb | (Zak B. Elep)++ | assets/js/dataTables.filter.perlModule.js: 14:14
modules.perl6.org: Add filter plugin for dataTables
modules.perl6.org:
modules.perl6.org: This is a simple client-side plugin for handling Perl module names in
modules.perl6.org: DataTables.
14:14 dalek left 14:15 dalek joined, ChanServ sets mode: +v dalek 14:20 Actualeyes left, Actualeyes joined 14:26 khw joined 14:32 kjs_ joined 14:46 rurban left 14:51 paulmr left
viki Happy Christmas! 14:53
m: say 0o31 14:54
camelia rakudo-moar cb8f78: OUTPUT«25␤»
masak m: say :10<25> == :8<31>
camelia rakudo-moar cb8f78: OUTPUT«True␤»
masak m: say 25.base(8) eq "31"
camelia rakudo-moar cb8f78: OUTPUT«True␤»
15:01 kjs_ left 15:06 araujo left 15:09 araujo joined 15:14 kjs_ joined 15:25 g4 left 15:26 CIAvash joined
viki Buncha lang rankings: techbeacon.com/programming-language...nes-matter 15:26
viki is amused by Ruby ranking below Perl and Delphi in TIOBE
Didn't realize anyone even used Delphi these days.
15:27 domidumont joined 15:29 domidumont1 joined
moritz the TIOBE ranking is horseshit 15:31
15:31 bjz_ left
viki agreed 15:31
moritz (and I say that whether they say good or bad things about perl)
if metacpan.org puts a "perl programming" in the footer of each page it renders, perl would be like, 5 places higher than before 15:32
15:32 domidumont left, nadim joined 15:33 domidumont1 left 15:34 nicq20 left
lizmat so why doesn't metacpan.org do that ? 15:37
15:39 CIAvash left
moritz dunno, I never asked them 15:39
viki Well, it's not *that* easy. You need to game google, which will indirectly will game TIOBE 15:40
Well, and other search engines.
15:41 nicq20 joined
moritz but doesn't tiobe just look at the number of pages with some specific terms on them? 15:41
and google just counts, it doesn't feel gamed, does it? 15:42
viki From TIOBE Wikipedia page: "TIOBE index is sensitive to the ranking policy of the search engines on which it is based. For instance, in April 2004 Google performed a cleanup action to get rid of unfair attempts to promote the search rank. As a consequence, there was a large drop for languages such as Java and C++, yet these languages have stayed at the top of the table"
nicq20 I am surprised that Java is so high in the list for all of them. 15:44
lizmat I guess to an extent the metric is really how much a language has DWIM 15:45
15:45 jonas1 left
viki And how good its info resources are. 15:45
oh wait, that would still show up in google. Never mind :) 15:46
Heh. Looks like moritz isn't the only one with the idea: blog.timbunce.org/2009/05/17/tiobe...ing-gamed/ 15:47
And yeah, Delphi did show up unusually high, but that just made me question validity of TIOBE, not go "wow, I better pick up Delphi again" 15:48
So all these rankings aren't as useful as people seem to think IMO
15:48 nicq20 left 15:50 nicq20 joined
nicq20 Looking at that list, PHP is one of those funny languages where it is difficult to use (the syntax changes with every version) but it is very useful for web. 15:58
Funny it's ranked so high.
lizmat the only time I've used PHP in production (and that was 20+ years ago), was before mod_perl existed 15:59
and the PHP was generated by a Perl script every minute
15:59 kjs_ left
lizmat reduced the database load quite significantly :-) 16:00
dalek c: fea3925 | gfldex++ | doc/Type/Metamodel/ClassHOW.pod6:
doc Metamodel::ClassHOW.lookup
16:01
viki The only time I used it is on wargaming sites on challenges where you have to explot a PHP script :} 16:03
16:03 nicq20 left
moritz viki: I've probably read that blog post in the past, so it wasn't even an original thought 16:04
16:04 nicq20 joined 16:05 kjs_ joined
nicq20 Being able to put HTML right in PHP scripts is pretty useful though. 16:06
viki .... when writing unmaintainable tangled mess :)
16:07 wamba joined
nicq20 Lolz! Especially when trying to fix 10+ year old sites. 16:07
Huh. I wonder if there is some kind of way to get the same kind of functionality with Perl6. 16:10
timotimo sure. build a slang for it if you must. 16:12
viki nicq20: just use a HERE doc? 16:13
timotimo viki: they want a piece of text that automatically outputs itself to stdout when "encountered" 16:14
nicq20 I suppose that could work. But it would be difficult to do inline stuff.
timotimo: I thought slangs only replace the regular interpreter, instead of build off it. 16:15
timotimo in that case you were wrong :) 16:16
you can replace the language completely, but it's usually more useful to add some stuff in and keep the rest 16:17
viki m: gist.github.com/zoffixznet/9d166d9...775037937f 16:18
nicq20 timotimo: Huh, makes sense. Know of any examples?
camelia rakudo-moar 221633: OUTPUT«<!DOCTYPE html>␤<html lang="en">␤ <meta charset="utf-8">␤ <title>Today's Time and Date>␤␤ <h1>It's 2016-10-31T17:18:28.553122+01:00 right now!</h1>␤␤»
timotimo there are modules in the ecosystem that have "Slang" in their name
viki nicq20: modules.perl6.org/dist/Slang::Roman
16:19 snowman left, neuraload left
viki m: use LWP::Simple 16:22
camelia rakudo-moar 221633: OUTPUT«===SORRY!===␤Could not find LWP::Simple at line 1 in:␤ /home/camelia/.perl6␤ /home/camelia/rakudo-m-inst-2/share/perl6/site␤ /home/camelia/rakudo-m-inst-2/share/perl6/vendor␤ /home/camelia/rakudo-m-inst-2/share/perl6␤ CompUnit::R…»
nicq20 viki: Actually, the git snippet seems like it would work! I didn't realize that the { code } thing worked with those.
viki star: use LWP::Simple
camelia ( no output )
16:23 rurban joined
viki m: "{my $foo = 42} {$foo}" 16:23
camelia rakudo-moar 221633: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Variable '$foo' is not declared␤at <tmp>:1␤------> 3"{my $foo = 42} {7⏏5$foo}"␤»
viki nicq20: ^ that poses a big problem :(
.oO( thankfully, averting PHP6 from being birthed... )
16:24
Nothing some global variables won't fix ;)
nicq20 I have a feeling that is pretty close to how PHP started. 16:27
viki nicq20: it started from a Perl script, yeah
AlexDaniel m: say do { my $OUTER::foo = 42 }
camelia rakudo-moar 221633: OUTPUT«Cannot modify an immutable Nil␤ in block <unit> at <tmp> line 1␤␤»
AlexDaniel m: say do { my OUTER::‘$foo’ = 42 } 16:28
camelia rakudo-moar 221633: OUTPUT«===SORRY!===␤Could not locate compile-time value for symbol OUTER␤»
16:28 kjs_ left
AlexDaniel LTA, but whatever… 16:28
viki contemplates Acme::PHP6 16:29
Just for the luls
16:30 adeohluwa joined
nicq20 viki: yES 16:30
16:30 adeohluwa left 16:31 hankache joined
hankache hola #perl6 16:31
nicq20 Hey-o
viki \o 16:32
AlexDaniel 🙋
16:35 pmurias left, pmurias joined
pmurias blogs.perl.org/users/pawel_murias/2...pdate.html 16:37
nine pmurias++ # excellent progress! 16:39
timotimo always glad to see blog posts from that particular piece of rakudo :) 16:40
hankache pmurias++ 16:41
viki pmurias++
16:41 FROGGS left
nicq20 So how is the JS-Rakudo supposed to work? I haven't looked into it... 16:42
dalek c: 94b393a | (Zoffix Znet)++ | doc/Type/Grammar.pod6:
Document subparse always returns a Match
16:43
16:44 pmurias_ joined
viki Insert Perl 6 code. Receive Javascript. 16:44
??? 16:45
Profit!
pmurias_ yes
nicq201: in the simplest form: perl6-js --target=js -e '...' > output.js 16:46
nicq201: in the js world transpilers (source to source compilers) are common so you will also be able to hook rakudo.js in to your webpack etc. thing 16:49
16:50 pmurias left, pmurias_ is now known as pmurias 16:51 nicq201 left, Actualeyes left
nicq20 Huh. That's pretty cool! 16:51
16:52 domidumont joined 16:58 canopus left
viki m: gist.github.com/zoffixznet/eed942a...c5f6bb0995 17:01
camelia rakudo-moar 07eeea: OUTPUT«「 <!DOCTYPE html>␤ <html lang="en">␤ <meta charset="utf-8">␤ <title>Today's Time and Date</title>␤␤ <?💩␤ use LWP::Simple;␤ my $*foo = get 'perl.org';␤ 💩>␤␤ <h1>It's <?💩 $foo; …»
viki m: gist.github.com/zoffixznet/aec4dcd...54f09801c4
camelia rakudo-moar 07eeea: OUTPUT«「 <!DOCTYPE html>␤ <html lang="en">␤ <meta charset="utf-8">␤ <title>Today's Time and Date</title>␤␤ 」␤ html => 「 <!DOCTYPE html>␤ <html lang="en">␤ <meta charset="utf-8">␤ <title>Today's Ti…»
viki How come the first version parses "code" blocks correctly, but the second doesn't? In the second, I move the .+? from token code-block into a separate token code. Shouldn't it match the same? 17:02
17:06 canopus joined
nicq20 Tokens to count whitespace right? 17:06
*don't
viki Not sure what you mean.
rule {}s insert <ws> token for each interval of whitespace in them. 17:07
nicq20 Oops, got rule and token confused. 17:11
gtg, bye! 17:15
17:15 nicq20 left, zakharyas left
jferrero m: -2 ** 2 17:22
camelia rakudo-moar 07eeea: OUTPUT«WARNINGS for <tmp>:␤Useless use of "-" in expression "-2 **" in sink context (line 1)␤»
jferrero m: (-2) ** 2
camelia rakudo-moar 07eeea: OUTPUT«WARNINGS for <tmp>:␤Useless use of "**" in expression "(-2) ** 2" in sink context (line 1)␤»
hankache huh?
timotimo yeah, it's because -2 ** 2 is actually -(2 ** 2)
it always reports the outermost operator 17:23
jferrero m: ((-2) ** 2)
camelia rakudo-moar 07eeea: OUTPUT«WARNINGS for <tmp>:␤Useless use of "**" in expression "(-2) ** 2" in sink context (line 1)␤»
viki again.
timotimo what again?
viki jferrero: out of curiousity, how did you hear about it?
hankache m: say -2 ** 2
camelia rakudo-moar 07eeea: OUTPUT«-4␤»
jferrero sorry, viki. I saw at twitter 17:24
viki timotimo: like 4th person with the -1**1 thing in the past 6 days. I wonder how they hear about it.
jferrero: ah :)
hankache it's working fine. 17:25
m: 1 + 1
camelia rakudo-moar 07eeea: OUTPUT«WARNINGS for <tmp>:␤Useless use of "+" in expression "1 + 1" in sink context (line 1)␤»
viki m: my $x = -2²; my $y = 0-2²; say "It'd be weird if $x and $y were not the same"
camelia rakudo-moar 07eeea: OUTPUT«It'd be weird if -4 and -4 were not the same␤»
jferrero ouch... I forget the 'say' :)
timotimo viki: well, it's on twitter
17:25 sufrostico joined
hankache you need to do something with it (say) 17:26
jferrero m: say 4 == (1E12.log10 / 3).Int
camelia rakudo-moar 07eeea: OUTPUT«False␤»
viki floating math
m: say 4 ≅ (1E12.log10 / 3).Int
camelia rakudo-moar 07eeea: OUTPUT«False␤»
timotimo m: say 1e12.log10 17:27
camelia rakudo-moar 07eeea: OUTPUT«12␤»
viki /o\
timotimo m: say 1e12.log10 / 3
camelia rakudo-moar 07eeea: OUTPUT«4␤»
timotimo m: say 4 == (1e12.log10 / 3)
camelia rakudo-moar 07eeea: OUTPUT«False␤»
viki Ah, right. the ≅ won't help. 'cause .Int makes it 3 :)
.... cause of floating math
m: say 4 ≅ (1E12.log10 / 3).round
camelia rakudo-moar 07eeea: OUTPUT«True␤»
timotimo it really should output something that makes it clear it's not 4, but 4.something
viki m: put 1e12.log10 / 3 17:28
camelia rakudo-moar 07eeea: OUTPUT«4␤»
17:28 Gruber is now known as Grrrr
viki m: dd 1e12.log10 / 3 17:28
camelia rakudo-moar 07eeea: OUTPUT«4e0␤»
timotimo m: say (1e12.log10.perl)
viki heh
camelia rakudo-moar 07eeea: OUTPUT«12e0␤»
timotimo m: say (1e12.log10 - 12).perl
camelia rakudo-moar 07eeea: OUTPUT«-1.77635683940025e-15␤»
viki m: put (1e12.log10 / 3).perl
camelia rakudo-moar 07eeea: OUTPUT«4e0␤»
timotimo m: say (1e12.log10 / 12).perl 17:29
camelia rakudo-moar 07eeea: OUTPUT«1e0␤»
timotimo m: say (1e12.log10 / 12 - 1).perl
camelia rakudo-moar 07eeea: OUTPUT«-1.11022302462516e-16␤»
viki What was the thing to increase precision in output?
timotimo using fmt or sprintf
viki There's a method or something
Oh
m: printf '%.f', (1e12.log10 / 3)
camelia rakudo-moar 07eeea: OUTPUT«4»
viki m: printf '%.00000000000000000000000000000f', (1e12.log10 / 3)
camelia rakudo-moar 07eeea: OUTPUT«4»
viki shrugs
timotimo no, that's no thow
viki m: printf '%.12f', (1e12.log10 / 3) 17:30
camelia rakudo-moar 07eeea: OUTPUT«4.000000000000»
viki m: printf '%.32f', (1e12.log10 / 3)
camelia rakudo-moar 07eeea: OUTPUT«4.00000000000000000000000000000000»
viki m: printf '%.100f', (1e12.log10 / 3)
camelia rakudo-moar 07eeea: OUTPUT«4.0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000»
timotimo clearly that's b0rked as fuck.
viki m: say sprintf('%.1000000f', (1e12.log10 / 3)) eq sprintf('%.1000000f', 4)
camelia rakudo-moar 07eeea: OUTPUT«(timeout)» 17:31
viki m: say sprintf('%.10000f', (1e12.log10 / 3)) eq sprintf('%.10000f', 4)
camelia rakudo-moar 07eeea: OUTPUT«True␤»
17:32 kyclark joined
viki What's the second argument to nqp::log_n? 17:36
m: use nqp; say nqp::log_n(1e12, 10e0)
camelia rakudo-moar 07eeea: OUTPUT«2.30258509299405␤»
viki m: say e
camelia rakudo-moar 07eeea: OUTPUT«2.71828182845905␤»
viki m: use nqp; say nqp::log_n(1e12, 10000e0)
timotimo probably just switched around
camelia rakudo-moar 07eeea: OUTPUT«9.21034037197618␤»
viki m: use nqp; say nqp::log_n(10e, 1e12)
camelia rakudo-moar 07eeea: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Unable to parse expression in argument list; couldn't find final ')' ␤at <tmp>:1␤------> 3use nqp; say nqp::log_n(107⏏5e, 1e12)␤ expecting any of:␤ whitespace␤»
viki m: use nqp; say nqp::log_n(10e0, 1e12) 17:37
camelia rakudo-moar 07eeea: OUTPUT«27.6310211159285␤»
timotimo m: use nqp; say nqp::log_n(10e0, 1e20)
camelia rakudo-moar 07eeea: OUTPUT«46.0517018598809␤»
timotimo oh, huh.
viki m: use nqp; say nqp::log_n(e, 1e0)
camelia rakudo-moar 07eeea: OUTPUT«0␤»
viki m: use nqp; say nqp::log_n(e, 0e0)
camelia rakudo-moar 07eeea: OUTPUT«-Inf␤»
viki j: use nqp; say nqp::log_n(1e12, 10e0) 17:39
camelia rakudo-jvm 8d357a: OUTPUT«===SORRY!===␤Operation 'log_n' requires 1 operands␤»
17:39 dakkar left 17:42 kyclark left 17:43 kyclark joined
dalek osystem: 80380b7 | (Zoffix Znet)++ | README.md:
Add ecosystem-api.p6c.org/projects.json to readme
17:44
viki spots mojibake in that file :/ 17:45
Either that, or someone's got a really strange name: "authors":["Tadeusz тАЬtadzikтАЭ So┼Ыnierz" :D 17:46
timotimo Content-Type:application/json
no encoding apparently
viki yea 17:47
timotimo except json is specified to have a certain encoding, if i'm not mistaken 17:48
moritz I've just added charset=utf-8 to the header 17:49
viki Well, there can be several: tools.ietf.org/html/rfc7159#section-8.1 17:50
moritz++ 17:51
timotimo i didn't spot the mojibake :\ 17:52
viki Your browser then chose to use something else then. Mine chose Chyrilic 17:53
Cyrillic
timotimo i probably just looked over it too quickly to see
moritz or your browser is configured differently 17:54
17:59 nicq20 joined, itaipu joined
nicq20 Hello again o/ 18:00
viki \o 18:02
timotimo o7
viki Just in time. I'm doing final testing of my PHP6 parser :D
nicq20 Oh, cool! I didn't think it would be that hard, but that was fast! 18:05
viki m: gist.github.com/zoffixznet/d5e1da4...379277ea30 18:06
camelia rakudo-moar 07eeea: OUTPUT«===SORRY!===␤Could not find LWP::Simple at line 7 in:␤ /home/camelia/.perl6␤ /home/camelia/rakudo-m-inst-2/share/perl6/site␤ /home/camelia/rakudo-m-inst-2/share/perl6/vendor␤ /home/camelia/rakudo-m-inst-2/share/perl6␤ CompUnit::R…»
viki star: gist.github.com/zoffixznet/d5e1da4...379277ea30
camelia star-m 2016.04: OUTPUT« <!DOCTYPE html>␤ <html lang="en">␤ <meta charset="utf-8">␤ <title>Today's Time and Date</title>␤␤ ␤␤␤ <h1>The Perl 6 Ecosystem of ␤738␤ modules!</h1>␤␤ <table>␤ <thead>␤ <th>Module</th>␤ …»
18:06 kyclark left
viki And this is the resultant page: temp.perl6.party/out.html 18:06
18:06 eyck left
viki lol :D 18:06
Caveat: 💩 is not allowed to be in HTML itself :P 18:07
18:07 eyck joined 18:10 kyclark joined
AlexDaniel not sure what makes it PHP6 though. It's just some perl 6 inside HTML 18:13
18:14 seatek joined, brillenfux left
viki You're very observant! 18:14
18:16 labster joined
ilmari AlexDaniel: YHBT HTH HAND 18:16
18:18 mohae_ left, mohae joined
viki m: say (@z and @z.join) 18:22
camelia rakudo-moar 07eeea: OUTPUT«5===SORRY!5=== Error while compiling <tmp>␤Variable '@z' is not declared␤at <tmp>:1␤------> 3say (7⏏5@z and @z.join)␤»
viki m: my @z; say (@z and @z.join)
camelia rakudo-moar 07eeea: OUTPUT«[]␤»
viki TIL
18:22 Lucas_One left
viki m: my @z; say (@z.elems and @z.join) 18:22
camelia rakudo-moar 07eeea: OUTPUT«0␤»
viki neat
[Coke] should we canonicalize github addresses to a specific protocol in the module listing? 18:24
AlexDaniel speaking of php6… 18:25
m: dd Semaphore.^can(‘try_acquire’)
camelia rakudo-moar 07eeea: OUTPUT«(method try_acquire (Semaphore $: *%_ --> Bool) { #`(Method+{Callable[Bool]}|56124640) ... },)␤»
18:25 TEttinger joined
AlexDaniel why is it try_acquire ? 18:25
viki [Coke]: I thought we already did, but apparently we just cannonize to the "right" version of either git or http: github.com/perl6/ecosystem/blob/ma...ist.pl#L73 18:27
(and if we do want 1 address, we can just add code in that sub)
And I thought we normalized the source-url key to be 1 "right" key, but apparently not :/ 18:30
18:34 perlpilot joined 18:38 nicq20 left, cdg left 18:45 firstdayonthejob joined
viki uh-oh... app failed after pushing to production... 18:46
viki tries to recall how many times mst told him not to use MIME::Lite
18:48 brillenfux joined, brillenfux left 18:49 maybekoo2 joined 18:53 mohae_ joined
lizmat at least one time too few ? :-) 18:53
viki Seems to be. 18:54
Fortunatelly (or unfortunatelly?) I fixed the problem, leaving me free to ignore his advice some more :)
18:55 mohae left
pmurias viki: you are creating a php parser in Perl 6? 18:58
viki pmurias: nah. It was just a joke. Started with nicq20 asking if we could make same functionality with Perl 6 18:59
19:04 hankache left
viki .tell RabidGravy if you get bored, see if you can create a Perl 6 package for Minoca OS. Seems to be something for Raspberry Pies: blog.minocacorp.com/minoca-os-a-ne...b7998df3a7 19:07
yoleaux viki: I'll pass your message to RabidGravy.
19:10 bjz joined 19:20 wamba left 19:21 espadrine joined
lizmat is working on the Perl 6 Weekly: anything I *should* mention this week that I forgot about ? 19:21
19:22 darutoko left
lizmat any blog posts I missed ? 19:22
19:23 paulmr joined
viki lizmat: tbrowder++ posted this: blogs.perl.org/users/tom_browdef/20...erl-6.html 19:26
19:26 vendethiel- joined
lizmat yeah, got that :-) 19:26
19:26 RabidGravy joined
viki \o/ 19:26
19:28 vendethiel left
dalek line-Perl5: 37d444d | niner++ | / (3 files):
Fix using Perl 5 modules with Perl 6 extensions in Perl 6

Given a Perl 5 module package Foo; use v6::inline; ... Trying to use Foo:from<Perl5>; failed because the Perl 6 wrapper class overwrote the already created Perl 6 shadow class of the extended Perl 5 package.
19:32
RabidGravy boom!
yoleaux 19:07Z <viki> RabidGravy: if you get bored, see if you can create a Perl 6 package for Minoca OS. Seems to be something for Raspberry Pies: blog.minocacorp.com/minoca-os-a-ne...b7998df3a7 19:33
RabidGravy :)
19:38 espadrine left
RabidGravy let me have a look at the OS in a kvm first 19:38
viki Just spotted it on HackerNews :) No idea if it's any good even
19:39 kurahaupo__ joined 19:42 tomaw_ joined, bjz_ joined, bjz left 19:45 nadim_ joined, cdg joined
viki buggable: eco 19:48
buggable viki, Out of 739 Ecosystem dists, 166 have warnings and 1 have errors. See modules.perl6.org/update.log for details
19:49 nadim left
viki Needs refinement to know which errors are just due to GitHub.. (it's the Rakudo Travis thing all over again :o) 19:49
19:50 obfusk left
FROGGS[mobile]2 viki: I love you 19:53
19:53 leedo joined
FROGGS[mobile]2 r bots 19:53
timotimo hey viki you so fine, you so fine you blow my mind hey viki hey viki 19:54
FROGGS[mobile]2 *g* 19:55
19:56 Tonik joined
masak today's regular reminder that the hanzi for "ping pong" are 乒乓 20:03
:P
arnsholt =D 20:04
moritz nice :-)
20:05 itaipu left
kurahaupo__ timotimo: so that's what happened to Antonia Basilotta; she quit singing in 1983 to become a Perl coder? 20:07
masak pronounced "pīngpāng" -- those marks signify first tone, which is high and flat 20:08
er, level
lizmat and another Perl 6 Weekly hits the Net: p6weekly.wordpress.com/2016/10/31/...-в-perl-6/ 20:11
masak yay -- lizmat++ 20:13
another infrared clog classic, this time brought to you by japhb++: "" is best pronounced "hippity-hop" 20:14
masak also finds a lot of masak pleading with diakopter to stop naming macros "marco" 20:15
[Coke] "polo" a close second! 20:18
masak though I admit it took me years to realize that, since *functions* are called "foo" by default... 20:20
...*macros* should of course be called "moo" by default
(so that's what I do now)
20:20 domidumont left 20:21 tomaw_ left 20:23 Tonik left 20:25 richi235 joined
arnsholt masak: Is "polo" also accepted as a macro name? =) 20:29
20:30 FROGGS[mobile]2 left 20:32 FROGGS joined
FROGGS o/ 20:33
lizmat++ # p6weekly
viki lizmat++ # good weekly 20:37
masak arnsholt: I'd suggest going with "moo" and "jar", in analogy with "foo" and "bar" 20:40
arnsholt Oh, nice 20:41
20:41 ale1ster joined, abraxxa left
arnsholt From the Synopses, another favourite of mine is "sub marine(@sailors) { ... }" 20:41
20:43 abraxxa joined 20:44 MasterDuke left
masak oh! oh! I had completely forgotten about diakopter trying and failing to grok autopuns... :) 20:45
20:46 setty1 joined, nicq20 joined 20:47 ale1ster left
[Coke] masak: moose and squirrel 20:47
masak 'night, #perl6 20:48
lizmat night masak
21:00 kyclark left, skids left 21:05 bjz_ left
dalek line-Perl5: 65ceb50 | niner++ | p5helper.c:
Fix calling Perl 6 extension methods when loaded via Inline::Perl6
21:10
nicq20 What is the '++' that is sometimes placed after a person's name? Something similar to props? 21:13
21:15 FROGGS left, FROGGS joined
jonadab nicq20: Yes, you can safely ignore it. 21:15
lizmat it's a sign of appreciation
nicq20 Ah, ok. I thought it was, but I wanted to make sure. 21:16
lizmat nicq20++ # providing clarity to newbies 21:17
nicq20 Woo! \o/ 21:18
21:18 nicq20 left 21:19 cdg left, paulmr2 joined
lizmat blogs.perl.org/users/max_maischein/...-perl.html # /me wants for Perl 6 :-) 21:21
21:23 paulmr left, nicq20 joined 21:24 xdbr left
FROGGS ohh nice 21:25
21:29 MasterDuke joined
dalek c: a100f07 | (Jan-Olof Hendig)++ | doc/Language/functions.pod6:
Fixed incorrectly displayed code example
21:31
21:35 grondilu joined
grondilu hello #perl6 21:36
nicq20 Hey-o
lizmat grondilu o/
ugexe m: my $x = 5 andthen * *= 5; say $x; my $y = 5 andthen * = 25; say $y; # whats the difference that allows *= but not = ?
camelia rakudo-moar ba4967: OUTPUT«25␤Cannot modify an immutable Whatever␤ in block <unit> at <tmp> line 1␤␤»
grondilu some sort of a webassembly announcement on HN today 21:37
grondilu currently tries to compile emscripten again
grondilu vaguely hopes he could compile MoarVM with it
v8project.blogspot.fr/2016/10/webas...eview.html 21:38
21:59 kurahaupo__ left 22:00 setty1 left 22:02 setty1 joined 22:08 cdg joined 22:11 RabidGravy left 22:12 rindolf left 22:17 abraxxa left 22:18 paulmr2 left 22:21 kurahaupo__ joined 22:23 bjz joined 22:30 kurahaupo__ left, kurahaupo__ joined 22:34 skids joined 22:35 bjz left 22:37 khw left 22:40 nicq20 left 22:43 rodarmor left 22:45 kurahaupo__ is now known as kurahaupo, kurahaupo left, kurahaupo__ joined 22:46 kurahaupo__ is now known as kurahaupo, cdg left 23:06 dwarring joined 23:20 pmurias left 23:23 firstdayonthejob left 23:24 labster left 23:28 bjz joined, labster joined 23:32 FROGGS left 23:34 cdg joined 23:50 khw joined 23:56 nadim joined, nadim_ left, maybekoo2 left