»ö« 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:08 xragnar_ joined, xragnar is now known as Guest23388, Guest23388 left, xragnar_ is now known as xragnar 00:10 jack_rabbit joined 00:16 thou joined
jack_rabbit What can I do to help out perl6? I've found a lot of docs pointing me to different places, but one of the things most of them say are to check out the IRC channel. 00:18
00:20 thou left 00:34 hoverboard joined 00:37 pdcawley left 00:40 pdcawley joined
Timbus jack_rabbit, use it! 00:43
jack_rabbit heh. :) It looks like there's still some stuff missing. I like the syntax better than Perl5 (I'm still learning how to be proficient in version 5) 00:44
If perl6 has some documentation or tutorials, I'd love to take a look. 00:45
Timbus doc.perl6.org/ for some simple docs (that need work!)
modules.perl6.org/ for libraries you could use or improve 00:46
00:51 bjz left 00:52 bjz joined
jack_rabbit Thanks. I'll see if I can help out. 00:54
timotimo welcome, jack_rabbit :) 01:01
in this place you'll find friendly conversation, help with learning and developing 01:02
~1.5 years ago when i started helping, i found it surprisingly simple to work on the core itself (i worked mostly on the optimizer)
but outside of the core there's lots to improve, too: the spectest suite can always be expanded with tests for new bugs found for example 01:03
and the so-called "core setting" is pure-perl6 code; it contains all the classes and subs you'll end up using
(though it is rather performance-sensitive code, because much from inside the core setting gets used lots and lots) 01:04
01:04 hoverboard left 01:13 hoverboard joined 01:22 avuserow joined 01:23 hoverboard is now known as lel 01:27 avuserow left 01:28 lel is now known as hoverboard 01:30 FROGGS_ joined 01:33 Sqirrel_ left, FROGGS left 01:35 hoverboard is now known as ishaynx 01:38 Su-Shee_ joined 01:41 Su-Shee left 01:46 ishaynx left, ishaynx joined 01:50 thistuso- joined 01:52 ishaynx is now known as hoverboard, klapperl_ joined 01:54 thistusooa left 01:56 klapperl left 01:57 SamuraiJack joined 02:01 avuserow joined 02:02 thistuso- is now known as thistusooa 02:03 thistusooa left, thistusooa joined 02:04 thou joined 02:07 avuserow left 02:08 thou left 02:37 xragnar left 02:39 xragnar joined 02:41 thistusooa left 02:50 avuserow joined 02:54 thou joined 03:22 atroxaper joined 03:26 hoverboard left 03:27 hoverboard joined
jack_rabbit timotimo, Thanks! I'm sure I don't know enough to be trusted messing with performance-sensitive code yet, but I'd be happy to take a look at some of the tests. 03:45
03:46 hoverboard left
Timbus github.com/perl6/roast here be tests 03:47
its a lot 03:48
03:55 atroxaper left 03:56 atroxaper joined 04:06 hoverboard joined 04:11 rurban left 04:13 atroxaper left 04:16 kaare_ joined 04:27 baest_ joined 04:30 baest left 04:34 rjbs- joined, japhb joined 04:37 dayangkun joined 04:39 ribasushi joined 04:41 atroxaper joined 04:44 atroxaper left 04:45 rurban joined 04:46 atroxaper joined 04:57 atroxaper left 05:15 pdcawley left 05:16 pdcawley joined 05:17 BenGoldberg left 05:19 Sqirrel joined 05:39 xinming_ left
Timbus m: sub a(int $i) is cached { return unless $i; a($i-1) }; say a(4); 05:39
camelia rakudo-moar ce6acf: OUTPUT«Cannot find method 'gist': no method cache and no .^find_method␤ in method gist at src/gen/m-CORE.setting:7121␤ in block at src/gen/m-CORE.setting:3357␤ in any enter at src/gen/m-Metamodel.nqp:3089␤ in method postcircumfix:<( )> at src/gen/m-C…»
05:41 xinming joined 06:11 japhb left 06:12 FROGGS_ left 06:14 rurban left 06:31 Rotwang joined 06:41 hoverboard left 06:45 rurban joined 06:49 japhb joined, rurban left 06:59 darutoko joined 07:22 larks joined 07:34 ssutch left 07:42 jack_rabbit left 07:59 rurban joined 08:03 rurban left 08:17 anaeem1_ joined 08:25 kivutar joined 08:28 uniejo joined 08:30 uniejo left 08:33 anaeem1_ left 08:35 anaeem1 joined 08:36 anaeem1 left 08:41 spider-mario joined 08:53 martinzaremba joined 08:54 martinzaremba left, martinzaremba joined 09:03 pdcawley left, uniejo joined, uniejo left 09:05 pdcawley joined 09:07 thou left
lizmat good *, #perl6! 09:38
yoleaux 31 May 2014 22:31Z <vendethiel> lizmat: no, the replacement is fixed. but I'd need to generate stuff like <before "."x$len-1> ... stuff
09:39 SevenWolf left 09:47 Psyche^_ joined 09:51 Psyche^ left
lizmat Timbus: seems there is some confusion as to what gets passed to the sub 09:52
is cached uses the gist of the signature to creata a key
for caching the return value
m: sub a(int $i) is cached { return unless $i; a(($i-1).Int) }; say a(4)
camelia rakudo-moar ce6acf: OUTPUT«(Any)␤»
lizmat either defining $i as an Int, or making sure we pass an Int, is a workaround for now 09:53
09:54 itz joined 09:56 PZt joined
Timbus yeah. just thought it was an odd one 09:56
lizmat submits rakudobug 09:57
09:59 dmol joined 10:03 denis_boyun_ joined
masak good antenoon, #perl6 10:07
lizmat masak Timbus o/ 10:08
^^^^ #122004
synopsebot Link: rt.perl.org/rt3//Public/Bug/Displa...?id=122004
Timbus its an optimizer thing 10:09
also thanks for making the ticket :>
lizmat Timbus: ah, indeed, with MVM_SPESH_DISABLE=1 no problems 10:11
dalek kudo/nom: a1f80d9 | (Elizabeth Mattijsen)++ | src/core/ThreadPoolScheduler.pm:
Introduce RAKUDO_MAX_THREADS environment variable

