|
6macros: discussing the finer points of Perl 6 macros, Qtrees, and how to stay sane | irclog: irclog.perlgeek.de/6macros/today Set by moderator on 28 July 2015. |
|||
|
02:48
ilbot3 joined
07:54
pdcawley joined
08:26
vendethiel joined
08:55
pdcawley joined
09:16
FROGGS joined
|
|||
| masak | vendethiel: at some point, I'd love to discuss 007 and `is parsed` a little. at your convenience, of course. | 09:23 | |
| vendethiel | *searchs for a coffee mug* | ||
| masak looks furtively around; ducks | 09:24 | ||
| vendethiel | no coffee for me then ;-). | 09:25 | |
| masak | no no, go ahead | ||
| vendethiel | i'm not doing anything special at the moment, so fire at will (or wall). | ||
| masak | I'm just being silly | ||
| :P | |||
| vendethiel | (I don't have any coffee anymore.. :(.) | 09:26 | |
| masak | ok, my question is "what's the next step?", basically | ||
| vendethiel | the two issues we have for regexes and is parsed? | ||
| masak | looks like it's either #174 (regexes) or #177 (`is parsed`) | 09:27 | |
| both of them are marked up as `currently-looking-for-pr` | |||
| a very nice label :) | |||
| warmly yellow on the page | |||
| #174 is looking for the simplest-possible-way to parse <EXPR>, which would indeed be a big win to have | 09:28 | ||
| and would raise a lot of important questions to the forefront | |||
| for example "how is it that <EXPR> is available in an `is parsed` expression?" | |||
| what's the exact link between `is parsed` and the currently in effect grammar? | |||
| vendethiel | both good questions | 09:30 | |
| I was thinking about catch-all, that'd look at the extra rules in place, and parse with that | |||
| (in each grammar category) | 09:31 | ||
| masak | #177 is looking for using `is parsed` with just a constant-string regex on a statement macro. in a way, we'll get #80 for free if we do that. | ||
| yes, catch-all sounds fine, at least at first | |||
| in the fullness of time we'll probably want everything to go in with the same mechanism | |||
| (that's the trend with other similar features in 007) | 09:32 | ||
| vendethiel | aye | ||
| masak | oh, speaking of which | ||
| in implementing `class`, I'm feeling that the current implementation of Val:: and Q:: classes is reaching its limits | |||
| I'm thinking of throwing it out and replacing it with something better | |||
| basically, whenever we declare a `class` or `role` currently in Perl 6 (for some 007 type), we'd do a method call .register-type or something instead | 09:33 | ||
| the idea being just that, to put everything at the same level, and make user-defined types just as real as 007-defined types | |||
| (it's another example of "lifting", the act of putting more and more stuff in 007 itself rather than in Perl 6) | 09:34 | ||
| vendethiel | meta machinery | ||
| masak | right | 09:35 | |
| it's also a chance to actually reify and expose the places where the snake will eat its own tail | 09:36 | ||
| things such as "Type is a subtype of Object" but "type(Object) is Type" | |||
| vendethiel: did I tell you the fun thing that happened with builtins in runtime.007? | 09:38 | ||
| vendethiel | not sure | ||
| masak | so, I had this "great idea" about getting rid of Val::Sub::Builtin, which was a hack | 09:39 | |
| instead, builtins became normal Val::Sub objects, but with a &.hook which contained the Perl 6 code to be run | |||
| and the .call method in Runtime.pm knew to look for the &.hook and run the Perl 6 code | 09:40 | ||
| if $c.hook -> &hook { return &hook(|@arguments) || NONE; } | |||
| now -- cue reality ensuing -- none of the built-ins do a thing in runtime.007 | |||
| *because* that mechanism is not something we can emulate in pure 007 code | 09:41 | ||
| cheat successfully here, get punished for it there. waterbed design in action. | |||
| vendethiel | huh? | 09:47 | |
| masak | runtime.007 has a sub `call(fn, args)` | 09:54 | |
| whose implementation is "bind signature, run statementlist" | 09:55 | ||
| but the statementlist of a built-in with a Perl 6 implementation is *empty*, because the code is all Perl 6, not Q::Statement nodes | |||
| so nothing runs | 09:56 | ||
| vendethiel | ah, of course | 09:57 | |
| masak | and there's no way for the 007 code to check for &.hook, because the point of it was to not be exposed in 007 userland. d'oh | ||
| I was really pleased with &.hook until I realized this | 10:01 | ||
| not quite sure how to solve it, either | |||
| vendethiel: anyway, back to regexes and `is parsed` -- are you still eager to work on it? if so, can we perhaps plan a time to have a look at it all? | 13:01 | ||
| vendethiel | Not sure. I don't really code on my free time these days... A bit too tired when I get home | 16:01 | |
| masak | understandable. I have periods like that too. | 19:18 | |
|
19:26
vendethiel- joined
20:32
FROGGS joined
21:15
FROGGS joined
|
|||