»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, std:, or /msg camelia p6: ... | irclog: irc.perl6.org | UTF-8 is our friend!
Set by masak on 12 May 2015.
00:02 RabidGravy left
dalek kudo-star-daily: dff0e2b | coke++ | log/ (2 files):
today (automated commit)
00:02
kudo-star-daily: 5f2c73d | coke++ | log/ (3 files):
today (automated commit)
rl6-roast-data: 5f3ad9f | coke++ | / (9 files):
today (automated commit)
rl6-roast-data: 127b5dc | coke++ | / (9 files):
today (automated commit)
MadcapJake Curious what everyone feels about sigil and twigil syntax highlighting. I've been experimenting with having my language-perl6fe only highlighting the sigil and twigil (and differently for each too). Check out an example and cast your vote twitter.com/MadcapJake/status/6660...2228149251 00:07
zengargoyle i'm used to vim which highlights sigil and var but not twigil 00:13
00:13 Sqirrel joined
zengargoyle makes vars look like vars and twigil'd things look special 00:13
yikes. rakudobrew'd panda barfs: Unhandled exception: Missing or wrong version of dependency 'gen/moar/stage2/QRegex.nqp' (from 'src/Perl6/Pod.nqp') 00:17
even after rakudobrew nuke moar; rakudobrew build moar; rakudobrew build panda 00:18
00:21 raiph joined 00:30 xpen joined
zengargoyle think i mucked up git_reference 00:30
00:30 Sqirrel left 00:34 xpen left 00:46 Ven joined 00:51 Ven left 00:52 sprocket joined
arnsholt Progress! 01:02
01:06 colomon joined 01:10 yeahnoob joined, tokuhiro_ joined
MadcapJake zengargoyle: ok, that's good to know. I could just stick with the vim precedent. Take a look at the example I posted in that link, it's actually not too noisy (to me) and I might like being a bit different (since this is the Fun Edition™). Also, another reason for this change is that I think there is *too much* highlighting going on in the builtin highlighter. Most languages don't actually highlight variables and when you do, 01:12
it kind of takes over the whole page. I think highlighting should be reserved for signifying important details rather than just each time you access or declare a variable. Thoughts?
01:15 tokuhiro_ left 01:21 Sqirrel joined 01:31 Sqirrel left 01:35 flussence joined, ilmari joined 01:36 Juerd joined, chansen_ joined, raiph left 01:37 SmokeMachine joined, geekosaur joined, samb1 joined 01:38 flaviusb joined 01:39 [Tux] joined, mephinet joined 01:40 simcop2387 joined 01:42 ggherdov joined 01:43 isacloud joined, clkao joined, zemmihates joined 01:44 mrsolo joined 01:46 skarn joined 01:48 Ven joined 01:53 Ven left 02:03 rluko joined 02:07 rluko left 02:14 xpen joined
zengargoyle i can see what you mean sometimes. in P6 it sometimes makes me think of how to reduce un-needed variables. :) 02:17
and the visual cues have been handy with things like :$var and |@array and ~X !X ?X and the like. helps to not just overlook them. 02:18
might just be my eyesight, but the contrast difference in places is helpful. 02:21
woot: Pod::Data data = Pod::Data.new(unkeyed => [["an unkeyed data", "\n"], ["another unkeyed data", "\n"]], keyed => {}) 02:23
sadly blows up compile when i try to add the :keyed($hash) :(
02:24 Sqirrel joined
zengargoyle and &dd drops the = from $=data :P 02:24
02:27 helloworldlang joined, xpen left 02:29 xpen joined, xpen left 02:31 xpen joined 02:33 AlexDaniel left 02:41 kaare_ joined, aborazmeh joined, aborazmeh left, aborazmeh joined 02:45 aborazmeh left 02:47 aborazmeh joined, aborazmeh left, aborazmeh joined, Sqirrel left 02:50 helloworldlang left 02:51 yqt left 02:54 Ven joined 02:58 kid51 left 03:03 Ven left 03:06 tokuhiro_ joined 03:08 spider-mario left 03:19 geraud left 03:20 geraud joined 03:24 aborazmeh left 03:28 noganex joined 03:37 BenGoldberg joined 03:40 kaare_ left
autarch how do class methods work in Perl 6? is there a "class" like "self"? 03:41
or it's just self? 03:43
03:44 geraud left
BenGoldberg You can call the .WHAT method on self 03:50
autarch I just need the class name, which I think is in self, so that's fine 03:51
grondilu ::?CLASS 03:53
mr_ron .tell cygx MVM_JIT_DISABLE allowed the build with mingw/Strawberry Perl to complete but with make test all the NativeCall tests failed both with and without MVM_SPESH_DISABLE. With Microsoft build tools the NativeCall tests pass.
yoleaux mr_ron: I'll pass your message to cygx.
03:55 awwaiid joined
grondilu m: class A { multi method f($class:U:) { "class!" }; multi method f($self:D:) { "instance!" } }; say A.f(); say A.new.f(); 03:55
camelia rakudo-moar 8e1997: OUTPUT«5===SORRY!5=== Error while compiling /tmp/MIaQ6RO3XJ␤Invalid typename 'U' in parameter declaration.␤at /tmp/MIaQ6RO3XJ:1␤------> 3class A { multi method f($class:U7⏏5:) { "class!" }; multi method f($self:D␤»
grondilu oh I thought that worked :/ 03:56
m: class A { multi method f(::?CLASS:U:) { "class!" }; multi method f(::?CLASS:D:) { "instance!" } }; say A.f(); say A.new.f(); 03:57
camelia rakudo-moar 8e1997: OUTPUT«class!␤instance!␤»
autarch m: class A { method cm { say self } }; say A.cm()
camelia rakudo-moar 8e1997: OUTPUT«(A)␤True␤»
autarch m: class A { method cm { return self.new }; say A.cm() 03:58
camelia rakudo-moar 8e1997: OUTPUT«5===SORRY!5=== Error while compiling /tmp/hfYuL9pFsc␤Missing block␤at /tmp/hfYuL9pFsc:1␤------> 3ethod cm { return self.new }; say A.cm()7⏏5<EOL>␤ expecting any of:␤ postfix␤ statement end␤ statement modifier…»
autarch m: class A { method cm { return self.new } }; say A.cm()
camelia rakudo-moar 8e1997: OUTPUT«A.new␤»
mr_ron m: class C {method hi {say <hi>}}; C.hi
camelia rakudo-moar 8e1997: OUTPUT«hi␤»
autarch m: class A { method cm ($class:) { return $class.new } }; say A.cm()
camelia rakudo-moar 8e1997: OUTPUT«A.new␤»
grondilu you really want to use ::?CLASS 03:59
autarch so let's say I have an array of values like <a b c > and I want to construct a regex like /<[ a b c ]>/ - what's the nicest way to get from the data structure to the regex?
m: class A { method cm { return ::?CLASS.new } }; say A.cm()
camelia rakudo-moar 8e1997: OUTPUT«A.new␤»
grondilu /<@array>/
autarch how about if it's a hash and I want the keys? 04:00
grondilu not sure but <@(%hash.keys)> may work
04:00 Ven joined
autarch that's what I was wondering 04:00
m: my %h = ( a => 1, b => 2 ); say /<@(%hash.keys)>/ 04:01
camelia rakudo-moar 8e1997: OUTPUT«5===SORRY!5=== Error while compiling /tmp/OyuHUISfNr␤Variable '%hash' is not declared. Did you mean '&hash'?␤at /tmp/OyuHUISfNr:1␤------> 3my %h = ( a => 1, b => 2 ); say /<@(7⏏5%hash.keys)>/␤»
autarch m: my %h = ( a => 1, b => 2 ); say /<@(%h.keys)>/
camelia rakudo-moar 8e1997: OUTPUT«/<@(%h.keys)>/␤»
autarch hmm
m: my %h = ( a => 1, b => 2 ); say /<{%h.keys}>/
camelia rakudo-moar 8e1997: OUTPUT«/<{%h.keys}>/␤»
grondilu oh that's weirtd
m: my %h = ( a => 1, b => 2 ); say "aaa" ~~ /<{%h.keys}>/ 04:02
camelia rakudo-moar 8e1997: OUTPUT«「a」␤»
grondilu you have to match your regex on somthing
autarch ah
grondilu m: my %h = ( a => 1, b => 2 ); say "aaa" ~~ /<{%h.keys}>+/
camelia rakudo-moar 8e1997: OUTPUT«「aaa」␤»
grondilu m: my %h = ( a => 1, b => 2 ); say "aaduha" ~~ /<{%h.keys}>+/
camelia rakudo-moar 8e1997: OUTPUT«「aa」␤»
grondilu I'm a bit surprised you don't need a @ 04:03
m: my %h = ( a => 1, b => 2 ); say "aaduha" ~~ /<@{%h.keys}>+/
camelia rakudo-moar 8e1997: OUTPUT«5===SORRY!5=== Error while compiling /tmp/4gQFCXwQjQ␤Unsupported use of @{%h.keys}; in Perl 6 please use @(%h.keys)␤at /tmp/4gQFCXwQjQ:1␤------> 3, b => 2 ); say "aaduha" ~~ /<@{%h.keys}7⏏5>+/␤»
grondilu m: my %h = ( a => 1, b => 2 ); say "aaduha" ~~ /<@(%h.keys)>+/
camelia rakudo-moar 8e1997: OUTPUT«「aa」␤»
grondilu ^I'd use this one, the other one is suspicious 04:04
autarch why < and not <[ ?
and why @( and not @{ ? 04:05
grondilu m: say @{foo}
camelia rakudo-moar 8e1997: OUTPUT«5===SORRY!5=== Error while compiling /tmp/AKNBpoAgev␤Unsupported use of @{foo}; in Perl 6 please use @foo␤at /tmp/AKNBpoAgev:1␤------> 3say @{foo}7⏏5<EOL>␤»
grondilu just not the correct syntax
@{ is just something that is wrong 04:06
geekosaur perl5 used @{ as a parser hack
04:06 Ven left
grondilu correct, as in the famous @{[ @stuff ]} idiom for interpolating arrays 04:07
autarch so what about < vs <[ in the regex?
geekosaur it never really made any sense but getting it to handle @( was too painful. perl6 fixed this.
grondilu <[ opens a character class
autarch don't I want a character class if I want to match any key from the regex? 04:08
04:08 hartenfels left
autarch my %h = ( a => 1, b => 2 ); say "aabduha" ~~ /<@(%h.keys)>+/ 04:08
grondilu it opens a *literal* character class
geekosaur no? unless what you meant was to jumble all the keys together
autarch m: my %h = ( a => 1, b => 2 ); say "aabduha" ~~ /<@(%h.keys)>+/
camelia rakudo-moar 8e1997: OUTPUT«「aab」␤»
geekosaur they're strings, not a set of individual characters
autarch m: my %h = ( a => 1, b => 2 ); say "aabduha" ~~ /<[ @(%h.keys) ]>+/
camelia rakudo-moar 8e1997: OUTPUT«「h」␤»
autarch I don't think I'm following 04:09
geekosaur "character" class not "string" class
<[abcde]> and <[edcba]> are exactly the same charclass
autarch right .. and?
geekosaur <[aaa|bbb]> is the same as <[ab|]> 04:10
autarch so what is <abcde> then?
geekosaur if your keys are always going to be exactly one character, it might happen to do what you want
autarch ah, I see what you're getting at
geekosaur as soon as you add a key with more than one character, you will be very unhappy
autarch so really I think I'd want /@(%h.keys).join(' || ')/ or something like then 04:11
04:11 bpmedley joined
autarch the documentation doesn't talk about how strings interpolate into regexes at all, btw - that would be helpful 04:11
and yes, I know, patches are welcome, but I'm trying to tweak the pod -> html converter before I work on the docs 04:12
geekosaur iirc <abcde> looks for a rule named abcde and invokes its match routine
so if you have rule abcde { ... } then <abcde> matches that rule
autarch so how does <@(%h.keys)> work?
m: my %h = ( a => 1, b => 2 ); say /<[ @(%h.keys) ]>+/.perl 04:13
camelia rakudo-moar 8e1997: OUTPUT«/<[ @(%h.keys) ]>+/␤»
autarch m: my %h = ( a => 1, b => 2 ); say /<@(%h.keys)>+/.perl
camelia rakudo-moar 8e1997: OUTPUT«/<@(%h.keys)>+/␤»
autarch argh
m: my %h = ( a => 1, b => 2 ); dd /<@(%h.keys)>+/
camelia rakudo-moar 8e1997: OUTPUT«Regex $var = /<@(%h.keys)>+/␤»
autarch I guess it's making a closure?
geekosaur I think it's "not supposed" to work per design.perl6.org/S05.html#Extensibl...%3C...%3E) but it may be treating it as a quoting group and inserting the keys as a list of things to match? 04:14
autarch m: my %h = ( a => 1, b => 2 ); dd /"{%h.keys.join( ' || ')}"/ 04:15
camelia rakudo-moar 8e1997: OUTPUT«Regex $var = /"{%h.keys.join( ' || ')}"/␤»
geekosaur so < a b > in your case (the spaces are important)
autarch m: my %h = ( a => 1, b => 2 ); say 'abcdef' ~~ /"{%h.keys.join( ' || ')}"/
camelia rakudo-moar 8e1997: OUTPUT«Nil␤»
geekosaur meaning ('a' | 'b')
04:15 cognominal joined 04:16 geraud joined
autarch aha, I finally found the key part in the synopsis - An interpolated array: / @cmds / is matched as if it were an alternation of its literal elements. 04:17
geekosaur so the <> shouldn't be needed there
04:18 Axord joined
skids m: class A { has $.foo = 42; my role B[\stem] { method foo { say stem.foo } }; has B $.a = B[self].new; }; A.new.a.foo; # interesting if slightly inefficient idiom to deal with sub-objects 04:36
camelia rakudo-moar 8e1997: OUTPUT«42␤»
05:03 Ven joined 05:07 Ven left 05:10 doublec joined 05:13 BenGoldberg left 05:23 raiph joined 05:35 cognominal left 05:43 japhb joined 05:49 japhb left, japhb joined 05:53 xfix joined 05:56 crux joined 05:57 sprocket left 06:04 Ven joined 06:05 Ven left 06:10 dayangkun_ joined 06:12 dayangkun left 06:16 khw left 06:26 softmoth_ left 06:32 dpk joined 06:33 spider-mario joined 07:02 raiph left 07:04 spider-mario left 07:07 diana_olhovik_ joined 07:08 SmokeMachine_ joined 07:10 Praise- joined, Praise- left, Praise- joined, Juerd_ joined, Averna joined 07:11 integral joined, integral left, integral joined, ilmari_ joined, riatre_ joined 07:12 mr_ron_ joined 07:14 orevdiabl joined, Hotkeys_ joined 07:15 skarn left, ggherdov left, SmokeMachine left, mr_ron left, ilmari left, Juerd left, ilmari_ is now known as ilmari, Juerd_ is now known as Juerd, mr_ron_ is now known as mr_ron 07:16 domidumont joined 07:17 domidumont left, boegel joined 07:18 domidumont joined, cgfbee left, skarn joined, geraud left, domidumont left 07:19 domidumont joined 07:20 domidumont left 07:21 domidumont joined
dalek kudo/curli: ce27a92 | (Stefan Seifert)++ | src/core/CompUnit.pm:
Remove obsolete CompUnit::precomp
07:21
07:22 ggherdov joined
[Tux] test 50000 21.637 21.523 07:22
test-t 50000 18.246 18.132
07:22 brrt joined 07:23 cgfbee joined, Averna left
brrt good * 07:24
07:26 xfix left
[Tux] tony-o_, the error: 07:26
Cannot use a Buf as a string, but you called the Stringy method on it
in method get_line at /pro/3gl/CPAN/rakudobrew/moar-nom/panda/.panda-work/1447657889_7/lib/CSV/Parser.pm:33
07:27 CIAvash joined 07:30 Averna joined 07:32 darutoko joined 07:47 FROGGS joined 07:57 espadrine_ joined 08:01 abraxxa joined 08:02 espadrine_ left 08:04 darutoko left 08:05 zakharyas joined 08:06 darutoko joined 08:07 salva joined 08:11 telex left 08:12 telex joined 08:15 anaeem1 joined
brrt cygx: at first sight, it seems to be an error in (adhoc) exceptions within the JIT 08:33
i should probably be able to make a test for that hypothesis
if it is true, then i'm not 100% sure i can do anything about it 08:34
08:38 anaeem1 left 08:55 g4 joined 09:01 ][Sno][ joined 09:05 RabidGravy joined 09:08 dakkar joined
dalek osystem: 04c7862 | bluebear94++ | META.list:
Add Terminal::WCWidth to the ecosystem
09:08
osystem: fa1816c | RabidGravy++ | META.list:
Merge pull request #94 from bluebear94/master

Add Terminal::WCWidth to the ecosystem
09:14 Ven joined
jnthn morning, #perl6 09:19
yoleaux 15 Nov 2015 04:51Z <psch> jnthn: irclog.perlgeek.de/perl6/2015-11-15#i_11540381 is kinda-sorta what block bool_enum from being mergeable. the segfault is the some, except with getlex instead of bindlex, which somewhat off-by-ones, as mentioned earlier
15 Nov 2015 04:52Z <psch> jnthn: "is the same [issue]", not "is the some"...
15 Nov 2015 05:05Z <psch> jnthn: nvm, confused myself with sub vs method
15 Nov 2015 20:22Z <nine> jnthn: Why should CompUnit::Repository::Installation when followed by another one consider its set of modules together with its following repo's? You wrote that the best option across the two of them wins, but I don't see how one can be better.
15 Nov 2015 20:23Z <nine> jnthn: a CompUnit either matches the DependencySpecification or it doesn't. When it does, in what regard can another candidate be "better"?
jnthn nine++ # much comp unit hacking \o/ 09:20
09:20 andreoss joined 09:22 Ven left 09:23 tmtx joined
JimmyZ jnthn: rt.perl.org/Public/Bug/Display.html?id=121830 # I think it still is not fixed, maybe should reopen it :) 09:25
jnthn JimmyZ: That patch makes no sense
JimmyZ I don't have the right though
jnthn map needs a block
JimmyZ ok, so the comment is wrong 09:26
:)
jnthn I think so
Well
Maybe worth to git blame
But I wonder if some other change got done
And the comment left behind
JimmyZ jnthn: ah, this one github.com/rakudo/rakudo/commit/52...0e98908cda 09:30
jnthn aha :) 09:32
So yeah, comment can go :)
JimmyZ yeah 09:34
jnthn remvoes
JimmyZ++
JimmyZ :)
dalek kudo/nom: d3f3921 | jnthn++ | src/core/List.pm:
Remove outdated comment.

It referred to a block around a gather/take that was removed a while back. The block to map is needed, given map expects a block. JimmyZ++ for noticing.
09:35
09:38 brrt left 09:44 yeahnoob left 09:50 domidumont left 09:51 domidumont joined 09:55 rindolf joined
RabidGravy m: sub foo() { Str $bar }; # LTA error message 10:01
camelia rakudo-moar d3f392: OUTPUT«5===SORRY!5=== Error while compiling /tmp/CRhKCPAaCc␤Two terms in a row␤at /tmp/CRhKCPAaCc:1␤------> 3sub foo() { Str7⏏5 $bar }; # LTA error message␤ expecting any of:␤ infix␤ infix stopper␤ statement end␤ …»
jnthn What do you expect?
RabidGravy "Variable '$bar' is not declared" or some variant thereof 10:02
I can understand *why* it is that message
jnthn I think the syntax is too malformed for us to get to doing that check 10:03
In the normal way
We do rewrite lots of two terms in a row though
So can quite possibly do it that way
Maybe with a "(Did you mean `my Str $bar`?)" or so
(I'm guessing that is what you were meaning? :)) 10:04
RabidGravy yeah that would probably be the one, it's not like I'm losing sleep or anything ;-) It's just in my pre-caffeine overdose state I had to look more than once to see the error
dalek kudo/nom: b18ada0 | jnthn++ | src/ (3 files):
Only allow invocant colon on method-y signatures.
10:05
jnthn Feel free to file an LTA ticket on it.
I think we can do something about it. 10:06
.tell psch I made that sub vs. method mistake actually give an error now. :-)
yoleaux jnthn: I'll pass your message to psch.
dalek ast: 0a2bf66 | jnthn++ | S12-methods/syntax.t:
Use anon method rather than sub for this test.

In preparation for only allowing the : seaparator in signatures on methods.
ast: a2c5381 | jnthn++ | S06-signature/errors.t:
Test for X::Syntax::Signature::InvocantNotAllowed.
10:07
10:09 chewie_1982 joined
jnthn .tell nine We probably need to work at the definition of "better" somewhat, if one can't be found in the existing design docs. I think I'd go with: if there's more than one authority then always claim ambiguity. Otherwise, go with the highest version. That means :ver<3.*> and :ver<3.2+> will do the right kind of thing. 10:10
yoleaux jnthn: I'll pass your message to nine.
10:11 dayangkun_ left 10:13 domidumont left, domidumont joined
jnthn .tell nine As for why to search the two installations "in parallel": primarily 'cus I think TimToady++ wants it to be that way, but I think the reasoning is that a systemwide installed later version that matches should be considered over a locally installed earlier version. Hopefully if I'm remembering the intent wrong TimToady++ will notice when backlogging and correct me... :) 10:14
yoleaux jnthn: I'll pass your message to nine.
10:19 Ven joined
dalek p: c52b1cb | jnthn++ | src/vm/moar/ (3 files):
Remove long-unrequied hack from early Moar days.
10:21
10:24 Ven left
psch jnthn++ 10:24
yoleaux 10:06Z <jnthn> psch: I made that sub vs. method mistake actually give an error now. :-)
psch jnthn: i've PR'd a fix for the SEGV, the bool_enum branch still gens wrong code though
10:31 ed25519 joined 10:35 tmtx left 10:54 rurban joined 11:08 rurban left 11:09 rurban joined 11:10 rurban left 11:20 rurban joined 11:21 Ven joined 11:22 llfourn left 11:27 Ven left 11:32 cdc joined
cdc m: sub postfix:<!>(Int $a) is looser(&infix:<+>) { 2 * $a }; say (3 + 4!) 11:33
camelia rakudo-moar b18ada: OUTPUT«11␤»
cdc Hello #perl6 o/ Is this ^ expected? 11:34
psch cdc: looks fine to me, you're saying postfix:<!> is looser and it is..? 11:35
cdc psch: oh, it seems I didn't understand "is looser" correctly, then :( 11:36
psch: I'd like to have (3 + 4!) == 14 11:37
m: sub postfix:<!>(Int $a) is tighter(&infix:<+>) { 2 * $a }; say (3 + 4!)
camelia rakudo-moar b18ada: OUTPUT«11␤»
11:38 loren joined
psch *that* seems unexpected... 11:39
moritz it still looks tighter with "is looser"
ilmari tighter = higher precedence?
moritz yes 11:40
psch m: sub postfix:<!>(Int $a) is tighter(&infix:<+>) { 2 * $a }; say 3 + 4 !
camelia rakudo-moar b18ada: OUTPUT«5===SORRY!5=== Error while compiling /tmp/VbWIEsGG97␤Confused␤at /tmp/VbWIEsGG97:1␤------> 3ighter(&infix:<+>) { 2 * $a }; say 3 + 47⏏5 !␤ expecting any of:␤ infix␤ infix stopper␤ postfix␤ statement …»
moritz expecting any of... postfix 11:41
ah, it expected a postfix, but got whitespace instead
psch yeah
only dottyop gets the ws there
cdc moritz, psch: should I file a bug report? 11:42
psch m: sub postfix:<!>(Int $a) is tighter(&infix:<+>) { 2 * $a }; say 3 + 4 .&postfix:<!> # i'd expect this to work though... 11:43
camelia rakudo-moar b18ada: OUTPUT«5===SORRY!5=== Error while compiling /tmp/2x8iQGwpYg␤Unsupported use of . to concatenate strings; in Perl 6 please use ~␤at /tmp/2x8iQGwpYg:1␤------> 3ter(&infix:<+>) { 2 * $a }; say 3 + 4 .&7⏏5postfix:<!> # i'd expect this to work th␤»
moritz cdc: yes please
11:45 Averna left
psch oh, i was wrong from the start o.o 11:45
looser was right in the first place, sorry
not sure what the confusion was in my head
11:45 rurban left
cdc psch: no pb :) 11:45
jnthn is not sure quite how relative precedence between infixes and postfixes works out 11:46
In so far as we parse prefix/postfix as part of a term 11:47
psch m: sub postfix:<!>(Int $a) is looser(&postfix:<++>) { 2 * $a }; say 3 + 4!
camelia rakudo-moar b18ada: OUTPUT«11␤»
jnthn And then look for an infix, then another term.
11:48 xpen left, cdc_ joined
zengargoyle good * #perl6 11:49
11:49 cygx joined
cygx m: BEGIN "32".subst("3", "4") 11:49
yoleaux 03:53Z <mr_ron> cygx: MVM_JIT_DISABLE allowed the build with mingw/Strawberry Perl to complete but with make test all the NativeCall tests failed both with and without MVM_SPESH_DISABLE. With Microsoft build tools the NativeCall tests pass.
camelia rakudo-moar b18ada: OUTPUT«5===SORRY!5=== Error while compiling /tmp/YgzZT7meYZ␤An exception occurred while evaluating a BEGIN␤at /tmp/YgzZT7meYZ:1␤Exception details:␤ Type check failed in binding cds; expected Any but got Mu␤ in code at /tmp/YgzZT7meYZ:1␤␤»
11:50 znpy joined
psch m: BEGIN $/.^name.say 11:50
camelia rakudo-moar b18ada: OUTPUT«Nil␤»
psch m: BEGIN $/.^name.say; $/.^name.say
camelia rakudo-moar b18ada: OUTPUT«Nil␤Nil␤»
psch m: BEGIN $/.WHAT.say; $/.WHAT.say
camelia rakudo-moar b18ada: OUTPUT«Nil␤Nil␤»
psch heh 11:51
jnthn m: BEGIN { "32".subst("3", "4") }
camelia rakudo-moar b18ada: OUTPUT«5===SORRY!5=== Error while compiling /tmp/Kiq1zBaVAl␤An exception occurred while evaluating a BEGIN␤at /tmp/Kiq1zBaVAl:1␤Exception details:␤ Type check failed in binding cds; expected Any but got Mu␤ in block at /tmp/Kiq1zBaVAl:1␤␤»
jnthn m: BEGIN { my $/; "32".subst("3", "4") }
camelia ( no output )
cdc_ has filed #126653
11:51 RabidGravy left
jnthn delegates it to TimToady to decide if it's bug or "no, you can't expect that to work" 11:51
cdc_ :) 11:52
timotimo o/ 11:54
mrf o/ 12:02
timotimo today i'll be the one to do the perl6 weekly again 12:05
if you have something in particular you want included that i might miss, i'd appreciate a hint 12:06
12:09 Skarsnik joined
moritz ++timotimo 12:12
I have to say that docs/ChangeLog already looks impressive 12:13
timotimo for just the week or the next full release? 12:14
Zoffix timotimo, we got Pod::Coverage up and soon enough it will be included as part of the "Kwalitee" metrics of the dists in ecosystem. Not sure if it's perl6-weekly-worthy, but would be nice to spread the word so module authors would examine the state of their docs :)
arnsholt timotimo: I've gotten the rudiments of a pure Perl 6 kernel working, but the ipython docs are *terrible* on how messages are sent and what messages are possible 12:15
timotimo arnsholt: i felt like the docs on what messages are possible was kind of exhaustive and all right
arnsholt I'll try to push my changes to Net::ZMQ and IPerl6 today. Need to section things into commits first
Yeah, the actual messages seem to be documented, actually 12:16
timotimo first step is always to look at last week's weekly to see what was already covered :D
arnsholt But how they're sent over the socket isn't clear to me
timotimo oh 12:17
that's easy
it has this silly framing protocol
first message is an ID, then comes the literal string "<--ID|MSG-->" or something
Zoffix heh 12:18
timotimo did you see that in the docs?
it's explained and everything! :)
arnsholt Yeah, now I see what they're trying to say!
timotimo oh, actually, i think it's IDS, because a message can have multiple IDs
arnsholt Yeah, but a single message, presumably
timotimo of course 12:19
well, a multi-part message
12:19 llfourn joined
timotimo ZMQ has a name for that, but i forget 12:19
arnsholt And they're not entirely clear on what "serialized dict" actually means, but I suppose it's just UTF-8 encoded JSON
timotimo yeah, that's right
12:20 cdc_ left
timotimo pyZMQ actually does that for you if you pass a dict to the send function 12:20
12:20 sufrostico joined
arnsholt Ah, right. I don't think Net::ZMQ will do that anytime soon =) 12:21
12:23 llfourn left 12:24 Ven joined 12:26 molaf joined
timotimo i'm glad if i can be your doc guide 12:26
arnsholt Yeah, I'll pester you more soonish about getting this to work 12:28
From the experiment with the inline Python version, I think getting a barebones kernel working should be within reach
timotimo does that mean if i wait with the weekly for a few hours i can report a working iperl6 kernel?
arnsholt Not that close, no =) 12:29
timotimo OK
arnsholt Well, you can report the proof-of-concept Inline::Python one, I guess. But the pure Perl one will take some more work
timotimo sure :) 12:30
arnsholt A week or two, I guess. Depending on tuits and if other people start pitching in
timotimo understood
do we have a plan for things like displaying things with the display api? 12:31
12:31 Ven left
timotimo like pictures, HTML things, stuff like that? 12:31
arnsholt BTW, if you have the ZMQ man pages installed: does your version of ZMQ have both zmq_recv and zmq_recvmsg, or just one of them?
My current plan is just to get normal code execution working 12:32
zengargoyle woot, =data almost works. had to bypass all the nqp .add_constant / .compile_time_value madness :)
timotimo don't have the man pages, no :(
arnsholt Ah, no problem. We'll just see if the code breaks with my Net::ZMQ patches =D 12:34
timotimo wonderful
arnsholt 'Cause it appears that some versions of libzmq have both sendmsg and send, and other have just send (but with the arguments of sendmsg from the other ones) 12:35
timotimo o_O
arnsholt Yeah.
But I've got to got for a bit. Back in an hour or so 12:36
timotimo no problem. thanks for the effort!!
people will be so happy :3
here's something i'm noticing 12:37
on mondays, people visit and repost/tweet/share/... the weekly ... but they do it usually many hours before the weekly post of that week goes up 12:38
so i *think* they're always seeing weekly posts one week later than they are posted %)
12:39 AlexDaniel joined 12:43 flaviusb left, kaare_ joined 12:44 flaviusb joined, kid51 joined
stmuk that suggests the weekly should come out on Sunday to me 12:46
timotimo then the same thing will happen on sundays :)
maybe the weekly should happen every 6 days rather than every 7
stmuk we could try a sequence where the day is dec'd by 1 each week 12:47
to fool people
that wouldn't be confusing at all :)
timotimo that's exactly what i mean by "every 6 days"
12:48 rurban joined
timotimo if you dec the day by 1 each week and wrap at the 7th day, you'll end up with a weekly on the day after the previous weekly and then a weekly after 14 (or 13?) days 12:48
CIAvash require DateTime::Format <&strftime>; gives this error: Trying to import symbols &strftime from 'DateTime::Format', but it does not export anything 12:49
using this module: github.com/supernovus/perl6-datetime-format/
Am I doing it wrong? 12:50
AlexDaniel m: .say for 1^..^3 12:51
camelia rakudo-moar b18ada: OUTPUT«2␤»
AlexDaniel hmm
12:53 kid51 left 12:54 RabidGravy joined
mrf Is it possible to make something like /$<foo>=[$<bar>=[<[a..z]>]* % '.' ]*/ give a match object like $/<foo><bar> rather than $/<foo> and $/<bar> 12:54
timotimo m: "hello" ~~ /$<foo><bar>=<[a..z]>+/; say $/.perl 12:55
camelia rakudo-moar b18ada: OUTPUT«5===SORRY!5===␤Unrecognized regex metacharacter = (must be quoted to match literally)␤at /tmp/pXS0VWo9fp:1␤------> 3"hello" ~~ /$<foo><bar>7⏏5=<[a..z]>+/; say $/.perl␤Unable to parse regex; couldn't find final '/'␤at /tmp/pXS0VWo9fp:1…»
12:55 pmurias joined
timotimo ah 12:55
that syntax doesn't syntax
12:55 pmurias_ joined
timotimo i don't think there is a way without making the inner part an extra regex that you call 12:56
mrf :(
psch m: "a" ~~ / $<foo>=($<bar>=a) /; $<foo>.say # 12:57
camelia rakudo-moar b18ada: OUTPUT«「a」␤ bar => 「a」␤»
psch i think that still leaves $<bar> around though
m: "a" ~~ / $<foo>=($<bar>=a) /; $<bar>.say
camelia rakudo-moar b18ada: OUTPUT«Nil␤»
psch ah, no
timotimo oh!
mrf :D :D
timotimo nice catch, psch
mrf \o/
cygx CIAvash: I believe that's the correct syntax
psch m: "a" ~~ / $<foo>=$<bar>=a /; $<bar>.say 12:58
camelia rakudo-moar b18ada: OUTPUT«「a」␤»
mrf psch++ thank you thats what I needed. Didn't occur to me to use a capturig group got a name capture.
psch 'cause without capturing there it's equiv to that
cygx random ideas to try: hacke the module to use module { ... } instead of unit module or try exportinga proto for strftime
*hack
timotimo i don't think that'll help, "unit module" is purely syntactic IIUC
psch ISTR there's something different about module and package that has to do with exporting... 12:59
mrf m: "a" ~~ / $<foo>=($<bar>=a) /; $/0.say
camelia rakudo-moar b18ada: OUTPUT«5===SORRY!5=== Error while compiling /tmp/I_2I_Yj2KK␤Two terms in a row␤at /tmp/I_2I_Yj2KK:1␤------> 3"a" ~~ / $<foo>=($<bar>=a) /; $/7⏏050.say␤ expecting any of:␤ infix␤ infix stopper␤ statement end␤ …»
mrf m: "a" ~~ / $<foo>=($<bar>=a) /; $0.say
camelia rakudo-moar b18ada: OUTPUT«Nil␤» 13:00
mrf perfect
cygx timotimo: probably 13:01
CIAvash I wrote a small module(with unit module) and exported a sub, It works. Not sure why it's not working on DateTime::Format
mrf OOI what is the purpose of the unit keyword? as in "unit module Foo {}" 13:02
timotimo unit module Foo { } is a very strange idea of "unit"
cygx CIAvash: have you tried adding and exporting a proto?
timotimo to me, all it does is remove the need for { }
cygx proto sub strftime (|) is export {*}
timotimo perhaps it's something about our vs is export?
nine Good #perl6, afternoon! 13:03
yoleaux 10:10Z <jnthn> nine: We probably need to work at the definition of "better" somewhat, if one can't be found in the existing design docs. I think I'd go with: if there's more than one authority then always claim ambiguity. Otherwise, go with the highest version. That means :ver<3.*> and :ver<3.2+> will do the right kind of thing.
10:14Z <jnthn> nine: As for why to search the two installations "in parallel": primarily 'cus I think TimToady++ wants it to be that way, but I think the reasoning is that a systemwide installed later version that matches should be considered over a locally installed earlier version. Hopefully if I'm remembering the intent wrong TimToady++ will notice when backlogging and correct me... :)
13:03 loren left
timotimo oh hey nine! 13:04
cygx timotimo: why I was asking about unit is that the placement od exported subs as well as sub EXPORT is apparently important
require only sees things exported within the module, but sub EXPORT must live outside of it
timotimo hm, i think sub EXPORT still wants to be outside it, yeah
mrf timotimo: so you would only do "unit module Foo;" or "module Foo {}"
timotimo that's my understanding
i must admit i don't write many module-y things at all, so i don't have much experience with the whole thing 13:05
mrf I have seen a few examples of things like "unit grammar Foo {}" around which is why I asked as "grammar Foo {}" seemed to work as expected
moritz you need "unit" for the "unit grammar Foo;" syntax 13:06
mrf ok. Which I assume is roughly equivelant to p5s package Foo; syntax 13:07
CIAvash timotimo: from the module's source code: multi sub strftime (Str $format is copy,DateTime $dt=DateTime.now,Str :$lang=$datetime-format-lang,Bool :$subseconds,) is export {
timotimo: so it is exported
Skarsnik well it's exported by default when you do use x)
CIAvash Yeah 13:08
13:08 rindolf left
AlexDaniel m: say 4^^^ ^ ^ ^2; 13:09
camelia rakudo-moar b18ada: OUTPUT«Nil␤»
timotimo Skarsnik: huh? exported by default?
RabidGravy yeah unqualified is export exports the symbol by default 13:10
Skarsnik Module A { sub something is export {}}; use A; something();
m: module A { sub something is export {}}; use A; something();
camelia rakudo-moar b18ada: OUTPUT«===SORRY!===␤Could not find A in any of:␤ file#/home/camelia/.perl6/2015.10-323-gb18ada0/lib␤ inst#/home/camelia/.perl6/2015.10-323-gb18ada0␤ file#/home/camelia/rakudo-m-inst-1/share/perl6/lib␤ file#/home/camelia/rakudo-m-inst-1/share/perl6/v…»
RabidGravy to not export by default there needs to be an 'export tag'
timotimo Skarsnik: you want "import" instead of "use" there, as "use" looks in the filesystem 13:11
RabidGravy Skarsnik, in that case you just need "import A;"
Skarsnik m: module A { sub something is export {}}; import A; something();
camelia ( no output )
Skarsnik oh thx x)
I am still trying to come out with a module name for something that test the confirmity of NC type to their C counterpart. NativeCall::TypeDiag? 13:13
timotimo StructLinter? 13:14
StructConformance?
psch m: say 1 ^^ 2; say 1 xor 2 13:16
camelia rakudo-moar b18ada: OUTPUT«Nil␤1␤»
Skarsnik It's more the prefix. NativeCall make it a part of NC?
psch m: say infix:<^^>(1,2); say 1 xor 2
camelia rakudo-moar b18ada: OUTPUT«Nil␤1␤»
13:17 znpy left
pmurias_ jnthn: does the grant roadmap/test list look sane: github.com/pmurias/grant_proposal/...mplate.pod 13:18
timotimo i don't see a problem with using NativeCall:: 13:21
zengargoyle Note, EXPORT can't be declared inside a package because presently rakudo (2015.09) seems to treat EXPORT as part of the compunit rather than the package. 13:22
that's in the docs at the moment.
CIAvash cygx: It has not effect 13:26
*no
cygx CIAvash: then, I'm all out of ideas :(
13:27 rindolf joined, Ven joined 13:28 rindolf left 13:31 mr_ron left 13:34 rindolf joined 13:35 Ven left
cygx CIAvash: as a workaround, you could do this: 13:35
require DateTime::Format; my &strftime := ::('DateTime::Format')::EXPORT.WHO<DEFAULT>.WHO<&strftime>;
moritz eeeks 13:37
geekosaur glad I'm not the only one who had that reaction 13:39
Skarsnik CIAvash, what are you trying to do? 13:43
cygx actually, you don't need the WHO 13:44
RabidGravy at a guess re-export a sub
cygx just &::('DateTime::Format')::EXPORT::DEFAULT::strftime should suffice
CIAvash Skarsnik: to do `require DateTime::Format <&strftime>` instead of `use DateTime::Format` 13:45
Skarsnik Hm, I am not sure to understand how evalbot work. Should running it our own work out of box (it build perl6 stuff?). Or should I just add a server/channel to the git repository to have camelia somewhere else? 13:46
cygx CIAvash: `require DateTime::Format; my &strftime := &::('DateTime::Format')::EXPORT::DEFAULT::strftime;` works for me 13:47
CIAvash cygx: yeah, it works 13:49
13:50 pjscott joined
CIAvash But why shouldn't `require DateTime::Format <&strftime>` work?! 13:51
cygx it should
13:52 SmokeMachine_ left, SmokeMachine_ joined
pjscott Wondering why .HOW requires argument: 13:52
Skarsnik m-star: require DateTime::Format <&strftime>; 13:53
13:53 isacloud left
Skarsnik r-star: require DateTime::Format <&strftime>; 13:53
pjscott > 1.HOW.name('fish') # Int
jnthn To allow for prototype-like meta-objects as well as class-like ones. 13:55
moritz pjscott: general calling convention for the MOP, to allow... what jnthn said
13:55 olinkl joined, isacloud joined
jnthn For example, coercion types don't carry any meta-state around with them, so they get a singleton meta-object. 13:56
13:56 Spot__ joined, PotatoGim joined
jnthn And need the actual type passed to get the data needed. 13:56
pjscott Got it 13:59
14:08 sufrostico left
CIAvash I changed `unit module DateTime::Format;` to `unit module Format;` in module's source code and then this worked: require Format:file('[Path to /DateTime/Format.pm6]') <&strftime>; 14:15
does that say anything?
dalek c: 3754fdc | (Mike Francis)++ | doc/Language/regexes.pod:
Document recent changes to allow non-inclusive ranges as quantifiers
14:19
c: 4993047 | (Mike Francis)++ | doc/Language/regexes.pod:
Fixed typo
c: 9d1ef4e | (Zoffix Znet)++ | doc/Language/regexes.pod:
Merge pull request #199 from ungrim97/feature/document_quantifier_changes