To make it easier to debug problems involving threads.
10:18
lizmat m: say await do for ^13 { start { 1 for ^100000; $_ } 10:19
camelia rakudo-moar ce6acf: OUTPUT«===SORRY!=== Error while compiling /tmp/x2U9tuN2fA␤Unable to parse expression in block; couldn't find final '}' ␤at /tmp/x2U9tuN2fA:1␤------> do for ^13 { start { 1 for ^100000; $_ }⏏<EOL>␤ expecting any of…»
lizmat m: say await do for ^13 { start { 1 for ^100000; $_ } } 10:20
camelia rakudo-moar ce6acf: OUTPUT«(signal )»
lizmat m: say await do for ^13 { start { 1 for ^1; $_ } }
camelia rakudo-moar ce6acf: OUTPUT«(signal )===SORRY!===␤Spesh: failed to fix up handlers (132, -1, 154)␤»
lizmat m: await do for ^13 { start { 1 for ^1; $_ } } 10:21
camelia rakudo-moar ce6acf: OUTPUT«Unhandled exception: Spesh: failed to fix up handlers (132, -1, 154)␤ at src/gen/m-CORE.setting:11453 (/home/p6eval/rakudo-inst-2/languages/perl6/runtime/CORE.setting.moarvm:throw:117)␤ from <unknown>:1 (/home/p6eval/rakudo-inst-2/languages/perl6/r…»
lizmat jnthn ^^^ I assume this is another expression of the 13 x 1 REPL issue 10:22
masak lizmat++ 10:29
m: for ^13 { EVAL '1 for ^1; $_' }; say "alive"
camelia rakudo-moar ce6acf: OUTPUT«alive␤»
10:32 usernotexists joined 10:38 eternaleye left
lizmat r: say $*PID; $*PID = 23; say $*PID # is tha ability to change $*PID desirable ? 10:39
camelia rakudo-parrot ce6acf: OUTPUT«15667␤23␤»
..rakudo-moar ce6acf: OUTPUT«15675␤23␤»
..rakudo-jvm ce6acf: OUTPUT«20388␤23␤»
10:39 thou joined 10:43 thou left 10:45 FOAD left 10:46 eternaleye joined 10:47 FOAD joined
lizmat r: my @a = ^4; for @a <-> $_ {$_++}; say @a 10:47
camelia rakudo-{parrot,jvm} ce6acf: OUTPUT«1 2 3 4␤» 10:48
..rakudo-moar ce6acf: OUTPUT«0 1 2 3␤»
lizmat seem moar is wrong here
r: my @a = ^4; for @a -> $_ is rw {$_++}; say @a
camelia rakudo-{parrot,jvm} ce6acf: OUTPUT«1 2 3 4␤»
..rakudo-moar ce6acf: OUTPUT«0 1 2 3␤»
lizmat seems underlying "is rw" is faulty
masak: rakudobug ? 10:49
r: my @a = ^4; for @a {$_++}; say @a # default seems ok
camelia rakudo-{parrot,jvm,moar} ce6acf: OUTPUT«1 2 3 4␤»
xfix r-p: [].sorto 10:50
camelia rakudo-parrot ce6acf: OUTPUT«No such method 'sorto' for invocant of type 'Array'␤ in block at /tmp/OPbzWb40QY:1␤␤»
lizmat
.oO( that feels sorta right )
10:51
xfix Wouldn't it be nice if Rakudo could suggest using ".sort"?
lizmat ah, yes
indeed
on my list of things to do
m: sorto []
camelia rakudo-moar ce6acf: OUTPUT«===SORRY!=== Error while compiling /tmp/iN6cKT2lKy␤Undeclared routine:␤ sorto used at line 1. Did you mean 'sort', 'sqrt'?␤␤»
lizmat like that, right ? 10:52
xfix Yes.
m: sqrt []
camelia ( no output )
xfix (hm, I guess that array is sorto number)
lizmat m: say +[] 10:53
camelia rakudo-moar ce6acf: OUTPUT«0␤»
lizmat the "problem" (which makes this a less LHF for me) is that the levenshtein logic lives in Perl6/World.nqp
and would need to access that from the Perl6 exception handler 10:54
masak if it were to be factored out into a common place, what would be the logical place for it?
lizmat well, that would be the other approach: would we want levenshtein functionality to be Perl6 core ? 10:55
OTOH, we need it at compile time as well, so the place it lives now is probably ok 10:56
xfix Anyway, I'm working on module for Perl 5 which would add Levenshtein logic for errors. 10:57
dalek kudo/nom: 7e0940d | (Elizabeth Mattijsen)++ | src/core/Process.pm:
Make sure $*PID is immutable
xfix There are some issues, like accessing local variables, but I already figured how to do most things.
11:04 Su-Shee_ is now known as Su-Shee
dalek ast: 6324a64 | (Elizabeth Mattijsen)++ | S02-magicals/pid.t:
Add test for immutability of $*PID
11:06
ast: 8312a32 | (Elizabeth Mattijsen)++ | S02-magicals/pid.t:
Fudge $*PID immutability test for JVM / Parrot
11:12
11:18 martinzaremba left 11:20 cognominal joined 11:23 martinzaremba joined 11:25 virtualsue joined 11:40 martinzaremba left 11:49 anaeem1 joined 11:50 Alula joined 11:53 pdcawley_ joined 11:54 pdcawley left
lizmat r: class IntWithName is Int { has $.name }; my $a = IntWithName.new( :value(42), :name<foo> ); say $a; say $a.name # what am I doing wrong here ? 11:54
camelia rakudo-jvm 7e0940: OUTPUT«(timeout)» 11:55
..rakudo-{parrot,moar} 7e0940: OUTPUT«0␤foo␤»
timotimo the value most probably needs to put in with a box_i call
or set_i
lizmat nqp::box_i ? 11:56
timotimo i think so 11:57
you'd create an instance of IntWithName using box_i and then set the name ... or something
tbh, i'd rather plop a role onto an existing Int
lizmat I tried that too
timotimo oh
lizmat m: role Name { has $.name is rw }; my Int $a does Name = 42; $a.name = "foo" 11:59
camelia rakudo-moar 7e0940: OUTPUT«===SORRY!=== Error while compiling /tmp/OhRQaEthXa␤Cannot call 'trait_mod:<does>'; none of these signatures match:␤:(Mu:U $doee, Mu:U $role)␤at /tmp/OhRQaEthXa:1␤------> ␤»
timotimo m: role Name { has $.name is rw }; my Int $a = 42 but Name; $a.name = "foo"
camelia ( no output )
lizmat m: role Name { has $.name is rw }; my Int $a but Name = 42; $a.name = "foo"
camelia rakudo-moar 7e0940: OUTPUT«Cannot modify an immutable Int+{Name}␤ in block at /tmp/bKAqcAarFm:1␤␤»
timotimo m: role Name { has $.name is rw }; my Int $a = 42 but Name; $a.name = "foo"; say $a.name; say $a;
camelia rakudo-moar 7e0940: OUTPUT«foo␤42␤»
12:00 martinzaremba joined
lizmat timotimo++ 12:00
masak .oO( a 42 by any other name would smell just as sweet ) 12:09
12:11 [Sno] joined 12:12 martinzaremba left
lizmat masak: more going for something like this: $ 6 'say $*UID; say $*UID.name' 12:12
501
liz
12:15 martinzaremba joined 12:16 martinzaremba left
timotimo dang, $someone really ought to build a nice little demo for an asynchronous/multithreaded web server/framework thingie 12:17
lizmat someone will, when we get the bugs out of the asynchronous execution :-) 12:18
timotimo hmm.
lizmat timotimo: did you see the discussion about 1a224d30 on #moar ? 12:19
timotimo ah, yes 12:20
feel free to revert it
you could also just put a break; /* XXX this causes problems: *description* */ after case MVM_OP_can: case MVM_OP_can_s: in the optimize_bb function 12:21
and the same comment into the optimize_can_op function as well
or something like that.
12:23 martinzaremba joined 12:25 BenGoldberg joined 12:26 xenoterracide joined
masak lizmat: I would do that with 'handles', not 'is' or 'does'. 12:37
YMMV
lizmat masak: could you elaborate ?
masak the programmer meme that discusses this is called "favor delegation instead of inheritance" 12:39
12:39 BenGoldberg left
masak or s/delegation/composition/, but it comes out as the same. 12:40
seems there's a Wikipedia page for it: en.wikipedia.org/wiki/Composition_...nheritance 12:41
lizmat: for some reason I feel like I'm channeling moritz++ when I'm saying this: "a UID is not a special kind of Int" 12:42
lizmat so you'd rather have a $*UID_NAME ?
xfix I personally dislike inheritance in its Java form.
12:42 anaeem1 left
xfix (but it's probably just me) 12:43
12:43 anaeem1_ joined, anaeem1_ left 12:44 martinzaremba left
masak lizmat: *or* have whatever object is sitting in $*UID *not* be an Int, but happily numify and stringify to a UID, and also have a method .name 12:44
lizmat so what I did, is right, except that .WHAT says Int+{Name} ? 12:45
xfix *or* rename $*UID to $*USER, and make it stringify to name, but numify to ID.
masak lizmat: think so. 12:46
lizmat: I wouldn't use inheritance for... much at all, these days.
lizmat I'm trying to follow S28:122
synopsebot Link: perlcabal.org/syn/S28.html#line_122
xfix I personally like inheritance in JavaScript.
masak looks
xfix It just seems more practical, with Object.create().
12:47 denis_boyun___ joined
masak xfix: same -- though I find I don't actually *use* the prototypal nature of the inheritance much in practice. 12:47
xfix: I get by with object cloning in most cases.
12:47 xenoterracide left, denis_boyun_ left
masak lizmat: S28:122 says that it *is* an Int, yes. I'd be fine with that. where does it say that it has a .name method? 12:48
synopsebot Link: perlcabal.org/syn/S28.html#line_122
masak (also, doesn't it strike you as slightly odd that a user *id* would have a name, rather than the user itself?)
lizmat so you would be in favour of renaming it to $*USER and numify to UID and stringify to name ? 12:49
or rather not have the user name available at all (as the spec currently suggests)
masak in that case, I'd vote for custom opaque object $*USER, string $*USER.name and int $*USER.id 12:51
Woodi is it *nix specific discusion or need to work the same universally ?
masak but I'd also be happy with no custom object, string $*USER_NAME and int $*UID
Woodi and hi everyone :) 12:52
lizmat Woodi o/
12:52 BenGoldberg joined
xfix $*UID seems like the UNIX specific distinction. 12:52
Woodi why is Levenstain needed in core ?
xfix Woodi, because it helps fixing misspellings.
lizmat m 42.sorta 12:53
m: 42.sorta
camelia rakudo-moar 7e0940: OUTPUT«No such method 'sorta' for invocant of type 'Int'␤ in block at /tmp/lz4PZc_MSk:1␤␤»
lizmat suggest "sort" as a method name in such a runtime error
masak xfix: no, that's what it *does*, not why it's needed in core. :)
Woodi aha, now I know :)
lizmat m: sorta 42
camelia rakudo-moar 7e0940: OUTPUT«===SORRY!=== Error while compiling /tmp/_xZu7GD6Kv␤Undeclared routine:␤ sorta used at line 1. Did you mean 'sort', 'sqrt'?␤␤»
xfix In Windows, users are recognized basing on their SID numbers, which look like S-1-5-21-1180699209-877415012-3182924384-500.
masak charming.
lizmat like that, but for runtime method lookups 12:54
xfix Technically, the last part is closest think to the UNIX ID, but that works only when you have one computer.
s/think/thing/
Woodi last days I like to have simple functionalities available and then build complex things when needed. just packaged somehow 12:55
masak Woodi: yes, that sounds nice.
Woodi but sometimes not easy :)
masak Woodi: I think that's partly captured in the "easy things easy, hard things possible" slogan. but devil's in the details. 12:56
xfix I personally think that Perl 6 has too much in core, but Levenshtein distance doesn't seem like issue, as it's not publicly available.
Why .is-prime not a module anyway? 12:57
s/not/is not/
Woodi xfix: I had feeleing that CORE had gained a lot of functions lastly. but I never fully understand that simple core what was planned...
xfix I know that Perl 6 forms were removed from a core, but there are lots of other features that barely have any use. 12:58
Woodi maybe we need BATTERIES subsystem ? :)
xfix Python has huge standard library. Perhaps too big for its own good. But at least, core is relatively small. 12:59
Woodi but some say's and slurp's are needed. would be nice to have them packaged in packs and some just used auomatically 13:00
xfix Perl 5 was also minimalistic. It has get* and set* functions that nobody uses, but practically everything is in CPAN.
lizmat since most of the core is written in Perl 6, it should be relatively easy to move out stuff from the core if needed
xfix is also*
I'm personally against moving "say" from the core. It just seems like an useful function for basic "Hello, world" examples.
Woodi some time ago was discusion about stat :x functionalities - there are in core ?
xiaomiao as a distro packager I suggest not removing things from the core / stdlib once they are in 13:01
that makes dependencies very frustrating and slows down adoption
Woodi I thinked about all that functions from C. do we need some C:: namespace with ::stdio ::others available ? 13:02
xfix There are lots of functions that nobody uses, but they are still in core, because perhaps someone uses them, and they cannot be removed. I assume it's still why Perl 5 has low level functions in core language. 13:03
lizmat afk for a few hours&
xfix s/it's still/a reason/
Woodi xfix: that Perl5 functionality was intentionally changed 13:04
xfix Before Perl 5, modules didn't exist. 13:05
These days, modules exist. There is POSIX for example (which has lots of useless functions, but still).
Woodi and question is do scripting language needs all that low level functions. just using such function for performance probably is't a magic trick 13:07
13:07 dmol left
xfix They aren't exactly for performance, perhaps with few exceptions. 13:08
Sockets exist, but why anyone would use sockets directly?
Woodi and we want: a) syscals; b) /bin and /usr/bin utilities with all convenient switches both :)
xfix (ok, perhaps it's for performance)
masak I don't think providing conveniences in core (such as .is-prime or .combinations) is a real problem.
but I do agree that we don't really have a general strategy or rule-of-thumb for what goes in core and what doesn't. 13:09
xfix Second System Syndrome?
masak could you expend it into an entire question? 13:10
expand*
xfix Perl 6 wants to do everything, and everything requires lots of builtins.
masak (1) that's not a question
Woodi ppls like feeling of control when using simple tools. low level reads used in Perl feels simple and feels to have good performance but autually Perl5 native read with buffering have usually better performance :)
masak (2) many general-purpose languages can be described in that way.
the "small core" ideal has the advantage that whatever ends up in core tends to be fairly powerful and combinable primitives. 13:11
but Perl 6 has never promised to be "small core"
and in any case, the setting is already outside of the core and is more of a standard library of by-default loaded functions and types. 13:12
xfix Well, it's possible to make too small core.
masak the real core is the grammar/actions and the mop.
xfix Lua's core practically has ntohing.
13:13 dmol joined
Woodi masak: I have idea of some library of all that stuff available and things "being" in core just being "referenced" 13:13
xfix Woodi, like glob in Perl 5?
Woodi there was "no core" meme or something ?
no, functionality available somehow, not technique 13:14
eg. say would be just something in STDP6 and just used by default in core 13:15
masak there has been discussion now and then about "lazy loading" of heavy dependencies.
xfix Well, glob() in Perl 5 behaves exactly like this.
It loads File::Glob::glob().
Woodi ah, glob :)
masak for example, if you're not using any MOP stuff for your one-liner, maybe all the MOP stuff doesn't have to be loaded?
same thing with grammars, etc.
but I've never seen it proceed from the idea stage. and it would probably be hard to pull off, especially for the pieces I mentioned. 13:16
probably lots easier to lazily load parts further from the core, such as DateTime.
xfix That sounds like performance optimization, to be honest.
Woodi no, I think it is just (sh-like) functionality in P5 core not some functionality in P5 stdlibrary and autoavailable
masak it would primarily affect startup.
Woodi masak: yes pleas ! :) 13:17
no MOP by default :) if it's possible :))
masak the current problem with lazily loading things from the setting is that the setting is one big monolithic lexpad.
Woodi xfix: ok, I wasnt' avare it is that way 13:18
xfix There are LOTS of things in global namespace.
Dynamically loading things wouldn't fix this.
masak "no MOP by default" would be... tricky. basically, someone would have to develop a "dumb" version of Rakudo that didn't presuppose an MOP, and launch into that one if no MOP usage was detected. note that any class declaration or some such would qualify as MOP usage.
Woodi masak: maybe we have "core" word overloaded ? 13:19
masak certainly.
Woodi: there's a moritz++ blog post about that.
but it's basically a "yes -- deal with it" situation.
xfix Also, there was a decision to make Perl 6 object oriented.
Which leads to the situation where both `sqrt 2` and `2.sqrt` are valid. 13:20
Woodi masak: maybe no "no MOP by default" but only new crated objects to be just struct-like ?
with "is simple" trait or something ? 13:21
xfix In some languages, method(object) is syntactic sugar for object.method(), but this is not the case in Perl 6.
Woodi do we have pool of not quite instantiated objects ? 13:22
vendethiel xfix: not many languages, tho :) 13:23
xfix That's true.
vendethiel and don't you mean it the other way ?
`object.method` being sugar for `method(object)` N?
xfix Well, right.
vendethiel OTTOMH, I can think of luna, but not many others. Doesn't lua do something like that ? 13:24
xfix Lua has metaclass attribute or something.
masak xfix: it's true to some extent.
13:25 bjz left
xfix And a:method() is syntactic sugar for getmetatable(a).method(a) 13:25
masak m: class C { method foo { say "OH HAI from {self}!" } }; my $c = C.new; my $foo_method = C.can('foo')[0]; $foo_method($c)
camelia rakudo-moar 7e0940: OUTPUT«OH HAI from C<140421877400560>!␤»
masak xfix: ^^
xfix In Perl 6, classes themselves are objects (like null objects in other languages) which can call their methods, if I remember correctly. 13:26
m: class C { method foo { say "Hi" } } C.foo
camelia rakudo-moar 7e0940: OUTPUT«===SORRY!=== Error while compiling /tmp/ZPSGAr8ZYD␤Two terms in a row␤at /tmp/ZPSGAr8ZYD:1␤------> class C { method foo { say "Hi" } } ⏏C.foo␤ expecting any of:␤ postfix␤ statement end␤ …»
xfix m: class C { method foo { say "Hi" } }; C.foo
camelia rakudo-moar 7e0940: OUTPUT«Hi␤»
13:27 pdcawley_ left
xfix But I guess that this .can is useful, even if it's not straightforward. 13:27
(for calling methods on unrelated objects, perhaps)
13:27 BenGoldberg left
Woodi masak: do settings are precompiled and are just some binary blob loaded on startup ? 13:30
xfix There is also another issue. Some application may not need certain features, but other programs absolutely need it.
For example, I cannot see sin() being used for a simple web application.
masak Woodi: yes.
xfix: ...until you start doing animations, and need to calculate smooth trajectories... :) 13:31
xfix: then it's "gah what's this language doesn't even have sin()!!!"
xfix Yes.
Woodi xfix: I was dreamed some times ago compile-out functionality :) when program is compiled then not needed things from settings/core are compiled out :) but maybe compilers do this thes days :)
xfix gcc doesn't link with math by default. 13:32
13:32 pdcawley joined
xfix You need to specify -lm to be able to use functions like sin(). 13:32
Woodi and probably lot's of programs do not need eval available at runtime :)
xfix Programs usually don't have to use every single feature of a programming language. 13:33
And sometimes, they just cannot. 13:34
Many cloud computing providers don't allow saving files. 13:35
(you are expected to use a database instead)
flussence Does Rakudo have a good way to do fine-grained profiling of startup time? 13:36
xfix In this case, there is no point in opening files for writing.
flussence s/of/of its own/ 13:37
xfix I assume you can --profile empty code, or something like this.
13:39 FROGGS joined
flussence Then that would be a better place to start than trying to decide via strawpoll what shouldn't be in core. 13:40
xfix Do you want a poll with 200 questions? 13:42
(or more, I haven't really counted number of functions)
flussence I'm assuming here that the reason we're talking about the size of core is performance-related 13:44
xfix Not really.
Woodi ehmm, Mozilla and Debian asks for participations in some statistics colectings :)
xfix But I wonder about something else. Parse every single Perl 6 module, and check which methods and functions are most often called. 13:45
Woodi I think we need everything available and some of that functionalities loaded by default
masak Perl 5 has always been a language where you could build stuff you needed. CPAN attests to that.
with Perl 6, we aim to provide some of the nicer things by default. you can still build your own if/when you need it.
xfix Perl 5 needs CPAN for things more complex than text processing.
masak it's a different balance, a different local maximum. that's all.
Woodi masak: but it will introduce duplication of similiar code 13:46
dalek rl6-Text-Abbrev: 3a3cded | (Konrad Borowski)++ | META.info:
It's probably a good idea to fix the link.
13:47
xfix oops
I forgot I still didn't disable this.
Argh.
FROGGS about the state of panda and CPAN: my locally patched panda can almost fetch the MIRRORED.BY, only almost because panda does not use LWP::UserAgent, and the stuff I get is chunked
yoleaux 31 May 2014 21:33Z <lizmat> FROGGS: I'm also considering making @*INC an object with push/unshift/gist overloaded
31 May 2014 21:33Z <lizmat> FROGGS: so that a say @*INC will create a string that can be used with -I
FROGGS .tell lizmat yeah, would be nice to have a roundtripable @*INC 13:48
yoleaux FROGGS: I'll pass your message to lizmat.
FROGGS after we have the MIRRORED.BY, it is similar to fetching stuff from github...
that means that I develop the stuff to fetch from CPAN independently to the "install to a database / S11" work 13:49
13:49 rurban joined 14:00 geekosaur joined 14:05 rindolf joined 14:09 sqirrel__ joined 14:15 anaeem1_ joined 14:21 eternaleye left, zakharyas joined 14:24 zakharyas left 14:26 eternaleye joined 14:37 zakharyas joined
TimToady Perl 6 is a large language by design, like English, but that mostly only means we have a large dictionary somewhere that we can look things up in; the actual definitions (bodies of subroutines and such) could be loaded lazily when we get to the point we want to bootstrap Perl 6 in our wristwatches that will be memory limited to only a few terabytes :) 14:42
14:45 anaeem1_ left 14:47 anaeem1_ joined
masak :) 14:49
vendethiel o/ TimToady 14:50
masak damn, now I want Perl 6 in my wristwatch.
vendethiel doesn't own a watch
timotimo wow, +<= looks odd 14:54
14:55 pippo joined
masak I guess you could write it as [+<]= 14:56
timotimo m: my $a = 10; $a [+<]= 3; say $a; 14:57
camelia rakudo-moar 7e0940: OUTPUT«===SORRY!=== Error while compiling /tmp/8QBFmpZgMV␤Preceding context expects a term, but found infix = instead␤at /tmp/8QBFmpZgMV:1␤------> my $a = 10; $a [+<]=⏏ 3; say $a;␤»
timotimo :o
sergot hi o/
timotimo hi there 14:58
how's the www stuff going? :)
pippo o/ #perl6 14:59
japhb Any special trick for installing v5? 'panda install v5' dies while compiling the second module, lib/Perl5/English.pm, complaining it can't find Perl5. 15:00
timotimo froggs wasn't able to make v5 panda-able yet :( 15:02
rosettacode.org/wiki/Dinesman%27s_m...lem#Perl_6 - i changed the description to point out what needs to be changed to work with a different problem statement. feel free to improve upon it 15:04
itz roll on ARM moarvm and we can have 'droid rakudo
japhb FROGGS: Is the Rakudo patch still needed for v5? 15:06
timotimo itz: we're working on it ... or rather nicholas clark is :)
15:14 sqirrel__ left
itz japhb: its not 15:16
masak .oO( itz not ) 15:18
Perl 6 should have an entry here: codegolf.stackexchange.com/question...akes-2-2-5 15:25
m: multi infix:<+>(2, 2) { 5 }; say 2 + 2 15:26
camelia rakudo-moar 7e0940: OUTPUT«5␤»
masak I might be biased, but that solution beats all the others on that page.
oh. I can't add that answer, because it's protected and (I'm pretty sure) I don't have 10 reputation on that site. 15:27
masak adds it to HN instead
news.ycombinator.com/item?id=7829458 15:29
FROGGS japhb: no, the patch is not needed anymore 15:33
perl6-m Configure.p6 && make install # that should do 15:34
15:41 eternaleye left
japhb FROGGS: When I did the configure, the all target still pointed to p-all, so make by itself didn't work. I eventually found 'make m-install' and that seemed to work. 15:41
FROGGS ahh, yes 15:42
m-install is correct
I'd like to get it panda installable, but the actions and grammar are nqp modules, and panda cannot install stuff for nqp :( 15:43
would be awesome to turn it into pure Perl 6, but that is also a can of worms...
but since this is what slangs will be, Perl 6, I go that way 15:44
I need some brain cells of jnthn++ though for that task :o)
15:46 eternaleye joined 15:54 eternaleye left 15:55 anaeem1_ left 15:56 SamuraiJack left 16:04 thou joined
japhb Is perl6-debug-m known broken right now? I get 'Start argument to substr out of range. Is: -1, should be in 0..0' no matter how I use it (as a reply, with a -e '...' script, with a file script) 16:04
16:07 Khisanth joined
timotimo ... we ought to write tests that make sure stuff works in the debug frontend ... 16:07
japhb Oh, now *that's* interesting. This is what `perl6-debug-m -v` prints: This is perl6 version built on MoarVM version 2014.05-2-gb1add28
Note the missing perl6 version.
timotimo could be worse :)
japhb I'm guessing someone forgot to update the debug front end when they changed how versions and such are picked up. 16:08
16:08 thou left
timotimo i *think* the -v piece of the debug program actually comes from the backend rather than the frontend 16:08
japhb timotimo: I think that (or a related bug during the process var refactoring) is why perl6-debug-m is failing.
timotimo: But 'perl6-m -v' works fine. 16:09
16:10 eternaleye joined
timotimo okay; weird! 16:11
can you get a --ll-exception for the substr error?
16:16 molaf_ joined 16:19 molaf left 16:23 usernotexists left, sqirrel_ joined
masak Dijkstra was kind of a douche sometimes. he quotes another source, which contains the phrase "[...] to suggest some alternate avenues [...]", and he annotates "alternate" with '[meant is "alternative" EWD]', as if "alternate" weren't a workable synonym meaning "substitute". 16:30
japhb timotimo: There's a long dump if you do something in the REPL? 16:34
s/"'"//
s/'?'// 16:35
Sigh.
timotimo er ... yeah
japhb timotimo: Anyway. If you run 'perl6-debug-m' and then when the REPL comes up, do 'say "boo"', you should see the big backtrace 16:36
timotimo reinstalls everything ...
16:42 zakharyas left 16:48 eternaleye left, virtualsue left 16:50 eternaleye joined 17:08 denis_boyun___ left 17:24 sqirrel_ left 17:25 sqirrel_ joined 17:43 hoverboard joined 17:51 virtualsue joined 17:52 thou joined 17:53 rurban left 17:56 thou left 17:57 rindolf left 17:58 beastd joined 18:01 sqirrel_ left, anaeem1 joined 18:14 hoverboard is now known as moistcherry 18:15 pmurias joined 18:20 moistcherry is now known as hovercraft 18:29 sqirrel_ joined 18:31 Rotwang left 18:52 darutoko left 18:53 rurban joined 18:58 rurban left
masak timotimo: *EVERYTHING*??? 19:06
19:08 denis_boyun_ joined 19:10 ivanshmakov is now known as ivanshmakov| 19:12 bjz joined, ivanshmakov joined 19:14 hovercraft is now known as hoverboard, sqirrel_ left 19:16 ivanshmakov left, ivanshmakov joined
timotimo masak: it is taking a while 19:19
19:19 itz left
timotimo waiting for the universe to cool down 19:19
19:21 vendethiel left, vendethiel joined 19:24 ivanshmakov| left, Rotwang joined 19:25 rurban joined, pdcawley left 19:27 pdcawley joined
masak yeah, tell me about it. 19:29
19:39 anaeem1 left 19:40 thou joined 19:42 jack_rabbit joined 19:45 thou left 19:51 rurban left 19:57 dmol left
dalek nda/CPAN: ece2c62 | (Tobias Leich)++ | lib/Panda/Fetcher.pm:
allow to fetch http resources

