»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:, niecza:, std:, or /msg p6eval perl6: ... | irclog: irc.perl6.org/ | UTF-8 is our friend! | Rakudo Star Released!
Set by diakopter on 6 September 2010.
00:13 mfollett joined 00:31 icwiener_ left 00:36 justatheory left 00:42 Entonian left 00:43 flussence left 00:45 flussence joined 00:50 QinGW joined 00:52 silug joined 00:55 QinGW1 joined 00:56 QinGW2 joined 00:57 QinGW left 01:00 QinGW1 left 01:02 dju left, stkowski left 01:03 dju joined 01:07 mfollett left 01:08 rvrgs- joined 01:09 rvrgs left 01:14 mfollett joined 01:15 Schwern joined 01:28 kulp left 01:31 nadim_ left 01:34 breinbaa1 joined, moritz__ joined, patch_ joined, PZt left, Util_ joined, BooK_ joined 01:35 PZt joined 01:38 spacebat_ joined, mfollett left, thepler__ joined, moritz_ left, Juerd left, LionMadeOfLions left, huf left, felipe left, Gothmog_ left, breinbaas left, rhr left, eternaleye left, cognominal left, constant left, BooK left, thepler_ left, Util left, patch left, Infinoid left, spacebat left, eternaleye_ joined, eternaleye_ left, eternaleye_ joined, huf_ joined, Schwern left, flussence left, meppl left, pmichaud left, zb left, [Sec] left, chturne left 01:39 sukria left, simcop2387 left, Woody2143 left, jrockway left, jlaire left, phenny left, rjbs left, bobkare left, ingy left, grew left, Exodist left, c9s left, Grrrr left, krunen left, Infinoid joined, cognominal joined, eternaleye_ is now known as eternaleye, tomaw left, LionMadeOfLions joined, standz left 01:40 meteorjay left, rhr joined 01:41 tomaw joined, Schwern joined, flussence joined, meppl joined, pmichaud joined, zb joined, [Sec] joined, chturne joined, sukria joined, simcop2387 joined, Woody2143 joined, jrockway joined, jlaire joined, phenny joined, rjbs joined, bobkare joined, ingy joined, grew joined, Exodist joined, c9s joined, Grrrr joined, krunen joined, zelazny.freenode.net sets mode: +v phenny 01:42 Gothmog_ joined, risou joined 01:43 constant joined, constant left, constant joined 01:45 mfollett joined 01:47 lucas_ joined 01:48 mfollett left 02:05 whiteknight left 02:31 skids joined 02:34 envi joined, Juerd joined, risou left 02:37 lucas_ left
colomon github.com/colomon/Math-Prime 02:38
deadly slow so far. :(
02:40 risou joined
dukeleto colomon: have you seen Math::Primality on CPAN ? It might give you some ideas. 02:44
colomon dukeleto++ (I hadn't) 02:46
dang this thing is slow.
afk
02:50 Italian_Plumber left 02:58 nymacro joined 03:04 Italian_Plumber joined, Italian_Plumber left, mberends left 03:14 mfollett joined, mfollett left
colomon half an hour later, it's still running the third test I wrote for it (calculating the first 1000 primes). 03:23
so something better is clearly needed.
03:24 meppel joined 03:25 meppl left 03:34 [particle]1 joined, Alias joined 03:35 skids left 03:36 [particle] left, meppel left 03:38 meppl joined 03:51 risou left 04:04 icwiener joined
dukeleto colomon: there are some faster algorithms implemented in Math::Primality, but some are not fully implemented 04:05
04:05 icwiener left 04:10 orafu left
plobsing rakudo: my @odds := 3, 5 ... *; my @primes := 2, @odds.grep(-> $x { for @z { when * > sqrt($x) { return 1 } when $x %% * { return 0 } } }); .say for @primes[^10] 04:14
p6eval rakudo d35769: OUTPUT«===SORRY!===␤too few positional arguments: 2 passed, 3 (or more) expected␤»
04:15 justatheory joined
plobsing rakudo: my @odds := 3, 5 ... *; my @primes := 2, @odds.grep(-> $x { for @primes { when * > sqrt($x) { return 1 } when $x %% * { return 0 } } }); .say for @primes[^10] 04:16
p6eval rakudo d35769: OUTPUT«2␤3␤5␤7␤11␤13␤17␤19␤23␤29␤» 04:17
04:19 envi left 04:53 dalek left, dalek joined, ChanServ sets mode: +v dalek 04:54 constant left 04:55 constant joined, constant left, constant joined 05:02 Exodist left, masonkramer left, simcop2387 left 05:03 exodist joined, Lorn left 05:04 Lorn joined 05:06 sftp joined 05:09 masonkramer joined 05:10 sftp left 05:11 sftp joined 05:18 simcop2387 joined 05:19 kjeldahl joined 05:20 tylercurtis left, pythonian4000 is now known as pythonian4000afk 05:21 xabbu42 joined, xabbu42 left, xabbu42 joined 05:30 kjeldahl left 05:33 ggoebel left 05:34 _kaare joined 05:35 justatheory left 05:49 nadim_ joined 05:56 mberends joined
sorear good * #perl6 06:07
06:17 justatheory joined 06:21 wtw joined 06:25 mberends left 06:26 simcop2387 left 06:27 am0c^ joined 06:31 pythonian4000afk is now known as pythonian4000 06:32 justatheory left 06:36 masonkramer left 06:37 jaldhar left 06:38 jaldhar joined 06:48 standz joined, masak joined
masak good morning, #perl6! 06:49
phenny masak: 19 Oct 16:49Z <moritz_> tell masak I'm sure you've seen it before -- if not, look at ds9a.nl/amazing-dna/
masak moritz__: found it yesterday too :)
it's very detailed, and I haven't more than skimmed it yet. but the analogy as such is very tempting (for programmers), and the author seems pretty aware of where it breaks down. 06:50
06:53 simcop2387 joined 07:03 baux joined, baux left 07:04 baux joined
sorear masak: hello! 07:06
07:09 am0c^ left, rgrau joined
masak hi sorear. 07:09
when a reddit thread looks like this, I know my topic was probably a bit too narrow for the crowds: www.reddit.com/r/programming/commen...of_perl_6/ 07:11
:)
sorear masak: does strangely consistent do comments? 07:14
masak no, not yet.
I've planned to add a static page about it not doing comments. I'll add that now.
the roadmap is (1) import all old comments from use.perl.org; (2) make it possible to make new comments. 07:16
07:16 MayDaniel joined
sorear needs to re-read S05 on alias rules 07:17
there are too many of them. or they haven't clicked strangely consistent for me. or both.
masak having implemented them once, I'd say they're pretty sane. 07:18
they're not always what the implementor expects, though :)
07:21 am0c joined
sorear is shaving yaks to make / (.) / work 07:22
07:22 MayDaniel left 07:23 envi joined
sorear wonders stuff like what <foo=[x]> does 07:23
masak it binds $<foo> to the contents of the group. doesn't matter if it's capturing or not.
oh wait. that's an assertion. 07:24
hm.
in that case, I have no clue. I'd have to go check S05 myself. 07:25
07:39 xabbu42 left 07:40 xabbu42 joined, xabbu42 left 07:59 simcop2387 left 08:06 felipe joined 08:08 jaldhar left
masak luqui++ lukepalmer.wordpress.com/2010/10/18/idewtf/ 08:08
08:08 kensanata joined, jaldhar joined 08:10 jaldhar left, jaldhar joined
masak sorear: now the "no comments" text at the header of each blog post links to strangelyconsistent.org/no-comments 08:15
08:16 moritz__ is now known as moritz_ 08:19 simcop2387 joined 08:21 timbunce joined
jnthn morning, #perl6 08:21
mathw morning jnthn 08:22
sorear hey jnthn 08:24
08:34 [particle] joined
moritz_ good morning 08:34
08:35 [particle]1 left 08:36 C joined 08:37 C is now known as Guest68174 08:38 [particle]1 joined
Guest68174 Hello, I have few questions regarding the perl6 language. 08:39
moritz_ hi
go right ahead
08:40 [particle] left
sorear needs to do something awesome to race ahead of jnthn 08:40
Guest68174 mortiz: what are the main areas where this language is expected to been mostly used (for example we like ruby because of rails, Perl was loved for web implementations too in past)
sorear We don't. 08:41
Perl 6 is designed to handle unexpected applications
moritz_ Guest68174: that's a bit like asking "what are the main areas where screwdrivers are used?"
or maybe "where are computers used?"
sorear the overriding principle is "how do we make a language that will be relevant in 20 years"?
08:42 dakkar joined
sorear Perl 5 has lasted the last 17 years because of dynamism, CPAN, and a principle of making simple things simple 08:43
Guest68174 mortiz_: I understand you, but as you know perl 5 is now getting less and less used despite it is considered a genaral purpose programming language.. but other programming languages like ruby and python are taking the lead nowadays.. so what will perl6 provide to be in the lead?
moritz_ Guest68174: Citation needed (for Perl being used less) 08:44
Guest68174: anyway, there's a lot that Perl 6 offers 08:45
from grammars over lazy list to hygienic macros
dalek kudo: eef929e | moritz++ | build/PARROT_REVISION:
bump PARROT_REVISION to 2.9.1 release
am0c (what the flame)
moritz_ Guest68174: www.reddit.com/r/programming/commen...ng/c0ut9um has a list of nice features 08:46
jnthn sorear: I'd say Niecza is rather ahead of NQP.NET. :-)
am0c but I can understand Guest68174, because at the most first time Larry made Perl(Pearl) with purpose. 08:47
sorear Is it still an inferiority complex if you created it for motivational purposes? 08:49
Guest68174 mortiz_: thank you for the links I will check them now :) One feature I am sure of now is having a "very friendly community" :)
moritz_ Guest68174: btw take a second look at my name, the i comes before the t :-) 08:50
Guest68174 moritz_: oh I am so sorry for that :) it is just that the one I used is more common where I live :) 08:51
moritz_ no problem 08:52
jnthn I would recommend tab completion but it's dangerous in the m-space. ;-) 08:53
Guest68174 yeah.. 08:54
sorear wonders if we have anyone else from Guest68174's area 08:56
Guest68174 sorear: how does that relate to anything? 08:59
sorear I just like a geographically diverse community 09:00
jnthn++ alone has most of Europe covered ;)
jnthn Hey, my beer belly isn't *that* big. :P 09:01
There's plenty of folks from Europe here, anyways. :-) I keep running into them at workshops. :-) 09:04
jnthn grumbles about TFS being a sad excuse for a version control system 09:05
sorear wonders if he can count nothingmuch and rindolf
moritz_ that's two, if you can't :-) 09:06
09:06 mavrc joined
am0c Is cpan6 being made or designed? 09:10
moritz_ currently it seems we're stuck in both phases 09:11
09:11 Guest68174 left, xabbu42 joined
BinGOs its a game in two halves. 09:11
09:12 _twitch joined
masak has a feeling that cpan6 is need-driven, and that the need isn't all there yet 09:13
moritz_ right 09:14
sorear right now it's more apathy-driven
masak we have modules.perl6.org, and it works for now. attempts to dream ahead or hook up with CPAN are met with resistance, not from devs/users, but from reality itself in some way.
sorear: if you're willing to equate "resources spread thin" and "apathy", then sure. 09:15
am0c hm I see 09:16
09:17 [particle] joined
BinGOs cpan6 implies toolchain6 09:17
09:18 [particle]1 left, zostay left
masak mst on Moose/p6-oo: twitter.com/shadowcat_mst/status/27890522144 09:18
09:19 zostay joined
jnthn lol 09:20
I find mst increasingly irritating rather than helpful.
sorear I agree with mst, fwiw
moritz_ it's also curious that mst now uses "camelia" for Perl 6, but still uses "perl" for Perl 5
jnthn Yes. I don't like that. 09:21
moritz_ when I talked to him at YAPC::EU, he seemed to be have other plans
masak now that you mention it, neither do I.
09:21 simcop2387 left
masak sorear: oh! by the way, I recently learned that Rakudo *does* have an attribute MOP. 09:21
sorear moritz_: I think that's just twitter length limits talking 09:22
on IRC it's camelia perl and raptor perl
BinGOs but Perl5 is people! 09:23
moritz_ sorear: "raptor" is not much longer than "perl", so I don't accept that
09:23 silug left
masak I don't like the label "Camelia Perl" at all. maybe I'll get used to it, I dunno. 09:23
to me the language remains "Perl 6". it has a bit of negative PR attached to it, but not as much as some would perhaps think. it still represents hope and change for many people. 09:24
mathw Perl 6 is even shorter, so...
moritz_ well, camelia is a relatively new invention, compared to Perl 6
09:25 simcop2387 joined, zostay left
masak in some ways I think it's a mixing-together of levels to be calling Perl 6 "Camelia". it's a bit like calling Perl 5 "that camel language" -- not entierly wrong, but not very coherent, either. 09:26
mathw I find it comes across as erogatory, which may be the intention. I don't think mst really wants to call Perl 6 anything that might make people think it's Perl.
masak I'm still willing to give mst the benefit of the doubt. 09:27
mathw Of course, I'm biased.
sorear I think mst is doing a remarkably good job of coming to terms with his new identity as a Perl *5* guts hacker
masak aye. 09:28
I'd rather have 20 msts than 1 ank.
09:28 [particle]1 joined 09:29 zostay joined, [particle] left
sorear um, 20 msts would make #p5p implode 09:30
masak :)
09:30 jfried joined 09:31 QinGW2 left, am0c^ joined 09:32 QinGW joined
masak I've enjoyed talking to Matt Trout the person as well as being barked at by mst the persona. in some sense, mst is a singleton object, and having even two in the same IRC channel would be redundant. 09:34
09:35 am0c left
masak see also www.shadowcat.co.uk/blog/matt-s-tro...a-bastard/ 09:36
risou++ # "Welcome to Perl 6! Is Rakudo Star useful?" www.youtube.com/watch?v=95H7zvewBS8 09:38
szbalint I am convinced that there are 20 msts somewhere in a basement, but only one of them is ever present in public. The rest just hacks away on cool stuff.
masak :)
sorear right, if there were ever 2 msts in public at once, it would cause severe damage to reality 09:39
masak hm, the "usable Perl 6 features" slide seems to be put together from ChangeLog entries. 09:41
09:42 flatwhatson_ left, flatwhatson_ joined
moritz_ or maybe from rakudo.org/status 09:43
masak that might be it.
nope, it can't be. 09:44
at least not exclusively.
my eye picked out "Nil is now undefined" which sounds more like ChangeLog than rakudo.org/status
moritz_ right 09:45
masak I like the talk so far. he's very honest about what's there and what's not.
09:45 mavrc left
moritz_ doesn't understand most of it 09:45
masak I'm looking at it with the sound turned off, fwiw.
that seems to work fine. 09:46
09:46 mikehh left 09:47 ggoebel joined, florz left
masak here's the second part: www.youtube.com/watch?v=87Y9BP1qywQ 09:47
09:47 florz joined 09:48 aloha left, mavrc joined
moritz_ is always surprised when a non-#perl6 regular talks about Perl 6 09:50
colomon ack, my "1000th prime" test is still running, seven hours after I started it. 09:51
mathw not everyone is on IRC...
masak moritz_: risou is very active through Twitter, and I tweet with him sometimes. 09:52
mathw colomon: are you sure the algorithm will terminate?
colomon mathw: it worked okay for the first 60 primes.
and barring some weird programming error, it should stop every time a prime is found... 09:53
masak "Perl 5.14.0 will be released earlier than implementation of Perl 6 that has all features". nuh, yah. :)
I'm not sure there's even an end in sight, let alone soon.
moritz_ I'm sure that perl 6.0 will be released before Perl 5 is feature complete :-)
masak risou discourages "use for the business". I strongly suspect he means "production", which is orthogonal to "business". 09:54
but clearly, his heart is in the right place. his presentation covers a lot of things that I haven't seen others cover with the same clarity depth. 09:55
ss/clarity depth/clarity and depth/
moritz_ since I haven't seen a good definition of "production" yet, maybe "business" is clearer
masak "Let's use Rakudo Star positively!" \o/ 09:56
moritz_: to me, "production" just means that something is used as a product, something that can be consumed by people. hence, my new blog is an example of Rakudo being used in production. 09:57
TimToady++ is on there too: www.youtube.com/watch?v=KJUVP2Z13Yo 09:59
is that another Rakudo-based presentation I see? 10:00
masak is not sure
10:03 QinGW left
masak oh, and also, risou joined #perl6 as late as yesterday. admittedly not a regular, though. 10:03
dalek ecza/master: 9b64deb | sorear++ | v6/ (2 files):
Reimagine cursor_herelang as mixing in a role
10:04
ecza/master: 4c83f15 | sorear++ | / (7 files):
Implement $<foo> = [bar]

