Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2012-11-22

Perl 6 | Reference Documentation | Rakudo

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:00 Araq joined #perl6
00:07 Araq left #perl6
00:23 lue r: my %h = 1=>(2,3); for %h.keys -> $g {say "$g" for %h{$_};}; # bad warning message?
00:23 p6eval rakudo bf472b: OUTPUT«use of uninitialized variable $key of type Any in string context  in block  at /tmp/TPsjKo5l6M:1␤␤1␤»
00:25 huf joined #perl6
00:26 lue (really tripped me up considering $g was originally named $keys in my code and I couldn't figure out why rakudo seemed to be dropping the s)
00:31 larks joined #perl6
00:32 fgomez joined #perl6
00:36 Vlavv_ joined #perl6
00:57 whiteknight joined #perl6
01:00 fgomez joined #perl6
01:02 TimToady lue: um, what do you think is setting $_ anywhere?  But yes, it seems to be a suboptimal leakage of implementation details into the error message
01:02 anuby joined #perl6
01:02 lue TimToady: The use of %h{$_} was an error on my part and I know that. I was complaining about the warning I got from it.
01:06 * lue &
01:11 hypolin joined #perl6
01:22 stanley joined #perl6
01:48 grondilu joined #perl6
01:48 grondilu rn: say <1/3>.WHAT
01:48 p6eval niecza v22-36-g19fa03a: OUTPUT«Rat()␤»
01:48 p6eval ..rakudo bf472b: OUTPUT«Str()␤»
01:49 grondilu ?  Rakudo used to deal with Rat literals better than that.
01:50 grondilu rn: sub f(Rat $) {};  f <1/3>;
01:50 p6eval rakudo bf472b: OUTPUT«===SORRY!===␤CHECK FAILED:␤Calling 'f' will never work with argument types (str) (line 1)␤    Expected: :(Rat )␤»
01:50 p6eval ..niecza v22-36-g19fa03a:  ( no output )
02:13 larks joined #perl6
02:26 marloshouse_ joined #perl6
02:33 ifim left #perl6
02:36 kurahaupo joined #perl6
02:45 cognominal joined #perl6
02:56 gootle joined #perl6
03:04 perigrin joined #perl6
03:32 cognominal joined #perl6
03:40 cognominal_ joined #perl6
03:47 grondilu joined #perl6
03:48 grondilu why does parrot does not upgrade to 4.10.0 when I run 'perl Configure.pl --gen-parrot' ?
03:50 grondilu I'd like the new version because of '+ Fixed record separator bug on io handles' and I happen to have noticed this bug recently on this very channel
03:51 [Coke] because NQP is still pointing at 4.4
03:51 [Coke] (see nqp's tools/build/PARROT_REVISION)
03:54 grondilu ok
04:00 [Coke] (so, if you bump that in your local copy of nqp, that'll let you test out the new version
04:05 grondilu yeah I did that.  It's compiling right now
04:06 * grondilu likes to have the very latest version of software
04:32 xenoterracide are there any convention for interface (e.g. like java interface) naming?
04:33 xenoterracide yet?
04:34 sorear Callable, Numeric, Positional, Associative, Stringy
04:34 sorear they're all capitalized adjectives
04:35 cognominal__ joined #perl6
04:36 xenoterracide hmm
04:37 xenoterracide but what will happen for things outside of core I wonder
04:37 * xenoterracide thinking about the Digest Interface
04:38 xenoterracide also I've decided I'm not fond of Top level naming outside of core
04:38 xenoterracide too much namespace pollution
04:39 xenoterracide I wonder if it would be bad to start a convetion of prefix Interface::
04:39 HarryS joined #perl6
04:40 benabik I don't see a reason to separate them from their normal namespaces.
04:40 cognominal__ joined #perl6
04:42 xenoterracide well one reason would be so that interface would be separate from implementations
04:42 xenoterracide I don't know that it should be in /core/ but outside of core perhaps
04:44 * xenoterracide shrugs
04:44 xenoterracide thinking outloud for opinions
04:44 xenoterracide also thinking of the context of what if p6 someday has as many modules as CPAN has now
04:47 xenoterracide I'd almost like to have top level namespace registry that things not core can't add to.  so nobody ends up creating just Facebook.pm it'd have to be like WWW::Facebook
04:49 breinbaas joined #perl6
04:54 xenoterracide also is Digest.pm even needed in p6? all it is, is a factory
04:55 xenoterracide seems like supplying the Digest:: namespace interface is more important
04:57 lue xenoterracide: I'm not sure I see much of a threat in naming conflict by modules using top-level namespaces. Several CPAN modules do such a thing as well, notably CGI.pm .
04:58 perigrin joined #perl6
04:58 xenoterracide oh I'm not sure it's so much of a threat... as I do enjoy when there's a few top level namepsaces making things easy to find
04:59 TimToady I vote for "Fred" as a top-level namespace
04:59 * lue thinks there are some modules that would only fit under NotCore::
05:00 lue xenoterracide: when you said: "I wonder if it would be bad to start a convetion of prefix Interface::", is "Interface" a literal or a placeholder? ("Interface" or $Interface ?)
05:01 xenoterracide lue: literal
05:02 grondilu yeah using parrot 4.10.0 did indeed fix the record separator issue while opening text files
05:04 xenoterracide TimToady: actually I had considered that perhaps usernames should also be tld, so XENO::Exception (is perhaps better than the Class::Exception Exception::Class Exception Exception::Base Throwable, etc that some area's of cpan have devolved to, esp for the uninformed consumer
05:04 TimToady username can already come into the identity via "auth"
05:04 benabik Rather than tying the developer's hands like that, didn't p6 extend use...  right, auth.
05:06 lue Of course. One of about two things perl6 implementations still don't (really) handle yet concerning the use statment. (IIRC, the other is importing certain things from a module. "Arglist case of use NYI" or something like that)
05:06 benabik In S11, under Versioning
05:07 * xenoterracide goes back to doing something that's productive
05:09 aindilis joined #perl6
05:11 hypolin joined #perl6
05:17 perigrin joined #perl6
05:24 perigrin joined #perl6
05:25 telex joined #perl6
05:28 diakopter xenoterracide: ouch?
05:28 kaleem joined #perl6
05:29 birdwindupbird joined #perl6
05:57 telex joined #perl6
05:57 GlitchMr joined #perl6
06:21 kurahaupo joined #perl6
06:23 fgomez joined #perl6
06:36 rurban_ joined #perl6
06:38 Tabrenus joined #perl6
06:54 araujo joined #perl6
06:58 xenoterracide diakopter: ouch?
07:13 xenoterracide how would I put in the method signature, requires a function be passed?
07:19 lue r: sub needsub(&code) { say "OK!"}; needsub(&say); needsub(&open); needsub(25);
07:19 p6eval rakudo bf472b: OUTPUT«===SORRY!===␤CHECK FAILED:␤Calling 'needsub' will never work with argument types (int) (line 1)␤    Expected: :(&code)␤»
07:19 lue r: sub needsub(&code) { say "OK!"}; needsub(&say); needsub(&open);
07:19 p6eval rakudo bf472b: OUTPUT«OK!␤OK!␤»
07:24 lue xenoterracide: does that work?
07:27 cibs joined #perl6
07:48 Kharec joined #perl6
07:48 FROGGS joined #perl6
07:52 FROGGS good yawnin'
07:56 moritz \o
07:56 moritz FROGGS: has anybody given you commit access to the rakudo repo?
07:57 FROGGS moritz: no, masak said I should submit the contributor license first, which I signed yesterday but need to send
07:57 moritz FROGGS: but without it, it'll be hard to make a release :-)
07:57 FROGGS moritz: no commit bit to nqp either
07:58 moritz I'll try to organize a commit bit for you
07:58 moritz oh, nqp commit bit is easy to do
07:58 FROGGS k, I'll try to figure out the mail address to send the thingeny as a scan
07:59 moritz FROGGS: you now have nqp commit bit
07:59 moritz *a
07:59 FROGGS or I just put it in real hardware mail when I go to work
07:59 FROGGS cool, thanks
08:01 moritz pmichaud: ping
08:02 Su-Shee good morning everyone.
08:02 tadzik good morning
08:03 moritz \o Su-Shee, tadzik
08:04 FROGGS morning Su-Shee, tadzik
08:07 xenoterracide lue: possibly testing
08:09 domidumont joined #perl6
08:13 xenoterracide I have to use Role; before I can do does role? seems like something that does should imply
08:13 xenoterracide well I suppose use is loading the file
08:13 tadzik what happens if you try? :)
08:13 xenoterracide it complains
08:14 xenoterracide Unable to parse $*PKGDECL definition at line 6, near "does Diges"
08:14 moritz 'does' can't load the role for you
08:14 moritz 'does' is just a normal trait
08:15 moritz and it works on the object it receives, not on some name
08:15 brrt joined #perl6
08:16 moritz but if the role isn't loaded, the name doesn't map to any object, so the trait can't work on it
08:17 xenoterracide right...
08:18 xenoterracide too much typing
08:18 xenoterracide too much typing of the same thing
08:19 xenoterracide although it honestly isn't exactly the same thing, in practice it's common class/role/module maps to file right now
08:19 xenoterracide would seem like it could try load from the file
08:20 moritz I just explained that it can't
08:22 xenoterracide well I suppose that I'll end up writing does ( require 'Role' ) or some suchness a lot
08:27 domidumont joined #perl6
08:33 xenoterracide multi method add( $data           ) { ... } # so this is how I'd write for a required interface right?
08:33 sorear you don't need "multi"
08:33 moritz you'd write it without the multi
08:33 xenoterracide I did  because I had 2 different signatures for that
08:34 sorear ok
08:34 sorear in general, avoid multi if you only have one signature, because you're asking the runtime to do more work
08:34 xenoterracide but it doesn't throw any exceptions if the interface isn't iplemented
08:34 xenoterracide sorear: doesn't not using multi prevent extension?
08:35 sorear no
08:35 sorear you can still override a non-multi method in subclasses
08:36 xenoterracide can I add another method as multi in a runtime applied role? or a subclass (as opposed to overriding)
08:36 sorear xenoterracide: can you paste an example of the code that fails to check for required methods?
08:36 xenoterracide also providing these doesn't cause any kind of exception if an actual implementation isn't provided
08:37 sorear xenoterracide: there should be a compile time erorr if an implementation isn't provided.  *please* paste example code so we can find the bug
08:38 xenoterracide http://privatepaste.com/09eaa29e38
08:39 domidumont joined #perl6
08:39 sorear oh... I see what's going on
08:39 sorear { ... } allows you to require a *name*
08:39 sorear trying to require multis isn't going to fly
08:40 sorear you're treating multis as if they were the same as Java/C# method overloads
08:40 xenoterracide seems like the right idea? and the obvious thing?
08:40 sorear they're not.
08:41 xenoterracide why?
08:41 sorear because dynamic typing
08:42 xenoterracide this is a good thing?
08:42 xenoterracide p6 seems a little less dynamic
08:42 sorear some people like it, some don't, and some don't care
08:42 sorear p6 is a little less dynamic, but mostly with subs
08:43 xenoterracide it seems that since everything is an object that the types are more or less some kind of static.
08:43 sorear with methods, the reality of subclassing makes it impossible for the compiler to resolve method calls at compile time
08:43 xenoterracide though I am probably an idiot
08:44 xenoterracide wait so why would it work if they weren't multi
08:44 sorear rakudo and niecza track requiredness at the granularity of "Digester requires 'digest' and 'add'"
08:45 sorear multi signatures... because of constraints, they can't be compared in general
08:45 sorear so we aren't sure what it would mean to require one
08:46 xenoterracide compare the 2 signatures?
08:46 sorear if you had "multi method foo(Int $x where * > 0) { ... }", would "multi method foo(Int $y where * >= 1) { }" match it?
08:46 xenoterracide or perhaps even if ... just literally translate to add or digest
08:46 xenoterracide I'd say no
08:47 xenoterracide they are not exactly equivalent
08:47 sorear what if the spacing or paretheses are different?
08:47 sorear where do you draw the line?
08:48 xenoterracide at some point does it get normalized?
08:48 xenoterracide like when it hits bytecode
08:48 FROGGS moritz: going to mail office now...
08:48 FROGGS see ya'all at work
08:49 xenoterracide I would think if they compile to the same bytecode they are the same
08:49 sorear multis tend to work exactly as if you made a single giant method that looked at its argument types and decided which block of code to run
08:49 arnsholt xenoterracide: The where constraints are essentially small programs. Thus, deciding which of two constraints is more specific is an undecidable problem in the general case
08:50 xenoterracide hmm
08:50 sorear xenoterracide: I'm fearful of introducing anything that would depend on compiler fine details, e.g. constant folding changing 2+2 into 4
08:50 arnsholt Which means that it's a good idea to not try to be too clever, since it's bound to break horribly
08:50 sorear because then it's too easy to write unportable code
08:50 sorear and when we change the file details we might break stuff
08:50 xenoterracide hmm... well like I said I'm probably an idiot
08:51 xenoterracide but at some point it seems like your going to have unobvious behavior
08:51 sorear we're all idiots here...
08:52 sorear I'm sure there's an obvious and easy solution that I'm just too stupid to find :D
08:52 xenoterracide is the where clause the biggest problem? or are there a bunch of other things in the signature?
08:53 xenoterracide only asking because if it were me I'd simply compare the std parts of the arguments, types and variables
08:54 xenoterracide ignore any where's and document that
08:55 sorear could work.  still makes me uneasy because of liskov
08:55 xenoterracide explain
08:55 xenoterracide I'm probably missing something
08:55 sorear if an implementation has more constraints than the role, it doesn't really implement the requirements
08:56 moritz crippling a tool to prevent possible unobvious behavior isn't a good idea
08:56 sorear o/ moritz
08:57 sorear also, xenoterracide, nitpick on terminolgy
08:57 sorear we use "argument" to mean the actual runtime value
08:57 sorear the thing inside the signature is called a "parameter"
08:58 xenoterracide I'm not sure the current isn't crippled in some way? if you can't enforce the method signature then you aren't really enforcing an interface, just because 2 objects do 'add' doesn't mean it'll work, you can end up with an implementation that has only a similar interface
08:58 xenoterracide ok, I'll try to remember that
08:59 sorear yes, I agree the current way is bad
08:59 sorear I don't want to change it to another bad way, because people will confuse change for progress and think it works
09:00 xenoterracide hmm
09:00 kresike joined #perl6
09:01 kresike hello all you happy perl6 people
09:01 xenoterracide how do multi methods know between 2 different where's now?
09:01 xenoterracide how does it figure that out?
09:02 sorear they don't
09:02 wamba joined #perl6
09:02 sorear there is nothing in current perl 6 which relies on detecting if two signatures are the same
09:03 lue blog post (and a picturesque one too)!    https://rdstar.wordpress.com/2012/11/22/the-rakudo-codebase-visualized-partially/
09:04 * lue --sleep &
09:04 xenoterracide sorear: so... if you have 2 signatures with the only difference being the where clause it chooses at random?
09:05 sorear xenoterracide: no, it tries all of them and if more than one succeeds, it picks the first
09:05 sorear for cases other than where clauses, multiple success is an error
09:06 sorear it keeps a list of all definitions
09:06 sorear no attempt is made to detect duplicates in the list
09:06 xenoterracide this where clause is almost starting to sound like a badish idea for being part of the signature
09:07 xenoterracide I'm just saying it sounds slow, and like it may cause unexpected behavior
09:08 xinming joined #perl6
09:08 xenoterracide I think if it were me I'd consider taking the where clause out of the signature and make it illegal to have 2 multi methods that differ only in where's
09:09 sorear xenoterracide: you seem to be under the impression that methods are stored in a hash indexed by name+signature
09:10 xenoterracide not necessarily under that impression but sound efficient
09:10 xenoterracide sounds*
09:10 sorear that's not how it works.
09:10 xenoterracide how's it work? if you don't mind my asking
09:10 xenoterracide I don't want to take up too much time
09:11 sorear when you have multi methods, a "dispatcher" method is created to wrap them
09:11 sorear the method dispatch table is hashed only on name.  for normal methods it goes directly to your code, for multis it goes to the dispatcher
09:11 sorear the dispatcher keeps a list of all the registered candidates
09:12 sorear when called, it (abstractly) tries them all and invokes the first that works
09:12 brrt sorear...
09:12 sorear when where-clauses aren't used, this system can be optimized to use tables in the second pass
09:12 brrt could we make a hash of type signatures?
09:12 brrt i.e, signature types
09:13 sorear brrt: suppose the runtime value is 5.  do you look under (Int), (Real), (Any), (Numeric), (Mu), or (Cool) ?
09:13 diakopter well, it wouldn't catch inherited
09:15 xenoterracide hmm
09:17 orafu joined #perl6
09:17 brrt sorear, so, no :-)
09:18 sorear C++, C#, Java, and P6 use essentially the same algorithm for this...
09:18 fhelmberger joined #perl6
09:18 sorear except that one of those does it using runtime types in the dispatcher, while the other three do it in the compiler using declared types
09:19 sorear maybe there is room for using gradual types in p6 to compile-time-resolve method lookups; that's something I want to explore
09:21 xenoterracide sorear: ok so lets say that we still have to do runtime try its... is there any reason though that we couldn't disallow the situation of the signature only differing in where's and compile time check signatures on that.
09:21 xenoterracide that would allow compiletime muli method signature checks
09:22 xenoterracide also wouldn't the runtime check for an exact type first? meaning it 5 is an Int then it'll match Int
09:23 sorear xenoterracide: because having computational dispatch is occasionally useful
09:23 xenoterracide I'm worried about the often idiot
09:23 FROGGS joined #perl6
09:24 xenoterracide this seems like something that the not yet invented Perl6::Critic is going to complain aobut
09:25 xenoterracide I like powerful things
09:25 xenoterracide which is why I like multimethods
09:25 sorear subtypes and constants both generate constraints internally
09:25 xenoterracide but it seems like if I had to trade the occasionally powerful for the strict interfaces
09:27 xenoterracide the interfaces would win... the are more useful... though of course it's possible this is simply not a possibility.
09:27 xenoterracide sorear: thanks for explaining it all to me though
09:27 brrt i think you can do compile-time multi signature checking
09:28 brrt not sure about niecza, but it should be (relatively) doable in NQP
09:28 brrt the 'problem' or difficulty is mostly about the cases when you can't
09:29 brrt i.e. runtime-construction of parcel, sent to a multi
09:29 brrt or, 'unknown object passed in', that is also a popular one
09:30 brrt and i'm not sure whether compile-time-type-tracing is very realistic
09:30 sorear brrt: we have no ability to trace types negatively.
09:30 brrt run time type tracing is, however; going the v8 route
09:30 brrt sorear, why not?
09:31 sorear given 'my Int $x', $x might actually contain an object which multiply inherits from Array and Int
09:31 sorear so we cannot statically rule out the possibility that $x could match an Array parameter
09:31 brrt you know based on assignment what types it will take
09:32 brrt unless, well, you don't
09:32 sorear you don't know that until CHECK time
09:32 sorear and eval screws with everything
09:32 brrt yes, eval does
09:33 brrt so runtime tracing and speculative optimisation is the only way to go?
09:33 moritz you can know if you close the Array and Int classes
09:33 sorear moritz: not legal until CHECK time
09:33 brrt wait, good point, how is augment implemented anyway?
09:34 sorear brrt: Evil.
09:34 * brrt thought p6 classes were closed
09:34 sorear p6 classes are open during parse and closed at CHECK time *if* there is a use oo :closed; declaration in the main program
09:35 sorear if there is no such declaration, they stay open forever
09:35 brrt well, what about doing it the other way arround
09:35 sorear also this is only the main program.  modules, including the setting, are not allowed to close classes under any circumstance
09:35 brrt what, why not?
09:35 xenoterracide close classes?
09:35 sorear because S12 says so.
09:36 sorear and I don't want to step on the toes of whoever wrote that into S12
09:36 sorear I bet it was Larry
09:36 brrt well, this is a language in design isn't it
09:36 sorear not really
09:37 sorear the spec has been quasi-frozen for about a year
09:37 brrt hmm
09:37 sorear nothing changes these days without a *huge* fight
09:37 moritz well, discussing it doesn't imply stepping onto any toes
09:37 moritz sorear: I can't quite agree
09:37 brrt there is a way arround this
09:37 moritz sorear: we've had major changes to S16 without much fights
09:37 brrt instead of 'opening the class' and making it all writable and stuff
09:38 brrt we can also - in the scope of those that implement it - replace the symbol to a class with a derived one
09:39 brrt augment Foo { } would then mean, 'create a class extending Foo, and place it as a lexical called Foo'
09:39 PacoAir joined #perl6
09:39 xenoterracide oh this is nice
09:39 sorear brrt: you can already do 'my class Foo is OUTER::Foo { ... }'
09:39 xenoterracide so if you do method foo { ... } it'll require
09:39 xenoterracide but of course multi method foo { ... } can't satisfy
09:40 sorear brrt: your proposed change would be useless for everything I currently use augment for
09:40 brrt sorear, that is quite enough for augmenting, isn't it?
09:40 brrt ok, where do you use augment for?
09:40 sorear augment class Any { method to_json() { ... } }; say 5.to_json
09:40 sorear that kind of thing
09:41 xenoterracide basically like moose p6 compile time method checking is useless
09:41 brrt i don't think it does
09:42 xenoterracide because the only way to do it is with single methods and then if the implementer chooses to want multimethods they can't
09:42 * moritz doesn't quite understand that argument
09:42 sorear xenoterracide: multimethods are not part of the public API of a class
09:42 brrt because i have just installed a new Any lexically
09:42 sorear xenoterracide: the user of a class does not know whether it is implemented using multimethods or regular methods
09:42 brrt 5 -> Int -> … -> My Lexical Any -> Real Any -> … -> Mu
09:42 moritz augmenting isn't lexical
09:42 cosimo joined #perl6
09:42 brrt it should be
09:43 brrt :-)
09:43 moritz if you want something lexical, just use a sub
09:43 sorear it would be useless if it were.  reread what I wrote
09:43 moritz if you want code available in a lexical scope, a subroutine is exactly the right tool for the job
09:43 kaleem joined #perl6
09:44 xenoterracide http://privatepaste.com/928e3e83a6
09:44 brrt hmm
09:45 xenoterracide that throws an exception
09:45 sqirrel joined #perl6
09:45 xenoterracide Method 'add' must be implemented by Digest::Test because it is required by a role
09:45 brrt i guess you are right in a way
09:46 moritz xenoterracide: in the implementing class,  write   proto method add(|) {*}   and then your multi candidate(s)
09:46 FROGGS does somebody get these fails too? http://smolder.parrot.org/app/projects/report_details/32410
09:46 FROGGS t/spec/S32-io/IO-Socket-INET.t
09:47 moritz FROGGS: yes
09:47 FROGGS hmm, I dont
09:47 dalek Perlito: 589722e | (Flavio S. Glock)++ | / (6 files):
09:47 dalek Perlito: Perlito5 - js2 - fix context in method calls
09:47 dalek Perlito: review: https://github.com/fglock/Perlito/commit/589722e405
09:47 moritz I don't get them with newest parrot
09:47 moritz FROGGS: comment out the file in t/spectest.data for the release
09:47 FROGGS k
09:47 xenoterracide moritz:
09:47 xenoterracide Cannot call 'add'; none of these signatures match:
09:47 FROGGS IMO I still use parrot 4.4.0
09:48 xenoterracide oh wait
09:48 xenoterracide right because the signatures doesn't include any
09:50 xenoterracide FROGGS: why is it your opinion?
09:50 FROGGS because I wasnt sure, now (after looking) I am ;o)
09:52 FROGGS ohh, maybe I dont get this error because my parrot wasnt compiled against libISU
09:52 FROGGS ICU
09:52 xenoterracide so the spec is functionally frozen until ... what? a working implementation? just in general
09:52 moritz it's not functionally frozen
09:53 FROGGS I believe a spec is never frozen
09:53 diakopter never frozen *for you*. other people perceive frozen specs all the time
09:54 xenoterracide specs should freeze at some point, but then unfreeze later
09:57 xenoterracide anyways, http://privatepaste.com/928e3e83a6 back to this, does this seem like a sane preliminary interface for Digest? just wondering if I'm on the right-ish track, if anyone has feedback
09:58 dakkar joined #perl6
09:59 diakopter I don't know about the API, but I like the loading/instantiating thing. /me learned something new
10:00 diakopter ^ literally means "don't know", as in "no thoughts/opinion" :)
10:01 xenoterracide well I'm mostly stealing the API from the current digest, but I was trying to implement a strict interface module in digester for digest implementers
10:02 xenoterracide diakopter: I aim impatiently awaiting the ( require $module ).new syntax that should be coming
10:03 diakopter does it work if you make it say my Digester $impl
10:04 xenoterracide probably not, can you use role's that way?
10:04 diakopter I thought you could
10:04 xenoterracide maybe it does? idk still experimenting
10:07 xenoterracide diakopter: I guess in theory that should work ultimately, I need to do a role check in the constructor
10:08 telex joined #perl6
10:17 xenoterracide diakopter: yeah it works
10:21 xenoterracide now where was that doc on specifying a return type in the method sig
10:25 sorear has Int method foo() { }
10:25 sorear method foo(--> Int) { }
10:25 sorear these are identical
10:25 sorear don't let the placement of parens mislead you
10:27 moritz method foo() returns Int { }
10:27 rindolf joined #perl6
10:28 xenoterracide hmm... tried that last, let me guess, no bueno multi?
10:28 sorear no return type overloading if that's what you mean...
10:28 diakopter r: class A { has Int method foo(--> Int) { } }
10:28 p6eval rakudo bf472b:  ( no output )
10:29 xenoterracide I just meant syntax, it's been complaining for me
10:29 sorear how are you trying?
10:29 diakopter r: class A { has Str method foo(--> Int) { } }
10:29 p6eval rakudo bf472b:  ( no output )
10:30 xenoterracide sorear: oh nvm I figured it out, I was forgetting to use the role in the class
10:31 diakopter r: class A { has Str method foo(--> Int) { return "hi" } }; say A.foo
10:31 p6eval rakudo bf472b: OUTPUT«Type check failed for return value; expected 'Int' but got 'Str'␤  in method foo at /tmp/XV4UgBdCA9:1␤  in block  at /tmp/XV4UgBdCA9:1␤␤»
10:31 diakopter r: class A { has Int method foo() { return "hi" } }; say A.foo
10:31 p6eval rakudo bf472b: OUTPUT«hi␤»
10:32 PacoAir joined #perl6
10:33 diakopter phenny: ask masak see VBBHREUVND in the blockag. bug?  has Int method
10:33 phenny diakopter: I'll pass that on when masak is around.
10:35 xenoterracide I <3 .method and then constantly type ->method, wishing for error to say... no this is not perl5
10:35 xenoterracide which it basically does
10:35 diakopter std: Int->foo
10:35 p6eval std d38bbd0: OUTPUT«[31m===[0mSORRY![31m===[0m�Unsupported use of -> as postfix; in Perl 6 please use either . to call a method, or whitespace to delimit a pointy block at /tmp/fTk7_Mcwr1 line 1:�------> [32mInt->[33m�[31mfoo[0m�Parse failed�FAILED 00:00 41m�»
10:37 xenoterracide r: die "{ &?ROUTINE.name } unimplemented"
10:37 p6eval rakudo bf472b: OUTPUT«No such method 'name' for invocant of type 'Nil'␤  in block  at /tmp/6fnuwT1JUi:1␤␤»
10:37 xenoterracide aww
10:37 xenoterracide lol
10:37 moritz you're not inside a routine there
10:38 xenoterracide yeah guess not,
10:38 xenoterracide anyways, love that bit
10:40 xenoterracide not having to hardcode the name ftw
10:43 moritz aye, that's quite neat
10:44 xenoterracide die "{ self.WHAT }.{ &?ROUTINE.name } unimplemented";
10:45 xenoterracide use of uninitialized value of type Digest::Test in string context  in method digest at lib/Digester.pm6:12
10:45 xenoterracide weird
10:45 xenoterracide seems to be failing on the call to WHAT
10:45 arnsholt xenoterracide: self.WHAT will be the type object, which is the typed undef of the class
10:46 xenoterracide oh
10:46 moritz try self.^name instead
10:46 xenoterracide ok
10:47 colomon joined #perl6
10:47 xenoterracide yeah that's better, thanks
10:49 colomon_ joined #perl6
11:04 xenoterracide ok, next silly question of the day.. why is it &?ROUTINE what's the ? and why is it all caps? trying to figure out if there's a rhyme or reason to when I can expect instrospection things to be caps and not
11:04 FROGGS its all caps because it is some magic constant like __PACKAGE__ was
11:05 sorear and the ? is called a twigil
11:05 FROGGS http://perl6.wikia.com/wiki/Twigil
11:05 sorear wikia?  seriously?
11:05 FROGGS dunno, first hit
11:05 Su-Shee_ joined #perl6
11:06 FROGGS http://perlcabal.org/syn/Differences.html#Global_variables_have_a_twigil <--- better?
11:06 FROGGS $?foo       compiler hint variable
11:06 FROGGS $*foo       dynamically overridable global variable
11:06 FROGGS ...
11:07 FROGGS its interesting what you learn about p5 when reading p6 spec
11:07 FROGGS "Unlike in Perl 5, you may no longer put whitespace between a sigil and its following name or construct."
11:07 FROGGS I didnt know that
11:08 xenoterracide speaking of hits... they seem to be hit or miss... is there a good way to search for things in p6 that anyone is aware of?
11:08 sorear FROGGS: did you know that the first character of a variable name in perl 5 can be literally any non-whitespace?
11:08 xenoterracide or am I just needing to learn my way around the spec better
11:08 sorear eval: $
11:09 buubot_backup sorear: linux
11:09 FROGGS sorear: ya, thats why/how they added all these magic vars
11:09 FROGGS so if "they" can, you can too ;o)
11:09 FROGGS but I prefer varnames that match \w
11:10 FROGGS okay, that t/spec/S32-io/IO-Socket-INET.t fail wasnt about libICU...
11:11 cosimo joined #perl6
11:13 * xenoterracide thinks I would actually prefer &?SUB to &?ROUTINE. has anyone ever talked about changing the name to more closely translate to what 5.16 picked up?
11:14 moritz a method is a not a sub, but appears in &?ROUTINE
11:15 cognominal joined #perl6
11:16 FROGGS thats what I thought too, so &?SUB would lead you in the wrong direction
11:16 xenoterracide sub is short for subroutine? a function is not a subroutine? not sure I really see a distinction
11:17 xenoterracide in this context anyways
11:17 sorear p6: say Method ~~ Sub
11:17 p6eval rakudo bf472b, niecza v22-36-g19fa03a: OUTPUT«False␤»
11:18 sorear it's a very technical nitpicky point
11:18 sorear but the name "Sub" is already taken in perl 6
11:18 moritz xenoterracide: http://doc.perl6.org/images/type-graph-Routine.svg
11:18 sorear the common superclass of Sub and Method is Routine
11:19 moritz rn: say Submethod ~~ Method
11:19 p6eval rakudo bf472b, niecza v22-36-g19fa03a: OUTPUT«False␤»
11:19 * xenoterracide also wonders why pretty diagrams are not UML but that's really a strawman
11:20 xenoterracide ok, I surrender on the routine bit
11:22 brrt any polish people here?
11:22 brrt what is the polish word for polish
11:22 cread joined #perl6
11:23 sorear polski
11:23 sorear FROGGS is
11:23 brrt thanks
11:23 brrt should've known
11:23 FROGGS what?
11:24 bbkr brrt: I'm from Poland too
11:24 FROGGS sorear: I'm not, Woody is, and tadzik afaict
11:24 moritz tadzik and glitchmr, iirc
11:24 brrt what polish was in polish :-)
11:24 brrt nice, good community
11:24 tipdbmp or translate.google.com? =)
11:24 brrt is not always reliable
11:24 tipdbmp works for polish
11:24 moritz phenny: en pl "Polish"?
11:24 phenny moritz: "polski" (en to pl, translate.google.com)
11:24 moritz yes, it does
11:26 FROGGS phenny: de en "Rabenmutter"
11:26 moritz phenny: de en "Rabenmutter"?
11:26 phenny moritz: "Rabenmutter" (de to en, translate.google.com)
11:26 FROGGS O.o
11:26 tipdbmp Bad mother?
11:27 FROGGS right
11:27 FROGGS german invention
11:27 moritz though ravens have a reputation of being good at parenting
11:27 tipdbmp A friend has a bot that does this as well.
11:29 moritz why do most cache modules in perl have that stupid get/set interface?
11:29 cognominal joined #perl6
11:29 moritz for me, the most intuitive interface would be   $cache->get($key, $coderef)
11:29 sorear tipdbmp: google translate is especially unreliable with proper names of languages and cities
11:30 tipdbmp =)
11:30 sorear tipdbmp: because it works by correlating the contents of documents, and names of languages and cities tend to be in mismatched metadata
11:30 sorear jnthn tells once of Google Translate "translating" Bratislava into Prague
11:30 moritz right; most translation services have that problem, because most rely on machine learning
11:31 sorear anyhoo
11:31 sorear sleep&
11:31 moritz godd sleep&, sorear
11:33 xenoterracide moritz: CHI has the compute thing
11:33 xenoterracide although not sure why you might want a different coderef each time
11:34 moritz is it important if it's a different coderef or not?
11:34 xenoterracide I suppose not, just that the interface you propose makes most sense if you wanted to change it on the fly instead of setting it once somewhere
11:36 wamba joined #perl6
11:36 diakopter eval: $*
11:36 buubot_backup diakopter: No output.
11:36 diakopter eval: $**
11:36 buubot_backup diakopter: ERROR: syntax error at (eval 20) line 2, at EOF
11:37 moritz eval: my $x = 3; "$ x"
11:37 buubot_backup moritz: 3
11:38 moritz that's still one of my favorite p5 misfeatures
11:38 FROGGS ya, nobody should put whitespaces there
11:38 FROGGS unreadable++
11:39 xenoterracide Now: $self.$method()      # hard ref   Now: $self."$method"()    # symbolic ref
11:39 xenoterracide what's the difference?
11:39 moritz the quotes
11:39 kresike :)
11:40 xenoterracide but what do the quotes do
11:40 xenoterracide in this context
11:40 moritz they tell you that $method contains a method *name*
11:40 moritz without the quotes, the compiler will assume that $method contains a code object
11:41 xenoterracide oh
11:41 xenoterracide ok
11:43 dalek roast: 3c2dc0e | (Tobias Leich)++ | S32-io/IO-Socket-INET.t:
11:43 dalek roast: RT #115862, skipping multibyte tests for release
11:43 dalek roast:
11:43 dalek roast: After release with parrot 4.4.0 and upgrade to newer parrot these tests should work fine.
11:43 dalek roast: https://rt.perl.org/rt3/Ticket/Display.html?id=115862
11:43 dalek roast: review: https://github.com/perl6/roast/commit/3c2dc0e55f
11:44 daniel-s joined #perl6
11:51 sisar joined #perl6
12:04 brrt joined #perl6
12:17 geekosaur joined #perl6
12:18 mikemol joined #perl6
12:24 sftp joined #perl6
12:25 replore joined #perl6
12:28 cognominal joined #perl6
12:29 rindolf joined #perl6
12:34 jaldhar joined #perl6
12:36 Psyche^ joined #perl6
12:38 GlitchMr joined #perl6
12:38 immortal joined #perl6
12:38 immortal joined #perl6
12:38 tipdbmp No more v80.101.114.108.32.53 (v-strings)?
12:40 moritz r: say v1.0.1
12:40 p6eval rakudo bf472b: OUTPUT«v1.0.1␤»
12:40 moritz tipdbmp: we have version literals, but not v-strings
12:42 cognominal joined #perl6
12:42 tipdbmp Okay.
12:48 moritz eval: v0.1.2
12:50 jaldhar joined #perl6
13:11 spider-mario joined #perl6
13:21 cedrvint joined #perl6
13:21 cedrvint hello #perl6
13:21 cedrvint r: http://gist.github.com/4131134
13:21 p6eval rakudo bf472b: OUTPUT«===SORRY!===␤Confused␤at /tmp/w1LVJl2Njc:1␤»
13:22 cedrvint r: class Class { has $.attr;  method attr() { !!! } }; Class.new(:attr(1));
13:22 p6eval rakudo bf472b:  ( no output )
13:23 cedrvint the !!! stub isn't called. Is it expected? (note: it is called in the REPL)
13:25 SamuraiJack joined #perl6
13:27 moritz cedrvint: yes, it's expected
13:27 moritz cedrvint: it's called in the REPL because the REPL tries to print the object, and thus accesses the attribute accessor
13:28 moritz cedrvint: but construction binds the attributes directly, and doesn't call the accessor
13:29 moritz http://doc.perl6.org/language/objects#Object+Construction
13:37 rvchangue joined #perl6
13:37 cedrvint moritz: thanks!
13:38 dayangkun joined #perl6
13:48 Kharec joined #perl6
14:01 gv joined #perl6
14:14 kaleem joined #perl6
14:15 gv joined #perl6
14:23 fgomez joined #perl6
14:31 benabik joined #perl6
14:42 dalek Perlito: b371c5d | (Flavio S. Glock)++ | / (10 files):
14:42 dalek Perlito: Perlito5 - js - AUTOLOAD finished; add tests; workaround for broken bootstrap in 589722e
14:42 dalek Perlito: review: https://github.com/fglock/Perlito/commit/b371c5d99e
14:53 rurban_ joined #perl6
15:11 masak quick question: does C support closures in any form?
15:11 phenny masak: 10:33Z <diakopter> ask masak see VBBHREUVND in the blockag. bug?  has Int method
15:11 hoelzro masak: standard C, no; I think that some compilers support nested functions, however
15:13 geekosaur actually I think the very latest C standard does have something
15:13 hoelzro geekosaur: the latest? as in C 99?
15:13 * hoelzro isn't aware of a newer one
15:14 hoelzro holy crap, there's a C11
15:14 hoelzro did not know that.
15:15 hoelzro I don't see anything about it in C99 or C11, though
15:16 geekosaur oh, I see, it's only in c++11, not c11
15:19 replore joined #perl6
15:22 masak my general impression from searching ze veb is that it's not possible.
15:22 rindolf joined #perl6
15:22 masak there's some lua documentation that says it is, but I think it's them faking it somehow.
15:23 hoelzro masak: which Lua documentation?
15:23 masak http://pgl.yoyo.org/luai/i/3.4+C+Closures
15:23 hoelzro oh, that's because those are C functions encapsulated in a Lua object
15:24 hoelzro you can take a C function and associate a context with it, so with Lua calls it as a function, it may access that context
15:24 hoelzro it's a Lua construct rather than a C one
15:26 cedrvint masak: "nested functions" is a GCC extension (for instance LLVM doesn't support it)
15:27 Chillance joined #perl6
15:28 masak aha.
15:31 cedrvint masak: an example of nested function: https://github.com/cedric-vincent/PRoot/blob/master/src/execve/elf.c#L357
15:34 spider-mario I believe LLVM has its own nested functions, does it not?
15:35 spider-mario or maybe not
15:35 FROGGS_ joined #perl6
15:36 cedrvint at least the CLang front-end doesn't support it: http://clang.llvm.org/docs/UsersManual.html#c_unimpl_gcc
15:36 hoelzro wouldn't that be up to clang rather than LLVM?
15:36 FROGGS_ moritz: hi, any news from pmichaud?
15:37 masak cedrvint: thank you.
15:37 kurahaupo1 joined #perl6
15:45 cognominal joined #perl6
15:46 daxim joined #perl6
15:47 cedrvint left #perl6
15:59 skids joined #perl6
16:03 pmurias joined #perl6
16:20 bowtie joined #perl6
16:21 kresike bye folks
16:25 pmurias hi
16:26 kurahaupo joined #perl6
16:32 kaare_ joined #perl6
16:54 colomon joined #perl6
16:57 moritz FROGGS_: no :(
16:57 moritz FROGGS_: I'm afraid you have to do the release in a branch, and I'll merge the stuff over and do the upload for you
16:59 cognominal joined #perl6
17:02 cread joined #perl6
17:12 FROGGS_ moritz: in a fork you mean
17:13 FROGGS_ moritz: do tags play with pull requests?
17:21 moritz FROGGS_: yes, fork
17:21 moritz FROGGS_: I have no idea (re tags)
17:21 moritz FROGGS_: you can just give me the commands to copy&paste
17:21 FROGGS_ k, we'll see and learn
17:22 FROGGS_ k
17:27 MayDaniel joined #perl6
17:45 pmurias nqp: for <abc> {print("[$_]");}
17:45 p6eval nqp: OUTPUT«[a][b][c]»
17:45 pmurias jnthn: ^^ is this a bug?
17:48 moritz nqp: for 'abc' { say($_) }
17:48 p6eval nqp: OUTPUT«a␤b␤c␤»
17:49 moritz pmurias: it seems that iterating a string simply iterates over characters in parrot
17:50 pmurias rakudo: for 'abc' { say($_) }
17:50 p6eval rakudo bf472b: OUTPUT«abc␤»
17:50 pmurias rakudo: for <abc> { say($_) }
17:50 p6eval rakudo bf472b: OUTPUT«abc␤»
17:51 pmurias moritz: the thing that looks like a bug is that <abc> return 'abc' not a list
17:51 moritz nr: say <abc>.WHAT
17:51 p6eval rakudo bf472b, niecza v22-36-g19fa03a: OUTPUT«Str()␤»
17:52 moritz pmurias: no, it's a feature
17:52 sergot hi o/ !
17:52 moritz \o sergot
17:56 domidumont joined #perl6
17:56 cognominal joined #perl6
17:58 gv joined #perl6
17:58 pmurias moritz: I need to learn more Perl6 instead of implementing parts of it ;)
17:59 moritz pmurias: :-)
17:59 jerome joined #perl6
18:02 * __sri wonders what parrot supporting threads will mean for rakudo
18:03 __sri if i read this correctly 4.11 will be a very important release :) http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2012-11/msg00814.html
18:11 grondilu r: say %*SIG.perl
18:11 p6eval rakudo bf472b: OUTPUT«Failure.new(exception => X::AdHoc.new(payload => "Dynamic variable \%*SIG not found"))␤»
18:12 GlitchMr perl6: try { fail 'abc' ; CATCH { print 'lol' } }
18:12 p6eval rakudo bf472b:  ( no output )
18:12 p6eval ..niecza v22-36-g19fa03a: OUTPUT«[31m===[0mSORRY![31m===[0mâ�¤â�¤Undeclared routine:â�¤     'fail' used at line 1â�¤â�¤Unhandled exception: Check failedâ�¤â�¤  at /home/p6eval/niecza/boot/lib/CORE.setting line 1437 (die @ 5) â�¤  at /home/p6eval/niecza/src/STD.pm6 line 1147 (P6.comp_unit @ 37) â�¤  at /hom…
18:22 thou joined #perl6
18:23 FROGGS joined #perl6
18:24 FROGGS FROGGS_: go away
18:44 leont joined #perl6
18:52 masak good morning, #perl6 ;)
18:55 skids o/
18:55 diakopter masak: ahoy
18:56 japhb Hi, all!
19:12 masak lue++ # http://rdstar.files.wordpress.com/2012/11/core_fdp.png
19:12 erkan joined #perl6
19:12 erkan joined #perl6
19:12 masak this diagram made me realize that Rakudo's CORE is mostly made of exception types. :P
19:17 SmokeMachine joined #perl6
19:17 masak [backlog] I also can't quite agree about "the spec has been quasi-frozen for about a year"
19:17 masak some parts of the spec have been essentially frozen for far longer than that.
19:18 masak other parts are liquid, and even if they haven't changed recently, we expect them to.
19:18 masak there's a pending threads/events flurry coming up at some point, for instance.
19:19 masak and S19 needs to be aligned with actual reality.
19:21 masak there's been 241 commits to the spec in 2012.
19:21 masak many, many of these changes are minor fixes, yes. some are not.
19:23 FROGGS thats I meant to say, things that need tweaks or things that are broken by design(tm) need to be fixed, other things are better untouched (aka frozen)
19:24 masak r: class A { has Str method foo(--> Int) { return "hi" } }; say A.foo
19:24 p6eval rakudo bf472b: OUTPUT«Type check failed for return value; expected 'Int' but got 'Str'␤  in method foo at /tmp/i3D9GBxEy9:1␤  in block  at /tmp/i3D9GBxEy9:1␤␤»
19:24 masak r: class A { has Int method foo() { return "hi" } }; say A.foo
19:24 p6eval rakudo bf472b: OUTPUT«hi␤»
19:24 masak diakopter: yes, I think that's a bug.
19:24 masak let me check with spec.
19:25 masak looks like.
19:25 * masak submits rakudobug
19:26 TimToady I can quasi-agree that the spec is quasi-frozen.  :)
19:28 masak quasi-heh. :)
19:29 diakopter -modo
19:30 masak r: sub foo(--> Int) { return "hi" }; say foo
19:30 p6eval rakudo bf472b: OUTPUT«Type check failed for return value; expected 'Int' but got 'Str'␤  in sub foo at /tmp/nd3689ED29:1␤  in block  at /tmp/nd3689ED29:1␤␤»
19:31 masak r: my Int sub foo { return "hi" }; say foo
19:31 p6eval rakudo bf472b: OUTPUT«Type check failed for return value; expected 'Int' but got 'Str'␤  in sub foo at /tmp/R5jvMWiMIR:1␤  in block  at /tmp/R5jvMWiMIR:1␤␤»
19:31 Targen joined #perl6
19:35 diakopter masak++
19:35 diakopter masak**=masak
19:36 * masak .oO( but what if I'm 0... ) :P
19:37 colomon masak: he ++'d you first, so unless you started negative...
19:37 TimToady make that 242
19:37 dalek specs: 6d862fd | larry++ | S12-objects.pod:
19:37 dalek specs: oo final/closed pragma can also be deduced
19:37 dalek specs: review: https://github.com/perl6/specs/commit/6d862fde02
19:38 diakopter can monkey patching in a string eval affect things in outer scopes?
19:38 TimToady depends on what you mean by "outer"
19:38 TimToady eval cannot change lexical scopes
19:38 buubot_backup TimToady: ERROR: Can't locate object method "lexical" via package "scopes" (perhaps you forgot to load "scopes"?) at (eval 20) line 1.
19:39 TimToady er, right
19:39 TimToady monkey typing is about changing classes
19:39 TimToady but recall that we keep a quasi-strict separation between lexical dispatch and object dispatch
19:40 diakopter ok, I meant can it change classes existing before the eval
19:40 TimToady sure
19:40 TimToady it wouldn't be monkey-typing if you weren't monkeying with things that were already there
19:40 diakopter does monkey have to be enabled before the eval?
19:41 masak r: class C {}; eval 'use MONKEY_TYPING; augment class C { method foo { say "OH HAI" } }'; C.new.foo
19:41 p6eval rakudo bf472b: OUTPUT«OH HAI␤»
19:41 rurban_ __sri: parrot 4.11 is not important. It is important that npq will be fixed to become thread-safe and thread-aware, so that parrot can finally release threads.
19:41 masak diakopter: nope.
19:41 TimToady there must be a 'use MONKEY_TYPING' somewhere in the lexical outer scope, or in the eval
19:41 TimToady but the eval doesn't have to do it if it's already declared
19:42 diakopter I guess use MONKEY_TYPING would make use oo :closed :final; not very useful
19:42 TimToady eval is supposed to run in the currently defined language at the spot of the eval, not revert to some other language
19:42 buubot_backup TimToady: ERROR: syntax error at (eval 20) line 1, near "currently defined"
19:42 grondilu wow: "All tests successful."
19:42 TimToady it makes it less useful on the class you actually monkey with
19:43 TimToady but merely deriving from a class makes it non-final
19:43 TimToady don't need monkeytyping for that
19:44 TimToady the derivation does need to be done at compile time, though, or the optimizer is allowed to assume :final in the absence of a explicit request to the contrary
19:45 TimToady so any given class is more likely to be closed than finalized, I think
19:46 TimToady in the population of leaf-node classes, the likelihood is going to be closer than that, I suspect, with most of them closed/finalized at application CHECK time
19:48 TimToady actually, it's pretty easy to determine when we're at application CHECK time, since the application's CHECK is what fires off all the other CHECKs, if we follow the Perl 5 model of CHECK
19:48 TimToady eval UNIT
19:48 buubot_backup TimToady: UNIT
19:48 TimToady eval UNITCHECK { print "here\n" }
19:48 buubot_backup TimToady: here
19:48 TimToady which is why p5 has that
19:50 TimToady so if we work our linking right, CHECK time can almost always assume 'use oo :closed, :final;'
19:51 TimToady sorear: ^^ and the spec clarification above
20:07 sorear o/
20:07 masak sorear! \o/
20:08 tadzik hello sorear
20:09 sorear o/ masak, tadzik
20:09 masak tadzik! \o/
20:09 tadzik yay, me :)
20:10 xenoterracide joined #perl6
20:11 xenoterracide yawn
20:11 tadzik yawn, me
20:12 * masak .oO( the tadzik hype cycle is short this evening )
20:13 tadzik I feel dead these dyas
20:13 tadzik getting back home, it's 18, and I feel like sleeping
20:13 masak sir, I assure you, being dead is worse than this.
20:13 moritz masak: you speak from personal experience? :-)
20:14 masak moritz: for most of the Universe's existence, I wasn't even remotely alive.
20:14 tadzik the clones may know something about this
20:14 masak moritz: it was horrible.
20:14 moritz tadzik: I know that feeling very well. Add to that a daughter that doesn't let you sleep through the night... :-)
20:15 tadzik haha
20:15 masak wow, gotta try this parenting thing. sounds like a blast! :P
20:15 tadzik yeah
20:15 moritz speaking of which, I need to tell you a short parenting story
20:15 masak do tell.
20:15 moritz my wife was reading some book to Ronja
20:16 moritz and Ronja got bored after a while
20:16 moritz and said
20:16 moritz "blah blah blah"
20:16 tadzik ahaha
20:16 moritz we were very nearly rolling on the floor laughing
20:16 tadzik to which Ronja replied "hah hah hah" :D
20:17 masak ironic child is ironic.
20:17 moritz she didn't quite understand our amusement :-)
20:18 masak "hey, I just gave you scathing reviews, that's no laughing matter!"
20:18 masak "this is no time to completely lose it. read from the top, and better this time!"
20:19 tadzik huh, I completely missed http://feather.perl6.nl/~sergot/modules/module/Text::Emotion.html in our ecosystem
20:20 * masak .oO( "I hate Mondays, hurrah!" )
20:21 masak also, "emobot" conjures up very funny mental images.
20:21 gv joined #perl6
20:21 tadzik hehe, it does
20:21 dalek perl6-bench: eb1c2d7 | (Geoffrey Broadwell)++ | timeall:
20:21 dalek perl6-bench: Untabify timeall
20:21 dalek perl6-bench: review: https://github.com/japhb/perl6-bench/commit/eb1c2d7873
20:21 dalek perl6-bench: 82d7b0f | (Geoffrey Broadwell)++ | timeall:
20:21 dalek perl6-bench: - Skip timing of undefined (untranslatable) tests
20:21 dalek perl6-bench: - Rejigger a couple old tests to be more equivalent and better named
20:21 dalek perl6-bench: - Add a couple new tests based on harbud3's comments on reddit:
20:21 dalek perl6-bench:   http://www.reddit.com/r/perl/comments/12vtbw/i_know_python_very_well_is_there_any_reason_i/c716bke
20:21 dalek perl6-bench: review: https://github.com/japhb/perl6-bench/commit/82d7b0f0e4
20:21 dalek perl6-bench: d5fed63 | (Geoffrey Broadwell)++ | timeall:
20:21 dalek perl6-bench: Handle starting CWD as a compiler path; use this for rakudo
20:21 dalek perl6-bench: review: https://github.com/japhb/perl6-bench/commit/d5fed63c92
20:21 dalek perl6-bench: 4a9017c | (Geoffrey Broadwell)++ | / (2 files):
20:21 dalek perl6-bench: Add tests for three of the performance-related Rakudo commits
20:21 dalek perl6-bench: review: https://github.com/japhb/perl6-bench/commit/4a9017c451
20:21 tadzik in Polish, when a program runs slowly and glitches, you say that it "cuts itself"
20:21 tadzik emobot cutting itself would be a bit ironic :>
20:22 FROGGS ;o)
20:24 japhb Rakudo progressing from 2011.10 to 2012.10: https://gist.github.com/4132800
20:24 sergot http://feather.perl6.nl/~sergot/modules/ updated :)
20:24 fgomez joined #perl6
20:25 tadzik both cool! :)
20:29 TimToady japhb: cool, but kinda hard to read with the s and x intermixed like that
20:30 moritz seems it stayed mostly constant, no?
20:31 FROGGS I'd say it is about 10% faster than 2012.06
20:35 kurahaupo joined #perl6
20:36 PacoAir joined #perl6
20:43 tadzik ergh, help needed
20:44 tadzik 'not ok 1 - aaa # TODO' -- does this count as a passed test, or a failed one?
20:44 tadzik philosophically :)
20:44 moritz yes.
20:44 moritz :-)
20:44 xenoterracide mu
20:45 tadzik ah :)
20:45 FROGGS if you dont misuse TODO this test isnt a fail, but TODO ;o)
20:45 FROGGS otherwise it might be a fail
20:46 tadzik :F
20:46 ifim joined #perl6
20:46 tadzik my Test::Harness is a bit stupid
20:47 moritz well, it should count it as a passing test
20:47 moritz at least that's what p5 does
20:47 xenoterracide or more or less it should not cause the test suite to fail
20:48 xenoterracide the suite passes regardless of whether todo's pass or fail
20:49 FROGGS right, it just count them as todo (failed but ok), and todo (unexpectedly succeeded)
20:49 tadzik yeah. It's just that I have problems defining success
20:49 tadzik right now I define it as $!tests-ran <= ($!tests-passed + $!todos), which is a bit dumb :)
20:50 tadzik I think instead of shamanism I should just maintain a list of Successes and Failures, disregarding whether it was a todo, a skip or whatnot
20:50 FROGGS well, tests-ran is passed+todo+failed
20:50 tadzik I think it's also broken now
20:50 FROGGS success is when nothing fails
20:50 tadzik well, here we go
20:50 tadzik not ok 1 # TODO
20:51 tadzik did it fail? it did
20:51 FROGGS but if shoudlnt
20:51 tadzik is the test suite successful? It is
20:51 japhb TimToady, I've got to run so I'll have to make this quick (and backlog later), but the original is colored so that it is easy to see the difference between the s and x
20:51 FROGGS ahh
20:51 FROGGS the testsuite is fine, but the test counts as todo/failed
20:51 * japhb wonders if there is any way to colorize a gist
20:51 japhb back later &
20:51 tadzik bah, life's hard :)
20:52 tadzik programming is hard
20:52 FROGGS there are basically five states per test, pass, fail, skip, todo+pass, todo+fail
20:53 tadzik yeah
20:53 FROGGS ppl sometimes add tests to see how thing went on different platforms
20:54 FROGGS like a trial or probe
20:54 FROGGS it's a misuse of todo basically but hey, thats life ;o)
20:54 tadzik hrm
20:54 tadzik I ponder counting not ok # TODO as a passing test
20:55 tadzik this allows for an easy definition of success :)
20:55 FROGGS k
20:55 FROGGS as long as the author can see what happened ;o)
21:00 tadzik okay. Now p6prove should be sufficient for panda to switch to it
21:00 tadzik yep, works :)
21:02 colomon wait, p6prove?
21:02 tadzik yep
21:02 tadzik somewhat works :)
21:02 colomon \o/
21:02 Tene joined #perl6
21:02 Tene joined #perl6
21:04 tadzik now panda may be able to tell like "your tests failed, but only one of them, cheer up"
21:04 tadzik and similar info available in emmentaler and stuff
21:04 tadzik mebbe :)
21:06 FROGGS git question: if I'm in a 'detached HEAD' state, and I wanna add commits and a tag to that state, can I push afterwards to a branch that already has later commits?
21:07 moritz I don't think you can push from a detached HEAD state
21:07 FROGGS damnit
21:07 moritz the commits for the release should end up in master
21:07 FROGGS so I have to use nqp master and run the testsuite and cross my fingers than nothing breakes?
21:09 moritz don't fear; the new commits only added methods that are never called from nqp or rakudo by default
21:09 moritz (only by --target=past)
21:09 moritz so, nothing will break
21:09 FROGGS k, will try now
21:10 moritz (just for the record, if you want to recover from such a state anyway, you just create a new branch, 'git checkout -b release-2012.11', and then use that for pushing)
21:10 FROGGS right
21:11 leont left #perl6
21:15 lue Hello o/
21:16 masak lue! \o/
21:17 tadzik ufo ignores %*CUSTOM_LIB, doesn't it? :)
21:18 moritz it does, yes :(
21:18 moritz needs to be updated, I guess
21:18 tadzik that bites sometimes, if you mix up panda and ufo's 'make install'
21:19 masak pull requests welcome.
21:20 lue That reminds me. Should the panda bootstrap create symlinks from ~/.perl6/version-specific/(bin|lib) to ~/.perl6/(bin|lib) ? I did so manually after the last update I ran.
21:20 tadzik that'd be cool
21:21 tadzik apart from the fact that we can't create symlinks in a cross-platform way :)
21:21 lue There *has* to be a Windows equivalent. I'd be honestly shocked if there wasn't.
21:21 * masak never runs on that "cross" platform everyone keeps caring about anyway :P
21:22 masak Windows has had symlinks for ages, I think. it just doesn't expose them very much.
21:22 * TimToady wants to know what made it cross in the first place
21:22 dalek panda/p6prove: e968a09 | tadzik++ | / (2 files):
21:22 dalek panda/p6prove: Try to use p6prove instead of prove
21:22 dalek panda/p6prove: review: https://github.com/tadzik/panda/commit/e968a091d2
21:22 tadzik Something for adventurers like you
21:24 * lue thinks P6's ExtUtils should come with a ln command.
21:25 moritz masak: well, only on NTFS
21:25 moritz masak: fat32 doesn't support symlinks
21:27 lue I wonder how Windows systems deal with version-specific libraries and such when they can't symlink library_v0.1 to library /me guesses they don't.
21:27 FROGGS moritz: I need to patch nqp, rurban has added an enum_class_Proxy wich isnt defined in 4.4.0, and the switch PARROT_HAS_THREADS that could disable it when undef is defined already
21:27 FROGGS so I revert his patch for now I'd say
21:28 FROGGS https://github.com/perl6/nqp/commit/6d8b63d105392980a74ed250ae51a9c54ec73775
21:28 TimToady nrp: multi foo ($a where { .say.so }) { say "A" }; multi foo ($a where { .say.so }) { say "B" }; foo(42)
21:28 p6eval pugs: OUTPUT«*** ␤    Unexpected "where"␤    expecting "?", "!", trait, "=", default value, "-->" or ")"␤    at /tmp/lKlR49fJdg line 1, column 15␤»
21:28 p6eval ..rakudo bf472b: OUTPUT«42␤42␤A␤»
21:28 p6eval ..niecza v22-36-g19fa03a: OUTPUT«Potential difficulties:â�¤  $a is declared but not used at /tmp/aYpa2eynSj line 1:â�¤------> [32mmulti foo ([33mâ��[31m$a where { .say.so }) { say "A" }; multi[0mâ�¤â�¤42â�¤42â�¤Aâ�¤Â»
21:28 diakopter lue: in Windows libraries aren't installed system-wide unless they're kernel drivers
21:28 TimToady 42 42 is incorrect
21:29 TimToady it is *not* supposed to evaluate all the constraints ahead of time
21:29 diakopter what's the order
21:29 FROGGS moritz: or I better do: #ifdef enum_class_Proxy instead of #ifdef PARROT_HAS_THREADS
21:29 skids defined order.
21:30 diakopter lue: lemme rephrase.
21:32 diakopter libraries aren't installed systemwide to be accessible by filename. if a program wants to load a library by filename, it has to be on the path or directory housing the executable. libraries *are* registered in the registry, to make them available computer-wide
21:32 diakopter (.. or know the exact path of the library)
21:33 masak TimToady: I believe that bug is already RT'd.
21:34 lue Ah. I'm getting the feeling Windows is different enough in its library handling that panda will eventually need an entirely separate process for installing modules on Windows.
21:34 diakopter well, the site_lib system seems to work for activeperl and strawberry
21:35 * lue tried foolishly to run STD.pm6 in rakudo, and is currently stuck on line 96.
21:35 lue diakopter: I guess what to do then is /versionspecific/libs and then a variable in some config file saying "use this directory" that's automatically updated when panda is.
21:36 dalek nqp: 6806339 | (Tobias Leich)++ | src/pmc/nqplexpad.pmc:
21:36 dalek nqp: checking for enum_class_Proxy instead of PARROT_HAS_THREADS
21:36 dalek nqp:
21:36 dalek nqp: In parrot 4.4.0 enum_class_Proxy isnt defined but PARROT_HAS_THREADS is. So enum_class_Proxy would be added to the condition.
21:36 dalek nqp: review: https://github.com/perl6/nqp/commit/6806339701
21:36 diakopter lue: I don't understand your goals
21:37 moritz FROGGS: sorry; when I said that none of the commits broke nqp I was looking at my local checkout, which was stale :/
21:37 TimToady masak: I am more responding to sorear's remark at http://irclog.perlgeek.de/perl6/2012-11-22#i_6175924
21:37 FROGGS moritz: np
21:37 FROGGS as long I can fix...
21:38 sorear I'm not paying attention
21:38 sorear Should I be?
21:38 TimToady it does not try all the candidates in that case, except abstractly
21:38 lue I'm just thinking of the windows equivalent of ln -sT ~/.perl6/version-specific/(bin|lib) ~/.perl6/(bin|lib)
21:38 TimToady well, I don't know if you meant what you said :)
21:38 diakopter lue: what does -T do
21:39 lue makes the first argument the target, the second being the symlink's name. I can't be bothered to remember the order without it :)
21:39 TimToady sorear: the 42 42 example was to demonstrate that both rakudo and niecza are evaluating constraints unnecessisarily compared to what the spec requires
21:40 TimToady and your remark at http://irclog.perlgeek.de/perl6/2012-11-22#i_6175924 can be construed as justifying the extra work, read one way
21:40 TimToady *unnecessarily
21:41 sorear nrp: multi foo ($a where { .say.so }) { say "A" }; foo(42)
21:41 p6eval rakudo bf472b: OUTPUT«42␤42␤A␤»
21:41 p6eval ..niecza v22-36-g19fa03a: OUTPUT«Potential difficulties:â�¤  $a is declared but not used at /tmp/gYI9c3rm8V line 1:â�¤------> [32mmulti foo ([33mâ��[31m$a where { .say.so }) { say "A" }; foo(4[0mâ�¤â�¤42â�¤42â�¤Aâ�¤Â»
21:41 p6eval ..pugs: OUTPUT«*** ␤    Unexpected "where"␤    expecting "?", "!", trait, "=", default value, "-->" or ")"␤    at /tmp/cvzsmPTWFr line 1, column 15␤»
21:41 sorear TimToady: that's not quite what's going on I think
21:41 TimToady innersting
21:41 TimToady but still duplicate effort
21:41 diakopter "does it match" then "make it match"?
21:41 sorear I think that after it commits to a candidate, it restarts the binding
21:42 TimToady I think the binding should determine the commitment, not vice versa
21:42 TimToady why run the code twice?
21:44 * TimToady feels like he's been arguing the primacy of binding for a number of years now, though mostly in reference to partial binding of map closures
21:44 TimToady so it's controlled by the binding, not by introspection
21:45 diakopter how does the thing that launched the binding know it succeeded?
21:46 diakopter (unless they're chained recursively..)
21:54 diakopter (dumb question?)
21:54 sorear maybe not a dumb question but a non-issue for niecza
21:55 sorear niecza does the "check" by a binding operation
21:55 masak I don't think it's a dumb question. I'd need to prototype this in working code before I'd dare enter into the discussion... :)
21:55 jnthn evening
21:55 FROGGS hi jnthn
21:55 sorear but throws away the result because it *might* need to check extra signatures, in cases where detecting ambiguityis important
21:56 TimToady spec says it doesn't need to worry about that for constraints
21:56 sorear would be pretty straightforward to optimize niecza to eliminate the redundant check
21:57 TimToady but my viewpoint here is that binding is part of function application, not a separate imperative step
21:58 jnthn TimToady: I suspect the repeated checks are there because I did the simplest patch that could possible work to switch it over to "picks first" semantics.
21:58 jnthn *possibly
21:59 jnthn And probably didn't change much beyond that...
21:59 TimToady I was just a bit surprised that it still duplicated that work
21:59 TimToady when getting rid of the extra work was part of the motivation for the earlier ruling...
21:59 jnthn TimToady: Well, optimization after semantics...
21:59 jnthn TimToady: Also, the plan is to move the candidate sorter and much of that dispatchy stuff into NQP code.
22:00 jnthn So that'd be the opportune time to optimize this.
22:00 TimToady nodnod
22:01 jnthn (The cache will stay low level, meaning that the vast majority of things will be at least as fast, and the existing slower paths may well break even due to avoiding some nested runloops...)
22:01 TimToady though it still feels vaguely wrong to me to call it an optimiztion
22:02 dalek nqp: d0f9fec | (Tobias Leich)++ | VERSION:
22:02 dalek nqp: bump VERSION to 2012.11
22:02 dalek nqp: review: https://github.com/perl6/nqp/commit/d0f9fecda7
22:03 jnthn Well, it only shows up in the semantic sense if you write a where clause with side-effects, and iirc we don't promise much related to those.
22:04 jnthn Anyways, 'twill be fixed. :)
22:05 jnthn But not now, 'cus I'm exhausted...
22:05 TimToady well, slower is a side effect too :)
22:05 TimToady so is exhausted :)
22:06 TimToady nap &
22:07 jnthn masak: 113904 is a dupe iirc
22:08 masak jnthn: it felt familiar.
22:10 * diakopter must now go traditionally overeat
22:11 masak felicitous turkey.
22:20 larks joined #perl6
22:27 larks joined #perl6
22:29 fgomez joined #perl6
22:41 rurban_ joined #perl6
22:42 Tabrenus joined #perl6
22:42 masak 'night, #perl6
22:43 FROGGS gnight masak
22:47 * jnthn also rests...
22:47 jnthn &
22:47 FROGGS well then, good night
22:48 * FROGGS is making the last checks prior to release
22:57 FROGGS k, last time I need to run the stresstest
23:07 FROGGS moritz, sorear: sombody there to merge my release-pull request in?
23:07 FROGGS https://github.com/rakudo/rakudo/pull/88
23:08 sorear FROGGS: I do not have a rakudo commit bit
23:08 FROGGS k
23:09 dalek rakudo/nom: c65b52b | (Tobias Leich)++ | docs/announce/2012.11:
23:09 dalek rakudo/nom: [release] announcement for 2012.11
23:09 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/c65b52b41d
23:09 dalek rakudo/nom: 6254734 | (Tobias Leich)++ | docs/ChangeLog:
23:09 dalek rakudo/nom: [release] logges last missing changes
23:09 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/6254734922
23:09 dalek rakudo/nom: 77fdf4a | (Tobias Leich)++ | docs/announce/2012.11:
23:09 colomon o/
23:09 FROGGS thanks!
23:10 colomon no prob
23:10 FROGGS can you upload that tarball too please?
23:10 colomon where does it need to go?
23:10 dalek joined #perl6
23:10 * colomon has been out of the rakudo release loop for quite a while now....
23:11 FROGGS there is a downloads button at the right
23:11 FROGGS https://github.com/rakudo/rakudo/downloads
23:11 FROGGS and the tags where not included in the pull request, you have to do it manually:
23:12 FROGGS git tag -a -m"tag release #58" 2012.11
23:12 FROGGS git tag -a -m"tag release #58" "Walnut"
23:12 FROGGS git push --tags
23:13 FROGGS the tarball is here btw: http://froggs.de/perl6/rakudo-2012.11.tar.gz
23:13 sorear o/ colomon
23:14 colomon \o sorear
23:15 colomon FROGGS: I think I uploaded the tarball correctly, and pushed the tags.  Can you doublecheck, please?
23:15 FROGGS seen already!
23:15 aloha already! was last seen in  15666 days 23 hours ago .
23:15 colomon I'm trying to monitor a 4yo here at the moment too, things are a bit hectic.
23:15 FROGGS thank you sir ;o)
23:16 FROGGS colomon: I've got an almost 3yo and a 1.5yo
23:16 FROGGS but they are sleeping
23:18 Khisanth joined #perl6
23:21 FROGGS colomon: if you got a second, I made a typo in the announcement, here is another pull request: https://github.com/rakudo/rakudo/pull/89
23:21 FROGGS then I'm done
23:32 rurban_ joined #perl6
23:40 lue r: say "aaaa" ~~ /a**{2..*}/
23:40 p6eval rakudo bf472b: OUTPUT«===SORRY!===␤Quantifier quantifies nothing at line 2, near "{2..*}/"␤»
23:40 lue r: say "aaaa" ~~ /a**2..*/
23:40 p6eval rakudo bf472b: OUTPUT«「aaaa」␤␤»
23:40 lue Methinks it's a bug. Does anyone know if it's been reported already?
23:41 FROGGS hmmm, didnt seen it
23:41 FROGGS and I've looked at almost all reports this week
23:42 FROGGS r: say "aaaa" ~~ /a**(2..*)/
23:42 p6eval rakudo bf472b: OUTPUT«===SORRY!===␤Quantifier quantifies nothing at line 2, near "(2..*)/"␤»
23:42 FROGGS hmmm
23:42 FROGGS but well, gtg to bed
23:42 FROGGS gnight
23:44 * lue will report bug once his computer stops being slow on account of Perl 5 (and modules) upgrade
23:44 lue good knight FROGGS o/
23:49 dalek rakudo/nom: 9790c6c | (Tobias Leich)++ | docs/announce/2012.11:
23:49 dalek rakudo/nom: typo in codename
23:49 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/9790c6ca2f
23:49 dalek rakudo/nom: 50be5d2 | colomon++ | docs/announce/2012.11:
23:49 dalek rakudo/nom: Merge pull request #89 from FROGGS/patch-1
23:49 dalek rakudo/nom:
23:49 dalek rakudo/nom: typo in codename
23:49 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/50be5d23a9
23:50 colomon FROGGS: sorry for the delay, I had to put him to bed.
23:50 fgomez joined #perl6
23:51 colomon Had to read him and his slightly older cousin "Return of the Jedi".
23:51 * lue submits rakudobug
23:57 colomon hmmm, latest rakudo not building for me?
23:59 colomon NQP has been built and installed.
23:59 colomon ===SORRY!===
23:59 colomon NQP revision 2012.11 required (currently 2011.12).

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

Perl 6 | Reference Documentation | Rakudo