Document recent changes to allow non-inclusive ranges as quantifiers
c: 6ee2200 | (Mike Francis)++ | doc/Language/regexes.pod:
Document how to create nested named captures without subrules
c: 30b231c | (Zoffix Znet)++ | doc/Language/regexes.pod:
Merge pull request #200 from ungrim97/feature/nested_named_captures

Document how to create nested named captures without subrules
mrf Zoffix++ Cheers 14:23
cygx jnthn: CIAvash: test case: require JSON::Tiny; require DateTime::Format; say OUR::("JSON::Tiny"); say OUR::("DateTime::Format") 14:25
DateTime::Format doesn't get added to OUR::, for whatever reason... 14:26
pmurias_ jnthn: what do you think would be a realistic time estimate for rakudo-js? 14:27
moritz pmurias_: doesn't that depend a lot on how much you work on it? 14:28
jnthn pmurias_: Didn't get to read it yet; will do during my next spectest run :)
pmurias_ jnthn: ok
14:30 ribasushi joined 14:31 abaugher left, abaugher joined
pmurias_ moritz: you mean in terms of man-hours and the date differences vs start from finish? 14:34
14:34 sprocket joined
moritz pmurias_: the man hours per week affect the calendar weeks/months/years that it takes, primarily 14:35
14:35 tokuhiro_ left
moritz pmurias_: but also if the time commitment is too low, it might never finish, because you spend most of your time chasing API changes 14:35
pmurias_ I'm planning to focus on it full time if the grant gets approved, so API changes shouldn't be a huge factor 14:37
14:37 pippo joined
pippo o/ #perl6. 14:37
14:38 zengargoylew joined 14:39 rindolf left 14:41 pmurias_ left 14:42 pmurias left
cygx CIAvash: jnthn: gist.github.com/cygx/cfef662ea505cd68b2e8 fixes the issue, but I have no idea if that's the Right Thing to do 14:42
14:43 pmurias joined, pmurias_ joined 14:48 pmurias_ left, pmurias left
jdv79 RabidGravy: are you building some sort of service thing in p6? 14:49
14:50 pjscott left
[Coke] www.infoworld.com/article/2882300/p...r-larry-wa 14:51
ll-rethought-version-6-due-this-year.html
www.infoworld.com/article/2882300/p...-year.html 14:52
there.
14:52 khw joined 14:53 yqt joined
[Coke] why is there a perl6/rakudo? ? 14:53
ah. why "was" there. nevermind. 14:54
jdv79 [Coke]: is that article from febrary
14:57 skids joined 14:58 pmurias joined 15:00 pmurias_ joined, sprocket left
[Coke] I have no idea. Just saw it on twitter today 15:01
RabidGravy jdv79, sort of yes
15:01 sufrostico joined
RabidGravy jdv79, eventually I going to finish the radio station management system that I started writing in P5 in P6, but right now it's yaks all the way down 15:07
15:11 bpmedley left 15:12 corbyhaas joined
corbyhaas Buddy in another channel just linked video of Larry's recent talk and I'm hyyyyyyyyyyyped. 15:13
PerlJam corbyhaas: glad to hear it :) 15:15
heh ... glanced at an email that said "Project Advent" in the subject and at first I thought it was for Perl, but no, it's actually from my church. Weird how the default expectation got flipped in my head. 15:16
pink_mist heh 15:17
15:18 ed25519 left
brabo corbyhaas: :p 15:20
15:22 brrt joined 15:25 softmoth_ joined 15:30 raiph joined 15:35 tokuhiro_ joined 15:40 tokuhiro_ left
pmurias hmm, should I send by rakudo-js grant proposal to the TPF Grants Committe or to the Ian Hague Perl 6 Development Grants? 15:40
PerlJam Is there even any money left in the latter? 15:41
moritz I think so, yes
pmurias: I'd submit it as a Hague grant
less rigor in the process
PerlJam and it's specifically Perl 6, so the competition pool is much smaller :) 15:42
moritz aye
zengargoylew wonders who besided myself has strong opinions on POD's =data blocks.... 15:44
timotimo zengargoylew: i'll be happy when we have working =data blocks in any case :)
it's been a long time since i beat my head against the pod code :|
PerlJam (working =data blocks)++ :) 15:45
zengargoylew if i can straighten out some details, it's working.
15:45 abraxxa left
zengargoylew i.e. $=data[0] gives me first un-named data section. $=data<name1> gives me that named section. 15:46
timotimo very good! 15:47
zengargoylew need to decide whether the abbreviated form keeps newline or not.. and massage stuff to join array of lines, consider newlines, etc.
or leading whitespace. 15:48
but the hardest part for me at least seems to be at a workable stage. 15:49
15:49 pdcawley joined, pdcawley_ joined
nine Speaking of opinions: when one loads a Perl 5 module with use Foo:from<Perl5>; Inline::Perl5 creates a Foo package in Perl 6 space. Question: should it also create packages for modules loaded by Foo? Some modules like SNMP depend on this. You load the master module and get a whole namespace. 15:49
pmurias moritz: the Hague grants has a more flexible process which should allow me to submit it later this week rather then today which should allow me to finish up some nqp-js things to have a cleaner starting point 15:52
hoelzro nine: maybe only packages that are within the Foo:: package
(also, morning #perl6)
PerlJam nine: what hoelzro said.
jnthn pmurias: "web-base REPL" -> "web-based REPL" 15:53
nine hoelzro: good morning! Yes, that might be a workable compromise.
jnthn pmurias: It's a nit but "Get the part of the rakudo setting written in NQP" is a little off in that I don't consider the MOP/BOOSTRAP part of the setting really. 15:54
PerlJam nine: btw, if there's already a Foo in P6-space, what happens when you do use Foo:from<Perl5> ? (and how does that affect creating sub Foo:: namespaces>?)
15:54 kjs_ joined
jnthn pmurias: One area of concern: what is your strategy for taking on gather/take? 15:55
15:55 xinming joined 15:57 Psyche^_ joined, FROGGS left
zengargoylew i tend to think of P6 having everything lexical scoped, so name collisions are easily avoided/worked-around 15:58
dalek ast: b0c517b | coke++ | S32-hash/adverbs.t:
Fudge for the JVM so we can complete the test.
15:59 ZoffixW joined
ZoffixW Is there any way to shove that ( $h, $s, $v ) unpacking into the signature? 16:00
m: sub x ( Array $x ){ my ( $h, $s, $v ) = $x; say [$h, $s, $v].perl }; x [42, 54, 72];
camelia rakudo-moar b18ada: OUTPUT«[42, 54, 72]␤»
timotimo sure
m: sub x ( Array $x ($h, $s, $v) ) { say $h; say $s; say $x; }; x [42, 54, 72];
camelia rakudo-moar b18ada: OUTPUT«42␤54␤[42 54 72]␤»
16:00 Psyche^ left
moritz m: sub x ( @ ( $v, $s, $v ) ) { say [$h, $s, $v].perl }; x [42, 54, 72] 16:00
camelia rakudo-moar b18ada: OUTPUT«5===SORRY!5=== Error while compiling /tmp/oVx7i_lRTg␤Redeclaration of symbol $v␤at /tmp/oVx7i_lRTg:1␤------> 3sub x ( @ ( $v, $s, $v7⏏5 ) ) { say [$h, $s, $v].perl }; x [42, 5␤ expecting any of:␤ shape declaration␤»
moritz m: sub x ( @ ( $h, $s, $v ) ) { say [$h, $s, $v].perl }; x [42, 54, 72] 16:01
camelia rakudo-moar b18ada: OUTPUT«[42, 54, 72]␤»
dalek p: 427fedd | jnthn++ | src/ (2 files):
Cope properly with params whose name is "".
moritz too slow, timotimo++ too fast
ZoffixW Oh, sweet. Perl6++ timotimo++ moritz++
timotimo :3
dalek p: 54f2adf | jnthn++ | tools/build/MOAR_REVISION:
Bump MOAR_REVISION for named arg flattening fixes.
p: bf7b9bb | jnthn++ | src/vm/moar/QAST/QASTOperationsMAST.nqp:
Don't dis-order flattening named args on Moar.
16:02 Nei joined
dalek kudo/nom: 80ea923 | jnthn++ | / (3 files):
Bump to NQP/Moar with flattening named arg fixes.

This entailed some ABI changes, chased in the C updates in this patch.
16:03
pmurias jnthn: thank you for nitpicking, carefully reading is appreciated. ;) 16:04
dalek ast: 326b413 | jnthn++ | S06-signature/named-parameters.t:
Tests for RT #113546.
synbot6 Link: rt.perl.org/rt3/Public/Bug/Display...?id=113546
pmurias jnthn: I should really think over on my gather/take support so it doesn't end up a huge performance hit 16:05
Skarsnik what is the type for type? like if want to write sub foo($a){}; foo(int32); what should I put in front of $a?
timotimo Any:U for example
moritz types are typically objects of their own type, so Int is an Int :-) 16:06
and :U means undefined, so not an instance
ZoffixW wonders if Perl 6 has some sort of magical .range-limit thing
timotimo that's right
pmurias jnthn: something naive like a CPS transform everywhere is something that's best avoided
jnthn pmurias: It's not just a perf issue, getting it to work at all can take quite some engineering.
ZoffixW Some more concise way to write this: fpaste.scsys.co.uk/501566
timotimo i have no idea what you expect ".range-limit" to be
moritz m: say uint32.Range
camelia rakudo-moar b18ada: OUTPUT«0..4294967295␤»
timotimo well, we have max= and min= 16:07
ZoffixW $x.range-limit(0..^360);
zengargoylew m: sub foo(::T $type){ say T }; foo(Int);
camelia rakudo-moar b18ada: OUTPUT«(Int)␤»
ZoffixW And if it's below, it assigns 0, and if it's above, it assigns 360
moritz ZoffixW: subset Degree of Real where 0..^360
oh, coercive
ZoffixW Yeah, it has to be coercive.
cygx ZoffixW: but degrees should wrap around, not truncate 16:08
16:08 kjs_ left
timotimo m: my $a = 1000; $a min= 100; $a max= 0; say $a 16:08
camelia rakudo-moar b18ada: OUTPUT«100␤»
timotimo m: my $a = -2; $a min= 100; $a max= 0; say $a
camelia rakudo-moar b18ada: OUTPUT«0␤»
moritz m: sub clip-to($min, $value, $max) { $min min $value max $max }; say clip-to(0, 720, 360)
camelia rakudo-moar b18ada: OUTPUT«5===SORRY!5=== Error while compiling /tmp/mYSVpmClk2␤Operators 'min' and 'max' are non-associative and require parentheses␤at /tmp/mYSVpmClk2:1␤------> 3to($min, $value, $max) { $min min $value7⏏5 max $max }; say clip-to(0, 720, 360)␤ …»
nine PerlJam: probably the best way is to error out loudly if there's already a Foo in Perl 6 space. Of course everything would be easier, if we had actual support for long module names with an :auth
moritz m: sub clip-to($min, $value, $max) { ($min min $value) max $max }; say clip-to(0, 720, 360)
camelia rakudo-moar b18ada: OUTPUT«360␤»
ZoffixW Wow
cygx, maybe in math, but I doubt that's the case with colours, which what I'm working on right now :) 16:09
PerlJam feels like the clip-to op should already be there to me for some reason 16:10
16:10 MadcapJake left
moritz PerlJam: why? it's trivial to reproduce, and not used very often 16:10
16:10 rindolf joined
PerlJam If I knew why I wouldn't have said "for some reason" :) 16:11
dalek ast: f27b0ce | jnthn++ | S06-currying/named.t:
Unfudge RT #123498 tests.
synbot6 Link: rt.perl.org/rt3/Public/Bug/Display...?id=123498
16:11 rindolf left
pmurias jnthn: yes, the tricky part seem to be to get it to work without making everything else dog slow 16:12
16:12 rindolf joined
zengargoylew m: sub clip-to($min, $value, $max) { ($min min $value) max $max }; say clip-to(0,120,360) 16:12
camelia rakudo-moar 80ea92: OUTPUT«360␤»
ZoffixW moritz++ thanks. That clip-to is awesome.
zengargoylew m: sub clip-to($min, $value, $max) { ($min max $value) min $max }; say clip-to(0,120,360)
camelia rakudo-moar 80ea92: OUTPUT«120␤»
16:12 rindolf left
zengargoylew reversed your min/max there 16:13
jnthn m: sub () {}.(|{:a})
camelia rakudo-moar 80ea92: OUTPUT«Unexpected named parameter 'a' passed␤ in sub at /tmp/7GzxvoJJRR:1␤ in block <unit> at /tmp/7GzxvoJJRR:1␤␤»
zengargoylew m: sub clip-to($min, $value, $max) { ($min max $value) min $max }; say clip-to(0,400,360)
camelia rakudo-moar 80ea92: OUTPUT«360␤»
16:13 rindolf joined, pippo left 16:14 rindolf left
PerlJam moritz: clip-to fits in the same mental space as minmax for me, so I think why should one exists but not the other. (that's as close to a "why" as I can muster right now) 16:14
16:15 grondilu left
dalek ast: 0a27790 | jnthn++ | S06-signature/named-parameters.t:
Unfudge now-passing RT #77788 test.
16:15
synbot6 Link: rt.perl.org/rt3/Public/Bug/Display...l?id=77788
PerlJam moritz: squish is another one that seems odd in a similar way
dalek ast: bf1fd08 | coke++ | S03-metaops/hyper.t:
Fudge for the JVM so we can complete the test.
16:16
jnthn Fix one RT, get two for free...
PerlJam moritz: or repeated. that's another odd one. 16:17
zengargoylew i think some things were just needed internally and well... might as well give them names and make them available.
jnthn Down to 45 xmas RTs
colomon moritz: really? I find that for work, I need something like clip-to reasonably often. (Though almost never for the case of angles! usually you care about how far outside the range you are in that case.) 16:18
16:18 pippo joined
moritz colomon: I guess our works are very different :-) 16:18
16:20 Nei left
Skarsnik hm, is there something to say to say/print and co to display nothing? 16:20
[Coke] m: say "" 16:21
camelia rakudo-moar 80ea92: OUTPUT«␤»
PerlJam Skarsnik: do you have some special idea of "nothing"?
Skarsnik m: my $silent = True ;say "Hello there" if !$silent;
camelia ( no output )
Skarsnik I mean the equivalent of this 16:22
timotimo well, say puts a newline in any case
no matter what you pass
what you can do is have a list of things to say and if that list is empty, nothing gets said 16:23
and you can also .say with $foobar
pmurias jnthn: do you think 3 months of full time effort is a realistic estimate for rakudo-js?
16:23 rangerprice joined
timotimo m: my $foo; say "hey" with $foo; 16:23
camelia ( no output )
pippo It is possible to have say do nothing by setting out-nl to ""; I think.
PerlJam pmurias: At what level of parity? :-) 16:24
16:24 rangerprice left
timotimo that's true, too 16:24
Skarsnik I mean I can close stdout but it's seem overkill x)
timotimo closing stdout is a bit dangerous
jnthn Skarsnik: You could just lexically re-define say :)
Skarsnik: Or set $*OUT = class { method print(|) { } }; or so 16:25
brrt mr_ron, cygx, moar-on-mingw should work now
thanks for the fixes :-)
pippo m: $*OUT.nl = ""; say '';
16:25 telex left
camelia ( no output ) 16:25
jnthn pmurias: I find it hard enough to estimate my own work rate, let alone other people's... :)
Skarsnik jnthn, you mean like defining a sub say localy? 16:26
jnthn pmurias: I think allowing a month to get to the point of being ready to attack CORE.setting, a month to actually slog through compiling/startup of that, and a month for the rest, is kinda reasonable.
[Coke] as someone who is theoretically paid to deal with estimating how long it takes people to do this sort of thing, it's hard. And it doesn't matter because your boss will just rewrite your estimates anyway. :)
16:26 telex joined
[Coke] "it'll take six months" "ok, but we have to deliver something in 5 weeks." ... ... "right, then." 16:26
jnthn m: sub say(|) { }; say('lol i said willy and you will never see it!')
camelia ( no output )
ZoffixW wishes for some sort of "usage to signature" converter. 16:27
jnthn pmurias: The Big Risk for me is the gather/take thing
ZoffixW Why doesn't this { Color.new( hsv => [ 229, 100, 100 ] ) } match multi method new (Pair $p) {} signature?
jnthn pmurias: In Moar it was only as bad as "implement continuations", except the need to do that kinda influenced a lot of the rest of the design of the VM. ON the JVM it was a global CPS transform. 16:28
timotimo ZoffixW: because it's a named parameter
psch m: sub f(:$a) { say "named" }; sub f(Pair $p) { say "Pair" }; f a => 1; f "a" => 1
camelia rakudo-moar 80ea92: OUTPUT«5===SORRY!5=== Error while compiling /tmp/sbf5OXG8nk␤Redeclaration of routine f␤at /tmp/sbf5OXG8nk:1␤------> 3"named" }; sub f(Pair $p) { say "Pair" }7⏏5; f a => 1; f "a" => 1␤ expecting any of:␤ horizontal whitespace␤ …»
timotimo ZoffixW: if you quote the LHS, you'll get a Pair object passed
jnthn pmurias: The JVM code-gen was written with the CPS transform in mind
ZoffixW Aha
psch m: multi f(:$a) { say "named" }; multi f(Pair $p) { say "Pair" }; f a => 1; f "a" => 1 # vOv
camelia rakudo-moar 80ea92: OUTPUT«named␤Pair␤»
ZoffixW Thanks, timotimo++ 16:29
jnthn pmurias: My gut feeling is that if it hadn't been, it woulda been really tricky to retrofit.
pmurias: I don't think you'll be in quite such an awkward position; I had to deal with the JVM stack rules (like, when the stack must be clear, etc.)
And I didn't have to deal at all with wiring up the thing at the end of the day 'cus sorear++ did that :) 16:30
pmurias I'm considering moving tackling that to the front
16:30 diana_olhovik_ left
jnthn Yeah 16:30
[Coke] is getting a ton of new(?) NPE's in rakudo-jvm roast.
jnthn Note that you only need single-shot continuations.
The JVM impl can do multi-shot ones. Moar...sorta half kinda does but not really.
tony-o_ [Tux]: should be corrected now 16:31
pmurias I implemented single-shot ones one nqp-js using threads on node.js
PerlJam pmurias: just plan for things taking twice as long as you think so that if they suddenly don't you'll be pleasantlys surprised; and if they do, then you're a wizard at estimation :)
jnthn pmurias: Yes, it's wise to bring it up front.
pmurias won't be as easy in the browser
jnthn Aye 16:32
It was certainly one of the hardest things in the JVM impl, imo
16:33 sprocket joined 16:35 xfix joined
|Tux| tony-o_++ 16:36
16:37 brrt left, cdc_ joined
cdc_ m: multi sub fib(0) { 0 }; multi sub fib(1) { 1 }; multi sub fib(Int $a where * > 0) is cached { fib($a - 1) + fib($a - 2) }; fib(2) 16:37
camelia rakudo-moar 80ea92: OUTPUT«Cannot invoke object with invocation handler in this context␤ in block <unit> at /tmp/WFylEBqWD6:1␤␤»
cdc_ Is this ^ a known bug? 16:38
16:39 Ven joined, rindolf joined
jnthn cdc_: Yeah, it hits a known limitation burried down at the VM level 16:39
16:39 zakharyas left
jnthn Not sure if that particular case is filed 16:40
cdc_ oh yes, #125278
synbot6 Link: rt.perl.org/rt3/Public/Bug/Display...?id=125278
cdc_ I should have search in RT before asking, sorry.
jnthn np :)
[Coke] it's not easy to find things in RT, no worries.
ugexe there isnt a search RT operator yet? 16:42
[Coke] I am going to write a tool that grabs all the RT: numbers I occasionally post here, but getting any perl6 web stuff to work when on my dayjob ends up being very painful, usually. 16:44
16:44 Ven left
ZoffixW Weird that syntax highlighting breaks on several code blocks below this one the docs.perl6.org/type/Signature#Const...ned_Values 16:46
ZoffixW doesn't see any difference in the way the POD written for working and broken ones 16:47
16:47 grondilu joined
timotimo [Coke]: allegedly, the RT instance has a reachable API so you at least don't have to manipulate HTML to get it 16:48
[Coke]: but i was unable to get it to work
hoelzro ZoffixW: are you talking about the second block? 16:49
that's *really* weird
[Coke] timotimo: mm, rest api is good. My problem usually involves getting tools to work with the http proxy. 16:50
timotimo ugh, http proxy, that's bad
ZoffixW hoelzro, yeah second block and a couple after it. I opened an Issue: github.com/perl6/doc/issues/201 16:51
timotimo don't think i know much about our HTTP modules with regards to proxy compat
hoelzro wonders if that's pygments', and thus his, fault
zengargoylew is it because there are bolded things? 16:52
rindolf ZoffixW: hi, sup?
ZoffixW rindolf, hey
hoelzro ZoffixW: I'm wondering if it's the lack of a trailing semi-colon in the previous example 16:53
but the examples shouldn't affect each other
ZoffixW zengargoylew, good eye!
rindolf ZoffixW: how are you?
hoelzro ah, that bolded thing makes sense; I thought that was a side effect of the lack of highlighting
zengargoylew i've notice a few underlined links in code examples as well, not sure if i like that.
spent a few moments going wtf is a => with a bar under it? 16:54
timotimo oh, the > was terminating a pod tag?
ZoffixW rindolf, good. you? 16:56
Hm. There is "=for code :allow<B L>"
rindolf ZoffixW: I'm fine, my solution to the N-queens problem in Perl 5 (for the most recent Project Euler problem) is too slow. 16:57
ZoffixW has totally forgotten now why they were reading the /Signatures doc :D
rindolf, that's too bad.
Oh, right. 16:58
arnsholt timotimo: Pushed to iperl6kernel and Net-ZMQ 16:59
timotimo glad to hear it!
ZoffixW Is it possible to check the array contains the right type and number of elements in a signature? e.g. sub foo (Array [Rat, Rat, Rat] :$rgb) { ... }
timotimo not like that
you can have a "where" clause, though
if you type the array to be of Rat, the user has to explicitly define the array passed in to be of a fitting type 17:00
ugexe wasnt there a way to pass a %hash but in the signature get only specific key/values from it?
timotimo sure
ugexe what is the term im looking for 17:01
arnsholt Destructuring, probably
Or pattern matching
timotimo m: sub test(% (:onekey($eins), :twokey($zwei)) { say $eins; say $zwei }; test({onekey => 1, twokey => 42})
camelia rakudo-moar 80ea92: OUTPUT«5===SORRY!5=== Error while compiling /tmp/xC8GxjUkSo␤Missing block␤at /tmp/xC8GxjUkSo:1␤------> 3test(% (:onekey($eins), :twokey($zwei)) 7⏏5{ say $eins; say $zwei }; test({onekey =␤»
timotimo m: sub test(% (:onekey($eins), :twokey($zwei))) { say $eins; say $zwei }; test({onekey => 1, twokey => 42})
camelia rakudo-moar 80ea92: OUTPUT«1␤42␤»
ZoffixW m: sub foo (Rat :$rgb where $_.elems == 3 ) { ... }; foo rgb => [42, 45, 45]
camelia rakudo-moar 80ea92: OUTPUT«Type check failed in binding $rgb; expected Rat but got Array␤ in sub foo at /tmp/9o40VnqxED:1␤ in block <unit> at /tmp/9o40VnqxED:1␤␤»
timotimo not like that, either, ZoffixW ;) 17:02
ZoffixW reads more of /Signature
timotimo that'd have to be :@rgb so you'll expect an array at all
ugexe destructuring was it arnsholt++
timotimo and if it's typed Rat (as in: Rat :@rgb) the user'll have to Array[Rat].new(42, 45, 45)
ZoffixW Oh. Nah
17:08 espadrine_ joined, cdc_ left
ZoffixW Weird that this doesn't fail: 17:09
m: sub foo (Array :$rgb where { $_.elems == 3 and not grep { ($_ + .0).^name ne 'Rat' }, $_ } ) { say $rgb[1]}; foo rgb => [42, 45, 'x'];
camelia rakudo-moar 80ea92: OUTPUT«45␤»
mrf should $<foo>= not trigger a call to method foo in an action in a Grammar? 17:11
jnthn mrf: No. It's not capturing that triggers action method calls, it's reaching the end of a token/rule/regex 17:12
arnsholt The $<foo>= syntax just names the slot where something is to be stored 17:13
psch m: say ($_ + .0).^name given 42
camelia rakudo-moar 80ea92: OUTPUT«Rat␤»
psch ZoffixW: adding a Rat to an Int gives you a Rat
arnsholt If you really, really need to trigger code in the middle of a regex, you can either use a code interpolation with { }, or split your rule into two
ZoffixW psch, yeah, but I have an 'x' in there
m: ('x' + .0).^name ne 'Rat' 17:14
camelia rakudo-moar 80ea92: OUTPUT«WARNINGS:␤Useless use of "ne" in expression ".^name ne 'Rat'" in sink context (line 1)␤Cannot convert string to number: base-10 number must begin with valid digits or '.' in '7⏏5x' (indicated by 7⏏)␤ in block <unit> at /tmp/uZwnce_F9Q:1␤…»
psch m: say not grep (True, False )
camelia rakudo-moar 80ea92: OUTPUT«True␤»
mrf hmm ok, That anoying as <My::Other::Grammar::token> doesn't call and action method of token. I was hoping that $<token>=<My::Other::Grammar::token> would
arnsholt Ooooh, I see. Yeah, that can potentially be annoying 17:15
Don't have a neat solution for that one, off-hand
ZoffixW m: say not so grep (True, True ) 17:16
camelia rakudo-moar 80ea92: OUTPUT«True␤»
ZoffixW m: say not grep { $_ }, True, True
camelia rakudo-moar 80ea92: OUTPUT«False␤»
psch oh, right
mrf arnsholt: No worries. Will see if I can work round the issue for now
psch that where is messing with topicalization... :)
Skarsnik Interesting comparing a csizeof on a struct and a ncsizeof can hide some interesting mistake pastebin.com/2c2T7J6Q
psch m: sub foo (Array :$rgb where { $_.elems == 3 and all($_) ~~ Rat }) { say $rgb[1]}; foo rgb => [42, 45, 'x']; # probably..? 17:17
camelia rakudo-moar 80ea92: OUTPUT«Constraint type check failed for parameter '$rgb'␤ in sub foo at /tmp/CWp7ehrv9h:1␤ in block <unit> at /tmp/CWp7ehrv9h:1␤␤»
psch m: say Int ~~ Rat
camelia rakudo-moar 80ea92: OUTPUT«False␤»
psch nah
m: say not grep { True, True, False }, [42, 45, 'x'] 17:18
camelia rakudo-moar 80ea92: OUTPUT«False␤»
psch errr
psch slowly steps away from the keyboard 17:19
ZoffixW What does my sub need to return to simulate self.bless(:$r, :$g, :$b); ? I've tried return r => $r, g => $g, b => $b; and return [r => $r, g => $g, b => $b]; but I still seem to get the defaults for those attributes instead of my new values
ZoffixW feels so dumb now -_-
cygx github.com/rakudo/rakudo/blob/nom/...d.nqp#L850 17:20
^ not very windows friendly, that one
17:21 mathw left, llfourn joined
moritz ZoffixW: please show the class definition 17:21
ZoffixW moritz, here: github.com/zoffixznet/perl6-Color/....pm6#L3-L6 then here, I'm printing values and returning github.com/zoffixznet/perl6-Color/...m6#L41-L43 17:22
Here I'm running the example code: github.com/zoffixznet/perl6-Color/...lor.pl6#L5 and my output is fpaste.scsys.co.uk/501567 17:23
The "000" means the attributes are at the defaults
17:26 M-Illandan left, eternaleye left
moritz 17:26
return self.bless(:$r, :$g, :$b); looks good to me
ZoffixW moritz, I have a multi new. The second one is troublesome: github.com/zoffixznet/perl6-Color/...or.pm6#L16 17:27
17:27 kjs_ joined
ZoffixW moritz, I suspect it might be because my attributes are Int and the hsv2rgb is returning a rat or something eslse 17:27
moritz m: say (a => 2.4, b => 3.5)>>.Int.perl 17:28
camelia rakudo-moar 80ea92: OUTPUT«Method 'Int' not found for invocant of class 'Pair'␤ in block <unit> at /tmp/47WgrD3tEj:1␤␤»
17:28 ribasushi left 17:29 mspo joined, pippo left
sprocket hello, p6 17:29
ZoffixW \o
moritz m: my %rgb = (a => 2.4, b => 3.5); .=Int() for %rgb.values; say %rgb.perl 17:30
camelia rakudo-moar 80ea92: OUTPUT«{:a(2), :b(3)}␤»
moritz ZoffixW: ^^ you could use something like this
sprocket if i had a method: method foo() returns Bar { …. } how can i declare it to sometimes return a Bar type object, but sometimes nothing?
ZoffixW I'm actually trying to have some sort of "generic number" so that passing ( a => 1, b => 2.5 ) would work. 17:31
Man. This type stuff is hard after a decade of Perl 5 coding :/
moritz sprocket: you could return a Nil type object, which newest rakudo allows even when a differen return type is declared
pink_mist ZoffixW: so ... Num?
PerlJam sprocket: Can "nothing" be an undefined Bar thingy? OR do you really and truly mean nothing?
ZoffixW pink_mist, Type check failed in assignment to $!r; expected Num but got Int
:)
moritz ZoffixW: Real would be the correct type constraint
ZoffixW: that allows Int, Num and Rat 17:32
ZoffixW Ah. Thanks, moritz++
sprocket Perljam: i suppose it’s a “sometimes Bar exists, sometimes it doesn’t” - like a return from a SQL query that has 0 rows
moritz doc.perl6.org/type/Real look at the type graph 17:33
sprocket mortiz: ah, ok, i had been returning Nil, but was getting a type error; perhaps i just need to update my rakudo
17:33 bpmedley joined
ab5tract_ sprocket: in general i would just assume an empty list for a return of 0 rows 17:34
s/assume/expect/
Nil is a bit overkill imo 17:35
timotimo m: say all([42, 42, 'x']) ~~ Real
camelia rakudo-moar 80ea92: OUTPUT«all(True, True, False)␤»
timotimo m: say so all([42, 42, 'x']) ~~ Real
camelia rakudo-moar 80ea92: OUTPUT«False␤»
timotimo ZoffixW: how does that sound?
ZoffixW Awesome, timotimo++
timotimo it's not very nice performance-wise, though 17:36
ZoffixW Ah. Then I'll skip it
ab5tract_ m: say [&&] [~~] [42,42,'x']
camelia rakudo-moar 80ea92: OUTPUT«False␤»
timotimo m: (1, 2, 3) ~~ [Rat, Rat, Rat]
camelia ( no output )
timotimo m: say (1, 2, 3) ~~ [Rat, Rat, Rat]
camelia rakudo-moar 80ea92: OUTPUT«False␤»
ab5tract_ ZoffixW: that's the junction free version
timotimo m: say (1, 2, 3) ~~ [Real, Real, Real]
camelia rakudo-moar 80ea92: OUTPUT«True␤»
mspo should that look like OUTPUT<<False n/l>> or is my utf8 broken
17:36 M-Illandan joined
timotimo m: say (1, 2, 'x') ~~ [Real, Real, Real] 17:36
camelia rakudo-moar 80ea92: OUTPUT«False␤»
17:36 M-eternaleye joined
timotimo that works, too 17:36
and should have you better performance than the version with all()
ab5tract_ oops 17:37
timotimo *and* you can put it directly as the thing where matches against
ab5tract_ m: say [&&] 42,42,'x' X~~ Real
camelia rakudo-moar 80ea92: OUTPUT«False␤»
ZoffixW m: sub second (Real :$r, Real :$g, Real :$b) { say [$r, $g, $b ]}; sub first { return r => 24, g => 55, b => 45 }; second first
camelia rakudo-moar 80ea92: OUTPUT«Too many positionals passed; expected 0 arguments but got 1␤ in sub second at /tmp/CRS2VZ2iFZ:1␤ in block <unit> at /tmp/CRS2VZ2iFZ:1␤␤»
17:37 tokuhiro_ joined
ab5tract_ that;s better 17:37
ZoffixW Is there some way to make this work?
moritz äääääÄAÄää ,xxxxxxxxxxxxa6512e1d2 xe5wref3c- frrx
timotimo m: sub hsv($foo where [Real, Real, Real]) { }; hsv(1, 2, 3); hsv("hi", "how", "are") # you
camelia rakudo-moar 80ea92: OUTPUT«Too many positionals passed; expected 1 argument but got 3␤ in sub hsv at /tmp/Bdk6jMIpR0:1␤ in block <unit> at /tmp/Bdk6jMIpR0:1␤␤»
timotimo oh, derp :)
ilmari mspo: yes, except that "<<", "n/l" and ">>" are a single character each
timotimo m: sub hsv(*@foo where [Real, Real, Real]) { }; hsv(1, 2, 3); hsv("hi", "how", "are") # you
camelia rakudo-moar 80ea92: OUTPUT«Constraint type check failed for parameter '@foo'␤ in sub hsv at /tmp/n1co465GZk:1␤ in block <unit> at /tmp/n1co465GZk:1␤␤»
mspo ilmari: yeah I can't type them into the term but I can see them 17:38
ilmari: is the n/l newline?
timotimo m: sub hsv(*@foo where [Real, Real, Real]) { say "yay!"; }; hsv(1, 2, 3); hsv("hi", "how", "are") # you
camelia rakudo-moar 80ea92: OUTPUT«yay!␤Constraint type check failed for parameter '@foo'␤ in sub hsv at /tmp/JbQREV_Wxk:1␤ in block <unit> at /tmp/JbQREV_Wxk:1␤␤»
timotimo see, there's a yay and a failure in there
m: sub hsv(*@foo where [Real, Real, Real]) { say "yay!"; }; hsv("hi", "how", "are", "you")
camelia rakudo-moar 80ea92: OUTPUT«Constraint type check failed for parameter '@foo'␤ in sub hsv at /tmp/RPw4PfHC0c:1␤ in block <unit> at /tmp/RPw4PfHC0c:1␤␤»
ilmari mspo: yes, U+02424 - SYMBOL FOR NEWLINE
timotimo m: sub hsv(*@foo where [Real, Real, Real]) { say "yay!"; }; hsv(1, 2)
camelia rakudo-moar 80ea92: OUTPUT«Constraint type check failed for parameter '@foo'␤ in sub hsv at /tmp/E2k4wkPIUq:1␤ in block <unit> at /tmp/E2k4wkPIUq:1␤␤»
17:38 kusuriya joined
ab5tract_ timotimo: yeah but if you don't want to deal with hardcoding the numbers... 17:38
mspo ilmari: okay cool, screen -U works I guess ;)
timotimo it doesn't give a very good error message, though
ab5tract_: i lost the context through all of these camelia outputs :( 17:39
ab5tract_ m: sub hsv(*@foo where * X~~ Real) { say "yay!" }; hsv(4,5,6)
camelia rakudo-moar 80ea92: OUTPUT«5===SORRY!5=== Error while compiling /tmp/qwCXbZk44v␤Malformed parameter␤at /tmp/qwCXbZk44v:1␤------> 3sub hsv(*@foo where * X~~7⏏5 Real) { say "yay!" }; hsv(4,5,6)␤ expecting any of:␤ infix␤ infix stopper␤»
ab5tract_ m: sub hsv(*@foo where { @_ X~~ Real }) { say "yay!" }; hsv(4,5,6)
camelia rakudo-moar 80ea92: OUTPUT«yay!␤»
17:39 ribasushi joined, kusuriya left
timotimo ab5tract_: oh, you mean you don't want to hard-code that HSV only takes 3 arguments? 17:39
ab5tract_ in general it makes a lot more sense to reach for X and [&&] / [||] when porting a junction 17:40
s/a lot//
ZoffixW Don't see anything in docs.perl6.org/language/functions
ab5tract_ ymmv ofc
ugexe are junctions significantly slower?
17:41 Ven joined
ab5tract_ ugexe: yeah.. no one has explained why they don't map to [&&] in the implementation, though I'm not sure if I ever asked.. 17:41
17:41 tokuhiro_ left
ab5tract_ ugexe: for a one off it shouldnt matter 17:41
but in a hot loop it would
17:42 crucialrhyme joined
cygx github.com/rakudo/rakudo/pull/588 # fixes bogus $?FILE on windows in case of absolute paths 17:42
ab5tract_ timotimo: it's not my example, but yeah, I think a hardcoded length is pretty far from a junction
in terms of user expectation
ugexe ab5tract_: good to know. i use @a.any/all/none ~~ @a.any/all/none in a few spots that i think would be improved
er @a and @b 17:43
ab5tract_ ZoffixW: did you get my info about using [&&] 42,55.5,'x' X~~ Real ?
timotimo ab5tract_: well, if you have a function called "hsv", you'd expect three positional parameters, no? :P
ab5tract_ yeah, I guess :P
timotimo the code before that had an explicit check for the length against 3
so yeah, you'd end up with code that doesn't hard-code the length right next to a hard-coded length check
ab5tract_ whoops :) 17:44
ZoffixW ab5tract_, I've no idea what that code does and I was planning to look it up when I figure out how to make my arg passing work :)
m: sub second (Real :$r, Real :$g, Real :$b) { say [$r, $g, $b ]}; sub first { return r => 24, g => 55, b => 45 }; second first # this one
camelia rakudo-moar 80ea92: OUTPUT«Too many positionals passed; expected 0 arguments but got 1␤ in sub second at /tmp/hJPutFZfqi:1␤ in block <unit> at /tmp/hJPutFZfqi:1␤␤»
ab5tract_ ZoffixW: it's just "how" you port a junction
timotimo fair enough
ZoffixW I've no idea what a "junction" is either :P
ZoffixW is dumb
ab5tract_ m: sub second (Real :$r, Real :$g, Real :$b) { say [$r, $g, $b ]}; sub first { return r => 24, g => 55, b => 45 }; second |first 17:45
camelia rakudo-moar 80ea92: OUTPUT«Too many positionals passed; expected 0 arguments but got 3␤ in sub second at /tmp/GRGkZMgwLg:1␤ in block <unit> at /tmp/GRGkZMgwLg:1␤␤»
timotimo ZoffixW: i think return with named parameters is not what you want
ab5tract_ m: sub second (Real :$r, Real :$g, Real :$b) { say [$r, $g, $b ]}; sub first { return r => 24, g => 55, b => 45 }; second(|first)
camelia rakudo-moar 80ea92: OUTPUT«Too many positionals passed; expected 0 arguments but got 3␤ in sub second at /tmp/Z4QfFPkiT4:1␤ in block <unit> at /tmp/Z4QfFPkiT4:1␤␤»
17:45 Ven left
ab5tract_ m: sub second (Real :$r, Real :$g, Real :$b) { say [$r, $g, $b ]}; sub first { return r => 24, g => 55, b => 45 }; second(|%(first)) 17:45
camelia rakudo-moar 80ea92: OUTPUT«[24 55 45]␤»
timotimo m: say what.perl; sub what { return a => 1, b => 2, c => 3 }
camelia rakudo-moar 80ea92: OUTPUT«(:a(1), :b(2), :c(3))␤»
timotimo oh
ab5tract_ m: sub second (Real :$r, Real :$g, Real :$b) { say [$r, $g, $b ]}; sub first { return %( r => 24, g => 55, b => 45 ) }; second(|first)
timotimo oh, right, that was added at some point in the recent months
camelia rakudo-moar 80ea92: OUTPUT«[24 55 45]␤»
ab5tract_ yup! it's still pretty new 17:46
ZoffixW Oh, YEY
ab5tract_++
ab5tract_ ZoffixW: what's happening there is that you are in one case returning a list of pairs
which is not a hash
ZoffixW Ah
ab5tract_ and then furthermore a hash is a positional argument unless you Slup it
*Slip 17:47
timotimo Slup is short for Slip Up?
ab5tract_ timotimo: nope, it only *was* a Slip Up :)
ZoffixW: as for my other point about junctions, see timotimo 17:48
see timotimo++'s hsv sub for the version you most likely want
timotimo my office hours are daily whenever i'm on irc 17:49
though i suggest you don't travel all the way here just for junction advice
ab5tract_ shit, i never sign off.. must be a heck of a bill i owe you now ;)
timotimo nah, it's not like that. i only charge after having agreed to an actual appointment 17:50
ab5tract_ good to know :)
timotimo (in case you didn't catch it, i started this pun-tangent because you wrote "see timotimo")
ab5tract_ today i'm following you successfully so far :) 17:51
timotimo \o/
ab5tract_ our way of communication is not so weird ;) 17:52
timotimo m) yeah
ZoffixW ISAGN for DIE_ON_FAIL for tests akin to Perl 5's Test::Most. Set DIE_ON_FAIL env var to true and the output stops at first fail :) 17:56
ZoffixW is working backwards up the test suite right now.. too lazy to scroll
18:01 dakkar left 18:02 pmurias__ joined, pmurias_1 joined 18:03 muraiki joined, pmurias_ left
timotimo "I See A Grave Need"? 18:03
RabidGravy ZoffixW, with you on that, the first fail is sometimes all that you need to fix it ;-) 18:04
18:05 pmurias left
ZoffixW timotimo, Great 18:06
18:07 domidumont left
ZoffixW RabidGravy, yeah, and when you're doing TDD, you get a ton of output and you're only interested at the stuff on the top :) 18:08
nine ZoffixW: shift+home to jus scroll to top? 18:09
ZoffixW nine, when I press shift+home I see stuff from like 5 days ago :P 18:10
(`clear` isn't helping it either)
RabidGravy :)
nine Clear your history :) Ctrl+Shift+k in KDE's konsole. I press it every time before I start a compilation or test run. Makes life so much easier. 18:11
Of course that necessitates running those in their own terminal tab which is a good idea in any case.
18:12 znpy joined
ab5tract_ i have a p6 specific design question 18:13
github.com/ab5tract/Terminal-Print...ds.pm6#L87
I would like to parametrically configure my module on export
ZoffixW Oh. I guess that's better than nothing :) Thanks! nine++
ab5tract_ sorry, on *import* 18:14
i feel like what i am doing there is a total abuse of EXPORT
i want modules to be able import my module with a variety of different settings. one obvious solution is to use another module which imports the base module and mutates there 18:15
. o ( module module module module module )
i find it on the one hand convenient that i get all that nice EXPORT::foo stuff for free with named args and such 18:16
ah.....
probably the proper way to do this would be to use a trait? 18:17
cygx I've written a multi sub EXPORT thta dispatches on Whatever, and I'm sticking with it ;)
nine ab5tract_: did not objects get invented to couple functions with some state?
ab5tract_ i don't see what you are getting at
i just feel like using EXPORT to solely mutate the state of my own module based on a parameter is a design smell 18:18
on an import parameter, that is.
so i was wondering what the best approach would be
(there's nothing i've mentioned that has to do with OOP, which is why I'm confused nine)
nine ab5tract_: Exactly. So why not just have something like my $terminal = Terminal::Print.new(:use-ansi); $terminal.clear; 18:19
ab5tract_ because BEGIN
nine That way you can have all the configurability you need and users don't conflict with each other
ab5tract_ but that's a good point
ZoffixW m: sub hsv( Array :$hsv where [Real, Real, Real]) { say "yay!"; }; hsv( hsv => [1, 2, 3] ) 18:20
camelia rakudo-moar 80ea92: OUTPUT«yay!␤»
ZoffixW ^ that's what I ended up going with. Thanks timotimo++ ab5tract_++
ab5tract_ this can probably be moved away from BEGIN
and anyway I could just provide both the universal and ansi variants out of the BEGIN block
thanks for pointing that out nine, it does help in this case
18:21 FROGGS joined
nine :) 18:21
ab5tract_ ZoffixW: don't you thinkg you will get annoyed writing hsv( :hsv(@not-always-named-hsv) ) ? 18:22
18:23 znpy left
ab5tract_ if you wanted to go with named parameters, i would maybe be expecting hsv( :h(5), :s(5), :v(5.5) ) 18:23
otherwise it seems like a nice case for a pure-positional arg function to me. but TMTOWTDI, of course! :) 18:24
18:24 abaugher left
nine .tell jnthn just curious: why do you suggest Str $path in CompUnit::Loader and CompUnit::PrecompilationStore? 18:25
yoleaux nine: I'll pass your message to jnthn.
ZoffixW ab5tract_, my interface is Color.new( hsl => [ 72, 78, 65] ); Color.new( rgb => [ 72, 78, 65] ); Color.new( hsv => [ 72, 78, 65] ); etc.
18:26 abaugher joined
ab5tract_ awesome! 18:26
ZoffixW And I have a multi method new ( ... )
ab5tract_ ship it :)
ZoffixW :)
ab5tract_ yeah, in that case it is absolutely the perfect fit 18:27
\o/
cygx ZoffixW: can it also deal with Color.new(:hsv<72 78 65>) ?
ab5tract_ m: sub hsv( Array :$hsv where [Real, Real, Real]) { say "yay!"; }; hsv( hsv<1 2 3> ) 18:30
camelia rakudo-moar 80ea92: OUTPUT«Use of uninitialized value of type Array in numeric context in sub hsv at /tmp/e13cCeb8xK:1␤Use of uninitialized value of type Array in numeric context in sub hsv at /tmp/e13cCeb8xK:1␤Constraint type check failed for parameter '$hsv'␤ in sub hsv a…»
ab5tract_ m: sub hsv( Array :$hsv where [Real, Real, Real]) { say "yay!"; }; hsv( :hsv<1 2 3> )
camelia rakudo-moar 80ea92: OUTPUT«Type check failed in binding $hsv; expected Array but got List␤ in sub hsv at /tmp/Gkl7OhI02r:1␤ in block <unit> at /tmp/Gkl7OhI02r:1␤␤»
ab5tract_ m: sub hsv( Array() :$hsv where [Real, Real, Real]) { say "yay!"; }; hsv( :hsv<1 2 3> )
camelia rakudo-moar 80ea92: OUTPUT«yay!␤»
ab5tract_ that one's easy :D
ZoffixW \o/ 18:31
cygx++ ab5tract_++
ab5tract_ could see some sort of compile time flag (*cough* pragma *cough*) that makes that the default behavior
ZoffixW cygx, it can now :P
ab5tract_ "if can, coerc. else, die"
cygx
.oO( Color.new(:72h, :78s, :65v) )
18:32
ilmari m: sub hsv( List :$hsv where [Real, Real, Real]) { say "yay {$hsv.perl}!"; }; hsv( :hsv[1, 2, 3] ); hsv(:hsv(1,2,3)); hsv(:hsv<1 2 3>) 18:33
camelia rakudo-moar 80ea92: OUTPUT«yay $[1, 2, 3]!␤yay $(1, 2, 3)!␤yay $(IntStr.new(1, "1"), IntStr.new(2, "2"), IntStr.new(3, "3"))!␤»
dalek kudo/curli: d1c3026 | (Stefan Seifert)++ | src/core/CompUnit/Loader.pm:
Implement CompUnit::Loader::load-source and use it for load-source-file
18:34
hoelzro could a Windows user with tuits to spare help me getting my Linenoise module working on Windows? I sat down with FROGGS at the SPWS, but we ran into a problem with certain functions not being exported 18:38
I would really like to try to get it working on Windows so it could be included in Star
ab5tract_ hoelzro++ 18:40
ab5tract_ haz no windoze 18:41
18:41 M-eternaleye is now known as eternaleye, eternaleye left, eternaleye joined 18:43 Ven joined
hoelzro I have it, but I've yet to get a working moar + rakudo build on it 18:45
I've tried 7 and 8.1, with three versions of VS
cygx hoelwe've added some moarvm fixes for mingw just today 18:46
hoelzro: ^
(mis-tab)
18:47 Praise- is now known as Praise
cygx it should work out of the box with strawberry perl now 18:47
jnthn hoelzro: I've not a lot of spare tuits but: are the things you're wanting to call explicitly marked as exported when the DLL is built?
yoleaux 18:25Z <nine> jnthn: just curious: why do you suggest Str $path in CompUnit::Loader and CompUnit::PrecompilationStore?
hoelzro cygx: what kind of fixes? compilation, or runtime?
jnthn: I think we tried that, but to no avail
18:47 Ven left
hoelzro I can try to build again when I'm at my Windows box 18:48
dalek ast: 7018613 | coke++ | S02-types/baghash.t:
Fudge for the JVM so we can complete the test.
hoelzro I was able to build moar fine, but it would just segfault
jnthn .ask nine What would be more natural, in your view?
yoleaux jnthn: I'll pass your message to nine.
cygx hoelzro: build issues - you no longer need to disable the jit, and dyncall will no longer be compiled with g++ (which it did if the moon was right on some configurations)
hoelzro hmm 18:49
well, I'll try it
cygx hoelzro: even with MVM_SPESH_DISABLE=1?
hoelzro but I've been trying with VS, and I don't know if that'll help
cygx that would be a new one for me
hoelzro it's been a while since I've tried, but I think so
18:49 spider-mario joined
cygx I've been able to build with strawberry perl for a long time 18:50
I had to hack the Makefile until FROGGS fixe that, and then I had to disable the JIT (or even SPESH) until brrt pointed me in the right direction for a workaround 18:51
*fixed
18:51 ribasushi left
hoelzro I could try to get a mingw build working as well 18:51
maybe I'll give it one more shot before stealing someone else's time =)
CIAvash cygx: jnthn: Sorry for the delay! Should I file a bug report or something for the require issue? 18:53
18:55 andreoss left
jnthn CIAvash: Yes, please; I'm not likely to remember about them otherwise :) 18:56
jnthn bbl
ZoffixW Weird. Seems there's some type of conflict between this multi method and the one below it (line 19): github.com/zoffixznet/perl6-Color/...or.pm6#L15 When I run this test set, github.com/zoffixznet/perl6-Color/...#L215-L251 I get "Use of uninitialized value of type List in numeric context" with line number referring to the other method fpaste.scsys.co.uk/501568. And if I reverse them
in the source, the warning switches places as well
18:57 Sqirrel joined
cygx CIAvash: as jnthn said, it should be filed 18:57
the important bits of my analysis are irclog.perlgeek.de/perl6/2015-11-16#i_11545652 and gist.github.com/cygx/cfef662ea505cd68b2e8
ZoffixW Is it a bug? Where is it even getting the "numeric context" bit from 18:58
Oh, if I remove the "where $_ ~~ [Real, Real, Real]" bit, the code doesn't run at all. Cannot look up attributes in a type object 18:59
Fixed it! By swapping List to Array() 19:00
19:01 hankache joined 19:05 tokuhiro_ joined 19:11 tokuhiro_ left 19:16 bapa joined, ribasushi joined
dalek kudo/curli: 07f8d7b | (Stefan Seifert)++ | src/core/CompUnit (4 files):
Move circular module loading protection to load_module