This required a bit of restructuring to support synthetic subrules, which might not always trap captures or cut operators.
10:05 timbunce left
masak Juerd: ping 10:05
10:06 wamba joined
masak phenny: tell Juerd tried to restart november on feather, got this: gist.github.com/636134 -- any suggestions? 10:06
phenny masak: I'll pass that on when Juerd is around.
Juerd masak: apache2 10:07
phenny Juerd: 10:06Z <masak> tell Juerd tried to restart november on feather, got this: gist.github.com/636134 -- any suggestions?
Juerd This tells me that you should learn to tab complete everything :)
You'd have discovered it already
masak Juerd: please update the info on feather.perl6.nl/
Juerd Can you do it?
masak Juerd: that's why I didn't tab-complete, I copy-pasted. 10:08
Juerd Aha
Please test if the instructions work with apache2 without modification
masak ok.
it doesn't.
apache2: Syntax error on line 20 of /home/masak/apache/httpd.conf: Cannot load /usr/lib/apache/1.3/mod_log_config.so into server: /usr/lib/apache/1.3/mod_log_config.so: undefined symbol: ap_month_snames 10:09
moritz_ masak: docs/feather/index.html in the mu repo
masak conf file probably needs updating to apache2.
oh! the paths are all wrong now, of course. 10:10
Juerd It's interesting that apparently nobody has tried this for years
masak I rebooted November successfully as late as a month ago.
moritz_ Juerd: I think we had apache 1.3 and 2.2 installed in parallel for a quite long time
Juerd Yes 10:11
masak at that time, apache (no 2) existed.
Juerd A month ago?
masak something like that.
I need to start November occasionally.
Juerd That's slightly unlikely since Debian hasn't supported apache 1.3 for a few years now, and there have been dist-upgrades
masak because the server dips, etc.
Juerd OTOH you won't be lying about this. I'm confused.
sorear dips? 10:12
Juerd apt-get vehemently tries to remove all apache1-stuff, and has for a long time
masak sorear: goes down and comes back up again.
Juerd: this is the last documented instance: irclog.perlgeek.de/perl6/2010-08-22#i_2734235 10:13
two months ago.
Juerd Very strange
Maybe someone had apache1 compiled manually 10:14
I removed some old user homedirs with the migration
But that wouldn't remove symlinks of course
afk 10:15
moritz_ there's no dangling /usr/sbin/apache symlink
dalek ecza/master: ce8fb09 | sorear++ | / (3 files):
Implement numbered (captures)
masak moritz_: maybe the /usr/sbin directory wasn't migrated.
*lol* # irclog.perlgeek.de/perl6/2010-10-19#i_2925736 10:16
sorear out 10:17
moritz_ huh 10:19
in the second part of that video, TimToady talks about parallelizing infix X** 10:20
isn't that lazy?
colomon yes
dalek ecza/master: f9817db | sorear++ | / (3 files):
Implement $*GOAL
10:21 ggoebel left 10:24 aloha joined
colomon just tweaked the prime code and made it 12x faster for the first 100 primes case. 10:29
moritz_ is the code public somewhere?
colomon github.com/colomon/Math-Prime/blob/...h/Prime.pm 10:30
but that's the slow version
10:30 lucas_ joined 10:31 pythonian4000 is now known as pythonian4000afk, pythonian4000afk is now known as pythonian4000 10:32 am0c^ left 10:33 pythonian4000 is now known as pythonian4000afk
masak pythonian4000afk: make up your mind :) 10:33
colomon 1000th prime test still slow 10:41
10:42 Italian_Plumber joined
mathw colomon: these things have a habit of taking ages :( 10:42
colomon I've pushed the faster version (even though the third test hasn't finished yet). 10:44
10:45 Italian_Plumber left 10:47 arnsholt joined
moritz_ colomon: maybe better: my @primes := 2, 3, &next-prime ... *; sub primes() is export(:DEFAULT) { @primes } 10:50
colomon moritz_++ # I was trying to figure out how to do something like that. 10:51
I forget I can use the scoping rules to my advantage sometimes.
won't actually help for my current issue, but it would be a good deal in general.
10:54 Trashlord joined
moritz_ colomon: nopaste.snit.ch/24621 10:55
colomon does it work for 2? 10:56
moritz_++
moritz_ yes
10:58 ggoebel joined
moritz_ colomon: want a patch including a test? 10:59
colomon already added the patch (not commited)
paste the tests?
moritz_ +is (1..20).grep(&is-prime).join(', '),
+ '2, 3, 5, 7, 11, 13, 17, 19',
+ 'is-prime 1..20';
colomon (I started on them)
10:59 Italian_Plumber joined
colomon dude, elegant! 10:59
mathw falls in love with Perl 6 again 11:00
That's so... Haskelly 11:01
colomon hmmm, getting errors all over. :(
oh 11:02
moritz_ works here
colomon it's not your code, it's mine 11:03
ETOOMANYCHANGESATONCE
11:04 nymacro left
colomon it was my attempt to do the my @primes := thing that broke everything. 11:04
11:08 ggoebel left 11:09 ggoebel joined, ggoebel left
moritz_ doesn't seem to work out that easily 11:13
jnthn I eated an awesome cheezburger for lunch \o/
11:17 xinming left 11:19 xinming joined 11:31 allbery_b left 11:33 Italian_Plumber left, Italian_Plumber joined, allbery_b joined
colomon moritz_: did you try the @primes mod as well? 11:37
it seems like @primes is right, but
sub primes() is export(:DEFAULT) { @primes; }
is not.
jnthn is export(:DEFAULT) is the smae as is export 11:38
Or at least, should be.
colomon I think I was just copying what's in the spectests for is export.
moritz_ colomon: maybe lazy lists don't like it when they are reified in several different places (through the return value binding)? 11:39
11:42 mavrc left
moritz_ afk 11:45
colomon very confused here 11:47
11:48 allbery_b left
colomon everything works fine in the .pm file, but gets weird in the test file. 11:49
11:49 AndroUser joined
colomon ooooo! 11:51
11:51 aloha left
colomon it's primes.munch which is screwing things up. 11:51
it's actually munching the original list
seems unacceptable in the long run, but easy to fix in the short run 11:52
takadonet morning all 11:54
jnthn o/ takadonet 11:55
colomon \o 11:56
11:58 lucas_ left, mavrc joined 12:01 jjore left
masak \o takadonet 12:02
12:04 jjore joined
masak someone from .jp blogs about Perl 6: d.hatena.ne.jp/nishiohirokazu/20101...1287574907 12:04
12:04 aloha joined
masak that 'does A;' syntax -- is it still allowed by spec? 12:04
rakudo: role A {}; class Foo { does A; }; say "alive"
p6eval rakudo d35769: OUTPUT«alive␤» 12:05
masak huh.
12:05 allbery_b joined 12:07 wallberg joined
jnthn masak: It got changed I think. 12:08
masak colomon: (re [perl #78454]) in Perl 6, always close your filehandles manually.
jnthn: 'also does', right? 12:09
jnthn masak: But Rakudo did ne catch up yet.
Right.
colomon masak: is that a language requirement or a rakudo requirement?
masak: either way it's broken enough I'd have to seriously rethink ever using perl 6 for a major project
wallberg hi all! I just checked the release notes for the new Parrot 2.90. What does "Parrot and Rakudo Perl 6 now have access to the GCC Compile Farm" mean? What can be achieved with that? 12:10
masak colomon: automatic closing of filehandles hinges on reference counting. Perl 6, unlike Perl 5, uses a "real GC", not reference counting. thus there is no guarantee that as a variable goes out of scope, the object it contains is immediately GC'd. 12:12
jnthn Aye, but you'd expect it to get collected at program end, I guess. 12:13
masak wallberg: good question. I'd like to know, too. I've completely missed that.
jnthn: I've learnt not to expect that either.
colomon masak: yes, but that's completely different from saying it's okay if it's NEVER GC'd
jnthn masak: You can't rely on it in current Rakudo.
masak jnthn: ok.
colomon: that's your answer, then.
wallberg masak: ok.
masak I agree that it definitely should be GC'd eventually.
colomon masak: but the question is, is that a rakudo bug or a perl 6 design issue 12:14
?
jnthn masak: Though it's not insane to say that it should try GC everything left at exit.
12:14 masonkramer joined
masak jnthn: right. 12:14
colomon: sounds from what jnthn says that it's purely a Rakudo bug. 12:15
colomon: (probably with Parrot roots)
jnthn To clarify
It's not a bug nor a design issue that it isn't closed at scope exit. 12:16
It is a bug imo that it isn't closed/flushed at program exit though, and if the spec doesn't have a note to say that this should happen, we may want to consider adding one so it's clearly laid down.
masak +1 12:17
colomon +1
jnthn fwiw, I tracked down a very, very similar issue to this here at $dayjob recently
masak a whole little section on the expectations on the GC (and differences from Perl 5) would be nice.
jnthn But in C#, not Perl 6.
It's easy to get such mess.
colomon personally, I think this is one area where non-garbage-collected C++ really has it much better than things like C# 12:18
AndroUser good morning..
jnthn aye, it's a trade-off.
Though I know which way I usually prefer to trade. :-)
masak AndroUser: morning! 12:19
flussence masak, wallberg: a compile farm is usually just a bunch of homogeneous machines/VMs to ensure things work the same across them all
(probably meant heterogeneous there, dunno) 12:20
masak flussence: I'm with you so far. was more wondering about this particular one; when/how/why it happened, and why it's noteworthy.
(not saying it's not, just wondering why)
AndroUser i have a question i am new in perl but. is posible to make web application with perl?? 12:21
wallberg flussence: so, like easy compiling for ARM on Intel and such?
masak AndroUser: yes, but (unless you are asking about Perl 6 specifically), you're in the wrong channel.
AndroUser: try irc.perl.org, and something like #catalyst
AndroUser yes i am talking about perl6
masak oh, you are? excellent! 12:22
flussence wallberg: pretty much, it's just to prevent releasing something that turns out to be broken
masak AndroUser: I have a blog written in Perl 6: strangelyconsistent.org/
flussence mozilla has a similar thing for example
masak AndroUser: so yes, it's possible.
12:22 tylercurtis joined, tylercurtis left
AndroUser i saw a youtube tutorial this morning i i like the syntax 12:22
masak AndroUser: we like it too :)
wallberg masak: perhaps a silly question, but last time I tried Perl 6 in Rakuda there were massive memory leaks in arrays and considerable slowness every here and there. how have things changed over the last six months? do you think it is possible to start doing "capable" and "performant" bioinformatics tools in Perl 6 yet? 12:23
colomon wallberg: nope
masak AndroUser: might be a good idea to start with something simpler than a web application, though. mostly because of the state of Perl 6; not all pieces are in place yet. kind of a construction site.
flussence it's getting better
masak wallberg: "Rakudo". 12:24
colomon wallberg: things are a bit better, but it's probably still a couple of orders of magnitude too slow for bioinformatics
masak wallberg: probably still early. what the others are saying.
12:24 MayDaniel joined
flussence wallberg: rakudo is about as optimised as JS in Firefox 2.0, as a reference point 12:25
masak wallberg: I find today's Rakudo has more stability than last year's, though. it's more difficult to sink it with some bus error or other memory corruption.
AndroUser i am in the process to open a software companie
masak wallberg: but it's still a slow memory hog.
colomon moritz_: I just added you to the Math-Prime committers. ;)
takadonet colomon: It's really still too slow for bioinformatics. It needs lazy grammar before it can be really used 12:26
colomon is a bit sad that his Rakudo prime code is actually slower on his MacBook Pro than his old BASIC code was on his Commodore 64 12:27
AndroUser masak we want to develop a school appplication you think perl6 is ready for that??
kensanata AndroUser: I understand the comments to mean "not ready for productive use"
wallberg masak: and others, what is the general recommendation for developing Perl 5 tools that are easily ported further down the line and that remains as close as possible to the syntax and style of Perl 6? Is it Moose or do we have other options that are even closer to P6? 12:29
masak AndroUser: ...probably not. but the only way to know for sure is to look at what's there.
wallberg: Moose is a really good start. Modern Perl 5 in general is a really good start. 12:30
flussence wallberg: Moose is a good idea in general, whether or not it ends up ported to perl6.
masak +1 12:31
though I wouldn't use Moose unless I needed the OO.
12:31 fod joined 12:32 fod left 12:33 fod joined 12:34 fod left, fod joined
wallberg ok, yeah I tried it a bit for some small tools, but it is just that I felt a bit overwhelmed by all the sugar that could be applied everywhere so that in the end, I did not really grokk what the core of Moose was and how portable my code would be across servers. also, while I am sure the developers did a great job, I felt I lost some control over how my objects were built and how much RAM they used. I would really like Moose to finds its way into the 12:34
standard distribution of Perl, but I am sure others disagree.
12:36 fod left, fod joined
wallberg in any case, there is no such thing as a stable and maintained "Perl 6 syntax module" for Perl 5 on CPAN, right? 12:36
12:37 xinming left 12:38 fod left 12:39 fod joined 12:40 fod left, MayDaniel left, fod joined 12:41 wallberg left 12:42 fod left, fod joined 12:43 am0c joined 12:44 wallberg joined
masak wallberg: not sure exactly what you mean by that. 12:44
Perl 6 is not just syntax. there's only a certain extent to which Perl 5 could be made to look like Perl 6. 12:45
there are modules on CPAN for specific things, though.
12:45 fod left 12:46 fod joined, plainhao joined
wallberg masak: I am not sure what I mean either :-) apart from using the most portable coding style when starting new Perl 5 projects. 12:48
12:48 molaf joined
masak to me, it comes down to a small set of practices. 12:48
12:49 fod left, fod joined
wallberg masak: could that perhaps be the topic of a few future blog posts from a Perl 6 master as yourself? ;-) 12:49
masak and I still occasionally get bitten by slight differences, such as the (lack of) comma after the block after `map` in Perl 5, or the need for parentheses after `if`/`while`/`for`.
wallberg: I'm hardly a master. but I'll happily write such a post.
12:52 tzhs joined
wallberg masak: great! I found MooseX::Declare to use an OO style pretty similar to Perl 6. 12:52
12:52 fod left 12:53 fod joined, zby_home_ joined, ggoebel joined 12:54 fod left, fod joined
masak wallberg: yes, I was wondering whether to suggest that one. 12:54
12:56 fod left 12:57 fod joined
masak I'd also recommend MooseX::Method::Signatures for the same reason. 12:57
12:59 fod left, fod joined
wallberg masak: ahh. Yeah, that one looks great. The problem is that these modules are not very "discoverable" for many of us schmucks who do not spend most of our time programming, so some hints like these are great to prepare for and ease the transition into Perl 6 when the time comes. 13:00
sort of a "Poor mans Perl 6" 13:01
13:02 fod left, fod joined 13:03 fod left
masak here on #perl6, we already have a "Poor man's Perl 6" :) so the need for it is not as great, I would think. 13:04
wallberg: myself, I only discovered modules such as those by talking to Perl 5 people. 13:05
13:05 Italian_Plumber left
masak speaking of which, we really should form that Uppsala.pm group, to inform each other of things like these :) 13:06
wallberg yeah, were is that group? ;-)
masak so far, only in our heads.
mathw mumbles about people who are lucky enough to have Perl > 5.005 available at work
flussence oof, and I thought being stuck with 5.8 was painful. 13:07
mathw Well we've got some 5.6 and 5.8
but the lowest common denominator is 5.005
13:07 wamba left
wallberg oh man, is that machine running DOS or something? 13:08
mathw We don't do much Perl, but when I do some Perl I'd like to, you know, do it properly
wallberg: Solaris 8
wallberg ahh, yeah on those SUN panzer machines that refuse to die, right? 13:09
takadonet Lowest is 5.8.8 here!
stupid centos 5
flussence
.oO( that's the problem with machines built to keep running... you can't get rid of them )
13:10
wallberg or sell to the same customer twice ;-) 13:11
takadonet well I might start using App::perlbrew and is that as my base for programs
having perl 5.14 would be sweet
mathw we are ditching Solaris 8 13:12
the company find it uncomfortble to use without Sun's support :)
the Solaris 10 machines seem to have perl 5.8 on them 13:13
so the situation will be better once the migration's complete
13:13 Italian_Plumber joined
BinGOs still Solaris 10 comes with a dog-old version of Perl5 13:13
jnthn Clearly 5.10 and 5.12 aren't dated enough to be Enterprise Ready yet. ;-) 13:14
BinGOs heh 13:15
13:15 icwiener joined
mathw I think if we did any serious development in Perl I could convince people to get 5.12 13:15
or at least 5.10
just keep saying "switch statement"
flussence or "say"
mathw I don't think that's as important
When I do Perl training, they're always moaning about switch 13:16
flussence
.oO( verbally ending every sentence with "backslash n"... )
mathw I had to put in a slide about given/when and how they can't use it yet
BinGOs ~~ operators
masak I definitely miss 'say' more than given/when on older Perls. 13:17
flussence oh, and (?<name>...) is awesome. Too bad I can't use it where I need regex the most...
long-winded regex at that
masak flussence: I'll go so far as agreeing that the semantics are awesome :) 13:18
Perl 6 regexes/grammars (if you ask me) make up one of the more solid arguments why Perl 6 is *better* than (and not just different from) Perl 5. 13:20
takadonet masak: for sure. Writing grammar for bioinformatics file format is really easy
mathw say is a nice convenience when you're used to it, but it's not something that sells a Perl upgrade to people IMO 13:21
13:21 Patterner left
wallberg masak: yeah, I'd love to have those for parsing all the stupid bioinformatics formats around that seems to have be produced by minions of the Dark Lord himself 13:21
masak mathw: that's probably it. I'm hooked on 'say' already.
flussence somewhat related, I think it'd be neat if I could give unpack() something that looks visually like a C struct, and get a nice hash back (and vice-versa)
takadonet masak: problem is that I need lazy loading so I can 'quickly' search for a particular key/value pair then read the whole freaking thing
masak flussence: I really like the idea, and I think we should think up an API for it. 13:22
takadonet wallberg: do you work with bioinformatics file formats?
wallberg yeah
flussence I've actually written something like it for $dayjob, but arrayrefs of arrayrefs are horrible to work with. It'd look much nicer in p6. 13:23
(I might try making something like it later today, actually)
wallberg takadonet: parsing stuff like ace and that crappy fastq format that make you want to pull your hair
13:23 agentzh joined
jnthn masak, flussence: S09 has compact structs which may do that kinda thing. 13:24
takadonet wallberg: Ouch. So far I have a fasta and hmmer format done in grammars 13:25
wallberg takadonet: well, I actually gave up on doing it in grammars in Perl 6 and did it in Perl 5. 13:26
masak jnthn: aye, but it seems there is some (as yet unspec'd/unexplored) connection between pack/unpack and the compact structs of S09.
wallberg masak: one thing that would also be useful for the "blogs" would be a recommendation for IO formats that are likely to be implemented early on in Perl 6. JSON? YAML? XML?
jnthn masak: aye
takadonet wallberg: Which format?
masak wallberg: there's already JSON.
wallberg masak: aha. I did not know that. thats good to hear. 13:27
flussence jnthn: looking at that, it would need to know at least which order the fields are in. it's 90% of what I was looking for though!
masak wallberg: people seem to be wanting to write XML parsers almost as an initiation rite to grammars. don't know if we have any really stable ones, though -- or really if it should be done in pure Perl 6 at all.
wallberg: modules.perl6.org
colomon masak++ 13:28
masak wallberg: YAML is possible nowadays, but no-one has bitten down and actually done it. ingy is kinda sorta on the way, but he seems to be working breadth-first in 5 different languages at the same time.
flussence of course, we could just cheat and hook into libyaml :) 13:29
colomon no, wait. where's the official module list kept these days? I need to add Math::Prime.
masak flussence: I'd like that.
colomon: github.com/perl6/ecosystem
flussence I'm surprised that's not been done already
masak flussence: well volunteered!
flussence
.oO( I'm giving myself a huge list of Things To Do In Perl 6 now... )
13:30
:D
masak flussence: I'd certainly use it.
without a doubt.
takadonet same
masak flussence: you might want to look at github.com/jnthn/zavolaj
that might be the easiest way to hook into lib-anything right now. 13:31
wallberg masak: thanks. That yaml effort would buy a lot of beer in Uppsala if finalized. That is the perfect format for non-programming biologists to write input files in.
(IMHO)
13:31 Psyche^ joined, Psyche^ is now known as Patterner
masak nod 13:31
maybe I should help flussence, then :)
13:32 _kaare left
pmichaud good morning, #perl6 13:32
takadonet pmichaud: morning
masak pmichaud: mroing! how's $!cold?
colomon pmichaud: o/ 13:33
pmichaud $!cold is gone, replaced with $!worse :-(
masak :(
13:36 am0c_ joined
dalek osystem: 2daf67e | colomon++ | projects.list:
Switch ABC to currently updated version, add Math::Prime.
13:36
mathw Ah XML parsers 13:37
horrible things
flussence they're relatively nice
I've tried writing HTML parsers a few times, not fun
where the "HTML" is user comments on a webpage, so usually not HTML at all... 13:38
13:39 am0c left
masak after looking at how TimToady's presentation software behaves, my guess is that it's not written on top of Rakudo. 13:40
if it was, I'd see some IO lag.
colomon rakudo: 227000.sqrt.say 13:47
p6eval rakudo d35769: OUTPUT«476.445169982864␤»
masak rakudo: say 100.sqrt.WHAT 13:48
p6eval rakudo d35769: OUTPUT«Num()␤»
13:49 am0c_ left
jnthn o/ pmichaud 13:50
masak 100.sqrt should be a Num, but +100.sqrt should be an Int, right?
jnthn pmichaud: $!worse--
13:50 Schwern left
pmichaud jnthn: yeah. 13:51
colomon masak: why?
masak colomon: because prefix:<+> converts to the narrowest possible Numeric type. 13:52
jnthn masak: ?
colomon masak: it does?!
masak colomon: so that things like 'my Int $n = +$<foo>' will work.
jnthn masak: I'd think .Numeric on something that already is Numeric is identity. 13:53
And the result of .sqrt is decidedly Numeric.
colomon how would you even define the narrowest possible Numeric type?
masak jnthn: that was my question.
colomon: if it helps, I could write down what I mean by that. but basically Int, then Rat, then Num.
flussence narrowest possible: "Int" unless it has non-zeroes after the dot, I guess 13:54
pmichaud note that the spec says "narrowest type" for non-numerics
masak flussence: yes; in the case of going from a string.
pmichaud for numerics, I think prefix:<+> is identity
masak and maybe that makes sense. 13:55
that's why I asked :)
colomon I'd argue it doesn't even make sense for "non-numerics" in general. 13:57
Stringy, sure
masak here's some prior discussion on this: rt.perl.org/rt3/Ticket/Display.html?id=62622
through all of these discussions, I've argued for a "numify to narrowest numeric type", simply because it doesn't hurt and it's nice for those who need it. 13:59
pmichaud I'm thinking that prefix:<+>($x) simply returns $x.Numeric
masak my +100.sqrt question above was for the times when you want the narrowest type but already have a Numeric.
pmichaud and then it's up to .Numeric to decide what the appropriate narrowing criteria is.
jnthn pmichaud: I thought that's what it already did?
pmichaud jnthn: it may be 14:00
jnthn If not, it's what I expect it to do.
'k
masak pmichaud: by that token, it sounds like +100.sqrt might well give an Int back.
colomon jnthn: yes, that's what it already does
jnthn colomon: +1
colomon except Numeric doesn't decide anything like that
pmichaud masak: that would depend on what Int.sqrt returns
14:00 synth left
colomon at least, not for Numeric types. 14:00
jnthn masak: +100.sqrt will give back what 100.sqrt gives back because the result is Numeric.
colomon as jnthn suggested earlier, Numeric.Numeric just returns self. 14:01
masak pmichaud: I'm fine with Int.sqrt returning Num always.
14:01 am0c^ joined
pmichaud masak: then +100.sqrt would seem to result in a Num also 14:01
since 100.sqrt (Num) is already Numeric
masak so it's just in converting from Stringy that narrowing happens?
jnthn I belive so.
pmichaud and other non-numeric types
for example, +@array
jnthn aye, that too
masak I'm trying to find the underlying logic here. I understand the mechanism.
maybe it's Least Surprise to let prefix:<+> be a no-op for Numerics. 14:02
jnthn "I want a number. If this already is one, I'm happy."
masak then my question becomes: how do I turn a Numeric into its narrowest type?
pmichaud +~$x :-P
masak /o\
pmichaud er, + ~ $x 14:03
masak no please no
pmichaud or perhaps there's another method for narrowing
colomon seems to me that narrowing makes sense for Stringy, but in the general non-numeric case it should be "whatever is convenient".
jnthn masak: What is your actual use case for this?
pmichaud colomon: I can argue that narrowing makes sense for Complex, Rat, Num, etc
i.e., 3.4+0i could narrow to 3.4 14:04
and 10/5 could narrow to (Int) 2
colomon pmichaud: sure, but that's adding a good bit of overhead for something which is basically a no-op now.
masak jnthn: my Int $iknowthiswillbeanintsrsly = $somenumber.sqrt.narrow-it;
jnthn This feels more magical than +$foo should do though.
pmichaud masak: oh, in that case $somenumber.sqrt.Int 14:05
jnthn Then the operation you'll looking for is called .Int
colomon and we've already got a good standard way of doing that in masak's example
jnthn *you're
masak pmichaud: :)
I think I'm happy with that.
colomon and jnthn beat me to the punch. :)
14:05 aloha left
pmichaud colomon: someone might have strong reasons for wanting to be able to narrow a type 14:05
masak that doesn't apply in the +$<foo> case, though.
pmichaud multi sub f(Rat $r) { ... }; multi sub f(Int $i) { ... }; f($x.narrowed)
masak because there .Int is what we're trying to avoid having to type out.
colomon pmichaud: sure, I'm not arguing there's no reason to have such a method available at all. 14:06
just that it doesn't make much sense for prefix:<+>, imo
pmichaud I think I agree that prefix:<+> should be the "generic narrowing" operator.
*shouldn't 14:07
colomon important qualifier there! ;)
pmichaud (don't take anything I write today as gospel, btw)
(or even as being sane)
masak prefix:<+> means numification. on this we all agree. 14:09
colomon .narrowed would also be useful if you want my Int $a = $x.narrowed to actually fail if $x cannot be turned into an Int without losing precision
14:09 meraxes joined
colomon anyone have a better name than .narrowed? 14:09
masak .Int(:lossless) 14:10
jnthn .narrowed sounds predicatey
flussence .compact?
jnthn .narrow is more verby
pmichaud wonders if people will think "negated arrow" :-P
colomon masak: but it might be that you don't want an Int, you just want something as narrow as possible 14:12
pmichaud .u 2900
phenny U+2900 RIGHTWARDS TWO-HEADED ARROW WITH VERTICAL STROKE (⤀)
masak colomon: right, as may in fact happen with .sqrt 14:13
pmichaud .u 294e
phenny U+294E LEFT BARB UP RIGHT BARB UP HARPOON (⥎)
masak rakudo: say 42.25.sqrt.Rat 14:14
p6eval rakudo d35769: OUTPUT«6.5␤»
14:14 aloha joined
pmichaud .Numeric(:narrow) 14:14
masak or :narrowest
pmichaud .narrowmeric 14:15
(see early comment re: sanity or lack thereof) 14:16
*earlier
jnthn .narrowmatic would be a code smell though
colomon arrrr
14:17 MayDaniel joined
masak today's "tries to be an autopun but isn't, really": twitter.com/whatdoiknow/status/27934719446 14:21
14:21 Schwern joined 14:23 Lorn left 14:26 AndroUser left 14:27 _twitch left
PerlJam greets 14:28
masak salut, PerlJam.
PerlJam what was the decision yesterday wrt parrot release used for rakudo?
I got disconnected and never made it back on.
pmichaud 2.9.1
PerlJam ah, I see moritz has already taken care of it :) 14:31
dukeleto hopes that the new String.reverse method helps rakudo have a much faster 'flip'
moritz_ dukeleto: more than 100x faster 14:32
dukeleto \o/
masak rakudo: say '/o\\'.flip
p6eval rakudo d35769: OUTPUT«\o/␤»
14:33 Italian_Plumber left 14:38 aloha left, Italian_Plumber joined
masak Italian_Plumber: hi! 14:39
Italian_Plumber: has anyone mentioned that Perl 6 has pipes? :)
moritz_ rakudo: <a b > ==> .uc ==> say
p6eval rakudo d35769: OUTPUT«===SORRY!===␤Sorry, do not know how to handle this case of a feed operator yet. at line 22, near " say"␤» 14:40
moritz_ rakudo: <a b > ==> uc ==> say
p6eval rakudo d35769: OUTPUT«A B␤»
masak those look suspiciously like barewords. but I guess they're subs.
14:40 am0c^ left
jnthn That works for a very wrong reason :P 14:41
rakudo: <a b > ==> map *.uc ==> say
p6eval rakudo d35769: OUTPUT«AB␤»
mathw is it supposed to be able to do that
jnthn That works for the right reason. :-)
moritz_ I thought that the ==> replaces the map() ? 14:42
jnthn no
==> just says "put the array as an argument to the sub call"
It's meant to bind to a variadic only though, perhaps. 14:43
masak I wouldn't object to an error in the '==> uc' case.
moritz_ then has a totally wrong understaind of feeds 14:44
mathw doesn't understand feeds at all, clearly
pmichaud rakudo: say uc <a b>
14:44 icwiener_ joined
p6eval rakudo d35769: OUTPUT«A B␤» 14:44
masak moritz_: need to do a way instain understaind.
14:44 awwaiid joined
pmichaud rakudo: say uc 'a', 'b' 14:44
p6eval rakudo d35769: OUTPUT«Too many positional parameters passed; got 2 but expected 1␤ in 'uc' at line 2613:CORE.setting␤ in main program body at line 22:/tmp/ZB8pA71e75␤»
pmichaud very interesting. :-)
14:45 icwiener left
masak and correct, AFAICS. 14:45
mathw mm
jnthn Aye
pmichaud: If it expents to bind stuff to a variadic there's no need to pass it |@foo
So *@foo flattens anyways.
s/variadic/slurpy/ # gah, writing one language, talking about another :-) 14:46
masak oh, so *that*'s what "variadic" means! :P 14:47
14:47 aloha joined
mathw in C++, a 'variadic template' is one which can accept variable numbers of parameters 14:47
masak aloha: aloha!
mathw they're fun, in a very brain-hurty way 14:48
so I always get a bit wary when I see 'variadic' :)
masak a bit... wary-adic?
*SCNR* 14:49
mathw fish to the face!!
masak mmm. almost fresh. 14:50
mathw damn, wrong fish
that one was supposed to be dinner
masak enjoy dinner. :) 14:51
mathw meh
jnthn Leave the un-fresh one for a few more months and it'll be a Swedish delicacy. ;-)
mathw I'm going to aikido tonight anyway, dinner's fairly irrelevant
as long as I don't eat it just beforehand anyway!
jnthn rakudo: role LolVariadic[*@args] { } # ;-) 14:52
p6eval rakudo d35769: ( no output )
mathw Perl 6 awesomeness factor just increased.
Is there any way for a role to find out anything about the class it's been composed into? 14:53
masak mathw: how do you mean?
jnthn methods can look at self.WHAT and get the type object
if that's what you're after 14:54
PerlJam mathw: after a role has been composed, what does it mean to be "a role" ?
jnthn In theory $?CLASS is a geneirc reference to the class one was composed into also.
mathw PerlJam: inside a method body defined in the role {}, it's still a role
14:54 _twitch joined
mathw Actually what I really want is a good use-case for roles 14:55
because I have seldom seen one
I may be too steeped in the misuse of inheritance splattered across C++-land
PerlJam mathw: roles come into play where you would otherwise use multiple inheritance (or the language-equivalent) 14:56
(for instance) 14:57
14:57 skids joined
masak I had an interesting AFK discussion yesterday with gentletwitterer @jfitzell. 14:58
he's a Smalltalk guy.
he didn't really see what roles would be good for if Perl 6 still had MI.
I explained. he thought that roles might as well just be a "flag on MI" to get the nice no-method-conflicts behavior. 14:59
then we talked some more. he wondered why not use roles all the time, and never inheritance.
PerlJam masak: does that mean he finally understood? :) 15:00
masak I didn't (and still don't) have a good answer to that, except that sometimes it "feels right" to use inheritance.
15:00 colomon left
masak PerlJam: we reached some sort of consensus, at least. 15:00
PerlJam: he's definitely aware of what roles are. he just didn't see why Perl 6 has both them and MI.
jnthn Because TMTOWTDI. 15:01
masak I said as much.
jnthn Somebody would whine if Perl 6 didn't support MI
PerlJam I think without roles, using MI alone you end up creating artificial relationships to satisfy the needs of certain problems.
jnthn Though I woudln't be one of them.
masak I said that we are "blessed and cursed" with TIMTOWTDI.
jnthn I'd happily toss MI from Perl 6. 15:02
masak I meant to say, but forgot, that Perl 6 is meant to handle the things that Perl 5 handles.
jnthn It only makes my life more complicated. :-)
Well, though so do things that I don't want to toss ;-)
masak PerlJam: aye, definitely. that motivates roles. can you also motivate MI, given roles?
PerlJam masak: sometimes objects should really be related (via inheritance or MI) because they really are related in the thing you're modeling. 15:04
15:04 rvrgs- left
masak that's... rather vague. 15:04
15:04 justatheory joined
masak or rather, would it kill you to use roles instead in that case? sounds to me like it wouldn't. 15:04
15:06 xinming joined
PerlJam I'd have to think about it some, but I think this is a case where Perl philosophy still wins. You want to be able to solve problems by adapting the code to the problem without artificial constraints imposed by the language. 15:06
masak I agree fully. 15:07
that's the consensus we ended up with. he said "too much rope"; I said "of course".
jnthn I can see a situation where something really *is* two things.
15:07 colomon joined
jnthn And so an inheritance relationship makes sense lingustically. 15:07
masak jnthn: GlowingSword is Weapon is LightSource? :)
jnthn Yeah
masak (that's Yegge, btw) 15:08
jnthn But you could change the words around to factor it as roles too
masak right.
jnthn GlowingSword is Weapon does Shine
masak GlowingSword does Hurt does Shine
GlowingSword does Hurting does Shining 15:09
colomon and that's where things start getting fuzzy for me.
I wonder if there's ever a reason to inherit rather than do a role.
masak for some reason I tend to want my roles as gerunds.
colomon: that's where jfizell and I left off.
I said there was, but I could only half-motivate it. 15:10
I said one might want to instantiate both parent and child classes.
jnthn masak: I find it fairly hard to motivate too
masak: aye but role punning may get you a bunch of the way too
So even that use case ain't so solid.
colomon ...which you can do with a role. ;)
masak role punning is just hiding the class behind some sugar.
it's still a class. 15:11
jnthn But the subclass has no relationship with the punned class
They both just happen to do the role.
That's the real underlying difference there.
masak aye. not too big, AFAICS.
colomon is there a way to find the reified portion of a list? 15:12
jnthn At a practical level, perhaps not.
colomon clearly we need to do more p6 programming to figure these things out. ;)
masak colomon: sounds like a "too internals-y for the user's own good" question. what's the use case?
colomon masak: I've got a lazy list of primes. If I want to test to see if an arbitrary number is prime, I'd like to just check that list if the number I'm looking for is less than the largest reified prime. 15:13
masak colomon: couldn't you keep a global variable for that purpose? 15:14
15:14 tzhs left
jnthn masak: Anyway, I agree it's hard to motivate MI in Perl 6 beyond TMTOWTDI. 15:14
masak sounds like an excellent use of max=
15:15 agentzh left
masak jnthn: maybe there are some cases where one would actually *prefer* C3 MRO to role flattening? though I can't see what that would be, especially not in the MI case. 15:15
15:15 jaldhar left
colomon masak: sure, but it would be an exact duplicate of the reified portion of my lazy list.... 15:16
oh
hmmm
and no I can't, not without rewriting things significantly.
masak actually, I think I can come up with a use case in the SI case.
15:16 krunen left
PerlJam Did the original traits paper give any examples of where you'd want MI (or just I) rather than roles? 15:16
masak PerlJam: good question. since the original traits paper pertains to Smalltalk, I'd be surprised if they mentioned MI in a favorable light :) 15:17
jnthn It talked a lot about the problems of MI and mixins and proposed roles as a better way to do it. :-)
It is really wroth reading, and quite an easy read too, fwiw. 15:18
But it doesn't really offer much on "so why still MI" from what I recall. :-)
masak web.cecs.pdx.edu/~black/publication...02-012.pdf 15:19
masak reads
15:23 MayDaniel left
jnthn Home time & 15:25
pmichaud 15:13 <colomon> masak: I've got a lazy list of primes. If I want to test to see if an arbitrary number is prime, I'd like to just check that list if the number I'm looking for is less than the largest reified prime. 15:26
TimToady++ and I have been working with the idea of .gimme() which would return the number of reified items in a list
masak interestingly, c2.com/cgi/wiki?TraitsPaper says that the traits paper explains why traits are better than SI. 15:28
15:30 colomon left
[particle]1 broken link on perl6.org 15:32
15:32 [particle]1 is now known as [particle]
masak [particle]: do you have a commit bit? 15:33
[particle] i think so... actually, i'm trying to find the repo, but the STD.pm6 link goes to a broken/missing github page
15:34 _kaare joined
masak github.com/perl6/perl6.org 15:34
[particle] thanks
15:36 iwork joined 15:38 iwork left 15:39 Alias left, Lorn joined, Alias joined, wallberg left
masak swimming & 15:42
15:42 masak left 15:47 colomon joined
takadonet colomon: welcome back 15:48
colomon sorry, the wifi in the train table room is dodgy. :)
takadonet did not miss much
15:49 phenny left, phenny joined, ChanServ sets mode: +v phenny
colomon and actually, I missed the crucial line from pmichaud where he talked about current notions of getting the reified items from a list. :) 15:49
takadonet well you exited after that :) all well 15:50
15:50 araujo left, risou joined
takadonet ls 15:51
.... wrong terminal
15:55 Ross joined, Ross left, Ross joined
moritz_ colomon: you can actually do the hash caching in next-prime() 15:58
colomon moritz_: except that would interfere with my priming the pump with a few dozen primes. :) 15:59
15:59 _twitch left
colomon I mean, yes, I could prime the hash as well, I guess 15:59
moritz_ my @seed = 2, 3, 5, 7, 11, 13, 19; %prime{@seed} = 1 xx *; 16:00
my @primes := |@seed, &next-prime ... *;
pmichaud watches TimToady++'s YAPC::Asia talk 16:02
16:03 pyrimidine joined, envi left
takadonet pmichaud: url? 16:04
16:04 aloha left
pmichaud www.youtube.com/user/yapcasia#p/u/76/KJUVP2Z13Yo 16:04
takadonet thanks 16:05
16:06 aloha joined 16:07 envi joined 16:10 envi left 16:11 aloha left, molaf left 16:12 hillu_ is now known as hillu 16:13 envi joined
jnthn back 16:14
takadonet jnthn: welcome back 16:15
jnthn Hope to get a little more NQP.Net hacking in tonight :-)
16:17 stkowski joined 16:19 Entonian joined 16:20 zulon joined 16:21 aloha joined
jnthn pmichaud: What is your plan for PCT::HLLCompiler? Re-write in NQP? 16:22
pmichaud Yes.
jnthn OK.
pmichaud basically add the needed methods to HLL::Compiler
jnthn I noticed it's...quite long. 16:23
Ah, add them to HLL::Compiler and eliminate the inheritance?
pmichaud PCT::HLLCompiler? Yes. PCT::HLLCompiler's methods are a place where I disagreed with the architecture but was "overruled"
("overruled" is too strong a word on its own -- but I acquiesced to others' ideas of how it should work and wish I hadn't) 16:24
but yes, eventually HLL::Compiler can conceptually eliminate the inheritance
jnthn OK. 16:25
I've plenty to work on in NQP.Net for now, so no huge urgency. Once that is sorted out sufficiently then I can switch NQP's class keyword to use ClassHOW, I expect. :-) 16:26
After that it'll "just" be Grammar that needs updating. :-)
Then triage.
16:27 kensanata left
jnthn At the same time, I do want to get the Parrot implementation pushed along a decent bit because I'd like to try and reach the half-way point on my grant by the end of next month. 16:27
pmichaud okay 16:28
16:32 araujo joined, baest left 16:34 zulon left 16:37 cdarroch joined, cdarroch left, cdarroch joined 16:38 skangas joined 16:39 MayDaniel joined 16:42 colomon left 16:43 isBEKaml joined
pmichaud afk, lunch 16:43
16:43 isBEKaml left 16:44 isBEKaml joined, colomon joined 16:45 aloha left 16:48 colomon_ joined, dakkar left 16:50 colomon left, colomon_ left 16:51 colomon joined
colomon is-prime appears to be really slow. :| 16:52
16:53 baux left 16:54 aloha joined
moritz_ we need a hash cache 16:55
or binary search within @primes
colomon actually, I don't think either of those will work in this case 16:57
in particular, is-prime(514229) takes 7 seconds on my MBP
and that's with @primes primed up to 541
moritz_ so, what do we do? miller rabin test? 16:58
colomon it's next-prime that's the culprit, I think.
is-prime(317811) is under a second (including rakudo startup time) 16:59
moritz_ it would be much more efficient if is-prime checked only the reified parts of @primes, and above that used all odd numbers
colomon moritz_: yes 17:00
good point
rakudo: say 514229.sqrt
p6eval rakudo d35769: OUTPUT«717.097622363929␤»
moritz_ rakudo: say 317811.sqrt 17:01
p6eval rakudo d35769: OUTPUT«563.747283807204␤»
moritz_ so is-prime(317811) relies nearly only on reified values, thus it's fast
colomon yes
I've just run a simpler test, and effectively all the time is spent generating the primes from 541 to 717. 17:02
moritz_ until there's an API to get the reified values, &next-prime could store the highest value it generated in an outer lexical 17:03
and is-prime() then stops accessing @primes for any values higher than that
colomon true.
but I want to make next-prime fast. ;)
moritz_ has an idea 17:05
colomon me too
and mine isn't cheating in any way, and gets 4x speed up in this case. :) 17:06
moritz_ last if $_ > $i.sqrt
(even better: cache $i.sqrt)
colomon moritz_: except you need to hoist $i.sqrt out of the loop
moritz_ right
colomon yeah, that's a very noticeable improvement
moritz_ ship it! ship it! 17:07
colomon I'm also thinking that the *@primes thing probably sucks, too
sucks time, I mean.
so maybe keeping a separate array of current primes would be a good thing.
moritz_ why separate?
just declare @primes before next-prime 17:08
colomon ummm.....
moritz_ and then re-use it next-prime
colomon that sort of thing always hurts my head.
but let me see.
(first, spectest on latest changes)
moritz_ well, you'd have to make sure not iterate over the reified part of @primes in &next-prime, otherwise you'll get infinite recursion 17:09
17:18 silug joined 17:21 isBEKaml left
colomon huh. attempt to use @primes in next-prime passes tests, but has no speed up 17:25
17:27 stkowski_ joined 17:30 colomon_ joined, colomon left, colomon_ is now known as colomon, stkowski left 17:31 stkowski_ is now known as stkowski, Chillance joined 17:33 xabbu42 left 17:34 colomon left, colomon_ joined 17:48 MayDaniel left 18:02 baest joined 18:05 colomon_ left 18:07 zostay left 18:08 kcwu left, zostay joined 18:09 kjeldahl joined 18:10 kcwu joined, Ross left 18:12 PerlJam left 18:15 PerlJam joined 18:16 aloha left 18:18 zostay left, zostay joined 18:24 colomon joined 18:32 wamba joined 18:34 aloha joined
sorear good * #perl6 18:34
PerlJam greets sorear
18:35 Ross joined 18:36 masonkramer left, MayDaniel joined 18:58 kst left 19:00 kst joined, colomon left 19:03 Entonian left 19:07 kjeldahl left, kjeldahl joined 19:15 molaf joined 19:28 zostay left, zostay joined 19:32 x3nU left 19:34 molaf left, x3nU joined 19:44 mavrc left 19:45 ggoebel left 19:47 mavrc joined 19:50 supernovus joined
sorear niecza: say (1 < 3 > 2) 19:50
p6eval niecza 4f60774: OUTPUT«Bool::False␤»
19:54 ggoebel joined 19:55 ggoebel left 19:56 MayDaniel left, ggoebel joined
pmichaud I'll be a few minutes late for phone. 19:57
sorear (I am amazed at how long my CHAIN has been horribly broken(
19:58 Italian_Plumber left
sorear wants to see minutes again, should I pester chromatic at the nest #ps? 19:58
PerlJam someone should just record the phone conversation and "outsource" transcription. 19:59
(take the pressure off of chromatic) 20:00
20:01 supernovus left
dukeleto PerlJam++ 20:06
20:06 aloha left 20:07 zhenya joined 20:12 plainhao left 20:13 cggoebel joined, ggoebel left 20:15 meppl left 20:16 aloha joined 20:18 Entonian joined, MayDaniel joined
dalek ecza/master: 9d541a8 | sorear++ | / (5 files):
Implement !op, fix CHAIN
20:21
20:32 rvrgs joined 20:34 zhenya left 20:39 zby_home_ left, ggoebel joined 20:40 ggoebel left, cggoebel left 20:41 ggoebel joined 20:45 cggoebel joined 20:46 ggoebel left 20:51 Ross left 20:52 aloha left 20:54 cggoebel left 20:55 thepler__ left 20:56 thepler joined, aloha joined 21:04 skids left 21:10 wamba left 21:11 wamba joined 21:13 Trashlord left
jnthn std: { our $x = 42; }; UNIT::<$x> 21:13
p6eval std : ( no output )
jnthn std: 42
p6eval std : ( no output )
jnthn :-(
diakopter ?
oh, p6eval std is broken 21:14
sorear p6eval niecza and nqp were broken yesterday
diakopter huge thanks to moritz_, who has done most (all?) of the work to move p6eval to a newer/faster vps for me... I wish I could offer more time to help him 21:15
21:17 cognominal left 21:19 Entonian left
moritz_ sorear: std fails to build on the new machine 21:19
niecza: say "test"
p6eval niecza 4f60774: OUTPUT«test␤»
diakopter newer/faster/cheaper, I should say
moritz_: I can take a look at std build fail now...
diakopter pm moritz_
21:20 cognominal joined
moritz_ I suspect it's related to STD.pm being installed via CPAN 21:21
diakopter oh 21:22
hm
moritz_ diakopter: maybe we should install a separate perl for running STD.pm
diakopter sounds like a good idea 21:23
moritz_ runs cpanm App::perlbrew
diakopter logs out :)
21:26 MayDaniel left 21:28 ggoebel joined 21:36 ggoebel left 21:37 pyrimidine left, zostay left 21:38 zostay joined 21:40 Entonian joined 21:45 xabbu42 joined 21:47 zostay left 21:48 zostay joined 21:49 rvrgs left
moritz_ perlbrew-- # setting PATH to : 21:50
sorear What if Cursor and Match had a common superclass? 21:51
moritz_ Capture?
21:58 _kaare left
moritz_ github.com/gugod/App-perlbrew/issues/issue/20 # the reason why I didn't get std to work yet 22:00
22:02 ggoebel joined 22:04 ggoebel left 22:08 ggoebel joined 22:09 aloha left, mavrc left 22:11 aloha joined 22:13 icwiener_ left 22:19 ggoebel left 22:21 Schwern left 22:29 envi left
diakopter moritz_: a reply 22:39
to your perlbrew bug
was posted.
dalek odel: c5c71cc | jnthn++ | dotnet/runtime/Runtime/Ops.cs:
[dotnet] type_object_for op should take an object and unbox it, not a low-level string.
22:46
odel: 4772c46 | jnthn++ | dotnet/compiler/Actions.pm:
Start trying to get our lexical vs package lookup story straighter.
odel: 8948ea1 | jnthn++ | dotnet/compiler/ (2 files):
[dotnet] Support ::Foo := ... style declarations for putting bareword names into the lexpad.
odel: 4f3c7e0 | jnthn++ | common/NQP/NQPSetting.pm:
[common] Set up a GLOBAL.
odel: aa3298f | jnthn++ | dotnet/compiler/PAST2DNSTCompiler.pm:
[dotnet] First incomplete cut at handling package scoped stuff.
odel: 606ccdc | jnthn++ | t/nqp/09-var.t:
We now pass 09-var.t.
diakopter heh
sorear jnthn: ping 22:50
jnthn sorear: pong
sorear I tried to make my ::Foo := ... work in niecza but ran into insurmountable problems 22:52
essentially, the RHS needs to run at BEGIN time in order for construction of the later parts of the metamodel to work
if you want to do class Bar is Foo
how are you dealing with this?
jnthn Everything that comes up to that point is lexically scoped. 22:53
I'm not using ::Foo for class construction though
And I'm not sure ::GLOBAL := NQPHash.new is going to last either. :-) 22:54
It works for the time being though.
I don't see why it has to run at BEGIN time, anyway.
(:= that is) 22:55
sorear only if you want to use it at BEGIN time
jnthn (Of course, we need a stash at compile time really.)
22:55 rblackwe_ left
sorear ::True := ... would be fine, ::GLOBAL := would not be... but I see you're on the same line, so nm 22:56
22:56 rblackwe joined
jnthn Right, I don't expect that to last. 22:56
dalek ecza/master: 031179f | sorear++ | v6/ (2 files):
Move v6/STD.pm6 to new $<foo>={1} syntax
23:00
ecza/master: eb27fd4 | sorear++ | v6/STD.pm6:
Fix syntax errors in v6/STD.pm6
ecza/master: 6344d14 | sorear++ | / (3 files):
Implement Match.hash and Match.list
23:05 nymacro joined
dalek odel: 9dcc5ed | jnthn++ | dotnet/compiler/PAST2DNSTCompiler.pm:
[dotnet] Fix a $*BIND_CONTEXT leakage that could cause an...entertaining...constants table to be built.
23:08
23:09 bobnet joined 23:11 awwaiid left 23:14 rvrgs joined 23:15 xinming left 23:23 bobnet left
dalek odel: 0c0d5df | jnthn++ | dotnet/runtime/Runtime/Signatures/SignatureBinder.cs:
[dotnet] Fix a thinko in the signature binder that made optional parameters not work out so optional.
23:24
odel: aa37f0f | jnthn++ | t/nqp/22-optional-args.t:
[dotnet] We now pass 22-optional-args.t.
23:25 kjeldahl left 23:26 ggoebel joined 23:29 dju_ joined
dalek odel: 7e9d2b8 | jnthn++ | common/NQP/NQPSetting.pm:
[common] $diag arg of ok should be optional.
23:29
odel: 1fea9b0 | jnthn++ | t/nqp/16-ternary.t:
Now passing 16-ternary.t.
23:29 dju left 23:30 pothos left, eternaleye left 23:31 eternaleye joined, pothos joined
jnthn Need for loops to kinda work and return statements to get rather closer to ClassHOW working. 23:33
23:34 s1n left
jnthn will be happy to reach that point 23:34
23:40 nymacro left
diakopter rather depressed by the last post on 6guts 23:42
jnthn diakopter: Well, trying to get a handle on what's wrong is a required first step to working out some solutions, and I think the post helps on that front. 23:44
But yes, it's...tricky. 23:45
diakopter speechless, further. 23:46
23:47 ggoebel left 23:49 s1n joined 23:52 risou left
jnthn confused by diakopter 23:55
Anyways, $dayjob in the morning...
jnthn sleeps
23:56 cotto left 23:59 cotto joined