svn switch --relocate svn.openfoundry.org/pugs svn.pugscode.org/pugs/ | run.pugscode.org | spec.pugscode.org | paste: sial.org/pbot/perl6 | pugs.blogs.com Set by avar on 16 November 2006. |
|||
00:02
dvorak joined
00:08
justatheory joined
00:21
DebolazY joined
00:25
DebolazZ joined
00:41
ofer0 joined
01:16
nipra joined
01:17
weinig|away is now known as weinig
01:38
b00t joined
01:56
nipra joined
01:59
neonse left
02:00
justatheory joined
02:02
rashakil joined
02:12
Khisanth joined
|
|||
svnbot6 | r15143 | putter++ | redsix now smokable, but with unexamined regressions. | 02:17 | |
02:29
weinig is now known as weinig|zZz
02:37
araujo joined
02:43
Aankh|Clone joined,
dmq joined
02:49
mbradley joined,
mbradley is now known as mbradley|afk
02:53
Aankh|Clone is now known as Aankhen``
03:18
REPLeffect joined
03:27
buetow joined
03:52
justatheory joined
04:18
perlbot joined
05:18
avarab joined
05:24
wamiks joined
05:28
leed joined
05:29
avarab_ joined
05:33
zev joined
|
|||
zev | I'm not sure who to report this to, but www.nntp.perl.org seems to be down | 05:35 | |
dduncan | hey, you're right! | 05:38 | |
lambdabot | dduncan: You have 1 new message. '/msg lambdabot @messages' to read it. | ||
dduncan | is that so? | ||
05:39
dduncan left,
avar joined
05:49
avarab joined
05:52
ofer0 joined
05:59
avar joined
06:00
rashakil joined
06:09
avarab_ joined
06:12
wamiks left
06:14
BooK joined
06:15
dduncan joined
06:19
avarab joined
06:34
dc3aes joined
06:36
mdiep_ joined
06:41
wamikss joined
06:47
rashakil joined
07:13
szabgab joined
07:45
rfordinal joined
07:46
REPLeffect joined
08:54
elmex joined
08:57
wilx left
09:09
dduncan left
09:14
iblechbot joined
09:21
devogon joined
10:03
VanilleBert joined
10:07
nipra joined
|
|||
masak | what is the return value of &take? | 10:16 | |
10:31
pdcawley joined
|
|||
VanilleBert | ?eval &take | 10:31 | |
10:31
evalbot_r15142 is now known as evalbot_r15143
|
|||
evalbot_r15143 | \{Prim ([Pugs.AST.Internals.Val] -> () Pugs.AST.Internals.Val)} | 10:31 | |
10:45
Yappo joined
10:46
Yappo joined
10:50
Yappo joined
10:55
Yappo joined
|
|||
masak | is this expected behaviour? | 11:00 | |
?eval sub next($a) { return $a + 1 }; my $i = 0; gather { take $i = next($i) while $i < 10 } | |||
evalbot_r15143 | (\10, \10, \10, \10, \10, \10, \10, \10, \10, \10) | ||
masak | O_O | ||
11:00
REPLeffect left
11:01
chris2 joined
11:28
Psyche^ joined
11:33
jferrero joined,
iblechbot joined
11:38
VanilleBert left
11:43
Psyche^ is now known as Patterner
11:44
nipra joined
11:59
bernhard joined
12:06
polettix joined
12:12
nipra_ joined,
nipra_ is now known as nipra
12:18
elmex joined
12:20
rfordinal joined
12:29
reZo_ joined
12:51
SamB joined
13:19
xpika2 joined
|
|||
masak | do recursive coroutines make any sense? | 13:39 | |
13:41
Limbic_Region joined
13:46
avar joined
13:47
rashakil joined
|
|||
allbery_b recalls a contrived example of them in the icon book, so they apparently make some sense | 13:53 | ||
masak | allbery_b: because I found myself writing one in pugs-perl6 today, but I didn't get it to work properly | 13:58 | |
in the end I rewrote it in an iterative version, which did work | |||
but what I failed to find out was whether the recursive version did not work out due to a bug in pugs or a but in me | 13:59 | ||
s/but/bug/ | |||
eh, I mean s:2nd/but/bug/ | |||
xpika2 | there sounds nothing wrong with recursive coroutines. | 14:05 | |
14:11
larsen_ joined
14:20
nipra joined
|
|||
masak | xpika2: what I was thinking, more exactly, was: what are the semantics of &yield when the coroutine has called itself a few times? | 14:27 | |
does the yielded value end up in the next higher instance of the coroutine itself, or does it percolate all the way up to the last instance of non-co-routine in the callchain? | 14:29 | ||
I guess one could argue both ways | |||
the former seems saner and less complicated, but the latter might also be useful (and would have been in my case) | |||
14:34
xpika2 left
|
|||
masak | another way of putting it is: does &yield treat recursively called instances of the same function as individual instances, or does it lump them together? | 14:48 | |
as of now, there seems to me to be no reason that the latter is the case, unless the former is somehow impossible, which I don't think it is | 14:50 | ||
14:56
Schwern joined
14:59
mr_ank joined
15:01
wilx joined
15:02
wilx left
15:17
buetow joined
15:32
reZo joined
15:37
wilx joined
15:44
jferrero joined
15:54
neonse joined
15:56
nipra joined
16:01
szabgab joined
|
|||
szabgab | I cannot build Pugs again, the error line I get is: | 16:07 | |
Couldn't open "blib/lib/Prelude.js" for writing: No such file or directory | |||
16:09
wilx joined
|
|||
svnbot6 | r15144 | audreyt++ | * PIL2JS runjs.pl: Create dirname before outputting it. | 16:13 | |
r15144 | audreyt++ | Reported by: szabgab++ | |||
TimToady | masak: take $i = ... is returning an lvalue because = returns an lvalue | 16:14 | |
szabgab | audreyt++ thanks, now it compiles well | 16:18 | |
btw I keep forgetting where is the pastebot? | |||
allbery_b | lisppaste3: url | 16:19 | |
lisppaste3 | To use the lisppaste bot, visit paste.lisp.org/new/perl6 and enter your paste. | ||
allbery_b | there's also | ||
@paste | |||
lambdabot | Haskell pastebin: hpaste.org/new | ||
allbery_b | but it's not so perl6-friendly | 16:20 | |
there may be others hanging out here too :) | |||
szabgab | thanks but there was a much shorter link url somewhere | 16:21 | |
TimToady | I generally use sial.org/pbot/perl6 | 16:22 | |
lambdabot | Title: sial.org Pastebot - pasteling | ||
TimToady | have it as a button in my bookmark bar, in fact... | ||
allbery_b actually has a pastes menu in his bookmarks bar, because different channels have different preferred pastebots | 16:23 | ||
16:25
turrepurre joined
|
|||
masak | TimToady: why does = return an lvalue? in case I need to assign to the variable again? | 16:31 | |
how I do de-lvalueify it? | |||
s/I do/do I/ # sigh... | 16:32 | ||
TimToady | I think "take item" works, probably | ||
that's straight from P5, actually ($x = $y) =~ s/// wouldn't work otherwise | |||
masak | ah | ||
?eval sub next($a) { return $a + 1 }; my $i = 0; gather { take item ($i = next($i)) while $i < 10 } | 16:33 | ||
16:33
evalbot_r15143 is now known as evalbot_r15144
|
|||
evalbot_r15144 | (1, 2, 3, 4, 5, 6, 7, 8, 9, 10) | 16:33 | |
masak | ok. I have no complaints | ||
TimToady | item is $() really, and list is @(). | 16:34 | |
masak | that's nice | ||
TimToady | I just added : forms to go with the () forms | ||
they have list infix precedence on the right | |||
so you can instruct a zip how you want it contextualized | |||
for instance, @@: 1,2 Ā„ 3 4 | 16:35 | ||
equivalent to the "chunky" we've been discussing in p6l | |||
and @@:split gets you a chunky split, instead of the default flat one. | 16:36 | ||
wolverian | what does a chunky split return? | 16:37 | |
wolverian is being sow | |||
...er, slow :) | |||
TimToady | "source of wisdom" I was taking it. :) | 16:38 | |
masak also only almost follows | |||
TimToady | in p5, split just adds extra fields | ||
wolverian | source lacking of wisdom :) | ||
masak | wolverian: :) | ||
TimToady | split(/(delim)/) gets you field,delim,field,delim,field,delim | 16:39 | |
chunky would get you [field,delim],[field,delim], etc | |||
16:39
Limbic_Region joined
|
|||
masak | ah | 16:39 | |
wolverian | people capture the delim? the heresy.. | ||
TimToady | @@: 1,2 XX 3,4 gets [1,3],[1,4],[2,3],[2,4] | 16:40 | |
by defaults it's just 1,3,1,4,2,3,2,4 | |||
s/s// | |||
so you either write | 16:41 | ||
for 1,2 XX 3,4 -> $a, $b {...} | |||
or | |||
for @@: 1,2 XX 3,4 -> [$a, $b] {...} | |||
so the default @: works well with the default signature | |||
and zip defaults to not needing [...] in the sig to unpack | 16:42 | ||
but you can get a list of array if you want via @@: | |||
and we can unify zip and each into just zip | |||
and don't have to have two versions of split, map, take, etc | 16:43 | ||
@@: automatically takes a list of | |||
list of Capture and turns it into list of Array | |||
also applies to m:g results | 16:44 | ||
16:44
reZo joined
16:47
rindolf joined
|
|||
wolverian | I kind of thought of captures as tuples, so you wouldn't need to turn them into arrays, but that's sort of different, I suppose | 16:47 | |
TimToady | when you say "return 1,2,3" you have no idea what the caller wants to do with the listiness of it. | 16:48 | |
so we do it lazily | |||
just like when you call "mumble 1,2,3" | |||
it waits till it knows what it's binding to | |||
1 might be in scalar context | |||
2,3 might be list context | |||
wolverian | and it goes through captures? | 16:49 | |
TimToady | Captures and Match objects are very similar | ||
they try to capture the original "syntax" of ordered and unordered things | 16:50 | ||
16:54
VanilleBert joined
16:55
VanilleBert left
|
|||
rindolf | Hi all. | 16:55 | |
Hi wolverian, TimToady | |||
TimToady | morning | evening | 16:56 | |
wolverian | hello rindolf | ||
rindolf | TimToady: evening. | 16:58 | |
I mean it's evening here. | |||
TimToady | np, I used an inclusive or | ||
17:01
reZo joined
|
|||
rindolf | TimToady: what's up? | 17:01 | |
TimToady: have you seen the Pachelbel's Rant yet? | 17:02 | ||
TimToady | er, which rant is that? | 17:03 | |
rindolf | TimToady: shlomif.livejournal.com/32301.html?mode=reply | ||
lambdabot | Title: Post Comment | ||
pasteling | "szabgab" at 192.117.127.193 pasted "testing pastebot" (75 lines, 1.4K) at sial.org/pbot/22664 | 17:07 | |
rindolf | TimToady: I've been having some fun with XML::RSS recently, which is based on XML::Parser. | 17:08 | |
svnbot6 | r15145 | szabgab++ | pastebot client for those who keep forgetting the url | ||
rindolf | TimToady: one thing I don't understand is why the object given as callback to the handlers is different than the XML::Parser one. | 17:09 | |
Hi szabgab | |||
wolverian | rindolf, heh, that video is awesome. thanks. :) never knew about the canon. | 17:10 | |
rindolf | wolverian: knew what about the Canon? | 17:11 | |
wolverian: and you're welcome. | |||
TimToady | yes, I've noticed that chord pattern is rather common :) | ||
rindolf | Of course, "Let it be" doesn't sound anything like Pachelbel's Canon. | 17:12 | |
wolverian | rindolf, how common the chord progression is nowadays. | ||
rindolf | wolverian: I see. | ||
17:15
penk joined
17:21
reZo joined
|
|||
szabgab | rindolf: rehi | 17:24 | |
rindolf | szabgab: what's up? | ||
17:37
neonse joined
|
|||
svnbot6 | r15146 | szabgab++ | more tests for multiline comments | 17:39 | |
17:39
reZo joined
|
|||
svnbot6 | r15147 | szabgab++ | add "default" and "slurp" to perl6.vim | 17:42 | |
17:43
jrigby joined
18:00
xinming_ joined
18:05
reZo joined
18:23
pinskian joined,
pinskian left
18:35
mncharity joined,
mncharity is now known as putter
|
|||
putter | "This is a big undertaking. Perl 6 is the sort of language that only Perl can parse. But I'll do my best to get vim to." - perl6.vim :) | 18:39 | |
Schwern | I have a new principle of "good ideas that are really bad in language design"! | 18:42 | |
Treat built in types differently! | |||
lumi | Nonsense, it works so well in Java | ||
Schwern | And Javascript which is what I'm beating my head against right now. | 18:43 | |
Pass by reference? Sure! As long as you're not a built-in! | |||
18:48
nipra joined
|
|||
putter | It's fun when folks are unwilling to take a N% performance hit to get architectural clarity... and years later are still unwilling, despite it running M x 100% faster. Suggests "starved for computes" remains a primary concern. | 18:51 | |
cj | Schwern!!17! | ||
Schwern: ah, javascript. what you working on? | 18:52 | ||
or is that classified? | |||
Schwern | cj: I'm reimplementing this www.wium.net/nw/evetool/ | 18:53 | |
lambdabot | Title: EVE Character Tool | ||
rindolf | Hi Schwern | ||
Schwern | Mostly as an excuse to learn Javascript | ||
Hi all | |||
And have people send me ISK in EVE. | 18:54 | ||
cj | Schwern: eve looks a lot like homeworld... did they buy up the development team and artists? | ||
Schwern | Right now I'm struggling with the fact that in Javascript undefined + 5 == NaN | ||
cj | d'oh. | 18:55 | |
Schwern | cj: Its only superficial. | ||
cj | if(foo == undefined){ foo = 0 } | ||
Schwern | And that I can't write something like increment(foo.prop, 5) | ||
cj: But that's VERBOSE | |||
cj | or (foo == undefined ? 0 : foo) + 5 | ||
Schwern | But that's BIZARRE | ||
cj | Schwern: yeah, well... not everything can be perl | ||
Schwern | Best I've come up with is... Object.prototype.increment = function(prop, add) { (this.[prop] = (this.[prop] || 0) + add } | 18:57 | |
cj | hide it behind something more pretty :) | ||
like that | |||
Schwern | Then foo.increment(prop, 5) | ||
But still... yuck | |||
rindolf | Schwern: holy. | ||
cj | you could also have add + makeSureItsANumber(foo) | 18:58 | |
Schwern | Its fun to learn new languages... and recoil in horror. | ||
cj: But how do I know what property to look at on foo? | |||
cj | there's no type checking, is there? | ||
yeah, your treatment looks good to me other than it looks nasty. limitations of the language, I guess | 18:59 | ||
there's no operator override either, is there? | |||
Schwern | Dunno | ||
cj googles | |||
19:00 | |||
binarylord.com/work/js0wood.pdf | |||
is what I meant | |||
type checking | 19:01 | ||
Schwern | That's a language extension proposition | ||
? | |||
cj | www.mozilla.org/js/language/js20-20...ading.html | ||
lambdabot | Title: JavaScript 2.0 Operator Overloading, tinyurl.com/23rlqy | ||
cj | oh? well, then nevermind :) | ||
Schwern | Yeah, nobody's using JS 2.0 yet | ||
cj | I didn't *read* it :) | ||
Schwern | Its all 1.5 if you're lucky. | ||
The Javascript 2.0 spec was written back in 2000. Its just now solidifying. Mozilla is just getting around to implementing it. It'll be stable in most browsers around, say, 2010. And people think Perl 6 is taking a long time! | 19:02 | ||
cj | well, I s'pose $we could start pressing the IE and Mozilla folks to push support into their browsers | 19:03 | |
19:03
shachaf joined
|
|||
cj | but when you rush miracles... | 19:03 | |
Schwern | IE hasn't even implmented DOM level 2. | 19:04 | |
Oh bleh. | 19:06 | ||
Ok, I'll stop complaining about Javascript here. | |||
19:07
wilx left
19:08
allbery_b joined
|
|||
putter smokes an old pil2js (6.2.13). bbl | 19:13 | ||
19:16
elmex joined
|
|||
TimToady | someone with more time than I have should rewrite cbstream.rb in p6... | 19:19 | |
19:23
stevan__ joined
|
|||
rindolf | Schwern: what's up besides JavaScripting? | 19:24 | |
Schwern: any progress with TAP::Harness? | |||
Schwern | Ovid has taken that over with TAPx::Parser. They're talking about gutting Test::Harness and using it as the engine making TH 3.0 | 19:28 | |
rindolf | Schwern: I see. | 19:29 | |
lumi | TimToady: What's cbstream.rb? | 19:30 | |
[particle] | timtoady: did the S03 reorg make major changes, or just move text blocks around? does it have any ramifications for existing parsers? | 19:31 | |
...it's a lot to reread | |||
wolverian | TimToady, is there a %%()? | 19:36 | |
TimToady | wolverian: not yet. :) | 19:41 | |
19:42
Khisanth joined
|
|||
TimToady | [particle]: two changes. .accept => .ACCEPT and added @: syntax to be a listop-y kind of @() | 19:42 | |
cbstream.rb is the irc gateway that's feeding PerlMonks' chatterbox to #cbstream on freenode. | |||
[particle] | TimToady: thanks! | 19:43 | |
TimToady | that's so that we get @@: to mean "chunky". | ||
[particle] | it doesn't look chunky, but it works | 19:44 | |
TimToady | So @@: means pretend you bound this to a @@ and return what you'd've got if you'd done that... | 19:45 | |
And $: @: %: &: @@: are just $() @() %() &() @@() without needing the trailing paren. | 19:46 | ||
basically reusing the meme that ":" turns a method into a listop. | 19:48 | ||
except we tweak the precedence slightly so it governs operators like Y and XX as well. (sounds genetic...) | |||
avar | heh, more sugar:) | 19:49 | |
20:16
graywhite joined
20:43
weinig|zZz is now known as weinig
|
|||
TimToady | anyway, the implicit cbstream.rb challenge is at www.perlmonks.org/?node_id=596867 | 20:47 | |
lambdabot | Title: Re: I prefer to: | ||
TimToady | seems like a good chance to see how async {...} works | ||
and, of course, to show how much prettier Perl 6 is... :) | 20:49 | ||
21:13
DebolazX joined
21:16
aufrank joined,
Aankhen`` joined
21:41
stef__ joined,
ludan joined
21:48
jferrero joined
|
|||
putter | TimToady: re cbstream, add it to project_planning/TASKS or TALK? though it is entirely unclear whether anyone actually looks at them... | 21:50 | |
22:02
dduncan joined
|
|||
putter | smoke of old pil2js is up. 6.2.13 release, r14402, 2006-10-17. | 22:04 | |
It's rather less green than I had hoped/remembered. :/ | |||
eg all of t/builtins/arrays/ failed. | 22:07 | ||
22:14
awwaiid joined,
Grrrr joined
|
|||
putter | testing 6.2.12 pil2js... | 22:15 | |
If anyone knows a time with a good working pil2js, I'd love a pointer. tnx. | |||
looks like 6.2.12 r10930 2006-06-26 doesn't build under ghc 6.6. :/ | 22:19 | ||
definition: computer science, noun - a maze of twisty little passages | 22:20 | ||
stevan: ping? | 22:21 | ||
anyone know the state of Moose and such? | 22:22 | ||
the v6.pm "create a p6 runtime on p5" effort? | 22:23 | ||
22:26
hexmode` joined
22:57
neonse left,
weinig is now known as weinig|away
23:30
miyagawa joined,
devogon joined
23:31
mako132_ joined
|
|||
ingy | hi putter | 23:45 | |
putter | hi ingy | 23:46 | |
23:46
Psyche^ joined
|
|||
ingy | :) | 23:47 | |
putter: I myself would like to know the answer to that question | 23:48 | ||
putter | working pil2js? | ||
oh, Moose/v6? | |||
ingy | yes | 23:53 | |
ingy goes off to write a better Javascript version of Digest-MD5 | 23:54 | ||
putter , battered by wandering a dark maze of twisty little passages, sits down against a wall to contemplate which way to go next. | 23:56 | ||
I wonder if there is a phrase for that variety of yak shaving in which the yaks can teleport, can grow their hair back instantaneously, ... and have an evil sense of humor. | 23:58 | ||
Pamplonan running of the yaks | 23:59 |