load_module is now the one place where all module loading attempts pass through. This way we no longer need to pass around debugging information to lower levels.
19:19
ZoffixW :o "Undeclared routine: cymk2rgb used at line 16. Did you mean 'cmyk2rgb'?" 19:20
Perl 6's error messages are amazingly advanced. 19:21
geekosaur (everything old is new again. watfiv did that. iirc watfor did that but also proceeded as if you'd used the other one, occasionally producing hilarious results) 19:22
ZoffixW :) 19:23
It also disturbs me that after 5 years of having "Designer" in my job title, I only now realized it's CMYK and not CYMK... -_- 19:25
pink_mist lol 19:26
Hotkeys_ haha 19:27
what
why am I underscored
silly irc
19:27 Hotkeys_ is now known as Hotkeys
geekosaur netsplit probably 19:27
Hotkeys probably
19:28 crucialrhyme left 19:29 vendethiel joined
[Coke] apologizes for the nonspecific JVM NPE tickets, but fudging is more important than deep diving at this point. 19:37
Hotkeys hot damn
it's nice having windows repl working again
go us psch and ugexe 19:38
dalek kudo/curli: 7a1b6d1 | (Stefan Seifert)++ | src/core/CompUnit (3 files):
Remove unused code from CompUnit
19:39
kudo/curli: b6cf3c3 | (Stefan Seifert)++ | src/core/CompUnit (2 files):
Move rest of CompUnit.load code to CompUnit::Loader::load-source
19:39 muraiki left
dalek kudo/curli: fc73a7c | (Stefan Seifert)++ | src/core/CompUnit/Repository/Installation.pm:
Have CURLI load precomp files from the PrecompilationStore

