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.
moritz_ good morning ;) 08:39
pmurias hi 09:18
moritz_ hi pmurias ;) 09:24
pmurias is in a dilemma whether to implement double quotes or try to make 05-code-inside-rule.t work in kp6 09:28
moritz_ well, do both ;) 09:29
#pugs rand()
exp_evalbot OUTPUT[0.7210965431810116␤]
pmurias moritz_: the obvious choice 09:30
:)
masak morning all
moritz_ #pugs if rand() < 0.5 { print "double quoted strings" } print { say "05-code-inside-rule.t" }; say " first";
exp_evalbot OUTPUT[<SubBlock(<anon>)> first␤]
pmurias masak: morning
moritz_ #pugs if rand() < 0.5 { print "double quoted strings" } else { print "05-code-inside-rule.t" }; say " first"; 09:31
exp_evalbot OUTPUT[05-code-inside-rule.t first␤]
masak I'm afraid to admit that the pugs bug I found yesterday kept me up way too long into the night 09:32
that's a first for me: sleeplessness by pugs bug
I didn't solve it, but I gained some further insight into the architecture of pugs 09:33
and I trimmed down the problem itself into as few lines as possible
so I guess it wasn't a total waste
question: when a test failure only manifests through the use of a module, what is the proper placement of that module? should I still put it in ext/? 09:34
pugs_svnbot r17595 | moritz++ | [evalbot] added help message, updated TODO 09:35
diff: dev.pugscode.org/changeset/17595
lambdabot Title: Changeset 17595 - Pugs - Trac
moritz_ masak: yes, but document it ;) 09:38
masak: what was the bug btw? 09:39
nobody really expects ext/ to be BugFree[tm] 09:40
exp_evalbot: help 09:41
exp_evalbot moritz_: Usage: <\#(nqp|pugs|p6|eval|kp6) $perl6_program>
masak moritz_: the bug is disturbing to say the least
I will put together a nopaste for you to demonstrate 09:42
commit coming shortly, too
moritz_ don't hurry for me, I'll be off to breakfast soon ;) 09:43
but I'll backlog
masak sounds good
moritz_ my girlfriend is preparing scones atm ;) 09:44
masak woot
:)
moritz_ normally I do the cooking (like pancakes for breakfast), so it's a nice change ;) 09:45
masak I'd say 09:46
moritz_ btw why is it so hard to write a haskell debugger? is it because the execution modell is quite different from the way the code is written? 09:49
masak it doesn't sound overly hard 09:51
but debugging would probably not be very much like execution, no
you wouldn't want to see all the massive optimizations when debugging
moritz_ I assumed it was hard because the debugger for ghc was implemted rather lated
s/lated/late/ 09:52
masak there's a debugger for ghc? where? where?
masak needs it badly
I think
moritz_ I thought I heard there was an effort to write one
but my haskell knwledge is dangerously incomplete
masak @google ghc debugger 09:53
lambdabot hackage.haskell.org/trac/ghc/ticket/598
Title: #598 (GHC Debugger) - GHC - Trac
masak wow
pmurias #pugs my $a=[1];say $a[0]; 09:59
exp_evalbot OUTPUT[1␤]
pmurias #pugs my $a=[1];say $a[-1];
exp_evalbot OUTPUT[1␤] 09:59
moritz_ it should really be [*-1[, but that is NYI in pugs 10:00
s:2nd/'['/]/
masak hm, maybe I'll know enough soon to be able to implement it 10:01
it doesn't look impossible
pmurias moritz_: there seems to be hat for haskell debuginh 10:04
*debuging
masak hat?
pmurias yes
lumi There's an interactive debugger in ghc 6.7
masak downloads ghc 6.7 10:05
pmurias www.haskell.org/hat/
lambdabot Title: Hat - the Haskell Tracer
masak pmurias: nice
pmurias haven't tried it, but it looks much more usefull then the standart imperative debugger
*standard 10:07
pmurias needs @array[*-1] in mp6 10:08
@array[0-1] works :) 10:10
lambdabot Unknown command, try @list
pugs_svnbot r17596 | masak++ | [t/builtins/arrays/] 10:39
r17596 | masak++ | * here is the new pugs bug, in all its glory:
r17596 | masak++ | ** it seems that arrays initialized with "my" (but not assigned to)
r17596 | masak++ | in subs called from outside the method, are not initialized
r17596 | masak++ | properly and contain vestiges from earlier calls
diff: dev.pugscode.org/changeset/17596
lambdabot Title: Changeset 17596 - Pugs - Trac
pasteling "masak" at 130.238.204.78 pasted "A demonstration of the array init bug" (43 lines, 1K) at sial.org/pbot/27259 10:41
pugs_svnbot r17597 | masak++ | removed outdated comment about being in ext/
diff: dev.pugscode.org/changeset/17597
lambdabot Title: Changeset 17597 - Pugs - Trac
moritz_ scones take up less spaceif aligned to hexagonal lattice ;) 10:47
masak heh.
yes, that should be the most area-efficient arrangement for roughly circular scones 10:48
masak lunch & 11:00
Patterner Learn from Battle For Wesnoth :) 11:01
moritz_ learn from math courses ;) 11:20
pmurias renormalist: hi 11:21
pugs_svnbot r17598 | pmurias++ | [kp6] emitting inner code blocks in rules as seperate methods,unfortunatly self gets scrambled
diff: dev.pugscode.org/changeset/17598
lambdabot Title: Changeset 17598 - Pugs - Trac
renormalist pmurias: hi 11:27
lambdabot renormalist: You have 1 new message. '/msg lambdabot @messages' to read it.
moritz_ compilation of IO.pm is screwed for me (in kp6): COMPILE lib/KindaPerl6/Runtime/Perl6/IO.pm lib5/KindaPerl6/Runtime/Perl6/IO.pm
Can't load ExtractRuleBlock plugin: Can't locate KindaPerl6/Visitor/ExtractRuleBlock.pm in @INC
renormalist moritz_: since when? 11:28
moritz_ I don't know, perhaps a few days, perhaps since yesterday
maybe somebody forgot to svn add ExtractRuleBlock.pm? 11:29
pmurias yes 11:30
sorry
pugs_svnbot r17599 | pmurias++ | [kp6] files i forgot to add
diff: dev.pugscode.org/changeset/17599
lambdabot Title: Changeset 17599 - Pugs - Trac
pmurias it's svk add actualy 11:31
moritz_ ;)
pmurias i found the bug which screws up self, will fix it after lunch& 11:32
moritz_ 01-sanity/07-try.t uses unless {..} else {..} ;)
pmurias or somebody else can make sub receive sigs withought self (Grammar problem) ealier
moritz_: fix it then :)
moritz_ I'm on it ;) 11:33
pmurias *without
moritz_ revision 17600, YaY 11:34
is it legal to use a reference to a sub before declaring it? 11:35
pugs_svnbot r17600 | moritz++ | t/01-sanity/07-try.t: removed obsolete unless...else
diff: dev.pugscode.org/changeset/17600
lambdabot Title: Changeset 17600 - Pugs - Trac
moritz_ that's used in t/blocks/goto.t
pugs_svnbot r17601 | moritz++ | t/builtins/undef.t: removed obsolete unless...else 11:41
r17602 | moritz++ | removed t/oo/from_moose/000_load.t (OO is bulitin ;)
diff: dev.pugscode.org/changeset/17602
lambdabot Title: Changeset 17602 - Pugs - Trac
pugs_svnbot r17603 | moritz++ | t/operators/flip-flop.t: removed obsolete unless..else 11:47
diff: dev.pugscode.org/changeset/17603
lambdabot Title: Changeset 17603 - Pugs - Trac
moritz_ in the test suite I get some errors like that: 11:48
pugs: Internal error: Unknown pseudo-assignment form:Syn "=" [Var "$*_",Val (VInt 0)]
is that new?
for example in statements/given.t
pugs_svnbot r17604 | moritz++ | t/unspecced/sort.t: removed obsolete unless...else 11:50
diff: dev.pugscode.org/changeset/17604
lambdabot Title: Changeset 17604 - Pugs - Trac
rhr gone for 2 weeks & 11:54
moritz_ rhr: have fun ;)
pugs_svnbot r17605 | moritz++ | SLAVES: added myself for exp_evalbot 12:14
diff: dev.pugscode.org/changeset/17605
lambdabot Title: Changeset 17605 - Pugs - Trac
pugs_svnbot r17606 | masak++ | [File::Spec::Win32] 13:06
r17606 | masak++ | * worked around the strange array init bug
r17606 | masak++ | * module tests now pass
diff: dev.pugscode.org/changeset/17606
lambdabot Title: Changeset 17606 - Pugs - Trac
nwc10 does Flavio Glock appear here? 13:44
masak nwc10: yes
avar nwc10: as flgock 13:50
*fglock
masak #pugs use File::Util; my $f = File::Util.new; $f.existent('pugs') 13:52
exp_evalbot OUTPUT[pugs: *** Unsafe function 'use' called under safe mode␤ at /tmp/9v7MZb8zeB line 1, column 1␤]
masak ah, even use is unsafe?
pmurias use is very unsafe 14:09
masak pmurias: in itself?
pmurias i probably overestimated it's unsafnes ;) 14:12
masak pmurias: maybe, maybe not. I just don't see it right now
pmurias you can load code from the disk 14:13
so it's sort of io
masak yes...
but io in itself is ok, right?
I mean, there's a fixed number of modules on the server behind the eval bot 14:14
it's the things that the loaded code might do that are potentially dangerous
pmurias yes
well you might want to keep some code private 14:15
masak please elaborate
still don't see how it merits banning use
pmurias in the case of evalbot it dosn't make sense to ban it 14:16
masak no, not as far as I can see right now
pmurias but allowing banning anything else dosn't make sense as well as the evalbot is probably in a sandbox of some sort 14:17
maybe restricting the @INC to a predefined directory would be enough 14:18
and no forgein modules
like use DBI:from<perl5>
masak yeah, good point 14:20
pmurias it's no use to have partial unsafeness checking 14:31
masak true -- and there is probably undecidability creeping in there somewhere, so better to prohibit defensively 14:32
pmurias having the evalbot runing in unsafe mode in a good enough sandbox might be a better option 14:39
masak hm, yes 14:40
I'd still be a bit careful with arbritary system calls and the like
Tene Perhaps running on a read-only fs with no network access and proper ulimits and such. 14:42
masak yes 14:42
moritz_ I don't really care about anything but DOS attacks 14:44
fork bombs and the like are the most dangerous thing for the evalbot
or something that fills up the disc space
otherwise evalbot runs with low permissions in a chroot that is used for nothing else 14:45
still I'd like to see safe/unsafe flags per namespace/module/whatever
for example I'd consider Date::Calc to be "safe" and POSIX to be "unsafe"
masak moritz_: did you take a look at the array init bug in pugs? what do you think about it? 14:46
moritz_: maybe that would be a good enough idea, whitelisting modules
moritz_ masak: re array bug: weird indeed 14:48
masak moritz_: I wouldn't have excpected such a bug to still remain in pugs, shaky as it sometimes is 14:49
unfortunately, I don't have the required Haskell-fu to fix it yet
in pugs source, I repeatedly ran into something called pads, which seems a scary context somehow related to monads 14:50
pmurias lexical pads?
masak yes
moritz_ has heard that as well ;)
masak they're called Pad in pugs source
I know what they are
moritz_ explain! ;)
masak ok :)
they are environments tied to blocks of code containing variables bound to values 14:51
moritz_ re whitelisting... that's ugly, but workable ;)
masak you need many pads because the same name might connote different values in different parts of a p6 file
basically, ever subrouting has a pad 14:52
moritz_ and an assignment basically changes a pad entry?
masak dunno
conceivably
moritz_ and a declaration adds a slot, presumably
masak anyway, this all makes sense re the current bug, since something apparently is carried over from one call to the next
or rather (as I've seen by playing around with it) from the first call to all subsequent ones 14:53
we're basically seeing some unintended pad contamination
which only occurs in exported subs 14:54
I'm stuck with solving it because I cannot find the place in Eval.hs where "my" declarations are evaluated 14:55
if anyone from the future is reading this, please send a patch back to me somehow. kthxbai
pugs_svnbot r17607 | pmurias++ | [kp6] sub {} no longer gets $self as the invocant
diff: dev.pugscode.org/changeset/17607
lambdabot Title: Changeset 17607 - Pugs - Trac
moritz_ masak: did you see src/Pugs/Eval/Var.hs? that contains a rather verbose explanation of findSub etc. 14:58
masak moritz_: I found it and read it, yes 15:00
didn't find anything about declarations, though 15:01
pugs_svnbot r17608 | pmurias++ | [kp6] code inside rules works at last 15:44
r17608 | pmurias++ | fixed GLOBAL::print
diff: dev.pugscode.org/changeset/17608
lambdabot Title: Changeset 17608 - Pugs - Trac
pmurias that proved a difficult test to fix 15:50
mncharity pmurias++ 15:54
pmurias kp6 compiles Grammar.pm 18:40
:)
Tene Next step: STD.pm? ;)
pmurias :) 18:41
moritz_ wow, I'm impressed
pmurias well the next step is to check if it does it correctly
shower& 18:42
b_jonas lol 18:43
DarkWolf84 great
:)
pmurias b 18:56
moritz_ when I try to run the test suite with Grammar.pm compiled by kp6 I get a message 'Can't locate object method "comp_unit" via package "KindaPerl6::Grammar" at kp6-perl5.pl line 99' 19:10
all the Grammar/*.pm compile at least 19:12
pmurias moritz_: code compiled by kp6 and mp6 isn't compatible 19:15
moritz_ seems like, yes 19:17
pmurias you would need the whole compiler compiled by kp6, and a new kp6-perl5.pl
what i think is needed right now is a make target which compiles lib with kp6 to a diffrent dir 19:18
moritz_ I'm trying to recompile all of kp6 now to tmp/ 19:22
moritz_ no syntax errors so far 19:24
pmurias what i'm worried about is that grammars compiled with kp6 will be too slow 19:29
moritz_ Grammar.__rule_block1 seems to get defined/emitted twice
perhaps a problem with MOP.pm 19:30
pmurias nay
i know what causes that
did all files compile? 19:31
moritz_ yes
pmurias could you check them in?
moritz_ 'course 19:32
pugs_svnbot r17609 | moritz++ | [kp6] added bootstrap/ which contains a kp6 image compiled with kp6 19:33
diff: dev.pugscode.org/changeset/17609
lambdabot Title: Changeset 17609 - Pugs - Trac
moritz_ I can write a little bootstrap.pl script as well 19:34
avar moritz_: does bootstrap/ work without mp6 on your system? 19:35
moritz_ avar: it doesn't work at all ;)
pmurias moritz_: a make target would be better than a script
moritz_ pmurias: I'm not that confident with Makefiles... 19:37
pmurias: and usually if you change kp6 you want to recompile all of, don't you? 19:38
pmurias not always 19:39
you might want to use a stable version of kp6 and recompile only the changed part 19:40
DarkWolf84 cool kp6 is now bootstraped
:)
moritz_ DarkWolf84: now, not quite 19:40
DarkWolf84 why?
moritz_ DarkWolf84: it doesn't throw any syntax errors on itself, but it doesn't run yet 19:41
DarkWolf84 I had a problem making 'make clean && make'
that for kp6 19:42
pmurias make clean screws up kp6 19:45
moritz_ make forcerecompile; make is the way to go
pmurias make forcerecompile is redundant 19:47
just use make -B
b_jonas or make clean compile 19:50
pmurias NO! do not use make clean 19:52
DarkWolf84 I know that allready
:)
pugs_svnbot r17610 | pmurias++ | [kp6] Makefile complains if not used properly 19:54
diff: dev.pugscode.org/changeset/17610
lambdabot Title: Changeset 17610 - Pugs - Trac
avar moritz_++ # working on bootstrap 19:55
pugs_svnbot r17611 | pmurias++ | [kp6] fixed typo 19:57
diff: dev.pugscode.org/changeset/17611
lambdabot Title: Changeset 17611 - Pugs - Trac
pugs_svnbot r17612 | pmurias++ | [kp6] failing test for 'for' 20:00
r17612 | pmurias++ | s/prim/prime/
diff: dev.pugscode.org/changeset/17612
lambdabot Title: Changeset 17612 - Pugs - Trac
moritz_ more bootstrapping tomorrow, bed & 20:04
pmurias sleep& 20:06
pmurias and a bit of Compiling with Continuations, Continued 20:07
meppl good night 23:17
DarkWolf84 night 23:22