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