Camelia, the Perl 6 bug

IRC log for #parrot, 2008-05-19

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 * tetragon is currently setting up today's build fresh build tree
00:00 japhb Can I get A) Filesystem location of OpenGL headers, and B) contents of same posted somewhere or emailed to me?
00:01 tetragon A.1) /System/Library/Frameworks​/OpenGL.framework/Headers
00:01 tetragon A.2) /System/Library/Frameworks/GLUT.framework/Headers
00:02 tetragon (Note, the appropriate include lines for typical headers would be:
00:02 japhb tetragon: Do the header filenames all match '*.h'?
00:02 tetragon #include <GLUT/glut.h>
00:02 tetragon #include <OpenGL/OpenGL.h>
00:02 tetragon And yes, all the header files end in .h
00:03 japhb tetragon: OK, thanks
00:03 japhb Tene: Are you running MSVC, MinGW, or cygwin in that XP VM?
00:03 tetragon You just need to provide the correct framework name, gcc can handle the frameworks.
00:05 tetragon BTW, want the BridgeSupport files for them?
00:06 japhb tetragon: Well, I have to parse the headers, so I actually need to know where they are.  And as discussed last month, Parrot's config system has no way to tell indvidual config steps where headers can be found ....
00:06 japhb What are BridgeSupport files?
00:06 tetragon A little something added into OS X 10.5
00:07 Tene japhb: no, I've never done any development on windows.
00:08 tetragon It's more for scripting languages to be able to access Objective-C libraries, but not all of the libraries with descriptions are Obj-C
00:08 tetragon They're XML files
00:09 tetragon They describe functions, args, and more
00:10 tetragon http://developer.apple.com/documentation/Darwi​n/Reference/ManPages/man5/BridgeSupport.5.html
00:10 shorten tetragon's url is at http://xrl.us/bkpw9
00:10 * tetragon has been considering writing Perl 5 code for BridgeSupport
00:10 japhb Tene: Ah.  I assumed that's what you were making the VM for.  :-)
00:11 japhb tetragon: sort of a modern CamelBones?
00:11 tetragon Yep
00:11 tetragon I had previously looked at CamelBones, but it's lack of Leopard support killed it off as an option for what I do at work
00:12 japhb tetragon: hmmm, the BridgeSupport stuff looks intriguing.  Yes, please send it along as well.
00:12 japhb nodnod
00:13 tetragon japhb: email address?
00:19 tetragon Sent
00:20 japhb thx
00:26 DietCoke leopard?
00:26 purl well, leopard is a panther or not Panther or OS X 10.5 or at http://www.apple.com/macosx/leopard/
00:26 DietCoke thanks, purl. I can never remember which cat is which.
00:28 DietCoke tiger?
00:28 purl tiger is, like, OS X 10.4
00:29 DietCoke panther?
00:29 tetragon 10.3
00:29 DietCoke feed the bot. =-)
00:29 DietCoke panther is OS X 10.3
00:29 tetragon jaguar?
00:29 purl somebody said jaguar was incredibly much faster than 10.0x
00:29 DietCoke no, jaguar is OS X 10.2
00:29 purl okay, DietCoke.
00:30 DietCoke puma?
00:30 purl Puma?  Puma.  PUMA!
00:30 DietCoke no, puma is OS X 10.1
00:30 purl okay, DietCoke.
00:30 DietCoke cheetah?
00:30 purl rumour has it cheetah is like $700 for 9.8GB, so you'd beed 4 of those, and some sort of rack with raid controller or apparently quiet, which is in stark contrast to the 1st-gen cheetah i put up with and PAID $1000 FOR in joebloe's desktop mac for about 2 years
00:30 DietCoke no, cheetah is OS X 10.0
00:30 purl okay, DietCoke.
00:30 DietCoke wikipedia++
00:30 DietCoke Wow, there's a desk under this mess.
00:39 * tetragon grumbles about nosy, noisy siblings
00:50 teknomunk joined #parrot
03:37 DietCoke particle will be happy to hear I'm probably bringing my windows laptop to the con.
05:53 japhb DietCoke: would you happen to have OpenGL headers on said windows machine?
05:53 ilbot2 joined #parrot
05:53 Topic for #parrotis now Devel: 0.6.1 | http://parrotcode.org/ | 19/675 new/open tix
06:18 uniejo joined #parrot
06:57 Eevee perl6 roadmap includes 'selected libraries written in perl 6' -- what does this have in mind?
07:19 iblechbot joined #parrot
07:21 dalek r27626 | fperrad++ | trunk:
07:21 dalek : [Lua]
07:21 dalek : - bytecode translation : refactor forlist
07:21 dalek : - revert r27956
07:21 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27626
07:30 bacek_ joined #parrot
07:41 avar joined #parrot
07:44 Tux joined #parrot
07:44 Tux left #parrot
07:48 dalek r27627 | pmichaud++ | p6object:
07:48 dalek : [p6object]:
07:48 dalek : * Add 'name' vtable method to protoobjects.
07:48 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27627
07:54 IllvilJa joined #parrot
08:30 timbunce joined #parrot
08:33 timbunce Just built parrot (r27627) for first time in ages. Got two failures (on my Mac 10.5.2). Just want to check if they're expected:
08:33 timbunce t/tools/smartlinks.t                       (Wstat: 256 Tests: 73 Failed: 1)
08:33 timbunce Failed test:  16
08:33 timbunce Non-zero exit status: 1
08:33 timbunce t/examples/library.t                       (Wstat: 256 Tests: 4 Failed: 1)
08:33 timbunce Failed test:  3
08:33 timbunce t/tools/smartlinks.t                       (Wstat: 256 Tests: 73 Failed: 1)
08:33 timbunce Failed test:  16
08:33 timbunce t/examples/library.t                       (Wstat: 256 Tests: 4 Failed: 1)
08:33 timbunce Failed test:  3
08:38 jonathan timbunce: I think the library.t failure is interesting - it's known to be failing on Mac for some people, but I'm not sure how well it's been figured out yet.
08:41 dalek r27628 | pmichaud++ | p6object:
08:41 dalek : [p6object]:
08:41 dalek : * Allow protoobjects as 'parent' arguments to 'new_class'.
08:41 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27628
08:45 timbunce thanks jonathan.
09:00 Zaba joined #parrot
09:03 dalek r27629 | allison++ | pdd25cx:
09:03 dalek : [pdd25cx] Rework the PDD to keep 'rethrow' op and eliminate 'handled' op.
09:03 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27629
09:03 pmichaud Eevee: (cmp bug)  it looks like it's a bug in Parrot
09:08 * jonathan wonders what time it must be where pmichaud is...
09:08 nopaste "pmichaud" at 76.183.97.54 pasted "cmp bug in Parrot (for Eevee)" (21 lines) at http://nopaste.snit.ch/13010
09:08 pmichaud 04:08 here
09:09 pmichaud finished the major round of grading at 01:00, had a snack, went to bed at 01:45, woke up at 02:30.
09:10 pmichaud after not getting back to sleep by 02:45 I decided I might as well do some hacking.  :-)
09:10 jonathan :-)
09:10 moritz insomnia--
09:10 pmichaud but I'm about to head off to bed again
09:10 jonathan Hope sleep works out a little better this time
09:10 jonathan hacking++
09:11 nopaste "pmichaud" at 76.183.97.54 pasted "for jonathan: corollary patch for vtable_name patch" (13 lines) at http://nopaste.snit.ch/13011
09:12 pmichaud I haven't applied nopaste#13011 yet, but I think it's likely necessary.
09:12 dalek r27630 | allison++ | pdd25cx:
09:12 dalek : [pdd25cx] Initial filename change for ExceptionHandler.
09:12 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27630
09:13 jonathan pmichaud: Works for me.
09:13 pmichaud otherwise tracing ends up in a recursive loop :-)
09:13 jonathan If it builds and smokes, go ahead and a apply.
09:13 jonathan D'oh! :-)
09:13 pmichaud because we try to get the name of the class to display in the trace, but that calls a vtable sub, which generates instructions that need to get the name of the class, which calls a vtable sub, ...
09:15 pmichaud so, the patch causes trace to ignore any vtable_name entries when displaying the class of an object.
09:15 jonathan It probably makes it easier to know what class it REALLY is too.
09:15 jonathan But yes, stopping the infinite recursion is certainly wanted. :-)
09:16 pmichaud I have't had a chance to smoke it yet, but will do so in a few hours when I start hacking again.
09:16 pmichaud too tired to reliably do it now.
09:16 pmichaud later
09:16 pmichaud afk # sleep
09:33 ruoso joined #parrot
09:39 dalek r27631 | allison++ | trunk:
09:39 dalek : [exceptions] Deprecate old 'rethrow' C functions.
09:39 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27631
10:05 dalek r27632 | fperrad++ | trunk:
10:05 dalek : [Lua]
10:05 dalek : - bytecode translation : remove magic numbers from rules (BITRK, MASRK)
10:05 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27632
10:16 dalek r27633 | allison++ | pdd25cx:
10:16 dalek : [pdd25cx] Rename Exception_Handler to ExceptionHandler.
10:16 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27633
10:21 dalek r27634 | allison++ | pdd25cx:
10:21 dalek : [pdd25cx] Adding PARROT_CAN_RETURN_NULL attribute to Parrot_cx_peek_task.
10:21 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27634
11:11 Ademan joined #parrot
11:45 dalek allison@perl.org | Concurrency Tasks:
11:45 dalek link: http://www.perlfoundation.org/pa​rrot/index.cgi?concurrency_tasks
11:45 shorten dalek's url is at http://xrl.us/bjqpy
11:47 dalek allison@perl.org | Concurrency Tasks:
11:47 dalek link: http://www.perlfoundation.org/pa​rrot/index.cgi?concurrency_tasks
11:47 shorten dalek's url is at http://xrl.us/bjqpy
11:48 dalek allison@perl.org | Concurrency Tasks:
11:48 dalek link: http://www.perlfoundation.org/pa​rrot/index.cgi?concurrency_tasks
11:48 shorten dalek's url is at http://xrl.us/bjqpy
11:50 Senaka joined #parrot
11:50 Senaka left #parrot
11:51 davidfetter joined #parrot
12:06 tetragon joined #parrot
12:34 mj41 joined #parrot
13:00 jhorwitz joined #parrot
13:02 iblechbot_ joined #parrot
13:28 paco joined #parrot
13:33 dalek r27635 | pmichaud++ | trunk:
13:33 dalek : [core]:
13:33 dalek : * r27621 allows overriding the 'name' vtable method from PIR (jonathan++)
13:33 dalek :   but results in an infinite recursion if tracing is turned on.  This
13:33 dalek :   change avoids that.
13:33 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27635
13:52 Andy joined #parrot
13:55 dalek r27636 | fperrad++ | trunk:
13:55 dalek : [Lua]
13:55 dalek : - bytecode translation : add a synopsis in rules
13:55 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27636
13:58 Coke joined #parrot
13:58 Coke opbots, names
13:58 Coke opbots, trust rgrjr
13:58 slavorg Ok
13:58 clunker3 But I do not trust you Coke
13:59 Coke bite me, clunker!
13:59 dalek r27637 | fperrad++ | trunk:
13:59 dalek : [Lua]
13:59 dalek : - fix test with luac2pir.pir
13:59 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27637
14:01 Psyche^ joined #parrot
14:01 particle clunker3: trust coke
14:01 clunker3 But I do not trust you particle
14:01 was kicked by particle: clunker3
14:02 confound haha
14:10 Coke clunker, who do you trust?
14:11 Coke purl, trust noone.
14:11 purl Coke: excuse me?
14:20 nopaste "pmichaud" at 76.183.97.54 pasted "This is particularly unhelpful." (20 lines) at http://nopaste.snit.ch/13012
14:26 dalek r27638 | pmichaud++ | p6object:
14:26 dalek : [p6object]:
14:26 dalek : * Fix pod in P6object.pir.
14:26 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27638
14:26 dalek r27639 | pmichaud++ | p6object:
14:26 dalek : Sync p6object branch with vtable_name changes in trunk.
14:26 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27639
14:28 Coke pmichaud: there is a ticket open about various, conflicting ways to check POD, I think.
14:28 pmichaud in this case it turned out to be two '=cut' lines in a row.
14:28 pmichaud (separated by some comments).  Podchecker sees that as being valid, t/doc/pod.t doesn't.
14:35 Coke I would eliminate the reference to podchecker in the diagnostic.
14:37 kj joined #parrot
14:41 dalek r27640 | pmichaud++ | p6object:
14:41 dalek : [pge]:
14:41 dalek : * first round of converting PGE to use P6object instead of Protomaker
14:41 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27640
15:15 jhorwitz anyone have thoughts on #54444?  i'm blocking on that right now.  :(
15:16 NotFound joined #parrot
15:16 NotFound Hello.
15:16 Tene Hm.  pmichaud is your best bet for that, jhorwitz.
15:16 Tene Hi, NotFound!
15:16 pmichaud looking.
15:16 rdice joined #parrot
15:17 pmichaud the whole prologue code for perl6 subs is very likely to change soon (and radically)
15:17 * jhorwitz isn't surprised  :)
15:18 pmichaud but whether that will happen this week or next... I can't say just yet.
15:18 pmichaud at the moment I'd bet it'll be next week at the earliest.
15:18 jhorwitz i can use a wrapper sub to create an artificial call frame for now, though that has its own issues...
15:18 pmichaud feel free to submit a patch to test the caller depth.
15:19 pmichaud i.e., it's okay if we don't set '$/' if there's no previous call frame.
15:19 NotFound Someone wants to kill some code? #54428
15:20 jhorwitz pmichaud: how do we test for that?  right now any access to a nonexistent call frame is fatal.
15:20 pmichaud can we check for the number of elements in %r['lexpad'] ?
15:20 jhorwitz nope
15:20 pmichaud instead of jumping directly to  %r['lexpad';1]  ?
15:21 * pmichaud tries a few things.
15:21 jhorwitz reading the source, the return value is calculated based on the passed in call frame depth.
15:22 pmichaud try this... (nopasting)
15:22 jhorwitz IIRC, i get NULL for %r['lexpad'] cuz there's no lexpad in my current call frame.  doesn't help me calculate elements
15:23 nopaste "pmichaud" at 76.183.97.54 pasted "lexpad for jhorwitz" (10 lines) at http://nopaste.snit.ch/13013
15:23 jhorwitz that works
15:24 pmichaud so, add a test for null to the rakudo prologue for now.
15:24 pmichaud feel free to commit directly (if you have a commit bit and if 'make test' still passes for rakudo).
15:24 jhorwitz sounds good.  i'll make sure it works with mod_perl6.  you want me to commit that?
15:24 jhorwitz cool
15:24 pmichaud we're wanting to be a little careful on commits today (and tomorrow) until chromatic cuts the release
15:26 Coke can always have a branch to play in.
15:27 pmichaud most of what I'm working on at the moment is a little on the major side, so I'm tending to do everything in branches.
15:27 jhorwitz i can wait til the release
15:27 pmichaud it's okay to commit this one, though -- it's pretty minor and as long as 'make test' passes I think we'll be in good shape.
15:28 jhorwitz ok then.  :)
15:28 pmichaud and it'll close a ticket.
15:28 jhorwitz one in, one out.  :)
15:29 * pmichaud looks at #54428.
15:30 pmichaud #54428 looks great to me.
15:30 pmichaud I'll apply as soon as I finish my branch merge and can do a make test.
15:31 NotFound I'll go for the "Code Eraser" award ;)
15:32 dalek r27641 | pmichaud++ | trunk:
15:32 dalek : Merge p6object branch into trunk.  This just merges the core
15:32 dalek : P6object library itself -- none of pge, pct, rakudo, etc. make
15:32 dalek : use of P6object yet.  Those get migrated in separate branches
15:32 dalek : of their own.
15:32 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27641
15:33 dalek r27642 | pmichaud++ | p6object:
15:33 dalek : Remove p6object branch, it's gone back to trunk.
15:33 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27642
15:34 jhorwitz pmichaud: ok to use arbitrary temp registers in inline PIR?  e.g. $P0 = %r['lexpad']
15:34 pmichaud $P0 through $P9, yes.
15:34 pmichaud (and $I0 through $I9, $S0 through $S9, $N0 through $N9)
15:34 jhorwitz k
15:34 cognominal pmichaud: is pge supposed to work with Unicode?
15:35 pmichaud cognominal: yes.
15:35 pmichaud more precisely, though, it depends on Parrot for its unicode support.  So if Parrot doesn't handle something in unicode, then PGE doesn't do it.
15:36 cognominal my parrot is compile with ICU
15:36 pmichaud then it should work.
15:36 cognominal is there a way to know if my parrot is unicode ready?
15:36 pmichaud rakudo isn't doing unicode at the moment, though, because it really slows things down.
15:36 pmichaud that's why we don't have « or » in the grammar yet.
15:37 cotto_work joined #parrot
15:37 cotto_work that definitely didn't do the right thing
15:38 cognominal I will check later the problem. I must work on my presentation.
15:41 NotFound A simple test can be to evaluate the length in characters of a utf8 string.
15:41 pmichaud a simple test for...?
15:41 Coke if parrot supports unicode at runtime.
15:41 NotFound Unicode readyness.
15:42 pmichaud I think parrot can do that even if icu isn't present.
15:42 Coke though it seems we should be able to interrogate the config object for that.
15:42 pmichaud parrot does have *some* unicode support even if icu isn't present, it just doesn't have complete support.
15:42 cognominal pmichaud, btw in STATUS  "* non-capturing subrules  (<?expr>)" is now incorrect
15:43 dalek r27643 | infinoid++ | trunk:
15:43 dalek : [PMC] Fix warning:
15:43 pmichaud otherwise we wouldn't be able to handle « or » at all on platforms w/o icu
15:43 dalek : ./src/pmc/object.pmc: In function 'Parrot_Object_name':
15:43 dalek : ./src/pmc/object.pmc:159: warning: return from incompatible pointer type
15:43 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27643
15:43 pmichaud cognominal++  # good catch
15:44 cognominal pmichaud: I am preparing a presentation on PGE. I would like you to contribute a few lines about debbugging a grammar
15:44 pmichaud best approach is to not create any bugs in the grammar in the first place.  :-)
15:44 dalek r27644 | pmichaud++ | trunk:
15:44 dalek : [core]:
15:44 dalek : * More dead code removal!
15:44 dalek : * Patch via RT#54428 from NotFound++ <julian.notfound at gmail.com>
15:44 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27644
15:45 particle ...and don't keep changing the spec
15:45 pmichaud but really, the way I tend to debug grammars is to add <.panic: ...> rules
15:45 Tene come to think of it, <.warn: ...> might be useful.
15:45 cognominal ok
15:45 pmichaud I used to have a .warn
15:46 pmichaud helpful to someone doing PIR is to sometimes do   {{ trace 1 }}    and   {{ trace 0 }}
15:46 pmichaud I am considering having a trace mode where one can easily see the entry and exits from individual subrules.
15:47 cognominal one thing I did was to print the pir before evaluating it. Very useful in intereactive mode
15:47 cognominal But I am really talking parsing in my talk
15:47 pmichaud but I'm not quite sure how to enable/disable a trace mode yet.  possibly a modifier, like :trace
15:47 cognominal the other one will be about pct
15:48 pmichaud I have decided to try to give pge a substantial code refactor this week or next.
15:48 pmichaud I'm not happy with the current convoluted form of PGE::Match and PGE::Grammar, and saturday morning I woke up knowing how to resolve it.
15:48 cognominal you have finished you protostuff?
15:48 pmichaud I also figured out how to do a useful version of protoregexes
15:48 particle pmichaud: seems like a hook to give instructions to the rule engine is a good extension to S05
15:49 pmichaud particle:  I think that modifiers are that hook.
15:49 particle well... there needs to be something specific
15:49 pmichaud how do you mean?
15:49 particle i expect perl 6 will reserve, maybe, all lower-case modifiers
15:49 pmichaud (and there's always the hook of embedded code.)
15:50 pmichaud oh no, perl6 is pretty explicit about making them available
15:50 purl okay, pmichaud.
15:50 particle ok then
15:50 pmichaud generally Perl 6 reserves uppercase things.
15:50 particle well, :i :s etc are lowercase
15:51 pmichaud S05 has:
15:51 pmichaud # User-defined modifiers will be possible:
15:51 pmichaud m:fuzzy/pattern/;
15:51 pmichaud # User-defined modifiers can also take arguments, but only in parentheses:
15:51 pmichaud m:fuzzy('bare')/pattern/;
15:51 moritz isn't :P5 upper case?
15:51 particle yep
15:51 particle hrmm... does rakudo have :P5 yet? shouldn't be hard to do
15:52 pmichaud rakudo doesn't have P5 yet.  I don't know if rakudo supports modifiers yet.
15:52 pmichaud and I'm not sure that PGE understands :P5 yet, either.
15:52 pmichaud if pge does :P5 then rakudo doesn't have to do anything special.
15:52 Coke perl6?
15:52 purl perl6 is pretty explicit about making them available
15:52 jonathan I'm pretty sure Rakudo doesn't do modifiers yet.
15:52 * Coke pats purl on the head. #idiot.
15:53 jhorwitz pmichaud: i don't think that lexpad check is working. looks like %r['lexpad'] returns a valid lexpad for the current frame and therefore proceeds to check %r['lexpad';1]
15:53 pmichaud okay, if there's a valid lexpad, can you check its size?
15:53 jhorwitz via elements?
15:53 pmichaud yes.
15:53 dalek r27645 | fperrad++ | trunk:
15:53 dalek : [Lua]
15:53 dalek : - bytecode translation : don't generate duplicated .lex
15:53 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27645
15:54 jhorwitz pmichaud: yes
15:54 jhorwitz shall i skip if it's 0?
15:54 pmichaud or, let's get lexpads to do something reasonable when too large a stack depth is encounter... like return null instead of throwing an exception.
15:54 pmichaud skip if it's less than 2.
15:54 jhorwitz ok
15:54 pmichaud (noting that lexpad.elements == 1 would still not be sufficient :-)
15:55 jhorwitz btw, i also prefer returning null instead of throwing an exception.  but this will work as a stopgap.
15:55 pmichaud well, parrot has been slowly migrating over to "return null" instead of "throw exception" for stuff like this.  But there are still a few places that haven't migrated yet.
15:57 dalek r27646 | pmichaud++ | trunk:
15:57 dalek : [pge]:
15:57 dalek : * Update STATUS with respect to non-capturing subrules. (cognominal++)
15:57 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27646
15:57 * jhorwitz needs a new server for compiling actions.pm...  ;-)
15:57 pmichaud I'm hoping the protoregex stuff will speed that up a bit.
15:58 pmichaud because we won't be going down so many false trails on each statement or term.
16:01 Theory joined #parrot
16:03 pmichaud mmmm, I like closing RT tickets.
16:05 pmichaud looks like as soon as the release happens I can close five more.
16:07 cognominal can I bribe someone to commit http://rt.perl.org/rt3/Tic​ket/Display.html?id=52276
16:07 cognominal I really want stuff which works in perl5 to work in perl6 to better convince people
16:08 cognominal the noj surprise rule...
16:08 pmichaud there are going to be surprises for a bit longer in rakudo -- at least until we get mutables implemented.
16:08 pmichaud that's on my agenda to happen about the same time as the pge refactor.  right now those are competing for priority in my head :-)
16:09 pmichaud (reviewing patch)
16:09 cognominal I should have commented it :(
16:09 pmichaud did you try 'make test' on it?
16:09 pmichaud I'm concerned abou
16:09 pmichaud *about:
16:09 pmichaud + if $key eq '[ ]' or $key eq '( )' {
16:10 pmichaud since they aren't exactly the same
16:10 cognominal I use rakudo all the time.
16:10 cognominal what should I test?
16:10 pmichaud I don't know.  If parens were roughly working before, then I'd be concerned that this changes their behavior.
16:11 pmichaud otoh, it looks pretty close to me.  I'll apply with some changes.
16:12 cognominal you can leave them out.
16:12 pmichaud the nqp portion of the patch is fine.
16:12 cognominal I like the low precedence or and and
16:12 pmichaud agreed, they're useful.
16:14 Coke NotFound++
16:15 Coke NotFound: there is a ticket for verifying all functions are used, btw. Feel free to claim that one. =-)
16:15 sjansen joined #parrot
16:16 NotFound I've not done that... yet ;)
16:16 pmichaud he didn't say close it -- just claim it.  :)
16:17 pmichaud argggh, I don't like all of the explicit tests in actions.pm for infix:,
16:17 pmichaud those really should not be there.
16:18 cognominal it's ugly but I did not find better
16:18 pmichaud right... but apparently the number has expanded a bit since I last scanned actions.pm
16:18 pmichaud I think I had only one in there a few months ago.
16:19 cognominal and next we will have the ';' for multidimensionnals
16:19 pmichaud using syntax to check these things is just wrong.
16:19 pmichaud (or, more precisely, hardcoding the syntax to check these things...)
16:20 jhorwitz pmichaud: elements of %r['lexpad'] was 7!
16:20 pmichaud jhorwitz: ah yes, I remember this problem.
16:20 pmichaud if the 7th caller up doesn't have a lexpad entry, it throws the exception, I think.
16:20 pmichaud or maybe that's not it.
16:20 pmichaud hrm.
16:20 cognominal so we must parse a ,  list of  indefinite length to get it in grammar.pg
16:21 pmichaud cognominal: hrm?
16:21 purl Hrm. Hrm. Hrrrrrrm, rrrrm, rrrrrrrrr.
16:21 Coke zombie?
16:21 * purl eats Coke's brains
16:21 * Coke loves purl!
16:22 cognominal I meant a comma separated list of indefnit length in grammar.pg to get it out of actions.pm
16:22 pmichaud grammar.pg already parses comma separated lists of indefinite length
16:23 pmichaud what we need to do is to have infix:, return an appropriate PAST node
16:23 pmichaud oh, I know what bugs me about this patch.
16:23 pmichaud (3) is not a list.
16:23 pmichaud but this patch makes it one.
16:24 Tene That's unfortunate.
16:24 pmichaud that also means that expression like   5 + (4 + 2)   will probably give the wrong answer.
16:25 pmichaud because it'll treat it the same as   5 + [4 + 2]
16:25 cognominal yea
16:25 Tene purl: 5 + (4 + 2)
16:25 purl 11
16:25 cognominal List
16:25 cognominal > 5 + ( 4 + 2)
16:25 cognominal set_number_native() not implemented in class 'ResizablePMCArray'
16:25 cognominal inedeed
16:26 cognominal but I think one should et everything in grammar.pg. And call operator::,   even with 0 operators
16:27 pmichaud no
16:27 cognominal and fix operator::, if it does not
16:27 pmichaud with (3)  there is no infix:,
16:27 pmichaud because parens do not mean "make a list"
16:27 cognominal I an speaking of []
16:27 cognominal I aree that parens are speial
16:27 pmichaud for [] all that we do is call the 'list' function on the arguments
16:28 pmichaud we shouldn't have to check for infix:,
16:28 pmichaud (I agree that this doesn't work yet... thus my comment that we should fix the past generation for infix:, rather than plaster it explicitly throughout actions.pm)
16:28 cognominal the problem is that with  "[]"  we have no comma, so it does not know it is a infix:, with o operands
16:28 pmichaud that's not a problem
16:28 slightlyoff joined #parrot
16:29 pmichaud calling list()  (with no arguments) returns an empty list.
16:29 slightlyoff left #parrot
16:29 pmichaud more precisely, though, [] should call Array.new
16:29 pmichaud so that it returns an Array instead of a List.
16:29 cognominal [] is a list. The problem is that affectation does not make it an Array
16:30 pmichaud and calling Array.new() with no arguments would result in an empty array.
16:30 cognominal a List is a immutable array
16:30 cotto_work joined #parrot
16:31 pmichaud anyway.  tying "empty list creation"  to "infix:, with no operands" is the wrong approach.
16:31 cognominal now List behaves as array
16:31 cognominal you can push on a List
16:33 cognominal > say (3,4,5,6).push( 1)
16:33 cognominal 5
16:33 cognominal odd
16:34 * cognominal reverts into rakudo user mode
16:37 pmichaud I'll see if I can fix the infix:, parse a bit later today.
16:37 cognominal thx for the feedback
16:38 cognominal fix the infix, what a slogan
16:39 particle it'll be a fixity-fix
16:39 cognominal the fixity is right though
16:40 particle i know :( but the alliteration was too hard to resist
16:41 pmichaud anyone know approximately what time chromatic might be planning to cut the release?
16:41 pmichaud I'm trying to figure out my hacking schedule for the next two days.
16:41 Coke haven't heard, no.
16:41 particle no, but likely after parrotsketch
16:41 particle you should email him
16:41 pmichaud it's not critical that it be at a specific time -- just that knowing an approximate time might help me to adjust my task list
16:41 Coke or we can create a "dontscrewupmarrelease" branch and just roll it all in afterwards.
16:42 * Coke peers.
16:42 Coke s/mar/may/
16:43 pmichaud that might be a better approach than making separate branches for each feature I want to work on, yes
16:45 Coke as long as it's all destined for trunk in a day, I think it'll work ok.
16:45 Coke I'm just trying to insure you have uninterrrupted hacking time. =-)
16:46 pmichaud well, it's time for an interruption... need lunch
16:46 pmichaud bbiaw
17:10 cjfields joined #parrot
17:32 cjfields_ joined #parrot
17:43 Tene This class is fun, but mentally exhausting to teach.
17:45 jonathan Tene: what are you teaching?
17:46 Tene jonathan: http://www.redhat.com/courses/rh300_r​hce_rapid_track_course_and_rhce_exam/
17:46 shorten Tene's url is at http://xrl.us/bkqt3
18:01 Ivatar joined #parrot
18:10 Limbic_Region joined #parrot
18:24 pmichaud hey, I took that course!
18:24 pmichaud in dec 2002 :-)
18:27 Tene Heh.
18:34 pmichaud my rhce has expired now, though.  :-|
18:35 cotto_work joined #parrot
18:35 Tene Hm, I wonder what would happen if I added an "extra" student to my exam this Friday.
18:35 particle pmichaud: do we have defaults on params yet? method foo(Str $bar = 'baz') ??
18:35 pmichaud particle: yes
18:36 pmichaud added those about 10 days ago :-)
18:36 particle hrmm. maybe i need to update something outside languages/perl6
18:36 Tene I remember that commit.
18:36 Tene > sub foo ($f = 3) { say $f }; foo()
18:36 Tene 3
18:36 particle Statement not terminated properly at line 61, near "$type     "
18:36 particle method header (
18:36 particle Str        $type      = 'text/htmll',   # line 61
18:36 particle Str        $charset   = undef,
18:37 Tene > sub foo (Str $f = "foo") { say $f }; foo()
18:37 Tene Parameter type check failed
18:37 * Tene back to teaching.
18:37 pmichaud I'd be wary of types in parameters at the moment.  It's great that we have type checking, but not all of the types are working yet.  :-|
18:37 particle rats.
18:37 pmichaud that said, the problem that particle is seeing must be a parsing problem
18:38 particle i'm trying to import/convert CGI.pm from pugs repo
18:39 particle looks to be Str|Array :$cookie?
18:39 pmichaud I don't know if rakudo supports type junctions yet.
18:40 particle me neither, but i suspect not
18:41 particle and we can't s[] = ... yet either
18:41 particle how can i search/replace?
18:41 pmichaud i don't know.  we're not quite there yet.
18:41 particle match and substr?
18:42 pmichaud that might work.
18:42 particle i'll need index, too....
18:42 NotFound Code Eraser strikes again: #54454
18:42 pmichaud might see if there's a "replace" method for Str and implement that
18:44 Coke there's a replace in the parrot version you can inherit.
18:45 pmichaud except it works on fixed strings
18:45 pmichaud s[] uses regexes
18:46 Coke ah, didn't realize one implied 'tother. yah, that won't work, then.
18:50 particle hrmm, i guess we can't do pointy blocks yet
18:50 particle my $foo -> $bar { ... };
18:50 particle i forgot an equals there
18:50 pmichaud as soon as I fix up <sym> processing in PGE we can do pointies.
18:51 pmichaud or we could do a somewhat ugly hack.  I prefer to get protoregexes in PGE working to doing the hack, though.
18:51 particle eta?
18:51 purl well, eta is estimated time of arrival or Euskadi Ta Askatasuna, or like the Basque PLO
18:51 pmichaud early next week?
18:51 particle ok
19:10 particle Method 'lvalue' not found for invocant of class 'PAST::Stmts'
19:11 particle ok, after converting some lines, and commenting out 76, 'use CGI;' parses, and fails with the error in my last message
19:12 particle actually, it parses with fewer comments
19:12 particle but then i get 'gather' not implemented
19:13 particle basically, we need gather/take, s:g[]=..., and pointy blocks to get CGI compiling
19:13 particle and perhaps return to get it truly working
19:13 particle anyway, lunch &
19:17 dalek r27647 | pmichaud++ | trunk:
19:17 dalek : [nqp]:
19:17 dalek : * Add low-precedence infix:<and> and infix:<or>     (cognominal++)
19:17 dalek : * Patch courtesy St�phane Payrard <cognominal at gmail.com>
19:17 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27647
19:25 tetragon joined #parrot
19:27 tetragon japhb: Do you also want the OpenGL headers from 10.4?
19:32 japhb tetragon: yes, please, that would be great
19:33 cjfields joined #parrot
19:34 dalek r27648 | pmichaud++ | trunk:
19:34 dalek : [oo]:
19:34 dalek : * more dead code removal from NotFound++ !
19:34 dalek : * Patch via RT#54454, courtesy NotFound <julian.notfound  at gmail.com>
19:34 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27648
19:36 tetragon japhb: sent
19:36 japhb thx!
19:36 tetragon And yes, there are differences between the sets
19:36 japhb Can't work on it right at the moment, $day_job ...
19:36 japhb tetragon: I assumed as much.  :-)
19:36 tetragon Including, in a couple places, type
19:37 japhb sheesh
19:37 dalek r27649 | fperrad++ | trunk:
19:37 dalek : [Lua]
19:37 dalek : - bytecode translation : fix closure generation
19:37 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27649
19:38 tetragon For instance, for CGLCreatePBuffer, 10.4 uses long for the height and width, while 10.5 uses GLsizei
19:38 tetragon (wouldn't be surprised if GLsizei is equivalent to long)
19:38 pmichaud use.perl.org is down?
19:39 tetragon japhb: Holiday where I am.
19:39 japhb pmichaud: it's been flaky for days.  I usually wait a couple minutes, refresh, and it suddenly starts working again
19:40 Coke anyone open a ticket?
19:40 Coke webmaster@perl.org
19:41 japhb tetragon: if stupid Debian hadn't horked SVK, I'd happily send you my current diff, which contains among other things a typemap.  I believe it currently has GLsizei => 'int' .
19:41 pmichaud japhb++  that works.
19:41 pmichaud er, maybe.
19:42 japhb Hmmm.
19:42 * japhb adds 'check typemaps are the same across OSen' to opengl-todo
19:43 tetragon And it is int on 10.5
19:44 tetragon But long on 10.4
19:45 tetragon Just like GLint is long on 10.4 and int on 10.5
19:47 ambs joined #parrot
19:48 ambs \o/
19:49 japhb tetragon: sounds like "Wrong on 10.4, fixed on 10.5" so far.
19:50 tetragon Most non-pointer longs I see were switched to int (in the typedefs that I looked at)
19:50 tetragon Actually, it may be all non-pointer longs
19:52 japhb "Ooops, choosing int = long kinda sucks when we switch to 64-bit CPU.  And the graphics card hates it."
19:54 tetragon haha, but Apple had already released a box with a 64-bit CPU before 10.4 came out
19:54 tetragon (They didn't do as much 64-bit core OS at that time, though)
19:54 japhb Don't tell me, tell them.  ;-)
19:55 japhb Right
19:55 tetragon Other changes include using macros instead of simple casts in some places
19:55 japhb But it also could have been one of those things that didn't so much *break* things as just make them much slower because suddenly core operations were slinging twice as much data around the buses
19:55 japhb tetragon: wheeee ...
19:56 tetragon 10.5 has the macros, 10.4 has casts
19:56 japhb Sounding like 10.4 and 10.5 might as well be different platforms, from a porting perspective.
19:57 tetragon Check on more than just the GLUT version
19:58 tetragon They both claim GLUT 5, but I don't think 10.4 has OpenGL 2.1
19:58 japhb tetragon: Right now I'm handling the OpenGL compatibility via the header parsing.
19:59 tetragon 10.5 sets CGL_VERSION_1_2, while 10.4 doesn't
19:59 japhb I only detect GLUT version in the first place so that I can frob the C code in glut_callbacks.c
20:00 tetragon I don't think there are any relevant changes to GLUT
20:00 japhb tetragon: the real test will be Windows, where OpenGL is purposely made more painful, so that early DirectX could get a foothold.  Not that I'm bitter or anything.
20:00 ruoso joined #parrot
20:00 japhb tetragon: I didn't expect so.  And even so, I only care about changes to the callbacks.  The rest I will discover during parsing.
20:02 Eevee japhb: don't worry, I'm pretty bitter
20:03 japhb "Alimony Ale: The Bitterest Brew in America"
20:03 japhb (Never actually had it, but damn what a name)
20:05 dalek r27650 | pmichaud++ | trunk:
20:05 dalek : [pct]:
20:05 dalek : * Remove redundant 'returns' method.
20:05 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27650
20:07 Tene pmichaud: any ideas on what would need ot happen to get 'lc $a eq lc $b' to parse properly?
20:07 Tene Right now it's parsed as: lc ($a eq (lc $b))
20:07 Tene Or, is that right with Perl 6 precedence rules?
20:08 tetragon japhb: 10.5 also deprecates some values of CGLPixelFormatAttribute
20:08 ambs Coke, you have new email
20:09 japhb tetragon: for now, I'm glossing over enums.  I'll need them for people who want to do core CGL coding, but not needed yet while we're still in the "GLUT is good enough" phase of the porting work.
20:09 * tetragon generally sticks to the higher level Core Image framework
20:10 japhb I'd be damned happy to have a useful example app doing OpenGL 1.2 graphics using GLUT, working across all tier-1 porting platforms.  Once I get to that point, then I can raise my expectations a bit.
20:11 japhb Plus, I still am waving my hands mightily at things like interleaved vertex arrays with multiple base types
20:11 japhb (Though I've got a first guess at how to handle that, it may be rather slow.  :-(  )
20:12 japhb tetragon: and thank you again very much for your porting support!
20:12 tetragon Just don't use OpenGL 2.1 for the example; OS X 10.4 doesn't support it
20:15 japhb After allison convinced me not to port all of the red book examples, I'm thinking of doing a series of examples, using OpenGL 1.1/1.2 (last easy-to-use Windows version), 1.3 (first hardware accelerators), 1.5 (last fixed-pipeline hardware accelerators), 2.0 (most driver support for shaders), and 2.1 (the latest).  I'll do them in order, so it will take a while to get to that last one.  :-)
20:17 jhorwitz pmichaud: ping
20:19 Coke ambs: crap!
20:19 Coke (having not read your email, I can guess what it is!)
20:19 Coke ah, good, not dead yet.
20:19 Coke ambs++
20:19 ambs Coke, :)
20:20 ambs Coke, I really want your votes, but brian wants to publish results on TPR
20:20 ambs so, I need to get them fast
20:24 Coke crap, that leaves just me, doesn't it.
20:25 ambs yes
20:27 dalek r27651 | fperrad++ | trunk:
20:27 dalek : [Lua]
20:27 dalek : - bytecode translation : fix concat generation
20:27 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27651
20:28 * Coke tries to figure out why that thread starts with tilly's message and not ambs's.
20:29 ambs DietCoke, not sure
20:30 pmichaud jhorwitz: pong
20:30 jhorwitz pmichaud: any progress wrapping your brain around the caller depth problem?
20:30 jhorwitz er, lexpads and such
20:30 pmichaud not off the top of my head, no.  is the depth of the lexpad stack really coming back as 7?
20:30 jhorwitz yep
20:31 pmichaud I wonder if that's a "fake" number, or if the lexpad stack really does have 7 entries.
20:31 jhorwitz if it were fake, i'd imagine it's being set somewhere...
20:32 pmichaud I'm thinking "fake" as in "not really set, so garbage"
20:32 pmichaud tene:  in order for lc $a eq lc $b to parse properly we'd have to define lc as a named unary
20:32 pmichaud i.e., prefix:<lc>
20:34 jhorwitz pmichaud: i see. i can probably check that.
20:34 pmichaud wish I could somehow get    proto prefix:<lc> is name('lc') { ... }    to work.  I'll have to think about that.
20:35 Topic for #parrotis now Devel: 0.6.1 | http://parrotcode.org/ | 17/674 new/open tix
20:36 * pmichaud keeps closing tickets.  :-)
20:36 pmichaud would like to get us down to 690.
20:39 Eevee one more?  :P such aspirations
20:41 pmichaud 690.  :-P
20:41 Eevee pmichaud++
20:41 Topic for #parrotis now Devel: 0.6.1 | http://parrotcode.org/ | 17/673 new/open tix
20:42 pmichaud is there an easy query to see how many tickets I've closed today / this week ?
20:45 bacek good morning
20:45 * purl whips out a machete.  I'm *tired* of your shit bacek
20:46 Eevee maybe purl should switch to decaf
20:46 pmichaud lol
20:46 bacek :)
20:47 japhb "Now I see just how easy it is to accidently cut someone in half with a machete."
20:47 bacek pmichaud, what about closig 53666 and 54312?
20:48 * bacek have initial implementation of 'sort', but it depends on 'cmp' in parrot...
20:50 cognominal pmichaud, sorry, I am better at opening ticket than at closing them
20:51 pmichaud cognominal: tis okay, I'm more looking at the parrot tickets than the perl6/rakudo ones :-)
20:51 Eevee perl6 only has 23
20:51 Eevee (it must be almost finished!)
20:51 * bacek voting for fixing cmp!
20:52 pmichaud is there a ticket for cmp yet?
20:53 dalek r27652 | pmichaud++ | trunk:
20:53 dalek : [rakudo]:
20:53 dalek : * Add implementation of .kv for hashes.
20:53 dalek : * Patch courtesy Vasily Chekalkin <bacek at bacek.com>    bacek++
20:53 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27652
20:53 bacek pmichaud, don't know. I'm not sure about original cmp beahvior in parrot...
20:54 bacek thanks fo 53666 :)
20:55 bacek http://nopaste.snit.ch/13010
20:55 bacek Is expected result should be (-1, 1)?
20:56 japhb pmichaud: Does Rakudo have .kv for arrays?
20:56 pmichaud japhb:  not as far as I know
20:56 bacek japhb, yes
20:56 japhb I was just wanting that today in some Perl 5 code
20:56 pmichaud general warning:  be careful about adding too many methods to existing classes, as the whole structure of objects may be changing soon.
20:57 pmichaud s/may be/is very likely to be/
20:57 pmichaud and based on that, I'm going to wait on the Pair patch.
20:57 * japhb watches as motherboard tries to overclock itself (without my request), fails miserably, admits defeat
20:57 bacek pmichaud, ok
20:57 pmichaud does "admit defeat" imply "emits smoke"?
20:58 japhb pmichaud: nope.  Reboots to warning that says "Warning: previous overclocking FAILED.  Reverting to normal mode."
20:58 Eevee pmichaud: I notice there's a ticket for rewriting builtins in Perl 6 when possible anyway
20:58 pmichaud eevee:  yes.
20:58 jonathan pmichaud: what will change about adding methods to existing classes?
20:58 pmichaud in some cases the class names
20:59 jonathan Ah, OK.
20:59 jhorwitz pmichaud:the elements method of the lexpad PMC returns the hash size of the associated lexinfo PMC.
20:59 Eevee pmichaud: would it be possible to do that for syntactic sugar too?  e.g. implement the reduction metaoperator with perl6
20:59 pmichaud also, creating objects should generally be done with   Class.new(...)   instead of $P0 = new 'Class'
20:59 bacek pmichaud, is this syntax already works?
20:59 pmichaud jhorwitz: okay, but   $P0['lexpad'] isn't returning a lexinfo PMC, is it?  isn't it something like an array of lexinfos?
21:00 jhorwitz checking...
21:00 pmichaud reduction syntax doesn't work yet -- that's going to require some substantial grammar and pge changes
21:00 pmichaud that's why it's farther down the list on the roadmap
21:01 jhorwitz pmichaud: typeof returns 'LexPad'
21:01 pmichaud ah, okay, it returns a LexPad and not a LexInfo
21:01 pmichaud interesting.  hrm.
21:03 Eevee pmichaud: I know it doesn't work; just wondering about how it could be written
21:03 pmichaud oh
21:03 pmichaud you mean the part about calling .reduce ?
21:04 NotFound Estoy mirando #52222 que se queja de un segfault, y el código que lo produce dice: "Tries to crash parrot."
21:04 dalek r27653 | fperrad++ | trunk:
21:04 dalek : [Lua]
21:04 dalek : - bytecode translation : fix initialization of local
21:04 dalek diff: http://www.parrotvm.org/svn​/parrot/revision?rev=27653
21:04 pmichaud jhorwitz: maybe exists?
21:04 NotFound Uh, sorry.
21:04 Eevee yeah; save for actually recognizing the syntax (I don't think there's a metaprecircumfix), it could be written entirely in a few lines of perl 6
21:05 pmichaud from STD.pm: regex prefix_circumfix_meta_operator:reduce {
21:05 pmichaud and the action method will be
21:05 pmichaud something like
21:05 purl something like what, pmichaud?
21:06 NotFound I'm looking #52222 "crashes with a bus error", but the code that fails says "Tries to crash parrot."
21:06 jonathan metaprecircumfix :-)
21:06 NotFound Crashing when you want to crash does not look like a bug to me ;)
21:07 NotFound Line 52 in src/dynoplibs/myops.ops
21:09 nopaste "pmichaud" at 76.183.97.54 pasted "general idea behind reduce handling" (5 lines) at http://nopaste.snit.ch/13017
21:09 pmichaud oops, get rid of "regex" in that (copy and paste error)
21:10 pmichaud but that's the general idea-ish -- basically we convert the reduce token into a method call with the list and infix operator as arguments.
21:11 bacek pmichaud, I've created ticket for cmp (54474)
21:11 * bacek voting for fixing 54474! :)
21:11 pmichaud bacek: thanks.
21:12 pmichaud okay, dinner smells really good so I had better to eat while there's still some left.
21:12 pmichaud bbiaw
21:12 moritz in rakudo's Makefile, why are not all subdirs of t/spec/ included in the test run?
21:12 moritz selection? or missing updates?
21:13 jonathan moritz: I think in part, just to include those we have a chance of passing at all.
21:13 jonathan No point running, say, any hyper ops ones just yet.
21:13 pmichaud correct.
21:13 moritz ok, I'll take a look what might be apropriate to add
21:13 pmichaud we select the ones that have a reasonable chance of being fixed in the relatively near future
21:14 pmichaud otherwise it's too difficult to see if a change "broke" anything because it gets swamped by all of the failing tests.
21:14 jonathan Please, let's not make the test output any "worse" than it currently is. Or was last time I checked it.
21:15 * moritz tests S12-{role,methods,attributes}
21:15 moritz they are relatively simple
21:15 jonathan Now, OO is indeed under-tested. :-)
21:15 jonathan That's one area where I think we do have more implemnted than tested.
21:15 moritz how do I regen rakudo's Makefile?
21:16 pmichaud "make Makefile"
21:16 purl "make Makefile" is what I'll be using :-)
21:16 pmichaud afk
21:18 NotFound Closed #52222
21:20 cognominal jonathan, this is very pedestrian but I would like a clean fix for http://rt.perl.org/rt3/Tic​ket/Display.html?id=52276
21:20 cognominal pmichaud noticed that my solution was unclean _and_ wrong
21:22 cognominal I understand you work on advanced stuff like roles but people expect basic perl5 like stuff to work
21:24 cjfields joined #parrot
21:29 DietCoke pmichaud: I can whip you up something, send me an email to remind me.
21:29 DietCoke (# of tickets closed by user in last N)
21:29 jonathan cognominal: pmichaud has noted on the ticket that there's some work to do in PCT to make this do-able more cleanly and it's happening soon; I'd rather hold off for that to be done.
21:30 jonathan And I do implement easy stuff too... ;-)
21:30 cognominal oh, how could one be mailed on its ticket is updated
21:30 cognominal jonathan: I know that you lift mountains
21:31 cognominal thx, pmichaud, I did not see the updating
21:33 NotFound pmichaud: I'm looking at #54384, the problem is that string_split has his arguments explictly marked as non null. Several pmc uses it, a change in his declaration can break things. Maybe adding other function to be used by the op will be the better solution?
21:34 DietCoke if you opened the ticket, you get certain updates on it.
21:34 DietCoke comments and other subtler changes are not sent back. Replies are, though, as are changes to resolved (or rejected).
21:35 NotFound And take into account that mails from rt can delay some time.
21:41 cognominal pmichaud++ # answer to #54448
21:46 dcat joined #parrot
21:52 pmichaud (#52276)  also, in order to get something like   my @a = (3) to work properly we will need to fix the parsing of infix:<=>.  In order for that to happen, I need to update the operator precedence parser in PGE.
21:53 pmichaud what makes (3) into a list isn't the parens but rather the fact that the thing on the right hand side of the '=' isn't a scalar.
21:53 jonathan Is it about as simple as, there's an @ there?
21:53 pmichaud more precisely, there isn't a "$" there
21:53 jonathan Ah, OK.
21:53 pmichaud but that means that infix:<=> has to be able to discover what the type of its lhs is
21:54 pmichaud and at present the operator precedence parser doesn't provide that sort of introspection
21:54 jonathan OK.
21:54 pmichaud (because $Larry changed the introspection semantics back to what I had originally written in the first place a long time ago, but only after I had update everything to use the new semantics :-| )
21:55 jonathan :-(
21:57 pmichaud thus   $a = 3, $b = 4   parses as ($a = 3), ($b = 4),   whereas   @a = 3, 4, 5   parses as   @a = (3, 4, 5)   and not   (@a = 3), 4, 5
21:58 jonathan *nod*
21:59 braceta joined #parrot
21:59 pmichaud so infix:<=> is an operator that has two levels of precedence.  :-)
22:02 pmichaud (and this is what makes list context a challenge :-)
22:02 pmichaud anyway, it's in my constellation of things to fix
22:02 * jonathan doesn't even dare ask about return
22:02 pmichaud heh
22:03 pmichaud return is (I think) a bit simpler, but I'm more concerned with getting this other stuff out of the way.  Also, I expect allison to be pushing the exceptions branch into trunk soon, so it may be worth waiting for that.
22:05 nopaste "cognominal" at 82.67.232.89 pasted "is there a cleaner way? in an actions.pm" (13 lines) at http://nopaste.snit.ch/13018
22:05 cognominal at least, it works
22:08 pmichaud cognominal: what do you need chars() for?
22:08 cognominal I need to write an escHTML
22:09 pmichaud you mean  like &#nnnn; ?
22:09 cognominal basically I am writing a beautifier for PGE stuff
22:09 pmichaud (what's an "escHTML"?)
22:09 cognominal so I need to escape stuff to entities
22:09 pmichaud ah.
22:10 cognominal it works, I just want to now if I choose the least convoluted way
22:10 pmichaud it's pretty close to least convoluted.  :-)
22:10 Eevee that is a lot of assigning
22:10 moritz did you look at NQPs or rakudo's substr implementation? You might be able to reuse parts of it
22:11 pmichaud easier might be to add a '.chars' method to the String class.
22:11 pmichaud then it's just  $s.chars()  in NQP  :-)
22:11 pmichaud jhorwitz: ping
22:11 cognominal in fact I stole code from the Str class and NQPfied it
22:12 cognominal anyway I learnt a new skill
22:23 davidfetter joined #parrot
22:26 teknomunk joined #parrot
22:28 jhorwitz pmichaud: running out for a few.  :(
22:32 pmichaud jhorwitz: when you come back -- if accessing the lexpad is throwing an exception, can you simply trap it?
22:36 nopaste "pmichaud" at 76.183.97.54 pasted "suggestion for jhorwitz" (18 lines) at http://nopaste.snit.ch/13019
22:41 jonathan pmichaud: Is doing this right really just a case of context scope being implemented?
22:42 pmichaud jonathan: I think so, yes.
22:42 pmichaud it might need another piece, such as mutables.
22:42 jonathan Hmm. I doubt that's excessively hard.
22:42 pmichaud scope?
22:42 purl scope is same.
22:42 jonathan (context scope, not mutables)
22:42 jonathan :-P
22:42 pmichaud it's not too bad, no.
22:43 pmichaud but we still have to have the PGE modifications to be able to introspect infix:<=>
22:43 pmichaud otherwise we can't decide what scope to use
22:43 pmichaud and trying to fix up the parse afterwards is probably fraught with difficulty.
22:43 jonathan Oh, I thoght we were on the $/ problems?
22:43 pmichaud oh, sorry
22:43 pmichaud wrong problem
22:44 pmichaud wrong notion of "context"
22:44 pmichaud you meant contextual variables.  :-)
22:44 jonathan ETOOMANYPROBLEMS
22:44 jonathan Yes!
22:44 pmichaud I still have to figure out the real semantics of $/, $_, and $?
22:44 jonathan OK.
22:45 pmichaud if you know them, then maybe you can explain them to me?  ;-)
22:45 jonathan I thought you'd mentioned before that they were contextual?
22:45 pmichaud istr that S04 says they're contextual, yes.
22:45 Eevee what is $/ now?  or is it the same as p5
22:45 pmichaud $/ is the result of a match
22:45 Eevee (punctuation variables)--
22:45 jonathan There's not many of them in Perl 6.
22:46 pmichaud here are my basic questions.
22:46 pmichaud (1) does every block get its own lexical $_ ?
22:47 pmichaud I'm pretty sure answer here is 'yes'.
22:47 jonathan If the answers "yes", how is it a contextual variable?
22:47 pmichaud where is it initially bound?
22:48 pmichaud for a pointy sub, it's bound to the first argument
22:48 pmichaud for an immediate block, ... ?
22:48 jonathan My understanding is that some things bind it. Like pointy sub, given block, etc
22:48 jonathan For others, it's just contextual.
22:49 jonathan lookup of a Contextual = find the most shallow thing in the dynamic scope that is a context var of that name, I thought?
22:49 pmichaud right
22:49 pmichaud so, if
22:49 pmichaud my $foo = { say $_ };
22:49 pmichaud and then later
22:49 pmichaud given ($x) {  $foo();  }
22:50 pmichaud the value of $_ in foo is contextual ($x) and not lexical as of the point when the closure was taken
22:50 pmichaud does that sound right?
22:51 jonathan I think it's right in so far as, that's the logical conclusion of it being contextual.
22:51 pmichaud it think it's also right in so far as what we expect to have happen
22:51 jonathan So long as you're aware that $_ is contextual, of course.
22:51 pmichaud the difference being that something like
22:52 pmichaud my $x = 'x';   my $foo = { say $x; };
22:52 pmichaud my $y = 'y';
22:52 pmichaud given ($y) -> $x {   $foo();  }
22:52 cognominal pmichaud++
22:53 jonathan OK, that should give x
22:53 pmichaud right.
22:53 pmichaud because $x is lexically taken at the point of the closure.
22:53 jonathan But my $+x = 'x'; my $foo = { say $+x; }
22:53 jonathan Is analogous to what $_ is.
22:53 pmichaud okay
22:53 jonathan Then youd'd get y
22:54 jonathan At least, that's the semantics of contextuals as I understand them.
22:54 jonathan I'm just putting "$_ is contextual" and how I believe context vars to work together.
22:54 Eevee interesting, didn't know you could actually declare dynamically-scoped variables with a + twigil
22:54 pmichaud yes, the + twigil means "look up the caller stack"
22:55 pmichaud okay, this is making a lot of sense to me
22:55 pmichaud so
22:55 jonathan Just found the S02 chunk
22:55 pmichaud given ($x) { ... }     creates a new lexical $_
22:55 jonathan $_, $! and $/ are always contextual.
22:56 jonathan Yes.
22:56 jonathan Which "is context"
22:56 pmichaud and any time we use $_, we just look up the context stack (including the current caller)
22:56 pmichaud er, (current sub)
22:56 pmichaud so yes, we just need :scope('context')
22:56 jonathan Also note
22:56 jonathan The CALLER package refers to the lexical scope of the (dynamically scoped) caller. The caller's lexical scope is allowed to hide any variable except $_ from you. In fact, that's the default, and a lexical variable must have the trait "is context" to be visible via CALLER.
22:57 pmichaud yes, I knew that part.
22:57 pmichaud my plan was to include the + as part of the variable name
22:57 jonathan Yeah, I'd forgotten it.
22:57 pmichaud that might not work, though
22:57 pmichaud actually, it won't.
22:57 NotFound pmichaud: can you take a quick look at #54384?
22:58 jonathan What I also like is, "Any lexical declared with the is context trait is by default considered readonly outside the current lexical scope. You may add a trait argument of <rw> to allow called routines to modify your value."
22:58 pmichaud but the real way it'll be handled is as a property/trait on the mutable, and then we'll adjust :scope('caller') to skip those variables that aren't contextual.
22:58 jonathan Right, we'll just put the "context" traint on it.
22:58 jonathan my $+foo to me is just shorthand for my $foo is context
22:58 pmichaud yup, me too.
22:59 pmichaud NotFound: looking.
22:59 jonathan The trick here is getting PCT to do this in a language-independent way.
22:59 pmichaud NotFound: I'm not the one who can evaluate this particular patch, sorry.
23:00 jonathan The nice thing about the "only contexts are visible" and "readonly by default" is that I think it makes us able to do some optimizations I'd not previously thought possible.
23:00 jonathan I thought everything, not just is context, was visible through CALLER, which hoses a lot.
23:00 pmichaud well, I was going to have PCT ignore context traits -- i.e., its default is to assume all variables are contextual
23:00 NotFound pmichaud: I mean if the solution of returning a null pmc will be adequate.
23:01 jonathan Yeah, but then you have to have a way to tell it "no, that's not good, go searching again"
23:01 pmichaud or supply it with an alternate search algorithm.
23:01 jonathan Yeah, that'd work.
23:01 pmichaud that's what I was thinking of.
23:01 jonathan Just some predicate function
23:01 jonathan "I found this, is it context enough for you?"
23:01 TimToady To me, my $+x is bogus, because it means I'm trying to declare a variable in my caller's scope
23:02 pmichaud i.e., PCT provides a default "contextual" function that the :scope('context') node uses to locate the desired variable
23:02 TimToady and we need to be able to say my $x is context = $+x
23:02 pmichaud but individual languages can replace that with a call to something else
23:02 TimToady which doesn't work with my $+x = $+x
23:02 TimToady + is supposed to mean "CALLER::"
23:02 pmichaud TimToady: yes, we got you :-)
23:02 jonathan Ah.
23:03 TimToady on $foo = { say $_ }
23:03 jonathan OK, small matter of syntax and semantics. :-)
23:03 pmichaud jonathan: you're correct that I hadn't considered that having "only contexts are visible" makes for a lot more optimization possibilities.
23:03 pmichaud I can get rid of a lot of fetches.
23:03 TimToady that has an implicit argument of -> $_ = OUTER::<$_>
23:03 TimToady not CALLER
23:03 jonathan OK, how do we know which blocks have that?
23:04 TimToady you can't just go looking up the stack for the caller's $_
23:04 TimToady not unless they say $+_
23:04 pmichaud TimToady: ah, excellent.  that makes sense.
23:04 TimToady likewise for $+/ and $+!
23:04 pmichaud yes.
23:04 pmichaud beautiful.
23:05 purl beautiful is a love thing
23:05 jonathan if ($foo { ... } # does this block have an implicit $_ = OUTER::<$_>?
23:05 pmichaud how about for something like      if $x { ......... jonathan got it :-)
23:05 pmichaud in the case of if, that's more of an "immediate block"
23:06 TimToady if doesn't pass the parameter unless it sees a real -> syntactically, I supppose
23:06 pmichaud inside of if ($foo) { say $_; }
23:07 TimToady if $x {...} and if $x -> $_ {...} do different things
23:07 pmichaud right.
23:07 pmichaud in the first case, does the block have its own lexical $_ ?
23:07 TimToady and the presence of $_ is not enough to force "I must have a parameter"
23:07 TimToady whereas $^a is
23:08 TimToady so I guess maybe if just pays attention to minimum arity
23:08 TimToady which is 0 when $_ has a default
23:09 TimToady arguably for should try to bind maximally though
23:09 pmichaud so, for $/ and $!, those are effectively   -> $_ = OUTER::<$_> { my $! = OUTER::<$!>;  my $/ = OUTER::<$/>; ....   }    ???
23:10 TimToady seems about right
23:10 TimToady you want the lexical scope or undefined
23:10 pmichaud okay.
23:11 pmichaud so, what is S02 trying to get at when it says that $_, $!, and $/ are always contextual?
23:11 TimToady just that they're always visible to a sub
23:12 TimToady not that $+ will get you anywhere further than the next caller out
23:12 pmichaud oh, so they're always  "is context"
23:12 TimToady in fact, is context<rw>
23:12 pmichaud got it.
23:12 TimToady so fail can set the caller's $!, for instance
23:12 TimToady and a match can set the caller's $/
23:13 pmichaud yes.
23:13 pmichaud beautiful.  TimToady++
23:13 jonathan Suddenly, it all makes sense. :-)
23:13 pmichaud and we don't need :scope('context') just yet.
23:14 * jonathan tweaks his mental model of Perl 6.
23:14 pmichaud my mental models have been in overdrive this past week.
23:14 pmichaud I don't know what I did, ate, or otherwise happened to cause all of this to start falling into place.
23:16 pmichaud and in the case of something like   my $! = OUTER::<$!>;   above.... those are actually assignments and not binding
23:16 pmichaud i.e., changing $! doesn't change OUTER::<$!>
23:16 pmichaud so our prologue code effectively becomes
23:17 pmichaud $P0 = find_lex '$_'
23:17 pmichaud if null $P0 goto skiplabel
23:17 pmichaud $P0 = clone $P0
23:17 pmichaud .lex '$_', $P0
23:17 pmichaud skiplabel:
23:18 pmichaud oops, I should've used $! there.  $_ is more special.
23:19 pmichaud (i.e., it depends on whether the block is taking arguments)
23:19 jonathan Sure.
23:19 jonathan Or $/
23:20 jonathan OK, I fix that up on Wednesday if I'm not beaten to it, and try and get $_ right too.
23:20 pmichaud oh, here's some scheduling infor
23:20 pmichaud *info
23:21 pmichaud tonight I have to finish my grading.  shouldn't take long.
23:21 pmichaud Any hacking I do tomorrow (rakudo, pct, pge) is going to be in a branch so as not to interfere with a release.
23:21 pmichaud as soon as the release is cut, and presuming what I've hacked doesn't break too many things, I'll roll it into trunk late tuesday or early wednesday morning.
23:22 pmichaud but the things I'm looking to do in the branch include
23:22 pmichaud add :pasttype('list')  (for infix:,)
23:22 pmichaud convert rakudo to use the new P6object implementation
23:22 purl I don't know how to convert rakudo to use the new P6object implementation.
23:22 pmichaud that's okay purl, we know you're not perfect.
23:23 pmichaud convert pct and pge to use the new P6object implementation
23:23 purl I don't know how to convert pct and pge to use the new P6object implementation.
23:23 pmichaud and I suspect I won't get much farther than that before rolling back into trunk.
23:23 pmichaud (or that I'll get all of those done-- those are just what are on my high list)
23:23 jonathan OK
23:23 pmichaud then I'll have a major pge refactor branch starting on wednesday
23:24 jonathan For the proto-regex?
23:24 pmichaud but by wednesday I'm hoping to have rakudo on the new object model
23:24 jonathan OK, sounds good.
23:24 jonathan I'll be on hand to help with that.
23:24 pmichaud ("speakers so loud...")
23:24 TimToady one other note, $_ $! $/ are always null at a Routine start; they don't clone their outer lexical scope for those vars
23:25 TimToady just Block start that clones outer
23:25 pmichaud well, $_ might be bound to something
23:25 cognominal g'night
23:25 jonathan TimToady: Do we still have the, invocant goes in $_ for methods?
23:25 TimToady I think the $_ of file scope shouldn't leak into subs ordinarily
23:25 TimToady no, haven't had that for years
23:26 jonathan OK.
23:26 jonathan :-)
23:26 jonathan I remember the long, drawn out thread, but forgot the conclusions. :-)
23:26 TimToady method foo ($_: ...) is easy enough
23:26 * jonathan adds it to list of things to make sure work
23:26 pmichaud anyway, the note about $_, $!, $/ null at routine start is also useful.
23:27 jonathan Yes.
23:27 jonathan And all makes good sense, from a sanity point of view.
23:35 jonathan TimToady: You said "+ is supposed to mean "CALLER::"", but S02 says "Use of $+FOO is equivalent to CONTEXT::<$FOO> or $CONTEXT::FOO."
23:45 jonathan Argh, dilema. Sleep or slide writing & beer.
23:46 jonathan It's sleep time, but I don't feel sleepy... :-S
23:56 * jonathan is sensible for once and sleeps
23:56 jonathan night all
23:59 bacek_ joined #parrot
23:59 TimToady yes, it's really CONTEXT, but there's never any difference for vars that are always in CALLER

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

Parrot | source cross referenced