Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2013-04-08

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:02 colomon n: say rand xx 2
00:02 p6eval niecza v24-35-g5c06e28: OUTPUT«0.815935582768142 0.413482928841134␤»
00:04 colomon grondilu: I guess the magic that makes the left-hand-side into a block doesn't work through Rop
00:04 colomon probably should count as rakudo and niecza bugs
00:25 grondilu ok, that's what I thought
00:35 lustlife joined #perl6
00:47 _jaldhar joined #perl6
00:55 anuby joined #perl6
01:04 _jaldhar joined #perl6
01:09 cognominal joined #perl6
01:17 FROGGS_ joined #perl6
01:20 cognominal joined #perl6
01:25 anuby_ joined #perl6
01:27 berekuk joined #perl6
01:33 Bzek joined #perl6
01:33 edgeuplink joined #perl6
01:37 edgeuplink joined #perl6
02:06 colomon n: say infix:<xx>(rand, 3)
02:06 p6eval niecza v24-35-g5c06e28: OUTPUT«0.62666999903818121 0.62666999903818121 0.62666999903818121␤»
02:08 colomon n: sub g(\item, $count) { ^$count.map({ item }); }; say g(rand, 3)
02:08 p6eval niecza v24-35-g5c06e28: OUTPUT«0..^1␤»
02:09 colomon n: sub g(\item, $count) { (^$count).map({ item }); }; say g(rand, 3)
02:09 p6eval niecza v24-35-g5c06e28: OUTPUT«0.83686888582858676 0.83686888582858676 0.83686888582858676␤»
02:13 colomon n: say rand xx 3
02:13 p6eval niecza v24-35-g5c06e28: OUTPUT«0.035388940030424365 0.63918304845652685 0.74073798569884985␤»
02:19 * colomon has no idea how niecza does that.
02:21 * colomon knows how niecza does that!
02:21 diakopter nice!
02:21 colomon thunk_sub
02:21 colomon Operator::Replicate
02:23 berekuk joined #perl6
02:25 colomon dunno if I can do anything useful with that knowledge, but it's still nice to know.
02:27 colomon n: say 3 Rxx rand
02:27 p6eval niecza v24-35-g5c06e28: OUTPUT«0.05756106649411892 0.05756106649411892 0.05756106649411892␤»
02:27 colomon n: say 3 Rxx { rand }
02:28 p6eval niecza v24-35-g5c06e28: OUTPUT«{ ... } { ... } { ... }␤»
02:35 bruges joined #perl6
02:50 orafu joined #perl6
02:53 preflex_ joined #perl6
03:15 Khisanth joined #perl6
03:16 awwaiid joined #perl6
03:24 dalek rakudo/nom: 2bd981d | (Geoffrey Broadwell)++ | src/core/Hash.pm:
03:24 dalek rakudo/nom: Break DUMP recursion for Hash
03:24 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/2bd981dddc
03:24 dalek rakudo/nom: 160c0f8 | (Geoffrey Broadwell)++ | src/core/Mu.pm:
03:24 dalek rakudo/nom: DUMP armoring and correctness fixes
03:24 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/160c0f8a3e
03:24 dalek rakudo/nom: 5adc4db | (Geoffrey Broadwell)++ | src/core/Mu.pm:
03:24 dalek rakudo/nom: DUMP(): Remove redundant null check; add explicit low-level hash handling; minor refactoring to make debugging clearer
03:24 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/5adc4dbdf6
03:27 japhb_ joined #perl6
03:56 rindolf joined #perl6
04:05 japhb_ Anyone remember how to check on the rebuild status of p6eval (meaning, when's the last time it tried, and whether it succeeded)?
04:06 t5a joined #perl6
04:08 t5a How I can Start GUI in perl?
04:16 * geekosaur has no clue what you are trying to ask
04:17 geekosaur also, if this is a question involving perl 5, try #perl
04:20 japhb_ r: say «««»»».DUMP
04:20 p6eval rakudo 5adc4d: OUTPUT«Parcel<1>(:$!storage(RPA<2>(␤    "«",␤    List<4>(␤        :$!flattens(Mu),␤        :$!items(â–¶Mu),␤        :$!nextiter(ListIter<6>(␤            :$!list(=List<4>),␤            :$!reified(â–¶Mu),␤            :$!nextiter(â–¶Mu),␤            :$!rest(RPA<7>(MapIter<8>(␤    â€¦
04:21 japhb_ diakopter, ^^
04:23 diakopter how you fix it
04:24 diakopter I'll armor your dump
04:24 japhb_ diakopter, the last three commits.  :-)
04:25 japhb_ You should run it locally, too.  It's a pretty astonishingly large dump for a six-character expression.
04:27 japhb_ r: say DUMP(\())
04:27 p6eval rakudo 5adc4d: OUTPUT«Capture<1>(␤    :$!list(Parcel<2>(:$!storage(RPA<3>()))),␤    :$!hash(Hash<4>(␤        :$!descriptor((null)),␤        :$!storage(Hash<5>())␤    ))␤)␤»
04:27 diakopter r: say DUMP(.^methods)
04:27 p6eval rakudo 5adc4d: OUTPUT«Unmarshallable foreign language value passed for parameter '$value'␤  in method new at src/gen/CORE.setting:6611␤  in block  at src/gen/CORE.setting:6743␤  in sub coro at src/gen/CORE.setting:5911␤  in method reify at src/gen/CORE.setting:5893␤  in method reify at …
04:27 diakopter ftw, first try
04:28 japhb_ KAAAAAAAHHHHHHHHHNNNNNNNNN!!!!
04:28 japhb_ ;-)
04:28 diakopter "Fire....."
04:33 t5a left #perl6
04:44 diakopter r: say «««»»».DUMP.chars
04:44 p6eval rakudo 5adc4d: OUTPUT«2734␤»
04:45 diakopter r: say «««««««««««««««»»»»»»»»»»»»»»».DUMP.chars
04:45 p6eval rakudo 5adc4d: OUTPUT«(timeout)»
04:45 diakopter yeah........
04:45 diakopter *whimper*
04:46 * geekosaur wonders if you've written fibonacci or something
04:47 geekosaur r: say ««««»»»».DUMP.chars
04:47 p6eval rakudo 5adc4d: OUTPUT«3918␤»
04:48 geekosaur at least it's not ackermann's function
04:49 diakopter japhb_: confused....
04:49 diakopter «««»»»
04:49 diakopter um
04:49 diakopter r: say ({ $_ := .DUMP } for ^200)
04:49 p6eval rakudo 5adc4d: OUTPUT«0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91…
04:57 japhb_ diakopter, what are you confused by?
04:58 diakopter sorry, being dense
05:02 Bzek joined #perl6
05:04 d4l3k_ joined #perl6
05:41 daniel-s__ joined #perl6
05:46 cibs joined #perl6
05:53 frdmn joined #perl6
05:55 arcterus joined #perl6
05:56 SamuraiJack joined #perl6
06:02 FROGGS_ joined #perl6
06:03 rindolf joined #perl6
06:31 wtw joined #perl6
06:32 rindolf joined #perl6
06:58 domidumont joined #perl6
07:05 brrt joined #perl6
07:09 moritz \o
07:09 timotimo good day moritz
07:11 kivutar joined #perl6
07:14 domidumont joined #perl6
07:15 kshamen joined #perl6
07:18 nwc10 jnthn: back to "the ususal"
07:18 brrt hi #perl6
07:19 labster joined #perl6
07:19 FROGGS_ morning
07:23 domidumont joined #perl6
07:24 labster morning
07:25 diakopter morning.
07:25 diakopter .. and yet, bedtime.
07:26 BigBear joined #perl6
07:26 labster It should be bedtime for me too.  Let's just pretend I live in Hawaii so I can get a couple more hours.
07:28 vaelxon http://xkcd.com/448/
07:34 sqirrel joined #perl6
07:35 brrt joined #perl6
07:39 jnthn nwc10: Is that in master or in the branch?
07:42 nwc10 the branch
07:42 nwc10 master hadn't changed, IIRC
07:45 jnthn Ah, true :)
07:45 * jnthn will merge the branch later today
07:49 timotimo was ASM only suggested because of a nicer API? performance? size of library?
07:50 jnthn timotimo: API did actually match better, and it is faster, but its much better invokedynamic support was what convinced me.
07:52 labster FROGGS_: I'm still a bit stuck on the naming of the splitpath/catpath alternates.  File::Spec.split and .join sound okay, because it's splitting and joining a file specification.  But if one does my $sp = File::Spec; ... $sp.join($path) -- it looks like it might be joining a string.
07:52 labster Thinking about path2vdb (volume-directory-basename) and vdb2path, but those seem inelegant too.  Maybe just multi-dispatch splitpath and catpath based on whether they want basename?
07:53 timotimo jnthn: considering my brownian tree example takes about 2000 seconds to calculate, you make me happy every time you mention "faster" (although i imagine this is only compile time speed-ups)
07:56 labster we're all happy any time jnthn++ mentions "faster"
07:57 BigBear left #perl6
07:59 kivutar joined #perl6
08:00 cognominal joined #perl6
08:04 berekuk joined #perl6
08:13 xinming joined #perl6
08:17 cognominal joined #perl6
08:30 dakkar joined #perl6
08:30 Heather joined #perl6
08:30 Heather hi there
08:31 Heather I need some regex guru (
08:31 * moritz hands Heather a plastic regex guru
08:32 Heather moritz hi
08:32 Heather I'm trying to handle file names alike qwe.4.1.JPG
08:33 Heather but I don't know even how to set rule string to be separated buy dots
08:33 Heather I mean... alike in example
08:33 moritz in what way do you need to "handle" them?
08:33 moritz what's the goal of parsing them?
08:33 moritz or do you want to find them in a string?
08:33 Heather well first part is any string... I guess \\w+ ?
08:34 Heather second part is any number
08:34 Heather and last part is [1-2] (1 or 2)
08:34 Heather and some extension
08:34 Heather I'm trying to check if there are files named following this rule
08:34 jnthn If you just want separated by dots, just .split('.') :)
08:34 fhelmberger joined #perl6
08:35 moritz jnthn: that's why I asked what the purpose is
08:35 moritz Heather: \w+ isn't "any string"
08:35 Heather well I need to examine if file satisfy all the rules ...
08:35 moritz sounds like you want something like
08:35 Heather moritz that's bad
08:36 moritz if  $fn ~~ /\. \d+ .. [1|2] \. \w+ $ /
08:36 Heather it's modern regex? :(
08:36 moritz modern?
08:36 Heather new perl6 regex )
08:36 kresike joined #perl6
08:37 kresike hello all you happy perl6 people
08:37 moritz well of course; this is #perl6 :-)
08:37 Heather krunen hi
08:37 Heather moritz for now I need regular one ) but thank you, it will be easier for me to convert I guess
08:41 FROGGS_ labster: how do you wanna distinguish if you get a basename to catpath, if you just slurp an array?
08:42 bruges joined #perl6
08:43 labster use a named argument like :usebasename?
08:44 diakopter Heather: in a phrasing such as   (haha ) )  , how can I one tell which is the smiley
08:45 Heather diakopter eh?
08:45 FROGGS_ labster: hmmm, then you could pass the base name as :basename
08:46 labster FROGGS_: actually, for now, I just decided to use .split and .join until someone decides to complain.  There already was a join alias for catfile, so I might as well repurpose that.
08:47 FROGGS_ ya
08:48 kaleem joined #perl6
08:48 labster If no one complains I obviously didn't do anything wrong.  The whole goal of this is for the low-level parsing of file paths to be available, but hard, while IO::Paths are easy to manipulate.
08:54 BigBear joined #perl6
08:56 grondilu joined #perl6
09:01 berekuk joined #perl6
09:02 domidumont joined #perl6
09:04 BigBear Good morning #perl6
09:06 moritz good morning BigBear
09:41 bruges joined #perl6
09:41 labster just wrote: if all($directory, $file) eq any('/','\\')
09:41 labster ♥ junctions so much
09:42 masak :)
09:43 masak I hardly ever use them as first-class thingies, though.
09:43 masak maybe that extra bit of freedom is sometimes worth it... but I try very hard not to make junctions leak from my APIs, for example.
09:44 daxim joined #perl6
09:44 masak I could very well live with junctions that were just syntactical.
09:45 moritz occasionally they are very handy as arguments to grep
09:45 moritz where it wouldn't work if they were just syntactical
09:45 masak yes.
09:45 moritz but maybe it'd be worth it
09:46 moritz and we'd get rid of that weird Mu/Any distinction
09:46 masak and once I wrote a script when I stored them as values in a hash table. the use is the same really, because I put them in a grep later on.
09:47 masak moritz: warping the type system to accommodate junctions always felt weird to me, even before I knew a lot about type systems.
09:47 masak moritz: but I think it's too late to affect such a change.
09:56 jnthn Having it fall out of the type system means it's much less of a special case.
09:57 jnthn We push a lot of distinctions into the type system in Perl 6, so it's a fairly natural way to do it.
09:59 anuby joined #perl6
10:02 daxim teach me using the docs:  if I want to look up the syntax for interpolating expressions (like babycart in p5 and #{} in ruby), where do I go first?
10:02 moritz S02
10:03 moritz 'cause S02 deals with nearly all syntax stuff
10:03 timotimo ... babycart?
10:03 moritz @{\[ ... ]} iirc
10:04 daxim can that be made discoverable somehow?  I don't know that S02 equals syntax, I need to be told or shown a click trail
10:05 brrt joined #perl6
10:05 masak moritz: \ and [] are kinda redundant.
10:06 daxim the official title of S02 is "Bits and Pieces"
10:06 masak heh.
10:06 masak I think of it as "Syntax" :)
10:06 daxim sorry, this is terrible usability
10:06 masak granted.
10:07 masak daxim: that chapter title is taken from the Camel book, IIRC.
10:07 Heather left #perl6
10:07 tgt joined #perl6
10:07 masak daxim: yep. just confirmed.
10:07 masak fwiw, I think of S02 as "Syntax and basic types".
10:08 masak I guess the syntax is the "pieces" and the basic types are the "bits" :P
10:11 daxim rakudo: Qc'yayxpression! { 3+3 }'.say
10:11 p6eval rakudo 5adc4d: OUTPUT«yayxpression! 6␤»
10:11 daxim aha, that worked
10:13 daxim rakudo: cï½¢yaynicode! { 23+42 }ï½£.say
10:13 p6eval rakudo 5adc4d: OUTPUT«[31m===[0mSORRY![31m===[0m�Two terms in a row�at /tmp/B1J_fEtRHh:1�------> [32mc[33m�[31mï½¢yaynicode! { 23+42 }ï½£.say[0m�    expecting any of:�        argument list�        postfix�        infix stopper�        infix or meta-infix�        statement end�      Ã¢â‚¬Â¦
10:13 daxim where does the adverb go?
10:16 domidumont joined #perl6
10:17 Heather joined #perl6
10:17 Heather p5: say "hi"
10:17 Heather p5eval: say "hi"
10:17 p5eval Heather: hi1
10:18 Heather p6eval: say "1.2.1.1" =~ "(\\%s)(\\.)(\\d+)(\\.)([1-2])(\\.)(\\w+)"
10:18 Heather p5eval: say "1.2.1.1" =~ "(\\%s)(\\.)(\\d+)(\\.)([1-2])(\\.)(\\w+)"
10:18 p5eval Heather: 1
10:18 Heather ...
10:18 Heather 1?
10:18 Timbus p5eval: ""
10:18 p5eval Timbus: No output
10:19 Timbus p5eval: say ""
10:19 p5eval Timbus: 1
10:19 daxim the expression is true, what else do you expect?
10:19 Heather p5eval: say "1.2.1.1" =~ "(\\1)(\\.)(\\d+)(\\.)([1-2])(\\.)(\\w+)"
10:19 p5eval Heather: 1
10:19 Timbus yea
10:19 Heather daxim I expect false
10:19 Timbus p5eval: say "1.2.1.1" =~ "(\\1)(\\.)(\\d+)(\\.)([1-2])(\\.)(\\w+)"; -5
10:19 p5eval Timbus: -5
10:20 Timbus :3
10:20 daxim p5eval: say for "1.2.1.1" =~ "(\\1)(\\.)(\\d+)(\\.)([1-2])(\\.)(\\w+)"  # let's try list context for the binding op
10:20 p5eval daxim: No output
10:21 Timbus oh boy contexts
10:21 FROGGS_ p5eval: unless( 0e0 ) { ... } elseif( 0 ) { } else { "yay"}
10:21 p5eval FROGGS_: ERROR: syntax error at (eval 7) line 1, near ") {"
10:21 Heather !!!
10:21 FROGGS_ p5eval: unless( 0e0 ) { ... } elsif( 0 ) { } else { "yay"}
10:21 p5eval FROGGS_: ERROR: Unimplemented at (eval 7) line 1.
10:22 FROGGS_ p5eval: unless( 0e0 ) {  } elsif( 0 ) { } else { "yay"}
10:22 p5eval FROGGS_: No output
10:22 * FROGGS_ would like to add statement modifier loops and continue block to make it worse
10:23 huf continue blocks go on loops
10:23 huf if aint one, afaik
10:24 labster FROGGS_ needs to implement the ufo operator next
10:24 Heather left #perl6
10:29 bbkr_ joined #perl6
10:32 cognominal joined #perl6
10:38 lizmat good postnoon #perl6
10:39 lizmat http://www.smbc-comics.com/index.php?db=comics&amp;id=2939#comic
10:39 lizmat so true
10:40 FROGGS_ !!#&@! looks really perly :o)
10:42 masak lizmat: wow, yes.
11:03 fhelmberger joined #perl6
11:04 brrt joined #perl6
11:11 cognominal .u &#9634;
11:11 yoleaux U+0023 NUMBER SIGN [Po] (#)
11:11 yoleaux U+0026 AMPERSAND [Po] (&)
11:11 yoleaux U+0033 DIGIT THREE [Nd] (3)
11:12 cognominal .u &#x25A2;
11:12 yoleaux U+0023 NUMBER SIGN [Po] (#)
11:12 yoleaux U+0026 AMPERSAND [Po] (&)
11:12 yoleaux U+0032 DIGIT TWO [Nd] (2)
11:12 brrt yoleaux is a bot?
11:14 cognominal yoleaux, help .u
11:14 cognominal yoleaux, help
11:14 FROGGS_ .help
11:14 yoleaux FROGGS_: I'm yoleaux. Type .commands to see what I can do, or see http://dpk.io/yoleaux for a quick guide.
11:14 FROGGS_ .commands
11:14 yoleaux Commands are divided into categories: general, services, admin, api, demos. Use .commands <category> to get a list of the commands in each.
11:14 FROGGS_ .commands services
11:14 yoleaux Commands in services: acronym, add-command, beats, bitcoin, cat, command-help, del-command, dety, flip, geo, google, lastfm, leo, meow, moon, ngrams, nokiageo, nownext, o, oed, pass-rate, rb, republical, rot13, scm, shipping, suggest, swhack, thesaurus, ud, weather, yi, youtube. Use .help to get information about them.
11:14 cognominal .help .u
11:14 yoleaux Search for a Unicode character by codepoint, name, or raw character
11:15 cognominal .u 25A2
11:15 yoleaux U+25A2 WHITE SQUARE WITH ROUNDED CORNERS [So] (â–¢)
11:16 BigBear joined #perl6
11:19 colomon .u 9634
11:19 yoleaux No characters found
11:22 FROGGS_ .u 阴
11:22 yoleaux No characters found
11:22 FROGGS_ ENOTCOMPLETE
11:25 sqirrel so habs paket weggebracht und milch gekauft
11:25 masak .u characters
11:25 yoleaux U+1F007 MAHJONG TILE ONE OF CHARACTERS [So] (🀇)
11:25 yoleaux U+1F008 MAHJONG TILE TWO OF CHARACTERS [So] (🀈)
11:25 yoleaux U+1F009 MAHJONG TILE THREE OF CHARACTERS [So] (🀉)
11:25 masak :P
11:25 sqirrel uups wrong window sorry
11:29 FROGGS_ hehe
11:29 FROGGS_ >.<
11:29 FROGGS_ sqirrel++
11:36 brrt that is such an awesome name for a bot
11:36 tadzik oh, BigBear, hi
11:37 tadzik I glanced at the issue yesterday, and I'm not sure why would it work on osx but not on windows
12:03 cognominal joined #perl6
12:12 lizmat rn say :!verbose.perl
12:12 lizmat rn: say :!verbose.perl
12:12 p6eval rakudo 5adc4d, niecza v24-35-g5c06e28: OUTPUT«"verbose" => Bool::False␤»
12:13 domidumont1 joined #perl6
12:14 lizmat I guess .perl doesn't have to roundtrip source, just AST's, right?
12:20 jnthn The aim is to try and have .perl.eval round-trip
12:20 masak lizmat: TimToady_ long wanted it to roundtrip source. but I have the feeling that the non-TimToady consensus is not to emit source code is part of function values.
12:21 lizmat ok, clear
12:21 lizmat so in the end, .perl will emit source that will recreate the same AST
12:21 jnthn I keep wanting &some_regex.perl to give me the source though...
12:21 gcole joined #perl6
12:21 masak yeah.
12:21 jnthn lizmat: ASTs are also very transient
12:22 jnthn We don't execute the AST, it just exists during compilation, then once we have the bytecode for the target VM we just throw it away, for the most part
12:23 lizmat ack, so .perl.eval is the only thing we're sure that will roundtrip
12:23 lizmat gotcha
12:39 jerry66 joined #perl6
12:39 domidumont joined #perl6
12:39 jerry66 http://www.reddit.com/r/XXXEROTICSXXX/comments/1bwvye/i_am_a_19yo_nimfo_girl_searching_to_have_a_fun/
12:40 mattp__ suspecting off topic...
12:42 jnthn Well, Perl 6 is -Ofun...
12:42 [Coke] tadzik++ #pander
12:47 timotimo -Ofuntopic?
12:48 timotimo -Offuntopic?
12:48 frdmn|afk joined #perl6
12:51 dakkar_ joined #perl6
12:52 ilogger2_ joined #perl6
13:02 bluescreen10 joined #perl6
13:04 Woodi_ hallo today
13:05 FROGGS_ hi Woodi_
13:05 Woodi_ I have that problem for some longer time... http://pastebin.com/Nj4B3pBz
13:06 Woodi_ I didn't pustcode to github becouse this makes stop in basic functionality...
13:11 masak hi Woodi.
13:12 PacoAir joined #perl6
13:14 BigBear joined #perl6
13:21 denisboyun_ joined #perl6
13:23 lizmat rn: "\c[LINE FEED]"
13:23 p6eval niecza v24-35-g5c06e28: OUTPUT«[31m===[0mSORRY![31m===[0m��Unrecognized character name LINE FEED at /tmp/5ykb57IjHH line 1:�------> [32m"\c[LINE FEED[33m�[31m]"[0m��Unhandled exception: Check failed��  at /home/p6eval/niecza/boot/lib/CORE.setting line 1443 (die @ 5) �  at /home/…
13:23 p6eval ..rakudo 5adc4d: OUTPUT«[31m===[0mSORRY![31m===[0m�Unrecognized character name LINE FEED�at /tmp/87bu8WhYz1:1�------> [32m"\c[LINE FEED[33m�[31m]"[0m�»
13:24 lizmat this is a failing rakudo spectest…  is that correct ?
13:25 lizmat afk for a few hours&
13:26 jnthn iirc, that's one of those funny wants that has the name <control> and you gotta look under the old name Unicode property to find it as LINE FEED...
13:26 jnthn s/wants/ones/
13:26 jnthn though warts woulda worked... :)
13:35 cognominal joined #perl6
13:36 colomon joined #perl6
13:36 kaare_ joined #perl6
13:39 SmokeMachine joined #perl6
13:49 frdmn joined #perl6
13:56 shinobicl joined #perl6
14:12 tgt joined #perl6
14:23 Psyche^ joined #perl6
14:38 xilo joined #perl6
14:39 xilo_ joined #perl6
14:41 arcterus joined #perl6
14:48 ggoebel joined #perl6
14:54 kaleem joined #perl6
14:57 mmol_saffron joined #perl6
14:59 skids joined #perl6
15:03 rindolf joined #perl6
15:04 felher masak: did you already do your 'perl6 workshop'?
15:05 estrabd joined #perl6
15:06 estrabd joined #perl6
15:09 dalek nqp-jvm-prep/asm_port: 0866deb | jnthn++ | src/org/perl6/nqp/jast2bc/JASTToJVMBytecode.java:
15:09 dalek nqp-jvm-prep/asm_port: Cleanup some dead code.
15:09 dalek nqp-jvm-prep/asm_port: review: https://github.com/jnthn/nqp-jvm-prep/commit/0866debf25
15:10 kresike bye folks
15:10 colomon asm_port?
15:11 jnthn colomon: Replaces BCEL with ASM for code-gen
15:11 * colomon does not know what either of those acronyms means...
15:11 jnthn colomon: They are different code-generation libraries.
15:11 * colomon is pretty sure you're not talking about the Autodesk Shape Manager....
15:12 jnthn colomon: I went with BCEL (Bytecode Engineering Library) at first, but donaldh++ pointed out that a different library, ASM, was preferable in various ways. I agreed, he did the hard work, and yesterday I did the final fixes so we can switch over to it.
15:12 colomon cool
15:12 jnthn colomon: This unblocks working towards making use of invokedynamic.
15:13 * colomon is googling this stuff in another window now.
15:16 masak felher: no, and I'm still mulling over it, and still wanting that perfect combination of enough participants and a date when maximally many are available.
15:16 masak felher: I still plan to do it. I have a half-finished schedule of Things To Talk About.
15:17 dalek Heuristic branch merge: pushed 20 commits to nqp-jvm-prep by jnthn
15:17 jnthn There we go. Merged.
15:17 jnthn donaldh++ :)
15:19 felher masak: ah, okay. Well, since I have now completed my bachelor, I'm finally starting to get some free time again. So you may count me in. I'd really like to participate in your workshop :)
15:22 moritz felher: congratulations!
15:22 felher moritz: thank you :)
15:24 masak felher: yes, congrats! and welcome aboard!
15:24 crab2313 joined #perl6
15:26 masak that makes Heather, tadzik, TimToady, census, timotimo_, and felher.
15:26 masak felher: when are you available? what about May 1st?
15:29 nwc10 jnthn: right now, is the NQP-JVM codegen actually still outputing Java 1.6 bytecode?
15:29 shinobicl left #perl6
15:32 gtodd masak I think I have cloned the tip ... will now try to merge something and make a "release" for my own edification :)
15:32 felher masak: Thanks. Seems like a nice group :) Regarding May 1st: Don't know yet. Every couple of years we go out on May 1st with the wohle family. I will be able to tell you at the end of the week, though. :)
15:32 jnthn nwc10: I don't think so.
15:32 nwc10 OK: :-/
15:32 jnthn nwc10: Oh, wait, maybe...
15:32 jnthn nwc10: Either way, invokedynamic usage will come soon, so...
15:33 jnthn That'll force it to that if it's not already.
15:33 nwc10 yes, I realise that at that point it definately will be firmly beyond 6
15:34 felher masak: how long will your workshop probably be?
15:35 [Coke] java 7 ftw. mostly.
15:35 gtodd masak: I'm assuming that in a real release scenario, the most git tools will somehow just let me know what "pull requests" (?)  people have tested and approved for merging into a release ... otherwise things could be errm the opposite of the cheeseshop sketch
15:36 masak felher: it will probably stretch from 16:00 to 20:00 UTC or so. at least if people from the Americas want to participate.
15:36 masak felher: 3 or 4 hours sounds reasonable. but I'm not 100% about when it'll be. have to ask Heather, too, who is from the East.
15:38 felher masak: fair enough :)
15:40 [Coke] gtodd: in a real release scenario, you'd ship whatever had been pulled already.
15:40 masak felher: am I thinking right with May 1? it will be a day when people are mostly off work, yes?
15:40 [Coke] if you were one of the developers, you could (as a previous step) review the pull requests and pull them yourself if you liked them.
15:40 masak felher: the alternative would be to have it happen in the weekend, but that feels wrongish.
15:41 [Coke] ... which reminds me: there are 9 open pull requests that need tending. One is almost a year old.
15:41 gtodd oops I meant "the most excellent git tools" which is short for "some way of doing it without having to click all over the place on github ... etc. etc."
15:41 dalek perl6-roast-data: ef7d533 | coke++ | / (3 files):
15:41 dalek perl6-roast-data: today (automated commit)
15:41 dalek perl6-roast-data: review: https://github.com/coke/perl6-roast-data/commit/ef7d533271
15:41 dalek perl6-roast-data: 784b762 | coke++ | / (3 files):
15:41 dalek perl6-roast-data: today (automated commit)
15:41 dalek perl6-roast-data: review: https://github.com/coke/perl6-roast-data/commit/784b762c7c
15:42 felher masak: I think you think right. :) On May 1st most people probably will be off work. But I for one don't have any problems with workshop on weekend either :)
15:44 gtodd [Coke]: :-) now you see I can see those 9 request on github :-)  ... I assume updates to my cloned repo would awake me from any slumber in some way and allow a pumpking or release manager to automatically harass the requesters and testers so those can be merged ...
15:45 [Coke] dvj: I think it was you that modified S02-names-vars/perl.t - when fudging (and I missed this also when I reviewed your commit), be sure to avoid things like {{ #?pugs skip 'isn't working' }} - the nested single quote there throws off the parse of the whole file.
15:46 gtodd [Coke]: or if merged by a too enthusiastic person or script and not playing nicely ... then backed out
15:46 [Coke] you need to use the webterface to see those.
15:46 BigBear joined #perl6
15:46 gtodd ... and all of that somehow documented as a errm Release Engineering
15:46 [Coke] I am not sure you can (easily) apply them from the command line.
15:46 gtodd hmm ok
15:46 FROGGS joined #perl6
15:47 [Coke] gtodd: those are dealt with ad hoc, not as part of the release.
15:47 [Coke] you are under no obligation as a release manager to deal with undealt with pull requests. (but you can if you want to.)
15:47 gtodd possibly they can be scripted - using perl 5 just to be safe ;-)
15:47 [Coke] dvj: also, be sure to update the plan when you add tests.
15:48 nwc10 jnthn: "the usual", post merge
15:49 gtodd [Coke]: ok so because of ease of pull fork merge in git then chaos can ensue until closer to a release (either a timed release or some testing blocking bug style release)
15:49 [Coke] dvj: ... when there is one. curses.
15:50 tgt joined #perl6
15:50 masak felher: ok. I'll try to get in touch with more people and ask them too. thanks for your feedback!
15:50 masak and your interest.
15:51 felher masak: thanks for doing a workshop! :)
15:51 dalek roast: 64c7348 | coke++ | S02-names-vars/perl.t:
15:51 dalek roast: pugs refudge
15:51 dalek roast: review: https://github.com/perl6/roast/commit/64c7348454
15:52 gtodd [Coke]: only really familiar with release process of FreeBSD-#.#-RELEASE (by observing as a user; not by being involved) and I am interested to see how git as a process is used by perl6/rakudo
15:52 [Coke] gtodd: "we release once a month whether we need to or not".
15:53 [Coke] I wouldn't say we use git to drive the process.
15:53 masak [Coke]: fwiw, there hasn't been a month where there wasn't anything new in Rakudo.
15:54 [Coke] nom is the branch we release from. we are not sticklers about things passing on nom before commit (but please try to make sure they do), but we do make sure that the full spec test suite passes before a release.
15:55 [Coke] masak: new ne release worthy, but aye.
15:55 gtodd ah ok
15:56 [Coke] I think we've had 2 cases where we've had to release a bugfix compiler release shortly after the initial release due to missed bugs.
15:56 [Coke] in general, big merges are better immediately after a release to give us a more time to test.
15:57 [Coke] but none of that is driven by code, or by a specific branching methodology.
16:00 frdmn joined #perl6
16:28 isBEKaml joined #perl6
16:31 Chillance joined #perl6
16:31 isBEKaml masak: you now have another scheduling headache. :) Count me in for your perl6 workshop!
16:33 nwc10 p5eval: $* = \*STDERR; print $*foo
16:33 p5eval nwc10: foo1
16:33 nwc10 where did that 1 come from?
16:33 jnthn return value of print
16:33 nwc10 p5eval: print 1
16:33 p5eval nwc10: 11
16:33 isBEKaml nwc10: eval thingy return value.
16:33 nwc10 p5eval: print "1\n"
16:33 p5eval nwc10: 11
16:33 nwc10 p5eval: print "hello world Newline!\n"
16:33 p5eval nwc10: hello world Newline!1
16:34 isBEKaml p5eval: "Hello World!\n";
16:34 p5eval isBEKaml: Hello World!
16:34 huf p5eval: print "things"; ''
16:34 p5eval huf: things
16:34 nwc10 ah
16:34 huf le trick.
16:34 nwc10 p5eval: $* = \*STDERR; print $*foo;
16:34 p5eval nwc10: foo1
16:34 nwc10 anyway. I'll go back to torturing the perl 5 parser
16:35 isBEKaml .tell masak, 1600-2000 hrs UTC sounds alright to me, though I'm not sure I can last the entire session. Thanks for doing the workshop!
16:35 yoleaux isBEKaml: I'll pass your message to masak,.
16:35 masak isBEKaml: :)
16:35 isBEKaml yoleaux: you're bad at passing messages.
16:36 masak consider the message received, though.
16:36 huf :)
16:36 isBEKaml masak: :)
16:36 masak isBEKaml: if I remember correctly where you live, your TZ and Heather's should be about the same.
16:36 huf i bet there's a million jokes about this situation
16:37 isBEKaml masak: If Heather's in UTC+4, I'm about 1.5 hrs east. :)
16:37 * [Coke] remembers an old google maps-style thing where we could record rough locations of developers for parrot, and wonders if such a thing exists today that doesn't involve over sharing
16:37 isBEKaml [Coke]: #haskell too had something like that, I think.
16:38 * [Coke] was excited, until he realized he is utc MINUS 4, and therefore no where near isBEKaml. :)
16:39 isBEKaml [Coke]: lol, we are all on IRC, right? :)
16:39 huf i live on something like utc-4 or so, but the place i live moves on utc+1 :)
16:41 masak if there are both a lot of UTC-plus people and a lot of UTC-minus people, I could deliver the workshop twice that day -- once in my morning for the easterners, and once in my evening for the westerners.
16:41 masak that's definitely an option.
16:41 geekosaur @localtime
16:41 geekosaur oh, lb doesnt hang here any more
16:42 masak thankfully :)
16:42 isBEKaml masak++ # more practice, more tuning! but we easterners are the guinea pigs :)
16:42 masak (turns out lambdabot wasn't very compatible with a channel about a language with variables with the @ sigil) :P
16:43 masak I'll only deliver it twice if there are enough signups from both hemispheres, mind.
16:43 isBEKaml quick people, overwhelm masak! :P
16:43 geekosaur in any case it's just /ctcp time :p
16:44 sjohnson joined #perl6
16:44 masak sjohnson! \o/
16:45 sjohnson :3
16:45 sjohnson hello masak, long time no see
16:45 masak indeed!
16:45 masak sjohnson: we're talking about a Perl 6 workshop. would you be interested?
16:46 SamuraiJack joined #perl6
16:46 sjohnson where would it be located?
16:46 isBEKaml masak: will there be channel logs?
16:49 dalek nqp-jvm-prep: a51b6a4 | jnthn++ | / (2 files):
16:49 dalek nqp-jvm-prep: Basic code-gen support for invokedynamic.
16:49 dalek nqp-jvm-prep: review: https://github.com/jnthn/nqp-jvm-prep/commit/a51b6a410b
16:49 dalek nqp-jvm-prep: 36b6176 | jnthn++ | / (2 files):
16:49 dalek nqp-jvm-prep: Start using invokedynamic for wval lookups.
16:49 dalek nqp-jvm-prep:
16:49 dalek nqp-jvm-prep: This uses the invokedynamic bootstrap mechanism to install a resolver
16:49 dalek nqp-jvm-prep: for the first time the WVal is needed, doing the hash and index lookup
16:49 dalek nqp-jvm-prep: once and then using the resolved object. In theory, this tells the JVM
16:49 dalek nqp-jvm-prep: enough to make WVals be JITted like static data after a first lookup.
16:49 dalek nqp-jvm-prep: review: https://github.com/jnthn/nqp-jvm-prep/commit/36b61769c2
16:49 masak isBEKaml: moritz++ says yes.
16:49 isBEKaml jnthn: invokedynamic already? are you targetting jdk7? :)
16:49 masak sjohnson: in a channel close to this one.
16:49 isBEKaml masak: awesome! moritz++
16:50 jnthn isBEKaml: Yeah. That is the very first usage of it, not even for calls but just for wval lookups. It's the Simplest Possible Useful Thing I can do with invokedynamic, which suits me well for the first thing :)
16:50 jnthn isBEKaml: Beyond this I plan to start using it for calls.
16:51 isBEKaml jnthn: cool, delegates, dispatch? :)
16:51 sjohnson masak: oh. sure.
16:51 jnthn Guess I'll do sub calls first.
16:51 jnthn Then look into method invocation.
16:51 isBEKaml jnthn++
16:51 isBEKaml jnthn: I've been out of tune with nqp-jvm tasks and some amount of moe. :(
16:51 jnthn It'd be really cool to find a way to integrate it with multiple dispatch too, but I need a bit more thinking time to work that one out.
16:53 isBEKaml jnthn: I think jruby had those implemented in terms of invokedynamic.
16:53 jnthn Yes, the jRuby source was what finally made me understand how you do Useful Stuff with invokedynamic :)
16:54 isBEKaml jnthn: that's nice, steal from the best and make ours even better than them! :)
16:55 PacoAir joined #perl6
16:56 spider-mario joined #perl6
17:01 tadzik felher: I envy you for the finished bachelor :)
17:01 lizmat should make spectest of rakudo be clean or not?
17:02 tadzik more-less ;)
17:03 lizmat so a failing test because "\c[LINE FEED]" doesn't even compile, should be ok?
17:03 lizmat rn: "\c[LINE FEED]"
17:03 p6eval niecza v24-35-g5c06e28: OUTPUT«[31m===[0mSORRY![31m===[0m��Unrecognized character name LINE FEED at /tmp/f2insbnQu3 line 1:�------> [32m"\c[LINE FEED[33m�[31m]"[0m��Unhandled exception: Check failed��  at /home/p6eval/niecza/boot/lib/CORE.setting line 1443 (die @ 5) �  at /home/…
17:03 p6eval ..rakudo 5adc4d: OUTPUT«[31m===[0mSORRY![31m===[0m�Unrecognized character name LINE FEED�at /tmp/8cAFzcnKEi:1�------> [32m"\c[LINE FEED[33m�[31m]"[0m�»
17:04 felher tadzik: Why envy? :)
17:04 nwc10 lizmat: I've got some perl 5 code (and C code) which can do all those lookups using only about 300K of data
17:04 nwc10 including aliases such as "LINE FEED"
17:05 lizmat aka, an ICU lib replacement ?
17:05 nwc10 aliaes are easy. 300K is not
17:05 nwc10 not an ICU replacement. At all
17:05 nwc10 just name->code point lookup
17:05 lizmat ack
17:05 lizmat a subset of ICU
17:05 nwc10 not a subset. A one trick pony :-)
17:05 tadzik felher: I'm going through this now, and it's happening to be a little bit of a PITA
17:06 lizmat nwc10: aha, ok
17:06 lizmat something to integrate into nqp perhaps ?
17:09 [Coke] lizmat: is your rakudo linked to ICU?
17:09 lizmat I thought it was, but am not sure anymore
17:09 masak sjohnson: cool! how does May 1 sound?
17:09 felher tadzik: (After looking up PITA) yeah. Especially the last semester was quite stressful. But it was worth the effort :) I wish you the best of luck for your (computer science?) bachelor :)
17:09 felher tadzik: in which semester are you?
17:10 [Coke] lizmat: so, might be a test that needs ICU but isn't marked as such.
17:10 jnthn shop, dinner, etc &
17:10 [Coke] which test?
17:10 tadzik felher: yeah, CS, and the last semester
17:10 tadzik felher: I hope I won't end up delaying it more than half a year :P
17:11 lizmat [Coke]: t/spec/S02-literals/char-by-name.rakudo
17:11 bbkr joined #perl6
17:12 sjohnson masak: sure
17:14 isBEKaml masak: May 1 sounds good to me too.
17:15 tadzik first of may, first of may
17:15 tadzik outdoor... hacking starts today
17:15 gtodd :)
17:15 isBEKaml rappertadzik
17:15 * [Coke] thanks tadzik for cleaning that up
17:15 tadzik I altered original Coulton's lyrics a bit :P
17:15 felher tadzik: Well, while 6 semesters is the official usual duration of a bachelor of CS here, most of us here do it in 7 semesters. Nothing wrong with taking one semester more :)
17:16 * lizmat wonders how one can attend masak's Perl6 workshop
17:16 tadzik felher: it's normally 7 semesters here, then another 3 for a magister, for a total of 5 years
17:16 tadzik it's my 7th semester now, but they shouldn't sack me unless I delay it more than 2 years ;P
17:16 tadzik congrats on finishing it :)
17:16 gtodd are there any thought about what might consistitute a sort of almost default per6  GUI toolkit ?
17:17 [Coke] lizmat: it's marked as needing ICU.
17:17 tadzik gtk was the first one seriously running, I think
17:17 felher tadzik: thanks :) I'll hope you get it done without needing four extra semesters ;)
17:17 gtodd a la perl/tk except updated so it's really just a WebUI
17:18 gtodd tadzik: ah ok ... I thought maybe it would be bundled with it but be some revolutionary thing :)
17:18 [Coke] then pick mojo6 and we can run things locally via morbo.
17:18 gtodd [Coke]: yeah like that
17:18 [Coke] gtodd: there's enough revolution going on. we don't need to look for trouble.
17:18 gtodd haha :)
17:18 hoelzro ahoy #perl6
17:19 isBEKaml holazro!
17:19 gtodd maybe one day some version of perl6 will just tell parrot or whatever "render this in some SVG HTML5 way .."
17:20 tadzik hai hoelzro!
17:21 tadzik gtodd: I was pondering a thought of something DBI-ish, which abstracts the actual toolkit used and provides a common API for all of them
17:21 dmol joined #perl6
17:24 gtodd tadzik: interesting ... I thought there was once a "pure perl" GUI ... that allowed for quick plotting etc. that sort of did the same thing ... kind of like how "R" does dev(jpg|png|opengl|svg|web)
17:24 tadzik gtodd: Prima, maybe?
17:24 gtodd ok maybe "R" doesn't do opengl
17:25 isBEKaml tadzik: I'll be interested to see if you succeed. GUI frameworks currently are a mess of API. :|
17:25 gtodd tadzik: yeah ! I was thinking primo or something like that
17:26 snuffles joined #perl6
17:26 tadzik isBEKaml: well, db's have a common SQL. GUI toolkits have a common...nothing
17:26 gtodd I guess "R" is sort of a console with various graphic plotting methods so comparing it to a full on tool kit for writing applications is probably wrong ...
17:27 isBEKaml tadzik: exactly my point.
17:27 tadzik fundamental things like layouts or callbacks are completely different between, say, gtk and qt
17:27 bruges joined #perl6
17:27 tadzik qt distinguishes between widgets and layouts, gtk doesn't
17:27 gtodd but I'm just thinking of how perl6 could be sort of out of the box outfitted to do different kinds of graphic output not so much a toolkit
17:27 tadzik gtk uses regular callbacks, qt invents signals and slots
17:27 isBEKaml tadzik: so if you succeed in unifying them all into a common layer of an interface, that'll be a huge deal.
17:27 tadzik yeah
17:28 tadzik it'll probably end up nothing like either :P
17:28 isBEKaml tadzik: so far, I loved qt. GTK was a mess that I couldn't even get past hello world without some jumping around the steaming kettle. :D
17:29 gtodd I installed what used to be a fairly simple application ipython for someone to do math plotting etc ... and 20-30 packages were installed !
17:29 isBEKaml tadzik: I never tried any other frameworks, so my experience is little-to-nothing here.
17:29 tadzik isBEKaml: well, I found gtk simple and sane and Qt full of NIH
17:30 tadzik let's have our own EVERYTHING!
17:30 tadzik of course I'm exaggarating
17:30 gtodd Samsung seems to be building/supporting enlightenment's ETK
17:30 tadzik or however you write that
17:30 isBEKaml tadzik: heh - we'll turn the jungle by counting the leaves.
17:30 tadzik ayes :)
17:31 tadzik so yeah, that's a tricky business
17:31 gtodd which seems relatively small, featureful, nicely licensed ...
17:32 isBEKaml so keep counting, I'll watch. :P
17:33 tadzik I think this will eventually turn into the "a new standard" situation
17:33 gtodd I guess the set of features I'm interested in are more plotting PDL-ish instead of GUI application development toolkits
17:33 tadzik oh, you may like Math::Model and SVG::Plot
17:34 gtodd :)
17:34 isBEKaml gtodd: PDL? Is Rakudo in a state we can freely call into C/C++ libs?
17:34 gtodd isBEKaml: don't think so
17:34 isBEKaml gtodd: or fortran. :)
17:34 tadzik I do think so
17:34 tadzik C should be alright
17:36 masak lizmat: how to attend: that's a good question. maybe I should have some way to sign up.
17:36 lizmat masak: is it IRL or not?
17:36 gtodd tadzik: I imagine someone could use the *ahem* future new perl6 standard replacement for CGI.pm (dancer mojo plack??) to make something like the julia-lang console in SVG
17:36 isBEKaml lizmat: IVL.
17:37 * lizmat wouldn't mind driving up to Malmö
17:37 gtodd tadzik: js etc
17:37 masak lizmat: no, it's solely on IRC.
17:37 isBEKaml lizmat: or ITL. (this is over IRC)
17:37 lizmat ack, ok
17:37 lizmat no travelling necessary then  :-)
17:37 masak but I'm now at the point where I'd like to collab over a participants list.
17:38 lizmat fwiw, it's in my agenda now  :-)
17:38 _sri gtodd: trivial, canvas is more popular for that kinda stuff atm though
17:38 masak does anyone know a no-frills online public document editing system?
17:38 masak so that people can easily sign themselves up.
17:39 lizmat wouldnt a wiki be enough?
17:40 [Coke] masak: docs.google.com
17:40 lizmat one needs a google login for that, no?
17:40 gtodd _sri: yeah ... I guess when I'm thinking of something like a "defauilt" plotting surface it's a canvas
17:40 [Coke] masak: the catchall git repo for perl6.
17:40 isBEKaml lizmat: it is possible to make it anon edits too, that is no login necessary.
17:40 [Coke] lizmat: yes.
17:40 tadzik masak: doodle.com
17:40 masak https://github.com/perl6/mu/wiki/perl6-workshop-may-2013
17:40 [Coke] ah, even better.
17:40 masak people! sign up!
17:41 tadzik that's super-useful for this sort of stuff imo
17:41 * [Coke] notes that github editing sucks for co-temporal edits.
17:42 dalek perl6-roast-data: 040ecd5 | coke++ | / (3 files):
17:42 dalek perl6-roast-data: today (automated commit)
17:42 dalek perl6-roast-data: review: https://github.com/coke/perl6-roast-data/commit/040ecd5b24
17:43 masak [Coke]: I changed you from "potential" to "audience". might be a safe category for more people.
17:45 isBEKaml masak: you forgot Heather
17:45 masak isBEKaml: and a few others who said yes before we settled on a date.
17:45 isBEKaml masak: ah, okay
17:46 masak I'll ask her on twitter.
17:49 masak vaelxon: ping
17:49 masak timotimo: ping
17:49 masak TimToady_: ping
17:52 [Coke] masak: ok. to me, audience sounds like more of a commitment than I am willing to make, but I defer to your judgement.
17:53 isBEKaml [Coke]: audience is no commitment, it's drive-by assault. :P
17:57 masak [Coke]: I understand. I'm mostly trying to create a category of people who answer "maybe" to the question of whether to participate.
17:57 masak (because that's not much more informative than what I already had)
17:58 BigBear joined #perl6
18:09 gtodd heh if one googles for perl and linenoise (as in linenoise as replacment for readline) you see a lot of complaints about perl's syntax
18:10 masak gtodd: Perl is occasionally ugly. but if you ask me, that's more a statement about the author of the code than about the language.
18:11 masak gtodd: regardless of the language I'm in, and regardless of the *size* or *lifetime* of the thing I'm writing, I spend quite a bit of time making things readable.
18:11 masak gtodd: compared to other languages, Perl 5 and Perl 6 give me more knobs to twiddle to make things the way I prefer them.
18:11 masak gtodd: it's only people who are not aware of those knobs (or who don't care enough about them) that will write ugly code.
18:11 masak hope that makes sense.
18:12 gtodd masak:  agreed it feels more like a real "language" to me (but I'm not a real programmer). Maybe perl6 should build and ship linenoise instead of readline so people can feign misunderstanding of the criticism... "yes perl comes with linenoise"
18:12 nyuszika7h_ joined #perl6
18:13 hoelzro a linenoise binding would be easy to write
18:13 hoelzro with NativeCall
18:13 gtodd it's just down the street on github ;-)
18:13 PerlJam masak: you should contrast with python where the code may *look* "pretty" but could be incomprehensible and you wouldn't be able to tell at a glance whereas with perl, it's easy to see :)
18:13 * hoelzro is working on POSIX bindings, with interesting results
18:14 masak PerlJam: yeah. I'd say Python pushes everything into the middle of the bell curve, making everything look the same. possibly prettier/more readable on average, but the brilliant bits are less brilliant.
18:15 gtodd hoelzro: cool ... I'd rather perl's REPL came with linenoise (or libedit or whatever but linenoise is small) and required me to install readline and friends  ... :)
18:15 PerlJam yes, that's an excellent way to put it.
18:15 * [Coke] wonders what linenoise is.
18:15 xilo joined #perl6
18:15 gtodd https://github.com/antirez/linenoise
18:15 gtodd :-)
18:17 gtodd just a minimalist terminal/line editing library ... I think it forces an assumption of vt100
18:18 [Coke] gtodd: seems like a decent parrot project - add it to the probe when trying to find readline.
18:18 Heather joined #perl6
18:18 Heather masak hey
18:18 Heather thank you for invite
18:19 masak \o/
18:19 masak Heather: just remembered that you were one of the original interested ones.
18:19 Heather =)
18:20 dmol joined #perl6
18:20 Heather masak well what's happening here? in nutshell
18:21 gtodd [Coke]: whoa .. that could work
18:21 masak Heather: in the workshop? we spend four hours talking about interesting programming topics, how to become a better coder, how to make your code shine, and we experiement a lot with runnin Perl 6 code.
18:21 colomon masak++
18:21 masak Heather: all the participants will do some simple tasks.
18:22 frdmn joined #perl6
18:25 dakkar joined #perl6
18:34 tadzik let's maybe employ play-perl
18:34 masak no, strike "simple". the tasks will be challenging-ish for newcomers and more experienced coders alike. :)
18:35 masak tadzik: tell me more.
18:35 tadzik masak: http://play-perl.org/player/tadzik
18:35 tadzik it's a collaborative todo thing
18:35 tadzik people Like my tasks, and I get karma if I complete them
18:35 japhb_ joined #perl6
18:36 masak tadzik: sounds good. if you meant for there to be a connection to the workshop though, I think you have to spell it out. :)
18:36 tadzik hm
18:37 tadzik I think 3rd party can also complete the tasks
18:37 tadzik so people may complete workshop exercises to get karma
18:37 tadzik or something :
18:38 masak I plan to publish the tasks on the day of the workshop, so anyone can do them, participant or not, then or later.
18:38 masak I... I don't feel a need to do things through a 3rd-party TODO list... :)
18:38 tadzik :)
18:38 tadzik I know, that's probably overkill
18:38 masak especially as that would be One More Dependency, and one more thing for people to sign up to, for little reward.
18:38 tadzik ah, sure
18:39 masak the idea as such is interesting. just maybe not applicable for the workshop format.
18:41 FROGGS .ask jnthn if I am allowed to push that https://gist.github.com/FROGGS/5fe2eb96e2515bf02a14 (would make collab easier)
18:41 yoleaux FROGGS: I'll pass your message to jnthn.
18:42 tgt joined #perl6
18:45 sqirrel joined #perl6
18:46 domidumont joined #perl6
18:48 fgomez joined #perl6
18:51 \\fade joined #perl6
18:56 gabriel_ joined #perl6
19:00 Heather masak when it will start?
19:00 Heather ah sorry there is date time
19:01 Heather I can't parse it : T16:00Z
19:01 moritz 4pm in UTC timezone
19:01 Celelibi joined #perl6
19:02 Heather moritz is Txx:xxZ standard format for writing UTC time?
19:02 masak yes.
19:02 masak Heather: what's your time zone, ooc? UTC+4 ?
19:02 moritz Heather: it's ISO 8601 format
19:02 Heather masak UTC+4 , right
19:04 Heather then it will be 20->24 for me, not that good time I can't guarantee if I will be in
19:06 FROGGS masak: you are talking about an online perl6 course?
19:06 FROGGS a 'webinar'
19:06 masak FROGGS: yes.
19:07 FROGGS that's cool :o)
19:07 masak FROGGS: see https://github.com/perl6/mu/wiki/perl6-workshop-may-2013
19:07 masak Heather: would it help you if I moved the starting time from 16:00 UTC to 14:00 UTC?
19:08 masak that would still be workable for most US people, I think.
19:08 Heather masak well 16 is even better
19:09 Heather well it's not that bad time... ideal time will be something alike 9:00 UTC
19:09 crab2313 joined #perl6
19:10 Heather But I understand that it could affect other people
19:10 jnthn FROGGS: Is there a reason not to parse <version> and then have a if ~$<version><vnum>[0] eq '5' { ...the load stuff... } ?
19:10 yoleaux 18:41Z <FROGGS> jnthn: if I am allowed to push that https://gist.github.com/FROGGS/5fe2eb96e2515bf02a14 (would make collab easier)
19:11 FROGGS jnthn: within the actions?
19:11 jnthn FROGGS: No, right there in the grammar
19:11 jnthn FROGGS: At the moment you parse a normal version number, then check it's not 5
19:11 jnthn FROGGS: Why not just put a block instead of an assertion after the <version>, see if it is 5, and do the loading?
19:12 jnthn FROGGS: Then we always parse <version> and just take action based on what is seen
19:12 FROGGS jnthn: ahh, now I know what you mean
19:12 FROGGS jnthn: I did it this way because version have to start with a 'v'
19:13 FROGGS and to be able to parse old-schools 'use 5.10', I made the 'v' optional
19:13 Heather I still think that perl6 needs something for building native image (jit)
19:13 Heather I can distribute scripts that easy w/o it
19:14 FROGGS Heather: what is 'native image'?
19:14 fgomez joined #perl6
19:14 Heather FROGGS machine code
19:14 jnthn std: use 5.10;
19:14 p6eval std 86b102f: OUTPUT«[31m===[0mSORRY![31m===[0m�Confused at /tmp/igDBTT2w4m line 1:�------> [32muse [33m�[31m5.10;[0m�    expecting any of:�     module_name�    version�Parse failed�FAILED 00:00 40m�»
19:15 FROGGS std: use 6; # should work
19:15 p6eval std 86b102f: OUTPUT«[31m===[0mSORRY![31m===[0m�Confused at /tmp/x237qmurAZ line 1:�------> [32muse [33m�[31m6; # should work[0m�    expecting any of:�  module_name�    version�Parse failed�FAILED 00:00 40m�»
19:15 FROGGS ohh, wait
19:15 FROGGS std: 6; # this should turn on lax mode
19:15 p6eval std 86b102f: OUTPUT«ok 00:00 41m␤»
19:15 FROGGS IIRC
19:16 FROGGS jnthn: I know that std does not allow 'use 5.10', but fiddling with hundrets/thousands of cpan-modules is rather a task for 10  years
19:17 FROGGS .... that's why we should special-case the use of peril 5
19:18 jnthn FROGGS: If we're using a Perl 5 module, should the use statement not carry it (use Foo:from<perl5>)?
19:19 lizmat jnthn: only if "use" is called in a perl6 environment, I would say
19:19 lizmat after a "use v5", "use Foo:from<perl5>;" would be a syntax error, no?
19:20 FROGGS right, but I guess after 'use v5' you will only load Perl5 modules
19:20 jnthn lizmat: Sure, but even then we know to interpret the use as a "use a Perl 5 module", so there's not am ambiguity.
19:22 FROGGS jnthn: I was hoping to support: bash~$  perl6 old_perl5_script.pl, without the need to change it at all
19:22 jnthn I think I'm fine with the change going in to make "use v5" work, but less comfortable with making "use 5.10" style things happen without somebody like TimToady weighing in.
19:22 FROGGS k
19:22 anocelot I'd still lobby for "abuse v5"  ^.^
19:22 jnthn FROGGS: How many scripts actually start with a "use 5.10" style thing? :)
19:23 FROGGS well *cough*, errrmmmm
19:23 lizmat jnthn: many, as they are needed to activate features such as "say"
19:23 FROGGS I tend to 'use feature qw(say switch)'
19:24 * lizmat tends to "use 5.14"  :-)
19:24 flussence I put "use 5.016" just to be a jerk
19:24 FROGGS hehe
19:25 FROGGS flussence: a Perl joke, nice :o)
19:26 flussence though 99% of the time that stuff I write is for a tightly controlled perlbrew env anyway, so I may as well use everything on offer
19:26 lizmat argh, indeed "use 5.014"  :-)
19:26 flussence (even though I don't *actually* use anything added since v5.12ish...)
19:28 Heather good night #perl6 :)
19:29 lizmat jnthn: I think when the spec for "use v5" was written, there was only one good Perl 5 around (even pre 5.6, I would think)
19:30 lizmat since then, with "use 5.N" activating specific features, there is now much more code with "use 5.N" around then we had around the time the spec was written
19:31 tgt joined #perl6
19:37 arcterus joined #perl6
19:44 fgomez joined #perl6
19:47 lizmat rn: say 10.rand.perl
19:47 p6eval niecza v24-35-g5c06e28: OUTPUT«0.675530527101611e0␤»
19:47 p6eval ..rakudo 5adc4d: OUTPUT«7.38955708543898e0␤»
19:48 lizmat shouldn't that be "10.rand" ?
19:48 colomon lizmat: why?
19:48 lizmat seems wrong to me that this is constant folded
19:49 colomon lizmat: it's not
19:49 colomon rn: say (10.rand).perl
19:49 p6eval niecza v24-35-g5c06e28: OUTPUT«4.8859148448733212e0␤»
19:49 p6eval ..rakudo 5adc4d: OUTPUT«3.33404456355737e0␤»
19:49 colomon you asked it to generate a random Num, then take the .perl of it.
19:50 lizmat $ perl -MO=Deparse -E 'rand 10'
19:50 lizmat rand 10;
19:50 moritz deparse != .perl
19:51 moritz the correct comparison would be   perl -MData::Dumper -E 'print Dumper rand 10'
19:51 lizmat aha, ok
19:51 * lizmat adjusts mind
19:52 moritz rakudo doesn't have anything depars-y yet
19:53 moritz the fairest comparison might be perl -MO=Concise <prog>   compared to  perl6 --taget=ast <prog>
19:55 FROGGS *--target
19:55 berekuk joined #perl6
19:56 moritz ah yes, thanks
19:59 xilo joined #perl6
20:02 masak moritz++ # Dumper/.perl != Deparse
20:02 masak moritz: though Dumper can be made to deparse subrefs, with the appropriate options.
20:03 * lizmat wonders whether ".perl" shouldn't really be called ".lave"
20:03 lizmat but only for a short moment
20:08 labster joined #perl6
20:12 rjbs Booooo. :)
20:14 labster masak: I would like to attend your workshop.  UTC-7 geographically, though I personally am closer to UTC-10.  But I can do normal people hours, for the workshop.
20:15 masak labster: ok, adding you.
20:16 masak 7 people. cool! :)
20:23 pjcj joined #perl6
20:24 fgomez joined #perl6
20:27 lizmat std: my Buf $x; say $x ~< 1
20:27 p6eval std 86b102f: OUTPUT«ok 00:00 43m␤»
20:27 lizmat rn: my Buf $x; say $x ~< 1
20:27 p6eval niecza v24-35-g5c06e28: OUTPUT«Unhandled exception: Buffer bitops NYI␤  at /home/p6eval/niecza/lib/CORE.setting line 1504 (die @ 5) ␤  at /home/p6eval/niecza/lib/CORE.setting line 3426 (infix:<~<> @ 4) ␤  at /tmp/Kx3TqpwaSx line 1 (mainline @ 4) ␤  at /home/p6eval/niecza/lib/CORE.settin…
20:27 p6eval ..rakudo 5adc4d: OUTPUT«[31m===[0mSORRY![31m===[0m�Unable to parse expression in quote words; couldn't find final '>'�at /tmp/8uNJj4pRtV:1�------> [32mmy Buf $x; say $x ~< 1[33m�[31m<EOL>[0m�    expecting any of:�        postfix�        infix stopper�        infix or meta-infix�  Ã¢â‚¬Â¦
20:27 pjcj joined #perl6
20:27 lizmat I guess the niecza error message is more informative  :-)
20:31 dalek nqp-jvm-prep: 02bb9ef | jnthn++ | src/org/perl6/nqp/ (2 files):
20:31 dalek nqp-jvm-prep: Enable inlining of P6bigint into P6opaque.
20:31 dalek nqp-jvm-prep:
20:31 dalek nqp-jvm-prep: A tad cheaty, but will handle Perl 6's needs, which is The Goal. Up to
20:31 dalek nqp-jvm-prep: 20 out of 36 passing in 60-bigint.t with this.
20:31 dalek nqp-jvm-prep: review: https://github.com/jnthn/nqp-jvm-prep/commit/02bb9efa5c
20:31 colomon \o/
20:41 * jnthn tries to make sense of nqp::pow_I
20:44 [Coke] instead of .lave, could we call it .blave? (he said, bluffing.)
21:10 dalek nqp-jvm-prep: bccc2af | jnthn++ | src/org/perl6/nqp/sixmodel/reprs/P6bigint.java:
21:10 dalek nqp-jvm-prep: Fix incorrect import.
21:10 dalek nqp-jvm-prep: review: https://github.com/jnthn/nqp-jvm-prep/commit/bccc2af2f3
21:10 dalek nqp-jvm-prep: 54104a2 | jnthn++ | / (2 files):
21:10 dalek nqp-jvm-prep: Implement pow_I.
21:10 dalek nqp-jvm-prep: review: https://github.com/jnthn/nqp-jvm-prep/commit/54104a2c87
21:13 arnsholt jnthn: Looks like you were able to make sense of it =)
21:13 jnthn Yeah, I think I got it. :)
21:14 jnthn Those more mathematically knowledgable than I are most welcome to review it :)
21:14 masak looks nice :)
21:15 arnsholt "Overflows integer. Terrifyingly huge, but try to cope somehow." =)
21:15 masak basically, you're finding all the special cases, and then delegating to Math.pow :)
21:16 arnsholt jnthn: The second "base.compareTo(BigInteger.ONE) == 0" is superfluous, isn't it?
21:16 arnsholt It'll always be false, since the first if clause will always catch base == 1
21:17 jnthn oh...
21:17 colomon errr, all the logic is duplicated, no?
21:17 jnthn Then I guess the original code in Parrot is also redundant there too
21:18 arnsholt Or, at least that's what it looks like to me
21:18 jnthn colomon: It's as faithful a translation of nqp_bigint_pow as I could do, fwiw. :)
21:18 arnsholt I could be mistaken, obv =)
21:18 jnthn arnsholt: Yeah, looks like it to me.
21:18 colomon the logic's kind of botched anyway, I think...
21:20 jnthn I can only claim it passes tests :)
21:20 jnthn oh ouch...
21:20 jnthn There's a BigInteger.doubleValue() method
21:20 jnthn But no method for getting from a double to a BigInteger.
21:21 lizmat rn: 1.say && 2.say || 3.say
21:21 p6eval rakudo 5adc4d, niecza v24-35-g5c06e28: OUTPUT«1␤2␤»
21:21 lizmat rn: 1.say && 2.say S|| 3.say
21:21 p6eval rakudo 5adc4d: OUTPUT«1␤2␤3␤No such method 'postcircumfix:<( )>' for invocant of type 'Bool'␤  in block  at /tmp/uLMC7J_Juq:1␤␤»
21:21 p6eval ..niecza v24-35-g5c06e28: OUTPUT«[31m===[0mSORRY![31m===[0m��This macro cannot be used as a function at /tmp/5LsNJ3pUsv line 1:�------> [32m1.say && 2.say S||[33m�[31m 3.say[0m��Unhandled exception: Check failed��  at /home/p6eval/niecza/boot/lib/CORE.setting line 1443 (die @ 5) �…
21:22 jnthn oh...hah. :) BigDecimal.valueOf(num).toBigInteger()
21:22 lizmat S03:4823 states that "The compiler is free to discard any C<S> metaoperator that is provably redundant, such as the one in C<S||>."
21:23 lizmat so is this a bug?
21:23 FROGGS looks like
21:24 jnthn Not sure we ever tried to implement S in Rakudo so far, fwiw
21:24 jnthn Weird error, though
21:24 FROGGS r: say 1 S& 2
21:24 p6eval rakudo 5adc4d: OUTPUT«all()␤»
21:24 dalek nqp-jvm-prep: 4431604 | jnthn++ | / (2 files):
21:24 dalek nqp-jvm-prep: Implement fromnum_I and tonum_I.
21:24 dalek nqp-jvm-prep: review: https://github.com/jnthn/nqp-jvm-prep/commit/4431604bb2
21:25 jnthn 31 out of 36. At this rate I'll have all the test file passing before sleep :)
21:25 lizmat jnthn++
21:25 FROGGS I wish I'd make such progress :/
21:26 FROGGS currently fighting: while ( ) BLOCK continue BLOCK
21:26 colomon rn: say 2 ** 234582349058390583905839058493859438590385903543535345435
21:26 p6eval niecza v24-35-g5c06e28: OUTPUT«(timeout)»
21:26 p6eval ..rakudo 5adc4d: OUTPUT«Inf␤»
21:27 colomon rn: say -2 ** 234582349058390583905839058493859438590385903543535345436
21:27 p6eval niecza v24-35-g5c06e28: OUTPUT«(timeout)»
21:27 p6eval ..rakudo 5adc4d: OUTPUT«-Inf␤»
21:27 colomon ...seems like that should be +Inf, no?
21:28 lizmat maybe the exponent is too large and became an uneven Num ?
21:29 colomon lizmat: should be an even Bigint
21:29 bluescreen10 joined #perl6
21:30 FROGGS wow, Stage parse: 310s for a macosx in a virtualbox
21:30 lizmat rn: say (1.say & 2.say)
21:30 p6eval rakudo 5adc4d: OUTPUT«1␤2␤all(True, True)␤»
21:30 p6eval ..niecza v24-35-g5c06e28: OUTPUT«1␤2␤all(Bool::True, Bool::True)␤»
21:30 lizmat rn: say (1.say S& 2.say)
21:30 p6eval rakudo 5adc4d: OUTPUT«1␤2␤all()␤»
21:30 p6eval ..niecza v24-35-g5c06e28: OUTPUT«1␤2␤all(Bool::True, Bool::True)␤»
21:31 lizmat something is happening with "S&" in rakudo
21:31 masak 'night, #perl6
21:31 colomon \o
21:31 dalek nqp-jvm-prep: 7b74d10 | jnthn++ | / (2 files):
21:31 dalek nqp-jvm-prep: Implement base_I.
21:31 dalek nqp-jvm-prep: review: https://github.com/jnthn/nqp-jvm-prep/commit/7b74d10719
21:31 FROGGS knight masak
21:32 pib1908 joined #perl6
21:33 FROGGS lizmat: I have no idea where the metaops live, all I can say is there is no infix:S&
21:34 lizmat yes, I got that
21:34 * colomon didn't realize anyone had Sop implemented yet
21:34 jnthn Hm, I think it is being parsed...
21:35 jnthn token infix_prefix_meta_operator:sym<S> { <sym> <infixish('S')> {} <O=.copyO($<infixish>)> }
21:35 colomon rn: say (1 S& 2)
21:35 p6eval rakudo 5adc4d: OUTPUT«all()␤»
21:35 p6eval ..niecza v24-35-g5c06e28: OUTPUT«all(1, 2)␤»
21:36 FROGGS lizmat: wrt v5, I have the same issue on my mac
21:37 lizmat FROGGS: ack
21:37 FROGGS lizmat: I can 'use v5' though, and it is picking up Perl5 module
21:38 lizmat but that would mean changing the spectests ?
21:38 FROGGS but the TAP is exactly like yours, so fudge is ignoring the --add_use_v5 for some reason
21:38 lizmat adding 'use v5' to them?
21:38 BigBear jnthn: just came across your perl6-debug screencast, sweet. jnthn++ the simple::poll perl6 code isn't per chance available as a git repo or zip or tarball somewhere? follwoing along woudl make experimenting a litl easier, same for the try and catch sessions. seeing the code in front of me and "playing" with it helps me learn. (in fact it's probably the only way I learned most perl-ish things)
21:39 FROGGS add "use Test;\nuse v5;\n"
21:39 FROGGS but that's basically the job of that fudge script :/
21:39 FROGGS I'll fix it tomorrow morning, bed time now
21:40 BenGoldberg joined #perl6
21:40 BigBear tadzik: sorry I missed your comment today. will try to catch you tomorrow ;-)
21:41 jnthn BigBear: Hm, no repo at the moment, but you can copy-paste the code out of the slides at http://jnthn.net/papers/2012-yapceu-exceptions.pdf
21:42 lizmat gnight FROGGS
21:49 lizmat goodnight #perl6
21:50 colomon \o
21:51 jnthn 'night, lizmat
21:52 dalek nqp-jvm-prep: fab1b73 | jnthn++ | / (2 files):
21:52 dalek nqp-jvm-prep: Implement expmod_I.
21:52 dalek nqp-jvm-prep: review: https://github.com/jnthn/nqp-jvm-prep/commit/fab1b73007
21:52 dalek nqp-jvm-prep: ef13c49 | jnthn++ | / (2 files):
21:52 dalek nqp-jvm-prep: Implement div_In.
21:52 dalek nqp-jvm-prep: review: https://github.com/jnthn/nqp-jvm-prep/commit/ef13c4925d
21:52 dalek nqp-jvm-prep: e9826c5 | jnthn++ | t/nqp/60-bigint.t:
21:52 dalek nqp-jvm-prep: Add fully passing 60-bigint.t.
21:52 dalek nqp-jvm-prep: review: https://github.com/jnthn/nqp-jvm-prep/commit/e9826c5cdb
21:52 colomon \o/
21:53 jnthn I think there's a handful of things that the tests don't cover, but that should be most of the big integer stuff done.
21:54 BenGoldberg Your big integer pow_I is missing a few special cases...
21:55 BenGoldberg When the exponent is positive and even, and the base is neg one, return pos one
21:55 BenGoldberg When the exponent is positive and odd, and the base is neg one, return neg one
21:56 BenGoldberg When the exponent is huge, and the base is less than neg one, return either Inf or -Inf depending on whether the exponent is odd or even
21:57 BenGoldberg When the exponent is negative, and the base is zero, return Inf
22:00 BenGoldberg In that last case, you might want to throw a division by zero, instead.
22:05 jnthn BenGoldberg: Thanks! I don't have the energy to turn that into code/tests tonight, but I put it in a ticket so it isn't forgotten.
22:08 kurahaupo joined #perl6
22:08 kurahaupo good morning @p6
22:09 dalek nqp-jvm-prep: f9b69a1 | jnthn++ | src/org/perl6/nqp/runtime/Ops.java:
22:09 dalek nqp-jvm-prep: Big Integer case of boolification spec.
22:09 dalek nqp-jvm-prep: review: https://github.com/jnthn/nqp-jvm-prep/commit/f9b69a18a2
22:09 dalek nqp-jvm-prep: 493742d | jnthn++ | docs/ROADMAP:
22:09 dalek nqp-jvm-prep: Remove some completed ROADMAP items.
22:09 dalek nqp-jvm-prep: review: https://github.com/jnthn/nqp-jvm-prep/commit/493742d513
22:09 jnthn o/ kurahaupo
22:18 xilo joined #perl6
22:20 jnthn sleep; 'night o/
22:20 diakopter o/
22:33 edgeuplink joined #perl6
22:46 arcterus joined #perl6
22:47 edgeuplink joined #perl6
22:49 census joined #perl6
22:53 skids joined #perl6
23:02 arcterus joined #perl6
23:13 japhb_ Did someone succeed in implementing a Perl 6 Grammar for C?
23:16 raiph http://irclog.perlgeek.de/perl6/2013-03-29#i_6643290
23:18 raiph japb_: c11 parser with grammar: https://gist.github.com/andydude/5268163
23:19 raiph japhb_: ^^
23:29 japhb_ raiph, oh very cool.
23:37 raiph japhb_: yeah, adu++
23:38 raiph why were you asking about it?
23:38 japhb_ Is the intent of 'has $foo;' that $foo have no type constraint (Mu, effectively), or that it be implicitly 'has Any $foo;' ... because Rakudo does not seem to be enforcing that (at least not in the code I'm looking at).
23:39 raiph i think the default is supposed to be Any
23:40 raiph (Any)
23:41 japhb_ raiph, As for C grammar, because I was thinking about parsing some C headers into NativeCall bindings.  :-)
23:41 japhb_ r: class Foo { has $.foo; method new($v) { $!foo = $v } }; Foo.new(Mu);
23:41 p6eval rakudo 5adc4d: OUTPUT«Nominal type check failed for parameter '$v'; expected Any but got Mu instead␤  in method new at /tmp/tSz6xgw5Zt:1␤  in block  at /tmp/tSz6xgw5Zt:1␤␤»
23:41 japhb_ OK, that way worked.  Hmmm.
23:42 japhb_ r: class Foo { has $.foo; method new(Mu \v) { $!foo = v } }; Foo.new(Mu);
23:42 p6eval rakudo 5adc4d: OUTPUT«Cannot look up attributes in a type object␤  in method new at /tmp/LZzbOpwtdc:1␤  in block  at /tmp/LZzbOpwtdc:1␤␤»
23:44 japhb_ r: class Foo { has $.foo; method new(Mu $v) { nqp::create(self).BUILD($v) }; method BUILD(Mu \v) { $!foo = v } }; Foo.new(Mu);
23:44 p6eval rakudo 5adc4d:  ( no output )
23:44 japhb_ Ah-ha!
23:45 japhb_ r: class Foo { has $.foo; method new(Mu $v) { nqp::create(self).BUILD($v) }; method BUILD(Mu $v) { $!foo = $v } }; Foo.new(Mu);
23:45 p6eval rakudo 5adc4d:  ( no output )
23:45 Psyche^ joined #perl6
23:45 japhb_ r: class Foo { has $.foo; method BUILD(Mu $!foo) { } }; Foo.new(Mu);
23:45 p6eval rakudo 5adc4d: OUTPUT«Cannot call 'new'; none of these signatures match:␤:(Mu : *%attrinit)␤:(Mu : , , Mu *%_)␤  in method new at src/gen/CORE.setting:726␤  in block  at /tmp/DpxJtJMbOE:1␤␤»
23:46 raiph ++japhb # thinking about a lazy impatient way to make boatloads of C libs available
23:46 japhb_ r: class Foo { has $.foo; method BUILD(Mu :$!foo) { } }; Foo.new(:foo(Mu));
23:46 p6eval rakudo 5adc4d:  ( no output )
23:46 japhb_ r: class Foo { has $.foo; method BUILD(:$!foo) { } }; Foo.new(:foo(Mu));
23:46 p6eval rakudo 5adc4d: OUTPUT«Nominal type check failed for parameter '$!foo'; expected Any but got Mu instead␤  in method BUILD at /tmp/hGS4NruKnN:1␤  in method BUILDALL at src/gen/CORE.setting:759␤  in method bless at src/gen/CORE.setting:743␤  in method new at src/gen/CORE.setting:728␤  in m…
23:47 japhb_ OK, so it looks like it's BUILD that has to enforce the type checking during instance construction ....
23:48 japhb_ r: class Foo { has Any $.foo; method BUILD(:$!foo) { } }; Foo.new(:foo(Mu));
23:48 p6eval rakudo 5adc4d: OUTPUT«Nominal type check failed for parameter '$!foo'; expected Any but got Mu instead␤  in method BUILD at /tmp/cI2gHNaDqy:1␤  in method BUILDALL at src/gen/CORE.setting:759␤  in method bless at src/gen/CORE.setting:743␤  in method new at src/gen/CORE.setting:728␤  in m…
23:48 japhb_ r: class Foo { has Any $.foo; method BUILD(Mu :$!foo) { } }; Foo.new(:foo(Mu));
23:48 p6eval rakudo 5adc4d: OUTPUT«Nominal type check failed for parameter '$got'; expected Any but got Mu instead␤  in method BUILD at /tmp/1Yuu6mAyPJ:1␤  in method BUILDALL at src/gen/CORE.setting:759␤  in method bless at src/gen/CORE.setting:743␤  in method new at src/gen/CORE.setting:728␤  in me…
23:49 japhb_ ... and it looks like I was right, the 'has $.foo' type stricture is weaker than Any.
23:50 raiph hmm
23:51 japhb_ (At least as Rakudo implements it.)
23:53 BenGoldberg How hard would it be to implement a grammer or two to convert lex and yacc into perl6 grammers?
23:54 BenGoldberg Then, you could use existing C language grammars
23:56 diakopter that's a cool idea
23:56 diakopter but since those languages include C....
23:56 japhb_ BenGoldberg, there is an assumption in yacc's grammar that you are going to be compiling it to C, but you might be able to just ignore the C embedding.
23:58 japhb_ .oO( How do I safely iterate a VM-level hash that may contain unmarshallable values? )
23:59 japhb_ EDUMPISHARD
23:59 diakopter ETRYALAXATIVE
23:59 japhb_ ewww.

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

Perl 6 | Reference Documentation | Rakudo