pugscode.org/ | nopaste: sial.org/pbot/perl6 | ?eval [~] <m oo se> | We do Haskell, too | > reverse . show $ foldl1 (*) [1..4] | irclog: irc.pugscode.org/
Set by diakopter on 11 July 2007.
pmurias hi 10:33
moritz_ hi
DarkWolf84 hi 10:42
IO.getpeername don't work 10:43
:(
moritz_ patch it ;)
DarkWolf84 It wil be dificult to write network test 10:44
It will* 10:45
I don't know wheter fork will work 10:51
I didn't tried it yet 10:52
moritz_ $ pugs -e 'if fork() { say "foo" } else { say "bar" }' 10:53
bar
foo
looks good ;)
DarkWolf84 ok 10:54
maybe I have to try
moritz_ woo, but if you leave stray forked processes, you have to kill them manually ;) 10:57
pmurias you plan to fork the test so as to have a server and a client?
DarkWolf84 I know 10:59
that is writen allready in perldoc
:)
yes
there is no other way 11:00
the only problem with fork will be windows 11:01
if fork emulation is not implemented
pmurias having the test server run on for example feather might be an option 11:06
DarkWolf84 I think fork don't works too 11:16
DarkWolf84 Is the syntax different form perl5 for kill() 11:20
the mistake for fork is mine 11:32
:) 11:33
pid is 0 in the child process
not undef
DarkWolf84 maybe it's more safe to test with real server 11:58
DarkWolf84 ?eval my $sock = connect('feather.perl6.nl', 80) // die "Can't connect feather.perl6.nl: $!"; say $sock.getpeername; 12:16
pugsbot_r17185 Error: Unsafe function 'connect' called under safe mode
DarkWolf84 ok
pmurias, thanks for the advice :) 12:17
that makes things simple 12:18
no test for IO at all? 12:22
found it 12:23
in builtins
?eval $?OS 12:27
pugsbot_r17185 \"linux"
DarkWolf84 I think my test is near ready 12:56
DarkWolf84 I have one question 13:22
Is it ok to write one test in a separate file? 13:24
I finished IO.getpeername test 13:32
pmurias IMHO it's better to write a file for a one test then to put it in a wrong file 13:38
if it makes sense to put other tests in that file later on i think it's ok
pugs_svnbot r17243 | darkwolf++ | Add test for IO.getpeername, need checking 13:51
diff: dev.pugscode.org/changeset/17243
lambdabot Title: Changeset 17243 - Pugs - Trac
DarkWolf84 small lag
:)
daxim_ I want to have an svk cheat sheet, if you could translate these handful of svn commands into svk, that would be cool www.perlfoundation.org/perl5/index....heat_sheet 15:24
lambdabot Title: SVN cheat sheet / Perl 5 Wiki
PerlJam daxim_: most of those are exactly the same but you type "svk" instead of "svn" 15:27
daxim_: I don't think that svk does $keyword$ expansion though. 15:28
daxim_ that doesn't give me offline working
pmurias you use *additional* commands for offline working 15:29
PerlJam "svk push" and "svk pull" are your friends :)
thoughtpolice wee. i'm quite happy with the results of my irc bot. :) 15:43
pmurias what does it do? 15:50
thoughtpolice pmurias: right now it's kind of limited... i'm working on the 0.2 release, but the general idea is it's a tiny but extendable irc bot in haskell. 15:52
then again, I haven't exactly gone through any *huge* efforts to write plugins for it as of current, although I assume some lambdabot commands could be ported over without too much hassle. 15:53
plugins are compiled and loaded on startup rather than being statically built in (hs-plugins,) so you can make changes and just restart to see the effect. for the 0.2 release I'm going to work on having the ability to have the bot update plugins 'in-situ,' i.e. you can reload it as it's online. 15:55
i posted it to haskell-cafe but apparently it's of no interest or something. :(
pugs_svnbot r17244 | pmurias++ | kp6: converted ->{_dispatch}() to dispatch() in emitted code 19:31
diff: dev.pugscode.org/changeset/17244
lambdabot Title: Changeset 17244 - Pugs - Trac
pmurias fglock_: hi 20:40
fglock_ hi pmurias 20:40
pmurias thought a bit about Captures & Signatures 20:42
i think signatures will need to get a reference to the variables the need to bind 20:44
pmurias shouldn't iS 20:46
s/.*//
fglock_ I see signatures as data, which will be used by the CALL and APPLY methods
pmurias methods of?
fglock_ Code.APPLY() uses Code.signature 20:47
fglock_ Code.APPLY( $capture ) 20:48
fglock_ I think that, when we get the compile-time and runtime storage of multis set up, we'll have a better view of how the multi dispatcher should work 20:52
pmurias i thought of it more like sub($a,$b,$c) {} being tranformed into sub($capture) {:($a,$b,$c).BIND($capture)}
fglock_ that's right - and at a lower level, this is $sub.APPLY( $capture ) { ... } 20:55
and then - dispatch( $sub 'APPLY', $capture ) 20:56
pmurias i grok that part 20:57
pmurias what intrests me more is will the binding of arguments be done by the signature object or will code be emitted based on it 20:59
e.g will sub ($a,$b) {} be emitted as sub($capture) {$a := $capture.positional[0];$b := $capture.positional[1]}? 21:00
moritz.faui2k3.org/irclog/out.pl?ch...20#i_67188 might be of some interest to you 21:02
lambdabot Title: IRC log for #perl6, 2007-07-20, tinyurl.com/27rhrm
fglock_ this is up to the optimizer and emitter; for example, v6.pm uses sub( $invocant, $arrayref, $hashref ) 21:03
looking 21:04
pmurias i know how to implement the dynamic way, but i think now that emitting code which does it is more better (faster and more portable) 21:06
and avoid bootstrap problems 21:07
fglock_ I think :($a,$b,$c).BIND($capture) is the no-premature-optimizations way to do it 21:09
we can optimize the easy cases
pmurias doing it dynamicly is not required by the spec (asked TimToady) 21:10
.BIND is not required 21:11
and defining .BIND without signatures would be hard 21:12
got to sleep now as i go on a bicycle trip tommorow morning (back in a ~week) 21:14
g'night 21:15