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.
masak is there any way to inspect a junction, to peek inside it without collapsing it? 09:18
is there a way to know if one is handling a junction or a non-junction value? 09:19
Aankhen`` masak: .values? 09:36
(For the first question.)
Or perhaps I didn't understand.
pugs_svnbot r18257 | fglock++ | [kp6] roadmap update 10:07
diff: dev.pugscode.org/changeset/18257
fglock re inspect a junction - I was just wondering about that 10:15
fglock hmm - if NQP supported threads 10:45
avar default sequence: ExtractRuleBlock Token MetaClass Global EmitPerl5 12:49
--lisp only uses EmitLisp, I wonder if it should use any of those too 12:50
pmurias avar: Token for sure 13:04
avar: or do you handle rules specialy
ExtractRuleBlock,Token as ExtractRuleBlock is nessary for code blocks in rules 13:05
MetaClass turnes some things into calls to the metamodel 13:06
and Global turnes undeclared variables into GLOBAL:: vars 13:07
avar No we want rules to perl6 definetely 13:22
most of that stuff depends on things we don't have yet anyway so it doesn't matter much
fglock i'm trying to get threads working on kp6 13:45
compiling to parrot should do it, 13:46
but that's not a generic solution
i was also told several times not to rely on Perl 5 threads 13:47
rewriting to call/cc might work
avar couldn't threads be done abstractly at the kp6 level and then left up to emitters to implement? 13:50
pmurias fglock: what do you plan to use instead of perl5 threads?
fglock pmurias: continuations (implemented with perl 5 closures) 13:51
avar: yes, but you still have to implement
pmurias fglock: it won't give you concurency
fglock pmurias: it's enough for gather/take, and coro 13:52
but not async
avar well, it could emulate async, after all the order isn't guarenteed:)
fglock avar: are Lisp threads good enough (for starting hundreds of threads, for example)? 13:57
avar: thinking of running TimToady's desugared STD 13:59
rather than plain STD, which doesn't require much laziness
avar CL doesn't have threads, but the implementation specific ones are good 14:01
they're OS-threads good, approximately 14:02
(sb-thread:make-thread (lambda () (write-line "hello"))) 14:08
moritz_ re 14:13
lambdabot moritz_: You have 1 new message. '/msg lambdabot @messages' to read it.
fglock I'm trying to figure out pros and cons 14:21
requiring threads in the compiler may be bad for portability
fglock but implementing language-level threads may be good 14:22
PerlJam getting threads right in perl (any perl) must be good. :) 14:23
pmurias fglock: do what's most fun ;) 14:25
PerlJam pmurias++ 14:26
fglock pmurias: working out a plan is fun 14:29
pmurias fglock: i don't think threading concurrency will move us further on the roadmap 14:33
pmurias fglock: is there anything blocking the bootstrap apart from the parser speed? 14:39
fglock only minor things, I think 14:40
pmurias: let's say we had STD parsed and running, 14:41
would we call it Perl 6?
it wouldn't implement most of the interesting parts of the runtime
avar NoReallyIt'sKindaExactlyLikePerl6 14:42
PerlJam fglock: I'd call it fglock-perl-6
fglock :P
avar well it would be "a" Perl 6
PerlJam or perl-6-foo (where foo is something meaningful that I can't think of right now)
pmurias Perl 6 is the language name, i suppose you can have a (partial) implementation of Perl6 14:44
s/can have a/could call it a/
partial untill it passes the test suit 14:45
PerlJam pmurias: I suppose we will only have partial implementations of perl 6 until something profound happens
fglock PerlJam: what would that be like? 14:46
pmurias someone writing a full implementation ;)
PerlJam fglock: wish I knew.
[particle] or someone writing a full specification ;) 14:47
PerlJam pmurias: I think it would take something like blessings from Larry for Perl 6 to be born. (it's still germinating) 14:48
avar Odd this need to attach a definite article to everything:) 14:49
avar fglock: Excellent that the bootstrap is going well! 14:49
moritz_ I've been on vacations for ten days, so excuse my dumb question: what happened here lately? 14:51
fglock moritz_: Aankhen`` and avar have been working hard on kp6-lisp
ruoso and pmurias worked on kp6-kp6 (kp6 bootstrap) 14:52
fglock pmurias worked on a C implementation on Perl 6 tokens 14:53
of
moritz_ fglock: and you?
fglock I've been studying thread models
didn't implement much
I did a bit of work on macros 14:54
moritz_ fglock: thanks for the update! 14:57
pmurias meeting& 14:59
fglock I think it boils down to - when is kp6 Phase 4 finished? (in kp6 roadmap) 15:02
phase 4 was defined too loosely
hmm - lazily
moritz_ is 5.10 out? 15:06
s/out/released/? 15:07
[particle] perl.org reports "Current Release: 5.8.8"
rgs no it's not
rgs but it's close to be. 15:07
PerlJam rgs: What RC is it at? 15:08
moritz_ [particle]: I generally don't trust the up-to-date-ness of perl.org
rgs RC1 maybe this weekend 15:09
avar rgs: yeah right:) 15:30
rgs I plan to have tuits
ferreira Juerd: I incorporated your suggestions into the article on sort comparison operators: here feather.perl6.nl/~ferreira/perl6-op...pare2.html and here www.oreillynet.com/onlamp/blog/2007...art_1.html 15:31
lambdabot Title: compare2.pod6
rindolf Hi rgs 15:55
pugs_svnbot r18258 | avar++ | Fixed indenting 15:57
diff: dev.pugscode.org/changeset/18258
lambdabot Title: Changeset 18258 - Pugs - Trac
avar 37 tests passing now, +4 15:58
pugs_svnbot r18259 | avar++ | Return kp6 values from defined and substr, this makes their respective tests pass
diff: dev.pugscode.org/changeset/18259
lambdabot Title: Changeset 18259 - Pugs - Trac
moritz_ kp6: say "hi" 16:18
exp_evalbot r18259: OUTPUT[hi␤]
avar kp6: my $str = "not ok"; substr($str, 4) 16:20
exp_evalbot r18259: OUTPUT['ok'␤]
spinclad fglock: for a name: FullGrammarPerl6 16:47
MerelyFullGrammarNotToImplyFullyFullPerl6 16:48
avar JesusChristTheJewThisIsALongBloddyPackageNameOhAndByTheyWayItKindaSortaMaybeaAlmostParsesPerl6 16:51
spinclad s:2nd/y// for a shorter name 16:55
oop -- s:3rd
otherthanthat the name might fly 16:56
s:nexttolast/a// for even shorter. now it's unassailable. 16:57
amnesiac avar, pretty self-explanatory package name... 17:05
fglock and we can use a digest to shorten 17:05
Aankhen`` fglock++ # bahaahahahaahaahahaha. 17:09
fglock fnished reading one year's worth of Perl 6 Design Meeting Notes - chromatic++ 17:17
fglock I wonder what's the state of STM and threads in Parrot 17:22
avar dude just hack sbcl:) 17:23
pugs_svnbot r18260 | avar++ | * Indenting of class Call, notabs
diff: dev.pugscode.org/changeset/18260
lambdabot Title: Changeset 18260 - Pugs - Trac
avar svn + vc.el > svk 17:25
fglock it seems that it's possible to construct a kp6 (Perl 6?) AST entirely of Call nodes 17:27
[particle] fglock: threads is a working prototype, but with bitrot on win32 17:28
threads and concurrency pdds should be complete 15 nov and 15 dec 17:29
we're due to have them implemented by march 2008
awwaiid thought you said "implanted" for a second there. 17:31
fglock [particle]: that will be cool 17:32
fglock wish I had it now 17:32
[particle] you're not alone :)
fglock [particle]: I've been thinking more seriously about kp6-parrot 17:35
[particle] fglock: that's good to hear 17:36
you've all been making massive progress on kp6 lately
it's great to see!
fglock [particle]: thanks :) 17:39
[particle] let me know when and where parrot fits in with kp6, and how i can help
pugs_svnbot r18261 | avar++ | (kp6-true) for && and || not (perl->cl, 0 && say 'foo' no longer says foo
diff: dev.pugscode.org/changeset/18261
lambdabot Title: Changeset 18261 - Pugs - Trac
fglock we have a Parrot emitter that needs some work, 17:40
fglock the basic things are simple to implement 17:40
it will need more work to implement closures and user-defined classes 17:41
I think Parrot already has the whole runtime 17:42
i think it's about a week worth of hacking 17:43
avar plays with sbcl threads and notes that they rock 17:43
fglock avar: yay!
avar they're just sugar around the native OS threads 17:44
fglock we could try out an async() implementation
avar www.sbcl.org/manual/Threading.html 17:44
lambdabot Title: Threading - SBCL 1.0.10.14 User Manual
avar it's also easy to make the whole interpreter code threadsafe, most of it is already 17:45
fglock avar: how about implementing it as &code.async()
needs zero grammar and ast modifications 17:46
just for testing
avar lisp doesn't support subs yet through
fglock [particle]: re help, when is the best time for you? 17:52
Aankhen`` avar: We do support anonymous code blocks, however. 17:55
Then again, no objects.
fglock [particle]: I need some snippets to use as examples, such as: define &GLOBAL::say and store it in a file to include as a lib 17:56
[particle] fglock: probably later this week
i'm available this month, but in november i'll be trekking in nepal
fglock [particle]: ok!
avar Aankhen``: IMPLEMENT! 17:57
fglock please let me know if you are nearby Lisbon :)
[particle] fglock: not likely in the near future, but i'll let you know :)
fglock kp6-parrot should reuse the Perl 6-Parrot runtime 18:01
it wouldn't make sense to have a separate runtime
fglock re Lisp, it probably makes sense to write it by hand first 18:03
in order to have a working prototype
avar Aankhen``: Can you tell me about some stuff I could implement? I'm not so familiar with how it's all working atm 18:04
fglock home & 18:13
Aankhen`` avar: I'm not really sure… 18:14
avar: The answer to the second question is "just barely". <G> 18:15
Oh, dang, it wasn't a proper question.
I'm trying to finish up some (unrelated) stuff right now, give me about half an hour and I should be able to hack with you.
avar sweet 18:18
pugs_svnbot r18262 | avar++ | * POD documentation, this is the visitor used by --ast 18:27
diff: dev.pugscode.org/changeset/18262
lambdabot Title: Changeset 18262 - Pugs - Trac
Aankhen`` Actually, forget that, I've done enough intricate, tedious and time-consuming work today. 18:30
Aankhen`` waits for the VM to be restored.
avar: In the mean time, you wanted to know how it all works? 18:31
avar Aankhen``: sure
pugs_svnbot r18263 | avar++ | * Updated POD/DESCIPTION
diff: dev.pugscode.org/changeset/18263
lambdabot Title: Changeset 18263 - Pugs - Trac
Aankhen`` avar: Where would you like to start? Are there any particular areas you find confusing?
avar Aankhen``: Just explain everything and I'll filter out stuff:) 18:32
>:)
Aankhen`` giggles. 18:33
Hmm, let's see. 18:34
pugs_svnbot r18264 | avar++ | * Updated POD/DESCRIPTION
diff: dev.pugscode.org/changeset/18264
lambdabot Title: Changeset 18264 - Pugs - Trac
Aankhen`` Sorry, distress call from my mother and sister to set up a DVD player. 18:38
I'll have to keep popping in and out. 18:39
Anyway.
A ::CompUnit creates a new package for the code (which doesn't make much sense, actually, since we'll have to implement Perl 6 packages ourselves; the CL package system is very different) and pulls in Runtime.lisp, which pulls in the entire Lisp runtime. 18:40
util.lisp contains a few Lisp-side utility functions and macros, nothing complicated.
var.lisp only contains, at this point, KP6-DEFAULT, which takes a sigil and returns the default value for an uninitialized variable which has that sigil. 18:41
pugs_svnbot r18265 | avar++ | * Add POD docs
diff: dev.pugscode.org/changeset/18265
lambdabot Title: Changeset 18265 - Pugs - Trac
Aankhen`` Next, a KP6-INTERPRETER is basically a self-contained P6 world.
Initialization of the interpreter creates the GLOBAL package. It'll probably need to create a few other packages as well later on. 18:42
Aankhen`` Interpreter.lisp also contains the first of the three major macros used in generated code: WITH-KP6-INTERPRETER. All this one does is to wrap the body with a LET that puts a new KP6-INTERPRETER in the given variable. 18:50
After that, it loads error.lisp, which contains derivatives of the CL functions SIGNAL, WARN and ERROR. The derivatives (formed simply by prefixing "KP6-") are mostly intended to add information about the particular interpreter in which the error occurred. 18:51
Aankhen`` pokes avar to check that he's listening.
avar oh I'm always here:0 18:52
Aankhen`` Heh.
error.lisp also contains the KP6-NOT-IMPLEMENTED error class, which we're having a lot of fun with. :-P
avar yeah, I saw that one
Aankhen`` Object.lisp defines the KP6-OBJECT class which all Perl-land objects derive from. It also defines the KP6-TRUE generic function with a base case for the KP6-OBJECT class. 18:53
Cell.lisp defines the simple KP6-CELL class (cells <=> containers) and a wrapper function to create new KP6-CELL instances. 18:54
avar cell instaces?
Aankhen`` Yessir.
Variables are stored in hashes keyed by the name, with the value being a cell. 18:55
avar any reason not to call (make-instance) directly instead of stuff like (defun make-kp6-cell (value) (make-instance 'kp6-cell :value value)) ?:)
Aankhen`` No, it's just a convenience function.
avar ah, this is required for bindings I take it?
Aankhen`` You could substitute (make-instance 'kp6-cell :value value) everywhere you have (make-kp6-cell value). 18:56
Aankhen`` You have the rather uninteresting KP6-VALUE class with a single VALUE slot in Value.lisp… 18:57
Container.lisp has the KP6-CONTAINER class along with a KP6-BAD-INDEX error class and a bunch of generic function definitions. (SETF KP6-LOOKUP) is the only one with a method defined since it's simply a wrapper around KP6-STORE. 18:58
After that you have all the various value types and container types, which I'll pass over to avoid redundancy… 18:59
Ah, now we come to Package.lisp.
Hmm, we should probably swap Package and Pad, since Package builds on Pad. 19:00
I'll talk about Pad first. KP6-PAD derives from KP6-HASH. A pad is simply a hash whose keys are variable names and values are cells.
The WITH-KP6-PAD macro is the major point of interest here. It takes an interpreter, a name for the pad, and an optional parent pad. 19:02
What it does is to create a new pad and wrap the body you provided in a bunch of lexical functions which manipulate that particular pad. 19:03
So you have DEFINE-LEXICAL-VARIABLE, SET-L-V, LOOKUP-L-V and DEFINE-OUR-V, which only operate on that particular pad. This means the generated code need not keep track of anything; it can simply call the functions with the name (and value, as appropriate) and they'll do the right thing. 19:04
S-L-V and L-L-V operate on the value of the variable cell; they also have /C variants that operate on the cell itself. 19:05
So to simply assign a new value to a variable, you'd use SET-LEXICAL-VARIABLE. In order to bind the variable to another value, you'd use SET-LEXICAL-VARIABLE/C and supply a KP6-CELL instance. 19:06
Make sense? 19:07
avar yeah 19:08
Aankhen`` Good, because it didn't to me, for a long time.
I banged my head on the wall a lot over that stuff.
avar I guess I'm just so amazingly awesome 19:09
Aankhen`` Or you're faking it. Either way, might as well continue. :-D
Ah, packages. 19:10
Packages are also pads, funnily enough.
WITH-KP6-PACKAGE follows the same pattern as WITH-KP6-PAD, except that it obviously defines functions for manipulating package variables. 19:11
They're not strictly needed, they just obviate the need for specifying the interpreter everywhere. 19:12
WITH-KP6-PACKAGE additionally wraps its body in a WITH-KP6-PAD.
Aaaand that's it for Package.lisp, I guess. 19:13
I believe you're quite familiar with foreign.lisp and GLOBAL.lisp already.
coerce.lisp is what it says on the tin: a KP6-COERCE function for converting values between types. 19:14
Aankhen`` display.lisp defines PERL->DISPLAY for use in &infix:<~> and &print, mostly. 19:14
That's it for the individual overviews, I think. 19:15
What else would you like to know about?
I think I'm going to be cleaning up a lot of code.
avar now?
Aankhen`` Yup.
I'm checking here as well, though, so shout if you need something. 19:16
avar I've been playing with subs while you were talking
$ echo 'our &VAR = sub { say "WAR" }' | perl kp6-mp6-perl5.pl --lisp| sbcl
*
MAIN
*
#<KP6-CODE {AB68BD9}>
Aankhen`` Great. :-P
Stall me while you get work done. Hmph. 19:17
avar no not at all:)
how do I call functions..
Aankhen`` Do you want KP6-APPLY-FUNCTION?
avar Aankhen``: sial.org/pbot/27847 19:19
lambdabot Title: Paste #27847 from Someone at 208.78.101.240
avar just nuke my changes:)
Aankhen`` Eh? 19:20
Why do you want me to nuke your changes? :-S
avar because they don't work 19:21
Aankhen`` Ah. 19:22
avar w 2 19:23
Aankhen`` Ack. 19:24
80,6952537fatal error encountered in SBCL pid 6452(tid 3085350592):
80,6952537GC invariant lost, file "gencgc.c", line 4601
Hmm, it's a problem with my SBCL. 19:25
Installing a binary didn't help. I wonder if it's because of having the VM suspended for so long. 19:31
pmurias Aankhen``: saving your explanations into a file in docs/ might make sense :) 19:32
or just referencing the log in a README (lazy option) 19:34
Aankhen`` Sure, if it'd be helpful. I didn't much like the explanation though. 19:37
avar or writing out some docs you lazy bum:)
Aankhen`` Gak. 19:38
SBCL still isn't working for me.
avar what code are you trying on it?
Aankhen`` I just say `SBCL` and it gives me the error I showed above as soon as it's done initializing. 19:39
avar then it really does suck 19:40
pugs_svnbot r18266 | Aankhen++ | * [kp6] added docs/kp6-lisp.txt 19:44
diff: dev.pugscode.org/changeset/18266
lambdabot Title: Changeset 18266 - Pugs - Trac
Aankhen`` Hmm. 19:45
The error appears to be caused by LINEDIT.
Yup.
pugs_svnbot r18267 | Aankhen++ | [kp6-lisp] 19:50
r18267 | Aankhen++ | * removed INTERNED-SYMBOL.
r18267 | Aankhen++ | * moved KP6-GENERATE-VARIABLE from Pad.lisp to var.lisp
r18267 | Aankhen++ | * removed CURRENT-PACKAGE slot from KP6-INTERPRETER class.
r18267 | Aankhen++ | * removed PACKAGE argument to KP6-INITIALIZE-INTERPRETER, changed method to accept &key &allow-other-keys.
r18267 | Aankhen++ | * removed BIT slot from KP6-OBJECT.
diff: dev.pugscode.org/changeset/18267
lambdabot Title: Changeset 18267 - Pugs - Trac
pmurias Aankhen``: re explanation: i don't know common lisp, ans so as i'm not the intended audience i can't judge it 19:52
pugs_svnbot r18268 | avar++ | Deleted docs/kindaperl6-ast.pod and moved its contents to KindaPerl6::Ast POD 21:29
diff: dev.pugscode.org/changeset/18268
lambdabot Title: Changeset 18268 - Pugs - Trac
avar 0/w 37 21:31
pugs_svnbot r18269 | avar++ | v6-KindaPerl6-lib5 is a verbatim copy of ../v6-MiniPerl6/lib5. Copied 22:09
r18269 | avar++ | to inc so that KindaPerl6 can be shipped in a self-contained tarball
r18269 | avar++ | outside of the pugs tree.
diff: dev.pugscode.org/changeset/18269
lambdabot Title: Changeset 18269 - Pugs - Trac
avar $ echo 'say "hello"' | perl -Ilib script/kp6 -e 23:35
hello
avar I broke make test in kp6 but I don't see how it could have worked before.. 23:53
it was running kp6_kp6 but that fails,
pugs_svnbot r18270 | avar++ | Uses lib5, obsolete, can be resurrected again via svn magic if needed 23:57
r18271 | avar++ | Removing old kp6 cli interface, new one is in script/kp6
diff: dev.pugscode.org/changeset/18271
lambdabot Title: Changeset 18271 - Pugs - Trac