»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:, or /msg camelia p6: ... | irclog: irc.perl6.org or colabti.org/irclogger/irclogger_logs/perl6 | UTF-8 is our friend!
Set by moritz on 22 December 2015.
00:02 Rawriful left 00:10 espadrine joined 00:14 espadrine_ left 00:37 john51 left, john51 joined 00:40 mempko left 00:43 splatt9990 joined 00:55 markong left 01:01 astj joined 01:02 Cabanossi left 01:04 aborazmeh joined, aborazmeh left, aborazmeh joined 01:05 Cabanossi joined 01:17 unicodable6 left, quotable6 left, unicodable6 joined, ChanServ sets mode: +v unicodable6, quotable6 joined, ChanServ sets mode: +v quotable6 01:18 Actualeyes joined 01:20 mempko joined 01:21 wamba left
shinobi-cl r: my @a is default(Nil); @a.append(1,2,3,Any,Nil,6); say @a.perl; my @b = @a; say @b.perl; 01:21
camelia [1, 2, 3, Any, Nil, 6]
[1, 2, 3, Any, Any, 6]
shinobi-cl Hmmm, interesting, the modifier sticks only to @a. That's to be expected anyway. 01:22
01:22 a3r0 joined 01:26 splatt9990 left 01:29 splatt9990 joined 01:38 splatt9990 left, perlbot left 01:46 splatt9990 joined 01:50 aborazmeh left, cdg joined 01:52 splatt9990 left 01:54 cdg left 02:01 perlbot joined 02:02 simcop2387 joined 02:15 shinobi-cl left 02:26 Herby_ left 02:40 cdg joined 02:45 cdg left 02:46 ilbot3 left 02:51 espadrine left 02:57 ilbot3 joined, ChanServ sets mode: +v ilbot3 03:03 mempko left 03:19 cdg joined 03:21 epony left 03:32 epony joined 03:33 epony left 03:34 epony joined 03:42 Kaiepi joined 03:43 mempko joined 03:44 jeek joined, adu joined 03:50 klapperl joined 03:57 bloatable6 left, bloatable6 joined, ChanServ sets mode: +v bloatable6 04:00 cdg left 04:01 faraco joined
faraco hmm... 04:01
I'm not sure if this is only me, but I saw that in perl6.org (recent blog posts) section there is some repetitive typos (iniside) unless that was intended as a pun.. 04:02
faraco *shrugs*
04:02 epony left
adu what? 04:03
faraco I'm seeing this - i.imgur.com/0SO7RfC.png 04:05
04:06 cdg joined
adu faraco: are you refering to "in Perl 6"? 04:09
04:11 adu left
faraco No, I meant the 'Perl 6 iniside out'. Nevermind...I thought it is a part of perl6.org system. 04:11
04:11 cdg left 04:12 epony joined 04:13 epony left 04:14 epony joined 04:15 faraco left 04:16 plicease joined 04:17 aindilis joined 04:37 Cabanossi left 04:40 Cabanossi joined 04:43 cdg joined 04:47 cdg left 04:51 TEttinger joined 05:02 lowin left 05:15 lowin joined 05:41 jeromelanteri joined 05:46 khw left 05:57 cdg joined 05:58 khisanth_ left 06:01 cdg left 06:04 kerframil joined 06:06 abraxxa left, abraxxa joined 06:07 abraxxa left 06:09 abraxxa joined 06:11 khisanth_ joined 06:17 cdg joined 06:22 cdg left 06:26 domidumont joined 06:31 domidumont left 06:32 domidumont joined 06:36 jeromelanteri left 06:45 domidumont left 06:46 musca joined 07:15 lowbro joined, lowbro left, lowbro joined 07:24 jast left 07:27 jeek left 07:28 aindilis left 07:29 wamba joined 07:33 darutoko joined 07:47 leont joined
leont I see Proc::Async has gained a merged output supply. 07:48
El_Che hi leont 07:49
leont Is that a real merged on a file descriptor level? 07:50
Of is that merged on a Supply level
El_Che I saw you forgot your fire protection on p5p :)
07:50 domidumont joined
leont I did -_- 07:52
El_Che sunblock factor 50k 07:53
07:56 FROGGS joined
timotimo leont: it's merged at moar level, but it looks like it still creates two pipes rather than passing the same pipe for both 2nd and 3rd fileno 07:57
github.com/MoarVM/MoarVM/blob/mast...ops.c#L661 07:58
leont timotimo++ 07:59
timotimo it's on the spawner to decide whether stdout/stderr are buffered or not, right? 08:01
leont That is unfortunate. Makes is unusable for my purposes.
If they're different file descriptors, then the order of the moar-merged stream isn't necessarily the same as the order that data is written in. 08:02
Buffering can happen on both sides 08:03
timotimo can you give me a short one-liner that i can proc::async.new that'll tell me if stdout and stderr are the same underlying fd? 08:08
leont Not sure I can. On the child process they look like different FDs. 08:10
08:10 Manifest0 left 08:11 aindilis joined 08:12 markong joined
leont And p6 tries hard to hide platformy things like file descriptors 08:13
timotimo not terribly hard 08:14
github.com/rakudo/rakudo/blob/mast...ync.pm#L72 08:15
leont I see
timotimo i briefly tried to handle merge by just passing the same pipe to stdout and stderr, but that didn't seem to work, causes some HLL exceptions 08:16
don't have time right now to try doing it right 08:17
also, i'd like for it to be possible to give more FDs to a spawned process than just stdin/stdout/stderr
leont Yeah that can be useful 08:27
moritz yes, very useful for IPC 08:30
timotimo can you pass sockets over FDs only on unices or also on windows? 08:32
leont You mean passing FDs over sockets?
That's a unix thing AFAIK
Windows doesn't really have FDs, but handles, which are pointers except when they're not. They're weird. 08:33
moritz TBH, FDs are also pretty weird :-)
08:35 zakharyas joined 08:36 El_Che_ joined, El_Che_ left
leont The file descriptions behind them are weird, but most of the time you don't need to think about those. 08:38
08:43 jast joined 08:50 leont left 08:59 dudebbn_ left, dudebbn_ joined 09:00 rindolf joined 09:03 zakharyas left, zakharyas joined 09:04 dogbert17 left 09:12 faraco joined
faraco camelia: 'hello'.say 09:12
09:12 scimon joined
faraco p6: 'hello'.say 09:13
camelia hello
moritz faraco: re misspellings, those blog posts are by andrew shitov
though the typo seems to be somewhere else 09:14
yes, my fault: github.com/stmuk/pl6anet.org/commi...7fe8451a5e 09:15
faraco moritz: Ah, I see.
moritz github.com/stmuk/pl6anet.org/pull/9 09:16
stmuk_: ^^ sorry for the noise
09:19 Kaiepi left 09:21 Kaiepi joined 09:37 faraco left 09:59 markong is now known as margeas
stmuk_ moritz: no worries! merged & deployed :) 10:18
moritz stmuk_: thanks 10:19
10:35 Knot0nline left, Knot0nline joined 10:41 ufobat joined 10:43 zakharyas left 10:46 TEttinger left, zakharyas joined 11:01 wamba left 11:03 zakharyas left 11:08 shinobi-cl joined
buggable New CPAN upload: App-Platform-0.2.1.tar.gz by KAJI cpan.metacpan.org/authors/id/K/KA/...2.1.tar.gz 11:12
11:21 shinobicl joined 11:22 shinobi-cl left, shinobicl left, shinobicl joined 11:30 araujo joined 11:36 pmurias joined 11:37 dakkar joined 11:39 broquaint joined 11:40 zakharyas joined, cdg joined 11:45 notbenh joined, committable6 left 11:46 committable6 joined 12:06 zakharyas left 12:23 pmurias left 12:24 vike left 12:28 abraxxa left 12:29 raschipi joined, pmurias joined, wamba joined 12:34 vike joined 12:37 shinobicl left 12:42 abraxxa joined 12:43 wamba left 12:46 pmurias left 12:52 pmurias joined 12:57 cdg left 13:13 raschipi left 13:17 jeromelanteri joined, vike left 13:19 cdg joined 13:21 vike joined 13:24 cdg left 13:35 margeas left 13:48 zakharyas joined 13:51 zakharyas left, wamba joined 13:52 zakharyas joined 13:56 lowin left 13:58 lowin joined 14:01 Knot0nline left 14:05 araujo left 14:09 cdg joined 14:13 bisectable6 left 14:14 bisectable6 joined 14:16 grumble left 14:19 grumble joined 14:21 raschipi joined 14:28 jeromelanteri left 14:32 markong joined 14:47 squashable6 left, squashable6 joined 14:55 abraxxa left 15:00 zoosha joined
masak today's autopun spotting: twitter.com/vgr/status/952442493001285632 15:16
15:28 zakharyas left, cdg left, zakharyas joined 15:35 dj_goku joined 15:36 troys joined 15:39 cdg joined 15:49 pilne left 15:57 raschipi left 16:04 dakkar left 16:10 cdg left 16:11 cdg joined 16:17 cdg left
buggable New CPAN upload: P5tie-0.0.1.tar.gz by ELIZABETH cpan.metacpan.org/authors/id/E/EL/...0.1.tar.gz 16:22
lizmat aka Perl 5 tie() for scalars, arrays and hashes 16:23
16:31 st_elmo joined 16:39 zakharyas left, lowbro left 16:41 cdg joined 16:43 khw joined 16:46 cdg left 16:53 troys is now known as troys_
Geth doc: 9dff74fe1b | (Luca Ferrari)++ | doc/Type/Version.pod6
Add crosslink to 'v (version)' to point to type Version.

