»ö« | perl6.org/ | nopaste: paste.lisp.org/new/perl6 | evalbot usage: 'perl6: say 3;' or rakudo:, alpha:, pugs:, std:, or /msg p6eval perl6: ... | irclog: irc.pugscode.org/ | UTF-8 is our friend!
Set by lichtkind on 5 March 2010.
00:06 kensanata left
jnthn Hmm 00:13
75434 is a very wtf ticket.
00:14 pragma_ left, pragma_ joined 00:15 pragma_ left, pragma_ joined 00:16 whiteknight joined
patrickas oh! the elders are here! 00:18
can someone help with a couple of things ?
rakudo: class Foo { has Int $.length; method p {say $.length;} } ; my $f = Foo.new(:length(5, 7)); $f.p;
p6eval rakudo 609fd6: OUTPUT«57␤»
patrickas what is this doing ?
TimToady hopes that's not "elder" in a cthulhuian sense 00:19
it would appear to be working
patrickas :-)
jnthn patrickas: I guess the Int type constraint ain't being enforce 00:20
patrickas so is it working? or is it a bug ?
jnthn Er, actually I'm pretty sure it isn't, given .type introspection on attributes doesn't work either.
patrickas: That's a bug, I believe.
TimToady either that, or (5,7) does Int somehow 00:21
jnthn oh noes!
rakudo: say (5,7) ~~ Int
p6eval rakudo 609fd6: OUTPUT«0␤»
jnthn phew
:-)
TimToady whep
er, wehp
patrickas the problem is ... it is from an example in the advent calendar I am going over
perl6advent.wordpress.com/2009/12/2...erloading/
jnthn TimToady: IIUC, then a "package Foo;" in Perl 6 should die. 00:22
TimToady: But a "package Foo { }" is OK.
TimToady: std doesn't seem to pick up on the package Foo; though
TimToady that is correct, 'package Foo;' is forbidden
jnthn std: package Foo; "I am OK!"
p6eval std 31137: OUTPUT«ok 00:01 107m␤»
patrickas the example is multi sub infix:<+>(PieceOfString $lhs, PieceOfString $rhs) { PieceOfString.new(:length($lhs.length, $rhs.length)); }
jnthn TimToady: OK - any preference on the error message?
TimToady well, we'll see about *that*!
the correct error message depends on whether the interpreter knows how to switch to p5 code :) 00:23
jnthn TimToady: For now, it doesn't.
TimToady "I don't know how to run Perl 5" or some such is fine
jnthn OK
TimToady or "This looks like Perl 5 code"
jnthn Maybe some enterprising soul will come along and hack things up so it does it via Blizkost or something. :-) 00:24
TimToady and maybe STD will attempt to switch to STD_P5 at that point, assuming I ever finish it...
patrickas ping mathw 00:28
00:30 awwaiid left
patrickas also trying (and failing badly) to understand and get the one liner from day 23 to work on recent rakudo 00:32
rakudo: say [my@i=0 xx 9,1,0 xx 9];map {say [@i=m {%([^8]>>.fmt("%03b") Z 0,1,1,1,1,0,0,0){@i[($_-1)%19,$_,($_+1)%19].join}},^19]},^9;
p6eval rakudo 609fd6: OUTPUT«0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0␤»
jnthn TimToady: OK, seems I have it working nicely. :-) 00:38
00:39 xinming_ is now known as xinming
jnthn spectests 00:39
Hmm...must be getting towards beer time. :-)
patrickas almost 4 am here ... I think beer time has passed! :-) 00:40
jnthn 2:44am here
But I got up at 3pm
My body clock has slowly got skewed like an hour a day later over the last week. 00:41
Next week I have a meeting to make, as well as a flight, so I probably need to make some attempt to return to normality soon though.
patrickas I can't say you're on the right track for that :-) 00:42
colomon o/ 00:44
jnthn yayitscolomon!
patrickas \o 00:45
colomon a mostly asleep colomon, admittedly. 00:50
messing around with max here
jnthn hands colomon strong coffee and his commit bit
colomon wishes the coffee were extra-strong orange Mountain Dew. ;) 00:51
pugssvn r31138 | lwall++ | [varnames] use $/ := to avoid STD carping about P5 usage
jnthn hasn't seen Mountain Dew in Europe
Thus I've heard lots about it but never actually tried it. 00:52
00:52 xomas_ left
colomon Lots of caffeine and sugar. 00:53
I was kind of addicted to it in college, then gave it up cold turkey.
Now if I have some, I can feel its effects half a day later.
pugssvn r31139 | lwall++ | [STD etc.] more prep work for moving EXPR out of STD 00:54
r31139 | [STD] carp about 'package Foo;'
00:57 skids left
jnthn colomon: Wow...odd stuff :-) 00:57
colomon: We have lots of other energy drinks over here. 00:58
I tend to avoid 'em though.
00:58 skids joined
jnthn (Though I do drink coffee...mostly only within the first few hours of waking up.) 00:59
colomon: We're down to 608 open tickets in RT. :-) 01:00
colomon I found that if I don't drink caffeine, I don't miss it.
\o/
we could really use some better tests for min and max.
jnthn I can imagine. :-)
I got us running much of S12-introspection/attributes.t again
I really should spend the tuits to get handles back soon. 01:01
colomon Lots of edge cases not tested at all. :(
jnthn :(
colomon \o/
I like your news better than mine. :)
jnthn Attribute now actually inherits from Any.
Fixed a bunch of other minor RT tickets.
Well, minor as in "easily dealt with", at least one of them was a very nasty bug. 01:02
Well, a copule were...
colomon which one? I was impressed with all the commits...
jnthn Well, the exit one was icky.
But also, "use" wouldn't set the file handle it used to read the module in with as having utf8 encoding
Meaning as soon as you used anything non-ASCII in a module...boom. 01:03
Unless you pre-compiled it, of course. :-)
I think that we didn't notice until recently tells us how many people are using unicode chars in their modules...
er, chars not in ASCII 01:04
colomon I understood. :)
jnthn Just about through the spectests for that patch, anyway. :-)
Heh, I'm trying to get all of the charset/code points/graphemes stuff straight in my head at the moment. :-)
colomon oh no, dueling patches! ;)
jnthn was a tad ignorant on that area, but mentoring a GSoC project covering that area was a good incentive to read up on it 01:05
colomon (actually won't commit here until I've done at least two spectests, I reckon. I'm testing to make sure my new version of max works, then I'll port the changes to min and minmax.)
jnthn OK. I'm through the tests and it seems fine.
pushed 01:06
That's two more RT tickets down, once they get tests.
dalek kudo: f1042d7 | jonathan++ | src/Perl6/Module/Loader.pm:
Ensure we read in modules as utf8.
kudo: 6ba4b22 | jonathan++ | src/Perl6/Grammar.pm:
carp about 'package Foo;'
jnthn tried to fix 74236 earlier and epic failed, breaking much of the spectest suite 01:07
Will have another crack at that some other day.
01:07 masonkramer_ joined
jnthn colomon: Another nicety is that warn now gives a line number too. 01:08
colomon jnthn++ # for a good day's work.
jnthn Yeah, lots of little but good to have bits I think. :-)
In the ROADMAP we have the rather hard-to-know-if-we-got-there: 01:09
1 ** improved error messages and failure modes (B, all)
I'm wondering what our benchmark is for saying we've done enough there.
pmichaud: ^^ comments on this one welcome 01:10
It's the roadmap equivalent of an unclosable ticket. :-)
01:10 awwaiid joined
patrickas i say whenever the other items are done, the error messages would be good enough by then :-) 01:11
jnthn :-)
patrickas we close the ticket on the spot and annouce christmas... or something like that 01:12
colomon jnthn: huh. can't decide if we should close it or bump it down a level in severity. 01:13
jnthn colomon: Well, it's an area we should be aiming for constant improvement in really.
colomon jnthn: exactly.
jnthn colomon: I'm just wondering if we're at the point where we feel we're "good enough" for R* on this front, and if not, what are the things we really must fix. 01:14
TimToady WARNING: improving error messages has been determined to be addictive.
colomon jnthn: actually, one useful thing for R* (maybe?) might be a review of when we die and when / how we fail. 01:15
jnthn Ah, good point.
colomon I think we could probably use more consistency. (Should we ever die on errors, actually?)
jnthn We may be over-inclined to die.
colomon I'm probably a guilty party here....
jnthn Well, me too.
Mostly habbit from working in other languages where there's no such thing as a lazy exception, so you either throw it now or forever hold your peace. 01:16
er, I mean, rely on somebody checking a return value
Which never happens.
mdxi TimToady: it's true. it's a very, very good use of time and effort, though :)
jnthn (Never happens consistently, anyways. :-))
The Perl 6 model is nice though. :-) 01:17
TimToady one good error message can save a ton of FAQs
jnthn Aye.
Which is very fitting for a language that wants to help people Get Stuff Done. :-) 01:18
TimToady std: package Foo; 01:19
p6eval std 31139: OUTPUT«ok 00:01 104m␤»
pmichaud jnthn: I agree, the ROADMAP item is a big vague (more)
jnthn rakudo: package Foo;
p6eval rakudo 609fd6: ( no output )
jnthn aww. too soon too.
TimToady ENOTYET
and the svn version lies
jnthn ЕЕШОНЕТ 01:20
pmichaud if we know of any error messages or modes that are currently unacceptable, let's list them directly in the roadmap. Otherwise, I'm comfortable with marking the roadmap item as "done" whenever the rest of the team is comfortable with it.
jnthn pmichaud: +1
pmichaud: I'm fairly comfortable with where we are now for R*. Yes, we've some way to go, but I sense going to The Next Level is going to be quite a lot of effort. 01:21
01:21 masonkramer left, masonkramer joined
jnthn pmichaud: e.g. the highwater stuff STD does, and trying to mark the exact spot and the green/red highlighting of either side of it, etc. 01:21
pmichaud oh, I think highwater isn't _that_ hard. I'm planning to try it for nqp. 01:22
jnthn pmichaud: Oh, cool.
pmichaud if it goes in easily enough for nqp, we can get it for rakudo.
(and I suspect it will.)
jnthn pmichaud: It's IMO not our most pressing issue right now, though.
pmichaud doing the green/red highlighting... I don't know about that one yet. :)
well, highwater marking would help a lot with our current "unable to parse blockoid" failures.
so I think it's just below highest level.
jnthn Yeah, those are...uninformative.
Lists and closures are probably two of the real biggies atm. 01:23
pmichaud those are my highest priorities, yes.
jnthn OK, excellent. 01:24
pmichaud I'm working on exit() today because it involves changes that need to go into Parrot 2.5
jnthn Ah, yes.
pmichaud so there's a bit of a time constraint there. and I see other constants coming up.
jnthn Typical that it's about as early in the month as it possible could be.
pmichaud ah well, just bad luck of the calendar there. 01:25
we'll make it work out.
jnthn *nod*
If I can, I'll try and work out why on earth Parrot segfaults on exceptions caught in the REPL too.
pmichaud oh, I thought I fixed that already. 01:26
oh, wait, I started, but realized another fix was needed first.
The segfault is an infinite-exception-handler loop.
jnthn oh hmm, it ain't doing it for me now... 01:27
pmichaud ...but I think I fixed that already, now that I think about it.
jnthn I'm sure it segv'd on me earlier
pmichaud it did
jnthn Oh, maybe it was before I bumped PARROT_REVISION
Or git pull'd
pmichaud the problem was that Exception PMCs didn't know how to concat with a string constant
jnthn Or some such.
ah.
OK, good that's fixed. 01:28
pmichaud so that threw an exception, which got caught by the handler, which tried to display the exception message, which threw an exception, which ...
jnthn heh
It's exceptions all the way down.
Does anyone else get SEGVs in t\spec\S05-match\capturing-contexts.rakudo btw? 01:29
jnthn has them reliably here ATM. 01:30
01:30 whiteknight left
jnthn pffft...backtrace involves tailcalls 01:31
01:34 justatheory left
jnthn Ugh. Nasty. I'll take it another day. 01:34
01:35 zorgnax joined
jnthn aboutish for another hour or two, but mostly relaing rather than hacking on stuff 01:35
01:35 zorgnax left
colomon I'm getting two failures, S02-builtin_data_types/hash.t (which is %a not flattening on slurpy args, I think). 01:38
and S02-names_and_variables/varnames.t? 01:39
anyone else seeing the latter?
sorear pmichaud: Any updates on lexical persistance in the Rakudo REPL? 01:40
jnthn colomon: I've been seeing the hash.t one today too
sorear TimToady: Do you think the high water stuff belongs in STD or Cursor?
pmichaud sorear: haven't worked on it since last week.
jnthn colomon: Haven't seen issues with varnames.t
colomon: oh. 01:41
Yeah, it...seems to be not quite right. Odd.
colomon: oh, wait 01:42
I ran the .t
colomon: the .rakudo is clean.
colomon := binding of variables not yet implemented
is what I am getting
sorear let
let's implement that. 01:43
jnthn huh, I don't see any := in there
colomon: You get an interesting backtrace at all
sorear jnthn: you need to update
01:43 patrickas left
jnthn sorear: update...? 01:43
sorear the := was added 50 minutes ago
colomon := binding of variables not yet implemented
in 'infix:<:=>' at line 630:CORE.setting
in main program body at line 25:t/spec/S02-names_and_variables/varnames.rakudo
Dubious, test returned 1 (wstat 256, 0x100)
jnthn Oh
er, wtf. 01:44
jnthn wonders who added that and why
pmichaud I don't see a := update.
unless you mean to the test file.
sorear perlcabal.org/svn/pugs/revision/?rev=31138
01:44 ash___ joined
jnthn pmichaud: Yes, to the test file 01:44
colomon TimToady did
jnthn :/
colomon rev 31138 01:45
jnthn TimToady: ?
pmichaud okay, so either #?rakudo skip it or add := to rakudo. :)
if the latter, note that any sort of syntactic := is (IMO) wrong.
jnthn pmichaud: I'm not sure I understand why the test was changed.
pmichaud I suspect that $/ wants binding instead of assignment, in general.
jnthn Ah, OK
01:45 ash___ left
jnthn Well, probably we fudge it then. 01:46
pmichaud: := should be a normal multi-dispatch
pmichaud fudge +1 for me for now.
01:46 ash__ left, ash___ joined
pmichaud jnthn: agreed. I just know that I've seen people arguing it should be syntactic on channel and I want to make sure it's not. :) 01:46
jnthn pmichaud: What does need to be syntactic is the LHS in the case of my ($a, $b) = ... vs my ($a, $b) := ...
But that's a seperate issue.
The way I have it now, though, := itself is just a multi 01:47
pmichaud good.
jnthn In fact, the error is just given my the multi candidate where we need to implement the working thing. :-) 01:48
*by
sorear pmichaud: My assertion that it should be syntactic was due to a critical misunderstanding on what := did. Pretend it never happened. 01:51
pmichaud no problem :-)
sorear TimToady: my $a := 2; (-> $b { $a := 1; say $b })($a);
resolution of this case is the #1 issue blocking := 01:52
dalek p-rx: 6841519 | pmichaud++ | (2 files):
Adjust regexes to use @?BLOCKPAST dynamic var instead of @?BLOCK global.
01:53
01:56 ash___ left
diakopter sorear: how goes it? 02:00
02:14 yinyin joined
sorear diakopter: Partly waiting for you, partly designing the backtrack system 02:16
02:24 azert0x left
TimToady pugs: my $a := 2; (-> $b { $a := 1; say $b })($a); 02:32
p6eval pugs: OUTPUT«2␤»
sorear diakopter: OK, now I'm completely waiting for you
TimToady I think pugs is correct here.
sorear :(
there's a very simple way to implement binding compatible with everything you and pmichaud have said in Rakudo 02:33
it involves adding ANOTHER level of indirection to variables
TimToady I think most of the things like highwater belong outside the grammar 02:36
I'm going to have to change the precedence table from lexical constants to move EXPR out though.
sorear is that a problem? 02:42
TimToady well, it's another level of indirection or two :P 02:52
02:53 masonkramer_ left
TimToady also have to figure out what to do about $*LEFTSIGIL 02:54
dalek kudo: c0efe09 | (Solomon Foster)++ | src/core/Any-list.pm:
Allow min, max, and minmax to handle single-argument block Orderings.
02:57
jnthn colomon++! :-)
pugssvn r31140 | colomon++ | [t/spec] Unfudge two tests that now work correctly, add six new tests. 02:58
colomon If moritz_++ is feeling lazy this week, a newcomer challenge to write more min / max / minmax tests might be a good thing. 02:59
:)
jnthn Yes. :-)
colomon: What's the latest test pass count? 03:00
colomon 33,257.
jnthn Nice 03:01
colomon okay, our brief reprieve where Henry actually slept two hours in his crib is over, so I'd better get to sleep in case I have to rock him a few hours from now.
o/
jnthn night o/ 03:02
lue ohai and goodnight colomon o/ 03:04
Unless it cannot be done, I'd like to upload the designs I made for perl6 merchandise into pugs' misc/ folder 03:07
sorear hmm, I could implement binding, unfudge a few hundred tests, then dangle a test# under pmichaud's nose while keeping the time increase a secret 03:08
jnthn sorear: I think pmichaud had a Plan Of Immense Evil that let us pay the price of the extra indirection lazily, fwiw. 03:09
sorear: If your luck with the IR Clogs searchengine is any better than mine, you may be able to dredge up discussions of it. 03:10
TimToady tries to picture a UV Clog... 03:11
jnthn www.idealo.co.uk/pp/1440163.html # ENOTULTRAENOUGH 03:13
lue Gamma Clogs are the worst.
TimToady actually, I think of STD as the standard grammar stuff, outside of STD_P6
so maybe it's stuff moving out to STD_P6 that we're talking about, really 03:14
lue Maybe the shoe is straddling inbetween violet and UVA
TimToady I could see much more of that color after I got cataract surgery 03:15
black lights aren't very black now...
lue How fun it would be to see the whole of the EMR. 03:16
Should be that painful, it'd be like a creature who only sees red and yellow suddenly seeing our visible spectrum. 03:17
s/should/shouldn't/
TimToady if you don't mind your retinas getting ionized, sure 03:18
lue after that though, looking at the stars won't just be black and white and ROYGBIV anymore...
TimToady you could have a great career as an airport scanner 03:19
03:19 Chillance left
lue just sit in the lobby w/ a newspaper, and run like hell towards anyone with a high amount of metal, esp. lead 03:19
TimToady Excuse me, sir, but why are the bullets in the gun hidden in your crotch shining in gamma radiation? 03:20
lue But then [ow], you'd see every single radio station in the area O.o
TimToady like the old commercials: You just saw it on the radio!
lue And then a day on the beach in Antartica [eeeeeee] 03:21
"beach" meaning the warmest spot on the island, of course :) 03:22
TimToady Life's a beach, and then you dry.
lue I looked up IR ink once, it's waay more difficult to shift IR into visibility than it is w/ UV 03:23
03:23 hercynium left
lue On the bright side, you'd be able to dodge cosmic rays much faster than when you use a stupid little scanner :) 03:26
03:34 alester joined 03:35 yinyin left
lue thinks it's time for a wiki protocol... something like wiki://keyword 03:35
03:39 gbacon joined
mberends sorear: go right ahead with deleting the old Sprixel, nothing depends on it. There is a test harness that does partial fudging of tests without creating copies of the test scripts, I've stashed it locally. 03:40
jnthn mberends: Heh, you're up at this time too, huh. :-) 03:41
mberends oh-oh, insomniacs not-so-anonymous... 03:42
jnthn :-)
Well, I probably will attempt sleep soonish. 03:43
mberends jnthn: but have just had over 6 hours sleep. Have you? ....
jnthn I didn't go to bed yet
But I got up at 3pm yesterday 03:44
mberends it's the silly season for body clocks
jnthn Yeah...it's got warmer here too, which doesn't help me sleep. But having a week with no meetings at all made it kinda easy to get de-sync'd. :-) 03:45
Next week I have a meeting *and* a flight to make.
mberends: BTW, will you be heading to the Belgian Perl Workshop? 03:46
mberends hmm, not thought about 26th June yet. It's theoretically possible, since the $work just prior will be in .nl afair. Must check the diary later today. "Maybe". 03:50
03:50 gbacon left, meppel joined
jnthn mberends: OK, I'll be there. 03:52
mberends I think it was those friendly Belgians who gave out the wooden little round tuits in Arnhem.
jnthn mberends: Going to do a bit of family visiting in the UK, then it's just the Eurostar over to Brussels.
And then sleeper train from Cologne back to here on the Sunday evening.
So works out pretty nicely. 03:53
mberends jnthn: yes, very good plan
lue [ I'll be there, in little bits :) ]
That's the one bad thing about the US, IMO. We don't have an awesome train system :/ [for passengers of course] 03:54
03:54 meppl left 03:55 envi^home joined
mberends I'll travel to UK by road this evening for $work before FPW on Friday/Saturday 03:55
lue
.oO(Where is my TARDIS? grr)
03:56
jnthn mberends: OK, nice. I'm flying to Kiev on Friday for Perl Mova.
mberends: Wish I was doing it by train, but it's really quite a trek from here. 03:57
mberends: More out of bad schedules than distance. :/
mberends will present 2 of jnthn's talks at FPW. Doing an impersonation will be tricky.
jnthn mberends: Well, you can always google for "fake beard store calais"
mberends lol
jnthn mberends: Which two, out of curiosity? 03:58
mberends Solved, and Dispatch. journeesperl.fr/fpw2010/talks 03:59
lue how much memory doth it take to compile rakudo, out of curiosity? 04:00
mberends sorear++ mentioned around 300MB. I stopped monitoring when it went under 700MB 04:01
jnthn mberends: Ah, cool.
mberends: Let me know if you have any questions.
lue As long as its under 384 MiB [which is what I last heard], I can theoretically fit that all on my physical RAM :D 04:02
jnthn lol..."crack syntaxique‎"
mberends jnthn: thanks, I'll look over your slides during the week. I would like to run some of the code live during the talk, even though some presenters think that's playing with fire. 04:04
jnthn mberends: I still have burn scars. ;-) 04:05
lue Fire is a great friend; look at all the satisfied arsonists :)
jnthn OK, time to atempt sleep. o/ 04:09
mberends o/
lue good night o/
sorear jnthn: Good to know... and not good to know. We can't have all the important features blocking on the tuits of one man :( 04:16
04:17 occamshatchet left
sorear also, why is #perl6 never online when I am 04:17
lue I feel the same way sometimes 04:19
Most of the guys on #perl6 seem to be in Europe.
mberends lue: that's true only for the times that *you're* online ;) 04:30
lue so, for my 2 am, everyone in the US is up? ō.o 04:33
mberends #perl6 is the place where programmers with disturbed sleep pattern hang out 04:36
04:36 tedv left
lue I'll have plently of time for that during summer vacation :) 04:36
that also applies to the Internet in general :) 04:37
mberends uck. building latest Rakudo crashed here making core.pir: Parent isn't a class :-( 04:38
04:42 kaare joined 04:43 kaare is now known as Guest50061
sorear mberends: that is, by chance, exactly the same error which results from any attempt to load PCT.pbc at runtime from within Rakudo 04:44
it was a showstopper in blizkost for a while before I found a medium-horrid workaround 04:45
mberends curious. I'm going to backtrack a few commits with git reset
oops, makefile.in changed. must re-run Configure.pl before worrying. 04:47
04:55 finanalyst joined
mberends no worries now, core.pir compiled ok (in 367MB virtual) 05:00
05:05 pragma_ is now known as _pragma
lue ooh 05:09
rakudo: my $a = 1; $a++; say $a; ++$a; say $a
p6eval rakudo c0efe0: OUTPUT«2␤3␤»
lue what is the difference between the postfix and prefix form? 05:10
05:10 _pragma is now known as pragma_
pugssvn r31141 | sorear++ | [viv] Remove "use Cursor" fossil; it was causing duplicate definition warnings due to perl 5's inadequate %INC handling, and is unneccessary with moose_extends. 05:11
sorear lue: absolutely none
ok, they call different overloads
this isn't C++ 05:12
05:13 stephenlb joined, stephenlb left 05:14 pragma_ is now known as _pragma 05:15 _pragma is now known as pragma_ 05:16 pragma_ is now known as _pragma
sorear TimToady: How is whitespace DWIM for all quantifiers as a concept? [:r x +] == x**<.ws> 05:16
pmichaud pugs: my $a := 2; (<-> $b { $a := 1; say $b })($a); 05:19
p6eval pugs: OUTPUT«*** ␤ Unexpected "$b"␤ expecting operator or ")"␤ at /tmp/YR_z6ivnOt line 1, column 18␤»
pmichaud pugs: my $a := 2; (sub ($b is rw) { $a := 1; say $b })($a);
p6eval pugs: OUTPUT«2␤»
pmichaud pugs: my $a := 2; (sub ($b) { $a := 1; say $b })($a); 05:20
p6eval pugs: OUTPUT«2␤»
eternaleye lue: postfix returns the input as an lvalue, prefix returns the incremented rvalue.
rakudo: my $a = 1; say ++$a; $a = 1; say $a++
p6eval rakudo c0efe0: OUTPUT«2␤1␤»
pmichaud pugs: my $a := 2; (sub ($b is rw) { $a = 1; say $b })($a); 05:21
p6eval pugs: OUTPUT«*** Can't modify constant item: VInt 2␤ at /tmp/N3a0i3vL87 line 1, column 31-37␤»
eternaleye Unless you use the return value, they are identical (well, prefix is more efficient, but that isn't noticable in rakudo atm.
pmichaud pugs: my $a = 2; (sub ($b is rw) { $a = 1; say $b })($a);
p6eval pugs: OUTPUT«1␤»
lue thank you eternaleye 05:22
05:27 justatheory joined
PerlJam Must a named rege:q 05:27
lue pmichaud: what are you doing? Just curious.
PerlJam blah
05:28 justatheory left
pmichaud lue: just checking some binding behaviors. 05:30
alpha: my $a = 2; (sub ($b) { $a := 1; say $b })($a)
p6eval alpha 30e0ed: OUTPUT«2␤»
05:32 _pragma is now known as pragma_
sorear alpha did syntactic binding 05:33
pmichaud right.
sorear basically just container assignment. nice, simple, and doesn't allow for the possibility of the read only aliases that are oh so critical for S06 05:34
pmichaud well, alpha predated those.
sorear my timelines are so screwed up 05:36
pmichaud but yes, if the pugs version is correct (and I suspect it is), then I don't see an obvious way around the double-indirection. 05:37
variables end up being ObjectRef to Perl6Scalar to the actual value.
sorear that's the way I see it working too
pmichaud we could potentially go back to alpha's mechanism of copying values, so that we end up with ObjectRef to container/value.... but I suspect that's not the best way to go. 05:38
sorear alpha's mechanism of copying values is?
pmichaud $b = 2 actually copies a "2" value into the container 05:39
as opposed to binding a container to a value
sorear as opposed to copying a pointer to a newly allocated 2
pmichaud well, an existing 2, actually 05:40
in current master, we just bind to immutable values
which works out pretty well, so we're not creating copies of values all over the place
dalek p-rx: c341588 | pmichaud++ | src/NQP/Actions.pm:
Refactor loop exceptions slightly.
05:41
lue I can't wait for binding :=) 05:42
PerlJam Anyone happen to know where in the spec it talks about named regex without being within a grammar?
sorear S05 05:43
PerlJam obviously.
I was hoping for a something slightly more narrow :)
pmichaud "This form always gives preference..." # start of section 05:44
sorear yeah, but I didn't know the line number off the top of my head 05:46
the section I was going to refer you to seems to have been a figment of my imagination, anyway 05:47
lue It'd be interesting if you did :)
sorear regexes are a special kind of sub that defaults to "has" scope
pmichaud ?
regexes are basically methods 05:48
sorear so bare regex/token/rule is only valid in a grammar (or other kind of class, but you're inviting disaster if it doesn't inherit from Cursor)
"my regex" and "our regex" are fine outside grammars, and drop the regex object (which isa Method) into lexical or package scope
and methods are basically subs
05:49 Guest33860 left
PerlJam Current rakudo doesn't seem to quite implement the spec in this regard I guess. 05:49
sorear rakudo: my regex foo { \d+ }; say "123" ~~ &foo;
p6eval rakudo c0efe0: OUTPUT«123␤»
pmichaud I think it does everything except for translating <xyz> to act like <xyz=&xyz> when xyz is in scope.
PerlJam ah, that would explain what I'm seeing 05:50
pmichaud so, if you want a lexically scoped regex, at the moment you have to get to it through the &xyz form.
but otherwise I think it works fine.
PerlJam aye. that's it.
pmichaud rakudo: my regex foo { \d+ }; say "abc123" ~~ / <&foo> /; 05:51
p6eval rakudo c0efe0: OUTPUT«123␤»
PerlJam Why aren't regex scoped the same as subs again? 05:52
pmichaud they act more like methods than subs.
and in that sense, they tend to scope the same as methods. 05:54
rakudo: my method xyz() { say self ~ 'here'; }; &xyz(123);
p6eval rakudo c0efe0: OUTPUT«123here␤»
PerlJam When would there not be a "current grammar"? 06:01
sorear ? 06:02
PerlJam "This form always gives preference to a lexically scoped regex declaration, dispatching directly to it as if it were function. If there is no such lexical regex (or lexical method) in scope, the call is dispatched to the current grammar, assuming there is one." 06:03
If there were always a "current grammar", it seems like it would be simpler to say that named regex declared outside of an explicit grammar declaration are lexically scoped in the current grammar. Then you don't have to worry about a fall-back mechanism because you always dispatch to the current grammar. 06:05
and thing "regex foo { ... }" would very much be like "sub foo { ... }"
s/thing/then/
So ... when would there not be a current grammar? and what does "current grammar" really mean? 06:06
pmichaud think of "current grammar" as "current class" 06:07
does that help?
(because a grammar is really a class)
PerlJam no, because classes require declaration. 06:08
pmichaud so do grammars. :-)
PerlJam presumably <before ...> and friends only work because of the fall-back to the "current grammar" which is implicitly the Perl 6 grammar.
(outside of an explicit grammar declaration that is)
pmichaud no, the Perl 6 grammar is not the "current grammar" 06:09
at least, I don't think it is.
when one creates a new grammar, it derives from Grammar, not from the Perl 6 grammar.
<before ...> and friends work because they're default methods in Cursor
(and Grammar derives from Cursor)
06:09 gfx joined
PerlJam so ... how does if "blah blah blah" ~~ / \s+ <before blah> / { say "whitespace before blah" } work? How is <before> dispatched? 06:11
pmichaud it's a method on Cursor 06:12
sorear PerlJam: the method is called with a fresh Cursor as invocant
Cursor is the base of all grammars
pmichaud more to the point, the regex is called with a fresh Cursor as invocant
&regex.match(...) creates a new Cursor for the match.
sorear User-defined grammrs are just subclasses of Cursor; as such, they can override rules (which are methods)
pmichaud more detailed: Regex.ACCEPTS calls Regex.match, and Regex.match creates a new Cursor object for performing the match 06:13
PerlJam okay, that makes sense. 06:14
pmichaud and the built-in assertions like <before>, <alpha>, <digit>, etc. are all defined on Cursor
PerlJam I now don't understand the parenthetical here " ... then the call is dispatched as a normal method on the current Cursor (which will fail if you're not currently within a grammar)" 06:15
pmichaud given <xyz>
if there is no &xyz in scope
then the assertion is dispatch as self.xyz() 06:16
sorear that parenthetical is quite possibly wrong and/or outdated
PerlJam sorear: that's that I'm thinking.
pmichaud sorear: that's true also, although it looks newish to me (i.e., I don't remember reading this particular phrasing before tonight)
sorear as a rule, I don't remember phrasings. I make them up on the spot. 06:17
PerlJam It's in the paragraph starting on S05:1278
pmichaud about like 68% of my statistics (made up on the spot)
I agree that in light of something like <before>, the synopsis text doesn't make sense. 06:18
lue
.oO(4 out of 5 dentists say they have been that 1 out of 5 before.)
pmichaud synopsis might make more sense if the parenthetical was removed. 06:20
PerlJam It would make complete sense if it were removed and that bit about spontaneous Cursors added somewhere. (maybe it is there but I missed it though)
06:23 shtrb joined 06:24 JimmyZ joined
PerlJam If grammars are automatically derived from Cursor, is the only way to get a "grammar" that's *not* derived from Cursor to make a class? 06:25
pmichaud PerlJam: I believe so, yes.
I'm not sure such a grammar would behave, though.
sorear you'd have to implement the regex engine API yourself 06:26
JimmyZ std:
lue afk 06:27
PerlJam having to say "my regex foo { ... }" rather than just "regex foo { ... }" really grates on my brain for some reason. 06:48
pmichaud do you have the same issue with "my method foo" versus "method foo", ooc? 06:49
PerlJam no, because I've never wanted to declare a method outside of a class. 06:50
pmichaud ah.
but you want to declare a regex outside of a grammar. I can see that. 06:51
06:52 alester left
pragma_ is perl6 modeling OO based on the Moose module? 06:55
pmichaud pragma_: more the other way around :) 06:56
they were really developed together
but Moose ideas came out of Perl 6.
06:56 fridim joined
sorear the projects have diverged since then 06:56
PerlJam If all regex declared outside of a grammar were part of a single anonymous grammar that derived from Grammar/Cursor just like any other and regex calls to named subrules dispatched to this anonymous grammar, I think we get the same effect as specced only I don't have to say "my regex" :-)
pmichaud PerlJam: the hard part is getting Cursor to be part of that anonymous grammer. 06:57
*grammar.
i.e., when we do Regex.match() -- how does it know what type of Cursor to use?
or do you want .match to use that anonymous one as well? 06:58
and in that case, "regex xyz ..." would really be like MONKEY_TYPING with the anonymous grammar
PerlJam yes, I realize that :)
pmichaud (unless we want to repeatedly derive new anonymous grammars for every regex declaration)
PerlJam no, no. only one anonymous grammar. 06:59
pmichaud no, it has to be separate, because the regex declarations need to be lexically scoped.
we don't want a regex declared in one block to suddenly appear in uses of the anonymous grammar in other blocks.
it sounds like what you really want is that "regex ..." outside of a class/grammar definition is automatically treated as "my" 07:00
(just like "sub ..." is automatically treated as "my sub ...", although this occurs within class/grammar definitions as well.) 07:01
PerlJam yes.
07:01 finanalyst left, shtrb left
PerlJam or no 07:02
This is the whole reason we have the method/sub dichotomy for classes now. methods are "has" scoped. subs are lexical. regex are "has" scoped. _____ are lexical. 07:04
("subs" could fill the blank but I don't want to go there :) 07:05
anyway, I think I'm working towards a huffman coding argument or something. I get the impression that named regex outside of a grammar would be very common. 07:06
07:06 Sarten-X left
pmichaud well, even in the case of 'sub' I think it will be a better practice to say "my sub ..." instead of just "sub ...". 07:08
diakopter sorear: what do you need from me? :)
PerlJam Take the example in the Perl6 book: gist.github.com/427388
I can see someone evolving their regex to that without the need or desire of a grammar.
(granted that example needs updating now) 07:09
pmichaud but if we come up with a different name for lexically-scoped regex, we'd also want new words for 'token' and 'rule' too.
(at least I think we would.)
PerlJam yes and then the universe gets a tad uglier. 07:10
pmichaud so, explict "my" seems relatively clean, then.
sorear diakopter: an explanation of what + does in perlesque 07:11
diakopter: a way to see the IRs of perlesque
PerlJam Seems like Perl 6 leans heavily on the idea of lexical scope (by default) ... except when it comes to regex. 07:12
pmichaud agreed.
PerlJam Either I'm suffering a foolish consistency or Perl 6 has a foolish inconsistency then :)
sorear you're missing the fact that Perl 6 was designed to be self hosting 07:13
requiring "our" on the 1000s of regexes that will make up the eventual STD.pm6 would not be good 07:14
PerlJam I don't want to require "our" in that manner. 07:15
07:16 masak joined
masak oh hai, #perl6! 07:16
phenny masak: 05 Jun 13:43Z <jnthn> tell masak yes, I thought I mentioned that elements was still missing, but you may like to have a crack at adding it. :-) But I can do so. :-)
masak jnthn: oh, I could definitely have a crack at adding it, if you havn't already. guess I'm not entirely over my Parrot/C aversion yet. :) 07:17
I'd need to toally cargo-cult something to do it, though.
cosimo good morning 07:18
i need help understanding how to build my own grammar 07:19
reading Perl6/Grammar.pm or STD.pm6 is quite a nightmare
any docs out there?
pmichaud cosimo: a grammar to parse what? 07:20
masak what would you like to know?
there are plenty of existing, smaller grammars out there that you could look at.
just go to proto.perl6.org
cosimo pmichaud: to parse puppet modules, but I can start simple and get there step by step 07:22
there's already an existing grammar, here. not sure if it helps or makes things worse for me 07:23
github.com/reductivelabs/puppet/raw...grammar.ra
JimmyZ hello masak 07:24
masak oh hai JimmyZ
cosimo say for example, 07:25
regex TOP { ^ <line> ** \n <empty_line>? $ }
what is '^'? and '**' ? how can I find out?
masak cosimo: my advice: write tests for the existing grammar, not necessarily as Perl 6 code. implement the new grammar such that it passes the new tests.
pmichaud cosimo: oh, Synopsis 5.
PerlJam cosimo: read S05
JimmyZ masak: were they bugs last time I showed you?
pmichaud ^ means "start of string". 07:26
cosimo PerlJam: pmichaud: great, thansk
masak JimmyZ: I think they were. but weren't they reported to RT already?
cosimo thanks, even
pmichaud ** is the repetition quantifier
PerlJam cosimo: people here are always happy to share what they know too. 07:27
JimmyZ masak: I sent it. but I can't find it in RT
cosimo pmichaud: and, why it uses regex and not token for example?
sorear Read S05.
pmichaud 'regex' backtracks, 'token' doesn't.
masak JimmyZ: I thought I saw it as a comment on an existing bug. so maybe moritz_ or someone merged it into an older ticket, also submitted by you? 07:28
pmichaud (in many parsers, backtracking isn't needed, and explicitly declaring such makes for a more efficient parse)
masak or it simply didn't get through.
cosimo ok, I'll go read S05 then. I wanted to write a real app, and I think I found an excellent use case :) 07:29
JimmyZ masak: which RT?
masak cosimo: when to use 'regex', 'token' and 'rule' is still something that doesn't come naturally to me. it's a fingertips thing, I suspect. I usually use 'regex' until it's totally clear by circumstantial evidence that I should upgrade to 'token', ditto 'token' -> 'rule'.
JimmyZ masak: I can't see my email in p6c too. 07:30
masak JimmyZ: I don't know. my regular powers are diminished, because I'm not at my own keyboard.
JimmyZ oh, okay
pmichaud my guidelines: use 'rule' when you expect the parts of the regex to be separated by whitespace.
use 'token' when you're defining something where each part is all-or-nothing 07:31
masak if you find yourself adding explicit <.ws> calls everywhere, that's a good sigh you should be using 'rule'.
pmichaud or \s*
or \s+
masak eww! :P
pmichaud no, I mean if you're writing \s* or \s+ everywhere, that's a good sign you should be using 'rule' 07:32
not that you should rewrite <.ws> with \s* or \s+
PerlJam btw, these rules-of-thumb we've all independently discovered (more or less). I wonder if it's time for a "grammars best practices" or "grammar writing guide" or something.
masak pmichaud: yes, I know. still, I don't tend to write <.ws> like that. 07:33
sorear watches as pmtuits are diverted away from R* and towards helping newbies; wishes he could fill the void 07:38
pugssvn r31142 | sorear++ | [sprixel] Remove from trunk at request of diakopter and mberends 07:44
pmichaud sorear: no, my tuits are being spent waiting for parrot recompiles :-| 07:46
sorear Ah :(
pmichaud and trying to figure out why my changes aren't having any visible effect (see 'make bootstrap-ops' :) 07:47
sorear somebody broke the STD build 07:57
oh, no 07:58
I was just looking at the wrong window, which held a failed build from much earlier
08:04 plobsing left 08:07 meppel left
dalek p-rx: 7adae67 | pmichaud++ | src/NQP/Actions.pm:
Fix except_types error.
08:11
p-rx: 1d96f81 | pmichaud++ | src/stage0/ (4 files):
Update bootstrap.
p-rx: 610d80c | pmichaud++ | (4 files):
Bump PARROT_REVISION, rebuild bootstrap with full pasm constants.
p-rx: f4ffc61 | pmichaud++ | (4 files):
Bump PARROT_REVISION, update bootstrap to get latest CONTROL_EXIT fixes.
08:19 jaldhar left, jaldhar joined 08:21 xabbu42 joined, xabbu42_ joined, xabbu42 left, xabbu42_ is now known as xabbu42 08:22 isBEKaml joined 08:28 isBEKaml left 08:50 gfx left 08:54 Ross joined 08:55 meppl joined
pugssvn r31143 | pmichaud++ | [t/spec]: Fudge a test for Rakudo. 08:56
08:59 Su-Shee joined
moritz_ good morning 09:05
jnthn (or anybody else on windows) could you please try if you get the same error as www.perlmonks.org/?node_id=843317 ? 09:13
09:26 pmurias joined
pmurias ruoso: ping 09:26
pugssvn r31144 | moritz++ | [t/spec] test for RT #75434, guillemot not parsed in modules 09:28
09:31 TiMBuS joined
pugssvn r31145 | moritz++ | [t/spec] remove outdated test 09:31
r31146 | moritz++ | [t/spec] remove a package; fossile 09:34
09:39 patrickas joined
patrickas good morning perlsixers 09:39
moritz_ good morning p6trickas :-) 09:40
patrickas boss \o/
moritz_ always feels like an imposter when called "boss" :-) 09:41
patrickas sorry! ... boss! 09:42
I am getting near the end with the advent calendar
still have a coupl eof unresolved issues that I am tracking I'll letyou know when done ... 09:43
most important is the one liner in day 23, seems like it only works with pugs, don't know what should be done about it
maybe just mention that in th epost and leave it at that 09:44
moritz_ that's always an option
patrickas I was thiking about the MAIN and USAGE thingies, do you think I can help integrate them into rakudo or is it way out of my league ? 09:46
moritz_ it's something for which we need some advice from jnthn++ or pmichaud++ 09:48
www.unexpected-vortices.com/docs/de...start.html 09:49
09:51 patrickas left 09:52 patrickas joined 09:53 JimmyZ left
patrickas humm ok then i'll bug them about it when they have some free time :-) 09:53
moritz_ we've had some discussion about it, but I don't think we've reached a conclusion 10:00
patrickas ok. 10:01
moritz_ rakudo: class A { multi method a() { }; multi method a() { } } 10:06
p6eval rakudo c0efe0: ( no output )
moritz_ jnthn++
that is RT #75432, and looks resolved now 10:07
patrickas I remember I needed tha once but I forgot why! 10:09
rakudo: class A { multi method a() { }}; use MONKEY_TYPING; augment class A { multi method a(Int $b) { } } 10:11
p6eval rakudo c0efe0: OUTPUT«===SORRY!===␤A method named 'a' already exists in class 'A'. It may have been supplied by a role.␤»
moritz_ oh
used the wrong line :(
10:15 masak left 10:17 radu_ joined
radu_ hey 10:19
patrickas hello radu_
radu_ i have a question... 10:21
i was looking through the test files in the pugs repository and i ran across a call to eval_lives_ok, but i can't find such a function in the test module 10:22
am i looking in the wrong place or is this an error?
patrickas line 178
in Test.pm
10:39 xomas_ joined 10:44 xabbu42 left 10:47 xomas_ is now known as xomas 10:50 whiteknight joined 10:58 am0c joined 11:03 Ross left, azert0x joined 11:10 agentzh joined 11:12 jaldhar left, jaldhar joined 11:15 isBEKaml joined 11:19 ruoso left
patrickas rakudo: my %r = [^8]>>.fmt("%03b") Z (0,1,1,1,1,0,0,0);say (my @i = 0 xx 9,1,0 xx 10);for ^8 { say ( @i = 0, ( map { %r{ @i[$_-1] ~ @i[$_] ~ @i[$_+1] }}, 1..^19 ) , 0 ) } 11:31
p6eval rakudo c0efe0: OUTPUT«00000000010000000000␤00000000111000000000␤00000001100100000000␤00000011011110000000␤00000110010001000000␤00001101111011100000␤00011001000010010000␤00110111100111111000␤01100100011100000100␤»
patrickas \o/ 11:32
pugs: my @i = (1,2,3);say @i[-1];
p6eval pugs: OUTPUT«3␤»
patrickas rakudo: my @i = (1,2,3);say @i[-1];
p6eval rakudo c0efe0: OUTPUT«Cannot use negative index on arrays␤ in 'Array::postcircumfix:<[ ]>' at line 2582:CORE.setting␤ in main program body at line 11:/tmp/8rQUrtRdmT␤»
patrickas who's at fault here ?
rakudo: my @i = (1,2,3);say @i[*-1]; 11:33
p6eval rakudo c0efe0: OUTPUT«3␤»
patrickas rakudo: rakudo: my @i = (1,2,3);say @i[*+1];
p6eval rakudo c0efe0: OUTPUT«===SORRY!===␤Confused at line 11, near "rakudo: my"␤»
patrickas rakudo: my @i = (1,2,3);say @i[*+1];
p6eval rakudo c0efe0: OUTPUT«␤»
11:33 ruoso joined 11:39 Ross joined
colomon patrickas: rakudo is correct 11:44
negative indices have been banned from p6 11:45
patrickas What is the reason ?
would anyone expect anything else form a negative index ?
s/form/from/
11:45 satyavvd joined
colomon My impression is they were considered a horrible hack. Also, consistently supporting the *-1 approach is more flexible. 11:47
but I wasn't around when the actual discussions occurred.
patrickas unfortunately *+1 is not suported
so it looks kind of asymetrical... 11:48
colomon (more flexible: for instance, * / 2 is now a valid and frequently sensible index)
* + 1 is certainly supported
it's two past the end of the array
patrickas rakudo: rakudo: my @i = (1,2,3);say @i[*+1];
p6eval rakudo c0efe0: OUTPUT«===SORRY!===␤Confused at line 11, near "rakudo: my"␤»
patrickas rakudo: my @i = (1,2,3);say @i[* + 1];
colomon typing rakduo: twice is not support. :)
p6eval rakudo c0efe0: OUTPUT«␤»
colomon rakudo: my @i = (1,2,3); @i[* + 1] = 10; say @i.perl 11:49
p6eval rakudo c0efe0: OUTPUT«[1, 2, 3, Proxy.new(), 10]␤»
patrickas ok
it s does feel a bit strange, but I guess change always does. I suppose it'll grow on me 11:50
colomon rakudo: my @i = (1,2,3);say @i[* / 2];
p6eval rakudo c0efe0: OUTPUT«2␤»
patrickas ok that's a worthwhile advantage 11:51
cellular automata rule 30 in rakudo :-) 11:54
rakudo: my %r=[^8]>>.fmt("%03b") Z 30.fmt("%08b").split('').reverse;say (my @i = 0 xx 9,1,0 xx 9);for ^9 {say (@i=map {%r{ @i[($_-1)%19,$_,($_+1)%19].join }},^19)}
p6eval rakudo c0efe0: OUTPUT«0000000001000000000␤0000000011100000000␤0000000110010000000␤0000001101111000000␤0000011001000100000␤0000110111101110000␤0001100100001001000␤0011011110011111100␤0110010001110000010␤1101111011001000111␤»
patrickas also map in void context is allowed to be a noop ? 11:57
even if it has side effects ?
jnthn No, the void (akshually "sink") context is meant to make the map actually execute. 12:02
But NYI.
patrickas oh ok thx jnthn
jnthn moritz_: www.perlmonks.org/?node_id=843317 - can re-produce this here. WTF?! 12:04
patrickas same here 12:09
12:10 satyavvd left
dalek kudo: 24a823f | jonathan++ | t/spectest.data:
Turn on integration/advent2009-day18.t; patrickas++.
12:11
patrickas actually say +$num is giving me 0
jnthn Turns out chomp was clueless about Windows line endings. 12:14
patrickas also I noticed another unrelated thing, on windoes we are not chomping \r
jnthn Let's see if fixing that helps.
patrickas whoa!
jnthn I think they may be related.
patrickas I don't know
I tried manually setting the string to "6\r" 12:15
jnthn Fixing the chomping would be a good thing, anyway.
patrickas and it did not change lcoally
should definetely be fixed regardless :-)
trimming seems to fix it 12:16
actually just stringifying it removes the issue! doesn't prompt return a Str already ? 12:17
jnthn Please write a number : 5
5
8
\o/
patrickas: Not sure - fixing chomp seems to have helped though.
Probably this fixes another test fail I've had for a while on Windows due to the same issue too. 12:18
jnthn spectests
12:18 azawawi joined
azawawi hi 12:18
isBEKaml uh, jnthn, how come it works for nums > 10 or so like the op says in perlmonks?
patrickas ahlan azawawi 12:19
azawawi :) 12:20
12:20 Ross left
jnthn isBEKaml: I...hate to imagine. 12:21
isBEKaml: Still trying to fathom that one.
I guess a number parsing code quirk. 12:22
12:23 isBEKaml left 12:24 isBEKaml joined
isBEKaml jnthn: weird, but he also says that it works with parrot 1.7 or so.. :/ 12:25
jnthn isBEKaml: That coulda been on Rakudo alpha too, though. I think chomp was less broken there. 12:26
isBEKaml jnthn: yeah, weird. 12:28
patrickas I am afraid fixing the chomp could have just masked the problem 12:29
gist.github.com/427555
"readline" is in parrot right ? what does it return ? 12:32
jnthn patrickas: We have a readline in IO.pm which is what calls .chomp on the string. 12:33
rakudo: say +"3" 12:34
p6eval rakudo c0efe0: OUTPUT«3␤»
jnthn rakudo: say +"3 "
p6eval rakudo c0efe0: OUTPUT«3␤»
12:34 dual left
jnthn rakudo: say +"3x" 12:34
p6eval rakudo c0efe0: OUTPUT«3␤» 12:35
jnthn rakudo: say +"3\r"
p6eval rakudo c0efe0: OUTPUT«3␤»
jnthn rakudo: say +pir::set__sp("3\r")
p6eval rakudo c0efe0: OUTPUT«0␤»
jnthn Aha.
Parrot strings numify differently to Perl 6 ones. :-/
patrickas oh ok 12:36
jnthn So that's The Other Issue.
chomp still needs fixing though.
patrickas yes definetely
cosimo i'd like a new project to be added to proto \o/ 12:38
github.com/cosimo/perl6-puppet-parser 12:40
jnthn needs to pop to the shop...bbiab
patrickas what are Puppet modules ? 12:42
isBEKaml wha... Cool-str.pm only identifies "\n" in chomp? I see why chomp needs fixing. jnthn++
pugssvn r31147 | radus++ | [t/spec] Added tests for RT 65022 - Nested classes declared inside different classes cannot have the same name. 12:44
patrickas cosimo: I added perl6-puppet-parser ... it should show up on the proto.perl6.org in a couple of hours (unless I broke something) 12:46
rakudo: say +pir::set__sp("13\r") 12:49
p6eval rakudo 24a823: OUTPUT«13␤»
cosimo patrickas: thanks
patrickas rakudo: say +pir::set__sp("3foo")
p6eval rakudo 24a823: OUTPUT«0␤»
patrickas rakudo: say +pir::set__sp("13foo")
p6eval rakudo 24a823: OUTPUT«13␤»
cosimo patrickas: this puppet here, docs.puppetlabs.com/ 12:50
patrickas cosimo: I would have called the module perl-6-puppet-master instead ;-) 12:51
cosimo :)
isBEKaml rakudo: my $str = " yabba dabba doo "; $str.chop.perl.say; 12:52
p6eval rakudo 24a823: OUTPUT«" yabba dabba doo "␤»
isBEKaml uh, what's chop supposed to do? I believed it was for removing trailing/leading whitespaces...
patrickas rakudo: my $str = " yabba dabba doo"; $str.chop.perl.say; 12:53
p6eval rakudo 24a823: OUTPUT«" yabba dabba do"␤»
patrickas chop removes the last character
no matter what it is
chomp removes end of line character
trim removes the whitespaces
isBEKaml rakudo: my $str = " yabba dabba doo "; $str.trim.perl.say;
p6eval rakudo 24a823: OUTPUT«"yabba dabba doo"␤»
isBEKaml I see.. patrickas++ :) 12:54
12:54 [Coke] left 12:56 pugssvn left
patrickas anyone knows where the parrot devs hangdout ? 12:56
isBEKaml #parrot?
irc.parrot.org, IIRC.
patrickas thanks, I had the wrong server :-)
isBEKaml I made that mistake once too. then I checked in parrot.org. :) 12:57
12:57 patrickas left 12:59 patrickas joined
patrickas heheh i accidentaly disconnected my self :-) 12:59
patrickas is not only a perl6 noob but an irc noob too :-)
13:00 radu_ left
isBEKaml is noobier than patrickas. (if noobier counts as a word. ;) 13:00
patrickas we're like the blind leading the blind :-) 13:02
isBEKaml until the Elders turn up. :)
The Elders of Perl6oren. 13:03
dalek kudo: 53da4c1 | jonathan++ | src/core/Cool-str.pm:
Fix chomp to handle Windows newlines too.
13:04
patrickas I guess that means time to build :-) 13:08
azawawi Juerd: ping 13:10
isBEKaml I don't understand why some file methods are defined in Str.pm and some more in Str.pir. It seems very awkward to me... 13:11
methods s(), d() and f() in Str.pm and e(), l() in Str.pir.
13:12 azawawi left
patrickas isBEKaml: no idea, I would have expected things in Str.pm to be in perl6 and tings in Str.pir to be in PIR but apparently not 13:14
isBEKaml patrickas: I was more like, if these are file methods, I would have expected these to be in one location than defined in different files. 13:15
13:21 JimmyZ joined, masonkramer left, masonkramer joined 13:30 dju left
isBEKaml afk #errands, bbl o/ 13:33
patrickas \o
13:42 JimmyZ left, dakkar joined 13:45 Sarten-X joined 13:58 dual joined 14:16 pyrimidine joined 14:19 fridim left
jnthn patrickas,isBEKaml: Once upon a time the only built-ins were done in PIR. There's still various things that could be in the Perl 6 setting that currently are not. 14:22
(Because they didn't get ported yet).
pmurias ruoso: ping # i should really get round to writing that email instead of ping, but one last try won't hurt 14:25
jnthn church & 14:27
14:31 pyrimidine left, c9s left, pyrimidine joined 14:32 pyrimidine left 14:39 am0c left
masonkramer what the heck is a perl6 slang? iow, which synopsis should I read on that? 14:42
14:43 rv2733 joined 14:44 kraai joined
pmurias masonkramer: S02 14:47
masonkramer: use ack on the synopsis to find the right one
masonkramer 's brain explodes 14:49
pmurias so you found the part about slangs? 14:51
masonkramer I can't talk, my brain is asploded 14:52
(yes)
14:53 am0c joined
moritz_ back 14:58
jnthn: re numification of strings from IO - those seem to be parrot String things, not Perl 6 Str objects - at least .PARROT produces String, not Str 14:59
15:04 pmurias left 15:13 dju joined
cosimo any idea why this fails? 15:13
paste.lisp.org/display/111195
15:13 _jaldhar joined
cosimo I'm trying to invoke some pir functions, but the result is sub '_md5_print' not found 15:13
15:14 jaldhar left
cosimo i tried every possible monkey-generated combination of get_hll_namespace, get_hll_global, find_method, etc... 15:14
moritz_ I wonder if load_bytecode succeeded 15:15
does it fail loudly if you put in some fantasy name
cosimo hmm
yes, it complains "load_bytecode" couldn't find Digest/MD6.pbc 15:16
moritz_ hrm
cosimo i supposed the problem is that _md5_print is in the Digest namespace
but I can't seem to get at the real methods
moritz_ get_hll_global ['Digest'], '_md5_print' 15:18
cosimo tried that, but it doesn't work 15:19
Null PMC access blah blah
moritz_: how would I invoke that if I got something? 15:20
moritz_ $P0($args)
cosimo moritz_: right, but even a simple "say" of the result gives me Null pmc access 15:21
avar moritz_: I fixed the error message 15:22
github.com/avar/rakudo/compare/fix/...kage-error 15:25
moritz_ cosimo: I don't undertand it... examples/library/md5sum.pir works just with _md5sum 15:27
cosimo moritz_: i tried to even include the onload code to set the _md5_print global, but no way
moritz_: works for me too 15:28
the md5sum.pir i mean
I need to go now, bye 15:33
moritz_ ciao
dalek kudo: a3de524 | (Ævar Arnfjörð Bjarmason)++ | src/Perl6/Grammar.pm:
Fix 'package Foo;' error so that it suggest a Perl 6 alternative

didn't suggest what syntax to use instead. Explain that you should use package blocks, or the module declaration syntax. Signed-off-by: Moritz Lenz [email@hidden.address]
15:35
moritz_ avar++
not only complaining, but actually patching! 15:36
pmichaud good morning, #perl6
15:37 xinming_ joined
moritz_ hi 15:37
avar WHINE WHINE WHINE
moritz_: yeah, now that it's actually possible since rakudo isn't in svn :) 15:38
(it's been a while)
moritz_ even with svn you can submit patches... but I know what you mean
avar yeah, but it's so hard you never bother for stuff like this
pmichaud yummy patches! 15:39
avar wasn't parrot moving to git?
15:39 xinming left
moritz_ avar: yes, but after gsoc 15:39
pmichaud until then we're all just doing "git svn" :-P 15:40
moritz_ ... which combines some of the svn drawbacks with most of the git drawbacks 15:41
pmichaud yes, but (for me at least) it's still better than straight svn.
avar yeah, git svn is horrors
even cvs is better than straight svn :)
pmichaud of course, I don't do much branching with git svn
moritz_ btw t/spec/S03-smartmatch/capture-signature.t fails to compile for me 15:42
I've just commited a fix for line endings 15:43
but it doesn'T change anything
and previously it was touched in April
so something in rakudo or parrot broke it
15:52 xabbu42 joined, xabbu42_ joined, xabbu42 left, xabbu42_ is now known as xabbu42
lue ohai morning o/ 16:05
16:12 patspam joined 16:13 Ross joined
lue rakudo: say 10000000[1] 16:14
p6eval rakudo 53da4c: OUTPUT«Method 'postcircumfix:<[ ]>' not found for invocant of class 'Int'␤ in main program body at line 1␤»
16:15 TiMBuS left
pmichaud moritz_: yes, capture-signature.t doesn't seem to be working with latest parrot. It works with r47382 16:20
bisecting now 16:23
lue rakudo: *.defined 16:26
p6eval rakudo 53da4c: ( no output )
16:27 plobsing joined
lue rakudo: say (1, undef, 2, 3).grep(*.defined).perl 16:27
p6eval rakudo 53da4c: OUTPUT«===SORRY!===␤Unsupported use of undef as a value; in Perl 6 please use something more specific:␤ Mu (the "most undefined" type object),␤ an undefined type object such as Int,␤ Nil as an empty list,␤ *.notdef as a matcher or method,␤ Any:U as a type constraint␤
.. or fail() as a failur…
patrickas lue undefined is gone 16:29
rakudo: say (1, Mu , 2, 3).grep(*.defined).perl
p6eval rakudo 53da4c: OUTPUT«Nominal type check failed for parameter '$topic'; expected Any but got Mu instead␤ in 'Bool::ACCEPTS' at line 1223:CORE.setting␤ in 'infix:<~~>' at line 347:CORE.setting␤ in 'Iterator::perl' at line 1314:CORE.setting␤ in main program body at line 11:/tmp/R5vF018TXS␤»
patrickas this should have worked ... :-)
rakudo: say (1, Nil , 2, 3).grep(*.defined).perl
p6eval rakudo 53da4c: OUTPUT«(1, 2, 3)␤»
patrickas I think there is some bug retated to whatever not working with Mu 16:30
lue I know, I just copy n pasted from a ticket 16:31
rakudo: say 3 ~~ *; say Mu ~~ * 16:32
p6eval rakudo 53da4c: OUTPUT«1␤Nominal type check failed for parameter '$topic'; expected Any but got Mu instead␤ in 'Whatever::ACCEPTS' at line 4036:CORE.setting␤ in 'infix:<~~>' at line 347:CORE.setting␤ in main program body at line 11:/tmp/4WC56LTqT3␤»
16:32 justatheory joined
patrickas oh ok 16:33
lue hrm, lets look at the source code 16:34
well, I can't find in the source code if it has to accept Any $topic, instead of any $topic [Note capitalization!] 16:39
s/source code/spec/ 16:40
pmichaud r47400 fails
lue :( 16:41
pmichaud trying 47390
isBEKaml jnthn: (sorry for the late reply) Well, I didn't know we could learn history in #perl6! xD Any way I could do something so we don't have to get all bent in the future? ;) 16:43
16:44 agentzh left
isBEKaml (if at all, please do point me as to what I have to do ) 16:44
moritz_: (backlogging) svn doesn't do what we need with patches? svn diff -x -u for unified diffs, still version mismatches are a possibility. :( 16:46
16:49 tedv joined
pmichaud ick, bisecting parrot isn't going to work. Some of the intermediate parrots have other bugs that prevent me from finding the capture-signature.t one. 16:51
lue back from email land 16:53
I have the bad habit of letting my email sit for a couple of days, and then getting 300 emails to sort through :) 16:54
isBEKaml pmichaud: parrot test suite is in a different svn location? I don't find it with my parrot local checkout. I'm at r47414, fyi.
pmichaud: *it -> capture-signature.it 16:55
pmichaud isBEKaml: I don't quite understand the question.
capture-signature.t is in the perl 6 test suite
t/spec/S03-smartmatch/capture-signature.t
isBEKaml pmichaud: Ah, well. since you said bisecting parrot, I was a little confused.
pmichaud right
some change to parrot in the last 24 hrs has caused that test to start failing in rakudo. 16:56
I'm trying to find which parrot change causes the failure.
isBEKaml pmichaud: ok.
pmichaud: uh, that particular test passes with parrot at 47417. :? 17:04
17:05 eternaleye left
isBEKaml pmichaud: and rakudo at c0efe0 17:06
or this is with the latest version?
pmichaud it passes at 47417? 17:09
pmichaud checks. 17:10
it passes at 47388
pmichaud tries 47417
lue rakudo: say 1..{$_} # checking a ticket 17:13
p6eval rakudo a3de52: ( no output )
diakopter sorear: + in perlesque operates on value types 17:15
or between a value type and an object type that has an implicit cast to that value type 17:16
the compiler (runsharp) determines the best "overload"
sorear: to answer your other question, the IR while perlesque is compiling is represented by TypeGens and RoutineGens (RunSharp objects) 17:18
pmichaud isBEKaml++ # r47417 _does_ work!
that's good, I can bisect from there a bit better.
isBEKaml \o/ 17:19
pmichaud thanks for finding that... I might've been lost for quite a while w/o it
tedv So a week or two I was looking for introductory dev work and someone suggested writing a more complete spec for Compact structs (in S09)
diakopter sorear: so when you ask how to "see" these objects, I should ask "for what purpose?" or "how would you like these objects presented?" so I can come up with a way to serialize/output them
isBEKaml pmichaud: searching svn logs is a bit of a pain, imho. nevertheless, you're welcome. :) 17:20
tedv I had a number of ideas, but it seemed proper to have a discussion with People Who Know More Than Me(tm) first, and I'm not sure which mailing list is the right place.
is this better suited to the language list, the compiler list, or something else?
pmichaud spec generally belongs on the language list 17:21
lue I would say p6l is better suited (the language list)
tedv that's the bikeshed list, right? :)
pmichaud it does do that sometimes, yes.
diakopter bring lots of paint 17:22
lue can't wait for the demolition order against that bikeshed :)
tedv Also, is there a section of the spec that deals with data serialization of structs?
lue (And the poor grass surrounding it; it's a rainbow of colors, except for green :( ) 17:23
tedv which seems closely related to compact structs but not exactly the same
isBEKaml lue: that's colourful! ;)
tedv ie. encoding variable length fields is required for serialization, but confuses compaction
diakopter tedv: do you recall who suggested making that specification more ... specific? 17:24
lue afk
tedv It might have been moritz. Would have to check the logs
I originally wanted to write some spec tests for pack()
but mentioned that there wasn't a solid spec for pack, as best I could tell
and he said there was some intersection between it and compact structs, which hadn't been ironed out or something 17:25
when I mentioned that compact structs also were a little vague in their descriptions, he suggested I write a more solid interface for it.
it might have been pmichaud, but it was either him or moritz. 17:26
jnthn pmichaud: oh hai - capture-signature.t is broken? 17:27
pmichaud: What's the failure mode? 17:29
17:29 am0c left
pmichaud can't find $a 17:31
r47421 passes
trying r47424 17:33
jnthn Oddness
pmichaud: Sounds like a parsing-ish error though.
pmichaud yes, it does appear to get different parses. I don't really have any clue *why* it would do that, though.
jnthn :S
No, none of the patches, having glanced them, look immediately suspicious. 17:34
17:34 Sarten-X left
jnthn pmichaud: Signature parsing uses ** 17:36
pmichaud here's a somewhat golfed version: nopaste.snit.ch/20995
the ** changes are pretty old, though -- definitely before r47417 (which appears to work fine)
jnthn Ah, OK
Then, I'm kinda stumped. 17:37
pmichaud yeah, I'm wondering if it's a hash-ordering sort of bug. :-|
jnthn That woulda been the obvious place where things coulda gone awry.
Oh noes.
Ah well, at first when I read what test was broken I was vaguely terrified because I know how that lot works under the hood. :-) 17:38
pmichaud aha, it does appear to be a parsing bug
jnthn So I'm not rather relieved that it seems to be compile bug rather than runtime.
pmichaud in one parse it's treating :($a) as a colonpair, in another as a sigterm
jnthn (It does...erm...beautiful evil)
Oh.
That would indeed break things.
I wonder if we were just getting lucky. 17:39
std: :($a)
p6eval std 31152: OUTPUT«Encode::encode_utf8() called too early to check prototype at STD.pm line 17.␤ok 00:01 108m␤»
pmichaud uh oh, STD borken.
jnthn pmichaud: I think that's just a warning.
pmichaud oh, okay 17:40
jnthn pmichaud: Note the "ok" at the end.
pmichaud yeah, I see the 'ok' now.
jnthn std: lol broken +
p6eval std 31152: OUTPUT«Encode::encode_utf8() called too early to check prototype at STD.pm line 17.␤===SORRY!===␤Prefix requires an argument at /tmp/KOnDdIi7lo line 1 (EOF):␤------> lol broken +⏏<EOL>␤Parse failed␤FAILED 00:01 105m␤»
jnthn Yeah.
pmichaud: Wonder if our colon pair parsing is too liberal.
And up to now we just got lucky with some ordering of trying parsing rules. 17:41
pmichaud: Especially, could "
":my" in regexes is now properly declarative for LTM purposes."
have meant things LTM differently?
pmichaud huh
not in this case
jnthn OK.
pmichaud since there aren't any :my's involved in the relevant rules
okay, so.... 17:42
token term:sigterm { <sigterm> }
token term:colonpair { [ <colonpair> <.ws> ]+ }
in the case of :($a) -- what differentiates between these two?
sigterm is given as
jnthn Yeah, that's what I'm starting to wonder.
pmichaud ':(' ~ ')' <fakesignature>
and the relevant part of <colonpair> is 17:43
| :dba('signature') '(' ~ ')' <fakesignature>
jnthn STD has changed here I think, since I last saw it to.
pmichaud (these are from STD)
jnthn I don't see that :dba('signature') bit in colonpair?
pmichaud it's there 17:44
just a sec
17:44 am0c joined
jnthn | <coloncircumfix('')> 17:44
oh, so it is.
pmichaud are you looking at STD.pm6 or rakudo?
right, it's there.
jnthn STD.pm6. I was looking at precisely that rule too.
Just missed it. :-)
I don't really follow why that is there.
pmichaud so, it looks to me like either parse is valid.
jnthn Do we parse a signature there in Rakudo? 17:45
pmichaud sometimes, apparently
sometimes we go through <sigterm>, sometimes through <colonpair>
jnthn wait a mo...
pmichaud: Aha.
pmichaud: In Rakudo's grammar, we don't try to parse a signature there. 17:46
So instead we hit circumfix.
pmichaud ?
I'm looking at rakudo's parse(s), and don't see that.
just a sec
jnthn See colonpair in Rakudo.
17:46 Ross left
pmichaud okay 17:47
jnthn We're missing the signature case that STD has.
pmichaud so, the question somewhat remains -- do we still need <sigterm>?
jnthn I'm sure it hadn't use to have that.
pmichaud (does STD.pm still need sigterm?)
jnthn It's referenced from places other than term, I think.
ah, yes
token sublongname {
<subshortname> <sigterm>?
}
pmichaud okay, I really meant (unclear) do we need term:sigterm ?
jnthn But it feels like a bit of a wtf.
Not if we're going to parse it in colonpair 17:48
But that feels...wrong. :-S
pmichaud if term:colonpair already captures it, then...
yeah
jnthn That bit of STD feels like a total hack to me, fwiw.
I don't even get why it would prefer the signature case other the circumfix case right below it.
pmichaud well, because it comes first.
jnthn Oh, LTM tie-breaks on that? 17:49
pmichaud (fallback in ltm is whichever one is declared firs... yeah)
jnthn Right, Ok
Not quite so hacky then.
But still parsing sigterms in colonpair is a bit weird.
It'd work though.
I figure we've just been getting lucky up to now.
Note Rakduo's colonpair starts with:
:my $*key;
:my $*value;
pmichaud aha 17:50
jnthn Which hadn't used to be declarative.
pmichaud that would indeed do it.
17:50 azert0x left
jnthn So colonpair had an empty LTM prefix I guess. 17:50
pmichaud previously, yes. 17:51
17:51 Sarten-X joined
pmichaud and then we got lucky for a bit after fixing the :my stuff. 17:51
jnthn Yeah
OK, I think we have an explanation at least.
pmichaud well, I want to get rid of either term:sigterm or the signature portion of colonpair. Preference?
jnthn pmichaud: I don't think it's that easy. 17:52
(more)
If we keep sigterm, I don't see how that won't be ambiguous with :($a) as a colonpair.
So I'm not sure we have a choice as such. 17:53
I think it'll have to go in colonpair.
pmichaud I can fix it so that colonpair doesn't parse :($a)
jnthn std: my $op_name; &infix:($op_name) 17:54
p6eval std 31152: OUTPUT«Encode::encode_utf8() called too early to check prototype at STD.pm line 17.␤ok 00:01 107m␤»
pmichaud okay
jnthn pmichaud: Then we can't parse ^ though.
pmichaud so, yes, it has to go in colonpair.
jnthn I fear so. But it's kinda ugly.
pmichaud not really
at least, I don't see it as being that ugly.
jnthn Well, ugly is the wrong word. Just feels strange to me. :-) 17:55
Anyway, +1 to kill sigterm.
pmichaud if signatures are generally colonpairs, it fits for me.
jnthn Or, in the alternative, to just call <sigterm> from colonpair.
oh
that won't work
sigterm wants the colon
pmichaud right
jnthn
.oO( everything wants the colon)
17:56
pmichaud I could get term:sigterm to be preferred over term:colonpair
but we still need to be able to parse sigterms in colonpair
so...
I'll start by fixing colonpair
jnthn sigterm dies.
colonpair parses it.
Let's go with that, unless we find it won't work.
token term:sym<sigterm> { <sigterm> } 17:57
Is the only use of <sigterm> in Rakudo's grammar.
STD only has one other usage of it anyway
17:57 pnate left
pmichaud once I get to bump PARROT_REVISION, we'll have a working exit() 17:57
(from interactive mode)
jnthn Oh, nice.
.oO( damm, now I can't re-live my visual basic glory days with constant loop = 64; exit loop; )
17:58
pmichaud and we'll be using real pasm constant symbols instead of the numeric constants
jnthn \o/
Cool. We can clear up the nasty in backtraceprinter. 17:59
moritz_: BTW, may be worth noting on www.perlmonks.org/?node_id=843317 that I fixed the bug earlier today.
18:00 envi^home left
patrickas jnthn the related behaviour from parrot is bug too right? not just a different way of converting strings to nums 18:01
jnthn patrickas: Quite possibly, yes.
patrickas: Well, maybe not though
patrickas: Parrot doesn't need to have the same number parsing semantics as Perl 6.
patrickas: The problem is more than we end up with Parrot strings.
patrickas yes but the behaviour of parrot does not make sense regardless of perl6 18:02
rakudo: say +pir::set__sp("6foo") 18:03
p6eval rakudo a3de52: OUTPUT«0␤»
patrickas rakudo: say +pir::set__sp("16foo")
p6eval rakudo a3de52: OUTPUT«16␤»
jnthn Yeah
patrickas this seems odd no matter how you look at it
jnthn May be worth a Parrot ticket.
It looks very much like a bug rather than intended behavior. 18:04
That or somebody has weird intentions. :-)
patrickas heheh you can never discount that possibility
pmichaud nqp: say(+"6foo") 18:07
p6eval nqp: OUTPUT«0␤»
pmichaud nqp: say(+"16foo")
p6eval nqp: OUTPUT«16␤»
pmichaud ...huh. 18:08
18:08 pnate joined
pmichaud nopaste.snit.ch/20998 # Parrot weird numification 18:09
it's apparently been that way, like, forever. 18:10
18:13 am0c left
pmichaud Filed as trac.parrot.org/parrot/ticket/1674 18:17
apparently worked as of 1.0.0, though. 18:18
From method sigterm($/): 18:19
make $<fakesignature>.ast.ast;
...?!
sorear diakopter: I'd like to see them for the purposes of better understanding what's happening to the code
jnthn pmichaud: ya rly 18:21
pmichaud: $<fakesignature>.ast gets you a Perl6::Compiler::Signature object. 18:22
pmichaud that just looks so wrong
jnthn I probably shoulda called the .ast method of Perl6::Compiler::Signature something else but, well, it produces the AST. ;)
pmichaud seems to me that $<fakesignature>.ast should get you the ast, not the P:C:S 18:23
jnthn I'm pertty sure we don't want it to at that point.
Sometimes we need to do away with the signature and just make a list of the variables declared in it, for example. 18:24
pmichaud so, the issue is that $<signature>.ast returns the P:C:S
jnthn "issue" :-)
pmichaud yes, in air quotes
jnthn I did for a little while ponder monkey-patching PAST::Compiler to know what to do with a P::C::S. 18:25
But that felt...even more evil.
pmichaud no, that would be evil.
(yes, more evil)
I don't mind that $<signature>.ast returns a P:C:S so much, but it seems odd that $<fakesignature>.ast does so. 18:26
We never use the P:C:S from a fakesignature, afaict
anyway, shifting fake signature parsing into colonpair appears to have corrected the bug
jnthn You're right, we use it only from sigterm.
pmichaud spectesting now
jnthn Well, "used" now I guess. :-) 18:27
jnthn ponders what he wants for dinner
pmichaud time for a walk while spectest runs
jnthn :-)
18:29 ashleydev_ left
jnthn afk, nomhunt 18:32
18:37 Guest50061 left 18:47 patspam left
pmichaud pmichaud@plum:~/rakudo$ ./perl6 18:56
> exit(1)
pmichaud@plum:~/rakudo$
\o/
mathw ooh
\o/
pmichaud++
pmichaud pmichaud@plum:~/rakudo$ ./perl6
> exit
pmichaud@plum:~/rakudo$
just getting that to work involved fixing far too many other things. :-) 18:57
colomon still, \o/
mathw also, those other things got fixed too 18:58
sorear my $x = { exit }
$x()
dalek kudo: 1bac469 | pmichaud++ | src/Perl6/ (2 files):
Move fake signature handling into <colonpair>, eliminate term:sigterm .
19:02
kudo: 3d19599 | pmichaud++ | build/PARROT_REVISION:
Bump PARROT_REVISION to get latest exit() fixes and improvements to pasm
avar What's the stuff that needs doing in rakudo these days? 19:10
19:16 hudnix joined
colomon avar: it feels like everything at the moment... 19:16
19:19 rv2733 left
pmichaud I'm currently reviewing the rt queue a bit 19:20
mathw \o/
colomon since when is there a fatrat.t? 19:21
(not that I'm complaining....)
mathw since somebody neede some tests for fat rats I suppose :) 19:23
colomon mathw: there's just one test, and all it does is make sure the FatRat constructor works. 19:28
19:28 patrickas left
colomon afaik, there's no implementation where that's true. 19:28
jnthn
.oO( FatRat tests too thin )
19:34
(RT) I worked out how hack the query string so that RT gives me the whole queue on one page. :-)
That's *very* nice. 19:35
pmichaud oh, I've had that for months :)
jnthn :P
Wish I'd thought to try it sooner. :-)
cognominal rakudo: class A is rw {} 19:37
p6eval rakudo a3de52: OUTPUT«===SORRY!===␤Could not find sub &chars␤»
moritz_ just go to the home page, click on the 'perl6' queue, and then sort by date descending
then you can change the limit in the URL
jnthn rakudo: pardon? :-) 19:39
p6eval rakudo a3de52: OUTPUT«===SORRY!===␤Confused at line 11, near "pardon? :-"␤»
19:40 patrickas joined, ashleydev joined
patrickas ping mathw 19:42
19:43 _jaldhar left, _jaldhar joined
mathw pong patrickas 19:44
dalek kudo: 7f2b754 | moritz++ | Test.pm:
[Test.pm] diagnostic output if is_approx fails
19:51
19:56 Chillance joined 19:57 aesop left 19:59 xinming joined 20:00 mberends left 20:02 xinming_ left 20:03 Psyche^ joined 20:04 Patterner left, Psyche^ is now known as Patterner 20:07 hudnix left, pmurias joined
pmurias hi 20:07
diakopter hi
]o[
pmurias that's a TIE fighter? 20:08
diakopter heh
20:09 whiteknight left
diakopter <o> # Rembaldi 20:09
20:10 hudnix joined
pmurias diakopter: how's your back? 20:11
20:15 whiteknight joined 20:16 patrickas_ joined 20:18 patrickas left 20:19 patrickas_ is now known as patrickas 20:21 kensanata joined 20:25 Su-Shee left 20:37 masak joined
masak ahojte. 20:37
masak sighs contentedly 20:38
20:39 aesop joined
jnthn ahoj, masak! 20:42
Ako sa mas?
masak jnthn! just the punster I was looking for. :)
very well, thanks.
jnthn Bra. :-)
masak just back from the wonderful Eden-like home of my parents. :P
(and boy are my arms tired.) 20:43
jnthn ...you swam back?
;-)
masak no. my arms are tired from holding the laptop all day on the bus.
the tray wasn't a good place to put it, for some reason. 20:44
pragma_ screams loudly.
masak hugme: hug pragma_
hugme hugs pragma_
pragma_ "Hi everybody, I just flew in from Jew Nersy! And boy, are my arms tired!"
jnthn masak: I hate those trays 20:45
masak: A lot of airplane ones a like that too.
masak pragma_: my arms *are* tired... :)
jnthn: this bus journey felt much like a flight, actually. especially the no wifi. :(
jnthn :( 20:46
jnthn tycker inte om flyggar
masak jnthn: I've been trying and failing with that byteview length thing. care to tutor me a little?
jnthn Got one on Friday.
masak that is entirely the wrong noun form. :P
but points for trying, of course.
jnthn Heh, I was going for plural. :-) 20:47
But I didn't bother to learn how to make those yet.
:-)
masak yeah, I got that. :)
jnthn What should it have been?
masak the rest of the sentence was fine.
hm.
'flyg' is the most simple fix. 20:48
jnthn (Was shooting for a translation of the English "I don't like flights"
)
masak 'att flyga' is probably slightly more colloquial.
then 'flyg'.
jnthn flyg is...plural?
jnthn thought that was the singular
masak it's a plural as well as a singular.
and that, dear #perl6, concludes today's Swedish lesson.
jnthn In today's wildly preproccessed C lesson, we tackle adding a VTABLE method to a PMC. 20:49
masak: What did you get so far?
masak :)
I tried adding a VTABLE INTVAL get_integer() 20:50
jnthn Oh
arnsholt jnthn: In Norwegian (and I'm pretty sure Swedish as well) neuter nouns are identical in the singular and plural indefinite
masak because I had gone with indexing so far.
jnthn I was expecting a VTABLE INTVAL elements() { ... }
patrickas I think operator overloading is kind of broken in rakudo (and maybe multi subs too) ... is that a known issue gist.github.com/427841 ?
jnthn patrickas: (without even looking) Yes
patrickas: It's on my "to fix" list. 20:51
masak arnsholt: not all of them, I think.
20:51 tedv left
sorear dalek? 20:51
oh
right
patrickas jnthn: ok thanks. cause the breakage is kind of massive and not something subtle :-)
sorear pugs
pugssvn-- not being here to ++ me 20:52
masak jnthn: I was actually thinking of switching from indexing to iterators, which seemed a bit more fitting to me. but I wouldn't know how to do that. anyway, the method I added didn't help much.
I could nopaste the encode() method and the byteview.pmc as they look locally, if that helps. 20:53
jnthn gist.github.com/427888
masak looks 20:54
jnthn OK, and that's a nopaste I just hacked up of what I was thinking or writing.
*of
arnsholt masak: Yeah, I think you're right now that you mention it
20:54 azert0x joined
masak arnsholt: I don't have an example handy. but it'll come to me, I'm sure. 20:54
arnsholt Indeed ^^
masak jnthn: ah! elements! 20:55
jnthn masak: Then you can do
dalek kudo: 4bc8125 | pmichaud++ | src/Perl6/Actions.pm:
Refactor circumfix:sym<{ }> as hash constructor, fixes RT #74050
kudo: 06723b4 | pmichaud++ | Test.pm:
Merge branch 'master' of github.com:rakudo/rakudo
jnthn $I0 = elements $dabuff
masak jnthn: I saw it in some places in other .pmc files, but didn't find a compelling example, nor hard proof that that was the way to get the length.
jnthn: I will try omedelbart. :) 20:56
jnthn masak: It's the canonical vtable method for number of array elements.
masak I'm sure.
I'm canonically ignorant of PMC internals. :) 20:57
but learning quickly.
jnthn pmurias: Nice patch!
er
pmichaud: Nice patch!
21:00 kensanata left 21:03 tlb joined, colomon left 21:12 Trashlord left
dalek p-rx: 820f547 | pmichaud++ | (2 files):
Empty angles "< >" return a list (see RT #73772).
21:16
pmichaud jnthn: (nice patch) ...which one? ;) 21:17
the hash constructor one? yes, I like that patch.
seems much cleaner now.
jnthn pmichaud: They're all good, but that was the one I was referring to, yes.
You look at the parse tree rather than the PAST, it seems. 21:18
pmichaud only for determining the number of statements
jnthn Ah, yes.
pmichaud that's really a parse-ish sort of thing anyway.
jnthn Yeah
I think we collapse empty statements to nothing in the PAST tree
pmichaud as we probably should :)
jnthn I seem to remember long back fixing a bug where you could get a nasty error by writing ;;
or "; ;" 21:19
Or some such
Empty statements, basically
pmichaud I did run into a complication with {;} also -- fixed it.
jnthn I'd have guessed switching to the parse tree dealt with that?
pmichaud not entirely
jnthn Ah, ok
pmichaud {;} still has one statement in it :)
(from a parse perspective)
jnthn Ah, yes. 21:20
pmichaud *really* wishes konsole weren't so broken.
jnthn masak: Any joy?
masak jnthn: it built. running tests now. 21:21
jnthn :-)
21:24 adityavs joined
masak jnthn: yes. joy. 21:24
\o/
preparing commit.
21:24 jferrero joined
masak all tests in t/spec/S32-str/encode.t now run locally. all 10 of them. 21:24
one fails. 21:25
21:25 adityavs left
masak er. two fail. there's a decoding test I don't get right yet either. 21:25
21:26 patspam joined
jnthn masak: yay progress :-) 21:28
afk for a little 21:30
21:32 [Coke] joined
masak I'll make the weekly merge to master now. this week has seen six commits to the buf branch; five by me and one by jnhtn++. 21:33
I don't remember how many tests we passed a week ago, but it's at least one more now, and no tests need to be skipped. 21:34
21:38 eternaleye joined, hercynium joined 21:41 _jaldhar left, _jaldhar joined
dalek kudo: 841262f | pmichaud++ | src/Perl6/Actions.pm:
Empty <> quotes with only whitespace should return empty parcel. (RT #73772)
21:47
avar is there a perl6 sqlite interface? 21:49
or some database wrapper? 21:50
masak yes.
there's squerl in Web.pm, and fakedbi. both are listed on proto.perl6.org/ 21:51
neither are very easy to find, admittedly. 21:52
s/are/is/
21:53 tedv joined
masak here comes this week's merge commit with master. 21:57
21:57 _jaldhar left 21:58 _jaldhar joined
masak I've once again deleted the 'buf' branch. those who have it cloned should probably delete it too, because next week we'll have a new one. :) 21:58
dalek kudo: 359dbdf | masak++ | (5 files):
[Buf] improvements to Str.encode