Using the full DependencySpecification as the key for now.
19:43
19:44 Ven joined 19:48 Ven left
Skarsnik I am curious on how to bind the glib (as in Gnome lib) with all the gint and guint stuff. 19:48
timotimo ideally we'd have a module that reads glib introspection files and generates bindings from that 19:49
zengargoylew would sub gint { int } work? 19:51
timotimo i wouldn't do that
try "constant gint = int" instead
i'm not sure if that works so wll with native types
zengargoylew ah yes, i forget about constant all the time. 19:52
19:52 Ven joined
Skarsnik they probably match native type in most case 19:52
dalek ast: f20a1b2 | coke++ | S02-types/mixhash.t:
Fudge for the JVM so we can complete the test.
19:53
zengargoylew object have some sort of FALLBACK method right? does main scope have one for unknown identifiers?
it could just s/^g//; :)
Skarsnik I mean you have no way to know if you gint is a int32 or a int64 ~~ 19:54
zengargoylew you make a list of them and run them through cpp to see what they turn into
Skarsnik I mean I can look at the header. but at run time you are screw ~~ 19:55
19:55 rvchangue joined
zengargoylew by runtime you'll already now what they map to or am i missing something? 19:56
19:56 sno joined 19:57 timbunce_ joined 19:58 khw left, timbunce_ is now known as timbunce
Skarsnik I was looking a struct I want to use as an exemple and everything is gtype (gint, gchar, gfloat). Now I want to write the corresponding CStruct type in perl6. How do I know gint is really int32 19:58
19:58 avalenn joined
Skarsnik I mean it's maybe int32 on x86, maybe int64 on amd64 maybe something else on Windows 19:59
19:59 ][Sno][ left
zengargoylew you put the struct in a file with the proper #include <glib> or whatever and run cpp / gcc -E on it to transform the names into native 19:59
ah....
Hotkeys somewhat related question 20:00
when should one use int vs Int
FROGGS Hotkeys: in NativeCall code? never
Skarsnik I think the answers is don't use int with NC
zengargoylew then you have somebody do it on other architectures for you and write a module that maps them. and figure out a good way to guess which to use.
Hotkeys but like what about in general 20:01
eg in randomscriptxyz.p6
Skarsnik No idea
zengargoylew in general you have a C compiler and you do it at runtime with a test program.. :P
Hotkeys darn
moritz Hotkeys: use Int if you want to call methods on it, and/or use integers larger than fit into an int 20:02
zengargoylew theres not any other way i can think of that would work across all compilers, all architectures, etc...
Skarsnik int exist on nqp and not Int?
FROGGS Hotkeys: int is there to perform better in e.g. tight loops, but it might be only 32bits wide... Int has no size restriction but is slower there
Hotkeys Ah okay
so if I know I won't need anything larger than 32 bits int is the better choice? 20:03
or will it not make a huge difference in most cases
zengargoylew basically from the interact-with-native side of things, even the compiler may make a difference.
each compiler may pack a structure differently, it's just that the same compiler is used for the client C code and the library code so things work out ok. 20:04
FROGGS Skarsnik: you can write a glib module that compiles a C probe against glib.h on module installation time. then you use the glib.pm that hands back information of the probed types
zengargoylew that is a struct is a logical thing, not necessarily a physical thing. 20:05
FROGGS Skarsnik: glib.pm can for example create and export a gint type with the right size
cygx zengargoylew: but genrally C cmopilers do what the OS vendor does by default
not being able to make system calls would be a Bad Thing 20:06
20:06 hartenfels joined
zengargoylew yeah, but years on solaris with sun vs gcc has taught me different. 20:06
Skarsnik FROGGS, hm defeat the concept of installing without the dev package. but yeah, it's a solution
20:06 ribasushi left
FROGGS Skarsnik: true 20:06
20:06 Ven left
zengargoylew it's usually not a problem. but like the net-snmp SNMP module refuses to build unless the compiler is the same as the one used to build perl itself. 20:07
dalek ast: ffda0cb | coke++ | S02-types/sethash.t:
Fudge for the JVM so we can complete the test.
zengargoylew you can hack around it, but 'tis not supported that way.
konobi howdy
yoleaux 15 Nov 2015 07:33Z <[Coke]> konobi: I do some testing. I wouldn't say I handle the infrastructure. What's your question?
20:08 darutoko left
Skarsnik I need my size_t patch! my module with ether work on x86 or amd64 x) 20:08
ZoffixW I thought these special Unicode operators were there out of the box? 20:09
m: say so 8 ≤ 8.5 ≤ 9
camelia rakudo-moar 80ea92: OUTPUT«5===SORRY!5=== Error while compiling /tmp/EdBnINXq35␤Confused␤at /tmp/EdBnINXq35:1␤------> 3say so 87⏏5 ≤ 8.5 ≤ 9␤ expecting any of:␤ infix␤ infix stopper␤ postfix␤ statement end␤ statem…»
20:09 hankache left
ZoffixW Hm, might be confusing them with ≼ 20:10
cygx Skarsnik: until it gets merged, just define size_t as uint32 or uint63 depending on sizeof something with a CPointer repr
pink_mist 0_o uint63 o_0
cygx Skarsnik: cf github.com/cygx/p6-native-libc/blo...bC.pm6#L16 and following lines
pink_mist: I've also got a Uni63 module that does base-62 ;) 20:11
20:12 Ven joined, flussence left, flussence joined
Skarsnik Let's see if I can write: our native size_t is Int is ctype("CPointer") is repr("P6int") { }; 20:14
zengargoylew haven't messed with systemcalls on a low level on linux recently. i've seen times when system calls were packed into registers instead of using a stack.
FROGGS m: use NativeCall; native size_t is Int is ctype("CPointer") is repr("P6int") { };
camelia rakudo-moar 80ea92: OUTPUT«5===SORRY!5=== Error while compiling /tmp/PPMpUfd1rs␤Unhandled C type 'CPointer'␤at /tmp/PPMpUfd1rs:1␤»
20:15 domidumont joined
FROGGS m: use NativeCall; native size_t is Int is nativesize(nativesizeof(Pointer)) is repr("P6int") { }; 20:15
camelia ( no output )
cygx FROGGS: bytes vs bits 20:16
FROGGS ups
but isnt that like 'long' anyway?
cygx NOOOO
FROGGS :P
jnthn Certainly not reliably. :) 20:17
Skarsnik oh there is a is nativesize trait ? x)
nine Isn't every system Linux on x86_64 nowadays?
yoleaux 18:48Z <jnthn> nine: What would be more natural, in your view?
cygx the C standard actually recommended that size_t shoudl fit into long, but when MS went 64-bit, they decided to go the route of compatibility between types on different architectures
nine ducks
jnthn: Well we do have this shiny IO::Path class in Perl 6 :)
zengargoylew my work desktop was 32 bit until a couple of months ago 20:18
Skarsnik I think I forget to activate 64 bit virtualisation stuff and I can't create 64 bits virtualbox guss
20:18 xfix left
zengargoylew at least the linux one, sun box was sparc or 64bit 20:18
Skarsnik so yeah, my main perl6 installion is 36 bits x) 20:19
*32
zengargoylew isn't 32 bit perl like faster if you don't need the bits?
[Coke] r: SetHash.new(<a b foo>).keys.sort.say;
camelia rakudo-{moar,jvm} 80ea92: OUTPUT«(a b foo)␤»
psch hack's at 80+ load right now
FROGGS uhh
psch not sure if that's runaway again
but tab completion in bash hangs :P
RabidGravy Skarsnik, you had me excited there, I thought you had compiled P6 on some thirty year old mainframe ;-) 20:20
20:20 kaare_ left, xfix joined
cygx RabidGravy: Unisys is still in business 20:20
20:20 rorx joined
Skarsnik RabidGravy, perl6 on my 1.2Ghz dedicated server is not nice compile time/run time x) 20:20
20:21 Peter_R joined
Skarsnik took a minute to compile some code 20:21
jnthn nine: Hm, and I guess the bootstrap isn't pulled in through the repo, so we won't have issues around that.
[Coke] psch: I can't even open a new screen shell.
jnthn nine: I wonder how much overhead IO::Path has...
RabidGravy :)
20:22 Ven left
psch [Coke]: i guess that means it's the same runaway process again 20:22
hartenfels ping timotimo
20:22 Ven joined, ZoffixW left
Skarsnik ok, that did not work to define size_t like this: For has size_t index_within_parent : c-size=8 / nc-size=1 DONT MATCH 20:22
ugexe time to start digesting nine++ curli work
FROGGS psch: shall I reboot it? 20:23
Skarsnik funny why it fall on 1 for size
nine jnthn: IO::Path is essentially a glorified Str wrapper. I'm currently using it anyway in load-source-file and other places.
psch FROGGS: i guess so... it's at 113+ load now :S
jnthn nine: OK, then we can go with it :)
nine jnthn: ever since I separated BOOTSTRAP loading from the rest of the module loading code, bootstrapping issues just went away ;)
jnthn ;)
20:26 ZoffixW joined
hoelzro well, I went home for lunch and tried to get my Windows dev environment working; no dice =/ 20:26
my Windows fu is so weak!
20:27 [Coke] left
ZoffixW Is there a more concise way of writing this, without repeating Real:D all the time? 20:28
m: sub x (Real:D $x, Real:D $y, Real:D $z) { say [$x, $y, $z] }; x 1, 2, 3;
camelia rakudo-moar 80ea92: OUTPUT«[1 2 3]␤»
20:28 ollej left
ZoffixW Something like sub x (Real:D ($x, $y, $z) ) { ... } 20:28
hoelzro I got a working Moar built, but configuring NQP got really mad, complaining that C:Strawberryperlbinperl.exe couldn'
nine no dalek :(
hoelzro couldn't be found, which is...odd.
20:28 domidumont left, sergot left
nine commit b03e334e6 Stefan Seifert Remove CompUnit.load and use CompUnitLoader directly 20:29
This gets rid of most of the remainder of the previous CompUnit implementation. CompUnit::PrecompilationRepository now only deals with files and handles and doesn't need to know about CompUnit anymore. CompUnit's $.handle attribute is now required.
Review: github.com/rakudo/rakudo/commit/b03e334e6
jnthn nine++ 20:30
zengargoylew m: sub x(Real @ ( $x, $y, $z)){ say [$x, $y, $z] }; x 1,2,3;
camelia rakudo-moar 80ea92: OUTPUT«5===SORRY!5=== Error while compiling /tmp/H1uVbREdKn␤Calling x(Int, Int, Int) will never work with declared signature (Real @ (Any $x, Any $y, Any $z))␤at /tmp/H1uVbREdKn:1␤------> 3l @ ( $x, $y, $z)){ say [$x, $y, $z] }; 7⏏5x 1,2,3;␤»
jnthn nine: You can't imagine how happy I am that you took this task on. :) 20:31
nine jnthn: just adds to the fun :)
Skarsnik Well my binding still does not work properly because of a bug of NC that does not construct the proper struct size :(
ilmari hoelzro: something forgot to escape the backslashes when saving the path? 20:32
FROGGS I dunno what hack is doing right now :S
hoelzro that would make sense, but I don't know where to start looking
I'm a big command line user, so I feel so powerless on Windows 20:33
FROGGS moritz: are you there?
hoelzro I'm using cmd.exe with MingW and the Git for Windows location added to my PATH
20:34 sno left, zengargoylew left
mspo hoelzro: open powershell and be even more frustrated when they made aliases to unix commands but they work differently 20:35
20:35 zengargoylew joined
mspo but at least you can type ls 20:35
20:37 dalek joined, ChanServ sets mode: +v dalek
FROGGS ohh, that's better 20:37
20:38 CIAvash left, geraud joined 20:39 psch joined
psch ...ISTR there was a different host for irc screens, maybe i should move there :S 20:39
ZoffixW How do I take out the default constructor?
I have a bunch of multi method new {} but if none of them match some sort of "default constructor" is being called and it interferes with my error checking 20:40
20:40 [Coke] joined
ZoffixW I just want the code to crash and burn and not run the default constructor. 20:40
jdv79 override it?
ZoffixW I don't know how.
What's it signature? 20:41
jdv79 match the sig i imagine
psch m: Any.can('new')[0].signature.perl.say
camelia rakudo-moar 80ea92: OUTPUT«:(Mu $: | is raw)␤»
ZoffixW Ooo
psch well, that's the proto
[Coke] looks like hack was rebooted. anyone figure out what the problem process was?
r: SetHash.new(<a>).keys.sort 20:42
cygx hoelzro: I'm assuming you're using the gmake that came with strawberry perl, or something else?
camelia ( no output )
psch m: Any.can('new')[0].candidates>>.signature.perl.say
camelia rakudo-moar 80ea92: OUTPUT«(:(Mu $: *%), :(Mu $: $, *@, *%_))␤»
[Coke] r: SetHash.new(<a>).keys.sort; say "live"
hoelzro cygx: I think it's the one from Mingw
camelia rakudo-{moar,jvm} 80ea92: OUTPUT«live␤»
hoelzro not sure
[Coke] locally on JVM at that revision, I get an NPE
psch ZoffixW: the general wides candidate would be :(*@, *%)
RabidGravy ZoffixW, do a "multi method new(*%h) { die .... }" ?
psch +t
jnthn ZoffixW: Just write a proto method new(|) { * } in your class
ZoffixW: And it'll hide all inherited multis
RabidGravy even better 20:43
timotimo hartenfels: pong
jdv79 be nice if that stuff wss doc'd;) 20:44
ZoffixW weee "All tests successful. Files=1, Tests=7,"
jnthn++
jdv79 *was
ZoffixW No idea what that code does, but it did the trick :)
[Coke] Can someone with a local copy of rakudo-jvm double check that?
cygx hoelzro: Git for Windows might be to blame
20:44 ribasushi joined, kjs_ left
cygx note that you probably need to use gmake not make 20:44
hoelzro I'm using gmake
cygx there goes my guess who ate the slashes ;) 20:45
hoelzro I tried removing Git for Windows from my PATH; building NQP worked, but then nqp --version doesn't have a version in its output
so rakudo gets mad
cygx perhaps reordering your path would help?
20:45 kjs_ joined
cygx or just creating a batch wrapper for git 20:46
zengargoylew was there an answer to the sub x(Real:D $x, Real:D $y, Real:D $z) thing... my net went wonky for a few minutes.
ZoffixW zengargoylew, I've not seen one.
20:47 kjs_ left
zengargoylew there should be some signature unpacking magick... i just can't come up with it. 20:47
[Coke] be nice if searching for Variables on docs.perl6.org got us all the predefined variables.
bartolin [Coke]: jepp, I also get a NPE (on commit 80ea923)
[Coke] bartolin: thank you. Just did a lot of fudging based on that NPE, didn't want to have to undo it. :)
psch that's a bit troublesome :/ 20:48
20:48 brrt joined
psch 'cause in general i expect camelia to have troubles a standalone doesn't have 20:48
not the other way around...
b2gills m: say ([+] 0..10).^name 20:50
camelia rakudo-moar 80ea92: OUTPUT«Rat␤»
b2gills m: say [+] 0.0..10.0
camelia rakudo-moar 80ea92: OUTPUT«Cannot determine integer bounds␤ in block <unit> at /tmp/jOYtxZCZyE:1␤␤Actually thrown at:␤ in block <unit> at /tmp/jOYtxZCZyE:1␤␤»
hoelzro cygx: I can try playing with my PATH 20:51
[Coke] r: say $*PERL.compiler ; # see if they're lying.
hoelzro Git was at the end of it
camelia rakudo-moar 80ea92: OUTPUT«rakudo (2015.10.324.g.80.ea.923)␤»
( no output )
[Coke] so, perhaps we have an old jvm build masquerading as a successful new one? 20:52
20:52 Ven left
psch j: say $*PERL.compiler 20:52
camelia rakudo-jvm 80ea92: OUTPUT«rakudo (2015.10.134.g.273.e.895)␤»
20:52 Ven joined
psch oh, just below 200 commits behind... vOv 20:52
20:52 znpy joined
[Coke] j: Sethash.new(<a>).keys.sort.say 20:53
camelia rakudo-jvm 80ea92: OUTPUT«5===SORRY!5=== Error while compiling /tmp/vu4zKb2p7L␤Undeclared name:␤ Sethash used at line 1. Did you mean 'SetHash', 'Stash'?␤␤»
[Coke] j: SetHash.new(<a>).keys.sort.say
camelia rakudo-jvm 80ea92: OUTPUT«(a)␤»
[Coke] psch: so, yes. and j: and r: give different answers for the java code. neat. 20:54
psch r: SetHash.new(<a>).keys.sort.say 20:55
camelia rakudo-{moar,jvm} 80ea92: OUTPUT«(a)␤»
dalek kudo/curli: fd1e9f9 | (Stefan Seifert)++ | src/core/CompUnit (8 files):
Use IO::Path for all paths in CompUnit handling
psch [Coke]: isn't just the revision before the colon a lie?
[Coke]: for r-j that is
[Coke] and before j, too.
but the output of that code on j: and r-j is also different. (when asking for the compiler version)
psch oh 20:56
r: say $*PERL.compiler
camelia rakudo-moar 80ea92: OUTPUT«rakudo (2015.10.324.g.80.ea.923)␤»
..rakudo-jvm 80ea92: OUTPUT«rakudo (2015.10.134.g.273.e.895)␤»
[Coke] er, where by r-j I am meaning the response to "r:" for r-j.
psch looks the same from here...
[Coke] and now it's not consistent between runs.
psch ...i'm not seeing it? < 20:52 [...] (2015.10.134.g.273.e.895)␤» > and < 20:56 [...] (2015.10.134.g.273.e.895)␤» > look pretty the same to me 20:58
20:59 brrt left
bartolin j: my $match = 1, 2 # rakudo.jvm seems to be horribly broken 21:02
camelia rakudo-jvm 80ea92: OUTPUT«WARNINGS:␤Useless use of constant integer 2 in sink context (line 1)␤java.lang.NullPointerException␤ in block <unit> at /tmp/Oe6o6LKFVJ:1␤␤»
psch j: 1; 21:03
camelia rakudo-jvm 80ea92: OUTPUT«WARNINGS:␤Useless use of constant integer 1 in sink context (line 1)␤»
ZoffixW m: my $match = 1, 2
camelia rakudo-moar 80ea92: OUTPUT«WARNINGS:␤Useless use of constant integer 2 in sink context (line 1)␤»
bartolin j: 1, 2
camelia rakudo-jvm 80ea92: OUTPUT«WARNINGS:␤Useless use of constant integer 2 in sink context (line 1)␤Useless use of constant integer 1 in sink context (line 1)␤java.lang.NullPointerException␤ in block <unit> at /tmp/a8ciixqre2:1␤␤»
jnthn [Coke]: Your changes to S02-types/baghash.t have busted it, I think
[Coke]: The path does rather more than fudge for JVM 21:04
21:04 rindolf left 21:06 kjs_ joined 21:07 Ven_ joined, Ven left, tokuhiro_ joined
ZoffixW Perl 6 is so awesome :) I just wrote this in my code: my $Δ = $c_max - $c_min; 21:08
psch m: my \Δ = 5 - 2; say Δ 21:09
camelia rakudo-moar 80ea92: OUTPUT«3␤»
ZoffixW :o
What does \ do?
psch m: my \Δ = 5 - 2; say Δ; Δ = 7; say Δ
camelia rakudo-moar 80ea92: OUTPUT«3␤Cannot modify an immutable Int␤ in block <unit> at /tmp/igZuSLwDSy:1␤␤»
psch ^^^ that
ZoffixW Aha! psch++
psch you could still declare it an rw sub i guess... 21:10
but then you need parens
m: sub Δ () is rw {$}; Δ() = 5 - 2; say Δ(); Δ() = 10 - 4; say Δ() # vOv 21:11
camelia rakudo-moar 80ea92: OUTPUT«3␤6␤»
ilmari m: say e^(iπ)+1
camelia rakudo-moar 80ea92: OUTPUT«5===SORRY!5=== Error while compiling /tmp/CkQWUN9EPW␤Undeclared routine:␤ iπ used at line 1␤␤»
ilmari m: say e^(i*π)+1
camelia rakudo-moar 80ea92: OUTPUT«one(2.71828182845905, 1+3.14159265358979i)␤»
psch m: say e**(π\i)+1 # almost
camelia rakudo-moar 80ea92: OUTPUT«0+1.22464679914735e-16i␤»
psch ("almost" regarding the result, that is :) ) 21:12
21:12 tokuhiro_ left 21:13 kjs_ left
ilmari m: say e**(π i)+1 # ? 21:13
camelia rakudo-moar 80ea92: OUTPUT«5===SORRY!5=== Error while compiling /tmp/aoUkmXpkGN␤Two terms in a row␤at /tmp/aoUkmXpkGN:1␤------> 3say e**(π7⏏5 i)+1 # ?␤ expecting any of:␤ infix␤ infix stopper␤ statement end␤ statement modifie…»
ilmari oh, no space allowed for postfix ops?
psch yeah. the "expecting any of" includes postfix 21:14
oh, not there actually
ilmari m: say e**(π\ i)+1 # ?
camelia rakudo-moar 80ea92: OUTPUT«5===SORRY!5=== Error while compiling /tmp/m6JIVUJpTh␤Variable '&π' is not declared␤at /tmp/m6JIVUJpTh:1␤------> 3say e**(7⏏5π\ i)+1 # ?␤»
psch which is probably because you need to unspace... 21:15
huh
that should work i think
'cause the space after the unspace shouldn't be significant in any way...
pink_mist it's saying it can't find the pi sub? 21:16
ilmari it's a constant, not a sub
21:16 kjs_ joined
pink_mist not according to rakudo :P 21:16
ilmari src/core/Num.pm:240:my constant π := pi; 21:17
src/core/Num.pm:237:my constant pi = 3.14159_26535_89793_238e0;
[Coke] jnthn: crap, that bit was experimental and not meant to be committed. fixing.
jnthn [Coke]: np; thanks
It's one less test that my local changes have broken :P
21:18 kjs_ left
timotimo psch: i think you want \i instead of \ i 21:18
m: say π\i
camelia rakudo-moar 80ea92: OUTPUT«0+3.14159265358979i␤»
dalek ast: bed8c8a | coke++ | S02-types/baghash.t:
Revert unintended update to showkv

  jnthn++ for noticing the breakage
