feb autrijus: you're welcome 13:46
autrijus irclog frontpaged on pugscode.org. 13:48
Steve_p autrijus, < autrijus> nah. I'll just ask steve. ? 13:54
autrijus steve fink
not Steve_p :)
ingy hola
autrijus hihi ingy
ingy hi autrijus 13:55
did the /doc thing work for you?
Steve_p OK :)
Odin- places a sane-o-meter on the channel, wondering if it'll score above zero.
autrijus ingy: uhm no, so I moved it to lib/Perl6/lib
ingy hmmm 13:56
autrijus rationale is that I'd like it installed.
and become part of standard perl6 library.
as such it can't live in doc/. 13:57
(oh and we already have docs/.)
ingy it was supposed to be like the /pod/ dir in the perl dist
autrijus ah. I consider that layout rather broken, honestly
because you need special makefile magic 13:58
hi scw!
ingy and I thought docs was more like project docs
I see
ok by me sir
autrijus ok :) not saying it's the only Right Thing 13:59
but feels workable for now
we'll see how it goes :)
ingy kwid is working out oh so nice
did you try diffing the doc?
autrijus mm? 14:00
I looked at it when I moved it
not diffing
or you mean the kwiki page?
ingy diff -u perlpod.pod perlkwid.kwid
autrijus ohh 14:01
interesting. 14:02
it looks truly nice. 14:03
ingy the translation exercise was very interesting for me
autrijus bootstrapping++
ingy I varied from kwiki in some ways
autrijus torgox++ # worked on perlpod and perlpodspec
ingy and used pod norms where appropriate
autrijus cool.
it's still supportable by a kwiki plugin of course, right?
ingy [...] == L<...> (for the most part) 14:04
of course
my favorite newbie is `...` == C<...>
it cleans things up so much 14:05
autrijus yup
ingy I'll take another pass today
autrijus fwiw I ate [=...].
I mean, I hate.
ingy hate
yes, I hate it too 14:06
it was never a candidate for kwid :)
autrijus good :) 14:07
ingy autrijus: can you make pugs recognize '=kwid'
I tried but failed
autrijus and still ends by =cut?
ingy yes
(it's in the spec)
the spec being perlkid for now
perlkwid 14:08
Steve_p sees more pair goodness to test
ingy actually perl should ignore /^=[a-zA-Z0-9]+/ - =cut 14:09
so =kwid is valid even in perl5 today
btw, does perl6 have __END__ ? 14:10
autrijus no, it's =begin END 14:13
Steve_p heh
pjcj Now that's just copying Windows! 14:14
Steve_p I was thinking Pascal or PL/SQL myself :) 14:16
ingy there is one major podism I need to resolve 14:17
I note it in my checkin 14:18
the whole =over =item =back dance has its merit 14:19
not for the nominal list case
but for the more complicated lists
ingy has to run 14:20
stay tuned...
statico won't touch that dial! 14:22
ingy++ # moving forward with kwid 14:23
Steve_p guesses the preview was discussed on #kwiki last night
integral thinks pod's problem there is not that =over etc dance, but reusing it for numbered and bulleted lists
Steve_p Yes. Hate. 14:24
ingy integral: but what's worse is another kind of list
that is not bulleted or numbered but worded
=item this
blah blah
=item that
more stuff 14:25
integral just separate all the things out, surely?
ingy I need to find a sane roundtrip
btw {{*bold*}} == {*bold*} == *bold* 14:26
{{ leave asis }} == { leave asis } 14:27
`` C<stuff> == `stuff` `` 14:29
I think I can handle the insane edge cases sanely and beautifully
but I really gotta run
shapr I gotta unicycle! w00! 14:32
Steve_p watches shapr's first attempt and hands him an icepack ;) 14:33
shapr www.scannedinavian.com/images/uni-hop.jpg
Steve_p Does Perl 6 have a "defined"
shapr Steve_p: I got my first stitches in 33 years almost a year ago when I was learning :-) 14:34
almost a
huh, weird C-q C-m typo
Steve_p heh
wolverian Steve_p: yes 14:37
(pugs has tests for it) 14:38
Steve_p wolverian, it appears to have some issues
Damn, no nopaste! 14:39
this seems to choke t/op/not.t
ok ! defined $not, "not() returns undef in sclalar context";
Steve_p is being bothered by an attentio-seeking cat 14:40
shapr has five of them :-/ 14:41
autrijus hm 14:49
podBlock parsing harder than I thought.
but then, I'm being diverted by $work
I'll commit what little I have first 14:51
maybe someone who wants to trace parsec can give it a try -- it's r315.
otherwise I'll come back in a bit
rehi 14:54
scw autrijus: Oh! so when I login, it's yourself instead of bot said "autrijus> hi scw!" ! 15:03
autrijus uh.
yes.
I am not a bot.
but then, maybe I am, but I'm not self-aware.
hard to tell :)
Steve_p heh 15:06
autrijus yay. 17:10
finally got $dayJob nailed
ultra complex requirement :-/
however managed to get it done in 2hrs thanks to haskell. 17:11
autrijus wonders if perl6 will make it even easier.
wolverian I'm slightly annoyed that perl6's pattern matching (mmd) isn't syntactically as nice as haskell's 17:13
autrijus wolverian: if you can list specific points, we may be able to propose on p6l. 17:14
I'd like to have full pattern match facility as well.
wolverian I'm not sure how I'd go about fixing it.
I'll think about it tonight, though.
autrijus it applies to := and ::= too
which is the same as letrec
wolverian hmm. do you have any ideas there?
autrijus have you seen array unpacking syntax? 17:15
and hash unpacking
in parameter binding
wolverian pairs to pairs? yes.
autrijus hash unpacking is really like record pattern matching in haskell, and array to list
s/array to list/array unpacking is like list pattern binding as well/ 17:16
I think the magical _ helps.
and the use of constants as part of unpacking
but I think that's minor
the real deal is to use ~~ in binding.
if you can use ~~, you're set.
because ~~ is even more powerful than haskell patterns :) 17:17
wolverian hrm.
autrijus (you can use parsec-like Rules, for example.)
# dev.perl.org/perl6/synopsis/S04.html "Smart matching" 17:18
so yes, I'd like to see 17:19
multi sub foo ($x ~~ foo(), $y ~~ bar()) { ... }
where foo() and bar() may be rules, roles, lists, hashes, etc.
wolverian my (Foo @bar, Baz @quux) <== get_foos_and_bazes(); # if <== worked like this..
integral hmm, maybe some new code layout habits could help 17:20
maybe even being able to put multiple signatures and bodies after a single 'multi sub foo'
autrijus wolverian: that's :=
wolverian autrijus: oh, that works?
autrijus yup.
so it's not that bad :)
wolverian I thought it only distributes pairs
autrijus no, it distributes using the same rule as mmd.
or rather, as parameter binding. 17:21
wolverian oh, that's okay then.
autrijus I still miss pattern guards.
I think allowing ~~ in signature is like pattern guards.
wolverian it would enlargen signatures a lot, I think.
autrijus true.
and there's the nasty side effect thing.
which is why I'd like a functional sublanguage :) 17:22
but I already mentioned it.
wolverian is 'Foo $bar' in the signature a .does() test?
autrijus it is a ~~ test.
multi sub baz (&bar<Code, Int, Int>) 17:23
code unpacking works too.
wolverian and $bar ~~ Foo is a .does() test. okay.
autrijus yup.
so allowing explicit ~~
is merely generalizing things. 17:24
wolverian (I love perl6 already just because it's .does(), not .isa())
autrijus duck typing ++ :)
wolverian yes.
autrijus and .does can be made to do side effects as well
so there's already side effect bug
I think explicit ~~ won't hurt.
wolverian where is &bar<Code, Int, Int> defined?
autrijus S06 17:25
grep for "The closure parameter"
wolverian hadn't noticed that before. thanks!
autrijus np :)
wolverian 6
er, wrong window 17:26
autrijus so yeah, there's this trait ~~
and class/role ~~
wolverian (it takes so time to get used to ratpoison)
autrijus and sigil ~~
but no explicit ~~
multi sub foo ("constant") { ... }
wolverian this is going to be a p6l suggestion, isn't it?
autrijus which is made into --> multi sub foo ($dontCare ~~ "constant") { ... } 17:27
it is if you'd like to write it :)
wolverian I wouldn't probably be coherent enough.
autrijus or ask for another kind soul for summarization
that is fine. p6l is very constructive nowadays.
fancy that.
wolverian horrid.
:)
autrijus :)
the dontCare defaulting is actually pretty strong. 17:29
wolverian what is the haskell term for thsi? 17:30
this, rather.
pattern guards? 17:31
autrijus "Pattern bindings"
that's unpacking
assertion at binding level is called "guards" 17:32
and using binding as assertion is called "pattern guard"
you can refer to www.haskell.org/tutorial/patterns.html
wolverian thanks. so this isn't valid right now? my ($foo ~~ bar(), $baz ~~ quux()) := ...; 17:33
autrijus nope. far from it.
the haskell case expression is like perl's given expression
wolverian yeah.
autrijus so same idea can be used there.
(i.e. haskell can also do guards and bindings inside case conditions) 17:34
wolverian using ~~ like that directly would be special syntax, and I don't think that would fly. it'd be special syntax in signatures as well, but those are already special, so..
autrijus if I have to pick one feature in haskell that really shines, that is it :)
you mean ~~ in LHS being special?
wolverian yes.
autrijus but there is already implicit ~~ all around
so it's just unifying this idea
wolverian hrm. well, yes. 17:35
autrijus (pattern guards isn't in haskell 98 either, it's GHCism.)
I refer you to the excellent paper, " Pattern Guards and Transformational Patterns"
# scholar.google.com/scholar?hl=en&am...l+Patterns 17:36
wolverian thanks :)
autrijus =)
spj++ # full of good ideas 17:37
wolverian how would you state a less than/larger than assertion with ~~? 17:38
(can you do that in haskell? I'm woefully ignorant.)
I guess '$foo ~~ $min..$max' might work :) 17:41
the problem here is that ~~ is ugly when it's extended to do so much. 17:42
autrijus uh 17:44
smart matching is inherent in p6 17:45
wolverian yes, that's not what I meant, obviously
I think, anyway
autrijus $foo ~~ { $_ < 3 }
is how you assert for less than 17:46
wolverian right. that's probably a fair bit more efficient than smart matching against a range :)
autrijus depends on how good the optimizer is :)
journal up. 18:13
obra goes to read 18:22
nnunley does, too. 18:29
autrijus -c support in trunk now. 18:33
nnunley autrijus: So $work allows you to hack in Haskell? Most excellent. 18:34
autrijus :) 18:35
the good thing about owning a small consulting company is that you can usually choose your tools :)
nnunley nods.
True.
So... If we were to use QuickCheck to validate the Haskell side, would you inject it the same way you injected Parsec? 18:39
autrijus uhm, no
I inject parsec because I plan to port it into a state transformer
inside the Eval monad
I think I can use QC as-is. 18:40
nnunley nods. "It does have a side effect of increasing the portablity of the code to other Haskell implementations."
autrijus I did not find a way to StateTify Parsec without modifying the small source.
nnunley nods.
autrijus true, but we already must use binary IO
and lotsa pattern guards
and eventually unboxed types
so we're pretty tied to GHC right now.
nnunley Ok. 18:41
I think I'm going to try to make QuickCheck my vector into learning Haskell.
autrijus that's wonderful.
perlmonks.org/?node_id=434803 # AST
anyone think adopting Text.PrettyPrint in Pretty.hs will help? :) 18:42
that will give us beautiful deparse and AST output.
if someone is looking for a small haskell intro project, that could be it :)
nnunley grins.
autrijus T.PrettiPrint is a joy to use :) 18:43
and Pretty.hs is pretty much self explanatory.
s/PrettiPrint/PrettyPrint/
nnunley I remember basing a pretty printer API in Java on it. 18:44
autrijus :) 18:45
but, sleep. & boarding in 11 hrs
hmm, 10.
nnunley autrijus: Sleep good. 18:46
autrijus :)
autrijus waves &
nnunley Safe journey. 18:49
shapr nnunley: QuickCheck is most nifty, if you need help with it, bug me. I wrote a Test-Driven-Development version of QuickCheck. 18:57
nnunley shapr: Thanks. It feels a little daunting to start out with in Pugs. 18:59
shapr: Given that there's no Arbitrarys for the AST yet. :)
shapr: I guess I'm just trying to figure out a good cut point to start with. 19:02
shapr: Hrm. Do you have a reference to your TDD version that I can look at? 19:13
shapr nnunley: www.scannedinavian.org/~shae/tdd-qc.tar.gz 19:14
nnunley: Check out the README, and be warned that I'm probably the only regular user of that code :-)
If you think of a better way to save failing test cases, or if you find bugs where it no longer does some original QC stuff, please tell me. 19:15
nnunley No problem. As long as I don't start gibbering and chanting 'aie, aie, cthulu, cthulu', I should be fine. 19:16
shapr snickers
Hastur, Hastur, Hast-urk! 19:17
nnunley installs hugs. 19:20
Aie... Aie... 19:47
Back to the YaHT :)
shapr hehe 19:49
Any specific questions?
nnunley Just that I don't have enough Haskell yet. I've read through SOE... But since I never tried to apply it, it's all a little nebulous for me right now. 19:50
shapr: So I stand at the foot of the cliff and wonder, 'How do I start climbing?' 19:53
buu Am I missing something trying to check out pugs?
shapr nnunley: Have you written any Haskell yet?
buu svn checkout svn://svn.openfoundry.org/pugs gives me an error
nnunley shapr: Simple stuff from the first few chapters of SOE.
buu Oh. , not svn:// 19:54
integral buu: http://
buu integral: Oh wow, you can see me.
shapr imho, easiest approach is to learn the pure part first, and tackle monads after.
integral buu: I only /ignored you in #perl 19:55
buu Weird.
shapr nnunley: my first program was a text mandelbrot - www.scannedinavian.org/~shae/src/ha...rot-0.1.hs
nnunley shapr: I think it's just a mental block. I can read that without a problem. 19:57
shapr well, can you write a julia fractal? 19:58
crysflame mm, fractint.
nnunley shapr: Good challenge. I'll see. 19:59
shapr feel free to steal all/any of my code there.
buu Hrm. I wonder how to get haskell in cygwin 20:21
nnunley buu: I'm pretty sure you can just download a copy of ghc -- use.perl.org/comments.pl?sid=25119 20:51
That's a bit relevant to what you're about to experience.
buu Yeah, I got the binary 20:52
shapr another dimension, not only of sight and sound... 20:53
buu Crap. 20:54
"Can't find module 'System.Posix.Unistd' 20:55
Hrm. ghc -v lists stuff like: c:/ghc, which should work 20:57
nnunley buu: Did you run perl Makefile.PL ? 21:00
Apparently, you want to use nmake to build.
buu I ran perl Makefile.PL
But I can't use nmake
So
nnunley According to a message deeper in the thread, Makefile.PL will download nmake for you. 21:01
buu Doesn't seem to.
I just ran it, theres no mention of nmake in the file. 21:02
And if I exit cygwin to run nmake, it can't find my perl =/
iblech Hi, just found a bug in latest Pugs: ./pugs -e 'say say "hi"' outputs "hi\nhi\n1", and not the expected "hi\n1\n1" 21:09
err, the expected output is of course "hi\n1" 21:11
nnunley shapr: Fun... Going to define a julia point as an infinite stream. :)
shapr oooh, neat
iblech You can check that with Perl 5: perl -we 'print print "hi"' outputs the correct "hi1"
crysflame huh 21:13
say returns what it said instead of 1?
that sort of makes sense, if you want to do something with the result of the interpolation done inside what was passed to say after it's said.. but isn't terribly compatible with perl5 behaviour of print returning "true", i guess. 21:14
buu s/true/boolean/
iblech crysflame: Because of a bug, it depends ;) -- ./pugs -e 'my $x = say "hi"; say $x' outputs "hi\n1"
integral write a test :-) 21:15
Juerd Dutch Perl Workshop was fun 23:22
That part of my car exploded was not
luqui your car exploded?
Juerd Part
luqui oh, now I can parse that sentence 23:23
Khisanth missing comma somewhere :)
luqui no, it's fine
it's just hard to parse
some people might prefer "That part of my car exploded, was not"
but both are correct
Juerd I was just starting it and then all of a sudden a loud bang introduced the end of my car's life
Comma to separate the topic is wrong in Dutch 23:24
So I'm not used to using that
obra as a native speaker ""That part of my car exploded, was not"" is funny to me
mdiep the use of the comma seems out of place (wrong)
Juerd Anyway, RIP $car 23:25
mdiep err, s/the use//
Juerd Where P stands for Pieces
Wendy made pictures of the brokenness
When she sends them to me, I'll show them to you 23:26