Camelia, the Perl 6 bug

IRC log for #parrot, 2008-12-30

Parrot | source cross referenced

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

All times shown according to UTC.

Time Nick Message
00:00 pmichaud yes, I'm reviewing/refactoring other stuff as well
00:00 pmichaud it ends up affecting almost all aspects of variable handling, so that includes things like 'has' and the like.
00:01 jonathan *nod*
00:01 jonathan A good review now and then can't hurt.
00:01 pmichaud one thing I did yesterday that I hope will help is to turn traits into things that we can easily make roles/properties from.
00:02 pmichaud i.e., so that is xxx  can really turn into the appropriate invocation of the xxx role.
00:02 jonathan Invocation of the xxx role?
00:02 pmichaud sorry, mixin, whatever.
00:02 jonathan It should be a multiple dispatch.
00:02 jonathan to trait_auxiliary:is
00:02 pmichaud so that it can become a call to   trait_auxiliary:is(xxx, $obj, $arg)
00:02 pmichaud yes, that.
00:02 jonathan The more we can make stuff happen that way and not special-case it in the compiler, the better.
00:03 pmichaud I did go ahead and special-case readonly, rw, and copy for now.
00:03 pmichaud but they're special-cased in the signature binder, not in the compiler.
00:03 jonathan That's fine, I don't expect we can do 100% of them without specail-casing.
00:03 jonathan is also and is instead will likely for now want to stay special-cased.
00:04 pmichaud yes, they will as well.
00:04 jonathan Um, we don't do is instead yet.
00:04 pmichaud the point being that the generic trait nodes are there.
00:04 jonathan OK, that sounds good.
00:04 jonathan And inheritance is still handled through a dispatch to trait_auxiliary:is?
00:04 pmichaud so I have a general approach in place I'm comfortable with, and special-casing takes place in the sections where it makes sense :-)
00:04 pmichaud I haven't gotten to classes/inheritance yet, but I'm sure they will be.
00:04 jonathan They are at the moment (in trunk at least)
00:05 pmichaud then they undoubtedly will be in the refactor :-)
00:05 jonathan OK, good. It'd be nice to keep things that are done right-ish right. :-)
00:06 pmichaud one of my goals is to get things that look like subroutine calls out of the compiler and into subroutines :-)
00:06 jonathan Any thoughts on breaking some of the various subs actions.pm has within it out into some modules?
00:06 jonathan So we get an even leaner actions.pm?
00:07 pmichaud most of the 1500 line savings has been from getting rid of those subs :-)
00:07 jonathan Then we have less to re-compile during development.
00:07 jonathan Ah. Where are they now?
00:07 pmichaud at the moment they don't exist.  In many cases we no longer need them.
00:07 jonathan OK.
00:07 pmichaud (because the work they do is in one place)
00:07 pmichaud (and is short enough to be reasonably inline)
00:07 * jonathan guesses actions.pm compiles rather faster now.
00:08 pmichaud I haven't timed it.  I have noticed that I'm not bugged by compile time like I once was.
00:08 pmichaud I'm not sure where that speedup comes from.
00:08 chromatic_away I did speed up PGE by about a third with some STRING optimizations last week.
00:09 pmichaud but as an example, much of the work that was being done for setting up parameter traits in the various subs is gone and now part of the binding.
00:09 pmichaud even better, the traits get precompiled as part of the signature.
00:09 AndyA joined #parrot
00:09 pmichaud so it's now just "attach this already-compiled trait to my caller's lexical variable"
00:10 jonathan *nod*
00:10 jonathan Doing stuff once at compile time on that stuff is certainly a win.
00:10 pmichaud it may become an even bigger win
00:10 pmichaud in some cases we may actually be able to do a setprophash  to get them all at once.
00:11 jonathan Did that op already get implemented?
00:11 pmichaud no, and it's not enough of a win yet to warrant it
00:11 pmichaud (there are still some places where it won't be enough)
00:11 jonathan OK.
00:12 pmichaud if I need it, I think I can implement it :-)
00:13 pmichaud I'm _also_ toying with the idea that instead of having a 'readonly' property to indicate "don't write to this variable" that we have a "rw" property that says "this is a writable container"
00:13 pmichaud that will probably work great for scalar vars; I haven't quite figured out how to handle it for aggregate elements.
00:14 pmichaud so that will likely come after merging the refactor back to trunk.
00:14 pmichaud anyway, I'm being called to dinner.
00:14 pmichaud (chromatic):  Yes, your PGE speedup is likely the cause of the speed improvement, then.  Thanks, that's very helpful.
00:14 kid51 joined #parrot
00:15 * jonathan should sleep
00:19 jq joined #parrot
00:20 ask_ joined #parrot
00:30 nopaste "chromatic" at 69.64.234.10 pasted "pmichaud: Patch to add :ignore_rest parameter (first cut, unclean, but worth profiling)" (10425 lines) at http://nopaste.snit.ch/15123
00:37 GeJ I'm working on t/oo/mro-c3.t, and at some point new class creation switched from "A = new 'Class'" to "A = newclass 'A'".
00:40 jq joined #parrot
00:41 GeJ I understand that the later registers the 'A' class at a global level.
00:41 chromatic_away Right.
00:42 jhorwitz chromatic: does :discard make more sense than :ignore_rest?
00:43 GeJ Since I now run everything inside a :main sub, calling "newclass 'A'" twice (even in two separate subs) breaks the run.
00:44 GeJ So my question is : should I replace the "newclass 'X'" with anonymous classes (and be consistent within the file) or change the class names?
00:45 GeJ like MI{A,B,C} for multiple inheritance and DI{A,B,C,D} for diamond inheritance
00:46 GeJ third possible option: "You're overthinking it, just make it work."
00:49 nopaste "GeJ" at 202.22.229.231 pasted "[perl-to-pir conv] First attempt at converting t/oo/mro-c3.t" (305 lines) at http://nopaste.snit.ch/15124
00:53 cognominal_ joined #parrot
00:59 chromatic_away jhorwitz, that's not bad.
01:31 dalek r34595 | allison++ | branches/pdd22io_part3/src/pmc:
01:31 dalek : [pdd22io] Store the StringHandle mode converted to integer flags too.
01:32 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34595
02:05 dalek r34596 | pmichaud++ | branches/rvar/languages/perl6/src/classes:
02:05 dalek : [rakudo]:  Adjust Scalar method on Object.
02:05 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34596
02:15 GeJ in PIR, labels are local to the current sub, right?
02:15 pmichaud yes.
02:16 GeJ thank you.
02:19 * Coke kicks off an --optimized run of partcl's spec tests.
02:37 GeJ hum, converting perl to pir is actually fun.
02:43 kid51 joined #parrot
02:55 dalek r34597 | jkeenan++ | trunk/lib/Parrot:
02:55 dalek : Deleting one inline comment; rejecting http://rt.perl.org/rt3/Tic​ket/Display.html?id=43751.
02:55 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34597
03:01 dalek r34598 | allison++ | branches/pdd22io_part3/src/pmc:
03:01 dalek : [pdd22io] Keep the string data of a StringHandle around even after it's closed,
03:01 dalek : so can be read later. Make 'read' smarter about reading the specified number of
03:01 dalek : bytes, so it mocks the behavior of a filehandle better.
03:01 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34598
03:06 dalek r34599 | allison++ | branches/pdd22io_part3/t/pmc:
03:06 dalek : [pdd22io] Start to remove real temp file creations, since StringHandle doesn't
03:06 dalek : interact with real files. Add code to write dummy text to the StringHandle
03:06 dalek : objects, since it won't be reading from real files.
03:06 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34599
03:07 dalek r34600 | tene++ | branches:
03:07 dalek : Delete old unused branch
03:07 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34600
03:09 dalek r34601 | tene++ | branches:
03:09 dalek : Delete experimental branch.
03:09 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34601
03:09 dalek r34602 | allison++ | branches/pdd22io_part3/t/pmc:
03:09 dalek : [pdd22io] Reuse the stringhandle we wrote to, rather than creating a new empty one.
03:09 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34602
03:10 Tene pmichaud: check out http://www.parrotvm.org/svn​/parrot/revision?rev=29089
03:16 pmichaud Tene: niiiiice
03:16 Tene pmichaud: That never made it into trunk... should it have?
03:16 dalek r34603 | tene++ | branches:
03:16 dalek : Remove unneeded branch.
03:16 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34603
03:17 pmichaud it would be fine with me if it does.
03:17 pmichaud we already had approval for it during parrotsketch, iirc.
03:17 pmichaud (or maybe it was PDS)
03:17 pmichaud anyway, it looks much nicer as a method than an opcode.
03:18 Tene Any idea why we needed it?
03:20 pmichaud it (can) make some operations easier in P6object, iirc.
03:20 Tene Ah.
03:25 Tene yeah, rt #56616
03:25 Tene testing, then committing
03:26 Tene needs a docs update too I suspect, though
03:29 Tene pmichaud++
03:29 dalek r34604 | tene++ | trunk (2 files):
03:29 dalek : [core]:  Add 'make_namespace' method to NameSpace PMC (RT #56616)
03:29 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34604
03:30 dalek r34605 | tene++ | branches:
03:30 dalek : Create a branch for working pn HLL issues with PCT.
03:30 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34605
03:31 dalek r34606 | pmichaud++ | branches/rvar/languages/perl6/src/pmc:
03:31 dalek : [rakudo]:  ObjectRef automatically intializes to Object proto.
03:31 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34606
03:32 Tene pmichaud: .HLL 'Perl6' or .HLL 'perl6' ?
03:33 Tene I'm pretty sure the latter...
03:33 pmichaud I think the pdds say 'perl6'
03:33 pmichaud and I wonder if it should perhaps be 'rakudo'  :-P
03:33 pmichaud we'll go with 'perl6' for now
03:33 dalek r34607 | allison++ | branches/pdd22io_part3/src/pmc:
03:33 dalek : [pdd22io] Make StringHandle smarter about 'readline' so it really only reads a
03:33 dalek : line at a time.
03:33 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34607
03:35 Tene So is the HLL supposed to import the P6Object and PCT stuff into its own namespace, is the HLL supposed to get it from the Parrot namespace, or are the libraries supposed to export to the loading HLL?
03:35 Tene I know I've asked this a dozen times.  I can never remember which you want.
03:35 pmichaud My initial approach is going to be HLL imports into its own namespace
03:36 pmichaud eventually I expect it to import into its own private namespace... but that comes later
03:37 dalek r34608 | allison++ | branches/pdd22io_part3/t/pmc:
03:37 dalek : [pdd22io] Write to and read from the same StringHandle in test.
03:37 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34608
03:38 Coke (whoops. accidental repaste on my last send.)
03:38 Coke Huh. partcl is /slower/ with recent updates to parrot and partcl. whee! =-)
03:40 silug joined #parrot
03:43 Coke .HLL 'Perl6' is equivalent to .HLL 'perl6'
03:44 dalek r34609 | allison++ | branches/pdd22io_part3/src/pmc:
03:44 dalek : [pdd22io] StringHandle check for end-of-file needs to take offset into account.
03:44 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34609
03:44 GeJ PIR tests are way faster...
03:44 GeJ Or did I screw up something again?
03:45 Tene they're way faster
03:46 nopaste "GeJ" at 202.22.229.231 pasted "[perl-to-PIR conv] conversion of t/oo/composition.t" (619 lines) at http://nopaste.snit.ch/15127
03:47 tewk PIR tests make it very hard to test one test in isolation,
03:49 dalek r34610 | allison++ | branches/pdd22io_part3/t/pmc:
03:49 dalek : [pdd22io] Caught an untested failure case in FileHandle's tests when porting to
03:49 dalek : StringHandle, succeded when no lines were read.
03:49 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34610
03:51 chromatic_away GeJ, I just skimmed it but it looks good to me.
03:52 GeJ Did you had a look at the first one as well?  http://nopaste.snit.ch/15124
03:52 rurban_ joined #parrot
03:53 chromatic_away Also seems sane.
03:53 GeJ not sure I'll have time to do t/oo/new.t right now. Got some shopping to do. Probably tonight, tomorrow at the latest.
03:56 GeJ I actually enjoyed the try: catch: finally: trick...
03:58 GeJ oh shoot, I left my folding markers on.
04:01 elmex_ joined #parrot
04:08 Tene pmichaud: the 'parent' list passed to 'register'... should it be presumed that if it's strings, they're in the same HLL as the class being created?
04:13 Tene That's what I'm assuming, and so I'm going to add an optional :hll named param to a few functions on P6object.
04:13 Tene Maybe.  Still looking at options.
04:17 Tene Hmm.  No, not sure that's right...
04:29 Tene The problem is that add_parent uses get_parrotclass to look up the names, and get_parrotclass does get_hll_namespave on strings.
04:29 Tene Which is unlikely to be useful when the caller is in a different HLL
04:35 Tene Oh, ew.
04:35 Tene 'parent'=>'Boolean Any'
04:35 Tene 'Boolean' there refers to the core pmc 'Boolean'
04:36 Tene I guess we can first try in the hll namespace and then in the parrot namespace if that fails...
04:39 petdance joined #parrot
04:47 pmichaud at some point 'parent'=>  should expect an array of classes instead of a string.
04:47 pmichaud i.e., I don't necessarily want P6object to guess too much about the caller's intent.  If it's not clear, the caller has a way to make it clear.
04:48 pmichaud I also don't want :hll spreading itself too far throughout P6object
04:48 Tene I was able to get it working with just adding it to get_parrotclass
04:49 pmichaud looking up classes by string should be a convenience, but not one that is guaranteed to understand every possible nuance of how things might be named or organized.
04:50 pmichaud because strings just aren't that smart.
04:50 Tene right
04:51 Tene get_parrotclass is a convenience method.
04:51 Tene I could also rewrite the 'parent' option in new_class if you'd prefer.
04:52 pmichaud to do...?
04:53 Tene Right now new_class passes 'parent' on unchanged to 'register'.  I could modify 'new_class' to change the 'parent' option from a string to an array of classes.
04:54 pmichaud I would think that we should be doing that in register
04:54 Tene Okay.
04:54 pmichaud (if we do it at all)
04:54 Tene That's where it's currently handled.  I'll leave it that way.
04:55 pmichaud unless it's _trivially_ easy to get 'parent'=>'Boolean Any' to do the right thing, I think I'd prefer to make the caller explicitly provide the array of classes.
04:55 pmichaud and leave the existing code as-is.
04:55 Tene I now have to figure out why 'register' is returning undef.
04:55 Tene It currently DTRT with about four or five lines.
04:56 Tene if TRT is 'check HLL then parrot'
04:56 pmichaud patch?
04:56 purl We don't need no stinking patch!
04:56 pmichaud or diff?
04:56 purl diff is that a burned cat is not as attractive as scarlett johannsen  that a burned cat is also more likely to get its kit off
04:56 Tene Sure.  I'll need to trim... justasec
04:56 lathos purl, you are quite weird.
04:56 purl ...but purl is a she. or captain obvious...
04:58 nopaste "tene" at 166.70.38.237 pasted "hll for get_parrotclass" (45 lines) at http://nopaste.snit.ch/15128
04:59 chromatic_away joined #parrot
04:59 dalek r34611 | allison++ | branches/pdd22io_part3 (3 files):
04:59 dalek : [pdd22io] Change the 'readline' op to call a public interface, which calls the
04:59 dalek : 'readline' method.
04:59 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34611
05:00 Tene add_parent also calls get_parrotclass, which then just returns the class, so  little suboptimal.
05:00 pmichaud I wonder if a better approach is to use the hll class as part of the string name
05:01 pmichaud i.e.,   'parent'=> 'parrot;Boolean perl6;Any'
05:01 dalek r34612 | allison++ | branches/pdd22io_part3/t/pmc:
05:01 dalek : [pdd22io] Remove more of the old temp files, and write 10,000 lines to a
05:01 dalek : StringHandle for testing.
05:01 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34612
05:01 Tene that would be a bit nicer, but that's not necessary to get a working behavior right now.
05:02 pmichaud in general that 'hll' option feels very wrong to me.
05:02 Tene Agreed.
05:02 pmichaud (not only for this, but also in other places where we've used it.)
05:03 Tene Many places are still not HLL-friendly.
05:04 Tene Although the other influence is not asking HLL authors to keep repeating themselves.
05:04 pmichaud how do you mean?
05:05 Tene 'parent'=>'perl6;Foo perl6;Bar perl6;Baz' seems awkward to me.
05:05 pmichaud thinking.
05:05 purl http://www.terrybisson.com/meat.html
05:06 chromatic_away Meat.  They're made of meat.
05:06 pmichaud currently when we call new_class or register, P6object adopts the caller's view of hll, yes?
05:06 Tene in 'new_class' we could add the 'hll;' if it's not there.
05:06 Tene Right.
05:06 pmichaud 'parent' should do the same.
05:07 pmichaud so then it would be 'parent'=>'Foo Bar Baz'
05:07 pmichaud and if the hll wants something out of the parrot hll, it should explicitly say so
05:07 Tene and in the Bool class do we still want to try to support 'Boolean Any' or require 'parrot;Boolean Any'?
05:08 pmichaud but ultimately I still believe that strings are the wrong way to do this
05:08 pmichaud I want:
05:08 pmichaud $P0 = get_class 'Boolean'
05:08 pmichaud $P1 = get_hll_global 'Any'
05:08 pmichaud $P2 = new 'ResizablePMCArray'
05:08 pmichaud push $P2, $P0
05:08 pmichaud push $P2, $P1
05:08 pmichaud 'parent'=> P$2
05:08 pmichaud er, $P2
05:09 pmichaud yes, that's a pain for the HLL person.  But it's part of what happens from wanting to mix Parrot classes into your HLL.
05:09 pmichaud it's also the most technically correct.
05:10 lathos That only needs to be done once, when the class is set up, right?
05:10 Tene lathos: right
05:10 pmichaud correct.
05:10 lathos Phew. Looks good, then.
05:10 chromatic And that's in PIR, which is assembly code.
05:11 Tene pmichaud: should 'new_class' optionally deconstruct a string into that, to offer a more convenient option for the common case?
05:11 pmichaud Tene:  you mean register?
05:11 pmichaud because 'new_class' doesn't care.
05:11 pmichaud because 'new_class' shouldn't care.
05:12 lathos chromatic: The NCI discussion has made me wonder: why don't we just use C function signatures to represent C function signatures?
05:12 chromatic I can't think of any good reason.
05:12 Tene You're right.  I was remembering new_class as a more friendly wrapper around 'register'.  That was wrong.  I understand better now.
05:12 chromatic I mean, I can't think of any good reason not to do just that.
05:13 Tene chromatic: I thought that's what you were implying but avoiding saying explicitly the entire time.
05:13 Tene is that the case?
05:13 pmichaud new_class is a friendly "create a class and then register it" wrapper :-)
05:13 lathos Other than "parsing is hard", but we have Convert::Binary::C.
05:13 chromatic We have tewk's SoC project as well.
05:14 lathos Did that succeed? If so it will have been the only 2008SoC project I've found that did.
05:15 chromatic Yes, it did.
05:15 pmichaud Tene: thinking.
05:15 purl http://www.terrybisson.com/meat.html
05:15 lathos Excellent.
05:15 Tene pmichaud: mostly, I'm wanting to keep this branch as small and short-lived as possible.  I want to avoid rewriting all the class definitions in all of the languages in this branch if possible.
05:16 pmichaud Tene: the branch should only make it possible to convert languages to hll.  The branch itself shouldn't convert them all.
05:16 pmichaud that's up to the language implementors to decide if/when to do.
05:16 chromatic I can't see how merging C and PCC calling convention parsers and converters makes sense though.
05:16 lathos chromatic: Also, I think we now have all the bits in place we need to port File::Temp. (Apart from mkdir in P6 but we can fudge that in PIR for now.)
05:16 chromatic To Perl 6 or PIR?
05:17 Tene pmichaud: so you want all existing langauges to still work without specifying .HLL?
05:17 lathos Well, we could port it to PIR but that's painful. I was going to do it in P6.
05:17 chromatic Seems reasonable.
05:17 lathos Once I've done that there's a program that'll convert it to PIR for me. :)
05:18 pmichaud Tene: existing languages should continue to work in 'parrot' if that's where they're defined.  It's not up to us to change them.
05:18 chromatic I seem to have written a few of those.
05:18 pmichaud but when they want to switch to .HLL 'language', then there should be a path to do that.
05:18 pmichaud I'm just wanting to make sure that path exists, not force them onto it :-)
05:19 Tene pmichaud: if I drop the 'parent'=>'...' interface in this branch, that will break all P6Object-using languages.
05:19 Tene even ones that are in 'parrot'
05:19 pmichaud I wasn't saying eliminate the existing 'parent'=>'...'  meme -- I'm just saying "don't extend it"
05:19 Tene Ah.
05:19 Tene Okay. :)
05:20 pmichaud still thinking.  there's a solution/refactor for all of this percolating in my mind somewhere and I'm trying to bring ti to the surface
05:21 pmichaud what I _think_ I want is a way to convert a string or array of strings into its namespaces, not its classes
05:21 chromatic Parrot::Embed needs that too.
05:21 pmichaud we can then get to the classes from the namespaces, if/when needed
05:21 Tene That's easy.
05:21 pmichaud namespaces are what we end up passing along to newclass (the opcode) anyway
05:22 pmichaud Tene: yes, but I want that string to be able to specify the hll's also.
05:26 pmichaud so "Foo Bar::Baz" means the ['Foo'] and ['Bar';'Baz'] namespaces in the caller's hll
05:26 lathos Is there any reason not to rewrite the PIR File::Spec in Perl 6?
05:27 pmichaud lathos: the Perl 6 version would likely require the Perl 6 runtime.
05:27 lathos So?
05:27 purl No, se!
05:27 pmichaud the PIR File::Spec doesn't require that.  You asked for "any" reason.  :-)
05:28 lathos Sorry, I meant a good reason. :)
05:28 Tene 'The existing implementation works.'?
05:28 lathos Sorry, I meant a good and accurate reason. :)
05:28 pmichaud heh.
05:29 dalek r34613 | allison++ | branches/pdd22io_part3/src/pmc:
05:29 dalek : [pdd22io] Store full set of options for buffer_type.
05:29 pmichaud From a P6 perspective, having a P6 version of File::Spec will be excellent.
05:29 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34613
05:29 lathos % grep not_yet_implemented runtime/parrot/library/File/Spec/*.pir | wc -l
05:29 lathos 21
05:29 chromatic There are more valuable things to do?
05:29 lathos You said a File::Temp port would be a handy thing, and this is a first step to that.
05:29 pmichaud From a Rakudo perspective, a P6 version of File::Spec will be a very good test to see what other features we need.
05:29 pmichaud From a "will other people use it" perspective, requiring a working copy of P6 might be a minor bump.
05:30 chromatic I prefer not to require a working copy of Rakudo to run Parrot's core tests.
05:30 pmichaud but that's the only disadvantage I can think of.
05:30 lathos My view is that one of the aims of Parrot was to be able to share code between languages and thus it doesn't matter what language stuff is written in.
05:31 TiMBuS joined #parrot
05:31 lathos We could always have a bootstrappy thing that checks in a --output=pir version for common use.
05:31 pmichaud ...except that --output=pir version still needs the runtime.
05:31 chromatic Rakudo won't always be in the Parrot repository.
05:31 lathos That's why I said "bootstrappy"
05:31 chromatic I don't mind checking in a pure-PIR generated version, if it makes tests easier to write.
05:32 pmichaud I'm confused by what "pure-PIR" generated version means, but okay.
05:32 chromatic I prefer that it doesn't require PGE/PCT.
05:33 lathos pmichaud: Right now we have a magic program that turns Perl 6 code into PIR code. We can use that to produce code which does not rely on Rakudo to run.
05:33 pmichaud lathos: have you seen the PIR code that gets generated?
05:33 pmichaud it dependson having the Rakudo classes
05:33 lathos Ah.
05:33 lathos That is unfortunate, then.
05:34 Tene Is there ever a case where the 'new' op should be returning null?
05:34 pmichaud i.e., it's hard for us to say "make a List"  if the List type is only defined in Rakudo.
05:34 Tene PMCNULL, that is?
05:34 chromatic Tene, if something goes agly, I expect an exception not PMCNULL.
05:34 Tene Me too.
05:34 pmichaud or if the generated PIR call makes a call to .say, it's Rakudo's runtime that supplies that method.
05:39 pmichaud (in fact, if one looks at the output of --target=pir from Rakudo, the second sub is one that does `load_bytecode "perl6.pbc"` in order to make sure the runtime library is present :-)
05:40 dalek r34614 | allison++ | branches/pdd22io_part3/t/pmc:
05:40 dalek : [pdd22io] Alter buffer size tests to match actual behavior.
05:40 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34614
05:41 pmichaud Tene:  how about   'parent'=>'parrot;Boolean Any'   ?
05:41 pmichaud I'm looking for something p6-ish
05:41 pmichaud but it can also be parrot-ish
05:42 Tene pmichaud: I like it.
05:42 Tene That's what I would have suggested.
05:42 pmichaud either that or we start looking at other special character markers
05:42 pmichaud e.g.  '*parrot::Boolean Any'
05:43 Tene I like that rather less.
05:43 pmichaud well, the nice thing about that approach is that we continue to split on '::'
05:43 pmichaud and then a leading * on the first element returned indicates "hey, this is a hll"
05:43 pmichaud otherwise we have to look explicitly for a ';' somewhere.
05:44 Tene split on spaces for items, split on ; for hll, split on :: for HLL namespace
05:44 pmichaud oh, that might not be so bad.
05:45 pmichaud let's go with that for now.
05:45 pmichaud so, names passed to P6object are relative to the caller's hll, and use "parrot;" to grab things from a different hll namespace.
05:46 pmichaud I think the "split and convert to namespace" can be abstracted into its own private function, and it's okay with me if *that* function has a :hll option.
05:47 dalek r34615 | allison++ | branches/pdd22io_part3/t/pmc:
05:47 dalek : [pdd22io] Fix UTF-8 test to use the same StringHandle object it wrote to.
05:47 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34615
05:47 pmichaud get_parrotclass wasn't really intended to be user-facing; if it ends up being that way then I may want to rethink it.
05:47 Tene There's going to be at least one commit with that patch I showed you earlier until i get that that, though.  I need to get things working before I make them nice.
05:47 pmichaud you're committing to a branch, yes?
05:48 chromatic pmichaud, did you see my patch from earlier?
05:48 Tene Yes.
05:48 pmichaud Tene: commit as often as you like in the branch.
05:48 pmichaud I don't mind if branches break things.
05:48 pmichaud chromatic: I did see the patch, yes.  it'll be at least a day or two before I can play with it.
05:48 pmichaud I have it saved away for now.
05:49 pmichaud (I'm in the midst of a huge parameter-and-variable refactor in rakudo and that's a branch that can easily get separated from trunk if not done quickly.)
05:49 chromatic Okay.  It's just a quick proof of concept that needs cleanup, but it should be sufficient to let you experiment.
05:50 pmichaud that's exactly what I want.  I can do the experiment and we can see how much it improves things.
05:50 pmichaud I can even make it "switchable" so that we can try both approaches.
05:50 pmichaud and easily time between them.
05:50 pmichaud (or whatever other statistics we wish to run.)
05:51 pmichaud I'll probably make an experiment branch for us to play with.
05:51 GeJ Anyone could point me to some documentation about Key PMCs? I'm not quite sure to understand what they do and how to use them.
05:51 pmichaud gotta run for a bit -- bbiaw
05:52 chromatic GeJ, I'm not sure anyone really understands them either.
05:52 chromatic The problem is that it could represent a string, an array, or a linked list.
05:53 lathos Flattening parameters in Perl 6 doesn't work yet?
05:53 lathos Oh wait, I need to read the exegesis closer.
05:54 lathos Still doesn't work though. :)
05:54 pmichaud flattening arrays works
05:54 Tene rakudo: sub foo { say +@_ }; foo(1, 2, 3);
05:54 pmichaud foo(|@x)
05:54 polyglotbot OUTPUT[3␤]
05:54 pmichaud slurpy parameters "kinda work".
05:54 pmichaud that's what I'm fixing in the branch now.
05:55 lathos | ?!
05:55 Tene rakudo: sub foo { say +@_ }; my @a = 1..10; foo(|@a);
05:55 polyglotbot OUTPUT[10␤]
05:55 Tene rakudo: sub foo { say +@_ }; my @a = 1..10; foo(@a);
05:55 polyglotbot OUTPUT[1␤]
05:55 Tene sure looks like it works ot me.
05:55 pmichaud my @x = <a b>;   foo(@x);  # same as foo('a', 'b');
05:55 pmichaud oops
05:55 Tene lathos: what doesn't work?
05:55 purl Look buddy, doesn't work is a strong statement. Does it sit on the couch all day? Is it making faces at you? Does it want more money? Is it sleeping with your girlfriend? Please be specific!
05:55 pmichaud my @x = <a b>;   foo(|@x);  # same as foo('a', 'b');
05:55 lathos The exegesis doesn't work. :)
05:56 lathos [Update: We had better uses for a "splat" operator, so this flattening is now performed by the [,] reduce operator, which pretends the values passed on the right were originally separated by actual commas. See S03 for more about reduce operators.]
05:56 pmichaud Tene: those are "slurpy params" :-)
05:56 Tene rakudo: sub foo { say +@_ }; my @a = 1..10; foo(@a); foo(|@a);
05:56 polyglotbot OUTPUT[1␤10␤]
05:56 lathos So first it was *@a but that was re-jigged to be [,] @a.
05:56 Tene pmichaud: that doesn't demonstrate flattening?
05:56 lathos I couldn't find |@a
05:57 pmichaud Tene: yes, that's demonstrates flattening _and_ slurpy :-)
05:57 pmichaud lathos:  S06
05:57 Tene It's more typing to demonstrate flattening without slurpy. :)
05:57 lathos I'm looking at S06.
05:57 pmichaud foo(|@onetothree);           # okay:  @onetothree flattened to three args
05:58 lathos Hm.
05:58 lathos No, I'm looking at E06. Fair enough.
05:58 Tene sub f { say $^b; say $^a }; my @a = <one two>; f(|@a);
05:58 pmichaud rakudo:  sub foo($a, $b) { say "$a $b"; };   my @c = <1 5>; say foo(|@c);
05:58 polyglotbot OUTPUT[1 5␤1␤]
05:58 Tene perl6: sub f { say $^b; say $^a }; my @a = <one two>; f(|@a);
05:58 pmichaud rakudo:  sub foo($a, $b) { say "$a $b"; };   my @c = <1 5>; foo(|@c);
05:58 polyglotbot OUTPUT[two␤one␤]
05:58 polyglotbot OUTPUT[1 5␤]
05:59 Tene perl6: sub f { say $^b; say $^a }; f(|<one two>); # I wonder...
05:59 polyglotbot OUTPUT[two␤one␤]
05:59 pmichaud are placeholders allowed in a "sub" definition?  That looks wrong to me.
05:59 Tene huh.  didn't expect that to work.
05:59 Tene pmichaud: yes, only if there's no signature.
05:59 pmichaud Tene: sure -- S06 has
05:59 pmichaud |(1..2, 3);       # List, becomes \(1,2,3)
06:00 pmichaud anyway, I _gotta_ leave.  bbl
06:15 dalek r34616 | allison++ | branches/pdd22io_part3/t/pmc:
06:15 dalek : [pdd22io] Modify 'readall' tests to read from the same StringHandle they printed to.
06:15 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34616
06:16 dalek r34617 | allison++ | branches/pdd22io_part3/src/pmc:
06:16 dalek : [pdd22io] Modify StringHandle's 'readall' to create an empty UTF-8 string when
06:16 dalek : the encoding is set to 'utf8'.
06:16 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34617
06:26 nopaste "GeJ" at 202.22.229.231 pasted "RFC: On proper use of Key PMCs when instantiating new objects." (69 lines) at http://nopaste.snit.ch/15129
06:27 GeJ also there may be a more PIR-ish version of "push $P3, $P4"
06:30 GeJ And again, I have almost no idea of what I'm doing. I'm currently pseudo-randomly pushing keys on my keyboard until I only see 'ok' lines in my terminal. :)
06:33 dalek r34618 | allison++ | branches/pdd22io_part3:
06:33 dalek : [pdd22io] Updating the manifest with new files for StringHandle PMC.
06:33 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34618
06:34 lathos OK, I'm going mad.
06:34 lathos perl6: use Test;
06:35 polyglotbot OUTPUT[Can't find ./Test in @INC␤current instr.: 'die' pc 14740 (src/builtins/control.pir:204)␤called from Sub 'require' pc 15110 (src/builtins/eval.pir:111)␤called from Sub 'use' pc 15172 (src/builtins/eval.pir:134)␤called from Sub 'parrot;Perl6;Grammar;Actions;_block598' pc 109940
06:35 polyglotbot ..(src/gen_actions.pir:1962)␤called from Sub 'parrot;Perl6;Gramma...
06:35 lathos Ah well.
06:35 lathos is(1,1, "foo") is giving me "No applicable candidates found to dispatch to for 'is'"
06:36 Tene Okay, something weird is going on... getting PMCProxy objects when .HLL is set and Class objects when .HLL is not set... not sure from where yet...
06:37 Tene Hmm... it might not be seeing the 1s as objects...
06:37 Tene which would be weird, but possible.
06:37 * lathos svn's up just to be sure.
06:37 Tene lathos: does it do the same thing if you assign the 1s to variables and call is() on the variables?
06:39 lathos Oh this is hideous.
06:39 Tene orly?
06:39 purl YA RLY.
06:39 lathos is(1,1, "Foo"); # Works, of course
06:39 lathos is (1,1, "Foo"); # Fails
06:40 Tene yeah
06:40 Tene no space is allowed between the sub name and the opening (
06:40 lathos Ah.
06:40 lathos Funny way to say it, though. :)
06:40 Tene well, it's trying to call 'is' with no args.
06:41 Tene there's no multi defined for is() that has 0 params.
06:42 lathos I'm still not convinced this is a feature.
06:42 Tene It makes the grammar more regular and predictable.  This is a good thing.
06:43 GeJ synopsis
06:43 purl synopsis is http://git.jrock.us/?p=Bot-Synopsis.git;a=summary
06:43 lathos It's a good thing for the developer, but I actually want to use this language.
06:43 Tene A regular and predictable grammar is a feature for the user, not the developer.
06:44 Tene It has to do with differentiating between postfix, infix, postcircumfix, etc.
06:44 Tene iirc
06:45 lathos We have wildly different understandings of user-friendly.
06:45 Tene http://perlcabal.org/syn/S03.ht​ml#Minimal_whitespace_DWIMmery
06:48 lathos But something is still wrong because Rakudo accepts "foo (1,2)" as a valid statement consisting of a zero-arg sub call and then some data which it completely ignores. foo() (1,2) is a syntax error, and so should "foo (1,2)" be.
06:49 Tene That's right.
06:49 lathos Ah, OK, so when you're saying that it's a feature you actually agree with me that it's a bug. :)
06:50 Tene "Disallow space before the opening bracket of a postcircumfix operator" is a feature
06:50 lathos Here's another fun bug that just got turned up by an svn up:
06:50 lathos % ./perl6 -e 'say eval ""'
06:50 lathos Null PMC access in isa()
06:50 Tene "Don't throw an error message on a grammatical error" is a bug.
06:50 Tene rakudo:
06:53 pmichaud is(1,1,"Foo")   has three arguments
06:54 pmichaud is (1,1,"foo")  has one.
06:54 Tene Ah, right.
06:54 Tene ><
06:56 pmichaud (and there's no multi for "is" that takes only one param)
06:57 dalek r34619 | allison++ | branches/pdd22io_part3/t/pmc:
06:57 dalek : [pdd22io] Add tests for 'read', 'print', and 'close' opcodes on StringHandle.
06:57 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34619
06:57 GeJ in PIR, is there a method I could use to list all the methods that a PMC ca do?
06:57 lathos Oh my this is so confusing.
06:57 lathos perl6: sub foo { say +@_ ~ " arguments, which are: "; for @_ { say $_ }}; foo(1,2,3)
06:57 polyglotbot OUTPUT[3 arguments, which are: ␤1␤2␤3␤]
06:57 lathos perl6: sub foo { say +@_ ~ " arguments, which are: "; for @_ { say $_ }}; foo (1,2,3)
06:57 polyglotbot OUTPUT[1 arguments, which are: ␤1␤2␤3␤]
06:57 Tene GeJ: inspect
06:58 pmichaud lathos: I wouldn't completly trust @_ in subs yet, or any parameter starting with @
06:58 pmichaud that's a known long-standing bug in Rakudo.
06:59 pmichaud in particular, that second version you just wrote should've said "1 arguments, which are\n1 2 3\n"
06:59 pmichaud oh, wait. maybe not.
06:59 pmichaud at any rate, the second one is wrong.
06:59 lathos OK, I see that foo (1,2,3) is a one-argument sub call, but should it be? Shouldn't it just be an error? The synopsis says it's "not allowed".
07:00 pmichaud ...synopsis says it's not allowed?
07:00 Tene Not quite, just that it parses differently
07:00 Tene http://perlcabal.org/syn/S03.ht​ml#Minimal_whitespace_DWIMmery
07:00 lathos Whitespace is no longer allowed before the opening bracket of an array or hash subscript, or the opening parenthesis of an argument list.
07:00 lathos I read that as meaning it's no longer allowed.
07:00 GeJ Tene: Method 'inspect' not found for invocant of class 'Key' :-/
07:01 Tene GeJ: look at the inspect opcode, iirc
07:01 pmichaud lathos: ah.  I suspect that's a typo in the spec.  (more)
07:01 pmichaud technically, the paren in "foo (1,2,3)"  is the opening paren of an argument, not the argument list :-)
07:02 pmichaud i.e.,   foo (1,2,3), 4     has two arguments.
07:02 lathos Ah yes:
07:02 lathos # XXX this one is wrong, it's parsed as code( (5) ) # STD.pm agrees on that.
07:04 * lathos hits ^C on parrotbug and looks for larrybug instead. :)
07:09 dalek r34620 | allison++ | branches/pdd22io_part3/src/pmc:
07:09 dalek : [pdd22io] Change compile-time strings to actual string constants.
07:09 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34620
07:11 dalek r34621 | pmichaud++ | branches/rvar/languages/perl6/t/pmc:
07:11 dalek : [rakudo]:  Update t/pmc/objectref.t tests to not rely on 'assign' op.
07:11 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34621
07:25 dalek r34622 | pmichaud++ | branches/rvar/languages/perl6/src/parser:
07:25 dalek : [rakudo]:  A different refactor for variables, introduces 'itype'.
07:25 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34622
07:26 Tene i'm doing something very wrong here, but I can't quite find it.
07:26 Tene It looks like the parents aren't being set up quite right?
07:29 dalek r34623 | allison++ | branches/pdd22io_part3 (270 files):
07:29 dalek : [pdd22io] Bringing the pdd22io_part3 branch up-to-date with trunk r34621.
07:29 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34623
07:38 Tene pmichaud: rakudo question, if you have a minute.
07:38 pmichaud yes.
07:39 Tene How exactly does P6protoobject get into the class hierarchy for rakudo's protoobjects?
07:39 pmichaud rakudo's protoobjects _are_ P6protoobjects
07:40 Tene Ah, that's what's going on!
07:40 Tene rakudo extends P6protoobject through languages/perl6/src/classes/Protoobject.pir
07:40 pmichaud it doesn't actually "extend" it -- it just adds more methods.
07:41 Tene I'm getting a failure on calling .'!IMMUTABLE'() because that function is now defined in the perl6 HLL
07:41 Tene so should Protoobject.pir be set .HLL 'parrot' or something?
07:41 pmichaud yes.
07:42 pmichaud actually, each .pir probably needs to set its .HLL
07:42 pmichaud (it's okay if only a few do it for now.)
07:48 Tene For now I'm just putting .HLL 'perl6' at the end of Protoobject.pir
07:49 pmichaud wfm
07:50 Tene Hmm... 'parent'=>'PGE::Match Any'...
07:50 Tene Should that be parrot;PGE::Match ?
07:50 pmichaud yes.
07:52 Tene yay, segfaults!
07:55 Tene Program received signal SIGSEGV, Segmentation fault.
07:55 Tene 0x0000003fcb07c605 in calloc () from /lib64/libc.so.6
07:55 Tene from mem_sys_allocate_zeroed
07:55 Tene very nice
07:56 Tene oh, infinite loop
07:56 purl see infinite regress
07:56 Tene infinte regress?
07:57 Tene from Parrot_oo_get_class_str
08:09 dalek r34624 | allison++ | trunk (11 files):
08:09 dalek : [pdd22io] Merging the pdd22io_part3 branch into trunk for r34353 to r34623.
08:09 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34624
08:09 dalek r34625 | allison++ | branches:
08:09 dalek : Removing third I/O development branch from the repository
08:09 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34625
08:13 Tene allison: around?
08:14 iblechbot joined #parrot
08:14 allison Tene: yup
08:15 Tene Hmm.  Maybe nevermind.  I'm trying to debug an infinite loop with HLL stuff.  I don't have a specific question anymore, though.
08:16 Tene Something in rakudo tried to create a Hash and it hits an infinite loop of PMCProxies being created for PMCProxies, afaict
08:17 allison Tene: hmmm... it should only create it once, and then use the cache'd one.
08:17 Tene I think it might be in Parrot_oo_get_class_str
08:18 allison Tene: but then, if you structured it just right, it would be possible to have it attempt to do a look up of PMCProxy while it's in the middle of creating the cache'd proxy for PMCProxy
08:18 Tene Interested in helping me debug this?
08:19 allison Tene: I have a few spare cycles, where's the code?
08:19 Tene Lemme commit.
08:21 Tene pct_hll branch
08:21 dalek r34626 | tene++ | branches/pct_hll (15 files):
08:21 dalek : Start of support for HLL in PCT.  Doesn't work.
08:21 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34626
08:22 dalek r34627 | pmichaud++ | branches/rvar/languages/perl6/src/parser:
08:22 dalek : [rakudo]:  Refactor to hold attributes on the PAST::Var node directly
08:22 dalek : instead of the block's symbol table.  This uses a big-time cheat with
08:22 dalek : PCT's currently implementation, but I'll think about ways to make
08:22 dalek : something like it official.
08:22 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34627
08:22 Tene You can reproduce by trying to start rakudo.
08:23 nopaste "tene" at 166.70.38.237 pasted "Here's the start of the bt I get" (32 lines) at http://nopaste.snit.ch/15130
08:26 Tene I'm not certain that I'm not doing something stupid here.  It's quite possible.
08:26 allison Tene: building now
08:26 allison Tene: what's changed in the branch? or, what were you working on?
08:26 Tene .HLL 'perl6'
08:26 purl hmmm... .HLL 'perl6' is equivalent to .HLL 'perl6'
08:27 Tene purl: forget .HLL 'perl6'
08:27 purl Tene: I forgot .hll 'perl6'
08:31 Tene The last line in parrot -t is returncc... unsure if that's going to be the op it segfaults on or the one before that.
08:32 pmichaud btw, my "rule of thumb" these days is that segfaults are often related to .tailcall in the wrong places.
08:32 pmichaud _especially_ if they seem to occur in/around returncc
08:33 Tene pmichaud: any idea on getting parrot to tell me the file/line it's on in a trace?
08:33 pmichaud Tene: no, haven't seen that, sorry.
08:33 pmichaud did you try -t5 ?
08:33 allison Tene: doesn't look like you changed much
08:33 Tene allison: I haven't yet.
08:34 Tene pmichaud: much nicer.  thanks.
08:35 allison Tene: and my money is on runtime/parrot/library/P6object.pir as the source of the problem, possibly in parent_loop
08:35 allison (just scanning diffs now, while I wait for the compile)
08:37 Tene It comes from trying to instantiate an 'IO'
08:40 pmichaud ...wow, that's actually a good ways into initialization then.
08:40 Tene looks like Object.pir:294
08:40 Tene $P0 = p6meta.'get_parrotclass'(self)
08:40 Tene $P1 = new $P0
08:40 pmichaud be aware that tracing and segfaults don't always play well together
08:41 * Tene confirms
08:41 pmichaud sometimes the segfault halts the program before the trace buffers have flushed.
08:41 Tene Hmm.  You might be right.
08:42 Tene Still a good ways into initialization, though.
08:42 Tene Definitely in that function.
08:46 Tene Yeah, looks lke it's Object.pir:351, which is "init_attribs = new 'Hash'" and matches with what I thought was going on.
08:47 gaz joined #parrot
08:48 Tene and "new 'Hash'" reproducably dies earlier in the process.
08:49 pmichaud is that in Perl6Object's "new" method?
08:49 Tene Yes.
08:49 Tene Called from globals.pir:60
08:49 pmichaud it wouldn't surprise me if that's not completely right.
08:49 Tene Well, "new 'Hash'" dies if I call it from globals.pir earlier
08:49 allison Tene: looks like it does call 'Parrot_oo_get_class_str' from within PMCProxy's 'init_pmc', but only when it encounters 'scalar' as a classname
08:50 Tene allison: the classname there is 'Hash' according to gdb
08:50 allison ah, wait, it's that reversed string_equal logic
08:50 Tene That's != 0, which is "does not encounter scalar"
08:50 allison it's for all classnames except 'scalar'
08:50 Tene yeah
08:51 allison this is when I wish I had git, to quickly see when those lines were added
08:52 Tene I can check.  justasec.
08:53 lathos Hm, I used parrotbug but now I can't see if it got through.
08:53 Tene jonathan
08:53 purl i guess jonathan is mailto:jnthn@jnthn.net or trying to put together a grant application.
08:53 dalek r34628 | pmichaud++ | branches/rvar/languages/perl6/src/parser:
08:53 dalek : [rakudo]:  Bring ordinary variable declarations in line with the way
08:53 dalek : parameters are being declared from r34627.
08:53 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34628
08:53 Tene r33520
08:53 Tene "[core] PMCProxy wasn't yet building and keeping an MRO nor a parent list. Th
08:53 Tene ..."
08:56 allison it's the "skip ourself" part that doesn't seem to be working
08:56 allison and, there's not any code to ensure it skips itself
08:57 pmichaud ...maybe because it starts at i = 1  instead of i = 0 ?
08:58 pmichaud (i.e., it thinks "ourself" is element 0?)
08:59 Tene Also, if I remove the 'name'=>'Hash' part of Hash.pir, it doesn't die like this.
08:59 pmichaud that's odd.
08:59 pmichaud that really shouldn't have an impact.
08:59 pmichaud out of curiosity, did you try with -G ?
09:00 Tene P6object uses the name parameter to decide the namespace it's stored in, if present.
09:00 Tene Parrot-oo_get_class_str looks in the current HLL's namespace.
09:00 Tene -G makes no difference.
09:01 pmichaud oh.
09:01 pmichaud that's definitely a problem.
09:01 Tene Which part?
09:01 purl the IMPORTANT part!
09:01 Tene purl: forget which part
09:01 purl Tene: I forgot which part
09:02 pmichaud 'name'=>'Hash' means that p6object will create a protoobject at   set_hll_global 'Hash'
09:02 Tene Is that not what P6Object should do?
09:02 pmichaud yes, it is what P6Object should do
09:02 Tene Okay.
09:02 pmichaud but then Parrot_oo_get_class_str will get confused if it expects to find something else there.
09:03 Tene Right.  This is the sort of thing I expected to run into doing this before the class registry stuff was sorted out.  The meaning of new_*_sc and friends.
09:03 pmichaud i.e., Parrot_oo_get_class_str is being asked to find "Hash" based on its name.
09:04 pmichaud and if it's doing that by trying to look up the namespace in the current hll (as opposed to the hll where "Hash" is really stored), then kaboom.
09:04 Tene Well, it still shouldn't be segfaulting after an attempt at an infinite loop. :)
09:04 pmichaud of course, imo it's very wrong that init_pmc is trying to use class*names* to set up the MRO
09:05 Tene I've never looked at the MRO stuff at all.
09:05 pmichaud mro = method resolution order
09:05 allison pmichaud: yes, it should be using types
09:06 pmichaud apparently what init_pmc is doing is "get me the next mro type as pclass"
09:06 pmichaud then "okay, give me the name corresponding to pclass"
09:06 pmichaud then "okay, look up the proxy based on the name"
09:06 pmichaud there ought to be a way to go from pclass to proxy without having to get a name to look it up.
09:06 allison though, it's worse than that, it pulls the class object from the MRO array, then asks it for its name, then looks it up by name. huh?
09:06 pmichaud class object != proxy, perhaps?
09:07 pmichaud but yes, I find that weird also.
09:09 Tene I also don't know what PMCProxies are for, or why 'new "Hash"' needs to create one.
09:09 Tene Many parts of Parrot I still don't understand well yet.
09:11 allison Tene: PMCProxies allow PIR classes to have C PMCs as their direct parents
09:11 Tene Ah.
09:13 kj joined #parrot
09:14 allison why 'new "Hash"' needs to create one is an important question, though :)
09:14 pmichaud I suspect that somewhere along the way the "Hash" got looked up wrong also.
09:14 Tene does each instance of a PIR class get one?
09:14 allison pmichaud: yes, very possibly
09:14 pmichaud Tene: normally no
09:14 allison Tene: no, only C classes get a proxy
09:15 pmichaud it's one per class, not one per instance
09:15 allison which is why this code is very wrong
09:16 pmichaud I bet I can come up with a shorter test... just a sec.
09:20 pmichaud nope, apparently not.
09:22 Tene pmichaud: yeah, ->mro is [this class, parent1, parent2, ...]
09:22 Tene so starting at 1 is skipping self
09:23 allison whoami usually only reports the basename, not the hierarchy
09:23 Tene allison: so it gets the basename and then re-looks it up in the current hll namespace?  That sounds broken...
09:23 allison yes, it is broken
09:24 allison (experimenting with a few fixes now)
09:24 pmichaud why do we have to do a lookup at all?
09:25 pmichaud oh dear
09:26 * pmichaud looks at Parrot_oo_get_class_str
09:26 allison does the Perl 6 'Hash' inherit from the C PMC 'Hash'?
09:27 pmichaud yes, but the Perl 6 'Hash' is named 'Perl6Hash'
09:27 pmichaud i.e., it has a Parrot name of 'Perl6Hash'
09:27 pmichaud (unless Tene changed it in the branch)
09:27 Tene But stored in ['perl6';'Hash'] in the branch
09:27 pmichaud ....?
09:27 purl dot dot dot *yawn* dot
09:27 allison pmichaud: I did try cutting the lookup out entirely, and just storing the class object from the MRO directly, I got a lot of test failures about a missing 'parents' method
09:27 pmichaud what do you mean "stored in ['perl6';'Hash'] in the branch?
09:28 allison pmichaud: which tells me, that other code was expecting a Proxy object in the inheritance hierarchy and finding some other kind of object
09:29 nopaste "tene" at 166.70.38.237 pasted "'stored in [hll;:name]' for pmichaud++" (15 lines) at http://nopaste.snit.ch/15131
09:29 pmichaud allison:  what bugs me about Parrot_oo_get_class_str is that it's going to end up creating a Proxy object in every hll namespace.
09:29 pmichaud that is, "creating a _new_ Proxy object..."
09:29 allison pmichaud:?
09:30 pmichaud Parrot_oo_get_class_str looks for a proxy object
09:30 pmichaud in the current hll namespace root
09:30 pmichaud sorry, let me rephrase more precisely
09:30 allison pmichaud: it shouldn't. it should only create them in the HLL namespace of the C PMC
09:30 pmichaud PMC * const hll_ns = VTABLE_get_pmc_keyed_int(interp, interp->HLL_namespace,
09:30 pmichaud CONTEXT(interp)->current_HLL);
09:30 pmichaud PMC * const ns     = Parrot_get_namespace_keyed_str(interp, hll_ns, name);
09:30 pmichaud looks like it's in the hll of the interpreter.
09:32 allison yes, that's true
09:32 allison looks like an overzealous conversion to use HLL namespaces
09:33 pmichaud if I call Parrot_oo_get_class_str to look up "Hash" from a hll other than parrot
09:33 pmichaud then the lookup for the class will look in the wrong namespace
09:34 pmichaud and it will fail, so it will then create a new PMCProxy for "Hash" and give me that.
09:34 pmichaud and every call to obtain "Hash" will end up with a different PMCProxy
09:35 allison yes, I agree with that assessment
09:35 allison this needs to be fixed along with other changes to use real hierarchical namespaces
09:37 alvar joined #parrot
09:38 pmichaud Tene: you _might_ be able to get away with replacing $P0 = new "Hash" with
09:38 pmichaud $P0 = get_root_namespace ['parrot';'Hash']
09:38 pmichaud $P0 = get_class $P0
09:38 pmichaud $P0 = new $P0
09:38 pmichaud thus avoiding the string lookup altogether.
09:38 nopaste "tene" at 166.70.38.237 pasted "This avoids the crash. Don't know how correct it is." (16 lines) at http://nopaste.snit.ch/15132
09:39 pmichaud Tene: that works if we assume that all string class lookups are in the "parrot" namespace.
09:40 Tene Isn't that what you wanted to presume?  I really need to start keeping notes on what's planned so I can stop asking you to repeat yourself.
09:41 Tene Yeah, not a good fix.
09:41 pmichaud you mean presume at the opcode level?  no, that wasn't what I proposed.
09:41 Tene Right, that wouldn't work.  I get it now.
09:41 pmichaud I would want a lookup by string to look in the class registry.
09:41 pmichaud and not check namespaces at all.
09:43 allison pmichaud: that fix won't work, because it's always looking in the parrot namespace
09:43 pmichaud allison: I think that's what I said.
09:43 allison so, all class lookups in the entire system will only look in the parrot namespace
09:43 Tene which isn't the right behavior for that function.  Yes, that's what he said.
09:43 allison yeah
09:44 allison really, that should be a search, rather than a single lookup in a single place
09:44 pmichaud allison, did you see my proposal for fixing class lookups yesterday?
09:44 * pmichaud searches
09:45 allison pmichaud: no, in email?
09:46 pmichaud no, on irc.   http://irclog.perlgeek.de/​parrot/2008-12-27#i_788597
09:49 pmichaud basically it divorces the class registry from namespaces, and says that looking up a class by string always grabs things from the registry (and only the registry)
09:51 pmichaud but it avoids a "search for a class" step, which I think would likely be a source of long-term problems.
09:58 allison pmichaud: actually, it should go the other way around, and only lookup in the namespace
09:58 pmichaud allison:  huh?
09:58 allison but you're absolutely right that having two locations to look up classes is what's snarling us up
09:59 barney joined #parrot
09:59 allison well, the registry is on the way out
09:59 pmichaud if I want to lookup in the namespace, there's a good syntax for doing that
09:59 pmichaud $P0 = get_class ['Foo';'Bar']
09:59 pmichaud or
09:59 pmichaud $P0 = get_class ['Foo']
09:59 pmichaud that should mean "look up in the namespace"
10:00 TiMBuS joined #parrot
10:00 allison yes, nothing should be looking up a class in the registry
10:00 pmichaud to the extent that the class registry exists, it should be there to make it easier to grab the types that aren't in a local namespace
10:00 pmichaud i.e.,  so that I can still get a Parrot Integer without having to do a get_root_global first.
10:00 allison no, that's not it's purpose, it's just a unique id store
10:01 allison looking up classes that aren't in your local namespace should always go through the other namespace
10:01 pmichaud that will truly be a pain.
10:01 allison really, it's much simpler
10:01 pmichaud how is
10:01 pmichaud $P0 = get_hll_namespace ['parrot';'Integer']
10:01 pmichaud $P1 = new $P0
10:01 pmichaud simpler than
10:01 pmichaud $P1 = new 'Integer'
10:01 pmichaud ?
10:02 allison remember HLLs can subclass the namespace object, and have their own custom namespace
10:02 allison oh, no, no, no, you misunderstand me
10:02 allison $P1 = new 'Integer' # does a lookup in the namespace, not the registry
10:03 pmichaud that's not a big improvement over
10:03 allison everything does a lookup in the namespace, not the registry
10:03 allison all the backend code
10:03 pmichaud $P1 = new ['Integer']
10:03 allison well, those two should be isomorphic
10:03 pmichaud being able to use 'Integer' as a shortcut for ['Integer'] isn't very helpful
10:03 allison huh?
10:03 pmichaud especially since there's not really a good isomorph for  ['Foo';'Bar']
10:04 allison I don't follow
10:04 pmichaud you're saying that  $P1 = new 'Integer'  should look up my HLL's Integer class
10:04 pmichaud yes?
10:04 purl yes is that a trick question?  :)
10:04 Tene purl: forget yes
10:04 purl Tene: I forgot yes
10:04 allison yes
10:04 pmichaud I'm saying that   $P1 = new ['Integer']    does exactly this
10:04 allison yes
10:05 pmichaud and that there's no need to have  $P1 = new 'Integer'   do this function.
10:05 allison adding brackets to a single string doesn't do anything different
10:05 allison the brackets just group the strings
10:05 pmichaud I thought they created keys
10:05 pmichaud i.e.,   new ['Integer']   and new 'Integer'  would in fact be different opcodes.
10:06 allison yes, which in this case acts as a constant array of strings
10:06 allison or a list
10:06 allison so '
10:06 allison so ['Integer'] is a single element list
10:06 pmichaud is it really that way internally?
10:06 allison which is equivalent to 'Integer' without the brackets
10:06 pmichaud if I do     $P0 = get_namespace ['Integer'],   that's identical to   $P0 = get_namespace 'Integer' ?
10:06 allison yes, that's the way it's implemented
10:06 allison pmichaud: yup
10:07 * pmichaud checks.
10:07 dalek r34629 | kjs++ | trunk/compilers/pirc/new (3 files):
10:07 dalek : [pirc] count :named parameters twice; 1 for the argument, 1 for the :named flag value (name)
10:07 dalek : + add commments
10:07 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34629
10:08 pmichaud there is no   get_namespace_p_sc opcode.
10:08 allison well, you were asking about 'new'
10:09 pmichaud I'm saying that 'new' ought to act like get_namespace in this respect.
10:09 pmichaud just a sec, still checking.
10:11 allison it drills down to 'internal_ns_keyed_key' in src/global.c
10:11 pmichaud so, which opcode does   $P0 = new ['Foo']   call?  Does it call   new_p_sc   or does it call n_p_pc   ?
10:12 pmichaud sorry, new_p_pc
10:12 allison p_pc
10:12 pmichaud right, so it's not really the same as   $P0 = new 'Foo'
10:12 allison becaue it's a pmc constant
10:12 dalek r34630 | kjs++ | trunk/compilers/pirc/new:
10:12 dalek : [pirc] count :named arguments twice as well; once for the argument itself, once for the :named() flag value.
10:13 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34630
10:13 pmichaud right, that's my point.
10:13 allison yes, but they both call the same code
10:13 pmichaud but they don't have to.
10:13 pmichaud (more)
10:13 allison which ultimately calls 'internal_ns_keyed_key' , which iterates over each string in the key
10:13 allison doing exactly the same thing as a string
10:14 dalek r34631 | kjs++ | trunk/compilers/pirc/new (2 files):
10:14 dalek : [pirc] slightly more efficient code for parameter counting.
10:14 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34631
10:14 pmichaud they don't do the same thing, though.
10:14 allison and then they both call 'internal_ns_maybe_create' with the string
10:15 * pmichaud looks.
10:15 allison whether you pass a string or a key, they ultimately call the same function
10:15 TiMBuS if i provide an 'invoke' vtable method with a parrot class, it says i need to pass it an argument when i try to call it. erm. what is it expecting?
10:15 pmichaud new_p_pc   calls Parrot_oo_get_class
10:15 pmichaud new_p_sc  calls Parrot_oo_get_class_str
10:17 pmichaud I'm saying that Parrot_oo_get_class should always grab a class based on the hll namespace
10:17 pmichaud which is what it does now.
10:18 pmichaud that's the new_p_pc  ($P0 = new ['Integer'])  form
10:19 allison okay, yes, that is what it should do, and so should new_p_sc
10:19 pmichaud so then how do I make a new Parrot Integer from another HLL?
10:20 allison by an excessively long route of looking up the namespace of the other language, and doing a lookup on that namespace object
10:20 pmichaud I'm saying new_p_sc can avoid that excessively long route
10:20 allison but, you have to pick one for the short form, and looking up a class in the same HLL is the more common of the two
10:20 allison pmichaud: that'd be terribly confusing
10:20 pmichaud because we don't need new_p_sc to do the equivalent of the common form
10:21 pmichaud because there's already a convenient way to do the common form
10:21 allison because the string form is the more common of the two
10:21 pmichaud but it shouldn't be.
10:21 allison well, it's easier to type
10:21 pmichaud we're talking generated code.
10:21 pmichaud and it's only one set of brackets.
10:21 allison yes, but PIR is both generated and hand written
10:22 allison and really, generated code should just use the fully-specified path all the time
10:22 allison it's easier
10:22 allison (and safer)
10:22 pmichaud I think hand-written code should do the same, for the same reasons.
10:23 allison now, if lookups were searches, rather than just hitting one namespace, we could always check if the first item in the key is an HLL name
10:23 allison but, that has some problems with portability
10:23 pmichaud -1
10:23 purl -1
10:24 pmichaud because then we have to worry about "what if there's a namespace that matches an HLL name", etc.
10:24 allison your code that works fine breaks when you suddenly install a language named, say "Hash"
10:24 pmichaud exactly.
10:24 allison right
10:24 pmichaud I don't mind doing the namespace lookups for other HLLs
10:24 allison and, there's the option of adding a special character before HLL names
10:24 allison like '*parrot';'foo';'bar'
10:24 pmichaud where "other HLLs" is "other HLLs other than parrot"
10:25 allison and '*parrot;foo;bar'
10:25 pmichaud going the excessively long route is fine there
10:25 allison yes, but any automated searching we do of the parrot namespace just pollutes the HLL namespace
10:25 pmichaud right, so I'm saying no searching at all.
10:26 allison that is, if you search for 'Hash' and always find the parrot 'Hash', then you've effectively filled that space in the HLL namespace, even though it's empty
10:26 pmichaud that's my point!
10:26 allison then I have no idea what we're debating :)
10:27 pmichaud if we break the connection between 'Hash' and ['Hash'], then we get both.
10:27 allison no, we don't
10:27 pmichaud because ['Hash'] is the HLL namespace version of Hash, and 'Hash' can be something else.
10:27 allison that just moves the problem to another location
10:27 pmichaud how so?
10:28 pmichaud I'll phrase it a different way, and then I should get to bed (4:30am here)
10:28 allison because then you have people horribly confused trying to figure out why 'foo;bar' does something completely different than ['foo';'bar']
10:28 pmichaud I think that 'foo;bar' is equivalently bad, fwiw.
10:28 pmichaud actually, even worse.
10:29 allison I originally implemented it so the bracketed namespace always had to be fully specified
10:29 pmichaud because I can't tell if 'foo;bar' means ['foo';'bar']  or ['foo;bar']
10:29 allison so ['parrot';'foo';'bar']
10:29 pmichaud that's also bad.
10:29 allison yeah, it drove people nuts
10:29 allison I mean, namespaces are already pretty messy
10:30 pmichaud I'm not aware of anywhere else where we allow  'xyz' to be a shortcut for ['xyz']
10:30 pmichaud I can't do    get_hll_global $P0, 'xyz', 'name'
10:30 pmichaud I don't think I can do (anymore)    .namespace 'xyz'
10:30 allison well, anywhere it iterates over a key one at a time performing an action on the string will have the same result as performing an action on a string
10:31 allison I'm happy to remove the bare string version entirely
10:31 pmichaud so the argument that $P0 = new 'xyz'  is somehow superior to   $P0 = new ['xyz']   doesn't fit with the rest of parrot
10:31 allison but completely different behavior for two characters difference is just bad design
10:32 pmichaud heh
10:32 allison the bare string is just a convenience
10:32 pmichaud by that argument,   "string" and 'string' should be the same :-)
10:33 allison that one bites me all the time
10:33 allison but, it's pretty fixed in the culture at this point
10:34 pmichaud okay.
10:34 pmichaud I'll leave with this summary then
10:34 pmichaud (1) removing the bare string version entirely is fine with me
10:34 pmichaud that's where I was thinking we'd ultimately head anyway
10:34 tomyan joined #parrot
10:35 pmichaud (2) in the meantime, using the bare string version to mean "look up via class registry only" is an awfully convenient migration shortcut.
10:35 allison as long as it doesn't do anything special, the bare string version is pretty unoffensive
10:35 allison people will start depending on it though, and the class registry is definitely going away
10:35 allison I really don't want the registry exposed to PIR at all
10:36 allison I can see adding a 'new_from_root' or something like that
10:36 pmichaud to be honest, whenever I've used the bare string version I've always thought of it as being "special" and not the same as a class-by-namespace lookup.
10:36 allison that takes a fully-specified namespace path instead of hll namespace path
10:37 allison which is probably why this solution occurs to you. but it is doing a class-by-namespace lookup
10:38 pmichaud yeah, I wouldn't think of it as being a class-by-namespace lookup because to me "namespace in pir" has brackets.
10:39 allison well, a string name containing ';' characters splits out into an array
10:39 pmichaud that's icky.
10:39 allison yeah, probably so, but it was a necessary part of the migration
10:40 kj jonathan: ping
10:40 pmichaud this whole identifying a class by a string is just something we need to eliminate.
10:40 allison there's a fair bit of ickyness there, and I'm cringing right now because it looks like a lot more ickyness has crept in since we did the OO refactor
10:40 * allison sighs
10:40 allison pmichaud: yes
10:40 pmichaud okay.
10:41 allison classes should be identified by class object
10:41 allison and only by class object
10:41 pmichaud namespace if the class object isn't immediately available?
10:41 allison yes, namespace object is an acceptable alternative
10:41 pmichaud okay.
10:41 pmichaud PGE, PCT, and Rakudo will now evolve to eliminate all instances of   new_p_sc
10:42 allison music to my ears :)
10:42 pmichaud but we need a short-term solution.
10:42 pmichaud to the registry problem.
10:42 allison I'm not sure what the registry problem is
10:43 allison (other than the fact that it needs to die)
10:43 pmichaud I still can't create same-named classes across multiple HLLs
10:43 pmichaud and you just saw the issue with Parrot_oo_get_class_str
10:43 pmichaud that's going to be a HLL blocker, unfortunately.
10:44 allison yeah, that's a stupidity of looking up classes by string name :(
10:44 allison how about if we just replaced the registry with the namespace tree
10:44 allison each namespace object gets a unique id that it stores
10:45 dalek r34632 | kjs++ | trunk/compilers/pirc/new (4 files):
10:45 dalek : [pirc] insert the value of a :named flag as an extra argument. +Do some magic with flags.
10:45 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34632
10:45 AlexLibman joined #parrot
10:46 pmichaud that would probably work.  Ultimately the problem is fixing all of the code that currently uses Parrot_oo_get_class_str, I suspect.
10:47 pmichaud I think that function ought to just go away also, if we only look up classes by namespace.
10:47 pmichaud (or class object, or whatever else we're using besides strings)
10:48 allison what it used to do was just call Parrot_oo_get_class
10:48 allison but that was considered slow, because it created a PMC String
10:48 dalek r34633 | bernhard++ | trunk (2 files):
10:48 dalek : [codingstd] set SVN properties
10:48 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34633
10:49 pmichaud yes, but if I pass a Key or String to Parrot_oo_get_class, I kind of assume that it's relative to my HLL.
10:49 allison and I think the code has diverged since the two were split
10:49 pmichaud Existing code likes to use Parrot_oo_get_class_str as a quick way to find, say "Integer"
10:49 allison that's fine as long as Parrot_oo_get_class_str and Parrot_oo_get_class do the same thing
10:50 allison it's only bad if they do different things
10:51 allison hmmm... looks like they do the same thing
10:51 allison (lookup the name relative to the HLL root, create a proxy if it's not found)
10:52 masak joined #parrot
10:55 pmichaud okay, so what's the correct workaround for something like  src/pmc/capture.pmc:529 ?
10:56 lathos You want to workaround a workaround?
10:56 pmichaud lathos++
10:56 pmichaud what's the correct approach for doing what src/pmc/capture.pmc is currently working around?  ;-)
10:57 pmichaud (point to example is fine :-)
10:57 allison pmichaud: what's it trying to do?
10:57 allison pmichaud: just instantiate a Capture object?
10:57 pmichaud that's an old (possibly outdated) pattern
10:58 pmichaud if someone subclasses the Capture PMC, then we needed a way to get back to the non-proxied PMC instance
10:59 pmichaud (I didn't write this code -- I just did a search for places using Parrot_oo_get_class_str and this popped up)
10:59 pmichaud I guess it just needs to be using the GET_ATTR_array macro?
10:59 pmichaud oh, no.
11:00 pmichaud oh, yes.
11:00 allison I'm not sure why that code doesn't just create a 'pmc_new(INTERP, enum_class_Capture)'
11:00 lathos It's not instantiating anything.
11:00 pmichaud it's not creating a Capture, it's creating the array portion of the capture
11:00 lathos It's turning an existing capture into a list.
11:00 pmichaud it's adding a list component to a capture
11:00 allison lathos: it is, with CAPTURE_array_CREATE
11:00 pmichaud Capture objects create their list and hash components lazily, on demand.
11:00 pmichaud instead of always creating a list and/or hash PMC when the Capture itself is created.
11:01 allison though, what it's instantiating there is a resizable array
11:01 lathos Yeah, that create is more of a check AFAICS.
11:02 lathos if (!PARROT_CAPTURE(obj)->array) { make one }
11:02 pmichaud the list part is a resizablepmcarray, yes
11:02 lathos But the issue is not the array bit of the capture, the issue is when the capture itself is a proxied object.
11:02 pmichaud what the workaround is (was?) doing was making sure that "capt" was correctly pointing at the PMC that contains the array and hash slots
11:03 pmichaud which isn't (wasn't?) the case for a subclassed instance of Capture
11:03 allison if I read that right, it's instantiating a resizable array, and storing it as the 'array' attribute on an instance of Capture
11:03 pmichaud that's what CAPTURE_array_CREATE does, yes.
11:04 lathos allison: We're talking about the bit before that. (Are your line numbers up to date?)
11:04 allison (though it looks like it should be storing it on the 'array' attribute of a PMCProxy of Capture, but it can't possibly be doing that because PMCProxies don't have an array attribute
11:05 lathos So what it does instead is get the real underlying capture and store on that instead. It's how it should get at the underling Capture that we're wondering.
11:05 allison lathos: yes, but I can't say how to eliminate the work around until I can say for sure what the workaround is doing
11:05 pmichaud if I have   $P0 = subclass 'Capture', 'MyCapture'
11:05 allison is this code actually tested anywhere?
11:05 pmichaud $P1 = new 'MyCapture'
11:05 pmichaud $P2 = $P1.'list'()
11:06 pmichaud then this method is called
11:06 lathos Yes, look in t/pmc/capture.t
11:06 pmichaud however, SELF is an instance of MyCapture, not a Capture PMC
11:06 allison and $P2 should be what?
11:06 lathos Specifically pir_output_is( <<'CODE', <<'OUTPUT', 'list method delegation' );
11:06 pmichaud ($P2 will end up being an empty ResizablePMCArray in this instance)
11:06 pmichaud (but what $P2 ends up with is somewhat irrelevant to what I'm asking about.)
11:07 pmichaud so, as part of the 'list' method, a new ResizablePMCArray should be created if it doesn't exist, and placed in the Capture PMC's array slot
11:07 allison Okay, well either way, what it should be doing instead is either a straight lookup of the Capture PMC
11:07 pmichaud where "straight lookup" is...?
11:08 allison (which will lookup the Capture namespace and return the class)
11:08 lathos Which is basically what we are asking how to do.
11:08 allison or, it should be instantiating enum_class_Capture
11:08 pmichaud note that I'm not creating a Capture PMC in this method.
11:08 allison A straight lookup is 'PMC    *classobj  = Parrot_oo_get_class_str(INTERP, classname);'
11:08 pmichaud that's not what we're doing.
11:09 pmichaud mypoint is that this is *wrong*
11:09 allison that whole business with the proxy is a red herring
11:09 pmichaud we can't use Parrot_oo_get_class_str here.
11:09 allison why not?
11:09 allison is it not relative to the current HLL?
11:09 lathos You have to deal with the proxy somehow if someone calls list() on a Capture subclass.
11:09 allison it's a class in the 'parrot' hll?
11:09 pmichaud only if the interpreter was somehow set to Parrot prior to calling this method
11:10 allison yes, but get_class returns a proxy for C-level classes
11:10 allison so, the code here shouldn't have anything to do with the proxy
11:10 allison okay, I get it
11:11 allison this isn't a 'proxy' as in a PMC proxy for the class
11:11 dalek r34634 | bernhard++ | trunk/languages/pipp/t/php:
11:11 dalek : [Pipp] untodo a test case
11:11 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34634
11:11 allison this is the delegate object
11:11 lathos Yes!
11:11 pmichaud right.
11:11 pmichaud sorry, I didn't know/remember the term "delegate object"
11:11 allison which should be named 'delegate' or something sane
11:12 allison so, those sick delegate objects go away if you use GET_ATTR_*
11:12 pmichaud okay, that was what I was hoping.
11:12 pmichaud so I'll switch things to use GET_ATTR_*
11:13 allison so, if you need the 'foo' attribute of the parent C class, just declare one of the same type and name in the child class
11:13 allison in the child PIR class
11:13 pmichaud yeah, I don't have any instances of those.
11:13 allison ultimately this will be automated by simply calling 'subclass', but I don't think it's automated yet
11:14 lathos Incidentally, would it be useful to allow both relative and absolute access (think pathnames) to namespaces?
11:14 allison lathos: that's what we were talking about
11:14 pmichaud lathos:  we do that with the get_hll_namespace and get_namespace opcodes
11:15 pmichaud also with get_hll_global and get_global
11:15 pmichaud (and get_root_* variations of these as well)
11:15 allison lathos: and the answer is yes, but to reserve the short form for the relative namespaces
11:15 allison lathos: that is, short form as relative to hll root
11:15 pmichaud allison: iiuc,  the 'new' opcode doesn't use relative namespaces, though, yes?  or it's just relative to hll root
11:15 pmichaud okay.
11:16 pmichaud relative to hll root is fine with me.
11:16 allison pmichaud: yeah, only relative to hll root
11:16 pmichaud the other is easily done with get_namespace :-)
11:16 allison yeah
11:16 lathos Ack, I forgot the HLL/Parrot root dance too.
11:16 lathos Perhaps we need pathnames with drive letters. ;)
11:16 allison lol :)
11:17 pmichaud I want to reserve the Z: drive for Rakudo, then :-)
11:17 pmichaud allison: doing a quick search for Parrot_oo_get_class_str doesn't turn up too many instances, so I think we're in okay shape.
11:18 pmichaud we do need to fix that pmcproxy.pmc case at some point.
11:18 allison pmichaud: that's good
11:18 pmichaud there's a bunch in the delegate.pmc code, though.
11:18 pmichaud the rest look pretty sane to me.
11:19 allison delegate.pmc is in desperate need of a refactor anyway
11:19 allison needs to be using class objects
11:19 pmichaud I can fix the instances in capture.pmc, and there's one in class.pmc that is probably suspicious.
11:20 allison and then there's this one in pmcproxy.pmc that we know is broken
11:20 allison (the start of this conversation)
11:20 pmichaud yes -- maybe jonathan can do something with thatl.
11:20 pmichaud (since he wrote it, I think :-)
11:21 pmichaud okay, I need sleep.
11:21 pmichaud thanks for the excellent discussion and for helping to resolve some key issues.
11:22 allison and thanks for raising key issues
11:23 ruoso joined #parrot
11:30 dalek r34635 | bernhard++ | trunk/languages/pipp/src/pct:
11:30 dalek : [Pipp] Use a list of strings for declarung the superglobals
11:30 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34635
11:49 * barney found another Parrot: http://www.featherweightaltimeters.com/Parrot.php
11:51 rurban_ joined #parrot
12:00 register joined #parrot
12:10 Coke If we have a series of ops that just dispatch to methods... why don't we just eliminate the ops and have the users call the methods?
12:11 pdcawley joined #parrot
12:17 dalek r34636 | kjs++ | trunk/compilers/pirc/new (4 files):
12:17 dalek : [pirc] fix :named parameters. works for simple cases (non-aggregate).
12:17 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34636
12:18 gmansi joined #parrot
12:23 Tene kjs++
12:26 kid51 joined #parrot
12:26 Coke after the run of the last attempt at tcl's spec test, I'm now running 4 times slower and passing about 1/2 the number of tests I was. this is after about 400 parrot revs and about 30 partcl revs.
12:27 Coke (this with no regressions in the normal 'make test')
12:27 dalek r34637 | bernhard++ | trunk/languages/pipp/src/pct:
12:27 dalek : [Pipp] clean up trailing spaces and unused register $P2
12:27 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34637
12:27 Coke most of the failures are from losing entire files, presumably due to eventual memory panics.
12:27 * Coke sighs.
12:27 Coke ->
12:28 Tene Coke: Ew.  That's horrid.  Us--
12:28 kid51 What are we doing wrong?
12:29 Tene Partcl's spectests are running four times slower and passing half as many, possibly due to parrot OOMing.
12:29 kid51 OOMing?
12:29 Tene out of memory
12:29 purl hmmm... out of memory is at http://www.negativland.com/audio/memory1.wav
12:30 kid51 purl OOMing is running out of memory
12:30 purl OK, kid51.
12:35 dalek r34638 | bernhard++ | trunk/docs/user/pir (3 files):
12:35 dalek : [docs] add lines with svn-keyword $Id$
12:35 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34638
12:37 flh joined #parrot
12:38 flh hi everyone
12:38 purl Howdy, flh, you fantastic person you.
12:45 TonyC joined #parrot
12:47 dalek r34639 | bernhard++ | trunk/docs/user/pir:
12:47 dalek : [docs] use 'say' instead of 'print' in two code examples
12:47 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34639
12:48 dalek r34640 | kjs++ | trunk (9 files):
12:48 dalek : [pirc] refactor PCC related functions in a new file. svn props are set. MANIFEST is updated.
12:48 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34640
12:52 dalek r34641 | kjs++ | trunk/compilers/pirc/t:
12:52 dalek : [pirc] fix syntax error in test file.
12:52 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34641
13:02 dalek r34642 | bernhard++ | trunk/languages/pipp/src/common:
13:02 dalek : [Pipp] Remove unused sub
13:02 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34642
13:04 justin \
13:04 dalek r34643 | kjs++ | trunk/compilers/pirc/new (2 files):
13:04 dalek : [pirc] disallow users to write full signatured ops; it's not practical, not necessary, and would add a lot of complexity to PIRC. Just don't do it. Stick to 'set' as opposed to e.g. 'set_i_ic'
13:04 dalek : + whitespace
13:04 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34643
13:04 justin 7887
13:04 justin 788730-12 13:38.12 <+purl> Howdy, flh, you fantastic person you.
13:04 justin 30-12 13:42.25 -!- TiMBuS [~Hurf@123-243-167-27.static.tpgi.com.au] has quit [Quit: Leaving]
13:04 justin oops
13:04 justin ignore that ;-)
13:18 dalek r34644 | bernhard++ | trunk (2 files):
13:18 dalek : [docs] Add languages/README, pointing to the wiki
13:18 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34644
13:24 Coke tene: it is possible that changes to partcl are responsible for all of that. I have no easy way to tell with continuing deprecations and no profiling.
13:24 Coke barney: if we have the README and the wiki, can we now kill LANGUAGES.STATUS?
13:25 Coke I started to go through and verify that the wiki wasn't missing anything from the .STATUS file, but it took a while.
13:27 Coke that is, I got distracted.
13:29 Coke I really think both parrot and partcl could benefit from parrot folks digging through partcl and saying "why the HELL are you doing it this way?"
13:36 barney Coke: I wouldn't mind killing  LANGUAGES.STATUS
13:36 Coke barney: there's a ticket for it.
13:37 Coke TT #46
13:38 Coke barney++
13:39 ChrisDavaz joined #parrot
13:43 * barney claimed TT #46
13:48 ask_ joined #parrot
13:53 dalek r34645 | bernhard++ | trunk/languages/pipp/src (2 files):
13:53 dalek : [Pipp] Store the new class in the register 'def'
13:53 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34645
13:56 dalek r34646 | kjs++ | trunk/compilers/pirc/new:
13:56 dalek : [pirc] fix some iteration code; however, this messes up the result registers for get-params. They're now in reversed order. Will fix this later.
13:56 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34646
14:04 jimmy joined #parrot
14:08 dalek r34647 | kjs++ | trunk/compilers/pirc/new:
14:08 dalek : [pirc] rename some stuff, so I can understand what's going on.
14:08 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34647
14:25 dalek r34648 | kjs++ | trunk/compilers/pirc/new:
14:25 dalek : [pirc] some comments updates.
14:25 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34648
14:27 tetragon joined #parrot
14:31 apeiron joined #parrot
14:33 Coke anyone familiar with parrot guts who can tell me all the C functions which are responsible for invoking things with the PCC?
14:34 Coke partcl?
14:34 purl rumour has it partcl is tcl on parrot or http://code.google.com/p/partcl or slow, help make it go faster
14:34 Coke no, partcl is tcl on parrot or http://code.google.com/p/partcl or slow and a memory pig and pretty much not usable.
14:34 purl okay, Coke.
14:36 masak Coke: I know the feeling.
14:36 masak November?
14:36 purl November is at http://www.november-wiki.org/ or http://use.perl.org/~masak/journal/37212 or http://github.com/viklund/november/
14:37 Coke ah. i had heard that rakudo was zippy enough.
14:37 Coke no?
14:37 masak Coke: define 'enough'.
14:38 Coke "better than partcl", I suppose.
14:38 masak Coke: precompiling to PIR turns unusable to just sluggish, I'd say.
14:39 Coke whee. I cannot even /run/ append.test on feather.
14:39 masak :/
14:39 Coke PANIC: out of memory
14:39 purl it has been said that out of memory is at http://www.negativland.com/audio/memory1.wav
14:42 dalek r34649 | kjs++ | trunk/compilers/pirc/new:
14:42 dalek : [pirc] small refactoring, dedenting some code. + some function doc.
14:42 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34649
14:45 Coke so much crap, so little time.
14:55 masak pmichaud: #61838 was a bit of a surprize. both that and #61842 show that there are still spectests that need to be written.
14:56 masak also, crashing Parrot with (0,)[*-1..*] was fun.
14:56 masak rakudo: (0,)[*-1..*]
14:56 polyglotbot OUTPUT[src/inter_call.c:390: failed assertion 'PObj_is_PMC_TEST(sig_pmc)'␤Backtrace - Obtained 32 stack frames (max trace depth is 32).␤  (unknown)␤    Parrot_confess␤      Parrot_init_arg_op␤        Parrot_init_ret_nci␤          (unknown)␤            (unknown)␤              Parrot_NCI_invoke␤
14:56 polyglotbot ..          Parrot_pcc_invoke_sub_from_sig_object...
14:57 masak sort of like a secret code that opens up an impenetrable machinery.
15:01 Coke Aoogha. We have a "64-bit tell"?
15:10 dalek r34650 | fperrad++ | trunk/languages/lua/src/lib:
15:10 dalek : [Lua] io
15:10 dalek : - refactor io.tmpfile() with a StringHandle PMC
15:10 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34650
15:19 jhorwitz joined #parrot
15:20 masak fperrad?
15:20 purl rumour has it fperrad is mailto:francois.perrad@gadz.org
15:21 gryphon joined #parrot
15:24 Coke if someone is bored, they could probably find a few more tickets like TT #102 that involve the "don't touch" opcodes.
16:04 * Coke wonders what "TOTAL_COPIED" means in interpinfo.
16:08 register whos is the parrot commiter under the pseudo of leo?
16:11 Coke leo?
16:11 purl leo is possibly leo lapworth eq ranguard or one of parrot's older contributers.
16:12 Coke leo is also Leopold Toetsch
16:12 purl okay, Coke.
16:12 Coke he hasn't committed in some time. why do you ask?
16:12 Coke (when in doubt, check the CREDITS file.)
16:13 register because i see that he was one of the committer in the jit.c file
16:25 Coke whee. anyone think 3 million active PMCs for a dozen lines of tcl is a bit much?
16:32 masak it does sound a bit on the high side, yes.
16:35 pmichaud masak:  I'm working on #61838 in the rvar branch.
16:35 tewk daniel grunblatt?
16:35 masak pmichaud: nice.
16:36 tewk purl daniel grunblatt is daniel@grunblatt.com.ar
16:36 purl OK, tewk.
16:36 pmichaud #61842 is the same issue whereby slices think that any empty list mean "return the full array"
16:36 pmichaud I might be able to fix it quickly.
16:37 masak pmichaud: aye, I just realized that.
16:37 Coke I pick up about 3K pmcs a shot each time  through a while loop.
16:37 pmichaud I think it depends on the dozen lines of tcl :-)
16:38 register_ joined #parrot
16:38 pmichaud rakduo:  for 1..3000000 { .say };   # 3 million active PMCs in one line :-)
16:39 Coke hurm. I seem to be creating exception handlers in loops now. I blame tene. =-)
16:40 pmichaud #ps in 110
16:46 Coke added https://trac.parrot.org/parr​ot/wiki/ParrotBestPractices
16:52 mberends joined #parrot
16:55 masak a perl6 process running the above loop takes a few minutes to start printing numbers on my machine. after that it takes about half a gigabyte of RAM while it prints numbers in spurts of a couple of tens of thousands.
16:55 pmichaud masak: (few minutes)  it's building the 1..3000000 range  :-)
16:55 pmichaud ranges aren't lazy in Rakudo yet
16:55 masak aye, I realize that. :)
16:56 pmichaud I'm kinda surprised it even makes it
16:56 masak me too :)
16:58 hercynium joined #parrot
16:59 Zaba joined #parrot
17:01 Coke imagine my surprise when i started being able to tcl's spec tests.
17:01 masak that sentence no verb.
17:01 pmichaud "imagine" is a verb.  :-P
17:02 masak right. not enough verbs.
17:02 * pmichaud plays "guess the missing verb"
17:02 masak "eat tcl's spec tests"?
17:03 masak "harass tcl's spec tests"?
17:03 pmichaud "delete"
17:03 masak *lol*
17:03 mberends "grok"
17:03 pmichaud "pass"
17:03 masak "test"
17:03 nopaste "Coke" at 65.91.151.195 pasted "This prints 1807" (16 lines) at http://nopaste.snit.ch/15133
17:04 masak "fail"
17:04 masak "see"
17:04 mberends "tickle"
17:04 masak "entertain"
17:04 Coke run.
17:04 mberends "imagine"
17:04 purl i heard "imagine" was a verb.  :-P
17:04 masak Coke: totally didn't see that one coming.
17:04 masak purl: you are so corny sometimes.
17:04 purl ...but purl is a she. or captain obvious...
17:05 masak purl is also so corny sometimes
17:05 purl okay, masak.
17:05 Coke if I just jump to done, i get 1735 pmcs.
17:06 Coke so with no pmc creation on my own, I still end up with nearly 2K pmcs.
17:11 dalek r34651 | pmichaud++ | trunk/languages/perl6/docs:
17:11 dalek : [rakudo]: spectest-progress.csv update: 264 files, 5912 passing, 0 failing
17:11 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34651
17:12 masak .oO( almost 6k )
17:13 pmichaud yes.  I don't think we'll make 6k in december, though, unless the parameter refactor passes a bunch of spectests, or someone finds a nice cache of tests that we can pass quickly.
17:14 pmichaud still, december has been a very good month.
17:14 pmichaud 5912-4689
17:14 purl 1223
17:14 pmichaud 1223 new passing tests in december.  What's more, some of them are really good things to be passing, like slices and list assignment. :-)
17:15 pmichaud I have a fix for the @a[2..1] bug, running spectest now.
17:18 masak \o/
17:21 Infinoid wow, that means more than 20% of our current passes are new
17:22 masak that explains why some things aren't 100% stable yet. :)
17:23 pmichaud do we have a test for @a[2..1] ?
17:24 * masak doesn't know
17:27 dalek r34652 | pmichaud++ | trunk/languages/perl6/src (2 files):
17:27 dalek : [rakudo]:  Fix empty slice -- e.g., @a[2..1] .  Resolves RT #61842.
17:27 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34652
17:29 masak the script reached 3000000 now.
17:29 masak took about half an hour.
17:29 pmichaud say '\o/' xx 3000000
17:30 masak heh
17:32 Coke ps in 60.
17:33 Coke is there a way to say "free this pmc"?
17:34 Coke (the opposite of "new") ?
17:34 Infinoid are you sure it isn't being pointed to by anything else?
17:34 pmichaud you want ordered destruction?  ;-)
17:34 Coke Infinoid: no, and SFAIK, I have no way to see what is pointing at a given PMC.
17:35 Coke if I trusted the GC (see recent email thread) I wouldn't ask. =-)
17:35 Infinoid :)
17:35 pmichaud GC is scheduled to be fixed this month, see roadmap.  :-) :-)
17:36 Coke yahhh.
17:37 Infinoid I've got a fun problem.
17:37 Infinoid charsets and encodings are registered by init functions when parrot starts.  first encodings are registered, and then charsets are.
17:37 Infinoid it looks to me like if any strings are created before this init phase finishes, their encoding/charset pointers are NULL
17:38 Infinoid but, of course, the encoding init function tries to create a string (the name of the encoding) which ends up with a NULL charset pointer
17:38 Infinoid this violated the ARGIN() check because the pointer was null, which is why I'm looking at it.
17:39 allison Infinoid: Sounds like it needs a two-stage process, first register the charsets, then set their names
17:39 allison charsets/encodings
17:39 nopaste "Infinoid" at 75.5.247.153 pasted "charset=0x0. do I need to worry about this?" (11 lines) at http://nopaste.snit.ch/15134
17:40 Infinoid well, parrot has obviously been working fine for months, so it doesn't seem like a big deal.  but I'm not sure changing ARGIN to ARGIN_NULLOK is the right solution
17:40 Infinoid allison: that sounds doable
17:41 allison where did you encounter the problem?
17:41 Infinoid miniparrot
17:41 purl hmmm... miniparrot is not working yet, is it?
17:41 Coke purl, forget miniparrot
17:41 purl Coke: I forgot miniparrot
17:41 Wknight8111 joined #parrot
17:41 Coke what were you using miniparrot for?
17:41 allison Infinoid: just in trunk? with no changes?
17:41 Infinoid I'm adding asserts to enforce NONNULL pointer semantics.  see trac #105
17:41 Coke just the normal build bit?
17:41 Infinoid yeah
17:42 Infinoid this is one of the issues my patch caught, and I wasn't sure what the best fix is
17:43 Coke allison: made a slight improvement to partcl's memory pressure woes. need more. =-)(
17:43 Coke er, =-)
17:44 allison Infinoid: well, if it worked just fine with a null charset, that means it's setting a sane default somewhere, so probably safe to leave it
17:44 Infinoid so I can change ARGIN to ARGIN_NULLOK to skip the check?
17:44 allison Infinoid: yup, try that
17:44 Infinoid thanks.
17:45 allison Coke: excellent! I saw something about 3M PMCs for a few lines of code?
17:45 Coke yes.
17:45 allison Coke: yeah, that'll bite
17:45 Coke I think i shaved off about 500,000; no clue why the ones I avoided creating were not getting freed, however.
17:46 allison Coke: in a program that's only a few lines, it may never be running GC at all
17:47 Coke allison: uh..
17:47 allison though, with 3M PMCs, it must
17:47 pmichaud (few lines of Tcl code, not a few lines of PIR, IIUC)
17:47 Coke it's a few lines of tcl; that involves PGE, TGE, the tcl runtime...
17:48 Coke the output showed over 100 DOD runs, IIRC.
17:48 allison well that's a relief
17:48 Coke (and 8M of memory)
17:50 Coke if I have a global *Array, and I pop a hash off the end of it, should everything in that hash (barring other references) get collected?
17:51 Wknight8111 I have a suspicion that the GC is not accurately counting the number of PMCs it's freed
17:51 Coke or, because it's a container, would the hash and its contained PMCs keep each other alive?
17:52 Wknight8111 if nothing points to the hash or it's children, they would all get collected
17:52 allison Coke: nope, as long as there are no other references to the container, it will die
17:52 Coke k. just looking for potentially obvious places where things might not be getting collected.
17:52 allison Coke: if there are other references to some of the children, they will live, even though the container dies
17:53 Coke be nice if I had a way to dump the chart generated by a dod run.
17:53 allison Coke: yes, I've often wished for that
17:53 Coke otherwise I'm (still) shooting in the dark. =-)
17:54 Wknight8111 A dump of that wouldn't be too too hard to create, algorithmically. But if you had 3M PMCs, the output would be hell to read.
17:55 Coke Wknight8111: I'd trim up my sample code first.
17:55 Coke there were some loops in that code. =-)
17:56 Coke here's a scenario that tcl uses: i create an anonymous sub. I create a pir subclass of Sub, assign the anon sub into it. Does the anonymous sub go away?
17:56 Wknight8111 no, it shouldnt
17:56 Coke why not? nothing refers to it, right?
17:57 Wknight8111 the pir subclass object refers to it
17:57 pmichaud it does?  why?
17:57 Coke it doesn't have a copy of it.
17:57 Coke it's not a has-a, it's a is-a.
17:57 Wknight8111 i must not be understanding the question
17:58 pmichaud create an anonymous sub ('X'), create an instance of a subclass of Sub, assign X into the instance, does X go away?
17:58 Coke http://code.google.com/p/partcl/source​/browse/trunk/runtime/builtin/proc.pir
17:58 shorten Coke's url is at http://xrl.us/bea3cs
17:58 pmichaud Coke: I suspect it depends on how your subclass of Sub handles assignment
17:58 Coke (about line 213)
17:59 Coke pmichaud: whatever the default is.
17:59 Wknight8111 then no, the instance of the subclass would contain a reference to X
17:59 Coke subclass: http://code.google.com/p/partcl/sourc​e/browse/trunk/src/class/tclproc.pir
18:00 Coke ok. is there a way to keep the subclass that doesn't keep a copy of the thing I assigned to it?
18:00 Coke (the only reason I have the subclass atm is to easily add attributes to .Sub's, but that class will do more eventually)
18:00 pmichaud Coke: it may be a moot point -- istr jonathan mentioning something about compiled subs going into the constant PMC table
18:00 allison if it's stored anywhere that's reachable from the root-set, it'll be kept
18:01 Coke Ok; how do I force it to go away, then?
18:01 Wknight8111 take away all references to it
18:01 Coke ... where are those references?
18:01 pmichaud however, assigning to a Sub does _not_ appear to create a reference.
18:01 Coke if it's in the root set and I didn't put it there...
18:02 pmichaud so "the instance of the subclass would contain a reference to X" isn't correct at first blush
18:02 Wknight8111 I'm not sure about this, the sub may be constant and never disappear
18:02 pmichaud that would be consistent with what jonathan said, I think.
18:02 chromatic joined #parrot
18:02 Coke pmichaud: so if I use this approach, I basically get two subs for the price of one?
18:02 Wknight8111 i would need to do a lot more digging to find the real answer
18:03 Coke er, one sub for the price of two, I mean.
18:03 rurban Why is compilers/imcc/imclexer.c                         [main] in the MANIFEST.generated?
18:03 shorten Coke's url is at http://xrl.us/bea3c6
18:03 Coke wow, shorten. keep up.
18:03 pmichaud Coke:  if compiled subs are gc-able objects, then I would suspect that X would eventually be collected in your scenario
18:04 Infinoid rurban: isn't it generated by flex?
18:04 pmichaud if compiled subs are not gc-able (i.e., constant PMCs), then assigning to a TclSub would leave you with two PMCs (one gc-able, one not)
18:04 rurban I assume all compilers/* files can be deleted from this MANIFEST, or maybe getting installed into the runtime library
18:04 chromatic You should probably install PGE, PCT, and NQP files.
18:05 pmichaud what MANIFEST are we referring to here?
18:05 rurban Infinoid: yes, but I thought only files which should get installed should be kept there. But I see. To clean up generated files it must be there also.
18:05 pmichaud the MANIFEST for the download/build tarball?
18:05 pmichaud iiuc, MANIFEST is the list of files that should be present in the tarball.
18:05 rurban MANIFEST.generated on wihc I'm working right now. I completely generate it now at build-time
18:06 Coke I wonder if not managing my own lexpads would help ease the pressure.
18:06 rurban RT#40817 MANIFEST-generated.patch
18:06 ruoso joined #parrot
18:08 rurban But many interim pir's are also generated, and these are not kept in MANIFEST.generated. Should they be added?
18:09 Coke in rakudo, you're storing subs as 'subname' in the ns, and variables as (e.g.) '$variable' ?
18:09 Zaba joined #parrot
18:09 pmichaud PGE and PCT already put their installable components into runtime/parrot/library
18:09 Coke (not '&subname')
18:09 rurban okay. I added them for consistency
18:09 pmichaud so there's not a need to install their generated .pir components
18:09 pmichaud Coke: yes.
18:09 rurban I have now tge and json, the top of MANIFEST.generated
18:10 Coke json probably isn't worth installing.
18:10 pmichaud json would be a good candidate for rewriting in p6 :-)
18:10 pmichaud or nqp
18:10 Coke plus there's a languages/ variant.
18:11 ask_ joined #parrot
18:12 Coke I do wish we had a better solution than sigils to avoid allow different types in a NS.
18:12 Coke s/avoid//
18:13 Coke (string manipulation sucks)
18:13 pmichaud rakudo doesn't do much in the way of string manipulation to manage this, though.
18:14 pmichaud i.e., it all just falls out naturally
18:16 nopaste "rurban" at 212.183.50.193 pasted "40817-MANIFEST-generated.patch" (1463 lines) at http://nopaste.snit.ch/15135
18:22 rurban Is a compiler the same as a language (from the installation pov)? nqp e.g. Should I make an excemption in install_files for the to be installed compilers, or should I add make install targets to their makefiles?
18:23 pmichaud there was a long discussion about where they should go
18:23 rurban Sorry, I missed that
18:23 pmichaud but yes, they should be treated the way as language installs
18:23 pmichaud (imo)
18:24 pmichaud *same way
18:24 rurban I assume into runtime/parrot/library
18:24 rurban as pir and as pbc.
18:24 pmichaud actually, allison specifically rejected that
18:24 pmichaud and I wouldn't install the pir, just the pbc
18:24 rurban okay.
18:25 pmichaud #ps in 5
18:25 frodwith joined #parrot
18:27 pmichaud rurban:  http://irclog.perlgeek.de/par​rotsketch/2008-09-09#i_559123
18:30 pmichaud #ps in 0
18:31 dalek r34653 | allison++ | trunk/src/io:
18:31 dalek : [io] Setting append mode also sets write mode.
18:31 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34653
18:33 Zaba joined #parrot
18:40 chromatic Does anyone else find the GET_ATTR_foo in-place modification confusing?
18:42 allison chromatic: yes, but it was the only way to make those macros work. Feel free to refactor.
18:43 chromatic Will try.
18:59 Coke what about the remaining mmd function to be removed?
19:01 chromatic_away axe them
19:01 Coke it's actually invoked, though.
19:02 Coke just don't call it?
19:03 chromatic_away What invokes it?
19:03 Coke Parrot_mmd_get_cached_multi_sig
19:03 dalek r34654 | fperrad++ | trunk/languages/lua/src:
19:03 dalek : [Lua]
19:03 dalek : - revert r34355 for luap.pir
19:03 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34654
19:04 Coke which in turn is called by mmd_distance
19:04 Coke (why doesn't that have a Parrot on it?)
19:05 chromatic_away It's not external.
19:05 chromatic_away I'll take a look.
19:05 Coke but Parrot_mmd_get_cached_multi_sig is?
19:05 Coke odd.
19:06 chromatic_away Yeah.
19:06 Coke allison: can you do a quick run through the RTs in deprecated.pod and see if they trail off with "I need direction on this one"?
19:06 Coke the one for get_mro, for example, does.
19:06 Coke (from some time ago)
19:07 allison Coke: ok
19:07 brunoV joined #parrot
19:08 brunoV left #parrot
19:09 Coke allison: Danke.
19:10 dalek r34655 | coke++ | trunk:
19:10 dalek : This ticket was closed by tene on December 10, 2008.
19:10 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34655
19:11 Coke as i recall, new_from_string was also chip's, and also tricky.
19:11 Coke tene__
19:11 Coke tene++
19:13 allison Coke: you can kill the 'new_from_string' deprecation item and the associated ticket. It's just not important, and won't happen anytime soon
19:14 allison Coke: it may never happen, but if it does, we can figure it out then.
19:16 allison Coke: oh, I see someone merged in a ticket about 'new_from_string' being broken
19:16 Coke ayup. so if we don't kill it, we have to fix it. =-)
19:17 allison okay, well the task of removing it is to add an 'init_str' vtable function
19:18 allison and corresponding 'pmc_new_str' C functions
19:18 allison and corresponding new_p_x_sc opcodes
19:21 * Coke 's eyes glaze over.
19:21 allison :)
19:21 allison that is to say, it's actually a pretty simple task, probably take a couple of hours, a day at most
19:22 allison but, that won't fix the problem with FixedIntegerArray
19:22 Coke I have no idea what is involved in scope based on your comments there.
19:22 Coke <weasel> if you could just update the ticket... </weasel>
19:24 allison basically, we've got about 3 completely unrelated tickets here all bundled into one
19:25 pmichaud trac tickets are cheap
19:25 pmichaud unbundle the rt ticket into trac tickets, then mark the ones that are needed for the milestone :-)
19:25 Coke allison: remove_pic doesn't even /build/ for me. =-)
19:26 allison Coke: which platform?
19:26 purl I'm running on OS/2 on an Atari, can you help?
19:26 Coke feather.
19:26 purl well, feather is http://feather.perl6.nl/ or a perl6 community development server
19:26 * Coke tries again without -j
19:26 allison I don't know what feather is, some linux variant
19:26 masak pmichaud: I have a question. is merging the p5 and Rakudo runloops on a roadmap somewhere?
19:26 Coke src/jit.c:1624: error: 'PARROT_OP_pic_callr___pc' undeclared (first use in this
19:27 pmichaud it's not officially on a roadmap at the moment, no.
19:27 Coke allison: Linux feather 2.6.18-6-xen-686 #1 SMP Sun Feb 10 22:43:13 UTC 2008 i686 GNU/Linux
19:27 pmichaud that is the likely ultimate outcome, however.
19:27 allison Coke: ah, okay that's the last remaining piece of the old system I mentioned
19:27 pmichaud I feel we need a roughly working p6 implementation before I bog down too much in figuring out p5
19:27 masak pmichaud: understood.
19:27 purl understood. are you on schedule?
19:28 Coke ah. probably a makefile dep, then.
19:28 allison Coke: it's an actual indirect call to an opcode that doesn't exist anymore
19:28 Coke ah.
19:29 * Coke wonders how this built, then.
19:29 allison Coke: it passes over that on OSX, because of dynamic loading
19:29 masak pmichaud: I think p5 runloop access is now somewhere very high on my wish list. but OTOH, it's not urgent.
19:29 masak just very, very desirable. :)
19:30 dalek r34656 | particle++ | trunk/t/compilers/imcc/syn:
19:30 dalek : [t] correct regex in expected output causing unexpected failure
19:30 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34656
19:32 allison Coke: I can look at that tonight
19:32 Coke hokay.
19:32 Coke I have no idea how to fix it. =-)
19:33 allison Coke: I suspect it's just a matter of creating a simplified variant of the opcode that doesn't use PIC
19:38 ask_ joined #parrot
19:40 Coke pmichaud: can branches/rt59410 be removed?
19:41 pmichaud yes.
19:41 Coke (I assume it's related the RT ticket of that number which is closed.)
19:42 dalek r34657 | coke++ | branches:
19:42 dalek : The ticket that this branch corresponds to was closed on October 01, 2008
19:42 dalek : Ok to delete, per pmichaud++
19:42 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34657
19:44 chromatic_away left #parrot
19:44 chromatic joined #parrot
19:44 Coke pmichaud: the deprecation notice for 60384 is still around; the ticket is resolved, I presume it's safe to remove the deprecation note?
19:45 justin joined #parrot
19:45 pmichaud Coke: yes.
19:49 Coke particle: ok, I cleaned up most of the DEPRECATION notes; you can get the rest. =-)
19:49 dalek r34658 | coke++ | trunk:
19:49 dalek : This ticket was resolved on December 15th, 2008 by pmichaud++
19:49 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34658
19:50 Coke tewk: is 60590 still on your list?
19:50 Coke er, s/still//
19:51 rurban_ joined #parrot
19:52 tewk Coke: its done.
19:57 dalek r34659 | pmichaud++ | branches/rvar/languages/perl6/src (2 files):
19:57 dalek : [rakudo]:  Fix my ($s, @a) assignment.
19:57 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34659
20:00 Coke tewk: woot.
20:00 dalek r34660 | coke++ | branches:
20:00 dalek : starting over...
20:00 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34660
20:01 dalek r34661 | coke++ | trunk:
20:01 dalek : This ticket was resolved on December 30, 2008 by tewk++
20:01 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34661
20:10 alvar joined #parrot
20:13 dalek r34662 | coke++ | trunk/runtime/parrot/library:
20:13 dalek : Avoid [DEPRCATED] opcodes. yaml tests still pass.
20:13 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34662
20:22 gmansi joined #parrot
20:26 ask_ joined #parrot
20:28 desertmax joined #parrot
20:29 dalek r34663 | coke++ | trunk/runtime/parrot/library/Tcl:
20:29 dalek : avoid [DEPRECATED] opcodes. avoid a keyed lookup since we're already in this NS.
20:29 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34663
20:30 Coke bah. we have a lot of stuff in runtime/ that is still using flat namespaces with ::'s in them.
20:31 dalek r34664 | pmichaud++ | branches/rvar/languages/perl6/src/parser:
20:31 dalek : [rakudo]: Remove $?SIGNATURE_BLOCK after grabbing signature as a declarator.
20:31 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34664
20:33 Tene okay, time to dive into PGE in pct_hll...
20:34 Coke question; when loading libraries, we should be telling people to get at them with get_root_global, not get_global, neh?
20:34 Coke (since get_global is probably going to fail if they're in a HLL?)
20:34 chromatic Makes sense.
20:35 Coke s/HLL/some other namespace/
20:35 chromatic One nasty IMCC/MMD hack goes away....
20:36 Coke if I change t/library/sort.t to lookup data/sort/simple with get_root_global instead of get_global, all tests fail.
20:36 desertmax SDL is currently broken. Here is a patch that fixes (at least) some parts of it, including the basic examples in examples/sdl. Minesweeper, Tetris and LCD however are still broken. http://stud3.tuwien.ac.at/~e​0625243/parrot/tmp/sdl.patch Should I post this to the mailing list / file a bug report first?
20:37 Coke definitely open a ticket.
20:37 Coke thanks!
20:38 dalek r34665 | chromatic++ | trunk/compilers/imcc:
20:38 dalek : [IMCC] Rearranged some struct members (hopefully to minimize their size due to
20:38 dalek : padding and alignment).
20:38 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34665
20:39 Coke do we desire AUTHOR blocks?
20:39 Coke I suspect no.
20:40 chromatic What's that?
20:41 Coke pod sections in file that says "I'm chromatic, and I maintain this file. but don't email me, email the list."
20:43 chromatic You can wipe them out.
20:43 chromatic I have those in Parrot::Embed because I intended to put it on the CPAN, but ... okay, maybe that one needs it.
20:44 s1n joined #parrot
20:44 particle the road to cpan is paved with good intentions.
20:45 chromatic It wasn't an issue when we uploaded Parrot to the CPAN, but it might be an issue in the future when we don't.
20:47 dalek r34666 | chromatic++ | trunk (3 files):
20:47 dalek : [IMCC] [PIRC] [MMD] Fixed generation of multi signatures with no arguments,
20:47 dalek : removing a nasty hack in the process (RT #45951).
20:47 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34666
20:49 dalek r34667 | coke++ | trunk/runtime/parrot/library:
20:49 dalek : Use the pmc's builtin sort method (C) instead of the library (PIR)
20:49 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34667
20:51 dalek r34668 | tewk++ | trunk/src/pmc (2 files):
20:51 dalek : [core] added get_repr to FixedStringArray and added get_repr to String
20:51 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34668
21:01 Coke if there's a parrot module that needs to get uploaded to the CPAN, I wonder if that belongs in the parrot repo.
21:01 Coke wouldn't it be separate?
21:02 chromatic Why would it be?
21:04 Coke ... ok.
21:04 dalek r34669 | coke++ | trunk/runtime/parrot/library:
21:04 dalek : take advantage of calling conventions and an opcode that probably didn't exist when this written.
21:04 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34669
21:04 Coke (it's author block should probably not be "you", though.)
21:04 Coke bah, its.
21:05 dalek r34670 | chromatic++ | trunk (2 files):
21:05 dalek : [MMD] [IMCC] Optimized MMD signature generation where dispatch types are known
21:05 dalek : at compile time.
21:05 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34670
21:05 chromatic We do need a cohesive copyright policy.
21:05 Coke allison's got an open RT on that.
21:07 chromatic Any thoughts on the other MMD functions marked DEPRECATED?
21:08 GeJ Good morning everyone
21:11 * chromatic is tempted to throw an exception when declaring a multi with an unknown type name.
21:12 barney desertmax: Please file a bugreport, including the patch
21:12 barney desertmax: Please file a bugreport, including the patch
21:12 pmichaud chromatic: perhaps the type hasn't been created yet.
21:13 desertmax barney: http://rt.perl.org/rt3/Publi​c/Bug/Display.html?id=61858
21:13 pmichaud Tene: why is PGE affected by hll?
21:14 barney desertmax: Sorry, I didn't scroll down in my IRC client
21:14 chromatic I know, but I'm still tempted.
21:14 Coke chromatic: the others?
21:14 purl the others is best left to offline processing
21:14 clunker9__ joined #parrot
21:14 Coke there's only one left, isn't there?
21:14 chromatic Coke, several more have {{**DEPRECATE**}} in their documentation.
21:14 chromatic Of course, they're static functions, so nothing else used them.
21:14 chromatic AHA
21:15 ask_ joined #parrot
21:16 dalek r34671 | coke++ | trunk:
21:16 dalek : [docs] "not me!"
21:16 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34671
21:16 Coke chromatic: ?
21:16 Coke if nothing is using them, and they are internal...
21:16 Coke they doesn't require a deprecation cycle, duzzit?
21:17 dalek r34672 | bernhard++ | trunk/languages/pipp/src (2 files):
21:17 dalek : [Pipp] Use a plain 'Class' pmc for PHP classes.
21:17 dalek : Work on public class members.
21:17 dalek : Fail with setting up a default values of member variables.
21:17 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34672
21:18 chromatic Nope, removing now.
21:18 Coke chromatic++
21:18 chromatic Hm, the core tests seem about 10% faster now, for some reason.
21:21 chromatic We're not going to be able to get rid of mmd_cvt_to_types anytime soon unless we make really big changes to how we do MMD.
21:21 dalek r34673 | bernhard++ | trunk (8 files):
21:21 dalek : RT #61858: SDL library bindings and examples broken
21:21 dalek : Courtesy of Markus Mayr.
21:21 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34673
21:22 dalek r34674 | chromatic++ | trunk/src:
21:22 dalek : [MMD] Removed deprecated static functions no longer used within this file and
21:22 dalek : not visible externally (so that they need no public deprecation cycle).
21:22 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34674
21:24 TiMBuS joined #parrot
21:24 barney Is there a HLL in Parrot, that support default values of class attributes ?   has $x = 'default'    ?
21:25 PerlJam barney: doesn't rakudo do that now?
21:28 particle coke: put File/Spec.pir on the remove list
21:29 barney I haven't checked. '!keyword_has'  didn't look like  it
21:30 particle rakudo: class Foo { has $bar = 'default'; }; my Foo $x .= new; $x.bar.say;
21:30 polyglotbot OUTPUT[Method 'bar' not found for invocant of class 'Foo'␤current instr.: '_block14' pc 150 (EVAL_12:71)␤called from Sub '!UNIT_START' pc 16073 (src/builtins/guts.pir:327)␤called from Sub 'parrot;PCT;HLLCompiler;eval' pc 892 (src/PCT/HLLCompiler.pir:508)␤called from Sub
21:30 polyglotbot ..'parrot;PCT;HLLCompiler;evalfiles' pc 1217 (src/PCT/HLLCompiler.pir:669)␤cal...
21:30 particle probably forgot a necessary twigil there...
21:33 ask_ joined #parrot
21:34 barney rakudo: class Foo { has $.bar = 'default'; }; my Foo $x .= new; $x.bar.say;
21:34 polyglotbot OUTPUT[␤]
21:34 barney Yes, it parses, but the default is not stored in Foo
21:35 particle i thought jonathan had that implemented, but it seems i'm mistaken.
21:35 * PerlJam too
21:40 Coke chromatic: can you add a note to that effect to the ticket?
21:41 Coke perhaps we can resolve it as is; I think allison did the initial request on that, neh?
21:41 chromatic Yes.
21:41 Coke particle: what replaces it?
21:42 particle nothing uses it. it's half-implemented on win32 and abandoned.
21:42 particle (and not implemented on any other platforms)
21:44 GeJ lastlog GeJ
21:45 Coke particle: done.
21:45 particle coke++
21:47 chromatic GeJ, I'll check in your patches from yesterday soon.
21:48 GeJ chromatic: thanks... I'm working on t/oo/new.t so I can get the whole directory "pir_output_is"-free
21:48 GeJ Also, I posted a request for comments last night, but I guess almost everybody in the US was long gone.
21:48 GeJ http://nopaste.snit.ch/15129
21:49 GeJ Just to know if it's worth putting in the test suite
21:49 chromatic I'm surprised I didn't think of it.  That should make the test non-TODO.
21:51 GeJ Good, Well, I'm going to finish this last file and will paste results when I'm done.
21:52 Whiteknight joined #parrot
21:54 particle related to that nopaste, should we be converting all $Px = new 'Foo' to ['Foo'] ?
21:54 dalek r34675 | chromatic++ | trunk (6 files):
21:54 dalek : [ops] Removed deprecated infix and n_infix ops.
21:54 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34675
21:57 jonathan (attribute init) I thought I knot only had it implemented, but also unfudged related spectests.
21:57 particle jonathan: agreed
21:57 PerlJam jonathan: perhaps on a branch that didn't get merged?
21:57 particle there are several spectest failures for me, but they seem to be io and inf/nan-related
21:58 jonathan I rarely work in branches, and I'm almost certain I didn't do that in one.
21:58 jonathan Plus if there were unfudges...
21:58 jonathan rakudo: class Foo { has $.x = 42; }; say Foo.new.x
21:58 polyglotbot OUTPUT[42␤]
21:59 jonathan rakudo: class Foo { has $.x = 'default'; }; say Foo.new.x
21:59 polyglotbot OUTPUT[default␤]
21:59 jonathan rakudo: class Foo { has $.x = 'default'; }; my $x = Foo.new; say $x.x
21:59 polyglotbot OUTPUT[default␤]
21:59 jonathan rakudo: class Foo { has $.x = 'default'; }; my Foo $x .= new; say $x.x
21:59 polyglotbot OUTPUT[␤]
21:59 jonathan ...odd...
22:00 jonathan Why on earth would that make a difference. :-S
22:00 Tene pmichaud: I'm not sure yet.
22:01 particle odd is right.
22:01 particle --target=pir to the rescue, i hope!
22:02 Tene pmichaud: did we need to harass Jonathan about that crash I found last night?
22:02 Tene I was only partially awake for its discussion.
22:05 * barney needs to add !ADD_TO_WHENCE to Pipp,     tomorrow
22:05 jonathan Uh-oh...what else have I done? :-)
22:06 jonathan rakudobug?
22:06 purl rumour has it rakudobug is mailto:rakudobug@perl.org
22:07 jonathan (filed ticket on that default issue)
22:07 Tene jonathan: I'm getting a crash in my pct_hll branch in the second hunk of http://www.parrotvm.org/svn​/parrot/revision?rev=33520
22:08 Tene When it calls Parrot_oo_get_class_str, Parrot_oo_... makes a new PMCProxy, which ends up infinite loop
22:09 jonathan I'm probably a reasonable person to harrass about that.
22:09 Tene http://nopaste.snit.ch/15130 is a backtrace
22:09 jonathan Have you a relatively compact PIR example to reproduce it?
22:10 Tene Nope!  Trying to run rakudo in the branch triggers it, though.
22:10 Tene There was a lot of disucssion on IRC last night about it...
22:10 Tene purl: parrot log?
22:10 purl parrot log is probably probably irc log
22:10 Tene purl: irc log?
22:10 purl irc log is http://irclog.perlgeek.de/parrot/
22:10 pmichaud jonathan: the problem is that calling Parrot_oo_get_class_str doesn't work if we're not in the same HLL
22:10 pmichaud i.e., looking up a class by name is problematic.
22:11 pmichaud just a sec...finding reference.
22:11 Tene It started here: http://irclog.perlgeek.de/​parrot/2008-12-30#i_793387
22:11 nopaste "pmichaud" at 72.181.176.220 pasted "problem code in pmcproxy.pmc" (10 lines) at http://nopaste.snit.ch/15136
22:12 Tene The instruction that triggered it was "new 'Hash'"
22:12 jonathan Tene: When there's a .HLL in force?
22:12 jonathan And when the .HLL is removed, it goes away?
22:12 pmichaud yes.
22:13 pmichaud new 'Hash' is equivalent to   new ['Hash']
22:13 Tene Also when we don't store Perl6Hash in ['perl6';'Hash'], it goes away.
22:13 jonathan Ah.
22:14 pmichaud that part doesn't make much sense to me, fwiw.
22:14 jonathan So it's confusing the PMC with the Perl 6 one?
22:14 pmichaud it gets into an infinite loop.
22:14 pmichaud or at least a nasty loop
22:14 pmichaud at any rate, pmcproxy.pmc should not be looking up the proxy by name.
22:15 jonathan How should it be looking it up?
22:15 Tene pmichaud: I saw about 150k stack frames in gdb before I stopped holding down 'enter'
22:15 jonathan (Because if you have an answer it's an easy patch... ;-))
22:15 Tene so probably infinite
22:15 pmichaud I don't have an easy answer.
22:15 jonathan OK.
22:15 pmichaud because I don't completely understand how proxy pmcs are created/stored/managed
22:15 jonathan Question is where PMCs live.
22:15 jonathan Namespace wise.
22:15 pmichaud pmcs?  or classes?
22:16 jonathan PMCs.
22:16 jonathan PMCProxy doesn't apply for non-PMC classes.
22:16 jonathan I mean, if I write a
22:16 pmichaud note that    new 'Hash' and new ['Hash'] will no longer work when Rakudo moves to its own HLL
22:16 jonathan pmclass Foo { ... }
22:16 jonathan Is that going be looked up under parrot; Foo
22:16 jonathan Or will there be/is there a way to say "this PMC goes in this HLL?"
22:16 pmichaud isn't hll one of the options to pmclass ?
22:17 jonathan Maybe.
22:17 pmichaud i.e., to create a PMC in a different hll?  I'm pretty sure Tcl must be doing something like that.
22:17 jonathan If so, that implies the default is parrot
22:17 Tene pmichaud: they will work, they'll just get a Perl6Hash instead of a pmc hash.
22:17 pmichaud Tene: no, because what is at 'Hash' in the root namespace isn't a class object.
22:17 purl okay, pmichaud.
22:18 pmichaud *hll root namespace
22:18 pmichaud new "Hash" means  "get the class associated with the ['Hash'] namespace in the current HLL"
22:19 pmichaud Perl6Hash is in the ['Perl6Hash'] namespace.
22:19 pmichaud (implies the default is parrot)   that sounds very wrong to me.
22:19 pmichaud depending on what you're intending it to mean.
22:20 dalek r34676 | chromatic++ | trunk/src/pmc (2 files):
22:20 dalek : [PMC] Added "mro" as an inspectable attribute of PMCs (inherited from default
22:20 dalek : PMC now; overriders may need to work on this).  See RT #47976.
22:20 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34676
22:22 pmichaud the question I have for the pmcproxy code:  Why/when do we need to look up pproxy if we already have pclass ?
22:23 dalek r34677 | chromatic++ | trunk (7 files):
22:23 dalek : [ops] Removed deprecated get_mro opcode (RT #47976).
22:23 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34677
22:24 Coke chromatic++
22:24 pmichaud i.e., why aren't we simply pushing pclass as a parent directly?
22:26 dalek r34678 | pmichaud++ | branches/rvar/languages/perl6/src/parser:
22:26 dalek : [rakudo]:  Restore @_ and %_ slurpy params.
22:26 dalek review: http://www.parrotvm.org/svn​/parrot/revision?rev=34678
22:28 TonyC joined #parrot
22:34 Tene pmichaud: whatever pclass is, it isn't the right thing.  The errors we get when we do that are 'can't find method 'parents'' and such.
22:34 Tene I haven't checked what it actually is, though.
22:34 davidfetter joined #parrot
22:35 pmichaud what kind of thing is it, then?
22:40 Theory joined #parrot
22:41 pmichaud excellent. rvar branch is down to 63 spectest files failing, most in the oo stuff (which I'd expect, since I haven't put those back in yet).
22:45 pmichaud ...and some of those failures are errors in the test files.  :-)
22:50 Tene pmichaud: is pclass the class where we need the proxy instead?
22:50 pmichaud Tene: I don't know.
22:50 pmichaud I don't understand the whole class/proxy relationship yet.
22:51 particle pmichaud: wrt new 'Foo' becoming new ['Foo'], what does new $P0 become?
22:51 pmichaud that's unchanged
22:51 particle great.
22:52 particle how do i convince bash not to hate me?
22:52 pmichaud and it's really already the case that  new 'Foo' means the same as new ['Foo']
22:52 Cyndi just wanted to say "hi" Patrick.  Tell Paula I said "hi" too.
22:52 pmichaud I didn't find that out until discussion with allison++ last night
22:52 particle ack '\$P\d+\s+=\s+new\s+[\'"]' t
22:52 GeJ particle: threaten it to use zsh instead.
22:52 particle gives me a >
22:52 pmichaud Hiya Cyndi!  Happy New Year!  Hope CRP is treating you and your family well!
22:53 pmichaud particle: you've got an extra quote there
22:53 pmichaud the \ doesn't escape the '
22:53 Tene particle: \ doesn't work in ''s
22:53 particle so how do i search for ['"] ?
22:53 Tene use " instead with more \s
22:53 pmichaud maybe \x37 ?
22:54 pmichaud er, \x27
22:54 pmichaud '\$P\d+\s+=\s+new\s+[\x27"]'
22:54 particle pmichaud++
22:55 pmichaud but I would actually just search for   '\snew\s+[\x27"]'
22:55 pmichaud and similar considerations hold for subclass and isa
22:57 particle something like: ack '=\s+(new|subclass|isa)\s+[\x27"]'
22:58 particle anyway, i'm on my way now
23:01 Tene pmichaud: should I be passing NameSpace objects, classes, protoobjects, etc. as parsegrammar and parseactions to hllcompiler?
23:03 Tene looks like you can't run 'new' on a namespace.
23:08 tetragon joined #parrot
23:15 cognominal joined #parrot
23:36 pmichaud strings to hllcompiler is okay
23:36 pmichaud hllcompiler can parse the string into a namespace
23:36 pmichaud i.e., what it's doing now should be okay.
23:36 pmichaud oh.  hllcompiler is going to get a hll option.
23:37 pmichaud to tell it what hll to work in.
23:42 TiMBuS i know i asked this yesterday but i cant seem to get it. if you override the 'invoke' vtable method using a parrot class, you need to pass the class to itself to run it. like if your class in in $P0 you need to go $P0($P0) for it to work.
23:42 TiMBuS is there a workaround for this or do i just need to make a PMC instead
23:48 ruoso joined #parrot
23:56 particle TiMBuS: there is no workaround i know of
23:57 TiMBuS oh
23:57 TiMBuS :<
23:58 TiMBuS so i'd have to turn it into a pmc
23:59 particle at least, you'd have to write a pmc with the overridden invoke vtable function, but you could write the rest in pir
23:59 TiMBuS i could? :o

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

Parrot | source cross referenced