21:19
[Coke] I was testing out replacing showkv with a test function, but realized 90% of the way through that we had one test that needed to call it 2x.
and I never noticed it broke because I skipped all those tests on the jvm. :| 21:20
rebuilding r-m to double check... 21:21
21:22 Ven_ left
psch m: my $x = 5; $x\ ++; say $x 21:24
[Coke] yup, all better.
camelia rakudo-moar 80ea92: OUTPUT«6␤»
psch timotimo: if ^^^ works, why doesn't pi\ i?
21:25 Ven joined, molaf left 21:29 PerlJam joined 21:30 synbot6 joined 21:31 doublec left 21:32 cygx left, doublec joined, sergot joined
timotimo because i isn't a postfix operator 21:33
psch m: sub f () is rw { $ }; say f()\ i
camelia rakudo-moar 80ea92: OUTPUT«Cannot call postfix:<i>(Any); none of these signatures match:␤ (Real \a --> Complex:D)␤ (Complex:D \a --> Complex:D)␤ (Numeric \a --> Complex:D)␤ (Cool \a --> Complex:D)␤ in block <unit> at /tmp/F9wbLEnkBM:1␤␤»
psch m: sub f () is rw { $++ }; say f()\ i
camelia rakudo-moar 80ea92: OUTPUT«0+0i␤»
psch m: sub f () is rw { $++ }; say f\ i
camelia rakudo-moar 80ea92: OUTPUT«0+0i␤»
timotimo er, huh?
that's interesting
psch timotimo: it's constants parsing i guess
timotimo quite possibly
psch missing an <unsp> somewhere or somesuch...
timotimo could very well be 21:34
21:34 TEttinger left
timotimo OK, anyway, since my involuntary breakfast-ejection an hour ago helped with my brain-splitting headache, i think i can now finally get started on the p6weekly post 21:35
psch ...that doesn't sound particularly good? o.o
timotimo i felt pretty bad all day long 21:36
then i had to get to the hardware store to get replacement lightbulbs and then get dinner for me and a friend i was going to spend the evening at
bartolin btw, I just found that removing 'is pure' from the definition of 'proto sub infix:<,>' made the NPE with '1,2' go away
ZoffixW Hehe. A neat comparison of math formulas next to their Perl 6 equivalent :) twitter.com/zoffix/status/666369101766397952
ZoffixW is enjoying themselves too much coding Perl 6 :)
timotimo after getting out of the underground parking thing of the grocery store (i blame the up and down) i had to stop by the side of the road and find a place to ... do that thing 21:37
bartolin: oh, huh, so perhaps the problem is inside our optimizer when it tries to compile-time-evaluate things? it should help to --optimize=0 as well if that's the case
psch: all in all, not such a nice experience, i have to say! 21:38
bartolin timotimo: no, still a NPE with optimize=0 ...
--optimize=0 21:39
timotimo hm, what about --optimize=off, which kicks out the optimizer completely
bartolin yes, that helps
timotimo++
b2gills .tell TimToady There are two problems with Range.sum, It outputs a Rat for Int based ranges, and doesn't work for any other type of range ( see my comments on github.com/rakudo/rakudo/commit/6d...94b8b9b328 )
yoleaux b2gills: I'll pass your message to TimToady.
psch timotimo: oh, i can believe that... maybe get something easier to digest, depending on how involved your breakfast was
timotimo right; at --optimize=0, the optimizer runs, but doesn't change much (or anything? i don't know.) 21:40
psch: i had a sandwich and some haribo; i think the haribo was wrong or too much
after i lied down i had ice cream, which surprisingly didn't cause any trouble 21:41
21:41 sprocket left
jdv79 what is haribo? 21:41
the gummy bear company?
timotimo yup
psch timotimo: a friend of mine has a glucose allergy. maybe that's something for you to check for 21:42
timotimo Hans Riegel Bonn
glucose allergy? oh lord, that would be terrible
psch timotimo: yeah, i mixed it up. it's a fructose allergy actually 21:43
hartenfels timotimo: I made markdeep work in a roundabout way, if you remember github.com/hartenfels/Javascript-S...p/examples
timotimo hartenfels: that is cool!
it'll go in the p6weekly today for sure! thanks! 21:44
psch well, wikipedia says it's "fructose malabsorbtion", with symptoms such as vomiting
hartenfels Still needs a lotta work though :P
timotimo psch: i think the previous time i've vomited was the previous year, but i've had lots of sugary stuff in the mean time
psch timotimo: it's just something that came to mind, i'm not a doctor :) 21:45
timotimo mhm
thanks
21:45 espadrine_ left
timotimo i have a cat that demands cuddles 21:46
RabidGravy how annoying, I appear to have just one test out of 200 failing on URI::Template 21:48
ZoffixW m: gist.github.com/zoffixznet/72e6d8221832a282ad8c 21:49
camelia rakudo-moar 80ea92: OUTPUT«{:h(<10050/53>), :l(<106/255>), :s(1.0)}␤»
ZoffixW My mind is blown by the result! It's not decimals but fractions!
timotimo that test deserves a commendation!
of course it is :)
dalek kudo/nom: d9f6ca3 | jnthn++ | src/ (11 files):
Let Stash store a longname; MOP code to set it.

