6.2.7 released! | pugscode.org/ <Overview Journal Logs> | pugs.kwiki.org | paste: sial.org/pbot/perl6
Set by autrijus on 13 June 2005.
pasteling "Obra" at 209.6.22.26 pasted "Why does thsi code not parse?" (5 lines, 86B) at sial.org/pbot/11116 00:15
kelan obra: i don't think you can use a pointy block as an argument to while 00:16
obra kelan: see S04
It is possible to write 00:17
while =$*IN -> $line {...}
But it won't do what you expect, because unary "=" does a slurp in scalar context, so
$line will contain the entire file.
Note that Patrick mailed a change to that "But" caveat today that I wanted to test in pugs.
Er, that Note was poorly phrased
kelan well you didnt write that. you missed the `=` in front of the $*IN 00:19
maybe thats the problem?
obra Thank you
PEBCAK
kelan seems like it should work anyway
and pass the filehandle to $line
obra Though actually, it fails too
unexpected ">" or "w"
expecting ";", statements or end of input
reserved word
at /tmp/foo line 4, column 1
kelan maybe pugs just doesnt parse it yet?
arcady pugs doesn't parse while with pointies 00:25
pugs also doesn't like map @list -> { stuff } 00:26
you need a comma between the @list and the ->
cognominal what is the best kwid formatter? 01:29
is that Ingy Kwid on cpan? 01:30
mugwump hey cognominal, I was talking to ingy earlier and at the moment there is no prototype other than stevan's Perl 6 one available 01:40
cognominal how do I use stevan's one?
autrijus.org/tmp/perlkwid.kwid speaks of a pugsdoc but I can;t see any 01:41
oh, Sam, you are in New-Zealand? 01:42
mugwump I am
cognominal I met you in yapc at Paris, I think
mugwump that would have been 2003 ... who are you in RL? /msg if you like :) 01:43
cognominal Stephane Payrard
a tall French guy 01:44
mugwump Yes I remember having a long conversation with you in the back of that bar
cognominal yea, right 01:45
mugwump "that" bar being utsl.gen.nz/milk.jpg
cognominal no, probably another one :) 01:46
_meppl_ gute nacht - good night 01:51
formalin14 I have installed perl6(pugs). Where is the parrot compiler for perl6? 03:26
mugwump CPAN 03:27
search.cpan.org/dist/parrot/
you'll need 0.2.1 for recent pugs builds 03:28
formalin14 thanks 03:29
does the download from www.parrotcode.org include compiler for perl6? 03:30
mugwump no, pugs is the prototype perl 6 compiler 03:33
formalin14 what C compiler and make program you use on Windows? 03:34
mugwump on windows you probably want pixigreg.com/?pxperl 03:35
formalin14 ok, I have saw pxperl, it looks very good.
putter Hi mugwump. 03:43
svnbot6 r4706, putter++ | To Emit/Prim.hs, added NUM registers, + - * /, and the rest of ops/math.ops. 03:50
sdtr443w Is there any examples of continuations in Perl 6 yet? 03:52
putter I think I mostly did Emit/PIR instead. Got math.ops in. In the process of figuring out parrot, wrote a whole lot of haskell which didnt end up in the final version. Eh, good practice. 03:53
Looks like svnbot is down.
sdtr443w Was there a split? 03:55
wolverian yes
sdtr443w I got on the channel at a strange time then 03:56
wolverian yes. :) 03:58
04:00 _jql is now known as jql
sdtr443w I'll hold my breath and wait to ask all my irritating questions then. I wouldn't want to leave anybody out. 04:01
wolverian no, the split should be over now 04:04
sdtr443w Oh darn I was hoping I just wasn't going to get an answer haha 04:05
Wait that didn't come out right . . .
wolverian sdtr443w: pugs's continuation support is slightly flaky at the moment. 04:08
sdtr443w: search perl6-language for continuations if you want to see discussion 04:09
sdtr443w hmm ok. I was interested in how there were implementing continuations in a mostly procedural language. 04:13
wolverian parrot. 04:14
sdtr443w I'm trying to present the current syntax at work, and it's going to be a bear since continuations will be new to them, and also because they're being used outside their normal context.
in my opinion
to be honest though, I haven't used them much myself.
wolverian right. 04:15
sdtr443w Am I correct that when using a reference type I get the first reference for free? It's the impression I got from some examples. 04:20
Or rather, the first [de]reference
wolverian er, what do you mean exactly? 04:22
code example would be nice :)
sdtr443w Well I don't know where I got it but . . . 04:23
An array reference in perl 5 would be done with $foo->[$n]
formalin14 What is the language used to develop parrot runtime?
sdtr443w In Perl6, the claim is: $foo[$n]
Are they not talking about a reference type there? 04:24
wolverian that's a dereference. yes, perl6 references pretend they're not references most of the time, so you can just do $foo[$bar]
formalin14: C.
formalin14 3x
thanks
sdtr443w If I have a reference to a reference, do I start stacking on the dollar signs? 04:25
wolverian I'm not sure.
there was a very recent discussion on perl6 about the depth of autodereferencing, I think 04:26
sdtr443w ok then...
I have one last question I think is better suited to the newsgroup/mailing list, but I guess I can try it here. 04:27
I don 't really grok a line in Exegesis 4: "when 'previous' { return %var{""} // fail NoData }"
They make it sound like if previous is undefined, fail out. What I don't like about that is there is a when statement right underneath.
wolverian I don't think that is legal nowadays. I _think_ when is a statement, not an expression 04:28
sdtr443w It was part of a larger "given" block
wolverian (exegeses are not updated. only synopses are.)
sdtr443w oh gosh
wolverian yes, when is a statement. 04:29
so you can't use it in an expression like that without wrapping it in a do { }
which leads me to assume the whole thing is bogus :)
sdtr443w I don't know -- the synopsis seems to jibe
You saying it's illegal in the context of it being wrapped in a given { } block? 04:31
Oh I'm starting to see what that line was doing. 04:32
wolverian sdtr443w: I am saying that using a 'while { }' in an expression is illegal 04:39
putter Anyone looking for tasks could create Emit/PIR.hs versions of Prim.hs ops. 04:43
Or figure out how parrot's namespace and lookup stuff works.
Once we can do parrot namespaces, specifically Perl6::Internals, then Prim.hs ops can be pushed into Perl6::Internals, and wrapped by p6 modules. 04:44
Good night. & 04:45
Darren_Duncan I found what appears to be a Pugs bug 05:36
simply querying a value from a hash creates a corresponding key in the hash
svnbot6 r4707, andras++ | vmethods: and more math again: is_divisible_by 05:41
Darren_Duncan ?eval my %foo = {1=>2,3=>4}; "{%foo}"; 05:56
evalbot6 '12 34 '
Darren_Duncan ?eval my %foo = {1=>2,3=>4}; "{%foo.pairs.join(','}"; 05:57
evalbot6 Error: unexpected "j" expecting term postfix, operator, postfix conditional, postfix loop, postfix iteration, ";" or "}"
Darren_Duncan ?eval my %foo = {1=>2,3=>4}; "{%foo.pairs.join(',')}";
evalbot6 '1 2,3 4'
Darren_Duncan eval my %foo = {1=>2,3=>4,5=>6}; "{%foo.pairs.join(',')}"; 05:58
foo
?eval my %foo = {1=>2,3=>4,5=>6}; "{%foo.pairs.join(',')}"; 05:59
evalbot6 '1 2,3 4,5 6'
Darren_Duncan ?eval my %foo = {1=>2}; "{%foo.pairs.join(',')}";
evalbot6 '1,2'
Darren_Duncan looks like a bug to me
the last pairs() should return a single pair, but it returned a 2 element list instead
wolverian Darren_Duncan: yes. is there a test for it? 06:06
Darren_Duncan I don't know ... I found this out through trial and error while trying to get Locale-KeyedText to work
if not, one should be created ... if necessary, I'll do it 06:07
I'm still trying to isolate the other bug where simply reading a hash will add a key to it
but at least the single-pair hash bug is easy to reproduce
lumi_ Hi nothingmuch
nothingmuch hola 06:08
Aankhen`` Mawning.
Darren_Duncan another apparent bug is that calling .does(Pair) on a Pair::HashSlice returns false 06:13
wolverian is that a bug?
Darren_Duncan well, a Pair::HashSlice has a .key and a .value that can be read from, as a Pair does 06:14
it is the output of a normal %hash.pairs()
each element of said output
wolverian that's weird. 06:15
QtPlatypus Does making a pair supposed to stringafy the key? I thought the hash was supposed to be based on the .id of the hash? 06:16
Darren_Duncan the thing that gets to me the most, though (and it might be to the spec) is how hashrefs and arrayrefs like to turn into lists at every opportunity ... I have to keep assigning function args to a scalar, or return value of a function to a scalar, so they can be used properly
a Pair stringifies to its key and value with a space between, currently, as does a List or Array 06:17
wolverian refs never turn to lists magically.
Darren_Duncan well, thats happening to me 06:18
nothingmuch wiki.yapctoronto.org/index.cgi?ArrivalRSVP
wolverian I should have said - they aren't supposed to :)
nothingmuch they're making reservations, so put yourself down
Darren_Duncan they are doing so every time they are in a list context
QtPlatypus Darren_Duncan: Thats not what I was talking about. Hold on I'll try to replicate it with evalbot
wolverian Darren_Duncan: that is very broken. 06:20
pugs> (want,[9..12])
('List (Any)', {ref:<Array>})
the naive case works on feather :)
(r4691)
QtPlatypus ?eval my @rray=<a b c d e f>; my %foo = {@rray => 1};%foo.keys.perl
evalbot6 '(\'1\', \'a\', \'c\', \'e\')'
wolverian heh. easier to read without the .perl, maybe 06:21
QtPlatypus ?eval my @rray=<a b c d e f>; my %foo = {@rray => 1};%foo.keys
evalbot6 ('1', 'a', 'c', 'e')
wolverian that's supposed to happen. well, besides the fact that assigning a hashref to a hash shouldn't be making it a hash.
QtPlatypus wolverian: Why is that supposed to happen? 06:22
Darren_Duncan ?eval sub bar( $foo ) { "{$foo.ref}" } foo( {1=>2,3=>4} );
evalbot6 Error: No compatible subroutine found: "&foo"
Darren_Duncan ?eval sub bar( $foo ) { "{$foo.ref}" } bar( {1=>2,3=>4} );
evalbot6 'List'
Darren_Duncan now, I didn't pass in a List, but a Hash
see my workaround ... 06:23
QtPlatypus ?eval my $foo = {[<a b c d e f>] => 1};$foo.keys
evalbot6 ('1', 'a', 'c', 'e')
wolverian Darren_Duncan: now, that seems a bug
Darren_Duncan ?eval sub bar( $foo ) { "{$foo.ref}" } my $temp = {1=>2,3=>4}; bar( $temp );
evalbot6 'Hash'
Darren_Duncan see the difference?
wolverian Darren_Duncan: yes. seems to be {}s are broken :)
Darren_Duncan that's not all 06:24
it happens with Arrays too
and Pairs
I wasn't sure whether or not this was supposed to happen or not 06:25
nothingmuch wow, some spammer is nice enough to try random login names (peter, bob, etc) on woobling.org, but since i had cable problems yesterday the backup MX accepted them
so now they're bouncing back to [email@hidden.address] which is aliased to me
*sigh*
QtPlatypus mmmms a bit
?eval my $foo = ([<a b c d e f>] => 1);$foo.keys
evalbot6 (['a', 'b', 'c', 'd', 'e', 'f'])
QtPlatypus ?eval my $foo = ([<a b c d e f>] => 1);$foo 06:26
evalbot6 (['a', 'b', 'c', 'd', 'e', 'f'] => 1)
Darren_Duncan the cause of the problem is that the variable is passed as a sub/method argument, which imposes a list context
it seems
since array/hash etc constructors auto become a list in list context or a ref in scalar context, I was forcing scalar with the $temp 06:27
QtPlatypus I see what was happening {} was being considered as being a block.
Darren_Duncan I'm not sure if its supposed to do that or not
what you say is true if it is empty or has no => at its start
but if it does have a =>, then it should be interpreted as a hash
this is what I see in the Synopsis, and also what Pugs currently does 06:28
QtPlatypus I't doesn't look like my example was.
?eval my $foo = ([<a b c d e f>] => 1);$foo
evalbot6 (['a', 'b', 'c', 'd', 'e', 'f'] => 1)
Darren_Duncan your example has the => in it
QtPlatypus ?eval my $foo = {[<a b c d e f>] => 1};$foo
evalbot6 {('1' => undef), ('a' => 'b'), ('c' => 'd'), ('e' => 'f')}
Darren_Duncan the => is enough to make it a hash
QtPlatypus What is the one with the {} 06:29
's doing in this case?
Darren_Duncan a plain old {} will make a block
to make an empty hash, use hash()
Synopsis 5 i think 06:30
QtPlatypus Shouldn't my second example be treated as a hash since it has a => in it?
Darren_Duncan your last example did not have a => at the root level
mind you ...
nevermind
QtPlatypus It didn't?
Darren_Duncan ?eval my $foo = {[<a b c d e f>] => 1};$foo.ref 06:31
evalbot6 ::Hash
Darren_Duncan your last example is a Hash
so no worries there
QtPlatypus What it looks like is happening is that the stuff in the [<...>] is getting flattened? Sould it be flattened like that?
Darren_Duncan ?eval my $foo = {}; $foo.ref
evalbot6 ::Bare
Darren_Duncan ?eval my $foo = hash(); $foo.ref 06:32
evalbot6 ::Hash
Darren_Duncan I think it is supposed to flatten
Aankhen`` Hmm.
Darren_Duncan or maybe not 06:33
Aankhen`` Try as I may, I cannot get this file to parse.
QtPlatypus That doesn't seem like usefull behavour, If I wished to have it flatten i wouldn't put []'s around it.
Aankhen`` So I'm going to commit it under t_disabled/ and hope someone can help.
Darren_Duncan I seem to recall that you can use anything as a hash key, including an object or reference
give me a few minutes and I'll commit my recent work ... 06:34
QtPlatypus Darren_Duncan: In some of the stuff I've been doing the objects seem to loose there object nature.
And end up normal strings. 06:35
Darren_Duncan in Perl 5 that happens, I haven't tried it in Perl 6 yet
I mean when used as hash keys 06:36
Aankhen`` D'oh!
Darren_Duncan figured it out eh?
Aankhen`` Yep.
Aankhen`` looks ashamed.
autrijus rehi \camels! 06:37
Aankhen`` Morning autrijus. :-)
Darren_Duncan morning
autrijus I'm reading up on Boo. it looks wonderfully like perl 6.
Darren_Duncan I'm about to commit a big LKT change, then want to talk about it
I discovered several Pugs bugs and/or apparent mis-features
QtPlatypus ?eval my %hash = (Object.new => "foo");%hash.perl
evalbot6 '{(\'<obj:Object>\' => \'foo\')}'
autrijus In fact, I think it's much better than PyPy to copy from.
nothingmuch Boo? 06:38
autrijus nothingmuch: boo.codehaus.org/ -- read the manifesto
QtPlatypus The object looks like it gets stringafied, and that seems to be what happens in my code as well.
svnbot6 r4708, Aankhen++ | * added adverbial_modifiers.t under t_disabled due to parsefail. Help!
r4709, Aankhen++ | * t_disabled/adverbial_modifiers.t -- fixed parsefail.
r4710, Aankhen++ | * moved adverbial_modifiers.t to t/operators/
autrijus it's very well thought out... almost all perl6's core language "highlights" are supported one way or another 06:39
QtPlatypus: right, hash is shaped as (key=Str, val=Any) by default
QtPlatypus: there's currently no other IHash type
QtPlatypus: but writing a IHashAny will get you key=Obj
but bear with me a bit... I've slept for 6hr only and just woke up 06:40
Aankhen`` ?eval sub prefix:<blub> (Str $foo, Int +$times) { ("BLUB" x $times) ~ $foo }; blub "bar"; 06:41
evalbot6 Error: No compatible subroutine found: "&blub"
Aankhen`` ?eval sub prefix:<blub> (Str $foo, Int +$times) { ("BLUB" x $times) ~ $foo }; blub"bar"; 06:42
evalbot6 Error: No compatible subroutine found: "&blub"
autrijus ?eval sub blub (Str $foo, Int +$times) { ("BLUB" x $times) ~ $foo }; blub"bar";
evalbot6 'bar'
Darren_Duncan committed as 4711
autrijus Aankhen``: parser bug I think... the prefix: should be removed for nonsymbolics
Darren_Duncan 20_TrnProps passes all tests
10_MsgProps would pass all tests were it not for Bugs in Pugs 06:43
Aankhen`` Ah.
Darren_Duncan once y'all update you can see what I mean
QtPlatypus autrijus: I guess I'll have to learn haskal then. 06:44
svnbot6 r4711, Darren_Duncan++ | large Locale-KeyedText change set : changed all plural object properties to be refs to hashes/arrays rather than hashes/arrays; likewise all plural arguments and retvals are now refs; plural properties are now copied on input/output; updated LKT_10_MsgProps.t and LKT_20_TrnProps.t and t_LKT_Util.pm to work around an apparent Pugs misfeature where Hash|Array|Pair auto-become List when given as arguments; workaround a Pugs bug where sin
autrijus QtPlatypus: walked thru nothingmuch's harrorth journal yet?
QtPlatypus autrijus: No please throw me a URL. 06:45
Darren_Duncan autrijus, the most serious Pugs bug I encountered can be easily illustrated by comparing the following 2 examples ... 06:47
?eval my %foo = {1=>2,3=>4,5=>6}; "{%foo.pairs.join(',')}";
evalbot6 '1 2,3 4,5 6'
Darren_Duncan ?eval my %foo = {1=>2}; "{%foo.pairs.join(',')}";
evalbot6 '1,2'
Darren_Duncan the first example shows 3 pairs separated by commas; the second shows 2 scalars, the one Pair was split up
fix this and 2 of my failing tests will work 06:48
autrijus QtPlatypus: perlcabal.org/~nothingmuch/harrorth/
Darren_Duncan: is there a standalone test for it? 06:49
Darren_Duncan I don't know
autrijus t/data_types/*
hm, not sure
Darren_Duncan in any event, all the problems I found were when trial-and-erroring LKT
autrijus the test is t/builtins/arrays_and_hashes/pairs.t
but your example is not in there 06:50
can you spare a moment to add it in there so it's easier to track? I'll fix it right away.
Darren_Duncan will do
autrijus danke
Aankhen`` Um. 06:52
Darren_Duncan >> You're using {...} to assign to a hash?
Doesn't that create a hash ref?
Darren_Duncan it should, but currently those flatten anyway
Aankhen`` Ah.
autrijus ?eval my %foo = (1=>2); "{%foo.pairs.join(',')}";
evalbot6 '1,2' 06:53
Aankhen`` ?eval my %foo = (1=>2,3=>4,5=>6); "{%foo.pairs.join(',')}";
evalbot6 '1 2,3 4,5 6'
autrijus Aankhen``: currently the % in %foo is just a cxt hinter.
Aankhen`` OK.
Darren_Duncan same result, see
autrijus Aankhen``: so you can store a Ref in it.
gaal_ is there someinth akin to p5 STDIO in p6?
autrijus I'm unsure of whether it's a bug or a feature or both.
Aankhen`` Darren_Duncan >> I thought it would be, I just wanted to do it for the sake of completeness. :-)
gaal_ ie stdin+stdout
Darren_Duncan ?eval my $foo = (1=>2,3=>4,5=>6); "{$foo.pairs.join(',')}";
evalbot6 '0 1 2,1 3 4,2 5 6'
Aankhen`` autrijus >> Say it's a feature till someone complains? ;-)
autrijus gaal_: there is no such thing as STDIO in p5. 06:54
Darren_Duncan ?eval my $foo = {1=>2,3=>4,5=>6}; "{$foo.pairs.join(',')}";
autrijus Aankhen``: it's a feature :)
evalbot6 '1 2,3 4,5 6'
Aankhen`` autrijus >> Roger!
06:54 gaal_ is now known as gaal
gaal isn't there? 06:54
Darren_Duncan ?eval my $foo = {1=>2}; "{$foo.pairs.join(',')}";
evalbot6 '1,2'
Darren_Duncan I normally use the $ form anyway, and here it gives the same result
Aankhen`` Darren_Duncan >> I see that. 06:55
?eval 1 => 2
gaal eek, you're right. now why did i think there was?
evalbot6 (1 => 2)
autrijus it's actually a join bug.
?eval my %foo = (1=>2); %foo.pairs;
evalbot6 (\('1', 2))
autrijus ?eval my %foo = (1=>2, 4 => 5); %foo.pairs;
evalbot6 (\('1', 2), \('4', 5))
autrijus look, completly sane
?eval my %foo = (1=>2, 4 => 5); join '---', %foo.pairs; 06:56
evalbot6 '1 2 4 5'
autrijus basically join() is borked. fixing
Khisanth where did the --- go?
autrijus er, newlines.
?eval my %foo = (1=>2); (join '---', %foo.pairs).perl;
evalbot6 '\'1 2\''
autrijus ?eval my %foo = (1=>2, 4 => 5); (join '---', %foo.pairs).perl;
evalbot6 '\'1 2 4 5\'' 06:57
autrijus hmmmmm
obra ?eval for ('q','e') -> (say $_)
autrijus ?eval for ('q','e') -> { say $_ }
QtPlatypus obra: evalbot doesn't know about say
Darren_Duncan join() isn't the problem by itself; try doing a map:{} on the pairs() that invokes .key or something
evalbot6 Error: No compatible subroutine found: "&say"
Darren_Duncan program crash
autrijus ?eval gather @_ { for ('q','e') -> { take $_ } }; @_
evalbot6 Error: unexpected "{" expecting operator, postfix conditional, postfix loop, postfix iteration, ";" or end of input
autrijus ?eval gather { for ('q','e') -> { take $_ } } 06:58
evalbot6 ('q', 'e')
autrijus there.
obra ?eval gather { for ('q','e') -> $foo { take $_ } }
autrijus don't add space before ?eval
obra urg. paste fault
?eval gather { for ('q','e') -> $foo { take $_ } }
evalbot6 ('perl6', 'perl6')
autrijus wwwwwwtf?
obra grins
autrijus ah. it's correct in a sense ;) 06:59
it took the outer scope's $_
obra not according to A06
Darren_Duncan ?eval my $foo = {1=>2,3=>4,5=>6}; "{$foo.pairs.map:{.key~'='~.value}}";
evalbot6 '1=2 3=4 5=6'
obra at least according to one interpretation
Darren_Duncan ?eval my $foo = {1=>2}; "{$foo.pairs.map:{.key~'='~.value}}";
obra Methods, submethods, macros, rules, and pointy subs all
evalbot6 Error: cannot cast from VStr "1" to (Pugs.AST.Internals.Val,Pugs.AST.Internals.Val)
obra bind their first argument to C<$_>;
Darren_Duncan now see ...
that's how I FIRST encountered the problem
and no join in sight (here) 07:00
my join() example just better illustrates that pairs() is the piece at fault
autrijus obra: a bug. test?
obra was going to sleep, but ok. where should it live? 07:01
autrijus t/subroutines/whatever.t
dollar_underscore.t
nothingmuch boo sounds cool 07:03
maybe he should target parrot ;-)
autrijus Darren_Duncan: unfortunately, it's a class of problem plagueing all list/array methods.
Darren_Duncan: I'm fixing it :)
obra autrijus: I'd named it that before flipping back to this screen to see that you had too
nothingmuch goes to learn some Qt and write chapter 8 07:04
autrijus obra: heh cool
autrijus hopes Qt and ch8 are not related
Darren_Duncan autrijus, this is another thing, perhaps related ... 07:05
?eval sub bar( $foo ) { "{$foo.ref}" } my $temp = {1=>2,3=>4}; bar( $temp );
evalbot6 'Hash'
Darren_Duncan compare to
nothingmuch no, they aren't =)
Darren_Duncan ?eval sub bar( $foo ) { "{$foo.ref}" } my bar ( {1=>2,3=>4} );
evalbot6 Error: unexpected "{" expecting variable name, "undef" or ")"
Darren_Duncan one sec
?eval sub bar( $foo ) { "{$foo.ref}" } my bar( {1=>2,3=>4} );
evalbot6 Error: unexpected "{" expecting variable name, "undef" or ")"
Darren_Duncan again 07:06
?eval sub bar( $foo ) { "{$foo.ref}" } bar( {1=>2,3=>4} );
evalbot6 'List'
Darren_Duncan see, 'Hash' became 'List', and I didn't want it to
the same thing happens with 'Array' and 'Pair' when passed as argument 07:07
putting in all those $temp is troublesome
but this may also be a symptom of a deeper problem affecting other things
autrijus nod. 07:10
there are more than one bug here.
obra autrijus: committed
autrijus I'd appreciate if they are in a unit-by-unit form so I can test my fixes against... maybe stash them all into t/pugsbugs/ for now?
obra++
obra -> sleep. 07:13
ingy hi obra, autrijus 07:14
obra hey ingysan
er. autrijus, is openfoundry the canonical repo these days? 07:15
svnbot6 r4712, jesse++ | * Tests for pugs breakage when using the $_ implicit param after declaring a param 07:16
r4712, jesse++ | According to A06:
r4712, jesse++ | Methods, submethods, macros, rules, and pointy subs all
r4712, jesse++ | bind their first argument to C<$_>; ordinary subs declare
r4712, jesse++ | a lexical C<$_> but leave it undefined.
obra ah, yes :)
ingy obra: did you see doolittle?
obra ingy: no. whatis? 07:17
ingy obra: oh... hmm hold on
obra: doolittle.kwiki.org/ 07:19
so the idea is that everyone can write the *real* Kwiki/Spoon doc now 07:20
changes get saved right into the modules
which I can later release to cpan
obra ah. you finally did it. cool
ingy :)
so I want to open this up as a general service
Darren_Duncan committed 4713 ...
has the pairs() test added to pairs.t as autrijus requested 07:21
ingy and i was thinking that anyone with a FreePAN account should get this for free
svnbot6 r4713, Darren_Duncan++ | updated test t/builtins/arrays_and_hashes/pairs.t to check that pairs() on single and double element hashes returns one or two pair objects respectively
ingy which would be great for freepan. then I was thinking there should be some RT tie-ins too 07:22
which brings me to you!
Darren_Duncan of course, 2 of the 4 added tests fail ... of those the second crashes the program
ingy obra: oh, btw, gugod and I are writing Kwiki::Archive::Simple which just uses files and dirs. The big advantage is that you'll be able to delete spam with simple unix commands find/grep/xargs/rm etc 07:23
obra nice 07:24
Darren_Duncan another bug I discovered, which I still have to isolate, is why simply reading a hash element that doesn't exist will add that key to the hash
obra ingy: we should talk rt tieins when I'm more awake and less eyes-crossy
Darren_Duncan meanwhile, you can see it when running LKT_10_MsgProps.t; see the last 6 or so tests in it 07:25
obra -> thud, really
ingy obra: fair nuff 07:28
Aankhen`` ?eval my %foo = (); %foo<bar> 07:56
evalbot6 \undef
Aankhen`` ?eval my %foo = (); %foo<bar>; %foo.exists("bar");
evalbot6 bool::true 07:57
Aankhen`` ?eval my %foo = (foo => "bar"); %foo.exists('foo')
evalbot6 bool::true
Aankhen`` ?eval my %foo = (foo => "bar"); (%foo.exists('foo'), %foo.exists('bar'));
evalbot6 (bool::true, bool::false)
Aankhen`` ?eval my %foo = (foo => "bar"); (%foo.exists('foo'), %foo<bar>, %foo.exists('bar')); 07:58
evalbot6 (bool::true, \undef, bool::true)
Aankhen`` Darren_Duncan >> If you're busy, should I write the test?
Darren_Duncan just a minute
Aankhen`` ?eval true
evalbot6 Error: unexpected end of input expecting term
Aankhen`` Bleh.
OK.
Darren_Duncan you can go ahead 07:59
Aankhen`` A'right.
Darren_Duncan I'm still isolating it in a different way
Aankhen`` Hmm. 08:03
The bug doesn't seem to be there on my build...
?eval $?PUGS_VERSION
evalbot6 \'Perl6 User\'s Golfing System, version 6.2.7, June 13, 2005 (r4691)'
pasteling "Aankhen``" at 203.101.16.84 pasted "Reading an inexistent hash key" (5 lines, 212B) at sial.org/pbot/11124 08:04
Aankhen`` Seems to be fixed in later builds...
gaal autrijus + other lambdafolk: www.haskell.org/tmrwiki/ArrowsIntroduction 08:05
Darren_Duncan ?eval sub baz( Any $input ) {} my $foo; baz( $foo{'zzz'} ); baz( $foo{'bar'} ); "{$foo}";
evalbot6 'bar zzz '
Darren_Duncan there's my isolation
of the hash problem 08:06
the symptom only occurs if you put the read value as a sub argument
Aankhen`` I think you should wait for evalbot6 to recompile.
Darren_Duncan my machine is on the latest Pugs version and has the symptom 08:07
4713
Aankhen`` OK.
Darren_Duncan Aankhen, if you're still writing a test for this, try to include something like what I eval'd above, and credit me for the research 08:08
Aankhen`` Could you write the test? I have to run now...
Darren_Duncan okay
Aankhen`` (I wrote a test, discovered that it passed on my machine, and deleted the file [earlier]) 08:09
Darren_Duncan but I won't be including any of that exists stuff you were doing
Aankhen`` BBL, haircut. &
Darren_Duncan sub baz( Any $input ) {} my $foo; baz( $foo{'zzz'} ); baz( $foo{'bar'} ); "{$foo.pairs.join(',')}" 08:10
?eval sub baz( Any $input ) {} my $foo; baz( $foo{'zzz'} ); baz( $foo{'bar'} ); "{$foo.pairs.join(',')}"
evalbot6 'bar ,zzz '
Darren_Duncan brb 08:11
okay, committed some tests that hashes don't gain elements as a side-effect of being read from 08:44
svnbot6 r4714, Darren_Duncan++ | added test set to t/builtins/arrays_and_hashes/exists.t that asserts hashes will not gain elements just because someone reads from them
Darren_Duncan I put them in exists.t since it was the closest related conceptually; if that was wrong, feel free to split out 08:45
I'm going to bed now ... at almost 2am ... good night 08:47
chip Anybody else running screen on feather? 09:31
09:39 Boogie___ is now known as Boogie
nothingmuch chip: I can run it if you like ;-) 09:42
chip I'm just seeing some display artifacts. Missing spaces .. and for a while, #perl6 was actually "pound perl6". Like, british pound sterling 09:43
nothingmuch heh
i've never used screen because my prompt includes a ā€¢ and i never had any time to find out to get it properly displayed 09:44
nothingmuch just realized it was pointless to type a ā€¢ since you can't see ā€¢'s under screen. what it is a bullet, like what you see when you fill in a password box
and the reason it's there is that my bash prompt function will color it red or green based on the exit code of the last command 09:45
lumi Why not?
screen -U 09:46
nothingmuch chip: I guess that's your answer ;-)
gugod pugs.kwiki.org is getting spam :(
nothingmuch gugod: yeah, i've cleaned some on several occasions
lumi++
i think i'll start learning to use screen now =D
chip it's back 09:47
&perl6
ōæ½xA3perl6 even
My kde terminal doesn't understand utf8 though. Hm.
or maybe it does...
nothingmuch שלום! 09:48
did that look like latin or hebrew?
gugod ā™Ø
chip that looks like x copyright x reverse-\ x reverse-U x reverse-] !
nothingmuch i'm sending out utf8 09:49
and I saw gugod's hot spring
gugod Kwiki is kinda weak when rendering massive spam links 09:52
nothingmuch kwiki is always pretty slow 09:53
on small chunks of data it just doesn't matter
gugod HomePage was having 70KB of "..." , and it consumes >100MB to render it
and never finished
lumi I think the screen needs to be originally launched -U, and then you go /set term_type utf-8 in irssi
That is, screen -U irssi, and not just reattaching to an old, formerly non-utf8 screen, but I might be mistaken 09:54
gugod you can do ":encoding utf8 utf8" for old screen too 09:55
formalin14 does perl6 have pragmas? 10:18
crysflame did you have any specific ones in mind?
autrijus formalin14: yes, perl6 does. pugs however does not because we don't yet have a compiler. I'm however working on it. 10:21
formalin14 how to use perl5's pragmas? 10:22
meppl formalin14, use modulename; 10:26
formalin14 ?
meppl "use modulname;" 10:27
pjcj las cover 10:28
formalin14_ to use perl5 module: use LWP::Simple--perl5; but how to export functions? 10:32
use POSIX--perl5 qw(strftime); not ok
use strict--perl5 "vars", "subs"; not ok too 10:33
10:35 formalin14_ is now known as formalin14
mugwump formalin14: at the moment, I think you need to use only OO interfaces 10:38
formalin14 what is the multi-thread module in pugs? 10:39
meppl i would ask, if it still exists 10:44
mugwump there has been threading support via GHC
have a look at autrijus' recent paper 10:45
nothingmuch oh my, ch8 is getting long 10:46
mugwump ch8? 10:51
formalin14 wondering too 10:52
lumi_ Maybe divide it 11:05
cognominal autrijus, what do you use to format kwid docs? 11:18
autrijus cognominal: Spork::Formatter::Kwid 11:28
cognominal Spork will eat the world... 11:30
autrijus.org/tmp/perlkwid.kwid # is this a reference document?
autrijus yeah 11:31
cognominal I see there is an kwid event parser in pugs 11:32
autrijus it's stevan's. right 11:34
Gruber hmm 12:20
tobez@hrum src/pugs> ./pugs -e '"hello, world".reverse.say; my $x="hello, world"; $x.reverse.say'
hello, world
dlrow ,olleh
autrijus notes something about list context reverse. 12:22
but I'm not sure if that is relevant here. looks like the same list/array bug darren ran into. hmm. but I need to run to lunch now. bbiab... 12:23
mugwump ā™Ø āˆ‹ ā˜ŗ 12:42
nothingmuch is there a word meaning "reschedule to an earlier date"? 12:43
chapter 8 is done
mugwump "to bring forward"
nothingmuch in the context of elections? do you "bring forward the elections"? 12:44
mugwump yes, or "bring the elections forward"
or just "have early", perhaps. as in "have the elections early" 12:45
nothingmuch darcs pull 12:49
feedback on chapter 8 more than welcome 12:50
there's a known bug though
pasteling "gaal" at 192.115.25.249 pasted "Emit.PIR compilation warnings (linux)" (20 lines, 1.3K) at sial.org/pbot/11132 13:26
autrijus gaal: known :)
gaal k :)
did you see that link about arrow?
autrijus gaal: you're welcome to add signs 13:27
gaal arrows
autrijus gaal: yes and I surveyed parrow
it doesn't looks like production grade now
I'd wait until it can be more or less a dropin for parsec
(and also ghc runs monads faster than arrows, last I heard, so the space leak optimisation may not worth it)
gaal oh 13:28
it looked like for parsers it can work faster 13:29
not that i actually understand what "it" or "they" are.. :)
autrijus gaal: "can" as in "potentially in the future" :) 13:30
gaal ah :)
Limbic_Region autrijus - if you have time, there is a great parrot -> p6 question 14:18
perlmonks.org/index.pl?node_id=467256
I don't know how to answer it myself
ooh - didn't realize the channel was that quiet 14:19
anyone who knows how to get p6 and parrot talking to one another beyond rules support is welcome to answer btw
autrijus alright. 14:20
all pugs can compile to parrot using -BParrot
pugs -BParrot examples/mandel.p6
compiles to parrot, finds parrot in PATH, and run it.
replacing -B with -C compiles things to dump.ast. 14:21
in trunk pugs, there is a much more robust support, in the form of -BPIR and -CPIR.
Limbic_Region what about getting at Pugs from Parrot?
chip yay
Limbic_Region which I think is the root of the question
autrijus Limbic_Region: if you compile pugs with PUGS_EMBED=parrot
chip Limbic_Region: .sub foo / chdir "pugs" / .end
autrijus then you can eval perl6 using the usual compreg thing.
chip gets at pugs
autrijus see my previous p6c posts 14:22
i.e. you can eval perl 6 code from PIR
but that's all.
there is currently no support in running pugs directly from the parrot executable.
Limbic_Region would rather autrijus and/or chip answer the question by ninthwave since he feels he is likely to F it up bigtime
autrijus I can see a --with-pugs in the future.
(for parrot)
Khisanth ./parrot dump.ast is suppose to work? 14:24
autrijus Khisanth: aye 14:25
Limbic_Region ok - I will summarize this conversation as a reply and hope it suffices
autrijus gawd.
I replied it almost
and hit Ctrl-W
and this is new firefox
without extensions
oh well. 14:26
anyway, mention require_parrot() eval_parrot() primitives too
which works even with external parrot
the current help I can use is to help transcribe Pugs.Prims into Emit.PIR's prims.
Khisanth parrot has rather long op names O_O 14:29
gaal what's p6 for "$#bigarr = 65535"? 14:31
autrijus gaal: lvalue .end I think. not sure
gaal we don't have that yet, do we? 14:32
..no.
QtPlatypus @dim is shaped(0..65535);
my @dim is shaped(0..65535);
Does that sound right?
gaal could be :) what does @dim[70000] do? modulo, or error? 14:33
QtPlatypus Error IIRC
gaal ("is shape" probably)
yes, thanks, that's what s09 says 14:34
chip welcome to PL/I 14:35
gaal does this actually allocate memory?
svnbot6 r4715, iblech++ | * Added the usual svn props to t/subroutines/dollar_underscore.t and 14:36
r4715, iblech++ | t/operators/adverbial_modifiers.t.
r4715, iblech++ | * Added a test for the &prefix:<=> operator (generic iteration operator)
r4715, iblech++ | (t/operators/iteration.t).
chip I loved PL/I, actually. Even before I knew why it was different, it just seemed .... right
gaal and so can i have a class data constant saying $SIZE = 100, and then declare "has @arr is shape (0.. $SIZE-1)" ?
chip if if = then then then = else else else = end end if
QtPlatypus gaal: I expect thats an implementation issue. But I would expect that the compiler would be able to make use of the extra infomation to opimize arrays of fixxed size. Including prealocating the memory. 14:37
chip hm. I see two use cases. One is just trying to validate the indices, like locked hashes do. The other is actually planning to use the whole size every time. 14:38
gaal i like to have .end say the right thing right from start 14:39
'id
Limbic_Region my reply - perlmonks.org/index.pl?node_id=467294
gaal i'd
man i can't type
pdcawley ? eval sub foo { my sub bar { 1 }; bar(); }; foo() 14:40
?eval sub foo { my sub bar { 1 }; bar(); }; foo()
evalbot6 Error: Undeclared variable: "&bar"
gaal but actually since i need to initialize the array i just did @.arr[0 .. $MAX-1] = 0 in BUILD....
pdcawley could have sworn that something he read in an apocalypse or exegesis made that legal, but I can't find it now...
Khisanth WOW! O_O 14:41
svnbot6 r4716, iblech++ | Emit.PIR, Pugs.Compile.PIR -- Added "#ifndef HADDOCK" directives to make "make
r4716, iblech++ | haddock" work again.
Khisanth the speed difference between ./pugs examples/mandel.p6 and ./parrot dump.ast is just ...
QtPlatypus Khisanth: About 100x faster. 14:42
Skilled_sniper where ist iblechbot ?
Khisanth I think parrot does the whole thing in less time than it takes pugs to do 1 line
strange, every line with parrot seems to be constant time but pugs slows down around the "middle" of the fractal 14:43
integral is the parrot one faster than the perl5 one yet?
pdcawley That probably just means that hte parrot one *does* slow down, but that drawing to the screen is the limiting factor.
Khisanth parrot can draw to the screen faster than pugs? 14:44
iblech Skilled_sniper: Err? What do you mean?
integral Khisanth: haskell can be quite slow with strings (they're stored as cons lists)
svnbot6 r4717, iblech++ | Pugs.Prim, Prelude -- Made =$obj mean $obj.next(), as said by Damian (see
r4717, iblech++ | t/operators/iteration.t for a link to his post).
pdcawley Khisanth: No, but it can do the maths a lot quicker, so drawing to the screen takes up a greater percentage of its time.
But on thinking further, I'm probably talking utter bollocks. 14:45
pdcawley should just stick to playing world of warcraft and be done with all this technical stuff.
Khisanth EWW
integral: does not even come close to beating p5 :/ 14:46
pdcawley Is this JITted or unjitted parrot? 14:47
Khisanth not sure, how do find out?
integral iirc you'll need a very recent parrot for JIT to work
pdcawley parrot -j mandel.pasm
if memory serves.
Khisanth integral: I just checked it out not too many minutes ago :)
integral ok :-) 14:48
pdcawley Or whatever the file is...
Khisanth waits for pugs to finish running
integral is this an optimized pugs? 14:49
Khisanth integral: do the Haskell people plan to do anything about the slowness of the strings?
integral: I thought that was the default
integral there's a faster string type, pugs just doesn't use it
it's more opaque so you can't do pattern matching on it 14:50
Khisanth I mean the optimized pugs
integral if you type 'make' yes :-)
Khisanth then yes
I usually update pugs, have it start building and then go to sleep 14:51
autrijus jit unbox mandel beats p5. 14:52
but we are using boxed unoptimised parrot currently
for safety and ease of testing.
optimisation comes later.
(I benched unboxed mandel a few months ago on my journal)
even unoptimised parrot comes out to be 5% faster than optimised perl5. 14:53
(here unbox is just for literals)
Khisanth pdcawley: I don't think it's the string handling that is causing the slowdown
autrijus the slowdown in pugs's runloop is because we are running the parse tree
so all if() etc are processed in tight loop
redispatched and the closures recreated etc 14:54
Khisanth the middle part requires more if?
autrijus Khisanth: the
last() if $k > 12;
Arathorn autrijus: are you joking about targetting ecmascript/perl5, btw?
autrijus is redispatched with (Syn "if") every time
Arathorn: no.
Arathorn (or would that just be an academic exercise?)
integral looking at this new stuff, that doesn't look too hard, Arathorn :-)
autrijus Arathorn: I think a full fledged js/p5 retarget, even just for the base language (i.e. not full object model)
is maybe three days of work. 14:55
even easier if you have a working js/p5 emitter ast from haskell space.
Arathorn well, wow, then :)
autrijus so... if someone want to survey and integrate Emit.JS or Emit.Perl5 or Emit.Python or Emit.DotNet or Emit.JVM 14:57
please feel free to check into pugs.
I'll hook Pugs.Emit.* laters :)
Khisanth pdcawley: getting around the same speed with and without -j between multiple runs
autrijus the -j thing is bogus for all-PIR operations. 14:58
need to unbox constants to have it take any effect.
Khisanth ok
autrijus s/all-PIR/all-PMC/ 15:00
autrijus notes that "retargets" sounds much better than "translates to" 15:02
it implies that you actually have a formal operational semantic that is truly portable without relying on the underlying machine thing.
pdcawley You're just a marketing guy at herat aren't you?
autrijus like, you know, the C language
pdcawley: actually at heart I'm three marketing guys, four actresses, one dentist, nine jugglers, seventeen bouncing balls, 355/113 trees, e*pi time zones, one half jabberwocky 15:04
and then some.
not to mention a fraction of register alligator.
Limbic_Region prefers just to store 30 digits or so of pi in his head then to remember approximations like 22/7 and 355/113 15:05
autrijus but 113355 is so easy to remember :o
Limbic_Region did you get a chance to read my reply? 15:06
perlmonks.org/index.pl?node_id=467294
autrijus yes, it's I think adequate, and if s/he has more followup, I'll field
Limbic_Region thanks
autrijus is still trying to trick out a segfault from the old alligator
Aankhen`` Someone tell nothingmuch that "reschedule to an earlier date" == "prepone". 15:22
Ahh... I think the next time I work on Pugs will be after nearly three weeks. 15:26
Oh well.
I have more than a year to continue with it. =)
Hmm, I want to do something brainless... 15:27
Ah yes.
UT2004. &
svnbot6 r4718, bsmith++ | Added type signatures to Emit.PIR and Pugs.Compile.PIR where they were lacking. 15:31
gaal hi, a class method is defined "method foo(Class $class: .....)", right? 15:39
iblech Yep
gaal thanks! 15:40
and if actually it isn't going to use the $class, is there an elegant way to write that?
i still want it to be callable as MyClass.foo 15:41
iblech Wondered about that, too... But no, I think you have to give a varname, even if you don't use it
gaal hm, on the language level mayve stipulating "(Class undef)" for that could have worked 15:42
useful for letting the compiler emit warnings on unused vars, after all.
iblech Like that :) And the use of "undef" in "(Class undef)" is similar to the use of "undef" in "my ($a, undef, $b) = (...)" 15:43
gaal i'll propose it on p6-l then. 15:44
iblech Good :)
gaal btw, does it make a difference if i say (Class $x : ) or (Class $x) [<-- no colon] ? 16:01
dada wouldn't "sub foo(...)" work the same? 16:02
Arathorn surreal - Sun are including the Rhino javascript engine as part of j2sdk 6 16:03
dada inside "Class", that is
gaal sub foo would have to be invoked as MyClass::foo
dada gaal: right, sure
PerlJam Larry's response to autrijus regarding zip() has crossed my threshhold for english becoming a foreign language. 16:06
gaal also i thought Pipe was reserved for p5ish open| results 16:07
autrijus is having trouble understanding it. 16:08
gaal: looks like Pipe is this generic thing.
not sure how it plays with Iterator/Enumerator
gaal oh, nyeh, my reply was to larry by mistake and not the list.
autrijus decides to punt and go back to assembly
but! tests still welcome
(for zip)
gaal autrijus, i don't see a connection between unix pipes and lists? 16:09
autrijus gaal: lazy lists
gaal: *nix pipes can be thought of a lazy list with the iterate method that returns the next char.
or something like that.
gaal then any filehandle does that.
autrijus right
so it's all Chewbacca to me.
gaal following damian's recent = == iterator revelation
sorry, = == iterate 16:10
autrijus please clarify it with larry some, and write some more test, and kill yet some more existing tests :)
right
rjbs = ==? 16:12
PerlJam rjbs: unary = as iterator
rjbs while (my $item = =@list) ? 16:13
maybe I should go rtfml
Aha, thanks. 16:14
PerlJam that would be the same as while (my $item = @list.next) { ... }
Assuming arrays have a .next method 16:15
rjbs Yup, just read post.
PerlJam unary = still doesn't sit well with me though. I wish I could think of something better. 16:16
(syntactically)
kungfuftr autrijus: lxr.mozilla.org/mozilla/source/extensions/sql/ 16:17
autrijus: the idl files in there might be bloody handy 16:18
autrijus kungfuftr: you mean retargetting sql!? 16:20
compile perl6 to sql?
mm that's something I havn't thought about.
why not?
kungfuftr *blink*
awwaiid uh
rjbs PerlJam: I agree, unary = is a strange choice.
Is === an operator? can you say ($value===$iterator) ? :) 16:21
kungfuftr was thinking more in terms of using the idl's as a way to help bind to mysql, etc.
PerlJam rjbs: the main problem I have is that it's almost always $foo = =$bar; and "= =" is bothersome
no, === is not an op (unless you define one) 16:22
rjbs PerlJam: I just think = as a unary operator is jarring. Maybe I'll get over it.
PerlJam: I was miscounting anyway, as if one could contract "= =" to "===" because I thinkoed it as "== ="
kungfuftr autrijus: compile perl6 to sql!?!? are you crazy!? 16:23
PerlJam kungfuftr: crazy like a fox!
xerox Is SQL turing-complete? 16:24
PerlJam (or just some demented smart person anyway)
;-)
kungfuftr xerox: nope
Aankhen`` autrijus >> Re "I've also started thinking about retargetting the PAST -- that is the "essence" of Perl 6 evaluation -- to Javascript or Perl 5.": you're crazy. In a good way. :-D 16:25
Wouldn't it be quite difficult to target JS, though? 16:26
It doesn't really strike me as being a good match for Perl 6...
acme_ but it's a sign of a good AST ;-) 16:29
Aankhen`` I guess.
I never really understood the whole targeting thing anyway. :-P
Corion pops his head in 16:30
chip takes aim at Aankhen``
Aankhen`` whacks Corion's head.
Corion I'd be interested in having a JS (and Perl5) target for Pugs :-)
QtPlatypus ?eval sub zerorry () {2};zeorry * 2; 16:31
evalbot6 Error: No compatible subroutine found: "&zeorry"
Aankhen`` Sure, it'd be interesting. I'm not against, I'm just idly musing on the difficulty of such a thing... I would be more than happy to use it. :-)
Against it, even.
QtPlatypus ?eval sub zerorry () {2};zerorry * 2;
evalbot6 2
Aankhen`` o_O
?eval sub zerorry () { 2 }; zerorry() * 2; 16:32
evalbot6 4
Aankhen`` ?eval sub zerorry () { 2 }; zerorry * 2;
evalbot6 2
Corion Aankhen``: I've written a really smallish "compiler" for a subset of Perl5 to JavaScript (mostly for client side validation with server side validation)
QtPlatypus ?eval sub zerorry () {2};zerorry
evalbot6 2
Aankhen`` Corion >> Did it, perchance, include C<open>? :-D
QtPlatypus ?eval sub zerorry () {2}; 2 * zerorry
evalbot6 4
Corion Aankhen``: Naah ;) 16:33
Aankhen`` Corion >> Darn.
gaal Corion! long time no moose.
Corion Hi gaal!
Aankhen`` I just want something that gets Time::Local working in Pugs. :-)
Corion It won't get much better - no time this weekend for hacking ...
Aankhen`` (like, say, someone writing it) 16:34
s/writing/porting/
Corion Bike, People and GTA:SA are sucking all my time, and $work as well ...
gaal I am writing an interpreter of my own! (seems to be in vogue :-)
Corion gaal: For what language? And in what language? 16:35
HOP is another fresh timesink too :)
gaal in p6 of course, and let me tell you, it's going to be l33t!
Aankhen`` Corion >> HOP? 16:36
Corion Aankhen``: Higher Order Perl. "Stolen Secrets of the Wizards of the Ivory Towers"
Aankhen`` Ah.
Corion (How to program in Perl5 as if it were Lisp)
Aankhen`` Neat. :-)
Corion Aankhen``: Yeah - I've read most chapters online already :) 16:37
autrijus yay, control structures work.
I have successfully created call-by-need (aka lazy evaluation) in parrot!
Aankhen`` Awesome!
autrijus proceed to compile Grin over and we'll have Haskell running on parrot in no time!
Corion autrijus: Are you porting Haskell to Parrot? :)
Aankhen`` :-o
PerlJam Corion: HOP is already online?
autrijus Corion: thinking about it :)
Corion autrijus: Wacky man!
autrijus Corion: but anyway, the thunk is also needed for
Corion PerlJam: It was at the time I read the drafts
autrijus (f() ?? g() :: h()) //= i();
Aankhen`` Hmm. I know what Grin is... don't I?
autrijus Aankhen``: it's Jhc's internal lang 16:38
Aankhen`` Jhc?
Corion Ah - Jhc - Joes Haskell Compiler or something
Aankhen`` OK.
autrijus Aankhen``: a very slow haskell compiler that generates blazingly fast C code without the need of a runtime.
Aankhen`` Cool.
autrijus quite so
QtPlatypus ?eval sub zerorry () {return @_}; zerorry "foo" 16:41
evalbot6 'foo'
svnbot6 r4719, autrijus++ | * Pugs.Compile.PIR - control structure; thunks; lazy evaluation
autrijus ugh. bug.
gaal hmmm, we have no labelled blocks yet, right? if i have 16:42
Aankhen`` ?eval multi sub prefix:<blub> (Str $foo) { "BLUB$foo" }; blub "blub";
evalbot6 'BLUBblub'
gaal loop { given .. { when .. { last
what does the last break out of?
Aankhen`` ?eval sub foo (Str $bar) { "BAR$bar" }; "f".foo() 16:43
evalbot6 'BARf'
Aankhen`` ?eval sub coolrays (Str $foo) { "$foosome"; }; "awe".coolrays; 16:47
evalbot6 Error: Undeclared variable: "$foosome"
Aankhen`` Dang. 16:48
?eval sub coolrays (Str $foo) { $foo ~ "some"; }; "awe".coolrays;
evalbot6 'awesome'
Aankhen`` ?eval sub coolrays (Str $foo) { "{$foo}some"; }; "awe".coolrays;
evalbot6 'awesome'
gaal ?eval my @res; while "one two three" ~~ rx:P5<g>/(\S+)\s*/ { push @res, $0 }; @res 17:02
evalbot6 (no output)
gaal how do i iterate over words in a string?
i mean before iblech's proposal kicks in. 17:03
dada remembers vaguely something like :w
gaal :w on what? 17:04
dada rules
gaal i want to avoid p6 rules until they're supported everywhere pugs runs.
dada oh yes, I see
Khisanth for <<$foo>> -> $word { }? 17:05
rjbs where aren't they supported?
dada ?eval my @res = split(/\W/, "one two three"); @res
evalbot6 pugs: src/events.c:265: init_events_first: Assertion `rc == 0' failed.
dada ouch :-)
Khisanth hmm
gaal i also want to avoid split :) it's not lazy.
at least i think it isn't? 17:06
eval "words $foo", lang => 'haskell' :)
won't work of course.
broquaint ?eval my @res = split(rx:perl5/\W/, 'one two three'); 17:07
evalbot6 ['one', 'two', 'three']
Aankhen`` ?eval my @res; while ("one two three" ~~ rx:P5/(\S+)/) { push @res, $0; }; @res;
evalbot6 (no output)
Khisanth why does <> and <<>> give an extra undef element?
gaal k, now also make it also span newlines
Aankhen`` ?eval my @res = split(rx:perl5/\W/, "one two\nthree"); 17:08
evalbot6 ['one', 'two', 'three']
gaal cool!
Aankhen`` Khisanth >> How so?
gaal except that it isn't lazy that is.
dada gaal: and it eats any punctuation (don't know if this is what you want)
Khisanth ?eval <1 2 3>
evalbot6 ('1', '2', '3')
Khisanth hmm
Aankhen`` ?eval <<1 2 3 >>
evalbot6 ('1', '2', '3')
Khisanth here it's giving me 1,2,3,undef 17:09
gaal i don't actually care about punctuation right now :)
dada ?eval my @res = split(rx:perl5/\W/, "one! two?\nthree!!!");
evalbot6 ['one', '', 'two', '', 'three', '', '']
Aankhen`` ?eval $?PUGS_VERSION
evalbot6 \'Perl6 User\'s Golfing System, version 6.2.7, June 13, 2005'
Corion Khisanth: It shouldn't :)
Aankhen`` Err?
gaal actually i do care, i want it to be part of the word.
dada ?eval my @res = split(rx:perl5/\W+/, "one! two?\nthree!!!");
Aankhen`` Where's the SVN revision?
evalbot6 ['one', 'two', 'three']
dada better with a +
gaal or stripped, that works too.
Corion Anyway - I'm fading away again - CU soonish, latest in Braga I hope :)
Aankhen`` ?eval my @res = split(rx:perl5/\S+/, "one! two?\nthree!!!");
evalbot6 ['', ' ', ' ']
Aankhen`` ?eval my @res = split(rx:perl5/\s+/, "one! two?\nthree!!!"); 17:10
evalbot6 ['one!', 'two?', 'three!!!']
gaal Braga!? that's a nice place in Tuscany
dada Tuscany?
Khisanth Perl6 User's Golfing System, version 6.2.7, June 13, 2005 (r4711)
dada you sure, gaal?
gaal no, sorry, that's Barga.
dada :-)
gaal vi's ESCxp is seeping into my brain!!
kungfuftr gaal: Braga is north portugal 17:11
gaal And Barga is in Tuscany :)
ok the problem with split /\W+/ is also that it doesn't strip out leading whitespace. 17:14
svnbot6 r4720, autrijus++ | * Compile.PIR - nested thunks:
r4720, autrijus++ | say(1 ?? (2 ?? 3 :: 4) :: undef)
r4720, autrijus++ | now works as advertised.
gaal but i can do that :)
autrijus proceeds to build all control structures out from thunks.
gaal hmmm though - to do that i need to "is copy", which is kind of a waste.
Limbic_Region ?eval (1 ?? (2 ?? 3 :: 4) :: undef) 17:16
evalbot6 3
gaal ?eval my $x = 10; my @a; @a[0..$x] = 0; "done" 17:17
evalbot6 'done'
gaal ?eval my $x = 10000; my @a; @a[0..$x] = 0; "done"
evalbot6 (no output)
gaal slice assignments are VERY slow. 17:18
17:25 Arathorn is now known as Aragone
geoffb *finally* catches up on the last 21 hours of #perl6 17:36
autrijus :) 17:37
Limbic_Region so - summarize it for me so I don't have to ;-)
autrijus is happy that .pir output is finally very debuggable
Limbic_Region so the stuff you generate that is segfaulting is easy to figure out or what?
geoffb I wish I could do that Stranger in a Strange Land thing where he accelerates his local perception of time, so that the can get a pile done while the world ticks by slowly around him 17:38
sri_ is there a simple way to get all classes of a required file?
(porting Module::Pluggable)
geoffb Limbic_Region, my wife would only let me spend time on that if I got paid for it . . . I have enough trouble convincing her it's a good thing that I'm in here as much as I am
autrijus sri_: no... can't think of any. how do you do it in perl5? 17:39
geoffb BTW, autrijus, what do you mean by "thunks" in this case -- I usually think of them as things that convert API mismatches back and forth.
sri_ using the source :/
svnbot6 r4721, autrijus++ | * source column-range and Exp level debugging output
r4721, autrijus++ | as PIR comments!
autrijus geoffb: en.wikipedia.org/wiki/Thunk
geoffb Oh sure, give me something else to read. ;-) 17:40
autrijus is porting loops over... control structures as normal function calls
and "is lazy" traits
is lots of fun
basically all special case goes away
it's all just function calls :) 17:41
(with really fast tailcall and first-class continuation builtin)
geoffb heh
OK, so my conception of thunks were just a subset of the proper CS definition
pdcawley reads back. Wow! Way to go autrijus! 17:43
autrijus pdcawley: so. I'm implemeenting 17:52
&call_with_current_continuation
I think you'll like it.
it's the real one.
pdcawley Yay! 17:53
Don't you mean &?CALLER_CONTUATION? or are we just doing callcc and having done with it?
autrijus pdcawley: it's a parrot internal thing. 17:54
integral do we also get prompts+subcontinuations?
autrijus integral: yes.
integral yay! autrijus++
autrijus integral: and let-hypotheticals in form of nonthreaded STM partial rollbacks.
so feel free to port prolog over.
integral uses upwards only subcontinuations via Coro in perl5+POE
Limbic_Region someone call Ovid 17:55
pdcawley notes that Larry is *so* going to have to finish the design real soon now at the rate you're implementing.
pdcawley wonders what a minimal scheme implementation looks like.
autrijus pdcawley: with my PAST
integral we could threaten to replace him with a perl6 expert system :-P
autrijus I think compiling scheme to it is no problem.
because I'm explicitly modelling it with scheme semantics. 17:56
with auto-taillcalls you don't need to ask for
pdcawley Tee hee.
integral crosses his fingers that svk commit -P doesn't mess up and commit
autrijus praises CPS 17:57
Limbic_Region pdcawley - yeah - that's one of the 4 reasons I didn't list with regards to opening up the design document process to the general public 17:58
the 3 I listed are good enough not to also say - so Pugs doesn't run out of things to do
unfortunately, it looks like the thread has been warnocked
pdcawley notes that, if all else fails you can go look at Damian's Perl 5+i for pointers -- get something implemented so Larry can say "Not like that, like this"... 17:59
Except in the areas where he doesn't.
pdcawley rather liked Perl 5+i as a language. Perl 6 is better mind. 18:00
Limbic_Region I thought the analogy of the house was a convincing argument 18:01
perhaps there is no argument but also no reference material for mere mortals to frame up the house
pdcawley So how much of pugs runs on Parrot now? 18:02
integral
.oO( someone will have to set up smoking for this )
18:03
pdcawley integral: Well volunteered. 18:06
Darren_Duncan hiiiiiii everybody!
Limbic_Region salutations Darren_Duncan
Darren_Duncan back after some sleep, and currently looking to see what changed meanwhile
since 9 hours ago 18:07
pdcawley Oh, everything.
geoffb Didn't you notice the sky is now pink? 18:08
integral is more scared of the perl5 in the build system, than the haskell in the compiler
geoffb heh
Darren_Duncan aside from the regexp support, the Perl 5 is optional as I recall
gaal I am Larry, Lazy of Lazys, heed my emails an despair!
Darren_Duncan as the regexp is provided by PCRE
integral Darren_Duncan: well Makefile.PL is written in perl5, and using it is *much* easier than remembering today's ghc options 8) 18:09
Darren_Duncan sure
seems only 7 Pugs commits since my last one 18:11
superficially none appear to address the bugs I raised, and so I'll be limited in how much more I can do before then 18:12
autrijus yay, lvalue subs. 18:32
svnbot6 r4722, Darren_Duncan++ | updated planned test count of t/builtins/arrays_and_hashes/exists.t , which I forgot to do with r4714
autrijus "my ($x, $y); (1 ?? $x :: $y) = 2"
integral autrijus: are class Compile and Translate both ok to lift out to Pugs.Compile.Types? 18:33
autrijus integral: mmm not sure what you means 18:34
integral just move them to another .hs file so that a different Pugs.Compile.* module can use them
s/lift/move/
Aankhen`` MOVE OUT!!! 18:35
autrijus integral: oh. sure. my idea is that Pugs.Compile will be just compiler 18:36
which handles Exp->PAST
and the so-called retargettable compilers
is actually Translators
integral oh, hang on, yeah, ok :-)
autrijus of Pugs.Trans.PIR and Pugs.Trans.*
integral I was reading PAST as Parrot AST, not Pugs AST
autrijus of the form (PAST a) -> Foo a
no, it's pugs ast :)
the parrot ast thing is nonexistent.
integral is pugs -BPIR examples/mandel.p6 known to not work? 18:37
svnbot6 r4723, autrijus++ | * lvalue subroutines and thunks that Really World (tm)!
autrijus integral: no. I'm fixing it now 18:38
integral :) 18:39
Aankhen`` Really World?
autrijus integral: worksforme now. 18:40
Really Works.
sigh.
integral: as of 4723
Aankhen`` Ahh
.
integral thanks :-) autrijus++ 18:41
autrijus =)
Darren_Duncan yo 18:42
Aankhen`` Yoyo! 18:43
geoffb Please, someone, anyone, get 'make install' to stop rebuilding pugs when you just did a compile using 'make' or 'make unoptimized' immediately before. The reason this matters is that you may have to be root to do the install . . . which means the newly compiled/linked files are now owned by root, so you have to be root even to 'make clean'
Aankhen`` geoffb >> `make install` doesn't rebuild it here...
(Win32, MSVC)
integral it depends on how the version grabber script is getting the revision number
geoffb integral, oh? 18:44
integral if you use svn everything's fine, if you done, poor you
geoffb I use svk
integral geoffb: I assume it's Help.hs forcing the rebuild?
geoffb integral, nodnod 18:45
integral sees about fixing, since he uses svk and is partially responsible
geoffb THANK YOU
integral++
Darren_Duncan I never tried 'make install' but I know that plain make will only redo the files for which the source changed or their dependencies
that said, Help.hs seems to recompile no matter what, even with no changes 18:46
geoffb Darren_Duncan, right.
That's the problem
Darren_Duncan I use svn
geoffb Perhaps the solution is just to fix util/version_h.pl to not rewrite if the version it finds in pugs_version.h matches the one it was about to write 18:47
geoffb guesses that is exactly what integral is doing. ;-)
Darren_Duncan fyi, I'm running a 'make test' on 4722 ... should finish in awhile
I only do that every few days
geoffb ditto 18:48
4 hours is just too long to wait
integral yeah, exactly that =)
Aankhen`` I used to do it daily.
integral does it while he eats breakfast
Darren_Duncan I look forward to the day when Perl 6 compiles and runs as fast as Perl 5
Aankhen`` integral >> So your... system... eats tests for breakfast? 18:49
Aankhen`` ducks.
Darren_Duncan right now is like 20+ times slower
integral heh. /me doesn't test :-P
Darren_Duncan: when running on parrot it's only slightly slower than p5
Darren_Duncan the make test is more of a sanity check really
I've only used pure Pugs for now for simplicity ... may change eventually 18:50
geoffb Darren_Duncan, you're being kind to the pugs interpreter there
Khisanth only 20?
Aankhen`` I wish I could link Perl 5 and Parrot into Pugs on Win32...
Darren_Duncan maybe its 100 times slower
Aankhen`` With MSVC 7...
Darren_Duncan I just know that Perl runs my tests in 1 second, while Pugs I have to at least count to 10 before it starts to run the tests 18:51
I haven't benchmarked them
geoffb :-)
here 'pugs -e 1' takes 6.9s 18:52
'pugs -MTest -e 1' takes 23.7
Aankhen`` Here, about 1.3s.
(pugs -e 1)
About 3 or 4 for -MTest.
About 0.3s for `perl -MTest -e 1`. :-P
Darren_Duncan autrijus or whomever it applies to, any progress on those bugs I reported c10 hours ago, or do you have higher priorities at the moment? 18:53
geoffb Though the two Test.pm's are not equivalent, I get your point. :-)
Aankhen`` Heh. 18:54
Darren_Duncan brb
Aankhen`` eagerly anticipates the return of Darren_Duncan. 18:55
geoffb svk++ # Is there anything it doesn't do well? 18:56
nothingmuch evening
make tea
Aankhen`` geoffb >> Work on Windows?
Darren_Duncan Aankhen, I'm still around, just paying less attention to #perl6
Aankhen`` Yay!
Aankhen`` breathes a sigh of relief. 18:57
Darren_Duncan oh, see exists.t for that test you were going to write but I did instead
Aankhen`` OK.
geoffb Aankhen``, OK, "Is there anything it doesn't do well *on platforms it runs at all on*? :-)
Darren_Duncan, feeling caffeinated today? 18:58
integral hmm, well it no longer rebuilds Help.hs, but it still runs ghc everytime :-/
Darren_Duncan I don't drink coffee at all ... chocolate is another matter though
geoffb integral, does ghc insist on relinking? 18:59
integral I suspect it's a makefile issue.
Aankhen`` geoffb >> Er... emulate its failure on other platforms?
geoffb Darren_Duncan, do you prefer white, milk, dark, bittersweet, . . . ?
Darren_Duncan milk
geoffb Aankhen``, LOL
nothingmuch Aankhen``: you have editing to do
Darren_Duncan with nuts and/or creams inside, non-alcoholic 19:00
Aankhen`` nothingmuch >> Where?
nothingmuch feather.perl6.nl/~nothingmuch/harrorth
primarily doc/08.kwid
Aankhen`` OK, I'll look at it in a few minutes.
Darren_Duncan >> Nice, very thorough test.
s/\.$/s./
geoffb is firmly a 70% extra-dark kinda guy 19:01
Aankhen`` mutters something about not lik...
geoffb Mmmm, maybe I will have to go pull some El Rey out of the cabinet . . .
NO, NO, MUST FIGHT THE CHOCOLATE BEFORE LUNCH URGE
Aankhen`` geoffb >> Give into the Dark Side, young geoffb... you know you want to...
Darren_Duncan Aankhen, the previous one I did was in pairs.t ... that one's even better because it crashes
nothingmuch likes dark ~70%, and milk equally well 19:02
as long as it has no sourness whatsoever
integral why is unoptimized a double colon target?
geoffb Aankhen``, well, yeah, I do, but that would be somewhat dissonant with complaining about fitness
autrijus, how are you liking openfoundry SVN hosting? Any complaints? 19:04
svnbot6 r4724, bsmith++ | Changed version_h.pl to only rewrite version.h when the revision number changes.
geoffb I'm thinking of moving a project there
(and maybe more than one, if that works out, I suppose) 19:05
geoffb goes back to lurk mode while he reads HOP and waits for svk++ to finish mirroring the parrot trunk 19:06
Aankhen`` C:\Development\harrorth>darcs pull 19:08
Invalid repository: feather.perl6.nl/~nothingmuch/harrorth
darcs failed: Failed to download URL feather.perl6.nl/~nothingmuch/harro
rth/_darcs/inventory
libcurl error code: 28
Argh... I REALLY need to nopaste stuff.
Hrm, looks like it was just a DNS error.
nothingmuch bah!
ah
Aankhen`` 08.kwid, you say?
nothingmuch yep 19:09
Aankhen`` OK.
Editing. &
nothingmuch a new evaluator
skip the wtf -> wth translation this time ;-)
also 07.kwid p'raps, i'm not sure you got it
Aankhen`` Should I send the spellchecked version immediately or edit it thoroughly then send? 19:14
geoffb OK, I just gotta say -- while I'm certainly loving the content of HOP, the book itself is just beautifully designed. The layout and typography are masterful, at least to my lay eyes
Limbic_Region geoffb - the errata is quite large and still growing - available online fwiw (assuming you aren't on the HOP-discuss list) 19:15
geoffb I'm not, and thankyou 19:16
there was a note in the preface about MJD running the tests just before going to press and finding out most of them didn't run
Are the errata mostly in the code or the text or both? 19:17
Aankhen`` nothingmuch >> Ping. 19:19
nothingmuch pong 19:20
Aankhen`` PM?
nothingmuch uh, okay 19:21
Limbic_Region geoffb - hop.perl.plover.com/errata/
geoffb Man, nobody lets me get away with laziness around here. :-) 19:23
thanks, Limbic_Region 19:24
nothingmuch Aankhen`` says my english is lousy, and I agree 19:42
so harrorth needs a swarm of volunteer editors
please submit darcs patches for english you don't like
i promise to apply them
Aankhen``: says "That's defamation" 19:47
;-)
Aankhen`` Not to mention "slanderous". :-P
clkao 1/aw 19:48
nothingmuch not only that, Aankhen`` thinks Michael Jackson is innocent
Limbic_Region I thought slander was verbal and something else was written?
nothingmuch and he has only one nose!
Aankhen`` :-o
Limbic_Region >> libel?
Limbic_Region right
Aankhen`` I wasn't aware of the distinction. 19:49
Anyway, on IRC, you pretend everything's verbal. :-P
" A false and malicious statement or report about someone."
(one of the meanings)
But according to Merriam-Webster, it is only oral... 19:50
Limbic_Region dictionary.reference.com/search?q=slander dictionary.reference.com/search?q=libel
Aankhen`` I am checking libel now.
I already checked slander. :-)
OK.
s/slanderous/libel/ 19:51
nothingmuch so, any volunteers?
Aankhen`` points at Limbic_Region.
Limbic_Region Aankhen`` nothingmuch has been prodding me to get involved with harroth for some time 19:52
Aankhen`` Oh, good! You can get started now.
Limbic_Region problem is I have lost my interest *again* in Haskell
Aankhen`` Judging by the "again", I'd say you can regain it. :-D
Limbic_Region isn't as smart as he likes to think he is and needs more time than he has to digest
autrijus geoffb: I run openfoundry 19:58
stevan ah but Limbic_Region you are smart enough to know you are not smart enough, which is very smart :)
svnbot6 r4725, gaal++ | * interpreter for the esoteric language l33t. (TODO: CON opcode)
autrijus geoffb: or, not true (anymore), but I wrote most of its code
and still maintains stuff there
geoffb: so I'm as biased as you can get
Aankhen`` Nite. 20:04
Aankhen`` sleeps. &
Limbic_Region autrijus - how many days (localtime) is left on the current hackathon? 20:05
autrijus 3 20:06
or 4
not sure
probably 3 full days
geoffb is back 20:14
Reading scrollback
autrijus, ah, well then, I'm guessing you like it then. :-) 20:17
autrijus I try, I try :) 20:18
geoffb So, any tips for someone moving a project there?
autrijus not much... if you were using cvs or svn 20:19
you can newproject with a "mirror remote" (r/o) option
so it will transport all your revision history
then you can switch it to r/w
geoffb One project is coming from CVS, the other is coming from a tarball . . . but since the CVS repository is private (not net-accessible), I was expecting to need to use something else to push that codebase in -- 20:20
can svk do this easily? 20:21
autrijus sure! 20:22
you can first mirror cvs locally
sync all its history 20:23
then use "svk sm -BI" to replay it to openfoundry
alternately, if this is oneshot, use cvs2svn first
and then a svnmirror
via svm or replay
see svk.elixus.org for hints
#svk too
clkao one svk to rule them all
geoffb Yeah, the CVS project would be a oneshot conversion . . . I'll look at the above 20:24
clkao, the more servers you make svk understand, the better this world will be. Thanks for all you've done so far. :-) 20:25
clkao GRR!
kungfuftr svk can do bitkeeper too?
clkao don't thank! find bug and complain!
kungfuftr: bk exported cvs.
git is coming.
kungfuftr ah... k
geoffb clkao, I can only do so many things at once. Heck, in the background I've got SVK mirroring parrot's repo so that I can turn my suggestion to chip into a patch as he requested 20:26
And I already reported the "other server" tops on my list . . . darcs. So there. ;-)
clkao darcs won't be very hard. and there's the nice script converting darcs on svk.elixus.org 20:27
geoffb Oh, I don't have any darcs repos to convert; I just want to never have to believe that there is any SCM client other than SVK. And there are more and more darcs repositories I find myself needing to use 20:28
svnbot6 r4726, autrijus++ | * nested thunks now works, thanks to a horrible hack.
r4726, autrijus++ | eventually when leo fixes get_param over calls I'll
r4726, autrijus++ | revisit.
clkao *nod8 20:29
that should be simple, after i finish the git thing. i shall ditch vcp for those foreign system who knows about changeset already
vcp--
geoffb vcp's just there to make CVS interop easier, yes?
clkao yes. or harder. 20:31
geoffb ah, eww
brb, testing xchat startup config
integral anyone know why unoptimized is a double colon target in the makefile? 20:39
21:02 sri___ is now known as sri_
geoffb integral, what's the difference between a single or double-colon target (/me is not a makefile expert) 21:08
integral that's a good question :-) 21:10
dkf geoff: shekel.jct.ac.il/cc-res/online-doc/...html#SEC40 21:18
Aankhen`` Good morning. :-P 21:30
Darren_Duncan when testing, it appears that 't/pugsrun/02-dash-n' has gone into an infinite loop, stalling 'make test' ... will confirm 21:37
that was on r4722 21:38
geoffb Belated good morning, Aankhen`` 21:39
Aankhen`` WHAT'S SO GOOD ABOUT IT, PUNK? 21:40
Darren_Duncan getting all scrooge are you?
Aankhen`` Scrooge?
Darren_Duncan the guy in the story 'Christmas Carol'
I think one of his famous lines is "what's good about it?" 21:41
Aankhen`` Ahh.
Darren_Duncan unless I'm confusing someone else with him
Aankhen`` Didn't know about the line.
Could be that my brain is refusing to work on 2 minutes of sleep, though.
Darren_Duncan I think it was near the beginning of the story ... someone says "good morning" to him
svnbot6 r4727, autrijus++ | * PIR - more work on loop/while/etc statement control and inner blocks.
r4727, autrijus++ | * nested lvalue:
r4727, autrijus++ | my ($x, $y); (0 ?? $x :: (0 ?? $x :: $y)) = 3; say $y;
Aankhen`` Y'know, now that PIR has bool::* in the main namespace, maybe Pugs ought to be modified to be the same too... :-P 21:42
Darren_Duncan any idea how long t/pugsrun/02-dash-n.t is supposed to run? 21:47
I think the version I've got goes infinite-loopy
Aankhen`` I see 3/3 tests run. 21:48
1..3
Darren_Duncan it also seems to catch ctrl-c and keep on going
at least 3 times, then it doesn't 21:49
pasteling "Aankhen``" at 203.101.1.243 pasted "t/pugsrun/02-dash-n.t" (9 lines, 406B) at sial.org/pbot/11158
Darren_Duncan I'm updating a few more revisons and will try again 21:50
now made 4724; waiting while test runs 21:51
it printed out this so far, and then just hangs there ... 21:52
1..3 <break> # Running under darwin <break> # ./pugs -n -e say < temp-ex-input.9874.130 > temp-ext-output.9874.130
Aankhen`` Does redirection work alright on Darwin? 21:53
Darren_Duncan I would expect so, and I think I've used it before 21:54
Aankhen`` OK.
Darren_Duncan the two specified files do get created
now 3 minutes ago by my clock 21:55
Aankhen`` Put in `diag $str` and `diag $got`? 21:56
Darren_Duncan rerunning with change ... 21:59
Aankhen`` BRB. 22:00
Darren_Duncan the hang seems to be in 'system $command' 22:01
mugwump chromatic++ # Parrot SDL 22:02
Darren_Duncan so either the 'system' call is hanging, or what it is calling is hanging, eg: ./pugs -n -e say < temp-ex-input.9904.887 > temp-ext-output.9904.887 22:03
mugwump ffs Darren_Duncan, isolate the exact cause, commit a fix to the test suite that stops it looping, commit a test that demonstrates the bug without looping infinitely, and preferably fix it. but quit whinging and expecting people to look at every little bug you find in the interpreter and think "oh shit, better fix that so that Darren can finish coding LKT!" 22:06
svnbot6 r4728, autrijus++ | * hw2005 - Patrick's review. 22:07
Darren_Duncan sorry mugwump
in this case, it has nothing to do with my module
I just preferred to discuss issues I found before changing code 22:08
mugwump ok that's fine, and I apologise for being rude
Aankhen`` mugwump >> Chill... O_O
[03:17:23] <Darren_Duncan> any idea how long t/pugsrun/02-dash-n.t is supposed to run? 22:09
[03:17:39] <Darren_Duncan> I think the version I've got goes infinite-loopy
He just asked what the normal running time is.
Darren_Duncan fyi, I didn't think I was being annoying, but that people would want to know about bugs
Aankhen`` I was the one who was trying to help him figure out what was up. 22:10
Darren_Duncan and my main involvement is to find bugs, but I am not saavy enough to actually edit the Haskell
autrijus right. and it's appreciated. I don't think darren is whining, and I'm sorry for not having the cycle of looking at them in time.
(as I said so in the journal.)
but they are failing tests, and failing tests are swept during the weekend before release. :) 22:11
Aankhen`` Heh.
autrijus think of the weekdays as the "mark" phase and weekend as the "sweep" phase.
Darren_Duncan I'll also mention that I'm in no great hurry to get LKT etc ported; trying to do so is just the main way I discover bugs that affect people in real life usage scenarios
autrijus Darren_Duncan: right, and it's very very helpful. 22:12
I'm doing the same with parrot right now... and where pugs has bogus output or hangs occasionally... parrot just segfaults ;)
but at least it segfaults in constant time.
Darren_Duncan at the same time, I would appreciate if people told me if I sounded rude or demanding, so I change my ways before it gets worse
Aankhen`` goes to play UT2K4, where he can happily bite off people's heads.
mugwump all I'm saying is that the work towards isolating the fault needs to be performed by someone in any case.
Aankhen`` mugwump >> Right, it's just that DD needed a little guidance. 22:13
Like whether there was a problem in the first place.
autrijus mugwump: darren has a good track record of isolating individual failures and getting them into t/... :)
Aankhen`` And whether it was restricted to his machine.
UT2K4. &
mugwump ok, well I apologise again to you Darren_Duncan. I've been a little cranky recently, interfacing to a Java code base via XML 22:14
autrijus Darren_Duncan: and, fwiw, 02dashn hangs for me too.
Darren_Duncan no prob ... at least we worked it out
autrijus it's likely broken by iblech. 22:15
Darren_Duncan fyi, while it may run counter to the way some people work, I find that sometimes it is more effective to share issues before working too much to isolate them, since its possible someone else already did so
autrijus he made "=$*IN" call $*IN.next; 22:16
Darren_Duncan don't be afraid to ask questions and all that
autrijus which simply hangs.
Darren_Duncan on a different note ...
autrijus I'm adding IO::next now
done 22:17
testing.
Darren_Duncan I will be leaving within an hour to go to town, but should check in about 8 hours from now
autrijus great... I'll sleep now :)
Darren_Duncan: fixed! 22:28
Darren_Duncan great ... will confirm now ...
autrijus r4729. thanks so much
please ping me here if it breaks still 22:29
I'll go ahead and sleep :) 22:30
autrijus waves &
Darren_Duncan autrijus, the fix is confirmed ... t/pugsrun/02-dash-n.t now passes 22:34
svnbot6 r4729, autrijus++ | * Darren_Duncan++ for pointing out that $*IN.next did not
r4729, autrijus++ | actually do a readline -- iblech's fix only went halfway --
r4729, autrijus++ | which caused `pugs -n` to go into infinite loop. Fixed!
Darren_Duncan you give me too much credit ... you figured out the $*IN thing
wolverian what's $*IN? 22:35
mugwump STDIN
wolverian oh. well. could have guessed. but I thought it's still called $*STDIN :) 22:36
someone needs to add a generic iterator class to wrap our coroutines around
er, s,around,in,
Aankhen`` Make it a role. 22:44
:-D
class Foo does Iterator { ... }
Aankhen`` goes smiling all the way to the happy farm. 22:45
wolverian hahaha 22:46
anyway, yes, you're obviously correct, it should be a role.
Aankhen`` Am I? O_O
wolverian yes.
Aankhen`` Oh.
That's nice.
wolverian we're using roles for software reuse, now, remember, not classes. 22:47
Aankhen`` I should try to sleep less more often.
wolverian maybe. :)
Aankhen`` Hmm.
?eval role Happy { method smile () { ":-)" }; method laugh () { ":-D" }; method wink () { ";-)" }; } 22:48
evalbot6 undef
wolverian I don't think we have roles yet.
Aankhen`` ?eval role Happy { method smile () { ":-)" }; method laugh () { ":-D" }; method wink () { ";-)" }; }; my $Aankhen does Happy;
evalbot6 undef
wolverian (the ;s are redundant, by the way.)
mugwump technically, modules are for software re-use and roles are for behavioural units :)
Aankhen`` ?eval role Happy { method smile () { ":-)" }; method laugh () { ":-D" }; method wink () { ";-)" }; }; my $Aankhen does Happy; $Aankhen.smile();
evalbot6 Error: No compatible subroutine found: "&smile"
Aankhen`` Dang.
mugwump even more fine-grained precision! :)
Aankhen`` It was going so well.
wolverian mugwump: right, right. fine-grained. yes. 22:49
I was just saying that myself, too, but you were faster.
Aankhen`` [04:18:43] <wolverian> (the ;s are redundant, by the way.) # yes, I know, I just scatter extra semi-colons around my statements. :-)
wolverian and of course, perl6 very much pushes you towards using them, since all type matching is done with .does
(er, ~~, but anyway...)
maybe someone should write a tutorial on how to use roles, classes and even traits correctly 22:50
Aankhen`` role Sage { has $.intelligence; has $.wisdom; has $:motives; }
Perl 6 poetry? :-D
(yes, yes, $:motives is contrive)
wolverian that's funny :)
Aankhen`` Contrived, even.
Hrm. 22:51
wolverian role Sage { has ( $.intelligence, $.wisdom, $:motives ) } # nicer, maybe.
although, that should probably be @:motives
Aankhen`` role Sage { has ($.intelligence, $.wisdom, $:intelligence, $:wisdom); } # more accurate? ;-)
No, wait!
mugwump how about; role Sage { has $.intelligence; has $.wisdom; }; role Guru does Sage { has $:secrets }
wolverian mugwump: @:secrets! 22:52
Aankhen`` role Sage { has ($.intelligence, $.wisdom); } role Sage::Wannabe { has ($:intelligence, $:wisdom); }
wolverian let's not totally abandon the sigil-based plural/singular distinction perl gives us
Aankhen``: maybe the latter is merely an older sage, who understand that showing off is not a sign of true wisdom.
mugwump Which is actually optional, really. Because $ sigil variables might be hashes
wolverian s,understand,understands, 22:53
mugwump I guess that the % means that the variable .does(Hash)
wolverian mugwump: .isa(Hash), actually, by default
Aankhen`` role Sage { has ($.intelligence, $.wisdom); has @.modules; }; role Sage::Fake does Sage { method modules () { 0 } }
wolverian Aankhen``: why did you use two has-statements? :) 22:54
Aankhen`` wolverian >> I like to group variables according to sigil.
(or purpose)
wolverian oh, okay.
I just use vertical whitespace.
I'm not scared of long expressions.
cough, python, cough
Aankhen`` Heh.
That was some fun stuff. :-
D
mugwump language keywords are like whitespace! :) 22:55
wolverian perl6 has no keywords.
Aankhen`` role MailingList::Flamer { has @:opinions; } 22:56
role MailingList::Flamer { has @:opinions; does Argue; }
(C<does Argue> doesn't make much sense, but it reads well!)
wolverian hey, do class Foo { does Bar } type does-statements work?
I mean, are they specced? 22:57
Aankhen`` Yes.
wolverian ah, good stuff. thanks.
Aankhen`` You can have either: C<class Foo does Bar { ... }>
Or: C<class Foo { does Bar; }>
It applies to C<has> too.
wolverian egh, really?
Aankhen`` I believe so...
mugwump role MailingList::Flamer { has @:opinions; has @.knowledge ::= @:opinions }
Aankhen`` Now you have confused me.
For shame! 22:58
wolverian mugwump: hmm. does 'has @.knowledge ::= has @:opinions' work?
Aankhen`` Probably not.
mugwump heh, I might have the syntax wrong. It implies "presenting personal opinions as knowledge"
wolverian ('does' as in 'should it')
mugwump: yes, the syntax is correct. 22:59
I'm just wondering about my syntax :)
Aankhen`` Hmm, I seem to be wrong. I think maybe you can't use C<class Foo has $.bar>.
wolverian I certainly hope so.
that's putting too much into the signature. 23:00
(if you can call the class declaration that..)
Aankhen`` Yea.
Right. 23:02
Aankhen`` leaves -- going out of town, back on the 3rd.
I will miss hacking Pugs. :-(
Ah well.
Be seein' y'all!
wolverian back to boredom. :( 23:03
geoffb wolverian, if you're just starved for something to do, some debugging of --perl5 module usage would be very nice. I can provide you with a very short example showing the breakage, if you like. ;-) 23:07
(for the "MAKE IT A TEST" crowd -- I'm doing OpenGL stuff; the bug can be seen easily, but good luck writing a test that doesn't just trigger more related bugs) 23:09
wolverian geoffb: if it's haskell I'd be debugging, I'm afraid I'd be totally lost. if it's perl, sure.
geoffb I think it might actually be Perl6, Perl5, and XS between them
wolverian that sounds ugly. 23:10
geoffb Hence the reason I've been avoiding it. :-)
wolverian :) 23:13
I'm trying to fix my perldoc to not show '|' as <E2><94><82> over ssh 23:17
and other such character oddities
well, s,perldoc,nroff, as it doesn't happen with -t
geoffb Any OSSF bigwigs around? 23:21
OK then, that mental thread will have to block . . . 23:23
geoffb does geoffb.brain.schedule() 23:24
23:56 Limbic_Region_ is now known as Limbic_Region