»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'perl6: say 3;' or rakudo:, niecza:, std:, or /msg p6eval perl6: ... | irclog: irc.perl6.org/ | UTF-8 is our friend!
Set by sorear on 4 February 2011.
dalek ecza/non-bootstrap: 7d36f8c | sorear++ | lib/ (2 files):
First doodles on MiniParser
00:16
dalek rl6-bench: c7388f0 | (Geoffrey Broadwell)++ | bench:
Prepare to support multiple summary output formats; default (and only) format for now is 'text'
03:32
rl6-bench: 4ce8f19 | (Geoffrey Broadwell)++ | bench:
Allow style (e.g. color) to be forced off or on (or just DWIM); also some minor improvements to neighboring bits of main()
rl6-bench: 0cb18fd | (Geoffrey Broadwell)++ | bench:
Refactor summary output to generate output into string and print it all at once at the end
04:19
rl6-bench: 869b42b | (Geoffrey Broadwell)++ | bench:
Add html and html_snippet output formats
dalek rl6-bench: 03c3480 | (Geoffrey Broadwell)++ | bench:
Add json output format
04:51
moritz \o 05:24
sorear o/ 05:25
adu \/ 05:44
oo 05:45
╰╯ 05:47
tadzik `' 05:54
adu :) 06:04
.u ╰ 06:05
phenny U+2570 BOX DRAWINGS LIGHT ARC UP AND RIGHT (╰)
adu .u ╯
phenny U+256F BOX DRAWINGS LIGHT ARC UP AND LEFT (╯)
dalek ecza/non-bootstrap: 146fa60 | sorear++ | lib/ (3 files):
A few more fiddles to MiniParser, parse comments and grammar decls
06:11
sorear sleep& 07:29
dalek ecza/non-bootstrap: 70f727e | sorear++ | lib/Actions.cs:
translate Actions, part 1
sergot hi o/ 09:16
crab2313 sergot: hi
moritz \o 09:19
kresike hello all you happy perl6 people 09:50
moritz hello kresike. What about the unhappy perl6 people? :-)
kresike hello moritz o/ 09:51
don't think there are any :)
eiro hello there 09:52
moritz, is fpw12 tag alive ?
cognominal said it's sad to not wait for a week and have more features at fpw ... i have to admit i'm scarred about it 09:53
moritz eiro: oh, I forgot to push that one
doing that now
eiro moritz, don't :)
moritz dang
eiro i don't know how smart it is to wait for a week for example
(as cognominal said)
moritz the problem is that you'd always have to wait for another week 09:54
I don't expect we'll stop to work on rakudo soon :-)
oh, the push failed 09:55
eiro haha ... right :)
moritz eiro: so, what should I do? tag current HEAD and push the tag? 09:56
eiro: or tag the revision we discussed the other day?
if I were you, I'd want the current HEAD tagged, and then work with that 09:59
eiro hmm ... 10:03
moritz, i expect a version as stable as possible (in terms of features) so please feel free to tag any comit -past,present,future- you feel as a good choice 10:04
moritz eiro: ok. fpw2012 aka github.com/rakudo/rakudo/zipball/fpw2012 at your disposal 10:06
eiro \o/ thanks a lo moritz
moritz thing is, any version is as stable as another unless we have known regressions or known work-in-progress 10:07
eiro ok 10:09
moritz and I merged a branch yesterday, but it was fairly small-scale and not likely to have caused any trouble 10:13
felher nr: class C { }; my C $c1 .= new; $c1 does anon role { method get-self() { $c1 } } ; say $c1.defined; say $c1.get-self.defined; say $c1 === $c1.get-self; 11:07
p6eval niecza v18-6-ge52d6c3: OUTPUT«True␤True␤True␤»
..rakudo eef772: OUTPUT«True␤False␤False␤»
felher I guess niecza is right about that?
Maybe that the role-problem with lexicals moritz mentioned yestderday? 11:08
felher *that's *yesterday 11:13
moritz probably 11:22
ynot perl6: say <1 2> >>+<< <3 4> >>+<< <5 6> 11:51
p6eval rakudo eef772, niecza v18-6-ge52d6c3: OUTPUT«9 12␤»
..pugs: OUTPUT«912␤»
ynot perl6: say [>>+<<] <1 2>, <3 4>, <5 6> 11:52
p6eval pugs: OUTPUT«*** Hyper OP only works on lists␤ at /tmp/MYDvAW_jmb line 1, column 5 - line 2, column 1␤»
..rakudo eef772: OUTPUT«Nominal type check failed for parameter '$op'; expected Any but got Mu instead␤ in sub METAOP_REDUCE at src/gen/CORE.setting:11538␤ in block <anon> at /tmp/CDHqsxlOPQ:1␤␤»
..niecza v18-6-ge52d6c3: OUTPUT«21␤»
ynot perl6: say [>>+<<] (<1 2>, <3 4>, <5 6>) 11:53
p6eval pugs: OUTPUT«*** Hyper OP only works on lists␤ at /tmp/5TwH3T0Q5u line 1, column 5 - line 2, column 1␤»
..rakudo eef772: OUTPUT«Nominal type check failed for parameter '$op'; expected Any but got Mu instead␤ in sub METAOP_REDUCE at src/gen/CORE.setting:11538␤ in block <anon> at /tmp/pBeTt5uo50:1␤␤»
..niecza v18-6-ge52d6c3: OUTPUT«21␤»
sdo_ hello 12:34
I have to write something about perl 6 culture. Do you know where I can start? 12:35
thank you very much
PerlJam sdo_: greetings. 12:38
fglock sdo_: maybe www.perlfoundation.org/perl6/index...._the_onion
sdo_ hi
PerlJam sdo_: You could hang out here for a while and observe
sdo_: you could read perl6.org and make some inferences 12:39
sdo_ thank you PerlJam
PerlJam sdo_: Also, read jnthn's blog, moritz's blog, masak's blog and pmichaud's blog 12:40
:-)
sdo_ :-)
perlcabal.org/syn/ is it ok? 12:43
;-)
a lot of reading heuuuuuuuuu 12:44
PerlJam sdo_: why do you "have to write something"?
sdo_ It is foe fpw2012 12:45
It is for fpw2012
sdo_ I am not sur yet because I just received it and I don't want to make mistakes in what I'll say 12:46
s!sur!sure!
PerlJam sdo_: you can vet anything you want to say with the people of #perl6 12:47
sdo_ I am kinda rooky with perl 6 so .... 12:48
sdo_ ok i'll take care and i'll do carefully but slowly 12:51
thanks a lot guys
daxim sdo_, irclog.perlgeek.de/perl6/2012-06-01#i_5667075 12:52
for the historical aspect 12:53
sdo_ see u later aligator 12:59
pmichaud good morning, #perl6 14:41
tadzik hello pm 14:43
felher o/ pm 14:47
eiro hello 14:58
felher o/ 14:59
kresike bye all 15:29
moritz back 15:30
brrt hi moritz 15:33
moritz \o brrt 15:34
jnthn Good evening o/ 15:39
diakopter o/ 15:40
TimToady reports in from Madison
diakopter wishes it weren't sold out
pmichaud hello, TimToady! I'll be there tomorrow afternoon 15:48
moritz removes outdated rakudo branches 'require' and 'altnfa' 15:55
pmichaud \o/
branch pruning +1
moritz it seems the remaining branches potentially have some merit
lazy-subst and nil-assign are quire recent 15:56
*quite
alpha and ng are there for hysterical raisins
priv-role-attrs requires some design work iirc (jnthn++ was working on that one in March)
sink, sink2, staged-settings and parameter-perl were mine, I'm not yet willing to abandon them completely 15:57
jnthn The sink work never made it in, though? 15:58
moritz native-str-ops causes segfaults, which should be tracked down at some point
jnthn: no
jnthn: I gave up after not being able to debug/print out the PAST structures in a convenient way
and all my attempts to do without ran into brick walls
pmichaud sink might be re-addressible with the new iterator stuff in place. 15:59
*addressable
moritz pmichaud: the iterators weren't the problem
pmichaud: I managed to add a 'sink' method to class List just fine (though without much performance gain)
pmichaud: the problem was to determine which statements to sink
pmichaud iirc, rule statementlist should sink its statements 16:00
unless the statement is an assignment, in which case it has to be protected from sinkage 16:01
(oh, and the last statement isn't sunk, since it's the return value for the statement list)
moritz except if the statementlist itself is in sink context 16:02
and binding shouldn't be sunk either 16:03
pmichaud at one point we had speculated that operators would be tagged as to whether or not they should be sunk 16:03
or, more generally, operator precedence levels
moritz iirc after thinking more about it, I concluded that only PAST::Op call or callmethod needed to be sunk 16:04
s/or/and/
pmichaud that feels odd-ish.
TimToady op prec doesn't feel right to me
pmichaud well, specifically the %item_assignment and %list_assignment levels 16:05
TimToady => is at assignment level
but should likely get "Useless use of => in sink context" 16:06
moritz that's fine, pairs don't need to be sunk
TimToady anything useless in sink context should be sunk :)
moritz at least not for list iteration stuff
pmichaud => doesn't seem to be an operator -- it's a term 16:07
its rhs is at %item_assignment, yes.
TimToady in STD: token infix:sym« => » { <sym> <O(|%item_assignment, fiddly => 0)> } 16:09
pmichaud ah, I didn't search for the space
maybe just list_assignment needs protection, then. We don't want to sink @a = ..... 16:10
pmichaud 16:02 <moritz> except if the statementlist itself is in sink context 16:11
moritz might not be necessary 16:12
pmichaud I'm not sure that's an issue; if the statementlist is itself in sink context then its "caller" will sink it appropriately.
TimToady @a X[+=] @b
moritz if we just .sink the return value
Guest65939 Hey, I just wanted to drop in and say "congrats". I grabbed Rakudo Star from May and tried to do a quick parser proof of concept project with it. It worked flawlessly, using the JSON library as a guide.
pmichaud Guest65939: thanks! That's awesome to hear!
jnthn Nice! :)
pmichaud we're hoping June will be even nicer :-) 16:13
jnthn June's will parse faster for anything with protoregexes, I suspect.
May's shipped with the NQP implementation of the NFA runner.
jnthn (While June gets the C one.) 16:14
moritz it seems that JSON parsing has the right mixture of simplicity, size and real-worldness 16:15
harmil (ajs here) … man, I never quite got the hang of IRC
anyway, yeah, nice and smooth.
moritz I blatantly stole the idea of using JSON from "Real World Haskell" 16:16
harmil Only problem with JSON as a model was that it has no operator precedence concerns. My prototype didn't either, but now I'm trying to do a next pass, and re-remembering that all of PGE's nice optable stuff isn't yet available in rules. 16:16
spider-mario I like reading YAML better, to be honest
but JSON is easier to parse.
moritz spider-mario: well yes, I'm speaking about the implementation side, not the usability side :-) 16:17
TimToady "The question is who's to be master, that's all." --Humpty Dumpty
pmichaud niecza handles precedence fiddling, iirc. 16:18
I wonder what it would take to fold that back into Rakudo, though.
spider-mario <TimToady> @a X[+=] @b 16:19
isn’t that @a »=» [+] @b
?
harmil Hmm… perhaps I need to look into moving this project to Niecza, then. I really hate to have to build precedence rules manually. 16:19
TimToady well, yes, but the point is that the precedence is not list assignment
jnthn I'm not sure Niecza exposes EXPR to user-space either.
spider-mario ok, sorry 16:20
moritz harmil: does niecza expose the OPP to user space?
harmil not sure
TimToady the point of sink context is to compel evaluation of a side effect
pmichaud oh, there is that too.
(no OPP to user space)
TimToady "say" is a side effect
moritz TimToady: which is why it returns something that's fine to sink
moritz harmil: niecza allows custom precedence level for operators in Perl 6 code 16:21
harmil: maybe you're mixing up the two
pmichaud or maybe I mixed them up. 16:21
moritz sorear will know :-)
pmichaud I forgot that PGE basically provided EXPR services on arbitrary grammars
TimToady moritz: but it's not always something fine to sink, if it wasn't a side effect, hence "Useless use of" 16:22
pmichaud including operator precedence. we don't have an equivalent in p6, except for p6's grammar
TimToady we talked more than once about generalizing STD's EXPR, but hasn't happened yet...
harmil moritz, someone just mentioned it might have better handling, but yeah, that's what I might expect. I guess I'll have to write out the precedence levels longhand. Cumbersome and annoying, but hey, I got a pony, I won't complain that its tail isn't long enough ;) 16:23
moritz harmil: or write an operator precedence parser as a reusable module
harmil: publish it, and everybody will be happy
pmichaud yes, I was just thinking that we ought to have a reusable module for that
harmil moritz: I think you over-estimate the size of my tuits ;-)
pmichaud I might be able to publish one. 16:24
moritz TimToady: I was talking about say(), not the X[+=] case
TimToady as I recall, there were only five or six bits of EXPR that were P6-specific
and they have comments
yes, they're labeled # XXX P6
pmichaud porting STD's EXPR to a reusable rakudo module would be a good exercise to figure out what we're going to want to redo in NQP's EXPR equivalent 16:25
since NQP currently cheats in ways that are wrong 16:26
afk, lunch 16:29
moritz wants LEAVE blocks in NQP 16:56
TimToady wants all of Perl 6 in NQP :) 16:59
betterwo1ld shouldn't it be called QP then? 17:01
moritz it would
diakopter Perl Indeed
geekosaur did someone just win the qp doll? 17:02
harmil I'd think it'd be NNQP 17:04
[Coke] MTNQP 17:05
sorear good * #perl6 17:13
felher wo/ 17:17
dalek ast: 4222fe5 | moritz++ | S11-modules/import.t:
rakudo unfudge
17:47
sorear o/ majrmovies 18:07
majrmovies o/ sorear! 18:08
Got version 1 of the Perl 6 WWW::Curl module working ..
Now I need to play with testing in Perl 6 and get it out to the world
daxim links against libcurl? 18:11
tadzik awesome 18:12
daxim github or I don't believe it 18:13
dalek kudo/module-trace: 1b00e64 | moritz++ | src/Perl6/ModuleLoader.pm:
note end of module loading in debug mode
18:25
kudo/module-trace: 339771a | moritz++ | src/ (2 files):
start to trace module loading in a dynamic variable
majrmovies daxim: yes, links agains libcurl 18:47
daxim: it is real! I will publish it as soon as I write some tests.
moritz ++majrmovies
harmil Is there anything about the Grammar/Actions model that JSON::Tiny uses that isn't considered "best practice"? I was thinking about blogging about that model of writing a parser in Perl 6, and didn't want to perpetuate anything that's considered non-standard. 18:49
Something for later tonight, so no rush. Let me know if you think of anything.
moritz harmil: I'm not aware of anything that violates "best practise" 18:50
dalek kudo/module-trace: b5d0d37 | moritz++ | src/ (2 files):
enable basic module traces in X::Comp
harmil Well, for example, it seems to be falling out that writing actions inline isn't.
At least for full-fledged parsers. Clearly for smaller tools, it might make sense. 18:51
moritz it's a question of modularity 18:52
harmil aye
moritz you have the option to provide different actions to the same grammar
if you keep them separate
though so far that's only a theory
TimToady otoh, it makes it harder to have a hierarchy of grammars
moritz I know of no Perl 6 grammar with multiple actions
and since both are tightly coupled, it's a bit weird to keep them separate 18:53
jnthn imho it's just good OO
Separation of responsibilities.
harmil Interesting… OK, I won't make strong statements about "the one way to do it" then ;-) 18:54
TimToady but it's kinda the forest of frogs problem
harmil And now I rat-hole into reading RFC 254 ;) 18:55
jnthn That's the kinda problem that drives use of dependency inversion. 18:58
TimToady nodnodnodnodnodoff & # one too many red-eyes
moritz gist.github.com/2911966 # that's what the module-trace branch does 19:00
and what I want it to do in the end
pmichaud I find separating actions and grammar useful because it keeps the "parsing" versus "do something" parts distinct
imagine if the contents of Actions.pm were somehow inlined into Grammar.pm, even for something as small as NQP
imo, it becomes a lot harder to read if they're integrated. 19:01
moritz well
the actions are hard to read without having the grammar open at the same time
pmichaud yes, they can be.
jnthn moritz: Nice progress :)
moritz I agree that the grammar is much easier to read without the actions
jnthn moritz++
jnthn is working on the endianness issue in NQP 19:02
pmichaud jnthn++
jnthn Though...I have no access to a box to try it out on.
So it's kinda coding blind :)
pmichaud jnthn: did you see dukeleto's suggestion of something on the gcc compile farm? 19:03
jnthn pmichaud: Ah, that could work, if I can be given access...
pmichaud let 19:04
let's see if I can push that a long a bit
*along
pmichaud jnthn: from dukeleto's email: gcc.gnu.org/wiki/CompileFarm 19:07
looks like you can apply for an account and then you're set :) 19:09
harmil I guess the reason that I always thought actions and grammar should be separate is because you might want to use the grammar for things that don't involve actions (e.g. validation). 19:11
pmichaud harmil: that's another reason, yes. 19:13
dalek p: b1226fb | jnthn++ | src/6model/serialization.c:
Try to unbust things on big endian platforms. Untested, but should do the trick.
19:19
PerlJam jnthn: We don't have to worry about middle-endian? (Does Parrot run on ARM?) 19:25
jnthn OMG WHY? 19:26
tadzik :)
I thought it does
arnsholt ARM is weird-endian?
jnthn I guess if people are crazy enough to think that writing dates as MM/DD/YY was a good idea, then yeah, I guess people can come up with middle endian too... :) 19:27
pmichaud tmtowtei 19:28
moritz jnthn: in ModuleLoader.pm, should the pir::set_hll_global__vsP('GLOBAL', $preserve_global); 19:31
... also go into a CATCH block?
moritz if we use a module, die in the progress and catch the exception, the GLOBAL might be messed up, no? 19:32
jnthn I...don't see how that could fail
Oh...
Yeah, you're right.
moritz ok, I'll do that in the branch
moritz really wants something that recursively p6izes types through arrays and hashes 19:35
moritz jnthn: one more thing; for the module trace I need to put the file name of the mainline onto the @*MODULES stack, but not when it's compiling a module. Where should I best put such code? 19:38
hm 19:39
otoh I also want to capture the line number where the module is being loaded
jnthn isn't sure he completely follows...
moritz jnthn: I want to run code when the mainline is being compiled, but not when a module is being compiled 19:40
well
jnthn moritz: Looking at if target is set can tell you that 19:41
If you mean pre-comp
moritz mis-phrased
I have a file foo.pl
which contains 'use A;'
moritz and I want to push 'foo.pl' onto a stack 19:41
but not A.pm when compiling A which was triggered by the 'use' 19:42
moritz never mind, I think I know a better approach which also solves the problem of the line numbers 19:42
jnthn OK :)
jnthn fixes an RT
dalek kudo/nom: 901f2a7 | jnthn++ | src/Perl6/Metamodel/MethodContainer.pm:
Fix duplicate method detection; don't boolify. Fixes the crappy error reporting for duplicate regex definitions in a grammar.
19:47
jnthn pmichaud: rt.perl.org/rt3/Ticket/Display.html?id=112716 may be fixed now? 19:55
pmichaud jnthn: looking
when I last checked, it wasn't fixed yet. 19:56
jnthn ah, oK
pmichaud There's still some eagerness in the system somewhere that I've got to find.
jnthn I thought the map fix mighta been enough
OK :)
pmichaud it might be the "eager" that is added to the for loop that is doing it.
pmichaud pulls latest to test. 19:57
dalek kudo/nom: b12854a | jnthn++ | src/Perl6/Actions.pm:
Make .foo behave the same way as $_.foo does with regard to perl6ization of types.
20:02
jnthn r: UNDO { say 'undone' }; die 'foo'
p6eval rakudo eef772: OUTPUT«undone␤»
jnthn r: do { UNDO say "undone"; die "foo" } 20:03
p6eval rakudo eef772: OUTPUT«foo␤ in block <anon> at /tmp/EV_WPFkBhp:1␤␤»
jnthn r: sub foo { UNDO say "undone"; fail }; foo; say "alive"
p6eval rakudo eef772: OUTPUT«undone␤alive␤»
pmichaud yes, it's the "eager" part that is causing the problem. I'll need to think about it a bit, but I suspect the fix is easy-ish. 20:13
*is now causing
moritz nqp: my @a := [1, 2, 3]; say @a[-1]; 20:58
p6eval nqp: OUTPUT«Confused at line 2, near "say @a[-1]"␤current instr.: 'nqp;HLL;Grammar;panic' pc 22074 (src/stage2/gen/NQPHLL.pir:8456) (src/stage2/gen/NQPHLL.pm:326)␤»
moritz nqp: my @a := [1, 2, 3]; say(@a[-1]);
p6eval nqp: OUTPUT«3␤»
dalek kudo/module-trace: f97e562 | moritz++ | src/Perl6/ModuleLoader.pm:
restore GLOBAL if module loading failed
21:04
kudo/module-trace: 3d9fa49 | moritz++ | src/Perl6/ (2 files):
pass the line number to the module loader
moritz how do I check if something is a parrot Hash? 21:44
(in nqp, that is)
jnthn pir::isa 21:45
pmichaud I don't mind if we introduce nqp::ishash, to correspond with nqp::islist (fwiw) 21:53
dalek kudo/module-trace: 22f512d | moritz++ | src/Perl6/ModuleLoader.pm:
add line numbers where module loading occurs
22:42
kudo/module-trace: 7812723 | moritz++ | src/ (3 files):
p6ize module trace in World and pass it to the exception

it almost works, but the hashes seem to get flattend out
moritz r: say [pir::perl6ize_type(nqp::hash()), pir::perl6ize_type(nqp::hash())].perl 22:45
p6eval rakudo b12854: OUTPUT«use of uninitialized value of type Mu in string context in any <anon> at src/gen/BOOTSTRAP.pm:104␤␤use of uninitialized value of type Mu in string context in any <anon> at src/gen/BOOTSTRAP.pm:104␤␤===SORRY!===␤error:imcc:The opcode 'perl6ize_type_p' (perl6ize_ty…
moritz r: say [pir::perl6ize_type__PP(nqp::hash()), pir::perl6ize_type__PP(nqp::hash())].perl 22:46
p6eval rakudo b12854: OUTPUT«[]␤»
dalek kudo/module-trace: d53986b | moritz++ | src/ (2 files):
itemize hashes in p6ize_recursive; remove debugging output

Now the output looks like I wanted it
22:54