We need this to fetch MIRRORED.BY to know what servers are best to query, but we also need to fetch the p6dists.json to know what distributions are out there, waiting for us.
20:03
nda/CPAN: 5d6a864 | (Tobias Leich)++ | / (3 files):
add probe-mirrors target that pings CPAN servers

Pinging all 263 CPAN servers takes up to three minutes since we only ping one server at a time. The good thing is that we only need to do that once.
20:03 anaeem1 joined 20:07 rurban joined
vendethiel FROGGS: any reason to use `http '://'` instead of `''` ? 20:08
FROGGS no, not really 20:12
I think I did it because I first thought of / \w+ '://' / 20:14
plan for tomorrow: let this also spit out information about the source (gihtub/CPAN): 20:15
$ panda search native
NativeCall * Call native libraries
GTK::Simple * Simple GTK 3 binding using NativeCall
gnight &
20:22 virtualsue left, kaare_ left 20:34 user3 joined 20:35 kivutar left, user3 left 20:37 kivutar joined 20:41 Rotwang left 20:43 virtualsue joined 20:44 dmol joined 20:45 bjz_ joined 20:47 bjz left, bjz joined, bjz_ left 20:48 dmol left 20:55 rurban1 joined 20:58 rurban left
timotimo yays :) 21:02
21:03 rurban joined 21:05 rurban1 left
Ulti is there a way to do in place sorting of a list in Perl6 ? 21:07
tadzik sort of :)
(ha ha, get it? sort! PFFF)
Ulti :Z
colomon is there?!
tadzik m: my @a = <2 5 1 4>; @a.=sort; @a.perl.say
camelia rakudo-moar 7e0940: OUTPUT«Array.new("1", "2", "4", "5")␤»
Ulti and that acts on the list in RAM rather than creating a temporary one? 21:08
moritz it's not really in-place yet 21:09
colomon Ulti: no
Ulti okedoke
I wont worry about it for now then
tbh with statistics you can just subsample large data anyway 21:11
so I can just have a :sample(1000) adverb or something 21:12
also I notice 'rand' goes all the way down to the back ends so is there a spec for how random rand is? 21:15
colomon not that I know of 21:19
21:19 kivutar left, guru joined
colomon probably usually it's as random as C's standard library is 21:19
21:20 guru is now known as Guest1029
colomon though I seem to recall that the bigint rands we use usually go to an underlying crypto module. 21:20
21:20 Guest1029 is now known as ajr_, pippo_ joined 21:21 pippo left, dmol joined 21:23 rurban1 joined
Ulti tbh I'm not sure what is random enough for most statistical methods 21:26
21:26 rurban left
Ulti I usually use a mersenne twister implementation 21:27
which is the default in R so probably random enough :S 21:28
21:29 thou joined 21:33 molaf_ left, thou left 21:35 rurban1 left
colomon m: say [1, 2, 3] 21:41
camelia rakudo-moar 7e0940: OUTPUT«1 2 3␤» 21:42
colomon m: say [1, 2, 3].Str
camelia rakudo-moar 7e0940: OUTPUT«1 2 3␤»
colomon m: say [1, 2, 3].perl
camelia rakudo-moar 7e0940: OUTPUT«[1, 2, 3]␤»
colomon m: my @a = 1, 2, 3; say @a 21:43
camelia rakudo-moar 7e0940: OUTPUT«1 2 3␤»
colomon m: my @a = 1, 2, 3; say @a.perl
camelia rakudo-moar 7e0940: OUTPUT«Array.new(1, 2, 3)␤»
colomon scratches his head
21:43 rurban_ joined
jnthn [...] flattans, an @a doesn't, thus the different .perl output 21:44
21:45 rurban joined 21:46 bjz_ joined, martinzaremba joined, dmol left
colomon is finding it surprisingly hard to just get a nice [1, 2, 3] output 21:47
21:47 bjz left, aindilis` left
Ulti oh one quick question is there a ncie way to unpack kv from a list of pairs in a for loop? I was thinking: for $bag.pairs.sort -> $k, $v {} but you get $k as the Pair object 21:50
colomon Ulti: there is, but I can never remember the syntax 21:51
21:53 telex left
jnthn -> (:$key, :$value) { } 21:53
21:54 telex joined 21:56 pippo_ left
Ulti neat thanks 21:56
jnthn np :) 21:59
martinzaremba hi guys 22:08
lizmat Ulti: alternately you could do: 22:10
yoleaux 13:48Z <FROGGS> lizmat: yeah, would be nice to have a roundtripable @*INC
lizmat m: for <a b b c c c>.Bag.pairs.sort>>.kv -> $k, $v { say "$k = $v" }
camelia rakudo-moar 7e0940: OUTPUT«a = 1␤b = 2␤c = 3␤»
lizmat as .kv also works on a Pair
22:12 rindolf joined, pmurias left 22:16 martinzaremba left 22:17 martinzaremba joined, beastd left 22:19 martinzaremba left 22:20 pdcawley left, pdcawley joined
dalek kudo/nom: 6cd50fa | (Elizabeth Mattijsen)++ | src/core/Process.pm:
Implement $*USER and $*GROUP (not yet specced)

In numeric context, they provide uid/guid and in string context they provide the user's name and group. Works by executing "id" where available, but only when $*USER and $*GROUP are actually used.
22:23
kudo/nom: 57555c8 | (Elizabeth Mattijsen)++ | src/core/Process.pm:
Make $*EXECUTABLE and $*EXECUTABLE_NAME immutable
lizmat $ 6 'say ~$*USER; say +$*GROUP; say $*USER' 22:24
liz
20
liz (501)
Ulti -> (:$key, :$value) {} didn't work out :S
lizmat taking masak's advice from earlier today
22:24 spider-mario left
dalek ecs: fb4171b | (Elizabeth Mattijsen)++ | S28-special-names.pod:
Spec $*USER, $*GROUP, $*EUSER, $*EGROUP
22:30
jnthn r: my @a = a => 1, b => 2; for @a -> (:$key, :$value) { say "$key = $value" }
camelia rakudo-{parrot,jvm,moar} 7e0940: OUTPUT«a = 1␤b = 2␤»
jnthn Ulti: That bit in isolation seems to work, so maybe the problem is elsewhere? 22:31
Ulti r: my $bag = bag <1 2 2 3 4>; for $bag.pairs.sort -> (:key, :$value) { say "$key=$value" } 22:32
camelia rakudo-{parrot,jvm,moar} 7e0940: OUTPUT«===SORRY!=== Error while compiling /tmp/tmpfile␤Malformed parameter␤at /tmp/tmpfile:1␤------> ag <1 2 2 3 4>; for $bag.pairs.sort -> (⏏:key, :$value) { say "$key=$value" }␤ expecting any of:␤…»
Ulti oops 22:33
r: my $bag = bag <1 2 2 3 4>; for $bag.pairs.sort -> (:$key, :$value) { say "$key=$value" }
camelia rakudo-{parrot,jvm,moar} 7e0940: OUTPUT«1=1␤2=2␤3=1␤4=1␤»
Ulti weird
jnthn I'm curious what sort does on pairs... 22:34
Ulti especially as the >>.kv version works
its sorted by key
lizmat good night, #perl6! more tests tomorrow :-) 22:35
Ulti night lizmat
on the upside I now have code which appears to calculate the median of a Bag :S 22:36
22:37 rurban left 22:41 anaeem1 left
jnthn refrains from making a mean pun... 22:41
22:44 dmol joined 22:45 BenGoldberg joined
Ulti I'm not in the mode for puns 22:45
jnthn enables sleep mode :) 22:48
Should have tuits again from tomorrow evening
'night
timotimo hmm, this week's p6weekly will probably be dominated entirely by Eleven and lizmat's work 22:49
unless somebody swoops in and does some more interesting stuff ... *hint* *hint* 22:52
timotimo will spend much of tomorrow on le road 22:55
22:57 denis_boyun_ left 23:03 kivutar joined 23:04 dmol left 23:05 rurban joined 23:10 jack_rabbit left 23:12 Sqirrel left 23:14 Sqirrel joined 23:17 thou joined 23:20 martinzaremba joined 23:21 kivutar left 23:22 thou left 23:31 martinzaremba left 23:44 pdcawley left 23:47 pdcawley joined