to the bytes in a Parrot string, pending the Parrot people's long-term solution. Thanks to it, we now do string encoding of UTF-8 strings right.
21:59
22:04 bjarneh joined 22:06 PacoLinux left
eternaleye You know, I never got a canonical answer as to whether ~~ Nil behaving like ~~ *.notdef was correct. It's what Rakudo currently says, and it's a lot prettier, so I _want_ it to be true. 22:10
22:11 pmurias left
masak Nil is just the name for (), the empty Capture. 22:11
pmichaud empty Parcel.
masak right. empty Parcel.
so I'd expect it to mean "is an empty Parcel/list thingy"
eternaleye rakudo: say 1 ~~ Nil; say Int ~~ Nil; say Nil ~~ Nil; say 1 ~~ *.notdef; say Int ~~ *.notdef; say Nil ~~ *.notdef;
p6eval rakudo 7f2b75: ( no output ) 22:12
eternaleye rakudo: say 1 ~~ Nil; say Int ~~ Nil; say Nil ~~ Nil; say 1 ~~ *.notdef; say Int ~~ *.notdef; say Nil ~~ *.notdef;
p6eval rakudo 7f2b75: ( no output )
eternaleye rakudo: say 1 ~~ Nil; say Int ~~ Nil; say Nil ~~ Nil;
p6eval rakudo 7f2b75: ( no output )
eternaleye Weird
Ooh, 1 ~~ *.notdef NULLPMC's here 22:13
masak ooh!
eternaleye But the first three (~~ Nil) give me 0\n1\n1 22:14
masak rakudo: 1 ~~ *.notdef
p6eval rakudo 7f2b75: ( no output )
masak Null PMC access locally here too.
wow, even the Null PMC access errors are nice nowadays! \o/ 22:15
jnthn++
eternaleye Try -e, to make sure it isn't the repl locally
masak I always do -e ;)
eternaleye OOH
masak I don't trust the REPL much.
22:16 tlb left
eternaleye pmichaud: masak: Parcel doesn't seem to appear in the smartmatch table 22:16
Juerd azert0x: redirect(email) 22:17
eternaleye rakudo: say Nil.defined 22:20
p6eval rakudo 7f2b75: ( no output )
eternaleye 0 locally, which conflicts with S02 22:21
masak aye.
known bug.
eternaleye Is load on feather high right now? All p6eval calls seem to be failing
masak g'night. 22:30
22:30 masak left 22:45 rgrau joined 22:49 dakkar left 22:52 patspam left 22:53 bjarneh left 22:58 patspam joined 23:01 colomon joined 23:02 jferrero left, orafu left, orafu joined 23:06 lestrrat is now known as lest_away
diakopter eternaleye: p6eval is not on feather 23:14
it seems the rakudo build is not operable
eternaleye Hm, thought it was on one of the feather VMs 23:15
diakopter no
jnthn diakopter: "not operable"?
diakopter rakudo: say 1 23:17
p6eval rakudo 359dbd: OUTPUT«1␤»
diakopter rakudo: say Nil.defined
p6eval rakudo 359dbd: OUTPUT«0␤»
diakopter rakudo: say 1 ~~ Nil; say Int ~~ Nil; say Nil ~~ Nil;
p6eval rakudo 359dbd: OUTPUT«0␤1␤1␤»
diakopter I guess the server was busy
seems back to normal now 23:18
eternaleye rakudo: say Nil ~~ *.notdef 23:22
p6eval rakudo 359dbd: OUTPUT«␤Null PMC access in find_method('params')␤ in 'Block::count' at line 4941:CORE.setting␤ in 'Block::ACCEPTS' at line 4949:CORE.setting␤ in 'infix:<~~>' at line 347:CORE.setting␤ in main program body at line 11:/tmp/ZOrRc6Gn1j␤»
eternaleye rakudo: (*.notdef).count 23:23
p6eval rakudo 359dbd: OUTPUT«␤Null PMC access in find_method('params')␤ in 'Block::count' at line 4941:CORE.setting␤ in main program body at line 11:/tmp/cW45gTrod4␤»
eternaleye rakudo: (*.Bool).count
p6eval rakudo 359dbd: OUTPUT«␤Null PMC access in find_method('params')␤ in 'Block::count' at line 4941:CORE.setting␤ in main program body at line 11:/tmp/OazqYnmgG0␤»
jnthn Ah, guess *.foo blocks are a bit busted still. 23:26
eternaleye rakudo: say ~(*.Bool).signature 23:27
p6eval rakudo 359dbd: OUTPUT«␤␤»
eternaleye jnthn: Might it be a symptom of rt.perl.org/rt3/Public/Bug/Display.html?id=69362 ?
jnthn rakudo: say (*-3).signature.perl 23:28
p6eval rakudo 359dbd: OUTPUT«:(;; Mu $x)␤»
jnthn eternaleye: It's another case of that one, yeah.
eternaleye: The way we make the *.foo is a little different.
23:35 jhuni joined 23:41 patrickas left 23:44 hercynium left 23:51 kloeri left 23:57 kloeri joined 23:59 patspam left
azert0x Juerd: sorry, i just sleeped on my keyboard. bad output, it seams. 'go to bed :s. good night all. 23:59