Think twice before running "make install" for Pugs | moritz.faui2k3.org/irclog/ | pugscode.org | sial.org/pbot/perl6 | ?eval [~] <m oo se> | We do Haskell, too | > reverse (show (scanl (*) 1 [1..] !! 4)) | "Perl 6 Today" video from YAPC::Asia: xrl.us/v6op
Set by agentzh on 6 May 2007.
polettix TimToady: this is where my English fooled me. I always thought that "rewrite of the community" meant something like "change the community by rewriting it" 00:00
dduncan looking in hindsight, as I never participated in that RFC process, it looked like they were just providing ideas that could influence you
TimToady basically, the RFCs all missed the fundamental unifications that we're hoping Perl 6 will provide
dduncan and the current p6l list and this channel are the modern equivalent of the RFCs
polettix even if it does little sense, probably, it was kinda suggestive 00:01
TimToady after sitting back on my heels for six months or so in shock, I decided I had to take the RFCs as "cries for help", but basically ignore most of the proposed solutions
Juerd It's no wonder they missed unification, as they were written asynchronously without sufficient inter-author-communication 00:02
TimToady and come up with a design that met the needs of the RFCs on a more fundamental level
you still see the malady frequently on p5p, where it seems like you can fix one aspect of p5 without fixing the others, but you can't really. 00:03
Juerd Fixing is impossible, adding new features is hard.
TimToady it would have taken centuries to achieve that level of inter-author-communication, given the nature of committees. :)
Juerd Fortunately, a fix can be seen as a new feature, which makes the impossible just hard.
TimToady: Absolutely. I'm thankful that you're such an efficient one man committee :) 00:04
dduncan all hail visionary benevolent dictators 00:05
TimToady not so efficient
Juerd I wonder how inter-timtoady-communication works :)
TimToady only in comparison to a multiheaded committee can I be construed as efficient.
Juerd That was the comparison :)
TimToady I really have no idea myself.
things just bubble up from the froth occasionally
mostly I just know when I have a gut feeling that there's probably a better solution out there somewhere 00:06
Juerd Isn't there always?
TimToady so I procrastinate the design creatively. :)
well, there's better and then there's Better
Juerd My point was that there is no Best. 00:07
TimToady a lot of these unifications just suddenly go "click" and it's better in more than just a quantitative way
Juerd But I [:i b]etter get some sleep now; have to get up early tomo^Wtoday.
TimToady at the moment I'm still worrying over the ugliness of @@() context, and why X maybe has the wrong default on for modifiers... 00:08
rhr how do you make svn accept a file that "has inconsistent newlines" (on purpose)
TimToady good night
dduncan rhr, mark it as a binary file
rhr how is that done?
dduncan I think that is how things are by default 00:09
at least, we have to explicitly say that things have unix line endings and unicode
rhr it's refusing my commit
Juerd Good night!
dduncan which is what all text files should be
TimToady or encode the inconsistency somehow and decode it right before using
dduncan I can assume it only has mixed line endings due to your wanting to do something tricky 00:10
rhr I'm trying to test unicode whitespace parsing
dduncan or test data
rhr so there's bare CR, LF, etc.
dduncan is the file valid unicode?
rhr yes, it's utf8 00:11
TimToady run it through a preprocessor before testing, and then you can document "here is CR ->"
rhr how would I do that?
TimToady perl's pretty good at text processing, I hear :)
dduncan I suggest that you could have a simple encoder/decoder ...
that has a \w-encoded something at the end of every line which says what ending char it conceptually is, and then put an actual unix line ending after that 00:12
rhr how do you eval a file in p6?
dduncan encoding or decoding such should be trivial
same as Perl 5
TimToady s/here is a CR ->\n/here is a CR ->\r/
the processor can be written in p5
rhr I don't know how to do that in p5 either :) 00:13
dduncan "do $filename;"
or some such
polettix is there pack/unpack in p6?
rhr sure, that part's easy, but how do I run the test after translating?
dduncan or alternately, slurp the file, then "eval $filedata"
rhr OK, that'll work 00:14
00:14 Daveman joined
dduncan I suppose that the 'make' process could generate the decoded file from the encoded one 00:14
and that generated file just isn't checked in
like a lot of temp files in Pugs
then make test works as normal, with the generated file 00:15
Pugs will parse pack/unpack like Perl 5's, but I don't know how much of it actually works 00:16
polettix it could be a way to do encoding/decoding, using H
dduncan the reason that having just the line ending encoded such as I or TimToady mentioned is that for most of the file you can do normal diffs and other ops, and it is easy to just make the encoded file the one that you are actually editing 00:17
TimToady pack/unpack isn't implemented yet in pugs
could call out to p5, but I'm thinking the whole generator script is p5 00:18
dduncan I'm thinking the generator is part of the build process, so would be Perl 5 for now, since the makefile et al is
TimToady, on a tangent, back when I suggested the Blob data type as being distinct from Str or Buf, one of its intended uses was as the output of pack, or input of unpack, since they conceptually work with otherwise undifferentiated bit strings 00:19
polettix dduncan: I see (now)
well, have a good morning/afternoon/evening/night/whatever, sleep for me :) 00:23
svnbot6 r16232 | rhr++ | Add unicode whitespace parsing tests (most fail at present) 00:39
rhr I got svn to accept my file :)
00:41 [particle] joined 00:43 obvio171_ joined 00:45 nipotaway is now known as nipotan 00:59 veritos joined 01:11 veritos left 01:15 TomDLux joined 01:18 dolmans joined
rhr ?eval class Str is also { method id($x:) { $x } } sub foo($x? = 'a') { $x } $_ = 'b'; foo.id 01:38
01:38 evalbot_r16231 is now known as evalbot_r16232
evalbot_r16232 \"b" 01:38
rhr shouldn't that be 'a'? 01:39
02:20 obvio171_ joined 02:21 nipotan is now known as nipotaway
Aankhen`` ?eval sub foo ($x? = "x", $y? = "y') { "$x $y" }; $_ = "b"; foo() 02:24
evalbot_r16232 Error: ā¤Unexpected "b"ā¤expecting term postfix, operator, "-->" or ")"
Aankhen`` Ergh. 02:25
?eval sub foo ($x? = "x", $y? = "y") { "$x $y" }; $_ = "b"; foo()
evalbot_r16232 "x y"
Aankhen`` ?eval class Str is also { method id($x:) { $x } } sub foo($x? = 'a') { $x } $_ = 'b'; foo().id
evalbot_r16232 \"a"
Aankhen`` ?eval sub foo ($x? = "x", $y? = "y") { "$x $y" }; $_ = "b"; foo 02:26
evalbot_r16232 "x y"
Aankhen`` shrugs.
rhr I want something where foo.id and foo .id yield different results (to test long dot and unspace) 02:42
02:50 araujo joined 02:58 justatheory joined
TimToady sub foo ($x = "noarg") {...} 03:05
03:06 mako132_ joined
rhr ?eval class Str is also { method id($x:) { $x } } sub foo($x = "noarg") { $x } $_ = 'b'; foo.id 03:06
evalbot_r16232 \"b"
rhr ?eval class Str is also { method id($x:) { $x } } multi foo() { 'a' } multi foo($x) { $x } $_ = 'b'; foo.id 03:08
evalbot_r16232 \"a"
rhr ?eval class Str is also { method id($x:) { $x } } multi foo() { 'a' } multi foo($x) { $x } $_ = 'b'; foo .id 03:09
evalbot_r16232 \"b"
rhr should that also work with sub foo($x? = 'a') { $x } ?
03:13 kunwon1 joined 03:25 obvio171_ joined
jvoorhis hi 03:30
Tene Hi!
jvoorhis does anyone know about the subtype implementation in pugs? 03:31
the parser is cool with my subtype declarations, but the subtypes let me violate them in ways they shouldn't tolerate 03:32
03:33 agentzh joined
jvoorhis going beyond that, i'd enjoy tinkering with pugs src, but i'm not quite sure where to start 03:34
Tene jvoorhis: a good place to start looking when you want to see how well implemented something currently is is pugs' test suite. 03:35
in t/ in pugs' svn
agentzh jvoorhis: also take a look at perlcabal.org/syn :) 03:37
lambdabot Title: Official Perl 6 Documentation
jvoorhis yep, i'm not traditionally a perl programmer, but i've spent some time in the synopses 03:38
Tene jvoorhis: the docs at perlcabal.org/syn/ have links built in showing the tests for that section and their output and whether they pass or not. Updated semi-regularly, I believe.
lambdabot Title: Official Perl 6 Documentation
jvoorhis perfect 03:39
agentzh andara: i'm installing Moose on feather (globally) :)
jvoorhis oh, that is very nice 03:40
agentzh well, the synopses and tests are updated once an hour while the smoke results updated once a day :)
jvoorhis ah, i still haven't gotten my smoker to work
agentzh jvoorhis: glad you like it :)
jvoorhis i might steal the idea 03:41
agentzh cool 03:43
TimToady: iblech++ has just updated the smoke server. everything should be fine now :) 03:45
03:45 ofer joined 03:47 SubStack joined
TimToady rhr: I consider foo.id to be a misparse if ever interpreted as foo(.id) 03:48
listops explicitly require a space before their first arg 03:49
03:49 Alias_ joined
TimToady and I think foo falls into that category, or the category needs to be broadened to all non-parenthesized function calls 03:49
rhr that's what I thought 03:50
TimToady sorry, was distracted earlier...
rhr np
I'll add a failing test for sub foo($x? = 'a') { $x } 03:52
agentzh a few questions regarding p6 regexes: 03:53
how can i make an interpolated closure to affect parsing? 03:54
say, something analogous to 'block: { quote_blocklike($text) }' in Parse::RecDescent.
avar you want a perl subroutine instead of a p6rule-thingy? 03:55
agentzh avar: yup
i know <{...}> works if {...} returns a regex or a rule object
but...
the ability to work on the underlying $text would be great. 03:56
avar a rule is just a fancy sub and you can go into real subs with <somename>, but I don't know how you define them
agentzh i gathered so. i just want to know how to. :)
i have no idea what the API will look like.
TimToady they're just methods in the same grammar
STD.pm uses that trick all over
<EXPR(%assignop)> is just a method call 03:57
03:57 jvoorhis is now known as jvoorhis-afk
TimToady and EXPR is just written as a method 03:57
the object of the method is the current parse context 03:58
agentzh TimToady: is it possible to reuse Text::Balanced's extract_* from within the p6 regex?
avar grammar Ook: rule stringy { <[a..z]>+ } sub meh { ... } rule TOP { [ <stringy> | <meh> ]+ }
agentzh: yeah, parrot does this all over the place
(using the PIR equivalent) 03:59
TimToady presumably, STD just uses its own version of that
agentzh if meh == extract_quotelike, how can i call it in regex?
avar TimToady: where is it specced how `meh' will get its argumenst and how it affects its environment, like how do I say a sub matched 5 characters? 04:00
agentzh avar: right, that what i'm about to ask.
TimToady they aren't subs, they're methods, and the method's object is all the context
agentzh *that's
diakopter waits for a lull in the conversation to continue another topic.
agentzh Hmm 04:01
offby1 how about them Yankees?
diakopter offby1: :P
offby1
.oO("Yankees" ... sports team for sure. Baseball? Yeah, probably.)
04:02
agentzh TimToady: has the API of $self been defined?
such as $.text or $.pos?
i didn't see them in S05. 04:03
TimToady it's not completely defined yet, but whatever the implementors feel they need is probably fine. $self certainly contains the currently being constructed $/ somehow, I expect 04:04
it also has to know which string is being searched
agentzh that's COOL 04:05
04:05 amnesiac joined
TimToady whether the string or the $self keeps track of .pos is a good question 04:05
STD assumes $_ knows its .pos
agentzh okay, that's what i want :)
TimToady but that's just following p5's pos() semantics for now
but attaching pos to the $_ means various regexes can share a string that is being scanned, so I think that's still right 04:06
(of course, within a particular match, $_ is also aliased to that current string even if not $_ outside the match)
$a ~~ / foo { say $_ } / # prints $a, if it prints anything 04:07
agentzh not sure if PCR has implemented anything like that...fglock? 04:08
TimToady anyway, the key concept is that a given match has to keep its context somewhere, and that's convenient the $self of all these methods and rules, however we choose to distribute the data underneath the abstraction
*conveniently
I think PCR is method based, and PGE is currently sub based, if I recall.
agentzh i'll have a closer look :) 04:09
TimToady I could easily be misrecalling on either end
agentzh another question...
04:09 SubStack joined
agentzh is it okay to write <[ 04:10
<[\d2..\d3]>
?
i'm pondering writing a p6-regex based parser for the mini-lang defined in the email RFCs. 04:11
TimToady I don't think so, \d is digits in regexen, not decimal. at least if we follow p5 in this
in p5 you can say [\d\w]
04:11 dmpk2k joined
agentzh or \o123..\o125? 04:11
TimToady that would work better, since \o isn't taken by regex 04:12
but I doubt it'll happen often in practice
the world seems to be moving primarily to hex chars rather than octal
agentzh the ABNF in the email RFCs makes use of such kind of things.
TimToady certainly anything in the unicode ranges tends to be hex
agentzh widely use of, even 04:13
TimToady I'm sure a great many of those would be written differently today in hindsight...
agentzh what's the recommended way to do that then? 04:14
convert the digits to chars and put them into single-quotes?
TimToady <[S..U]> works pretty well
agentzh how about <['+'..'Z']> ? 04:15
TimToady that would include single quote in the character class
agentzh sigh. 04:16
that's what i fear.
TimToady and wonder why you did a range from single quote to single quote
a sane character class compiler will likely complain
Tene ?eval 'G' ~~ m/<\+..Z>/
evalbot_r16232 *** Cannot parse regex: <\+..Z>ā¤*** Error: ā¤Match.new(ā¤ ok => Bool::False, ā¤ from => 0, ā¤ to => 0, ā¤ str => "", ā¤ sub_pos => (), ā¤ sub_named => {}ā¤) 04:17
TimToady ?eval 'G' ~~ m/<[\+..Z]>/
evalbot_r16232 Match.new(ā¤ ok => Bool::True, ā¤ from => 0, ā¤ to => 0, ā¤ str => "", ā¤ sub_pos => (), ā¤ sub_named => {}ā¤)
TimToady with the usual evalbot damage...
agentzh cool, backslash works here.
TimToady ?eval 'G' ~~ m/<[+..Z]>/ 04:18
evalbot_r16232 Match.new(ā¤ ok => Bool::True, ā¤ from => 0, ā¤ to => 0, ā¤ str => "", ā¤ sub_pos => (), ā¤ sub_named => {}ā¤)
agentzh but it's a bit tricky to determin when to escape while doing it automatically.
*determine 04:19
TimToady the only metachars in a character class are ], \ and .. I think
agentzh ah, great
TimToady well, and whitespace 04:20
agentzh yup :)
TimToady ?eval 'G' ~~ m/<[ +..Z ]>/
evalbot_r16232 Match.new(ā¤ ok => Bool::True, ā¤ from => 0, ā¤ to => 0, ā¤ str => "", ā¤ sub_pos => (), ā¤ sub_named => {}ā¤)
TimToady and we probably just require \- to catch brainos from old regexen 04:21
agentzh to => 0 seems to be wrong
TimToady it is
evalbot doesn't do character classes
but it should work locally
agentzh k
Tene it does.
TimToady probably thinks the char classes are unsafe because it pulls in unicode 04:22
arguably that's true. :)
agentzh gotta run for lunch, thanks, TimToady &
TimToady ciao
Tene What's unsafe about unicode? 04:23
TimToady anything that touches cultural issues is unsafe. : 04:24
:)
Tene Ahh.
diakopter TimToady/channel: a friend of mine is considering spending time with the Perl 6 test suite, but he's worried about the volatility of the specifications. I really want him to come work with #perl6; any suggestions for how to tell him to chill out and start hacking on it? It might help him if he had a bit of an idea which Synopses you considered least volatile or even most completed.
mugwump just tell him to harden up
TimToady tell him when I change anything drastic, I usually go out and clean up the tests myself, so don't sweat it. 04:25
it's much better to have something than nothing
diakopter alright; i'll tell him. Hey, you, watching on the http log, see above. 04:26
TimToady and basically the specs from 1..13 aren't all that volatile anymore.
Functions is still in a bit of flux in spots, and IO
diakopter thanks for the details. Here's hoping he chills out. :) 04:28
TimToady I hope he chills in... :)
in any case, nobody bites anyone's head off in this project. well, not yet, at any rate... 04:29
diakopter lol
04:33 persib joined 04:49 agentzh left, persib left, the_dormant joined 05:18 diakopter is now known as TsantsasBiter, TsantsasBiter is now known as diakopter
rhr silly question: in an embedded comment, can unspace hide space between # and the opening bracket? 05:20
TimToady I don't think we need to allow for that, if we consider # and a following bracket to be a single token. 05:26
rhr sounds good 05:27
TimToady can't really think of a use case for the other way
rhr no, I would imagine not :)
TimToady we don't allow unspace for gluing together tokens in general 05:28
so foo\ bar is still separate foo and bar tokens
05:30 obvio171_ joined
diakopter bites your head off. 05:32
TimToady doesn't notice much difference... 05:33
clkao ~>
05:34 obvio171_ joined
diakopter oh good; the guy is going to resurrect his pugs credentials. 05:35
diakopter adds a tick next to 'reconverted a backslider'
oh, and we'll both be at oscon07. 05:36
TimToady: did you happen to see those parrot/pugs paintings I pasted URLs for a few weeks ago 05:37
TimToady yes
interesting coincidence... 05:38
diakopter I thought about ordering a print or two. never got around to it.
it'd make a neat t-shirt though
Alias_ what's this? 05:39
URLs?
diakopter heh
they'd be in the previous logging system
05:39 obvio171_ joined
diakopter which I think is still broken 05:39
or I guess I could google them again 05:40
TimToady I thought they were more recent 05:41
diakopter store.encore-editions.com/artist/jo...rtung.html
lambdabot Title: Johann Hartung Canine Dog Pug Paintings & Prints of Dogs
diakopter the other one was a photo of an ebay item that I doubt is still around. perhaps in googlecache. 05:42
TimToady moritz.faui2k3.org/irclog/out.pl?ch...-21#id_l51 05:43
lambdabot Title: IRC log for #perl6, tinyurl.com/275krv
05:44 obvio171_ joined
diakopter oh; I didn't see the high(er) res images of those paintings. 05:44
oh, I guess I did see them. back then. faulty memory.
TimToady i14.ebayimg.com/07/i/000/97/f1/187f_1_b.JPG is the other one
diakopter I suppose that's a cockatoo, which I guess is close to a parrot. 05:46
diakopter renames parrot to Psittaciformes to fit the images.
rhr there's discussion in S02 about infix/postfix ambuguities, but what if you have infix:<++> and you say '$n ++$m', is that always prefix? i.e. does prefix always require no space and infix requires space, like w/ postfix?
05:46 penk joined
TimToady prefix doesn't care about space 05:48
nor does infix
only postfix cares
rhr so what is '$n ++$m'?
TimToady a syntax error
rhr OK
TimToady well, maybe not. 05:49
might just parse it as $n + +$m
diakopter mv TimToady IdealPerl6EvalBot
TimToady since I doubt infix tables know about ++ at all
rhr but if you define infix:<++>?
TimToady then it's $n ++ $m 05:50
rhr OK. awful lot of choices there..
TimToady ?eval 1 ++2 05:51
evalbot_r16232 Error: ā¤Unexpected "2"ā¤expecting operator
TimToady I think the pugs parser isn't up-to-speed on postfix parsing yet.
that should never parse as postfix ++
Tene rhr: it can't be prefix because then you just have two terms 05:52
rhr OK, so it disambiguates that way
TimToady ?eval multi infix:<++> ($a,$b) { "$a..$b" } 1 ++2 05:53
evalbot_r16232 Error: ā¤Unexpected "2"ā¤expecting operator
TimToady ?eval multi infix:<++> ($a,$b) { "$a..$b" } 1 ++ 2
evalbot_r16232 Error: ā¤Unexpected "2"ā¤expecting operator 05:54
TimToady basically busted
05:54 obvio171_ joined
rhr I'm writing tests for it... 05:54
TimToady well, more just using semantics from an ancient synopsis...
which was busted... 05:55
05:55 obvio171_ is now known as obvio171 05:57 mjk joined
rhr $n++$m is postfix though, right? 05:58
05:58 obvio171_ joined
rhr (although it's invalid) 05:59
Tene infix, I thought.
rhr S02: "If a given token may be interpreted as either a postfix operator or an infix operator, the infix operator requires space before it." 06:00
Tene rhr: what would the postfix interpretation be? 06:01
rhr syntax error
Tene so wouldn't that be equivalent to "may not be interpreted as"?
rhr hmm... you have a point 06:02
TimToady it's a syntax error 06:03
with very few exceptions, the parser does not do backtracking 06:04
it commits to ++ being postfix before deciding about anything after the ++ 06:05
rhr OK, good to know
diakopter wow, IdealPerl6EvalBot is quite helpfully verbose. 06:07
TimToady in fact, the two places that backtrack are commented specially in STD
06:07 nipotaway is now known as nipotan
diakopter can an operator contain whitespace? 06:12
06:13 justatheory joined
TimToady none of the standard operators do 06:13
Alias_ runs screaming
TimToady in a sense, the circumfix operators allow whitespace in the middle... 06:15
svnbot6 r16233 | rhr++ | Add unspace and long dot tests
diakopter but a circumfix is a pair of a prefix and postfix. Shouldn't it be specified whether a postfix, infix, or prefix operator can contain whitespace? 06:18
06:19 rfordinal joined
diakopter on that note, is it legal to define an operator that is identical to one side of an already-defined circumfix? 06:20
TimToady it would likely shadow it
diakopter oh, well, of course, since those already exist. 06:24
TimToady if you define prefix:<[> you'll lose [...]
that's just "doctor, it hurts when I do this"... 06:25
diakopter ?eval multi infix:<)> ($a,$b) { "$a..$b" } 1 )2
evalbot_r16232 "1..2"
TimToady guaranteed to drive your syntax highlighter nuts
diakopter looks at Alias_ for syntax highlighting 06:26
Tene Ouch.
TimToady Alias_ already ran away
diakopter ?eval multi infix:<(> ($a,$b) { "$a..$b" } 1 (2
Alias_ heh
evalbot_r16232 Error: ā¤Unexpected "("ā¤expecting operator
Alias_ Man, I already wrote one document parser
I'm burnt out
diakopter I suppose that last eval makes sense.
Alias_ Plus, my approach shouldn't be necesary for Perl 6 06:27
So people keep telling me
And there's many people much better with proper grammars than me
diakopter and grammar, even! ;)
well now wait a second 06:28
rhr diakopter: you switched ( and ) 06:29
diakopter ?eval multi infix:<<> ($a,$b) { "$a..$b" } 1 <2
evalbot_r16232 Error: ā¤Unexpected "infix"ā¤expecting bare or pointy block construct, ":", "=>" or operator
diakopter heh; redefining
rhr nevermind, I'm blind
TimToady ?eval multi infix:Ā«<Ā» ($a,$b) { "$a..$b" } 1 <2 06:30
evalbot_r16232 Bool::True
TimToady the pugs grammar still hardwires a number of tokens, it seems 06:31
?eval multi infix:Ā«<Ā» (Str $a, Str $b) { "$a..$b" } 'a' < 'b'
06:31 evalbot_r16232 is now known as evalbot_r16233
evalbot_r16233 "a..b" 06:31
diakopter ?eval multi infix:<'let's paint a picture'> ($a,$b) { "$a..$b" } 1 'let's paint a picture'2 06:32
evalbot_r16233 "1..2"
TimToady that sortof works by accident, I think 06:33
diakopter ?eval multi infix:<''''''''''''''''> ($a,$b) { "$a..$b" } 1 ''''''''''''''''2 06:34
evalbot_r16233 "1..2"
rhr ?eval multi prefix:<'''>($a) {42} 1.''''' 06:35
evalbot_r16233 Error: ā¤Unexpected "'''''"ā¤expecting ".", "\187", ">>", "=", operator name, qualified identifier, variable name, "...", "--", "++", "i", array subscript, hash subscript or code subscript
TimToady ?eval multi infix:{"'let's","paint","a","picture"} ($a,$b) { "$a..$b" } 1 'let's paint a picture'2
evalbot_r16233 Error: ā¤Unexpected end of inputā¤expecting "\\", variable name or "'"
TimToady yeah, it's not really parsing :<'let's paint a picture'> as a hash subscript 06:37
06:37 marmic joined
diakopter multi prefix:<> {} 06:45
?eval multi prefix:<> {}
evalbot_r16233 Error: src/Pugs/Parser.hs:468:12-50: Irrefutable pattern failed for pattern (Pugs.AST.Internals.Syn "{}" [_, expr])ā¤
06:47 mugwump joined 06:51 agentzh joined
TimToady zzz & 06:52
diakopter ?eval multi postfix:<;> ($a) {}; say say 42 ; 06:53
evalbot_r16233 OUTPUT[ā¤1ā¤] Bool::True
diakopter titters 06:55
06:58 iblechbot joined 06:59 franck__ joined
agentzh moritz: i hope you will add search utility to ilbot's web interface when you have time. it's not easy for me to grep over your server without downloading the latest logs. 07:01
moritz: also, logging other channels like #parrot is cool as well :) 07:02
07:04 buetow joined 07:07 obvio171_ joined 07:11 obvio171_ joined
diakopter ?eval multi postfix:<;> ($_) { "$_"; } ""; 07:14
heh; agentzh: could you kill that evalbot on feather...?
evalbot_r16233 pugs: out of memory (requested 1048576 bytes) 07:15
diakopter k; never mind
07:16 Aankhen`` joined 07:21 jisom joined 07:29 BooK joined 07:31 franck___ joined 07:33 rindolf joined 07:44 demq joined
agentzh ?eval 1+2 07:46
evalbot_r16233 3
agentzh rhr: i don't quite understand why you add t/syntax/longdot.t when there is already a t/syntax/long_dot.t 07:49
rhr: is there a very good reason?
07:55 rfordinal joined
agentzh is working on a mini-mini-miniperl6 parser :) 07:56
Alias_ implements mini-mini-miniperl6-simple 07:59
07:59 buetow joined
rhr agentzh: doh! I can't believe I missed that. I'll merge them tomorrow, I made some mistakes in longdot.t anyway... 08:00
sleep& 08:01
agentzh rhr: sleep well :) 08:02
Alias_: url? 08:03
Alias_ :)
er
08:03 SubStack_ joined
Alias_ j/k of course 08:03
08:03 SubStack_ is now known as SubStack
agentzh ah :) 08:04
Alias_ It scares me that you consider it possible :) 08:09
08:14 the_dormant joined
agentzh why not? 08:15
08:19 SubStack joined
agentzh yay, it works :) 08:25
rindolf Hi Alias_
Alias_ hi
rindolf Hi agentzh
Alias_: what's up?
agentzh hi, rindolf
Alias_ releasing stuff
rindolf Alias_: nice.
Alias_ my repository has been down for a LONG time
agentzh Alias_: what's the status of PITA?
rindolf Alias_: I think there was something I wanted to talk with you about but I cannot recall what.
Alias_ So, PITA has some big issues to get past 08:26
One is essentially solved with pip
The second is solved by BinGOs' POE server manager thing
Which I've got about halfway integrated into the driver backend 08:27
The third, tbh, I forget :)
agentzh cool
Alias_ So yeah, PITA started quick, hit the wall, and it's taken a while to beat some of the underlying problem
I also don't get as many timeslices as I want
But it's one of those things that are stuck till you hit a certain point, then it's easy for other people to go further with it 08:28
rindolf, you said something like that last time :)
So yeah, it's not dead, just slow :(
agentzh gotcha 08:29
Alias_ As I get on top of my repository manager and get that out the way, then I have some more time for it
agentzh there's still a long way to go for integrating PITA into our smoke server ;)
Alias_ Well, you never know
agentzh hehe
Alias_ Because I have some ideas about that
That might actually make things trivial
agentzh really?
Alias_ :)
Have you seen Process 08:30
agentzh a CPAN module?
Alias_ ya
agentzh i think so, but can't recall...
Alias_ It was an experiment. I made it when I first realised that CPUs weren't going to be getting any faster
So I thought, I needed a way to take some computational process, and work with it as an object 08:31
So Process provides a strict API and some guarentees
And you write a class that inherits from a combination of Process classes, and thus advertises certain properties 08:32
agentzh Process has a scary API ;)
Alias_ :)
In any case, one of the nice things is that it piggy-backs off CPAN
agentzh i just thought it was a virtualmachine the first time i saw it.
Alias_ :) 08:33
It's basically a container for a chunk of input data that will have something run on it
Because if you have some bit of code to run, how do you know if the remote machine can handle it
So this way, you just check the remote machine for the class
And if it has the class, it can run your job
And thus, by installing a class from CPAN, you can make compute nodes 08:34
But it already has some funky stuff
For example, you an delegate a process to a different Perl
So you can run parts of your program in multiple different versions of Perl
agentzh interesting :)
Alias_ Dunno what the point would be...
But I was thinking you could just clone the object and run it on all different versions 08:35
And see if the resulting post-completion objects all come back the same
So you could write tests for differing behaviour across Perl versions, or something
in any case...
agentzh testing against different versions of perl is so useful.
Alias_ right
It occurred to me that if I already have an encapsulation for a task, and PITA is really about running tasks, why not us Process as the API 08:36
You generalise PITA a bit
agentzh Test::Base is having problems with perl 5.6.x and i've been looking for a perl to test it.
Alias_ So that one parts just takes a Process object, puts it into the virtual machine, runs it, and returns it
That way you could process anything inside the virt
You could do things like run part of your program under Windows, and part under VMS or whatever :) 08:37
agentzh wow
Alias_ And then you write the actual PITA testing sequences as a subclass of Process
And it just magically works
If you want to run the same testing sequence in the current Perl, it works normally
or delegate to another Perl, or another host, or a virt from a library of them, etc
Or pregenerate 100,000 of them in serialized form, chuck them into a SQLite databawse 08:38
And then write a Process server that takes connections from a distributed set of volunteers, hands out jobs, and collects the results
agentzh how to solve dependencies if delegating to a remote server?
Alias_ Process
You can't deserialize the object if you don't have the class 08:39
To install the class, you need to install the deps
So it uses the normal CPAN toolchain to fulfill dependencies
agentzh fair enough :)
Alias_ And you can ask the remote servers "Do you have any of these classes?"
etc etc
So Process lets compute environments advertise capabilities 08:40
Using the normal mechanisms provided in the language
etc etc
It's a nice abstraction, I like it :)
agentzh to me, it seems to be real-time CPAN testing service and provide more flexibility.
Alias_ Anyways, that's the sort of things Process is meant to allow
Certainly the flexibility part 08:41
08:41 stef__ is now known as cognominal
Alias_ It solves the "any version of Perl, in any configuration, on any software, on any hardware" 08:41
Which is a hard problem...
er
agentzh via network computing and colaboration
Alias_ via whatever
agentzh :)
Alias_ If you have your own cluster, just run them locally
agentzh *nod* 08:42
Alias_ There's no reason to focus on any one model of parellel computing, if you can abstract the job cleanly enough
And hence Process :)
Anyways
It's a lot like the whole Vanilla Perl thing
In my head, it SHOULD be a huge leap forwards
agentzh putting all the pieces together... 08:43
Alias_ But until I push it myself to a certain point, it resists having multiple people involed
In the case of Vanilla, I burnt huge hours making Bundle::CPAN work
And once that worked, lots of other people stepped in and started installing all sorts of modules and testing them and contacting the authors about bugs
And now I do very little really
It's running itself 08:44
agentzh Alias_++
Alias_ Hopefully PITA will be similar
But in this case, it's the core virtualisation loop that's the nasty bit
Once I have it abstracted away to a simple API, the rest should start to appear
But it's not worth anyone elses time really until that's done
PPI as well I guess 08:45
once it worked and didn't leak, I've not had to do much
08:45 andara joined
agentzh Alias_: good luck! :) 08:45
Alias_ Just handle bugs
heh
moritz agentzh: re irclog: #parrot has a no-log policy, and I respect that
agentzh: search is planned, but I don't have that much time... you're welcome to contribute if you want to accellerate it ;) 08:46
agentzh moritz: okay :)
Tene agentzh: you're always welcome to make your own private logs, though. 08:57
agentzh Tene: k 08:58
pasteling "agentzh" at 221.6.159.250 pasted "Declarative unit tests for PCR using Test::Base. All these tests are passing right now. Comments welcome :)" (45 lines, 531B) at sial.org/pbot/24778 09:00
Tene Vague reference to a joke about actually being a log-bot with a markov chain generator to reduce suspicion.
09:01 jisom_ joined 09:05 chris2 joined 09:28 jamhed joined 09:32 Psyche^ joined, Psyche^ is now known as Patterner
svnbot6 r16234 | agentz++ | [PCR] 09:34
r16234 | agentz++ | * added t/declare to hold declarative tests for PCR
r16234 | agentz++ | * added t/Regex.pm which subclasses Test::Base and serves
r16234 | agentz++ | as the tester scaffold for t/declare/*.t
r16234 | agentz++ | * added t/declare/00-demo.t to demonstrate the usage of
r16234 | agentz++ | the new tester mechanism.
r16234 | agentz++ | (currently t/declare/*.t are not seen by PCR's 'make test' because t::Regex is not mature yet.)
r16235 | agentz++ | [PCR] - declare/00-demo.t - fixed a typo 09:37
agentzh t::Regex doesn't use v6.pm or any other thing to parse the p6 var syntax due to the circular dependency problem and also performance consideration :) 09:38
i parse the p6 vars by hand with plain p5.
*that* is the mini-mini-miniperl6 :)
moritz ;) 09:39
agentzh the beauty of 00-demo.t is that it can trivially generate *.t in plain p5 (for PCR if fglock hates T::B), plain PIR (for PGE), plain p6 (for pugs/mp6/kp6/p6-on-parrot/etc) 09:40
it will pave a way to share basic test suite for p6 regexes among different implementations (automatically) 09:41
moritz agentzh: why not store the data in yaml?
agentzh yaml is not human-writable
moritz agentzh: or any other serialized format
bbiab &
agentzh moritz: *nod* serialization can indeed simplify the work of writing another emitter :) 09:43
supper & 09:44
09:44 agentzh left 10:13 ruoso joined 10:15 rhes1 joined 10:16 rhes1 left 10:25 buetow joined 10:54 elmex joined 11:12 franck__ joined 11:13 crashmatrix joined 11:24 VanilleBert joined 11:39 mako132_ joined 11:41 fglock joined
fglock avar: re $_ in PCR - $_ is not aliased to the string (yet); $/ is "self"; you can get to the string through a $/ method 12:04
moritz when i use p6 rules to parse a language (p6 for example), how do i implement error handling? 12:06
I mean a regex either matches or not, so the result would be either "matches = ok" or "doesn't match = syntax error" 12:07
how can I detect where the error in the input code is?
fglock moritz: use a side-effect, like a closure-block
12:07 polettix joined
moritz fglock: do you have an example? 12:08
fglock svn.pugscode.org/pugs/src/perl6/Per...0.0-STD.pm uses a rule named 'panic' 12:10
moritz fglock: thanks 12:11
fglock svn.pugscode.org/pugs/perl5/Pugs-Co...r/Rule2.pm uses: | { die "invalid alias syntax" }
lambdabot tinyurl.com/2fgmop
12:19 the_dormant joined 12:21 iblechbot joined 12:26 fglock joined
moritz how do define a class that has a custom stringifcation? 12:36
in "deploying perl 6" i've seen somthing like class foo does Printable { method to_string {...} } 12:37
is that specced anywhere?
12:39 jerrylee joined, buetow joined
svnbot6 r16236 | fglock++ | [v6.pm] version 0.018 in CPAN; fixed module name in CPAN index 12:44
12:48 pbuetow joined 12:53 nipotan is now known as nipotaway 12:54 fglock joined
fglock ?eval class X { has $.v } multi prefix:<~> ( X $v ) { 'x'~$v.v~'x' } my $x = X.new( v => 123 ); ~$x 13:03
13:03 evalbot_r16233 is now known as evalbot_r16235
evalbot_r16235 "x123x" 13:03
fglock but this doesn't work for "$x" 13:04
13:05 rfordinal joined
moritz I'd expect an interface that defines Roles (Printable/String, Array, Hash) and methods that you can override 13:07
fglock moritz: I think the pugs-MO rewrite will fix it; kp6 works like that, with roles for each api 13:10
moritz fglock: cool. do you know where I can find a list of the names of the roles and their methods? 13:11
diakopter Alias_: you still around? 13:12
13:13 VanilleBert left
fglock I don't think it is specced; I just made up the kp6 method names 13:13
moritz ok 13:14
fglock kp6 roles are like: container, readonly, auto_deref, str, int, ... 13:17
13:37 hareldvd joined 13:49 yumiko joined 13:52 justatheory joined 14:02 veritos joined
veritos morning all 14:02
moritz hi veritos ;) 14:03
fglock veritos: good morning 14:04
moritz it's nearly tea time here ;)
fglock I'm currently helping port a perl5 program to java, at $job; I will likely take some time to study perl6-in-jvm 14:06
veritos i was thinking of writing a c-on-perl compiler. 14:07
fglock veritos: c on perl6? 14:08
veritos maybe... 14:09
grammar C;
avar veritos: parrot has a c99 grammar, just the grammar though.
veritos shouldn't actually be too hard.
fglock I think Parse::Yapp comes with a working C grammar 14:10
veritos i'll try. i have to write a standard library too...i think 'use POSIX' will take care of most of that. 14:11
avar not really, that leaves out the C stdlib 14:12
you can write most of it in C itself, so you can just copy uClibc or something like that
rindolf Hi avar, veritos, fglock, moritz 14:13
veritos rindolf: heya
moritz hi rindolf ;)
rindolf moritz: what's up?
veritos: sup?
veritos avar: no, i wanted to write it in as much perl as possible
rindolf: discussing my evil plan to write a c-to-perl compiler 14:14
muahaha
rindolf veritos: oh, that.
fglock does Java has a form of eval() ?
rindolf veritos: yes, I recall discussing it with someone.
veritos: write a gcc backend.
moritz veritos: I think it's a mess with the pointer things ;)
rindolf Some pepole think that it's more secure to not have a C compiler on the system.
avar fglock: no
moritz veritos: do you want to solve that with a big @mem array? 14:15
veritos moritz, rindolf: it won't be perfect, and \ and $/@ should handle that.
moritz: that's one idea i was thinking
avar fglock: which is one reason why this whole VM thing for Java is quite silly:)
moritz veritos: I expect it to compile the linux kernel, of course ;)
veritos maybe a tied Mem, which would init unused areas to 0
moritz: so kernel on perl on c on kernel?
moritz veritos: of course ;) 14:16
veritos sounds like perl 6. p6 on haskell on c on java-to-c compiler on asm
moritz you can solve any problem in computer science by introducing another abstraction layer ;)
veritos port perl to one-instruction-set computer! 14:17
fglock avar: hmm - is it possible to store bytecode in a variable and then execute it? 14:18
moritz sounds evil indeed ;)
avar fglock: Not in java itself, but on the jvm I don't see why not
veritos just rewrite java in java!
gaal feather.perl6.nl/~audreyt/osdc/haskell.xul is looking a little borked. what does it need? a stylesheet? regeneration?
avar you can give it new bytecode to eat, that can just as well come from a variable
veritos or a jvm at least
gaal (also, moose all) 14:19
veritos it crashes for me. anyone know what's up with that?
here's what you need: frivolous toy interpreter.
<strikethru>frivolous</strikethru> 14:20
<strike>interpreter</strike>
toy...
-Ofun....
:)
fglock avar: so it will probably be (perl6->jvm) instead of (perl6->java->jvm) 14:24
14:25 lichtkind joined 14:26 amnesiac joined 14:32 [particle] joined 14:33 drupek12 joined 14:44 veritos joined 14:59 cognominal joined 15:07 bonesss joined 15:22 frobnitz joined 15:28 dmq joined 15:32 sri_ joined 15:38 rodi joined 15:47 prism joined 15:53 andara left 15:56 Loro_ joined 16:13 [particle] joined 16:19 veritos joined 16:24 pbuetow joined 16:32 jvoorhis-afk is now known as jvoorhis 16:33 jerrylee_ joined 16:35 franck__ joined 16:37 meppl joined 16:44 Southen joined, Southen_ joined 16:52 pmurias joined, REGJAVA joined, kanru joined
REGJAVA I am getting "Can't spawn "cmd.exe"" when i invoke system commands using perl , How can i fix it? 16:52
moritz REGJAVA: certainley not by asking in #perl6 ;) 16:53
16:53 Southen joined
pmurias #perl@irc.perl.org is generally the chanel for perl5 help 16:54
avar That channel is mostly about dongs, #perl on this network is better if you need help 16:55
yumiko at least he didn't ask in #lisp :P
REGJAVA will changing my perl to perl6 fix that issue? 16:56
pmurias uses windows only at school for starcraft, so can't help
perl6 isn't suitable for production yet, and is quite a different language
17:06 weinig is now known as weinig_, weinig_ is now known as weinig, franck__ joined 17:08 franck__ joined, gnuvince joined 17:15 the_dormant joined 17:19 fglock joined
pmurias fglock: hi 17:39
today.java.net/pub/a/today/2007/02/...anino.html
lambdabot Title: java.net: Tackling Java Performance Problems with Janino, tinyurl.com/2bh7e9
pmurias eval for java 17:40
17:45 bonesss joined
fglock pmurias: hi - looking... 17:45
17:46 [particle] joined 17:48 obvio171 joined 17:51 bernhard joined 17:54 japhb joined 17:55 Psyche^ joined
fglock pmurias: nice 17:58
does java support closures nowadays? 18:00
18:01 kanru joined 18:07 tokuhirom__ is now known as toku_away 18:09 Psyche^ joined, Psyche^ is now known as Patterner 18:10 jisom joined 18:13 kattana_ joined
pmurias read Thinking in Java, but hasn't used java almost at all 18:19
18:19 penk joined 18:26 buetow joined 18:36 prism joined 18:43 fglock joined 19:02 cognominal joined 19:08 pbuetow joined 19:14 weinig_ joined 19:17 edenc joined 19:30 the_dormant joined 19:46 dduncan joined 20:09 pmurias left, Belaf joined
japhb moritz: Backlogging, I noticed that you said #parrot has a no-logs policy. Happen to know the reasoning? 20:13
moritz japhb: no, I just know that the inhabitants of #parrot decided against it some time ago, but are considering to change their policy 20:21
japhb That would be nice. Information wants to be a hyperlink target. 20:22
moritz actually I'm surprised how many people use the irclogs
today about 130 hits on the logs 20:23
20:23 araujo joined
[particle] moritz: that could be one person refreshing every five minutes 20:24
moritz [particle]: but it isn't ;)
in my logs I can see a significant increase of unique visitors since the irclogs are online 20:26
and people are posting links to specific lines and pages, and I got some feedback - quite surprising ;) 20:27
[particle] well, #parrot's policy is that serious discussion should always happen on the mailing lists. #parrot is just a chat room.
we have logs of our weekly design meetings that occur in #parrotsketch
moritz nevertheless I don't think that the diskussions of #parrot are worthless 20:29
but since I don't contribute to that discussions I'm in no position to propose changes 20:30
PerlJam moritz: those of us that care to will log whatever channels we're in anyway. 20:34
screen++ btw.
moritz PerlJam: that's right, yes. And screen++ and irssi++ indeed ;) 20:35
PerlJam (I used to log everything, all the time, but stopped when I realized how infrequently I used the logs)
I've got some good conversations with tchristi from 1998 or so though :-) 20:36
er, tchrist
20:37 justatheory joined
avar logs don't take up a lot of space and come in real handy:) 20:37
moritz that's what bzip2 is for ;)
integral avar: they still take up a lot of space after sufficient time. 20:49
avar you irc too much:) 20:50
fglock good night all & 20:56
21:02 SubStack joined 21:13 buetow joined 21:14 marmic joined 21:21 yumiko joined 21:32 Aankhen`` joined 21:37 obvio171 joined 21:48 weinig_ is now known as weinig 21:49 weinig_ joined 21:50 weinig_ joined
diakopter anyone around to discuss test harness ideas? 21:57
offby1 nobody here but us zombie processes. 21:59
diakopter killall -9 zombie
moritz drops dead
qmole Terminated 22:00
22:02 rfordinal joined
diakopter I've been doing some thinking about how to differentiate the behavior of an interactive (Perl 6) shell/interpreter, and the behavior of a (Perl 6) compiler/emitter, from a testing standpoint. 22:03
I'm sure I'm misguided in a lot of ways, but does anyone have any pointers to reading material, or even terminology (to search) to further my thoughts? 22:05
I mean, a language is spec'd to behave a certain way, but there are different measures for success/failure, depending on whether it's being tested interatively or tested by measuring the results of a compilation or emission to another language. Or am I barking up the wrong tree (out of ignorance)? 22:11
moritz can give an example for "different measures for success/failure"?
I just expect an interactive shell to print the results of an expression right after it is typed 22:12
otherwise it should behave identical, right?
offby1 nods gravely
22:16 amnesiac joined 22:17 lisppaste3 joined
diakopter well, interactive perl5 is the debugger, right? And surely there are (perhaps subtle or irrelevant) differences between its behavior and normal execution. 22:23
I know that's not an example. I'm working on it... and learning more as I go. Thanks (seriously!) for stating the obvious, moritz. 22:24
22:28 semifor_ joined
offby1 Hey! Stating the obvious is _my_ job. 22:31
moritz offby1: I thought yours was to be off by one
;-)
TimToady perhaps the obvious is off by one 22:33
diakopter I think I'm off by one rocker. 22:34
offby1 moritz: that's not my job; that's just who I am.
moritz offby1: sorry, an internal pointer was off by... 22:35
offby1 considers changing his nick to something dull 22:36
moritz offby1: don't do that ;) 22:37
diakopter offby1: how about something shinier: offbyMinus1 22:38
offby1 eww, not shiny at all.
22:42 IllvilJa joined
diakopter my musings/questions have morphed into: is a Perl 6 interactive debugger part of the language specification (by the auto-inheritance clause of "everything else is like perl"), or is it explicitly left up to the language implementer? Does an implementation need an interactive mode to be a valid implementation? 22:42
22:43 obvio171 joined
offby1 excellent questions. 22:43
wish I had a clue as to their answers.
moritz diakopter: I think in p5 the debugger is part of the implementation, not of the language 22:44
diakopter: and I guess it's the same for p6
but that's just intuition
22:46 mako132_ joined
TimToady if the language provides enough metadata about the program to drive an IDE, there's enough to debug, I suspect 22:46
diakopter should I consider that answer a "we'll see..."?
or, "hopefully"? 22:47
TimToady maybe it's a question: "Do you know any IDE experts?"
22:48 polettix joined 22:49 obvio171 joined 22:53 prism joined
diakopter friend from my college-era is a pm at msft in the visual studio group. I doubt he'd be much help though. I'm guessing there are people around here who could contribute, given different circumstances (I don't know what those are). I think what you're saying is that it would be nice for it to be debuggable/IDEable, but it might turn out that the language's higher priority of goal of having extreme dynamism might ultimately prevent that 22:56
22:58 nperez joined
Khisanth debuggable is great but if you start requiring an IDE to write a program then there is something wrong with your language :) 23:00
TimToady the point is not to require an IDE, but to require the metadata that an IDE or debugger needs 23:01
it's perfectly fine to throw the metadata on the floor and just coredump. :) 23:02
moritz I'm a bit concerned... the metadata may rely heavily on what's going on in BEGIN blocks - and there may be unsafe operations in BEGIN
so just viewing a perl script in an IDE might execute unsafe operations (if poorly implemented; if not, the metadata will be partially wrong) 23:03
TimToady perhaps BEGIN can run in some kind of sandbox 23:04
moritz hm 23:05
still ugly ;)
TimToady not looking for beautiful here, but powerful
Khisanth is this anything like the perl5 situation were you program would only work/not work inside/outside the debugger? :) 23:06
QtPlatypus Damn hisenburges.
Khisanth hisenbugs! 23:07
offby1 "Heisenbugs", please. 23:08
QtPlatypus accepts the correction.
Khisanth hi on bugs
oops high :)
svnbot6 r16237 | moritz++ | [irclog] 23:12
r16237 | moritz++ | * added search for nicks
r16237 | moritz++ | * refactored much of the code of out.pl to use it in search.pl
r16237 | moritz++ | * removed hardcoded constants from index.pl
r16238 | moritz++ | [irclog] links to search, a bit more refactoring 23:18
23:35 mako132_ joined 23:41 rashakil_ joined 23:42 SubStack joined 23:49 obvio171 joined