»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:, niecza:, std:, or /msg camelia perl6: ... | irclog: irc.perl6.org | UTF-8 is our friend!
Set by sorear on 25 June 2013.
00:03 awoodland left 00:13 psch left
[Coke] colomon++ 00:13
00:14 cognominal left 00:21 virtualsue left 00:23 raiph left, ab5tract left 00:25 Business joined 00:26 raiph joined 00:36 dayangkun joined 00:48 Business left 01:02 atroxaper joined 01:05 Rounin left 01:06 ninjazach left 01:08 atroxaper left
raydiak the typo of the day is: perlformance 01:12
01:19 ninjazach joined 01:20 lue left 01:23 lue joined 01:27 dayangkun left 01:28 awoodland joined 01:34 yeahnoob_ joined
dalek rl6-roast-data: f8af72b | coke++ | / (5 files):
today (automated commit)
01:40
01:41 hagiri joined 01:44 awoodland left 01:46 awoodland joined
vendethiel moritz++ # sleeping 01:49
01:54 yeahnoob_ left 02:00 lsm-desktop joined 02:19 ssqq joined 02:20 rmgk_ joined, rmgk is now known as Guest73546, rmgk_ is now known as rmgk 02:21 Guest73546 left 02:22 hagiri left
ssqq m: my token somechar { < a b > }; if 'ccc' ~~ / ^ <!someclass>+ $/ { say 'ccc match <someclass> } 02:23
camelia rakudo-moar d45c53: OUTPUT«===SORRY!=== Error while compiling /tmp/4TphMBWfkx␤Unable to parse expression in single quotes; couldn't find final "'" ␤at /tmp/4TphMBWfkx:1␤------> lass>+ $/ { say 'ccc match <someclass> }⏏<EOL>␤ expectin…»
ssqq m: my token somechar { < a b > }; if 'ccc' ~~ / ^ <!someclass>+ $/ { say 'ccc match <someclass>' }
camelia rakudo-moar d45c53: OUTPUT«No such method 'someclass' for invocant of type 'Cursor'␤ in method ACCEPTS at src/gen/m-CORE.setting:14323␤ in block <unit> at /tmp/OFWZsvXKbz:1␤␤»
ssqq m: my token someclass { < a b > }; if 'ccc' ~~ / ^ <!someclass>+ $/ { say 'ccc match <someclass>' }
camelia rakudo-moar d45c53: OUTPUT«(timeout)» 02:24
ssqq this code would make perl6 interpreter into a deep loop.
m: my token someclass { <[ab]> }; if 'ccc' ~~ / ^ <!someclass>+ $/ { say 'ccc match <someclass>' } 02:26
camelia rakudo-moar d45c53: OUTPUT«(timeout)»
ssqq m: if 'ccc' ~~ / ^ <- [ab]>+ $/ { say 'ccc match <someclass>' } 02:29
camelia rakudo-moar d45c53: OUTPUT«ccc match <someclass>␤»
ssqq *token-name" like regex name could not use in negative class. 02:37
m: my token token-name { <[ab]> }; 'ccc' ~~ /^ <- token-name>+ $/;
camelia rakudo-moar d45c53: OUTPUT«No such method 'name' for invocant of type 'Cursor'␤ in method ACCEPTS at src/gen/m-CORE.setting:14323␤ in block <unit> at /tmp/MfzE5iOn1y:1␤␤»
ssqq nqp-m: token token-name { <[ab]> }; ok( 'ccc' ~~ /^ <- token-name>+ $/); 02:45
camelia nqp-moarvm: OUTPUT«Cannot find method 'name'␤ at <unknown>:1 (<ephemeral file>::53)␤ from gen/moar/stage2/QRegex.nqp:1872 (/home/camelia/rakudo-inst-2/languages/nqp/lib/QRegex.moarvm:parse:29)␤ from gen/moar/stage2/QRegex.nqp:1956 (/home/camelia/rakudo-inst-2/languages/nq…»
02:55 atroxaper joined 03:01 atroxaper left 03:05 ninjazach left 03:11 adu left 03:12 erkan left, ssqq left 03:13 Mso150_i joined 03:14 erkan joined, erkan left, erkan joined 03:15 vendethiel joined 03:18 Mso150_i_g joined, Mso150_i left 03:40 vendethiel left 03:46 vendethiel joined 03:50 Mso150_i_g left 03:54 noganex_ joined 03:57 noganex left 04:04 molaf left 04:22 Naddiseo joined
Naddiseo Is there a way to use the hyper operators to call multiple methods on a single object? 04:23
something like: my @methods = <foo bar baz>; my @results = $obj>>.@methods; 04:24
04:28 adu joined 04:30 koo6 left
flussence m: my $array = <foo bar zzz>; say $array."$_" for <count pop [1]>; 04:36
camelia rakudo-moar d45c53: OUTPUT«===SORRY!=== Error while compiling /tmp/nZbJfo4xii␤Quoted method name requires parenthesized arguments. If you meant to concatenate two strings, use '~'.␤at /tmp/nZbJfo4xii:1␤------> $array = <foo bar zzz>; say $array."$_"[33…»
flussence m: my $array = <foo bar zzz>; say $array."$_"() for <count pop [1]>; 04:37
camelia rakudo-moar d45c53: OUTPUT«No such method 'count' for invocant of type 'Parcel'␤ in block <unit> at /tmp/rhhJWdbAcz:1␤␤»
flussence m: my $array = <foo bar zzz>; say $array."$_"() for <elems pop [1]>;
camelia rakudo-moar d45c53: OUTPUT«3␤No such method 'pop' for invocant of type 'Parcel'␤ in block <unit> at /tmp/uA01yIwIV1:1␤␤»
flussence hm, the first one works at least...
m: my @array = <foo bar zzz>; say @array."$_"() for <elems pop [1]>;
camelia rakudo-moar d45c53: OUTPUT«3␤zzz␤No such method '[1]' for invocant of type 'Array'␤ in block <unit> at /tmp/LXHCwJmfcW:1␤␤»
04:39 raiph left
flussence tried to be too fancy at the end, but that works. If you want parallel method invocation like that it's not going to have a shorthand though. 04:40
Naddiseo Nah, I just wanted a shorthand way. 04:41
rather than writing my @a = ($foo.bar, $foo,baz, $foo.foo ....)
04:43 avuserow joined
flussence if it's an object pretending to be a struct, and you don't mind poking at internals, there's also this: 04:50
m: my class Foo { has $x = 1; has $z; has $y = 2; }; say Foo.^attributes».get_value(Foo.new)
camelia rakudo-moar d45c53: OUTPUT«1 (Any) 2␤»
04:51 raiph joined
Naddiseo Neat. 04:59
next thing. is there something for pretty printing the output of .perl ?
05:00 anaeem1 joined 05:01 anaeem1 left
moritz Naddiseo: I don't think so 05:06
Naddiseo *sigh* 05:07
05:07 [Sno] left, kaare_ joined
moritz though there's JSON::Pretty if you have only hashes, arrays, strings, numbers and booleans 05:08
05:08 [Sno] joined 05:11 BenGoldberg left 05:13 bjz joined 05:16 jack_rabbit joined 05:18 raiph left 05:19 awoodland left 05:22 awoodland joined
avuserow I have a nativecall question. Say I have a C function: void foo(int *bar, int *baz); and it does the thing where it puts the return values into bar and baz. Does nativecall have a good way of handling this? 05:22
also is there a better name for this? my C is rusty :(
moritz pointer 05:25
avuserow: you can use a CArray with one element to emulate such a pointer
avuserow I mean specifically returning a value via pointer
and okay, that works :) 05:26
moritz "C" :-)
05:28 bjz left 05:49 atroxaper joined 05:52 bjz joined 05:54 atroxaper left, bjz left 05:55 bjz joined 05:58 sqirrel joined 06:02 kaare_ left 06:15 adu left 06:18 dayangkun joined 06:25 dayangkun left, jack_rabbit left, kaare_ joined 06:26 anaeem1_ joined 06:31 sqirrel left 06:32 mr-foobar left 06:34 bjz left 06:46 anaeem1_ left, anaeem1_ joined 06:49 lue left 06:50 lue joined
raydiak m: my $v = 0; class A { has $.a = Proxy.new(FETCH => method { $v }); }; my $a = A.new; $v = 42; say $a.a; 06:52
camelia rakudo-moar d45c53: OUTPUT«0␤»
raydiak what am I doing wrong?
m: my $v = 0; class A { has $.a = Proxy.new(FETCH => method { \$v }); }; my $a = A.new; $v = 42; say $a.a; # but this works as I expect 06:53
camelia rakudo-moar d45c53: OUTPUT«\(42)␤»
raydiak m: my $a = 0; my $b = Proxy.new(FETCH => method { $a }); $a = 42; say $b; # needless complication removed 06:56
camelia rakudo-moar d45c53: OUTPUT«0␤»
raydiak m: my $a = 0; my $b := Proxy.new(FETCH => method { $a }); $a = 42; say $b; # nevermind :P 06:57
camelia rakudo-moar d45c53: OUTPUT«42␤»
raydiak trying to figure out how I would get a property to default to a Proxy, instead of its value, since you can't bind a default 07:02
07:07 kjs_ joined 07:10 bjz joined 07:19 erkan left 07:21 kjs_ left 07:22 bjz left, erkan joined, erkan left, erkan joined 07:25 darutoko joined 07:31 kaleem joined 07:38 kaleem_ joined 07:40 kjs_ joined, kaleem left 08:08 kjs_ left 08:12 vendethiel left 08:14 lue left 08:17 kjs_ joined 08:18 anaeem___ joined 08:19 cosimo left, cosimo joined 08:20 kjs_ left 08:21 anaeem1_ left 08:22 vendethiel joined 08:27 lue joined 08:32 telex left, erkan left 08:34 erkan joined, telex joined
raydiak good night, #perl6 08:37
08:45 census left 08:48 sqirrel joined 08:59 rindolf joined
dalek kudo/newio: f57427b | moritz++ | src/core/Supply.pm:
Simplify Supply.list
09:00
kudo/newio: 828d0df | lizmat++ | src/core/Supply (2 files):
Deprecate Supply.for in favour of .from-list
kudo/newio: d45c53a | lizmat++ | docs/ChangeLog:
Update ChangeLog for Supply.from-list
kudo/newio: 0477e37 | lizmat++ | / (3 files):
Merge branch 'nom' into newio
09:04 mvuets joined, Mso150 joined
El_Che moritz: ntpd ("lsof -i" showed it running). I just stopped it, I didn't disable it. 09:05
09:12 fhelmberger joined
dalek ecs: 9fd217a | lizmat++ | S17-concurrency.pod:
Rename Supply.for -> from-list

Main reason for this, is that after the GLR, the .for method will have a very different meaning in general. To avoid a conceptual clash, a rename felt warranted.
Also itemize "from-list" and "interval" for clarity.
09:20
09:28 dakkar joined 09:32 abraxxa joined
timotimo has started catching up with the advent posts 09:48
09:48 erkan left
timotimo m: subset Test where * < 10; my Test $foo = 5; 09:48
camelia ( no output )
timotimo m: subset Test where * < 10; my Test $foo = "3";
camelia ( no output )
timotimo mhm, mhm 09:49
there's a "" in the "cool subset of MAIN" post where i suspect the author put "<Any>"
events.ccc.de/congress/2014/Fahrpl.../6243.html - oh, interesting 09:51
09:51 erkan joined
abraxxa sounds bad 09:53
btyler_ there was some discussion about this on /r/perl -- it might be something groundbreaking, but more likely just a CGI param list context bug 10:05
timotimo oh, that thing again
btyler_ bugzilla.mozilla.org/show_bug.cgi?id=1074812 in particular 10:06
10:06 virtualsue joined
abraxxa this one is also by a Checkpoint security researcher: blog.gerv.net/2014/10/new-class-of-...lications/ 10:10
masak good antenoon, #perl6
abraxxa it links to the bug btyler_ pasted
jup, this is it 10:11
Check Point are going to be presenting on this vulnerability at the 31st Chaos Communications Congress in December in Hamburg, so check their analysis out too.
10:26 sqirrel left 10:30 anaeem___ left 10:31 anaeem1_ joined 10:32 kaleem_ left 10:35 Mso150 left 10:38 rurban joined 10:42 kaleem joined 10:43 hekmek joined 10:50 Ugator1 joined 11:05 bjz joined 11:18 atroxaper joined
moritz El_Che: ok, thanks. I deinstalled it, we'll see how well kvm-clock and openntpd on the host machine will work out 11:18
El_Che moritz: imho opinion replacing soft is not always the way to go. Specially if you know one well and the other not. 11:23
11:23 kaleem left
El_Che I am used from solaris zones to disable ntp and let the host feed the time to zones :) 11:23
moritz El_Che: openntpd was already running on the host 11:24
El_Che: reading through the reviews of ntpd source code scared the hell out of me 11:25
El_Che moritz: that bad?
11:25 atroxaper left
El_Che moritz: an alternative could be something like ntpdate in a cron 11:25
moritz El_Che: it's like 300k lines of C code, much of it not written with security in mind 11:26
11:28 spider-mario joined 11:30 avalenn joined 11:36 avalenn left 11:37 avalenn joined 11:39 avalenn left, avalenn joined, vendethiel left
moritz www.p6c.org/ is now live 11:39
11:41 vendethiel joined
moritz (box shadows stolen from the perl6.org 11:44
11:47 Ugator1 left
lizmat moritz++ 11:47
.oO( it feels faster to me)
11:48
11:48 itz_ joined
moritz it also has less content to load :-) 11:50
FROGGS_ ohh yes, it feels way faster
11:51 itz left
FROGGS_ at least in the middle of good Ol' Europe 11:51
moritz it's served from the same box as perl6.org
11:52 sqirrel joined
avalenn what is the difference between p6c.org and perl6.org ? 11:52
moritz avalenn: doesn't the title and contents make that clear? 11:53
FROGGS_ p6c.org and perl6.org look identical 11:54
moritz they do?
FROGGS_ yes
moritz shit, they don't for me :(
have I messed up the virtual hosts again?
FROGGS_ both show: Welcome to Perl 6
Hi, my name is Camelia.
...
avalenn yes, they not only look identical but are for all content and purpose
11:54 rindolf left
moritz at least they both show the perl6.org content 11:55
sorry for the confusion
p6c.org is supposed to show github.com/perl6/www.p6c.org/blob/...index.html
lizmat FROGGS_: do you have any feelings about runtime setting of %*ENV<PERL6LIB> and its effects of @*INC ? 11:56
moritz does www.p6c.org/ show the new thing for everybody?
lizmat moritz: I'm not sure what "new" is, looks identical to perl6.org for me
moritz :(
FROGGS_ I don't see <h1>Perl 6 Community Servers</h1> fwiw on p6c.org 11:57
lizmat: what do you mean by runtime setting?
moritz ok, please try again 11:58
FROGGS_ moritz: that did it :o)
moritz \o/
FROGGS_ lizmat: what I know is that using PERL6LIB to move a CURL::inst to the front does not work for panda
lizmat %*ENV<PERL6LIB> = 'path'; require module # should 'path' be included in search ?
FROGGS_: ok, looking at similar test issues now 11:59
FROGGS_ moritz: btw, I'm reading the Acknowledgements right now and realize I did not have paid by now
lizmat moritz: yeah, much better now
moritz sorry for the confusion everybody 12:00
avalenn: now it should be clear what the difference is :-)
FROGGS_ lizmat: I'm not sure about your example code...
moritz FROGGS_: well, the hardware is paid for, everything coming in now is for maintenance and running costs 12:01
lizmat FROGGS_: if 'module' is in 'path', should the module loader find that or not
FROGGS_ moritz: what do you prefer? that I pay now or on demand? 12:02
moritz FROGGS_: on demand, actually; now I have a decent buffer already
FROGGS_ lizmat: setting $*ENV<PERL6LIB> and expecting a change in @*INC sounds highly magical to me 12:03
too magical
lizmat FROGGS_: agree
FROGGS_ one should mess with @*INC directly or via 'use lib'
lizmat however, it would be a WAT for people coming from P5
I would even say: don't mess with @*INC
FROGGS_ true
lizmat but that is another issue... 12:04
ok, we agree on that then...
FROGGS_ :o) 12:05
12:06 bjz left 12:07 awoodland left 12:27 itz_ left, rurban left, FROGGS_ left, Woodi left, Alina-malina left, yeltzooo9 left, carlin left, synopsebot left, lsm-desktop left, eternaleye left, clkao left, isacloud_ left, kaare_ left, gtodd left, Spot__ left, cosimo left, gfldex left, colomon left, Akagi201_ left, nine left, prime left, cibs left, sqirrel left, virtualsue left, dakkar left, avuserow left, noganex_ left, dalek left, labster left, raydiak left, Celelibi left, Alula left, salv0 left, rmgk left, japhb left, bartolin left, sven_123 left, anaeem1_ left, nebuchadnezzar left, xinming left, dj_goku left, Possum left, fhelmberger left, mvuets left, lue left, lizmat left, charsbar_____ left, haroldwu left, davido___ left, dylanwh left, pnu left, avalenn left, hekmek left, telex left, JimmyZ left, ivan`` left, camelia left, DarthGandalf left, jferrero left, ilbot3 left, breinbaas left, hoelzro left, b2gills left, vendethiel left, erkan left, abraxxa left, FROGGS[mobile] left, petercommand left, djanatyn left, jtpalmer left, diegok left, Naddiseo left, kst left, ggoebel111111114 left, pochi left, avar left, betterwo1ld left, yoleaux left, wtw left, vukcrni left, woshty left, apejens left, spider-mario left, darutoko left, lestrrat left, hugme left, [Coke] left, Guest19298 left, araujo left 12:28 skarn joined, cibs joined, leedo_ joined, tinita_ joined, Timbus joined, MilkmanDan joined, dg joined, El_Che joined, alexghacker joined, mathw joined, mtj joined, Guest98101 joined, pyrimidine joined, PerlJam joined, cxreg2 joined, baest joined, jnthn joined, daxim joined, ingy joined, skaufman1 joined, MABGFJ3 joined, nine joined, Akagi201_ joined, colomon joined, gfldex joined, cosimo joined, Alina-malina joined, pmichaud joined, Sir_Ragnarok joined, moritz joined, Khisanth joined, broquaint joined, hahainternet joined, Spot__ joined, gtodd joined, kaare_ joined, Juerd joined, hobbified joined, isacloud_ joined, clkao joined, rhr_ joined, integral joined, eternaleye joined, lsm-desktop joined, jtpalmer joined, diegok joined, risou joined, jdv79 joined, jantore joined, eMBee joined, tony-o joined, anocelot joined, TimToady joined, Gothmog_ joined, nwc10 joined, mst joined, Ulti joined, BinGOs joined, frew joined, simcop2387 joined, huf joined, _sri joined, mls joined, Bucciarati joined, rjbs joined, mattp_ joined, osfameron joined, stux|RC-only joined, salparadise joined, Diederich joined, apejens joined, b2gills joined, hoelzro joined, breinbaas joined, woshty joined, vukcrni joined, ilbot3 joined, wtw joined, sven_123 joined, yoleaux joined, Possum joined, betterwo1ld joined, avar joined, jferrero joined, djanatyn joined, pochi joined, ggoebel111111114 joined, kshannon joined, romel joined, atta joined, amkrankr1leuen joined, sivoais joined, sjn joined, mephinet joined, weber.freenode.net sets mode: +v yoleaux, sunnavy joined, zoosha joined, Pleiades` joined, sergot joined, tadzik joined, xiaomiao joined, ponbiki joined, epochbell joined, xopatch joined, Maddingue joined, masak joined, mtj_ joined, flussence joined, m_athias joined, awwaiid joined, dsm joined, Util joined, retupmoca joined, lumimies joined, smash joined, ka05 joined, torbjorn joined, [particle] joined, oetiker joined, FlipBill joined, bcode joined, erdic joined, esaym153 joined, |Tux| joined, robinsmidsrod joined, BooK_ joined, orevdiabl joined, vike1 joined, geekosaur joined, SHODAN joined, go|dfish joined, sorear joined, Exodist joined, ggherdov joined, arnsholt_ joined, ribasushi joined, ugexe_ joined, yakudza joined, jercos joined, timotimo joined, woolfy joined, muraiki joined, yogan joined, Grrrr joined, pnu joined, [TuxCM] joined, Celelibi joined, dylanwh joined, raydiak joined, labster joined, davido___ joined, dj_goku joined, bartolin joined, haroldwu joined, salv0 joined, DarthGandalf joined, araujo joined, Guest19298 joined, camelia joined, xinming joined, petercommand joined, [Coke] joined, charsbar_____ joined, hugme joined, ivan`` joined, lestrrat joined, kst joined, lizmat joined, nebuchadnezzar joined, japhb joined, dalek joined, Alula joined, FROGGS[mobile] joined, JimmyZ joined, rmgk joined, noganex_ joined, Naddiseo joined, avuserow joined, darutoko joined, lue joined, telex joined, mvuets joined, fhelmberger joined, dakkar joined, abraxxa joined, erkan joined, virtualsue joined, anaeem1_ joined, hekmek joined, weber.freenode.net sets mode: +vvv camelia hugme dalek, spider-mario joined, avalenn joined, vendethiel joined, sqirrel joined, itz_ joined, rurban joined, FROGGS_ joined, Woodi joined, yeltzooo9 joined, carlin joined, synopsebot joined, prammer joined 12:37 BenGoldberg joined 12:49 kaleem joined, rurban left 12:52 anaeem1_ left 12:53 kaleem left 12:54 BenGoldberg left 12:55 sqirrel left 13:11 atroxaper joined 13:15 atroxaper left
lizmat drops a pin in the storm 13:30
13:31 telex left
moritz 's powerful magnet catches it before it hits the floor 13:31
13:33 telex joined 13:35 anaeem1_ joined 13:37 atroxaper joined 13:43 bjz joined
lizmat notices some classes in the setting are not "my" 13:48
does that make any difference? (I think not, but checking just in case)
moritz m: say OUR::<VM> 13:49
camelia rakudo-moar d45c53: OUTPUT«(Any)␤»
lizmat m: say OUR::<Pair>
camelia rakudo-moar d45c53: OUTPUT«(Any)␤»
lizmat so guess not, right ?
moritz m: class A { }; say OUR::<A> 13:50
camelia rakudo-moar d45c53: OUTPUT«(A)␤»
moritz lizmat: it seems the OUR from the setting is simply dropped somewhere
lizmat m: say SETTING::<Pair>
camelia rakudo-moar d45c53: OUTPUT«(Any)␤»
lizmat m: say SETTING::<VM>
camelia rakudo-moar d45c53: OUTPUT«(Any)␤»
lizmat m: say SETTING::<Pair>:exists
camelia rakudo-moar d45c53: OUTPUT«False␤»
lizmat m: say SETTING::<VM>:exists 13:51
camelia rakudo-moar d45c53: OUTPUT«False␤»
lizmat m: use Supply; 13:53
camelia rakudo-moar d45c53: OUTPUT«===SORRY!===␤Could not find Supply in any of: /home/camelia/rakudo-inst-2/languages/perl6/lib, /home/camelia/rakudo-inst-2/languages/perl6␤»
lizmat I was thinking of creating a hash in ModuleLoader with the names of the modules in core
and create a better error message
hoelzro ahoy #perl6
lizmat (if loading failed)
hoelzro o/
hoelzro o/ lizmat 13:54
13:57 jack_rabbit joined 14:04 rindolf joined
raydiak good morning, #perl6 14:06
lizmat raydiak o/
raydiak \o lizmat 14:07
14:08 erkan left 14:11 erkan joined, erkan left, erkan joined 14:12 PZt joined 14:16 kaare_ left 14:28 telex left
vendethiel okay, let me try something dangerous now. 14:28
:P
m: role Parent[::T]{ role Sub[T $x] { constant VAL = $x; } }; subset ParentInt of Parent[Int]; subset SubInt of ParentInt::Sub[5]; say SubInt::VAL; 14:29
camelia rakudo-moar d45c53: OUTPUT«===SORRY!===␤You cannot create an instance of this type␤»
vendethiel =(
14:30 telex joined
moritz also it would be SubInt::Sub::VAL, if at all 14:30
vendethiel moritz: no 14:31
moritz: I have two subsets
(the subsets are only necessary because X[Y]::Z doesn't parse ATM) 14:36
(...Which I should definitely look at)
14:37 raiph joined
lizmat errands& 14:42
dalek kudo/nom: c05de61 | lizmat++ | src/Perl6/ModuleLoader.nqp:
Remove trailing whitespace
14:43
moritz vendethiel: I don't think subsets inhert the WHO at all 14:44
14:44 Rounin joined
moritz m: role Sub[T $x] { constant VAL = $x; }; Sub[42].WHO<VAL> 14:45
camelia rakudo-moar d45c53: OUTPUT«===SORRY!=== Error while compiling /tmp/2walLxsg6y␤Invalid typename 'T' in parameter declaration.␤at /tmp/2walLxsg6y:1␤------> role Sub[T⏏ $x] { constant VAL = $x; }; Sub[42].WHO␤»
moritz m: role Sub[$x] { constant VAL = $x; }; Sub[42].WHO<VAL>
camelia rakudo-moar d45c53: OUTPUT«===SORRY!===␤You cannot create an instance of this type␤»
moritz m: role Sub[$x] { constant VAL = $x; }; 14:51
camelia rakudo-moar d45c53: OUTPUT«===SORRY!===␤You cannot create an instance of this type␤»
vendethiel m: role Sub[$x] { method x { $x } }; Sub[5].say 15:02
camelia rakudo-moar d45c53: OUTPUT«===SORRY!===␤You cannot create an instance of this type␤»
vendethiel m: role Sub[Int $x] { method x { $x } }; Sub[5].say
camelia rakudo-moar d45c53: OUTPUT«===SORRY!===␤You cannot create an instance of this type␤»
vendethiel what?
I'm positive this worked...
m: role Foo[Str $x] { method print { say $x } }; Foo["hey".uc].print
camelia rakudo-moar d45c53: OUTPUT«HEY␤»
vendethiel uh-oh.
moritz: is it the "Int"? 15:03
moritz m: say Sub
camelia rakudo-moar d45c53: OUTPUT«(Sub)␤»
moritz vendethiel: perhaps related to the fact that 'Sub' already is a class?
vendethiel probably is. 15:04
m: role X[Int $x] { method x { $x } }; X[5].say
camelia rakudo-moar d45c53: OUTPUT«(X[Int])␤»
vendethiel yeah.
m: role Foo[T $x] { constant VAL = $x; }; Foo[42].WHO<VAL> 15:05
camelia rakudo-moar d45c53: OUTPUT«===SORRY!=== Error while compiling /tmp/vX2Up5fc8M␤Invalid typename 'T' in parameter declaration.␤at /tmp/vX2Up5fc8M:1␤------> role Foo[T⏏ $x] { constant VAL = $x; }; Foo[42].WHO␤»
vendethiel m: role Foo[::T $x] { constant VAL = $x; }; Foo[42].WHO<VAL>
camelia rakudo-moar d45c53: OUTPUT«Cannot call 'postcircumfix:<{ }>'; none of these signatures match:␤:(Any \SELF, Any \key)␤:(Any \SELF, Any \key, \ASSIGN)␤:(Any \SELF, Any \key, :BIND($BIND)!)␤:(Any \SELF, Any \key, Any :SINK($SINK)!, *%other)␤:(Any \SELF, Any \key, Any :delete(…»
avalenn /msg camelia help 15:06
moritz m: role Foo[::T $x] { constant VAL = $x; }; Foo[42].WHO.^name 15:07
camelia rakudo-moar d45c53: OUTPUT«(signal SEGV)»
15:07 kaleem joined
moritz that's not good :-) 15:07
moritz rakudbugs it
p: role Foo[::T $x] { constant VAL = $x; }; Foo[42].WHO.^name
camelia rakudo-parrot d45c53: OUTPUT«Can only use get_how on a SixModelObject␤ in block <unit> at /tmp/2psc3GXD8v:1␤␤»
moritz r: role Foo[$x] }; Foo[42].WHO.^name 15:08
camelia rakudo-{parrot,moar} d45c53: OUTPUT«===SORRY!=== Error while compiling /tmp/tmpfile␤Unable to parse role definition␤at /tmp/tmpfile:1␤------> role Foo[$x] ⏏}; Foo[42].WHO.^name␤»
moritz r: role Foo[$x] { }; Foo[42].WHO.^name
camelia rakudo-parrot d45c53: OUTPUT«Can only use get_how on a SixModelObject␤ in block <unit> at /tmp/tmpfile:1␤␤»
..rakudo-moar d45c53: OUTPUT«(signal SEGV)»
moritz golf'd 15:09
15:16 jack_rabbit left
vendethiel moritz++ 15:17
15:34 rurban joined 15:37 kaare_ joined 15:40 jack_rabbit joined 15:41 molaf joined, jack_rabbit left 15:42 jack_rabbit joined 15:47 kaleem left 15:51 sqirrel joined 15:55 jack_rabbit left 15:58 raiph left
colomon oh noez, abctranspose is broken! 15:58
m: my $key = Mu 16:02
camelia ( no output )
colomon m: my $key = Mu; say "Okay"
camelia rakudo-moar c05de6: OUTPUT«Okay␤»
colomon ===SORRY!=== 16:07
Type check failed in binding $key; expected 'Any' but got 'Mu'
any way to get a better error message?
I ask because my code never binds a variable named $key anywhere but a my statement 16:09
16:10 abraxxa left 16:12 atroxaper left 16:13 atroxaper joined, atroxaper left 16:16 muraiki left 16:18 mvuets left 16:19 muraiki joined
moritz colomon: run with --ll-exception 16:21
colomon: maybe it's in the setting
16:23 mr-foobar joined 16:26 sqirrel left 16:29 hekmek left
masak ooh, www.p6c.org/ 16:32
moritz++ 16:33
moritz I guess I should announce the new server (and feather EOL) on some mailing list(s) 16:38
p6c? p6a? p6u?
16:38 raiph joined
masak all of the above sounds good to me. 16:40
nwc10 p6a is p6c|p6u ? 16:41
masak I think they're all disjunct... 16:42
colomon moritz++: good call
enum.Invert? 16:44
called by (several steps skipped) MapIter.reify? 16:45
elsif ($did_iterate || nqp::elems($rpa) || $rpa) && nqp::can($block, 'fire_phasers') { 16:46
$block.fire_phasers('LAST');
}
is the final step in the backtrace.
:\
moritz colomon: can you nopaste the whole backtrace please? 16:49
colomon moritz: gist.github.com/colomon/89d63a42453a978e3033 16:50
oh!
not running the moar I thought I was
ack, this one's just as scary 16:51
my $coro := { nqp::continuationreset($GATHER_PROMPT, $state); $takings };
moritz colomon: the whole backtrace is from the setting?
colomon is the top call the trace reports
moritz: yes 16:52
moritz colomon: does a simple perl6 -e 'say 42' work?
colomon yes 16:53
and "panda install ABC" works fine
but I don't think the abctranspose module is ever tested 16:54
moritz colomon: does loading the module alone work?
colomon: on my build, src/gen/m-CORE.setting:13612 points into X::Mixin::NotComposable 16:55
colomon yes
yes, but I'm 100% sure my m-CORE.setting is different than yours
moritz: the abc2ly script (which is my main use for ABC module) works fine. 16:56
so basically this rakudo works, but I'm doing something which triggers massive wonkiness 16:57
16:59 cognominal joined
colomon actually, I don't think those line numbers correspond meaningfully to my m-CORE.setting either. 17:00
moritz colomon: then there might some wonkyness with using older .moarvm files going on 17:01
colomon: what command are you running? I'll try to reproduce on my machine
colomon ack, that will be hard. 17:02
moritz t/06-duration.t ... ok
Could not find symbol '&Actions'
colomon moritz: right, as I said, current Rakudo is broken WRT ABC
it's one of the damned precompile bugs.
moritz :(
colomon …. so why don't I try current rakudo without compiling 17:03
?
give me a minute
gtodd feather EOL! 17:06
17:09 robinsmidsrod left 17:10 robins joined
masak m: say "feather ", chr(0xa), "!" 17:11
camelia rakudo-moar c05de6: OUTPUT«feather ␤!␤»
masak feather NL!
17:14 atroxaper joined
gtodd feather no longer 17:14
moritz: re ntpd software .... there's always taiclockd as an alternative ;-) 17:15
masak still hasn't learned not to log into feather in the antenoon 17:17
moritz masak: should I disable your feather account? 17:19
17:19 zakharyas joined
moritz gtodd: I've installed openntpd 17:19
nwc10 either that or send him coffee
17:19 cognominal left 17:20 cognominal joined, atroxaper left
moritz (and the thread level isn't all too high, because the NTP servers that it talks to are in the AS, and I trust those who run the network) 17:20
gtodd moritz: ++ most things associated with openbsd use security aware developers and such ....
masak moritz: that might help, yes. 17:21
moritz masak: I've set your login shell to /bin/false. I hope that helps 17:22
gtodd moritz: that last remark about trust constitutes the main security feature of everything :-)
colomon moritz: okay, I can duplicate with latest rakudo 17:23
moritz colomon: :( 17:24
gtodd writing about sort on the 23rd++
moritz: that is a sort of good article 17:26
moritz gtodd: thanks :-)
colomon moritz: so you need to clone the ABC repo
moritz colomon: done 17:27
colomon then get this file: gist.github.com/colomon/1ab1285e9daa221ff65f
then perl6 --ll-exception -Ilib bin/abctranspose Dmix Amix +7 <road_press.abc
and you should get the error I'm seeing 17:28
17:28 fhelmberger left
moritz colomon: I do 17:29
17:29 fhelmberger joined
moritz colomon: curious; I don't need the input file to reproduce the error, but I do need the command line arguments 17:30
17:30 anaeem1_ left
colomon yeah, just started worrying about that +7 17:30
nope, 7 still fails 17:31
moritz colomon: it seems to be $in.slurp in sub Transpose that produces the error 17:33
m: say $*IN.slurp
camelia rakudo-moar c05de6: OUTPUT«Céad slán ag sléibhte maorga Chontae Dhún na nGall␤Agus dhá chéad slán ag an Eireagal ard ina stua os cionn caor is coll;␤Nuair a ghluais mise thart le Loch Dhún Lúich’ go ciúin sa ghleann ina luí␤I mo dhiaidh bhí gleanntáin ghlas’ G…»
17:33 fhelmberger left
moritz m: sub f($in) { $in.slurp.chars }; say f $*IN 17:33
camelia rakudo-moar c05de6: OUTPUT«1134␤Saw 1 call to deprecated code during execution.␤================================================================================␤Method slurp (from IO::Handle) called at:␤ /tmp/URNNZyBU3n, line 1␤Deprecated since v2014.10, will be removed w…»
moritz huh, not so easy to reproduce 17:34
17:34 anaeem1 joined
moritz colomon: maybe the deprecation stuff is tripping over something else 17:34
colomon moritz: brill! 17:37
17:38 anaeem1 left
moritz colomon: oh 17:38
colomon: $original-key.scale-names produces ("D", "E", "F", "G", "A", "B", "C", "D", "E", "F", "G", Mu)
colomon afk # but looking forward to fixing stuff when he gets the computer back
moritz colomon: github.com/colomon/ABC/pull/1 waiting for you :-) 17:45
TimToady moritz: "please say so to." too? 17:46
(on p6c)
moritz TimToady: yes
TimToady: fixed in git, thanks 17:47
and smls++ also fixed a typo in git
masak .oO( I don't always remote shell -- but when I do, I /bin/false ) :P 17:50
17:50 koo6 joined
moritz Now I wonder why people (including myself) use /bin/false as a shell entry in /etc/passwd, when /bin/true would work just as well 17:52
does the exit status of the login shell determine if things show up in a log somewhere, maybe?
17:53 rurban left 17:55 dakkar left
jdv79 what determines what is built in or not? just a list in the setting? 17:57
masak jdv79: basically.
well, definitions in the setting, I guess.
jdv79 and they all just "export" as per their default mechanism - just trying to understand how stuff is just available globally 17:58
17:59 zakharyas left
moritz jdv79: they are in an outer lexical scope of the program you run 17:59
jdv79 so its not like the setting specs a list of well defined modules and then it loads them and they in turn export? 18:01
18:01 anaeem1 joined
moritz jdv79: no 18:04
jdv79: the motivation is that it makes lexical overriding/shadowing of pre-defined symbols possible 18:05
18:05 anaeem1 left
moritz it falls naturally out of the outer-lexical semantics 18:05
m: say pi
camelia rakudo-moar c05de6: OUTPUT«3.14159265358979␤»
18:05 anaeem1_ joined
moritz m: my \pi = 3.2; say pi 18:05
camelia rakudo-moar c05de6: OUTPUT«3.2␤»
18:06 virtualsue left
jdv79 interesting. thanks. 18:09
18:12 Mso150 joined
sergot moritz++ # p6c.org 18:14
moritz TimToady: if you have a bit of spare mental power, please take a look / comment on github.com/rakudo/rakudo/pull/339 18:18
18:26 erkan left, Ugator1 joined 18:28 erkan joined
colomon moritz++ moritz++ moritz++ 18:30
18:46 pmurias joined
pmurias does anyone besides me feel that an ack6 would be useful? 18:46
colomon pmurias: useful in what sense? 18:47
pmurias I do relatively a lot of searching with ack, I feel it we be awesome to do that using Perl 6 rules 18:49
vendethiel pmurias: I've considered translating github.com/tombenner/ru to p6 18:58
(admittedly not the same)
pmurias OTOH after thinking about it a bit what I really want is a structured code search: like all the mentions of a variable matching /foo.*/ 19:00
vendethiel: what I was also thinking recently is to make p6 *the* shell 19:01
vendethiel pmurias: ooh, that sounds pretty amazing as well. would work
pmurias with a slang that would allow shellish things
19:02 psch joined
pmurias so typing "ls" works ;) 19:02
psch hi #perl6 19:03
pmurias: p6sh is something that came up in my head as well, partly inspired by e.g. pryrepl.org 19:04
TimToady moritz: I'm fine with the \W approach
psch in a similar vein, improving the REPL had been on my mind as well for a long time, but i think that relies on a few things we don't quite do yet
e.g. allowing line breaks in the REPL means we'd have to lift it from NQP further towards HLL territory, i think 19:06
s/line breaks/line breaks as generic white space/
pmurias the p6sh seems seems to be a sum of an improved REPL and a shell slang 19:07
dalek kudo/nom: 27a9887 | usev6++ | src/Perl6/Grammar.nqp:
Allow postfix operator called as method after unary postfix hyper operator

currently something like '(my @a = 1)>>.++' fails, since METAOP_HYPER_CALL is called instead of METAOP_HYPER_POSTFIX. Fixes RT #122342.
kudo/nom: c941b0b | usev6++ | src/Perl6/Grammar.nqp:
Allow dotted form of postfix operator after unary postfix hyper operator, but only for non-wordy operators

The previous version which special cased postfix:<i> only seemed too fragile. Now the dotted form is allowed only for non-wordy operators.
synopsebot Link: rt.perl.org/rt3//Public/Bug/Displa...?id=122342
kudo/nom: 8154bd3 | moritz++ | src/Perl6/Grammar.nqp:
Merge pull request #339 from usev6/nom

Allow postfix operator called as method after unary postfix hyper operator
19:08 raiph left
psch pmurias: well, there is design decisions as well. e.g. *sh in general takes ^M as "evaluate this", while the REPL should check if what's been entered up to now could be completed to be valid 19:11
but then maybe /{$/ could *for p6sh* count as equivalent to \^M 19:12
i'm far from clear about how HLL::Compiler.interactive could be adjusted to allow \n as meaningless white space :/ 19:13
19:15 rindolf left
pmurias psch: that would need integration with the parser 19:16
FROGGS_ psch: that is what moreinfo should do (grep the irclogs and/or std for that term) 19:20
psch FROGGS_++: that's probably what i remembered that was missing without remembering the term for it 19:21
FROGGS_ :o)
psch heh irclog.perlgeek.de/perl6/2014-10-09#i_9480243 19:24
FROGGS_ hhe
hehe* 19:25
19:44 cognominal left 19:48 FROGGS__ joined 19:52 FROGGS_ left 20:10 virtualsue joined 20:19 Rounin left
TimToady s/moreinfo/moreinput/ 20:20
FROGGS__ yeah
masak TimToady: how's tomorrow's post coming along? 20:23
20:27 psch left, brrt joined 20:29 darutoko left 20:35 psch joined 20:37 mickcy_ca joined
[Coke] TimToady, moritz: "please say so to." was fixed to "so to0.", I changed it to "so." 20:38
mickcy_ca I am wondering if anyone can assist with linux fifo access 20:39
More accurately, linux sytem pipes
moritz [Coke]++ 20:40
geekosaur what's the question? (I don't think even perl 6 can fix fifos; they are idiosyncratic and almost never what you really want.) 20:42
mickcy_ca I am attempting to get data from ffmpeg through a pipe ... P5 - no problem ... P6 ... my $pipe= 'test'.IO; $pipe.get.say; .. .crashes with "Failed to seek in filehandle: 29" 20:44
masak wow, an actual Perl 6 question. didn't expect that. :) 20:45
mickcy_ca: I'm getting `No such method 'get' for invocant of type 'IO::Path'` -- do you have an outdated version of Rakudo? 20:46
mickcy_ca This is perl6 version 2014.09 built on MoarVM version 2014.09 20:47
Similar failure happens with $pipe.lines.say
geekosaur hm, why is get trying to seek? 20:49
so it's not an issue with fifos /per se/, but perl6 is doing something it probably shouldn't 20:50
mickcy_ca That is my assumption ...
Especially since Perl5.18.2 does fifo access flawlessly. 20:51
Interestingly, both .get and .lines can get the first value at run, but report blank lines after on the default Ubuntu install (2013 ... removed it already). Same basic error on Parrot and JVM. 20:53
Sorry ... on 2014.09, JVM reports only blank lines. 20:54
20:55 atroxaper joined
[Coke] Should p6c.org be an alias for www.p6c.org? 20:55
mickcy_ca Submitted as bug number 123484 20:57
psch mickcy_ca: .read works locally, with a ~1h old perl6-m build. no idea if it works on 2014.9. note that you get a Buf from that and have to encode (i think?) 20:58
nope, decode :) 20:59
mickcy_ca Maybe stupid question ... how to get bleeding edge version? 21:01
21:01 atroxaper left
mickcy_ca .get fails with "No such method 'read_bytes' for invocant of type 'Any" on 2014.09 21:02
moritz mickcy_ca: rakudo.org/how-to-get-rakudo # iirc
mickcy_ca Sorry that was parrot ..MoarVM say : "read bytes requires an object with REPR MVMOSHandle" ... Not sure what this is. 21:03
psch mickcy_ca: github.com/tadzik/rakudobrew for easy access to the bleeding edge 21:04
mickcy_ca Compiling ...
avuserow anyone tried HTTP::Server::Async lately? it seems to spin my CPU with a "hello world" server on moarvm. 21:06
rakudo built yesterday: This is perl6 version 2014.12-26-gd45c53a built on MoarVM version 2014.12
TimToady masak: pretty much done, but need to eat lunch now 21:10
masak TimToady++
21:14 cognominal joined 21:19 brrt left, Ecto joined 21:20 Ecto left 21:21 sqirrel joined 21:24 awoodland joined 21:34 kjs_ joined 21:38 ninjazach joined 21:42 awoodland left 21:43 awoodland joined
dalek ar: e5f2897 | moritz++ | tools/ (2 files):
Bump versions to 2014.12
21:44
ar: f86e108 | moritz++ | modules/ (14 files):
Update module revisions
21:44 robins is now known as robinsmidsrod
moritz all module tests pass with the moar backend 21:44
21:49 rurban joined, telex left 21:50 telex joined
moritz rakudo-parrot complains about missing install/bin/ops2c 21:52
21:52 erkan left 21:54 erkan joined
moritz why didn't that occur for the compiler release? 21:55
mickcy_ca OK ... I have gone bleeding edge ... same problem with reading from a system fifo. 21:56
moritz oh, because star has another copy of NQP::Configure
21:57 kjs_ left
masak :/ 21:57
psch mickcy_ca: are you opening the handle?
mickcy_ca Same error if I open or not. 21:58
21:59 sqirrel left
mickcy_ca Something else curious ... is there a reason why many of the functions that are listed at github.com/perl6/specs/blob/master...ary/IO.pod thrown as "No such method ..."? 22:00
timotimo what's with p6c.org now? 22:01
psch mickcy_ca: as mentioned, .read works for me, see gist.github.com/peschwa/934fd8e42da67b4c23c5
moritz timotimo: what should be with it? 22:02
timotimo it still looks like perl6.org on my machine
hold on ...
ah, a ctrl-r helped
psch mickcy_ca: .get is definitely bugged, but you reported that i think? 22:03
mickcy_ca psch: Reported .get and .list. 22:04
psch mickcy_ca++ 22:05
mickcy_ca psch: ... .lines not .list.
psch: This is perl6 version 2014.12-30-g8154bd3 built on MoarVM version 2014.12 22:06
throws No such method 'read' for invocant of type 'IO::Path'
psch m: IO.Path.^methods.say 22:07
camelia rakudo-moar 8154bd: OUTPUT«No such method 'Path' for invocant of type 'IO'␤ in block <unit> at /tmp/JXossQygVc:1␤␤»
psch m: IO::Path.^methods.say
camelia rakudo-moar 8154bd: OUTPUT«FALLBACK new gist␤»
psch m: IO::Handle.^methods.say
camelia rakudo-moar 8154bd: OUTPUT«FALLBACK new gist␤»
psch huh
timotimo try :all for ^methods?
psch m: IO::Handle.^methods(:all).say
camelia rakudo-moar 8154bd: OUTPUT«FALLBACK new gist ACCEPTS WHERE WHICH take WHY set_why Bool so not defined new CREATE bless BUILDALL BUILD_LEAST_DERIVED Numeric Real Str Stringy item say print note gist perl DUMP DUMP-PIECES DUMP-OBJECT-ATTRS isa does can clone Capture Method+{<anon>}.ne…»
moritz it's camelia
it cripples IO 22:08
for safety
psch oh, right, RESTRICTED again
timotimo oh, of course
raydiak attempting to open a pipe blocks until something is written to it? 22:11
moritz opening not, I hope
timotimo maybe it blocks until something opens it from the other side?
timotimo has hardly used fifos so far
raydiak no, I mean...unless I'm doing something wrong, it *does* 22:12
psch raydiak: that's what i'd think from what i see. echoing into a fifo blocks until something reads, so reading block until something writes 22:13
raydiak psch: I'm not trying to read anything
psch oh, wait, just opening shouldn't block, no
raydiak perl6 -e 'open "testpipe"' blocks
so something somewhere is trying to read and then seek back to 0, even on pipes, for whatever reason 22:14
do we look for a BOM automagically when we open files or anything? 22:15
timotimo BOM is deprecated :) 22:16
22:16 jferrero left 22:17 jferrero joined
raydiak ah 22:17
timotimo (as is windows)
mickcy_ca psch: read does not appear on either of those method probes.
psch: I mean any of those ... IO::Handle.^methods(:all).say spews out much but read does not appear on my just compiled version. 22:19
22:20 Naddiseo left
psch right, i didn't ran the perl6-m i recently compiled... 22:20
that's what i get for having one perl6-m in my $PATH and a few others that i just fiddle around with...
mickcy_ca: 2014.12-30-g8154bd3 and 2014.12-11-g08c2b0f both have IO::Handle.read 22:21
that's the two perl6-m i have built atm 22:22
TimToady perl6advent.wordpress.com/2014/12/2...a84e79302e
22:24 Mso150 left
mickcy_ca psch: Apparently, I am on crack is see read now ... testing ... 22:24
vendethiel TimToady++ 22:25
mickcy_ca psch: SUCCESS!!!!! my problem with read was that I set up var as my $fifo = "fifo".IO ... $fifo.WHAT.say says IO::Path then $fifo.open ... $fifo.WHAT.say says IO::Path ... If I do $fifo = "fifo"; $fifo = open $fifo; $fifo.WHAT.say says IO::Handle ... and now read works. 22:29
psch mickcy_ca: you can "fifo".IO.open
i.e. my $handle = "fifo".IO.open 22:30
22:30 kaare_ left
psch .open returns the opened IO::Handle from an IO::Path 22:30
mickcy_ca psch: so it does ... found another bug. 22:31
psch: I can submit that.
moritz compiling stuff with parrot feels really sluggish, now that I'm used to Moar 22:34
psch mickcy_ca: submit what?
mickcy_ca If you open the file directly with $file = "test".IO.open $file.WHAT is IO::Handle ... if one uses $file = $test.IO; $file.open; $file.WHAT reports IO::Path. This is inconsistent. 22:38
psch m: sub pretend-im-open ($file) { return "opened" }; my $opened = pretend-im-open("file"); my $file = "file"; pretend-im-open($file); say $opened; say $file 22:39
camelia rakudo-moar 8154bd: OUTPUT«opened␤file␤»
psch mickcy_ca: to expand on that, calling $file.open doesn't assign the opened Handle to $file, it returns it in sink context 22:40
mickcy_ca: you can use .= instead of . if you want it opened in-place (i think)
moritz TimToady++
moritz took the liberty of setting the category to 2014
psch yeah, if you have a IO::Path in $file and use $file .= open you get an opened IO::Handle afterwards 22:41
mickcy_ca: i don't see the inconsistency. .open is a method that returns an opened IO::Handle from an IO::Path, but you're no assigning that Handle but trying to read from the Path 22:42
22:42 naddiseo joined
psch mickcy_ca: on the other hand, "test.IO.open calls open on the Path and returns the Handle and that gets assigned to $file 22:43
s/"//
err, s/"test/"test"/
mickcy_ca psch: You are correct, but calling .open on a previously declared IO::Path object should convert and return an IO::Handle object to be consistent with calling .io.open. 22:46
psch mickcy_ca: it can't convert in-place, because the callee might be immutable. conside 22:47
m: "abc" ~~ s/a/d/
camelia rakudo-moar 8154bd: OUTPUT«Cannot assign to an immutable value␤ in method subst-mutate at /home/camelia/rakudo-inst-2/languages/perl6/runtime/CORE.setting.moarvm:1␤ in method subst-mutate at src/gen/m-CORE.setting:4099␤ in block <unit> at /tmp/yUmsbzRPCJ:1␤␤»
raydiak TimToady++: "implementtors"
22:47 awoodland left, atroxaper joined
psch mickcy_ca: same for "file".IO.open; the String "file" is immutable and can't be turned into a Handle 22:48
mickcy_ca: and surely special-casing .open to check whether the callee is a container or not isn't sane :)
(or is it the caller and i'm mixing this up again..? :/ )
what i mean with callee is "object the method is called on", which probably isn't what callee means... 22:50
mickcy_ca psch: Thanks for the feedback, but surely whether you call .IO.open or .IO followed by .open, the same results should follow. They don't. 22:52
Should it matter if I call it in one line or I proceed to do it in two lines for some reason. 22:53
22:54 atroxaper left
psch mickcy_ca: by that reasoning <my $x = 5 + 5;> and <my $x = 5; $x + 5> should both result in $x == 10 22:58
mickcy_ca psch: That is a great way to put it ... my reasoning is that if I execute <my $x = 5 + 5;> and <my $x = 5; $x += 5;> they should both return 10; 23:01
psch mickcy_ca: but you're not executing $x += 5, you're executing $x + 5. if you want $x += 5 use .= instead of . 23:02
mickcy_ca psch: I get now ... .open is not a coercer.
psch m: my $file = "file"; $file.subst(/file/, "opened"); say $file; $file .= subst(/file/, "opened"); say $file
camelia rakudo-moar 8154bd: OUTPUT«file␤opened␤»
mickcy_ca <sigh> my misunderstanding has been cleared up. Thank you VERY much. 23:03
psch mickcy_ca++: glad to help :) 23:04
mickcy_ca psch:++
23:17 ninjazach left
mickcy_ca Another question ... testing the Supply framework ... cannot seem to get the following to work <my my $pipe = 'test_pipe'.IO.open; my $supply = Supply.new.map({$pipe.read(30).dec....tap(-> $s {$s.say;}); sleep 20;> This outputs nothing, even though the $pipe.read is verified in a while loop elsewhere. 23:18
23:18 bcode_ joined
Timbus mickcy_ca, map is supposed to be applied to data being passed through the supply 23:22
you arent passing anything through it..
23:23 rurban left
mickcy_ca Timubs: That is interesting ... I may have made a error understanding perl6advent.wordpress.com/2013/12/1...ogramming/ where much the same framework was used. 23:25
Timbus: this works if I change Supply.new -> Supply.interval(1) 23:29
Timbus interval is an instance of a supply that pumps a tick every 1 second, so yeah 23:30
psch TimToady: "Eventually we we either reach a consensus" - i think one of those "we"s should go
TimToady oui
Timbus put an 'or' inbetween the we's imo 23:31
vendethiel TimToady: non
psch also "which is a certainly a mistake" 23:33
23:34 raiph joined
TimToady fixed 23:35
Timbus mickcy_ca, try this: my $supply = Supply.from-list('test_pipe'.IO.open.lines); 23:37
it might work how you want
hm, except you need bytes, not lines 23:38
23:43 bcode_ left
mickcy_ca Timbus: Big conversation about .lines "Failed to seek in filehandle: 29" earlier on ... running 2014.12-30-g8154bd3 built on MoarVM version 2014.12 ... and honestly, I would prefer lines. 23:46
23:47 cognominal left
Timbus oh 23:47
23:47 cognominal joined
mickcy_ca That is the whole reason for using .read 23:47
23:47 cognominal left
Timbus well in your case, you need to make your own supply. that's less cool though 23:48
psch you can build a Supply with gather/take around read(1) 23:51
Timbus yeah
23:52 Ugator1 left, Ugator1 joined
mickcy_ca psch: not sure how to do that. 23:55
I would like to get rid of the interval because the data from my source comes out at "about 1 / sec". 23:57
psch mickcy_ca: something like my $s = Supply.new; $s.emit({ my $fh = "file".IO.open; gather { while $fh.read(1).decode('UTF-8') -> $chr { my $line; if $chr ~~ /\n/ { take $line } else { $line ~= $chr } } 23:58
Timbus read 1 and then decode? something about that.. 23:59
psch plus syntax corrections :) (i think "})" at the end)