Nothing currently passes the longname, so it defaults to the "short name", though .WHAT and .^name currently don't map to that, but the literal name in the program whether it's multi-jointed or not. That will be addressed in the next patches.
21:50
kudo/nom: 77e178f | jnthn++ | src/Perl6/Metamodel/BOOTSTRAP.nqp:
Fix some missing Stash additions.
21:51 xfix left, ZoffixW left
jnthn That's initial work towards RT #118361. Got more of it locally...it's uncovering a few things (like those missing Stashes) 21:52
synbot6 Link: rt.perl.org/rt3/Public/Bug/Display...?id=118361
jnthn Enough for today, though. Will finish it up tomorrow
dalek kudo/nom: 921b2fb | cygx++ | src/Perl6/World.nqp:
detect win32 absolute paths in World.current_file
kudo/nom: 3177463 | jnthn++ | src/Perl6/World.nqp:
Merge pull request #588 from cygx/fix-file-win

detect win32 absolute paths in World.current_file
timotimo take care, jnthn!
jnthn Thanks! 'night, all o/
21:53 Ven left, Ven joined
hartenfels Is there any documentation on how to call into Perl 6 from native code? I know Inlines do it, but reading the code it just looked scary. 21:57
timotimo all you can do is have callbacks, but i expect that's what you mean 21:59
the examples in jnthn/zavolaj have that, i bet. otherwise, GTK::Simple does, too
hartenfels Yeah, that'd be enough.
Thanks, I'll check it out.
timotimo :)
psch "into Perl 6 from native code" sounds a few kinds of scary 22:00
i mean, taken literally
22:00 Ven left
psch but i guess one usecase would be using Perl 6 as extension language 22:00
(baring things like Inline::Perl6, which translates from one HLL to another, with the former HLLs semantics) 22:01
hartenfels Well, in this case it'd be gluing together JavaScript and Perl 6.
psch hartenfels: i'd suggest helping pmurias with the nqp-js backend, if you've got tuits 22:02
hartenfels That's not quite enough :P
22:02 [Sno] joined
psch now i'm curious about the usecase :o 22:02
"existing node app that wants to parse things easily" is something that comes to mind... 22:03
22:03 skids left
hartenfels It's simply to be able to use JavaScript library, without going all the way and use node as a backend. 22:04
psch oh 22:05
PerlJam hartenfels: you could always write Inline::JS ;)
hartenfels Which is what I'm kinda sorta doing :P 22:06
It's not very Inline yet though.
psch wonders what the namespace for v5-ish things is gonna be
'cause Inline:: seems to develop as "we're secretly calling the other language's interpreter"
whereas v5 was "we're doing this all ourself, damn the consequences!" 22:07
(well, "is", probably, even if stalled...)
22:07 cygx joined
cygx psch: Slang:: 22:08
psch cygx: Slang::Tuxic or Slang::Piersing don't seem to fit the same scope as a hypothetical Slang::JS
cygx but there's also Slang::SQL
psch cygx: i get it from a semantic perspective, but it seems practically different
hartenfels I wouldn't tie Inline::JavaScript to a particular implementation though.
psch oh, right, Slang::SQL is an argument toward that 22:09
although Slang::SQL still allows SQL as a statement-level sublanguage and doesn't replace the whole language...
hartenfels: hm, true. with :provides and such we should be able to layer those, i think. i'm bad at S22, though, so maybe that's wrong 22:10
Hotkeys Why is the majority language on perl6/nqp listed as parrot
I thought parrot was a (now unused) vm 22:11
hartenfels psch: Dunno, I didn't worry about Inlinyness yet.
psch Hotkeys: if you click "Parrot" in that listing it doesn't find any code
Hotkeys I know
psch Hotkeys: so i'd say github doesn't know what it's saying... vOv
hartenfels It's just called JavaScripdt::SpiderMonkey right now, and ideally an Inline::JavaScript would call into a common API for various JavaScript bindings.
Hotkeys lol
hartenfels Surely someone will write JavaScripdt::PP or something one day. 22:12
22:12 pmurias_1 is now known as pmurias
pmurias having a common API would be great 22:12
hartenfels github.com/hartenfels/Javascript-S...e/markdeep
psch yeah, i kinda still want a common API for "this other installed backend knows how to do that, hold on..." 22:13
but that's apparently insane :)
pmurias I thought about doing that in Perl 5, but I stopped developing JavaScripdt::V8 and passed it over to people who actually use it
psch: you mean in Perl 6 land? 22:14
hartenfels I woulda done V8 if I could manage to compile the darn thing
RabidGravy okay last test whacked, which is weird as I fully expected it break a bunch more
pmurias psch: so you can switch over from rakudo-jvm to rakudo-moar in the same program?
psch pmurias: yeah. e.g. r-m noticing a " use ...:from<Java>; " call and DTRT
pmurias this happening transparently seems like a bad idea 22:15
psch well, yes. a full BE switch would be bad
pmurias combining backends on a per block basis seems possible 22:16
RabidGravy now I need dnmfarrell to merge the PR to URI::Encode and we're good to go
psch pmurias: with dynvars and lexical scoping in general that already seems nightmarish enough 22:17
as in, i don't disagree with the people say it's insane, but it'd still be pretty cool :P
+who
pmurias I don't think it would be that crazy to implement, but it seems a bit crazy to use
psch i don't know 22:19
i mean, i do know that i'm not the person to try and implement that, 'cause i really don't know enough about the codebase nor compiler design and all those other theoretical things 22:20
22:22 vendethiel left 22:23 spider-mario left
Hotkeys is there a relatively simple way to load some code into a running program from a file for a plugin system (and probably also unload/reload) 22:36
Skarsnik you can use require to reload a file, but... it's quite ugly ^^ 22:37
timotimo require with a string lets you load a file
ugly, huh?
Skarsnik well you need to do other stuff, like cleaning the namespace this code used 22:38
timotimo that's true 22:39
22:39 johan joined
timotimo things require'd get put into the GLOBALish namespace, right? 22:39
pmurias psch: any use for mixing backends besides jvm interop? 22:40
Skarsnik the fun of it? 22:41
22:41 perlawhirl joined
Skarsnik maybe a backend is faster for a type of operation and you want to use it in this case, rahter than the main one 22:42
does the JVM backend has a good Inline::Java? x) 22:43
22:47 pmurias_ joined, pmurias_1 joined 22:48 cygx left 22:50 pmurias__ left, pmurias left 22:51 anon joined, anon is now known as Guest86646
dalek Heuristic branch merge: pushed 18 commits to modules.perl6.org/mojo-app by zoffixznet 22:52
22:52 eternaleye left, nebuchad` joined 22:53 zengargoyle joined 22:54 pmurias joined, pmurias__ joined, Grrrr left 22:55 lucs joined, Woodi joined 22:56 Grrrr joined, inokenty joined 22:57 pmurias_ left, esh joined, dj_goku_ joined
psch pmurias__: i'd assume r-m to r-js would be another, but no, except for interop i don't see any use 22:57
22:57 pdcawley__ joined 22:58 pmurias_1 left
psch Skarsnik: r-j doesn't have Inline::Java, it let's you use Java classes in the mainline (as soon as someone fixes the GLR fallout...) 22:58
22:58 Humbedooh joined, Sgeo_ joined 22:59 bapa1 joined, samigarus joined, Humbedooh left, Humbedooh joined
psch along the lines of "use java::lang::String:from<Java>; use java::lang::System:from<Java>; my String $java-string = String.new('foo'); System.get_out.println($java-string)" or similar 22:59
22:59 Timbus joined
psch (note that you don't need to have a Java String to print it, though...) 22:59
23:00 Bucciarati joined, M-eternaleye joined 23:01 mls joined
Zoffix Seems the modules.perl6.org/mojo-app branch is good to go :) The build script builds db and restarts the app successfully. 23:01
23:01 vike joined, erxeto_ joined
pmurias__ psch: for interop just having :from<Java> work on the moar backend seems like a saner first step 23:01
Zoffix Gonna run a setup on a virgin Debian install to see if I missed any prereqs and then the PR and demo shall be forthcoming.
23:01 f3ew joined, stmuk_ joined
psch pmurias__: probably, yes. although that's probably hard enough already, 'cause you need a JVM that knows about the TC 23:02
23:02 Mhoram joined
psch well, and the GC and GCX too 23:03
23:05 MilkmanD1n joined 23:06 abaugher left, pdcawley left, Axord left, Sgeo left, bapa left, samigarus is now known as oahong, oahong left, oahong joined 23:07 woodruffw joined, kjs_ joined 23:08 hpd joined 23:09 ShimmerFairy joined 23:13 DrPete_ joined, Axord joined
dalek href="https://modules.perl6.org/mojo-app:">modules.perl6.org/mojo-app: 4b4f948 | (Zoffix Znet)++ | / (2 files):
NOOP HTML generation and write JSON file to app's path
23:15
23:16 larion joined
dalek href="https://modules.perl6.org/mojo-app:">modules.perl6.org/mojo-app: a6d142c | (Zoffix Znet)++ | db-builder/lib/P6Project.pm:
Use attributes instead of digging into innards
23:17
Zoffix Does anything use modules.perl6.org/proto.json or is it just there? 23:18
(just to know how flexible we are with respect to breaking its format)
timotimo good question 23:21
23:26 apejens joined 23:27 pmurias__ left, pmurias left
arnsholt timotimo: Did you get a chance to look at the ipython kernel code? 23:27
timotimo not yet :< 23:28
is there anything in particular you'd like me to have a look at?
arnsholt Not terribly, although if you could see if it runs on your machine too (to the extent what I've implemented so far can be said to work, anyways) that'd be nice 23:29
23:31 crucialrhyme joined
timotimo haha 23:34
what should i be expecting?
you renamed the thing to IPerl6; maybe we want to have Jupyter::Rakudo instead? 23:35
dalek rl6-roast-data: 82c2101 | coke++ | / (9 files):
today (automated commit)
timotimo um, aren't messages on the heartbeat channel rare enough to be able to cause us problems for blockingly reading from it? 23:37
aaah, you're using JSON::Fast <3 23:38
23:38 kjs_ left
timotimo well, you'd be seeing it in the log output 23:40
building a new rakudo right now 23:41
Zoffix ehehe Pod::Coverage has no pod :P irony
Oh maybe it does 23:42
23:42 crucialrhyme left
Juerd I have extended pack() to handle length prefixes. It does what I need, but I don't want to put more time into it, so I won't write tests or documentation. Does anyone feel like taking this code and moving it forward? 23:42
It does nested length prefixes 23:43
pastebin.com/mAwrHbR4
timotimo ==> Testing Inline::Python 23:44
Too many positionals passed; expected 1 argument but got 3
in block <unit> at t/call.t:120
nine: ^ got a clue what could be wrong there?
arnsholt: i can't install Net::ZMQ, i get "" for all receivements :( 23:45
Skarsnik Good night there 23:49
23:49 Skarsnik left, RabidGravy left 23:50 zengargoylew left
arnsholt timotimo: I figured blocking on the heartbeat was best, since those are kind of important 23:57
zengargoyle timotimo: does it look like an array that got flattened due GLR?
arnsholt But it polls with a timeout of half a second, so that we check the other sockets pretty frequently
Not sure what gives with Net::ZMQ though. Do all the tests fail, or just one? 23:58
There's one that fails for me too, not sure why