Close #1732.
16:54
synopsebot Link: doc.perl6.org/type/Version
17:03 wamba left 17:05 cdg joined 17:06 cdg_ joined 17:07 cdg_ left, cdg_ joined, troys_ is now known as troys
El_Che lizmat: is P5 in the name a good idea? 17:08
lizmat what would you suggest ?
El_Che lizmat: it feels like it put limits to the implementation and the expiration date 17:09
lizmat well, that's the intent
El_Che why?
(if it's the intent, the name is right)
lizmat I would not recommend using tie() in new Perl 6 code: there are better ways of doing that 17:10
this is intended to make it easier to port stuff over from Perl 5
17:10 cdg left, domidumont left
El_Che ok, than it sounds ok 17:11
the censor approves :)
lizmat thanks the censor
El_Che connection on the train seems spotty today 17:12
lizmat doesn't notice it
TimToady note that a tie might cause lack of optimization in some cases
much like if we notice an EVAL 17:13
El_Che so, you plan to implement P5threds.pm6 and p5CGI.pm6?
lizmat P5threads no
p5CGI not sure yet
TimToady and if we can't detect that a tie is going to make optimizaiton impossible, we'll probably go ahead and do the optimization and break the tie, so to speak 17:14
El_Che I get the pratical use case, but I wonder if people are poritng their perl5 code to perl6 and if they are, I wonder if it would be straightforward because perl6 offers a lot of improvements 17:15
TimToady at least, that was the thinking a decade ago when we were deciding not to put tie into the language... :)
17:15 stmuk joined
lizmat P5tie is *not* about having code that executes in an optimal way, it is about lowering the threshold of porting Perl 5 code to Perl 6 17:16
TimToady nod 17:17
17:17 kerframil left, kerframil joined, stmuk_ left, kerframil left
lizmat dinner& 17:18
El_Che would suggest P5tieFighter to lizmat 17:22
17:23 coverable6 left, benchable6 left, coverable6 joined, benchable6 joined, ChanServ sets mode: +v benchable6
scimon Feeling happy about the progress I've made with Test::HTTP::Server this afternoon. Hopefully get some more work done on it this evening. 17:26
El_Che scimon: what does it do? 17:27
scimon It's intended to make testing things that make HTTP requests simple.
El_Che sounds useful 17:28
scimon By wrapping HTTP::Server::Async and adding some logging.
That you can check in tests.
17:28 domidumont joined
scimon I was looking at picking up WWW::Mechanize and realised I wanted something to do that. 17:28
pmurias lizmat: wouldn't a :: separated name be better? (like maybe Perl5::Tie?) 17:29
scimon Once I've got a bit more done I'll let people kick it and see how it goes.
off now.
17:29 scimon left
El_Che pmurias: I was thinking the same 17:30
or rather P5Porting:Tie
otherwise it may be confused with real Perl 5 modules, eg. used with Inline::Perl5
17:34 leont joined 17:42 darutoko left 17:47 konsolebox left 17:53 konsolebox joined
lizmat scimon: have you looked at Cro::HTTP::Client ? 18:08
El_Che: well, first of all, P5tie is about the tie() builtin, so it's not a module in Perl 5 18:09
pmurias: we haven't done the Perl5:: prefix for other modules either 18:10
in time, I guess these modules will be moved to an organisation, which you could then refer to in your -use- statement 18:11
18:13 zakharyas joined 18:15 zakharyas left, zakharyas joined 18:27 ChoHag left 18:31 geospeck joined 18:35 zakharyas left 18:40 releasable6 left, greppable6 left, reportable6 left, statisfiable6 left, releasable6 joined 18:41 nativecallable6 left, greppable6 joined, ChanServ sets mode: +v greppable6, reportable6 joined, ChanServ sets mode: +v reportable6, statisfiable6 joined, ChanServ sets mode: +v statisfiable6, nativecallable6 joined, ChanServ sets mode: +v nativecallable6 18:43 wamba joined 18:56 setty1 joined 18:57 scimon joined 19:16 shinobi-cl joined
buggable New CPAN upload: P5tie-0.0.2.tar.gz by ELIZABETH cpan.metacpan.org/authors/id/E/EL/...0.2.tar.gz 19:22
19:26 shinobicl joined 19:30 shinobi-cl left 19:34 ChoHag joined 19:37 troys is now known as troys_ 19:43 dogbert17 joined, newnick1 joined
newnick1 Hi. 19:43
How could one read command line arguments in Perl 6? 19:44
I want to treat them just as an array of tokens instead of named parameters.
timotimo try @*ARGS 19:45
19:47 geospeck left
newnick1 Could you please show me how to extract argument by index and get number of elements? I wrote sub MAIN() { say @*ARGS.elems; say @*ARGS[0]; } 19:49
but it doesn't work.
timotimo right, it won't run MAIN() if you have more than 0 arguments, because the signature wouldn't match 19:53
you can give the sub main a signature that will accept anything, like sub MAIN(*@, *%) or you could just not use MAIN at all
newnick1 And how to write signature of MAIN that would accept 0 or more args?
timotimo i've gotta take my RSI rest break, TTYL
19:53 roguelazer left 19:54 as_ joined
timotimo m: sub MAIN(*@, *%) { say "yo" }; MAIN(); MAIN(1, 2, 3); MAIN(9, 9, :foo) 19:54
camelia yo
yo
yo
yo
as_ rakudo: say UInt64.Range; 19:55
camelia -Inf^..^Inf
newnick1 Is it possible to iterate args in loop?
19:56 espadrine joined
timotimo of course, @*ARGS is just an array of string-likes 20:05
20:08 ChoHag left 20:10 domidumont left
scimon lizmat: I'm loathe to use the Cro stuff until it can install with tests. I'm 100% looking forward to it being stable :) but until then I'd like to not have to rely it. 20:14
timotimo m: say @*ARGS.perl 20:15
camelia []
timotimo hm, we don't have a way to tell camelia to give the script some arguments
so can't really demonstrate 20:16
lizmat timotimo: BEGIN @ARGS= () ??
newnick1 @timotimo, so it's not possible with Perl 6?
timotimo it definitely is possible 20:17
newnick1 Just wanted to iterate over arguments in loop.
Very simple use case.
timotimo just do "for @*ARGS -> $argument { say "$argument is an argument" }
newnick1 Is it possible to put it inside MAIN with appropriate signature? 20:18
sub main(<something>) { ...
MAIN
timotimo that's possible, too, but .. hold on, phone
20:19 ChoHag joined
jnthn scimon: Cro::HTTP, which is the bit you'd need to depend on, has done that fine for a good while 20:22
20:23 as_ left
jnthn The only remaining sometimes-fail I'm aware of is in the development tools 20:23
scimon I can always switch between them :) No offence intended jnthn, like I say it's an amazing bit of kit and I'm really looking forward to the .8 release. 20:24
jnthn None taken. :-) Just pointing out the piece you'd need is one of the stabler bits. :-) 20:25
scimon Cool :) 20:26
20:26 lichtkind joined, troys_ is now known as troys, SCHAPiE left
lichtkind is pierre viegier here? 20:28
newnick1 @timotimo, I'm sorry, could you please elaborate on example?
20:32 SCHAPiE joined 20:33 Ven`` joined 20:46 Kaiepi left 20:47 Kaiepi joined
scimon github.com/Scimon/p6-Test-HTTP-Server So here's the thing I'm working on. Idea if you point it at a folder and it's server up files in it. Also plan is to have a config.yml file that lets you define paths with special responses (like 500 errors etc). Idea is to make it very simple to setup tests. 20:48
20:50 newnick1 left
scimon But now I'm signing off to read some Malory. Night all. 20:50
20:50 scimon left, evalable6 left, evalable6 joined, ChanServ sets mode: +v evalable6 20:55 roguelazer joined, FROGGS left
lizmat and another Perl 6 Weekly hits the Net: p6weekly.wordpress.com/2018/01/15/...blue-note/ 20:56
21:06 pmurias left 21:07 pmurias joined 21:08 wamba left
leont :-) 21:16
moritz lizmat++ 21:18
21:25 wamba joined
pmurias lizmat++ # the weekly makes keeping track of rakudo community a lot easier 21:42
21:46 dct joined 21:55 rindolf left
El_Che news.ycombinator.com/item?id=15961031 <-- interesting comment in your weekly. Pretty relevant voor perl6 22:04
lizmat: kudos for the new section of the news letter 22:05
lizmat thanks :-)
gladly accepting links to wherever this is also occurring :-) 22:06
for inclusion in the P6W
El_Che I will certainly keep that in mind
lizmat thanks in advance!
El_Che are you strictly interested in perl 6 mentions or can it be widers? 22:07
lizmat it at least has to mention Perl 6
El_Che I saw a blog this week about how seclang was struggling due to intel vulnerabilities
ok
it makes sense
lizmat news.ycombinator.com/item?id=16153455 # will be in next weeks 22:08
it doesn't mention Perl 6 directly, but indirectly
that would also be ok for me
22:09 TEttinger joined
El_Che I agree so much with this (working on devops envs): "People flock to Go not only because of its performance, but because it can be easily deployed, and deployment isn't something even on Ruby's Roadmap." 22:09
timotimo pff, now we have docker everything's trivial to deploy! just ship a whole linux with it!
El_Che no it's not
timotimo i meant /s
El_Che golang on alpine is orders of magnitude easier and faster to build on docker than all other languages 22:10
I need to stick to centos for my perl 5 projects
thx $deity for docker specially for perl 5 on 6 22:11
without it it could be pretty hopeless
but even then deployment is hard
(CPAN is a lot saner than the gem environment, it must be said though) 22:12
upgrading the gems of a ruby project is hard
(you still need to manage that even with Docker)
22:12 roguelazer left 22:13 jeek joined
timotimo right, but as JS has taught us, you just keep local versions of everything with your code 22:15
El_Che yes, you do that in golang as well. But for security reason you need to update your stack
timotimo right 22:16
El_Che and in my experience things seem to blow up more often with gems than with cpan
22:24 Ven`` left
mspo gem bad 22:24
22:24 st_elmo left
timotimo i'll go into your basement and steal all your rubies and gems 22:25
El_Che you'll find only Rust
Although Julia may be there 22:26
Be careful for the Python
22:26 setty1 left, roguelazer joined, Ven`` joined 22:28 roguelazer left 22:36 alpha6 joined 22:38 Ven`` left 22:39 Ven`` joined
timotimo if anybody wants a slang idea for something really simple, why not implement ruby's ?a syntax for single character strings (?a would be "a", for example) 22:44
22:45 eliasr joined, Ven`` left, troys is now known as troys_
lizmat timotimo: how would that work with: my \a = 42; ?a 22:45
timotimo well, you wouldn't use the ? character 22:49
lizmat hehe, ok, fair enough :-)
timotimo but i'd expect longest token matching to prefer ?a as "a" 22:51
buggable New CPAN upload: P5tie-0.0.3.tar.gz by ELIZABETH cpan.metacpan.org/authors/id/E/EL/...0.3.tar.gz 22:52
lizmat apparently, if you pass a string to a precompiled module that is the name of another precompiled module, then ::() won't find it 22:53
timotimo is that a compile-time/run-time difference? 22:54
lizmat feels to me, yes
or compunit scope maybe
if the class is in the compunit of the caller, then ::() can find it 22:55
timotimo like, how do you pass it? does the passee know the string early enough?
lizmat I found this when implementing Tie::Array, a subclassable class that performs the tie() interface using a normal array
the logic in tie could not find it 22:56
I'll try to golf it down
and make an issue :-) 22:57
meanwhile, disallowing classes to be specified as a string, fixes the issue
if you have a string, then you will need to do the ::() yourself :-)
22:58 mempko left 22:59 john51 left 23:00 john51 joined, troys_ is now known as troys
Garland_g[m] Is there a way to take an 'is rw' class attribute, and run a bit of code whenever it's modified by assignment? 23:00
23:02 john51 left, Zoffix joined
Zoffix Garland_g[m]: yeah, just bind a Proxy object (or use Proxee module that's a more plished Proxy). Middle of "Coercers" section has an example of coercing to Int on assignment: github.com/zoffixznet/perl6-Proxee#synopsis 23:04
Garland_g[m]: in the future, it'll be possible to bind a Proxy to the attribute directly, instead of using `submethod TWEAK` for that purpose. 23:05
23:05 john51 joined
Zoffix huggable: Proxy 23:05
huggable Zoffix, Item container with custom storage and retrieval: docs.perl6.org/type/Proxy
Zoffix ^ that's the core version of Proxy
Garland_g[m] Thanks. 23:06
23:11 Zoffix left 23:27 pilne joined 23:30 jeek left 23:45 lowin left 23:52 espadrine left 23:54 cdg_ left