pugs.blogs.com | pugscode.org | pugs.kwiki.org | paste: sial.org/pbot/perl6 | <stevan> Moose... it's the new Camel ":P | .pmc == PPI source filters!
Set by Alias_ on 16 March 2006.
00:02 Quell joined
TimToady you know, @;_ is really ugly. I wonder if @@_ would be better for multidims... 00:02
Must be Friday night in the US again... 00:07
Limbic_Region yep 00:08
and as far as aestectics go - they both look like you are attempting ascii art to me
buu sends Limbic_Region an h 00:16
TimToady: Perl6 is just trying to win a competition that involves how many emoticons you can make compile, right?
Limbic_Region it is Friday and I never claimed to be able to speel
TimToady it would presumaby confuse Ruby programmers, which would have to be a plus... 00:17
buu Reasonable.
00:22 stevan_ joined 00:24 stclare` left
KingDillyDilly So, semicolons might be used for more than ends of lines in Perl 6? 00:34
SamB thought newlines were the method of choice for ending lines
KingDillyDilly Ends of statements, or whatever.
I remember some BASIC terminology. Not so good with Perl. 00:36
If I may revisit my old Function Critique from perlmonks.com/index.pl?nodenum=3885...d%20Nodes, I think the standard mathematical notation for abs should be allowed in Perl 6, and anything that needs to be changed to accomodate it should be. Possibly not much change would be needed, from what I remember of the discussion (perlmonks.com/?node_id=388534). 00:54
00:54 FurnaceBoy_ joined 00:58 qu1j0t3 joined
meppl gute nacht 01:00
KingDillyDilly Some quoted TimToady commenting about using the standard notation for abs, I think from back when he was developing the first version. He made it sound like that's way at the end of his priorities, but I wasn't clear on what he meant. I'd have to look through a bunch of threads to find the quote. 01:01
TimToady macro circumfix:<| |> {...} is all you need. 01:02
KingDillyDilly Yeah, I think that's what I said in the PM thread. 01:03
Well, sort of. 01:04
TimToady But it's certainly true that we're not bending over backwards to support pure "math notation". 01:06
We've kept away from defining any prefix:<|> more because it would be visually confusing with infix:<|> than out of respect for math notation. 01:10
KingDillyDilly Pure math notation is well defined and easy to support. Iif it's not built into Perl because of some conflict or confusion with other stuff, maybe there should be a pure math mode, or at least a module. I should say it's easy though because I don't really know how many symbols and whatnot there are. 01:16
s/should/shouldn't/ 01:17
TimToady Pure math notation is optimized for mathematicians, not humans. We'll make it possible to define things how you like, but Perl ain't math.
KingDillyDilly There would be keyboard limitations anyway. It's just a coincidence that keyboards have vertical bars like the abs notation. 01:20
TimToady Mathematicians use all sorts of weird whitespace dependencies and two-dimensional thingies that don't work out terribly well in a computer language. 01:21
They're also quite inconsistent about what some symbols mean, even comma and vertical bar. 01:22
Steve_p Its all context driven :-/
TimToady I was just about to say that.
At least we're allowing the user to define Unicode operators, which is a lot more than you can say for most other programming languages. 01:23
Steve_p bites his tongue ;) 01:24
TimToady "enough rope to shoot yourself in the foot"
KingDillyDilly At least you won over the biologists if not the mathematicians. 01:25
TimToady Biologists have simple desires. :) 01:26
Infinite strings, mostly.
well, huge strings...
and maybe a decent database to store them in. 01:27
sort of CGI writ large.
But I think Perl 6 has a decent shot at the mathematicians as well. 01:28
Or rather, some future variant of Perl 6...
Steve_p Wall Street programming types like Perl too, and Sybase, oddly enough. 01:29
TimToady One thing I can guarantee the mathematicians is that standard Perl will never waste juxtaposition on multiplication. 01:30
I think the Wall Street types will particularly like the ability to nail down modules to particular versions, along with the ability to use different versions in the same program. 01:31
At least some of them are very picky about upgrading modules...
KingDillyDilly That sounds like a good Perl 6 installation will become huge with various versions of each module. 01:33
01:36 vel joined
KingDillyDilly I'm picturing someone looking for scripts on the internet and finding that they all specify a particular version of a module, then the kid decides to download the full module package and ties up his computer for hours. But I don't know exactly what "nailing down" would mean exactly. 01:38
Anyway, if I'm thinking correctly, extra care to reduce bugs in modules and reduce the number of versions should be recommended for Perl 6 modules. 01:40
avar As opposed to him downloading the script witch would just silently fail because the API of the version you have is not compatable with the one it's written for?
KingDillyDilly Failed download or not working...same thing. 01:41
avar But you'd know that it happens due to incompatable versions, witch you wouldn't know otherwise. So I fail to see how this could be a problem since you're given more to work with to solve the problem. 01:43
KingDillyDilly Currently, programmers strive to make their scripts backwards compatible. Allowing them to specify a module version might make them lazy and put the problem on the consumer. 01:44
I think it's good, it's just that there are issues. 01:45
We may see more inlining of modules. 01:46
01:47 bsbr joined 01:48 aufrank joined 01:55 justatheory joined
KingDillyDilly Hey, look how far ahead of my time I was. My auto-updating snippets idea could be adapted for this (perlmonks.com/?node_id=374851) to install or inline modules that the script calls for. 01:57
PerlJam KingDillyDilly: you know, modules could always treat the versions as roles I bet. At least they have the ability to specify which API they conform to in various ways. 02:01
02:02 vel joined
KingDillyDilly I heard that term "roles" somewhere. That's all I know. 02:05
PerlJam In the language design game we're all entitled to makeup our own terms. Fortunately, only Larry's terms count for perl6 :) 02:10
TimToady well, terms and operators...
PerlJam speaking of which ... @; makes more sense as @@? What happened to the mnemonicity relating to @foo[@a;@b] ? 02:12
(well, there was a connection in my head if no where else :) 02:13
And why is it that I always seem to be eating while watching this channel?
azuroth heh, I'm eating too 02:15
avar I want pizza
PerlJam make make some homemade pizza this weekend.
I need some cheese though. 02:16
azuroth we were planning on making this apparently uber dough tonight, and cooking tomorrow
avar suspects drug slang 02:19
Steve_p heh
TimToady @@a is just a different mnemonic.
Steve_p blinks
TimToady And it looks a lot less like a bare @ with a terminator after it.
well, speaking of dinner, I'm being hauled off... 02:20
so biab &
buu So what is @@a? or @;a or what not 02:27
02:36 p5evalbot joined, vel joined
nothingmuch what's the Rule -> Regex change about? 02:38
TimToady After spending much time dithering about for a good name for non-backtracking rules, Damian hit upon the idea of just calling those "rules" and resurrecting "regex" to refer to the general regex {...} form. 02:39
02:40 amnesiac joined 02:43 vel joined 02:47 vel joined
KingDillyDilly buu: Multidimentional array, I think. 02:50
buu Scary.
@@x[1][2] ?
@@@x[1][2][3]
KingDillyDilly He originally said @;a_ and @@a_ and I thought the underscore was part of it, but I don't know anymore. Not that I'd know how to use it anyway. 02:51
buu: that's hot I thought of it and I was going to suggest a number instead of multiple @, but I know, like, nothing about this, so I shut up. I figured you'd be proud of me for that. 02:52
s/hot/how/
buu Oh I am.
KingDillyDilly dries his hair and eats 02:53
azuroth humm. I guess it makes sense. though it wouldn't be necessary, would it? just some optional type safety?
nothingmuch good night 02:55
audreyt TimToady: so how is 02:56
regex {... }
different from
rx { .. }
?
can we not have the first form? :) 02:57
(I know of the quotelike vs anon declarator difference)
actually, never mind. timtowtdi. 02:58
03:21 coumbes joined, xern_ joined 03:30 penk joined, marmic_ joined, scook0 joined 03:38 frederico joined 03:41 Entonian joined 04:10 FurnaceBoy joined 04:12 KingDillyDilly left 04:13 elmex joined
PerlJam okay, I just re-read S06 and @@_ does read better. I guess it's just weird that we have a "list of lists" thingy that looks like [;] which gets put in an array that looks like @@. Just like it's also weird to me that we have a \() matching up with a :() 04:19
perhaps though, syntactic correspondence isn't that important. 04:20
(as long as I can keep the concepts straight, it's all good :-) 04:21
arcady I mean, you also have @ with [] and % with {}
@@_ and [;] don't seem too bad 04:22
PerlJam arcady: yes, but those @[] and %{} are usually on the same side of an expression, while the others are on opposite sides of some sort of binding or assignment.
arcady true 04:23
but @@ is definitely better than @; 04:24
@;foo; looks wrong to me.
PerlJam though I almost want to say (0..3 @ 'a'..'d') instead of (0..3; 'a'..'d')
arcady well, the ; there makes its own sense 04:25
with its original meaning of a super-comma
PerlJam sure, I'm just letting the neurons fire as they may :)
arcady I think by the time perl 10 comes around, syntax will be reduced to just UNICODE SYMBOL DO-WHAT-I-MEAN 04:26
PerlJam heh
btw, would $@foo make any sense? Because if I make a list of all twigiled vars using @arrays, the second @ sure looks like a twigil and begs the question of $@foo and %@foo 04:37
scook0 $@foo looks like what you'd write if you wanted to use @foo in list context, but as an Array rather than flattening -- of course, in that interpretation, it's not acting as a twigil 05:09
one issue with @@foo is that it suggests @@@foo et al. should be meaningful, by analogy with $$$foo 05:12
FurnaceBoy <KingDillyDilly>Yes, me again. There's nothing in the topic of #perl6 that explains that this channel isn't about the current version of Perl and that it isn't for support of the current version. 05:16
is that guy as dumb as he sounds?
arcady sounds like it 05:17
FurnaceBoy eek
FurnaceBoy pins his hopes on natural selection 05:18
arcady first I saw him, he was trying to sell a web-based diff...
FurnaceBoy oh gawd, I think I heard that pitch 05:19
05:20 reZo joined 05:32 KingDillyDilly joined
KingDillyDilly What's there to sell? It's free with no ads. www.polisource.com/diffnote/ 05:33
Is the topic for this channel so obviously about Perl 6 development than a Perl newbie would know? I know nothing about any of the things in the topic, like pugscode. 05:34
arcady um... the channel name... 05:41
KingDillyDilly That's the problem. How's someone to know Perl6 isn't the latest version that someone new to Perl would need to know? Are they supposed to copy and paste each of those web addresses in a browser to see if it applys to the Perl they want to ask about? 05:42
arcady how would they get here in the first place? 05:43
and how often is this even a problem?
KingDillyDilly U S A B I L I T Y
Write it 100 times on the blackboard
If they were referred to an IRC channel by a tutorial, they'd probably be referred to the correct one, but they may just be on Freenode browsing. 05:44
TimToady then they're probably just troublemakers. :)
KingDillyDilly Well, at least I'm taller now. I used to be called a troll. 05:45
TimToady Well, I'm not a person to be poking labels on people, but I have noticed that there are certain people who are never happy unless they have something to be unhappy about. 05:47
I don't profess to understand the contradiction... 05:48
KingDillyDilly This was just a minor proposal, but then buum FurnaceBoy, and arcady started name calling. 05:49
s/buum/buu/
TimToady Maybe they thought you'd enjoy it. I dunno...
KingDillyDilly Nobody enjoys being called dumb, but mostly it degrades this community when someone who wants a clearer topic is attacked and called names. 05:51
Or just changing #perl to #perl5 should work. No big deal... 05:54
Actually, in Gaim, the room list isn't alphabetical, but that's another issue.
By no big deal, I mean I don't think it's a big deal and I ended the conversation on #perl and here, and people brought it up again. I don't get into protracted debates about these things. If you think someone is dumb for a suggestion like this, keep it to yourself. 05:56
TimToady Well, I've been fighting the flu, so I'd better toddle off to bed. 05:57
I don't think you're dumb. You're just persistent, which can be both a strength and a weakness. 05:58
nite &
KingDillyDilly Symbols even with nite?
ayrnieu postfix & is an idiom for a public '/away'. 05:59
Used to make it clear that you'll not be around for a while, of course, if you've spoken recently. 06:00
KingDillyDilly Oh
ayrnieu think of shell syntax.
KingDillyDilly I never think of shell syntax, or know it.
arcady it's the unix way of putting a program in the background 06:01
ayrnieu Should you come to learn it, you will now have amusing context to tie into what you learn.
KingDillyDilly I know to put semicolons between commands. That's about it. I had to figure out Tar once and immediately wrote EzTar for myself if nobody else. I guess someone will accuse me of "selling" EzTar now. Go on an buy it. I'm shamelessly plugging two charities on its webpage. 06:04
arcady well, the idea of a web-based diff, especially one for local files just struck me as kind of... dubious 06:05
ayrnieu wrapping such things is normal; I often wrap 'find' to not print permission errors.
arcady yeah, and tar has a pretty nasty syntax 06:06
probably because it is the Tape ARchiver
ayrnieu although it's sufficient for probably everyone to know a common subset of tar usage, and consult the manual if they need to do anything strange. 06:07
06:08 Aankhen`` joined
KingDillyDilly Many changes to web pages don't need to be kept secret, but you're correct that people should be aware that I can access what they're diffing. People have diffed mailing lists. 06:08
ayrnieu I noticed the other day that I will tend to tell people to read manuals for things that I actually learned first by example. 'tar' is an example of this; for a while I had invocation instructions in my home directory.
an instance. 06:09
KingDillyDilly I'm half way towards having a Unix philosophy (classic, no GUI Unix). A pretty graphical interface isn't so important, but it still has to have usability, and TAR wasn't usable enough for me. 06:13
And it just takes the right text. Too bad programmers don't analize the words they use as much as their computer programs. Or even half as much. I often do. 06:14
arcady the benefit of the unix way is that you CAN wrap tar however you want, relatively easily
KingDillyDilly I don't want to. I want it done for me. 06:15
scook0 ... and the failure of the unix reality is that you may have to :P
06:20 scook0 joined
aufrank is : ever a twigil? 06:48
does $:a mean something?
scook0 aufrank: I think at one stage it had something to do with pairs or named args, but that's probably been dropped 06:52
aufrank will have to look at the twigil table again tomorrow
scook0 aufrank: I don't see $: in the latest S02 (21 Apr) 06:54
:$foo means :foo($foo) [S06], and at one point I think it used to be $:foo 06:55
$:foo is probably unused (but that might be a good thing) 06:56
aufrank scook0: yeah, the :$foo form posted to the list today made me wonder about $:foo 06:58
I thought it might have been one of the within-object twigils
like $.foo
07:00 ntgrl joined
scook0 maybe ... but then private became `!`, so it's now $!foo (or self!foo) 07:02
aufrank yeah, that jives with what I remember
audreyt TimToady: surely "let" and "temp" are also declarators? they does not affect the pad, but should prolly be parsed the same 07:04
aufrank can anyone give a use case of the .= form of method calls? 07:06
audreyt @arry .= sort;
$moose .= chomp; 07:07
TimToady audreyt: if it makes sense, sure. The lists weren't not meant to be exhaustive, which is why I used "include"
audreyt TimToady: k, cool
aufrank heh. I guess that ones a win
s/ones/one's/
scook0 my Dog $spot .= new; 07:08
TimToady ?eval my @array .= sort;
07:08 evalbot_10053 is now known as evalbot_10054
evalbot_10054 Error: unexpected ";" expecting word character, "::", dot, ":", "(", comment, block construct, identifier, term, term postfix or operator The .= operator needs a type specification. 07:08
TimToady ?eval my @array.=sort
audreyt *nod* it's statement_control:<my> now ;)
which is wrong
evalbot_10054 Error: unexpected end of input expecting word character, "::", dot, ":", "(", comment, block construct, identifier, term, term postfix or operator The .= operator needs a type specification. 07:09
audreyt TimToady: can I go ahead and add temp/let?
aufrank "if you're looking for a mathematical vector product, this isn't where you'll find it"
TimToady sure, as long as you point out that they don't actually declare variables.
aufrank is there somewhere w/in perl 6 that I will find a vector product?
TimToady not currently. 07:10
(that I know of, anyway)
doubtless the PDL folks will have one or two hanging about eventually... 07:11
audreyt actually, per S06,
temp ($x, $y) = (1,2);
is currently unspecced
but that's probably useful 07:12
aufrank it'd be nice to get a @@outer_product out of @col_vec by @row_vec
TimToady It's not clear to me that signature is a good default arg.
aufrank but yeah, I reckon it'll show up when the pdl folk do
aufrank doesn't know who in the community actively works on PDL 07:13
TimToady we've certainly left sufficient bait in S09 for the pdlers.
aufrank are any of them involved in p6 development?
audreyt TimToady: it works the same for single-args though
aufrank yeah, I've been waiting for someone to rise to it
audreyt what this prevents you from doing is
temp 1 = 3;
and define Int.TEMP
TimToady how is that different from ordinary assignment?
audreyt but I don't see a big loss there
oh sorry .I mean 07:14
temp 1;
without the assignment.
07:14 KingDiamond joined
TimToady P5 still treats it as an lvalue. 07:14
audreyt per current S06 it's legal
because temp takes an objec
and triggers .TEMP at end of scope 07:15
and do nothing more.
I still think it should take Sigs forms
TimToady maybe temp only works on mutable objects.
audreyt temp ($x, $y);
# not mutable
TimToady distributes to two mutable objects
($x, $y) = 1,2 07:16
aufrank declarators take sigs, not seqs right?
TimToady have to be mutable anyway.
sure, but these aren't declararing anything really
they're just instructing a mutatable object to start a transaction. 07:17
sides, you can temporize methods, and those are *illegal* in sigs. 07:18
they're just lvalues
KingDillyDilly I edited Wikipedia's article ( en.wikipedia.org/w/index.php?title=...d=49521898 ) and quoted this channel, including people's handles ( en.wikipedia.org/wiki/Talk:Perl_6#B...to_Regexes ). Just want to make sure that's ok. Are the IRC logs for this channel permanent? 07:19
audreyt TimToady: ok, I'll check in that. 07:22
r8908 07:24
TimToady thanks, KingDillyDilly. I note that there are some other things that have suffered "design rot" too. Couple places where they seem to think <{...}> is an assertion, for instance, when it should be <?{...}>.
audreyt KingDillyDilly: yes, irc.pugscode.org 07:25
KingDillyDilly Well, unless there's an HTML element within those angle brackets, I know nothing about it. 07:26
Should I replace every instance of <{...}> with <?{...}> ? Literally? 07:27
KingDillyDilly is into Wikipedia because I shamlessly plug several of my webpages there and want to give something back 07:28
audreyt TimToady: *func() runs func under list context? 07:29
TimToady I would think so.
audreyt mm
because the S06-capture design has that
my $moose = \(*@x, *@y); 07:30
does not really flatten @x, just cast them into captures
and *$pair would expode that into named
so, either *func provides a Capture-item context, or its use inside \() expressions is not the same as outside 07:31
TimToady KDD: there are only two <{...}> that should be <?{...}>, I think.
KingDillyDilly IE only found one. 07:32
audreyt (also we have "list" prefix listop to do that)
the flattening that is
because if * only confers flattening 07:33
TimToady but the whole point of capture is to do the same thing a normal function arglist would do...
audreyt then *$pair can't be made to work
yes. which is why I think *$foo should be caster into Capture, not caster into List
and "list" should be caster into List
in, *func(), if func has 07:34
return(1,2,3)
TimToady KDD, the first is Simplified code assertions: <{...}>
audreyt that still works even if * confers item context 07:35
07:35 kanru2 is now known as kanru
TimToady the second is the second line of the example below 07:35
KingDillyDilly I changed the only one my browser found...searching for the other...
TimToady rx { ( ab* ) <{ $1.size % 2 == 0 }> }
audreyt so I'm not sure what list context buys us here (this is re S03 change on C<*>)
(also, does +func() confer Num or Int context?) 07:36
probably num
KingDillyDilly Done 07:37
TimToady uh, what S3 change? 07:38
audreyt ~ + ? * $ @ % & ==> Str Num Bool Capture Scalar Array Hash Code
TimToady: in your last S3 change, you added <*> among the item-context consters but call it a list-context one
pasteling "audreyt" at 220.135.90.73 pasted "S03 fix" (24 lines, 1.3K) at sial.org/pbot/16843 07:39
audreyt er, never mind, I'm sorry
that line was already here. :)
TimToady reformatted para 07:40
audreyt (still, I think * cannot confer list context now) 07:41
aufrank audreyt: I see the point of going * is Capture context, but there's something to be said for the */** lazy/eager mnemonic
TimToady but *func() in list context just falls out of the fact that func() always defaults to list if it doesn't know. 07:42
audreyt right. where it matters is *$x
TimToady I'm not sure we want to call func() lazily...
but there it doesn't matter since we can do it lazily.
audreyt so, would this work? 07:43
TimToady certainly $x doesn't care if it's in list context.
audreyt $x = (named => 'pair'); func(**$x);
TimToady it's only *@a that might be a problem
and *%a
audreyt if %a is flattened, we get a list of pairs
but func(*%a) and func(**%a) has them as named 07:44
compared to *@a
where func(*@a) always goes to positionals
even if @a contains pair elements
I think they should work the same as $x 07:45
07:45 iblechbot joined
audreyt (when holding an Array or Hash object) 07:45
TimToady fine by me. But ** is more list contexty than *, in a way.
audreyt which means * couldn't flatten-to-list
so, does ** simply mean "cast to Capture, but eagerly" in function args?
or it's the eager list caster, and therefor **%a can't become named? 07:46
I'm fine with the latter, but as aufrank noted, * and ** would be a bit different
TimToady I'm fine with eager Capture.
audreyt cool. that leaves room for lazy hashes in the future :) 07:47
(lazy mappings, really; they can't be hash tables)
TimToady novice: "What does that mean, 'Can't capture infinite list eagerly.'?"
what did we decide about duplicate named args? 07:48
audreyt they get bound according to Sig sigil
@ gets all; others get last.
TimToady right.
could go with normal sigil gets last, and new @@ sigil gets all. 07:49
though it's not the normal multidim situation... 07:50
audreyt ok. then this running example
push @foo, *$bar;
would cease to work; you have to say $bar[], or @$bar
three ways to do the same thing is a bit much anyway
oh wait, if push has *@_ as last arg 07:51
then it still works; infix:<push> is different from method push.
TimToady infix? 07:52
audreyt I mean, prefix:<push>.
TimToady @foo push 1,2,3;
aufrank reads alright.
audreyt @foo.push(*$bar) # wouldn't work if $bar is a Hash... but maybe it's a feature
TimToady arguably it's ,=
which we've rejected several times. 07:53
as to hard to tell from .=
*too
aufrank audreyt: wouldn't work because it would be a lazy Capture of named?
TimToady %foo.push would presumably add pairs to the hash 07:54
sorry, off on a tangent...
aufrank %foo push *$bar # add pairs to the hash?
heh, TimToady beat me to it 07:55
audreyt aufrank: %foo.push(x => 1, y => 2);
aufrank: right, and I presume Array.push wouldn't take nameds well 07:56
TimToady I think we have to stick with * to deref as arglist and % to deref as hash object
aufrank surely you could have an Array of Pairs as a data structure that you wanted to push to
audreyt aufrank: but you'll use normal postfix [] or prefix @ for that 07:57
which explicitly denotes arrayness
aufrank fine, I guess I'll settle for two ways to do something I'll almost never do anyway ;)
audreyt TimToady: the listfix= has a twist:
$moose[] = @x;
TimToady @pairs.push(%foo.pairs) if nothing else
meppl guten morgen 07:58
aufrank guten nacht
audreyt TimToady: do we do a syntactic scan for postfix zen-slices as well?
$moose[1,2,3] = @x; # this too
TimToady: pugs has a screenful of code doing that analysis
(but I think we can't get rid of them, right?)
TimToady yes, that's interesting, but I think it has to do what the user expects. 07:59
07:59 kanru joined
audreyt ok. so for [] and {} before =, we need to do a heuristic scan 07:59
TimToady and they'll certainly expect that to be a list assignment.
if there are multiple subscripts
we could probably get away with just saying it's list assignment if there's a subscript at all. 08:00
audreyt and $moose[$foo[$blah[1]]] = ...context...
context = scalar
aufrank audreyt: with listfix= your example would have a copy of @x in slots 1,2, and 3 ?
audreyt and $moose[$foo[$blah[1,2,3]]] = ...list...
aufrank: nono, no way, it takes the first 3 elements of @x. 08:01
TimToady: $moose[1] = @x; # too useful
TimToady how often are people going to write loop ($a[0] = 1, $a[1] = 2; ...
aufrank oh, got it
audreyt otoh, maybe it's not that useful. hm. not sure
p5 doesn't have this problem because it's shadowed by sigil variance :) 08:02
TimToady yep.
I think it is probably okay to train people that P6 subscripts like to pretend that they're lists. 08:04
if you say $moose[@jaw] you going to get a slice.
audreyt $moose[$antler] too. 08:05
TimToady and it's just a little like the interpolate-ending-with-brackets rule
aufrank what's the point of using the scalar container at all in that case? 08:06
audreyt it's just a 1-slice, but for assignment purposes it still confers lists context
TimToady On the other hand, there's probably some optimizations that depend on knowing you only are getting one value out of it.
audreyt aufrank: actually, @moose[@jar] and @moose[$antler] works the same.
aufrank right-- does $moose[@jar] buy you something that @moose[@jar] doesn't?
audreyt TimToady: for those optimizations, s/one/statically known/ is good enough 08:07
TimToady: so doesn't have to be oneness
TimToady oneness lets you throw out the looping code.
audreyt er, ok... 08:08
TimToady you say you alredy have the code to do the analysis?
audreyt yes
inferExpCxt
in src/Pugs/Eval/Var 08:09
TimToady much to be said for inferring the expected context...
audreyt it's the code luqui actively hates
(which is why he put all of them into Eval.Var)
and it's really heuristics
based on (say) known calls to "list"
and inferring return types for statically bound functions 08:10
and recursively for [] and {} in it
TimToady a mess, in other words
audreyt yes.
(but neccessary to preserve the p5 look-n-feel without sigil variance annotation)
KingDillyDilly ...don't get me started on "say"
TimToady how about a simple heuristic. one number or scalar, it's scalar. Otherwise assumes list
audreyt TimToady: recursively for sure? 08:11
$x[$y[1]]
aufrank I would want a scalar there for sure
TimToady that would seem wise.
aufrank $x[$y<a>] too 08:12
TimToady that's defined as a single element
so yes.
aufrank oh, right-- no list context anyway
audreyt and by "scalar" you mean scalar literals, non- @ and % variables, and nothing else? 08:13
even "undef"?
(which is not a literal)
or "rand"?
(which is not a literal)
TimToady any function goes list
audreyt cool! deal
TimToady except + or ~ ish things
audreyt oh , er, heh 08:14
how do know those are special?
by "proto"?
(which fallsback to full analysis)
TimToady I think people will be happier if we simply enumerate them.
+ is special inside [], and ~ is special inside {}. 08:15
audreyt and -func() is
TimToady and maybe vice versa
ooh
audreyt scalar
has to be, otherwise $x[-$moose] is gone 08:16
TimToady negation is kind of important for subscripts.
kinda goes with +
scook0 it sounds like this "scalar inference" is getting too complicated for its own good 08:17
audreyt scook0: it's currently full try-binding inference
which is even more costly (and one of the reason of pugs's runtime slowness in profiles)
TimToady: so
$x[-$moose] = @foo; #scalar 08:18
$x[$match.from] = @bar; # list
(it's the second one that prompted full try-binding inference)
and you have to disambiguoate with
$x[+$match.from] = @bar;
TimToady $x[$match.from] = +@bar too 08:19
audreyt or (scalar @bar)
but anyway, yeah.
TimToady I don't suppose we can delay it till we actually know how many 08:20
scook0 what would happen if you made scalar subscripts the default, and introduced some kind of statically-visible "marker" for slicing?
audreyt TimToady: can't, it's parsetime
TimToady: this wasn't an issue when listop= wasn't there
TimToady oh right, we just did that... dud
duh
audreyt TimToady: but now it is, my dynamic inference has to be lifted into parser
which has significantly fewer info
scook0: like @{$hash}{func()}? 08:21
I believe someone tried that
didn't work too well :)
TimToady parse as list, capture, then revert to assignment semantics?
audreyt TimToady: revert at runtime?
$x[moose()] = 3, 4, 5; 08:22
TimToady based on 1 vs many subscripts
audreyt not sure it can work
pretty sure it can't :) 08:23
I think it's a parsetime decision, and it's either proto-lookup or enumerated forms
(or both, heh)
but enumerated forms feels cleaner
TimToady how 'bout [1] [$x] [+anything] [-anything] is scalar, all else list 08:24
audreyt and I suspect slices are rarer in practice than singulars
TimToady maybe with recursive subscripts
audreyt sure, but another idea is [@x] [list y] [any,] is a list, everything is scalar 08:25
*everything else
08:25 Southen joined
audreyt (if slices are rarer, then that'd be more natural) 08:25
(and again with recursive subscripts) 08:26
scook0 audreyt: that's closer to what I had in mind with my earlier suggestion
audreyt scook0: *nod*
scook0 after all, what about @[$base + $offset]
audreyt yeah. I think list forms are more syntatcically distinct
than scalar forms
TimToady have to include ..
08:27 KingDillyDilly left
audreyt right 08:27
TimToady ; is pretty good indication too...
audreyt $x[@list.reverse,] = ...
$x[@list.reverse;] = ...
both works
TimToady $x[*@list.reverse] :) 08:28
audreyt that isn't guaranteed to work :)
but sure, we can statically detect that
and get the capture object and deref with all its positionals 08:29
that's fine
08:29 larsen joined
audreyt nobody will deref an array using a pair anyway. 08:30
TimToady I mislike the trailing comma for visualness
audreyt you can allow prefix semi. 08:31
$x[;@list.reverse]
a zen followed by anything
is just anything
zen is identity here.
aufrank audreyt: what is the zen jargon standing in for here?
TimToady except if you do have a multidimensional array, that means "all of the first dimension"
audreyt aufrank: $x[] is a zen slice; you give it nothing and get back everything
aufrank cute :) 08:32
TimToady "make me one with everything" could just be a hot dog
audreyt TimToady: I thought $x[1;2;3] is just sugar for $x[1][2][3]
and if you have a multidim, $x[][1][2][3] gets you the same thing
am I mistaken?
TimToady I think you're okay. If you really wanted to splat the first dim you'd say $x[*;1;2;3] 08:33
audreyt right
so prefix ; becomes natural disambiguator
TimToady well, I don't know as I'd go as far as to call it natural.
aufrank time for this one to sleep 08:34
TimToady and in a sense, it's not really right, because $x[;$y] is still a single element, presumably.
audreyt yeah. if we make it to mean list, it'd be hijacking the meaning
so nvm. hm.
aufrank sorry to butt in on the adults while they're trying to work =P
TimToady nite aufrank. thanks. 08:35
audreyt aufrank: sleep well :)
so, I have less problem with $x[$y,] = ...
because , still appears before =
but I agree prefix denotation may look better
$x[($y)] = ... # ok, bad idea. 08:36
(but kinda goes with the lvalue visual marker)
TimToady unless you want to use the same rules you use for lhs in general.
audreyt yeah.
TimToady great minds...
audreyt sick minds, more like, but thanks :)
audreyt thinks some more
TimToady the two are not mutually exclusive.
something before the [] maybe. 08:37
audreyt there is no general-purpose circumfix scalar
context marker
hm
TimToady $x() is going to run into role conflicts...
audreyt I think so far I like $x[($y)] better than $x[+$y] 08:38
and default-item, make provision to list and tuple forms
TimToady I should probably sleep on it.
audreyt sure. doesn't have to be fixed today :)
I'll commit the C<*>-not-producing-list-anymore fix.
TimToady k 08:39
this time maybe I won't try going to sleep with one eye on the IRC screen... :)
audreyt :D 08:40
TimToady anything else need deciding soon?
audreyt sleep well, TimToady :)
no, that's the only fallout I see from the parsing changes
nonparsable = showstopper :)
TimToady okay, g'nite, and thanks.
&
audreyt ditto :)
meppl good night timtoady 08:41
08:44 xern joined
TimToady .zZ( $x.*[foo()] = @foo ) 08:48
audreyt my @x = [1..2, 3..4]; # @x has 4 elements 08:51
my @y = [*(1..2), *(3..4)]; # @y has 2 elements
is the natural consequence
somehow I don't think it's a great problem :)
(that is, outside argument lists (same place where x=>y means a Pair literal), * still doesn't become a list) 08:52
s/same/=same/
09:00 DaGo joined 09:03 meppl joined
audreyt so, why do we need unary = 09:06
when we can say
for @$fh -> { ... }
?
:)
(MJD will be happy) 09:07
(as the Tie::File author, that is)
and then, = can mean "next" always 09:08
say =$fh; # always just one line
say @$fh; # always all lines
and the same iterating concept can be used to everything
xinming yeap, then, = means lazily, and @$fh means eagerly... :-) 09:09
audreyt well, not really
both means lazily
xinming audreyt: is ** and * dead?
...
xinming is confused...
audreyt what I'm proposing is that =$fh always return the next item
like perl5's each(%foo) or readline($bar)
xinming yes
audreyt and if you want a lazy stream of all items 09:10
use @$fh
for @$fh -> $line { ... }
xinming audreyt: do you mean? a whole file will slurp into a "line" ? 09:11
audreyt no... remember
for 1..100 -> $line { ... }
so it iterates one by one
but
for =$fh -> $line { ... }
will only run once
under my proposal
so you won't usually use it.
(you still will use it when you want to read a line only) 09:12
xinming how about @$fh? 09:13
audreyt for @$fh -> $line { ... }
will then run the loop once for each line
for *@fh -> $line { ... }
will read every line first
pack it up into "for"'s argument list 09:14
just like
for '1', '2', '3' -> $line { ... }
I think it makes some sense.
09:15 DaGo joined, xern joined, iblechbot joined, p5evalbot joined, stevan_ joined, pdcawley joined, turrepurre joined, Toaster joined, TimToady joined, Aragone joined, mako132 joined, nothingmuch joined, dvtoo joined, chip joined, chihchun joined, pasteling joined
audreyt or even 09:15
I mean for *$fh, sorry
there is no @fh :)
for *$fh -> $line { ... }
makes an eager loop, just like **$fh (that's the spec) 09:16
09:19 penk joined 09:20 lumi joined
xinming I understand * and **, but I saw you use @$fh instead of *, So I wonder what that does... :-) 09:21
audreyt xinming: wait me a bit, I'll commit to S03 the * changes
it's a conjecture, it's not spec yet 09:22
(if ever)
I was wondering why we still need context-sensitive readline, and why we can't use @$fh and =$fh explicitly as two forms
xinming I can understand what * in front of many things, eg a capture. Which means * will be flaten.... 09:26
audreyt: But I wonder What's the difference between *$fh and @$fh
09:27 turrepurre_ joined 09:28 chris2 joined, p5evalbot joined, chip joined 09:29 pdcawley joined
audreyt xinming: if $fh contains 100000 lines 09:29
=$fh will not consume that many lines
in a for loop
and *$fh is specced to read that many lines first 09:30
xinming hmm, 09:31
xinming wonders, is @$fh same as *$fh ?
audreyt currently it's illegal 09:32
I was proposing using it as a replacement to list-context =$fh.
and have =$fh always mean scalar-context =$fh
it's unrelated to *$fh :)
another idea is to have *$fh read lazily 09:37
and **$fh read eagerly
and forget about = in list context altogether.
that seems to work better
xinming audreyt: how about @ ? 09:38
audreyt then we don't need @ 09:39
since @$fh would mean you can assign back to it
@$fh = (1,2,3);
# clobber the file so it become 3 lines
which is why I said it will make MJD happy
but maybe too magical. 09:40
xinming my $a = (1,2,3); @$a; ---> my @a = (1,2,3); @a; these two are the same IMO.
audreyt that is correct.
the only difference is that in the first case
you can't push into @$a
or say 09:41
@$a = ();
if you want to do that, you'll have to say
my $a = [1,2,3]
xinming a bit complicated. :-)
audreyt yeah, but it was always very strange hwen (...) can magically turn into [...] :)
that strangeness is now gone
(1,2,3) is always a list and you can't extend it or delete from it 09:42
xinming [] means list, () means capture. { } means hash?
audreyt [1,2,3] is always an Array and you can do whatever you want
xinming or () == tuple...
audreyt well, in this case () doesn't mean anything
you can say
my @a = 1,2,3;
my @a = (1,2,3);
and they mean the same thing now 09:43
(as of yesterday)
xinming so () is gone... and () is only for group and other thing, right?
audreyt: my @a = [1,2,3]; ==> @a contains [1,2,3], ? 09:44
audreyt () is always just for grouping...
xinming: no, @a will contain one element
xinming instead of 1,2,3?
audreyt: ???
audreyt yeah
because those are actually two different operators :) 09:45
xinming which do you "yeah" for please? :-/
audreyt there is scalar=, and there is list=
xinming [1,2,3], or 1,2,3 ?
audreyt @a = [1,2,3]; # list=; @a.elems is 1
$a = [1,2,3]; # scalar=; $a.elems is 3
because list= turns [1,2,3] into 09:46
([1,2,3],)
xinming :-)
audreyt i.e. a List containing one Array
and scalar= do no such thing
xinming hmm, 09:47
my $a = 1,2,3; so $a contains 1,2,3 but why can't we make it act as a list? 09:48
xinming still lives in reference... :-/
I mean modify the data in $a. 09:49
Juerd xinming: That's still (my $a = 1), 2, 3 09:50
That's why you need the parens.
xinming Juerd: ok, my $a = (1,2,3); but I don't understand why can't we push something in to $a... :-/ 09:52
audreyt xinming: because $a will contain a List object, and you can't push into lists :) 09:53
or assigning into it.
as a whole, I mean.
(assigning into its members are fine as long as those members are mutable)
so
$a = 4; 09:54
is fine
but
$a = (1,2,3); @$a = 4;
would be bad
$ perl
(1,2,3) = 4
Can't modify constant item in list assignment at - line 1, at EOF
xinming hmm, so ,this list object is static compiled into the bytecode? 09:55
audreyt yes.
xinming my $a = (1..100000), will (1,2,3,4,5,6,7,8,9...100000) compiled as bytecode? :-) 09:57
if so, if someone ask for a program larger than 100M, It's easy to do in perl 6. :-)
(1..100) <-- will this create a list object? 09:59
audreyt xinming: that's a Range object :) 10:01
which can be seen as a List 10:02
I'll bbiab...
TimToady: never mind the *$fh doesn't flatten part 10:03
in
@x = [*$moose]
$moose is still exploded as arguments to circumfix:<[ ]>
so it still does what one expect it to do
and if we have 10:04
$foo = \(3, :by(3);
$foo = \(3, :by(3));
then
0..*$foo; # 0, 3
which manes *$fh in statement_control:<for> always work.
raised that on p6l; noncontrovertial cleanup committed to S03
be back in an hour. 10:05
10:13 elmex joined 10:19 pdcawley_ joined 10:30 pmurias joined
pmurias hi 10:30
11:07 dvtoo joined 11:10 turrepurre joined
Toaster wow, it's a fantabulously nice day outside 11:26
Toaster throws down keyboards and heads out
11:27 merlyn joined 11:41 avar joined 12:13 iblechbot joined 12:18 ghenry joined 12:33 macroron joined 12:40 macroron__ joined
audreyt gaal: packrat is fun 13:14
gaal: it is very space intensive without lazy eval 13:16
and now that rules commit by default... 13:17
perl6 is made very predictive 13:18
13:18 fglock joined
audreyt it is a lot of fun though. 13:18
but I'm not convinced that dynamic ambiguoation resolution via infinite lookahead can by us much in parsing perl6 itself. 13:19
it has a lot of potential in optimizing :panic though
basically making regexes as fast as rules
just pay in space cost
the XTC folks has a pretty solid implementation in Java called Rats! 13:20
cognominal XTC? 13:21
audreyt cs.nyu.edu/rgrimm/xtc/
"making regexes as fast as rules" is a big win
but designing a language based on it
is another matter 13:22
if we adopt packrat, all it buys us is whitespace irrelevance
i.e. all the disambiguated-by-whitespace places can disappear
say 1<2; # would be fine again
and not much else.
and the cost for it is a space penalty (linear to number of subrules) 13:23
as well as making it harder to teach newbies 13:24
since their eyes must also backtrack
cognominal audreyt: I think that a objectified siva is indeed possible by hanging a parrotobjet on it. by chance (or desing), at the PIR level attribute accesses use (set/get)__attributes even if they use arrays/hashes at the pmc level.
audreyt cognominal: I think it's by design
cognominal that means I should get away by redirecting these calles to the underlying object.
I hope to have something working at the end of the week-end 13:25
audreyt on the other hand, making "1<2" work does seem like a win.
pugs currently (erroneously!) recognizes it
but once we switch to optable, that will be gone
and I think I'm going to miss that.
cognominal I am thinking about a micro language that would be a cross of a simplified perl6 and e4x, to manipulate trees (that is ASTs). 13:26
audreyt (background: packrat is a way to memoize redundant backtracks and guarantee linear time for fully backtracking regexes) 13:27
cognominal: I think I'm doing the same, so let's gobby up.
cognominal and could control how the bits are layed out in the underlying objectified siva
gobby?
audreyt are you on mac or nonmac?
cognominal ho
the editor? 13:28
audreyt yeah
cognominal go for it
audreyt the collaborative editor
cognominal join on sterfp.dyndns,org 13:29
fglock audreyt: can I declare a rule with parameters: rule balanced ( $start, $end ) { $start .*? $end } 13:30
audreyt fglock: yes you can.
pmichaud has the syntax 13:31
<balanced: 1, 2>
to call it from other places
cognominal: connectino lost 13:47
cognominal oops my bobby exploded
save the files please
I don't know if I can get them back 13:48
audreyt I've read the FAQ now 13:49
fascinating stuff
cognominal can you connect and paste bili.pod? 13:50
arf
audreyt another crash
cognominal crashed again
audreyt sigh
so much for technology
you connect to perlcabal.org? 13:51
cognominal ok
were you able to save bili.pod?
audreyt sure 13:53
cognominal if you are interested I can mail you the text version of the e4x faqs 13:54
it seems that big documents crashe gobby
audreyt I already saved that too
I think we have slightly different need for compilers than for generic xml processing 13:55
for example, in "1+2", both side of the "+" node are parsed with the same subparser 13:56
and so wouldn't quite make sense to index them by name
i.e.
the E4Xesque 13:57
node.*.[0]
feels rather verbose
I'd rather just say $node[0].
xinming audreyt perl6 is made very predictive <--- what does this mean pleae? 14:00
s/pleae/please/
14:01 bsb joined
audreyt xinming: it means that you can generally know what a snippet of perl 6 text means 14:01
without looking at the parts after it.
for example 14:02
1<2
or rather
$x<2
can only mean "dereferncing $x as a hash, passing a string beginning with 2 as param
so if you see
$x<2... 14:03
without seeing ...
a predictive grammar will not "backtrack"
a backtracking grammar, like packrat's, can backtrack
so
$x<2;
backtracks
and now < means comparison
not quoting anymore
xinming so, which means, if we see $x<2 we could know that it is not comparison ?
audreyt right! 14:04
and when you see
$x <2...
you always know it _is_ comparison
xinming $x < 2, then, It is comparison...
audreyt yes
this allows expresisons like
$x<2;3;4;5;6;longstringhey>
to be unambiguous to the human eye.
xinming thinks, perl 6 will scare many people who wish to switch python to perl 6. :-) 14:05
audreyt currently the pugs parser is backtracking
so we can correctly parse one way or another
depending on whether there is a closing >
we pay for this in time and space cost
packrat let us eliminate the time cost
xinming hmm, so, backtracking isn't needed, right?
audreyt but TimToady's point is that, by nonbacktracking, it also makes the language easier for humans. 14:06
see the longstringhey example above.
xinming for, $x<2, and $x < 2 example, if it is predictive, then, backtracking is not needed, right?
audreyt yes.
14:08 BooK joined
xinming $x<2;3;4;5;6;longstringhey> ... --> (in backtracking circumstance) it will become ?($x<2); 3; 4; 5; 6; longstringhey> ... :-) 14:08
I think I understand
audreyt er, wrong 14:09
in backtracking
it becomes
$x{'2;3;4;5;6;longstringhey'}
but if you drop the >
it becomes
$x < 2; 3; 4; 5; 6; longstringhey 14:10
so basically it means infinite lookahead
which is naively exponential time
which is why pugs parses slowly
but packrat reduce that to linear time
and linear (though large) space
but I agree with TimToady that requiring infinite lookahead may not be good for humans. 14:11
though it's very convenient
xinming audreyt: did your see, ?($x<2) in my example... ? here, ?($x<2) what I mean is comparison. :-)
audreyt oh ok
yes
so yeah, you do understand :)
xinming audreyt: hmm, backtracking is good for writing JAPH program. :-) 14:12
audreyt it is!
audreyt ponders the @array[{$_ < 3}] overhuffmanization for @array.grep:{$_ <3} 14:15
xinming audreyt: what will be used to bootstrap perl6 do you think?
audreyt xinming: perl 6
xinming ...
audreyt by definition :)
xinming I mean the first perl 6. :-)
pugs or pX ? 14:16
audreyt now, if you mean which implementation will bootstrap first...
I have no idea XD
probably a mixture of all three, or more.
xinming I'm still in confusion about why can't pugs. I mean the one you write to write a compiler... :-/
audreyt xinming: mostly because the part needed to write a compiler -- namely, structural unpacking, tree binding, etc, is not yet supported by pugs. 14:18
so to use pugs-today to write a compiler will be... if not as painful as writing it in perl5, certianly comparable.
PerlJam wonders if fglock thinks of what he's doing as "painful" :) 14:19
audreyt notes that the codegen and optimizers are more nontrivial 14:20
and yet must be done somehow
pmurias PerlJam: most of pX is written in DSL's
audreyt fglock wrote the same parsing engine in perl6 too
runnable by pugs
xinming audreyt: how much is it completed about fglock's work?
PerlJam pmurias: this is true. 14:21
xinming means about pX
audreyt xinming: well... it still has yet to pass 01-sanity
xinming ... 14:22
pmurias xinming: lrep and lrep-compiler could run some primitive perl6, but were wiped out by api changes 14:23
xinming now understands that the first perl 6(not-official) won't be out until next year....(maybe longer...) 14:24
since audreyt made pugs for 1 year... :-/ 14:25
audreyt well, it's not _all_ my doing :)
and perl6 today is far, far easier to implement
than one year ago.
(thanks primarily to the test suite)
and also for sanity in Synopses
or at least, consistency. 14:26
xinming found the sunlight through the darkness...
audreyt: so you mean, what they need to do currently is just write a compiler... and check it if it passed the test suite? 14:27
14:27 lisppaste3 joined
audreyt yes. 14:28
14:28 justatheory joined
xinming then, do you mean pX will implement perl 6? which the same is as pugs does. 14:30
but they(pugs and pX) still aren't perl 6. :-/
14:31 enantiodrome joined
xinming gives up for trying to understand why perl 6 is so hard to implement... It's far beyond his knowledge... 14:32
PerlJam xinming: I bet you that we have a perl6 before the end of this year
avar PerlJam: perl6 as in..? 14:33
PerlJam avar: as in *the* perl6. (not final, ready for production, but certianly alpha quality)
audreyt as in equivalent to Pugs 6.283.0
I really doubt we can get the entire static analysis part figured out.
PerlJam As in, does everything that the specs say it should
audreyt since the typesystem part inthe spec is all speculative 14:34
and the design space... is huge.
but as a dynamic language, sure :)
fglock is there a problem with the svn server? I'm getting "400 bad request"
merlyn as long as you have prototypes and macros together with / being both divide and regex, you can't do static analysis
audreyt merlyn: post-parsing analysis. 14:35
xinming PerlJam: I know what you mean, But I don't think so. :-)
audreyt also known as "optimizer"
and "typechecking"
and "inferencing"
merlyn right. presuming parsing includes the compile-time execution context
as I brought up two days ago. :)
PerlJam xinming: I will remain eternally optimistic ;-)
audreyt yeah
post-parsing analysis is certianly possible
because we have compilation units
and they can't affect each other's parsing
it may even be neccessary 14:36
for storage classes such as
my int @x; @x[3]
that must emit a different code than
my Int @x;
to support packed int arrays
xinming PerlJam: But I hope you are right. :-) as I almost can't wait to use perl 6. :-) 14:37
PerlJam: pugs now can do many things, But it is too slow sometimes... that's why I want the self-hosting perl 6. :-) 14:38
audreyt xinming: a major source of slowness is backtracking parser
another major source is old, reference-based mutable containers 14:39
another major source is using maps to emuulate hashes
xinming :-)
audreyt the first is now resolved by "rule" always being predictive 14:40
by default
and we'll switch to a optable-based parser
and remove "try" in parsec
the second is now resolved with Capture, first-class Lists, and death of references
the third can be solved with Judy. I hope.
xinming audreyt: do you believe, that perl 6 will scare many people who wish to learn the language... as their are too man differences compared perl 6 with many languages. :-) 14:42
audreyt xinming: perl5 did that already
PerlJam xinming: no more than perl5 scares people.
audreyt I don't think p6 will be different
PerlJam Though I think perl6 will scare more perl5 people than random newbies :)
xinming audreyt: yes, but perl 5 isn't that hard to learn, as there are not many "rules" as perl 6 does. eg, $obj. .doit() and your example above, $x <1 $x<1 :-) 14:45
and perl 5 is in relax mode by default... this is good for some newbies.... :-)
avar xinming: mostly it isn't 14:46
audreyt @{$moose}{3,4,5}
$x = //;
*$g->{CODE}
xinming avar: hmm, new people will always forget the $x<1 if they mean comparison. :-) 14:47
audreyt I can go on and on and on...
xinming audreyt: :-) <<My heart will go on>>
pmichaud <fglock> audreyt: can I declare a rule with parameters: rule balanced ( $start, $end ) { $start .*? $end }
<audreyt> pmichaud has the syntax
<audreyt> <balanced: 1, 2>
<audreyt> to call it from other places
actually, the syntax is <balanced(1,2)> for multiple parameters. 14:48
the syntax <balanced: 1, 2> is equivalent to <balanced('1, 2')> (and is still conjectural in A05)
audreyt mea culpa
pmichaud np, just wanted to keep someone from having to backtrack later :-) 14:49
audreyt (conjectural-in-A05 and nonexistent-in-S05 means probably it doesn't exist :))
in specspace, that is
pmichaud I asked TimToady about it yesterday and he said it was okay to leave it in and leave it as conjectural :-)
audreyt heh.
what's wrong with <balanced('1')>?
longer to type?
pmichaud it was one of the reasons he introduced the <<< ... >>> syntax
from a purely PGE perspective, <balanced: ...> is slightly easier to parse 14:50
ultimately PGE will have to work with Perl 6 to be able to parse parameter lists
14:51 FurnaceBoy joined
pmichaud I have thought about updating PGE to parse constant parameter lists, however 14:51
audreyt yeah, uniform syntax seems better... 14:52
but I'm fine with the : form as well
pmichaud so, <balanced(1,2)> and <balanced('1')> would be okay, but <balanced($foo[3])> isn't going to do much until there's a perl6 to help it along
audreyt it just feels like another special case :)
sure
pmichaud and I may end up needing <balanced(delim=>';')> anyway.
audreyt yeah. I thikn one autoquoter (=>) is one too many 14:53
pmurias goes out to read perlguts on a nice bench somewhere
audreyt and another autoquoter, meh :)
avar likes autoquote;) 14:55
my (eval => 5);
eh, fleh
theorbtwo likes that autoquoter. 14:56
audreyt likes :eval(5) more... but well :)
timtowtdi
theorbtwo I'll probably use :eval(5) when thinking of adverbs, and eval=>5 when thinking of pairs, even though they're the same thing. 14:58
xinming audreyt: tmtowtdi <<== I ever used timtowtdi, larry told me he always use "there's" rather than "there is" :-)
theorbtwo ...just like unless (...) and if (!...) are.
audreyt I think it may make sense to have it always mean adverb and pair
so we can rid of the f((x=>1)) hack
but then, there is too much p5 mental legacy 14:59
in named=>'arg'
so it wouldn't fly, sadly
pmichaud I also chose delim=>';' above because that's the parrot syntax
14:59 aufrank joined
pmichaud (for better or worse) 14:59
audreyt <balanced(:delim<;>)> 15:00
really reads much nicer to me :)
but well, yeah, legacy and all that.
pmichaud actually, in PGE I could just search for the closing paren and pass the whole thing directly to Parrot
er, PIR 15:01
whenever the hosting language != Perl 6
audreyt not sure it buys you must
as PIR ne nesting language
pmichaud: have you seen perlcabal.org/~autrijus/tmp/p6.html ?
pmichaud yes -- saw it in the backlog yesterday
very cool
merlyn for some of us, "PIR" is "Portland International Raceway", and it's hard to shake the link
15:05 macroron__ joined, mago joined
xinming could I have an account on perlcabal.org? 15:07
Or, It is internally use only. :-/ 15:08
theorbtwo xinming: cd docs; find -name feather
xinming theorbtwo: yes, I've in that dir. :-) but I still don't know if I have an account on perlcabal.org :-) 15:13
s/if I/if I can/ 15:16
15:18 reisio joined
xinming thinks he should ask Juerd. :-) 15:19
15:19 Khisanth joined
audreyt xinming: just mail to justatheory 15:19
I mean, Juerd
xinming audreyt: Ok. 15:21
aufrank is @statements>>.compile the same as @statements.each.compile?
(good morning!)
xinming aufrank: I don't think so. :-)
audreyt aufrank: it's @statements.map:{.compile} 15:22
but doesn't guarantee order
xinming for @statements -> $one { $one.compile };
aufrank ok
got it
xinming audreyt: does for @ary guarantee order?
wolverian yes. 15:23
audreyt yes.
>>.compile guarantee order-of-result but not order-of-evaluation
15:24 dvtoo_ joined
xinming audreyt: why not make it guarantee the eval order? 15:24
avar xinming: for sp33d
xinming audreyt: hmm, It's much more human-understandable IMO. :-)
avar: thanks.
avar xinming: I can't imagine myself writing something like @arr>>.lc (or something) and caring about the order it happens in 15:25
cognominal audreyt: in S02, the comment with user-selected bracket is incorrect? if I judge par the criteria (every opening user-select bracket must be close).
s/close/closed/
audreyt mrr? 15:26
cognominal mrr?
audreyt what do you mean?
cognominal what does it means?
audreyt For all quoting constructs that use user-selected brackets, multiple,
adjacent, identical opening brackets must always be matched by an
equal number of adjacent closing brackets.
this?
xinming avar: but how about this example?
cognominal ho, I missed the word adjacent
it should probably say that the example contains non adjacent brackets to better convey the idea 15:27
audreyt patches to p6l :) 15:28
cognominal oki
xinming my @arry = ($a_object, $b_object, $c_object, $d_object); and we declared a multi to handle these 4 objects, which name is temporary mymeth, @array.mymeth should automatically handle these four type, but these 4 types need the right sequence... :-)
audreyt xinming: @array.mymeth doesn't do that at all 15:29
xinming avar: but maybe, This example is abit not correct. If it is in order, we then know to push them in order...
audreyt what you described is
mymeth(*@array);
avar xinming: I have no doubts that my example doesn't compile, execute etc.;)
xinming audreyt: I mean @array>>.mythem... :-)
audreyt but that just means
($a.mymeth, $b.mymeth, $c.mymeth, $d.mymeth) 15:30
and has nothing to do with multis
if you mean
f(*(@array>>.mymeth));
only the result order is important
and not the order of evaluation
xinming audreyt: yes, they need order to be called... I mean, $a.mymeth first, and etc... etc...
audreyt why?
you can call $b.mymeth first. 15:31
as long as it still occurs in the correct slot
in the result list
that is, if @array contains (1,2,3,4)
and you do
15:31 axarob joined
audreyt @array >>.say; 15:31
perl6 doesn't guarantee the order
you may see
2
1
3
xinming if $b.mymeth failed, then, $a.mymeth will fails...
audreyt 4
on your screen
xinming: oh you mean that... well in that case, the multi will still guarantee that 15:32
xinming audreyt: but people most want the ordered say... :-)
audreyt well, in which case they use
say for @array;
or something like that.
it's not like it's hard :) 15:33
@array.map:{.say}
map(&say, @array)
aufrank audreyt: now is @array.each.say relevant? or does this form not exist?
xinming .... 15:34
audreyt: thanks... I know... why that doesn't guarantee order.. :-) 15:35
audreyt aufrank: I don't know what it means...
15:35 davidfetter joined
davidfetter hello 15:35
aufrank hello davidfetter
audreyt aufrank: @array.each may mean =@array, that, iterating over array
aufrank: but that will only print one number
xinming perl 6 rocks... 15:36
davidfetter i was talking w/flavio & he said to ask here
i'd like to see about a prototype pl/Perl6
merlyn probably best to embed parrot
davidfetter interesting
whom would i talk w/about that
audreyt davidfetter: perl6-internals, also jhorwitz (Jeff Jorwitz) and leo (Leopold Totsch) in particular 15:37
fglock audreyt: is it possible to embed Pugs?
audreyt davidfetter: if you want to embed pugs in C-land, you can do that also; in that case, talk to clkao or me :)
fglock: yes, libHSPugs.a is a shared lib 15:38
and you can call "pugs_Eval" and "pugs_Apply"
see src/perl5/pugsembed.h
currently you need to link in p5 too
because the Apply returns SV 15:39
but it doesn't have to
if someone has a use for it, we can easily expand the API :)
15:40 axarob left
davidfetter ok 15:40
davidfetter takes a look at mod_parrot... 15:41
audreyt davidfetter: when you succeed in embedding parrot,
you can link in pugs and use the mod_pugs interface
(because pugs is a compreg)
I mean, registered compiler in parrot
or use parrot's trunk 15:42
davidfetter hm. interesting. the C here is way, way over my head. i'm just a db weenie
audreyt there's a languages/perl6/perl6.pbc
davidfetter trunk? i thought elephant's had trunks
15:42 KingDillyDilly joined
audreyt which you can load and use the parrot-native, currently-minimal but udner-active-development, compiler 15:42
KingDillyDilly What is it about 9:15 that makes people join this channel then? 15:43
audreyt davidfetter: trunk means svn.perl.org/parrot/trunk/
davidfetter: you can use "svn co svn.perl.org/parrot/trunk/" to get the latest parrot code
davidfetter it's 12:43 here 15:44
maybe it's that 9:15 influence
xinming 23:48 here...
KingDillyDilly 11:44 here, but I'm talking about the times at colabti.de/irclogger/irclogger_log/...-04-22,Sat
davidfetter sees whether he has svn on his mac... 15:45
KingDillyDilly Thought those times might be clien side times.
Hmmm... s/ht(.*)clien/h$1client/ 15:47
15:49 reisio left, alec joined
KingDillyDilly I was wondering if it's copycating, or if they're all on a network, or some client they all use that does that. 15:50
15:52 Limbic_Region joined
aufrank audreyt: totally off topic, feel free to ignore: do you know how to prepare a breakfast food from .tw called dan bing? 15:56
audreyt yes. 15:57
aufrank any chance you'd mail me a recipe? my girlfriend misses that in particular and I'd like to make it for her if I could
Limbic_Region audreyt - when was the last time you built on Win32? 15:59
Limbic_Region has had a problem for about a week now but hasn't bothered to try nmake realclean before building
Limbic_Region is trying that now
audreyt Limbic_Region: sorry, wasn't aware of that. 16:01
I'll fix tomorrow... have to sleep soon
Limbic_Region not your fault
I will confirm that it is still broke after a realclean make
and nopaste the error
so you can backlog
sleep well
aufrank audreyt: I figured you must be fading, as it seems you've been here since I left last night :\ 16:02
get to bed!
davidfetter g'night, aufrank
aufrank no no, I'm just getting here! 16:03
KingDillyDilly aaufrank: there's a dan bing recipe at mmm-yoso.typepad.com/mmmyoso/cooking/index.html 16:04
16:07 mako132_ joined 16:10 xerox joined 16:20 xinming joined
pmurias davidfetter: you want to embed parrot from c or perl5? 16:21
merlyn C 16:22
inside postgresql
davidfetter using the SPI stuff
merlyn I told him to look at mod_parrot as a potential example
davidfetter digs up a reference...
pmurias i'll look at how mod_parrot does data exchange 16:23
davidfetter www.postgresql.org/docs/8.1/static/spi.html <-- SPI 16:24
www.postgresql.org/docs/8.1/static/plperl.html <-- current PL/Perl usage
pmurias davidfetter: you can also look at misc/pX/Inline-Parrot in the pugs repo if you are realy desperate (it's pretty minimal at the moment) 16:27
davidfetter is just in the idea stage of this project 16:28
audreyt journal updated... good night for real :)
&
aufrank gnight audreyt
KingDillyDilly Get that recipe, aufrank, or am I on ignore? 16:29
Just like the good ol' days. I'd start a Perl6_Improved column if I knew anything about it. 16:30
aufrank sorry KingDillyDilly, missed it 16:31
found it now
thanks for that :)
KingDillyDilly :) Long page, but I didn't use the paste bin because there are pictures that might help. 16:32
Anyone else need a recipe? That's about all I can help with here. 16:33
16:33 dvtoo joined
Limbic_Region audreyt - for backlog, still fails on realclean build 16:34
perlbot nopaste
perlbot Paste your code here and #<channel> will be able to view it: sial.org/pbot/<channel>
pasteling "Limbic_Region" at 24.35.57.240 pasted "Win32 build failure (for about the last week or so)" (29 lines, 1.5K) at sial.org/pbot/16851
xinming Limbic_Region: She is in trance... :-P 16:35
Limbic_Region heh
xinming C:\Perl\bin\perl.exe here, we should use C:\\Perl\\bin\\perl.exe 16:36
otherwise, It can't found perl.exe
or you can use c:/perl/bin/perl.exe
this is nothing to say, except Windows sucks... :-)
hmm, sorry, I think I misunderstand that... :-/ 16:37
16:38 KingDiamond joined
pmurias xinming: you use windows? 16:44
xinming linux... 16:45
pmurias :)
KingDillyDilly There's nothing wrong with Windows. In fact, a recent study showed Windows servers are safer than Unix servers. 16:46
xinming I ever used windows, but I like how to do things in Linux, eg: with compiler, and you can upgrade the whole system without restart... 16:47
16:47 mako132_ joined
xinming KingDillyDilly: I don't think there are the safe os, and this depends on something who admin the system. 16:48
KingDillyDilly: But what I don't like windows is that, for the fresh install, you have to restart at least 4 times... :-)
pmurias xinming: i hate the GUI 16:49
xinming It's a pain if you are helping people installing windows, and there are many a day... :-)
pmurias: In fact, there is nothing wrong with GUI. :-) I prefer GUI + CLI.
pmichaud: eg, you wish to do some quote in irc, or you wish paste something to pastebin, In CLI, IMO, It's a pain. :-) 16:50
cognominal you must have choice and avalaibility of free software development tools
pmurias xinming: it's pmurias :) 16:51
cognominal unix shine at that, plus linux proposes everything nicely packaged
FurnaceBoy "<KingDillyDilly>There's nothing wrong with Windows. In fact, a recent study showed Windows servers are safer than Unix servers.
" -- do you believe everything you read?
xinming Why I like Gnu/Linux is all because it is "free", I mean, I can know manything from Linux, and In Windows, I have to just click the mouse... and nothing more. 16:52
KingDillyDilly Can't find the reference at the moment, but I recall it being an independent study. It's on MS's website somewhere.
merlyn it's "linux", not "gnu/linux" please
FurnaceBoy it is, is it?
merlyn RMS be damned
xinming FurnaceBoy: In fact, I believe that both Linux and Windows are safe... but it depends on the admin. But Windows restarts too much... 16:53
merlyn: hmm, do you think a kernel can do all?
FurnaceBoy there is no upside to windows. it's all cost, and all lockin. by design. that's why it's going away...
cognominal " independent study." not congruent to "It's on MS's website somewhere."
merlyn linus called the whole thing linux
it's his baby
davidfetter rms lost that fight before he started it
xinming merlyn: I'd like to say gnu/linux instead of linux. :-)
FurnaceBoy yeah, you'd think that was too obvious to need explaining, cognominal ...
merlyn linus is a much nicer guy tham RMS
so RMS be damned on that one
davidfetter that, or say X/BSD/GNU/vim/linux
merlyn I know, I've had dinner with both of them. :) 16:54
davidfetter i'm sure i've left out a few
same here
pmurias KingDillyDilly: it's not independent if it is on ms
FurnaceBoy plus, it's not true
cognominal FurnaceBoy: in IRC, better never leave anything imploed
FurnaceBoy indeed ;-)
pmurias things on gnu.org aren't indepenent too
16:54 amnesiac joined
davidfetter i won't repeat the rms dining experience. it's like eating with a 4-year-old with CP. enough to put you off your feed :P 16:54
xinming merlyn: well, if you call the whole system we use Linux, the problem raised...
merlyn: what the role of gnu is?
merlyn I call the entire distro "linux", yes
KingDillyDilly I'm sure it's elsewhere too. I'll look.
merlyn it's built with a bunch of gnu tools 16:55
but it's still all called linux
that's what linus calls it
and it's his baby
he can call it what he wants
davidfetter :)
cognominal linux is just sane huffmanization of gnu'linux, rms can nothing agains that.
FurnaceBoy KDD, we don't care. such assertions are errant crap, made by the ignorant or gullible. take it elsewhere.
pmurias and the gnu supply the ideology for the masses
davidfetter wonders what RMS has done code-wise this decade
merlyn it was only GNU/linux when RMS realized he didn't have any more battles to fight 16:56
cognominal davidfetter: he is very active on emacs I was said.
davidfetter meh
merlyn so he tried to ride the coattails of the linux project
that's crap on him
FurnaceBoy so, I guess there are few GPL licensors here...
KingDillyDilly When I was looking into which distro to install (I chose SUSE, but I don't have a writable CDROM, so didn't install it), I saw so many people bashing various distros. Saying "Linux is..." is meaningless.
merlyn he's bad for trying to do that
FurnaceBoy I'm sure we can agree to be grateful for the GPL, at least?? 16:57
xinming merlyn: hmm, so, what do we call windows? the kernel? or the whole operating system?
merlyn Yes - he gets HUGE CREDIT for the GNU project. but dammit, the name of the thing that Linus runs on his machien is "Linux", not "GNU/Linux"
I don't call windows anything
except swear words
FurnaceBoy smiles
cognominal well, it was tough for him to see that linux relaized its dream of a free complete linux (kernel and all) at a time the bsds has dubious legal status.
pmurias merlyn++
cognominal but rms carried his dream pretty far except for the kernel
merlyn right RMS is just sad about Herd 16:58
FurnaceBoy sure, he is, but more than people imagine, methinks
cognominal Hurd?
merlyn and tries to claim that Linux is really GNU/Linux
yes hurd
FurnaceBoy that remark about GNU/Linux has been retailed further than it was ever intended, I suspect
merlyn sorry for spelling it like english. :)
pmurias merlyn: is it true that rms dosn't like perl?
davidfetter heard hurd herds hirds
merlyn I don't think he's much of a Perl user, no.
he uses emacs lisp and that other thing they came up with 16:59
davidfetter heh
merlyn gnuscheme?
KingDillyDilly Not security related, but: www.computerworld.com/softwaretopic...37,00.html ... still looking
merlyn what was it called?
davidfetter something like that
cognominal esr does not like Perl and tells it loudly but he is wrong on so many things...
merlyn esr is a totally another story
FurnaceBoy yup cognominal
merlyn I've also had many beers with him too. :) 17:00
ESR gets the "practical" side better than RMS
FurnaceBoy except I like his hacker logo. best thing he ever did imho ;-)
davidfetter <aol>me, too!</>
merlyn but ESR is difficult to take in more than small doses
davidfetter he gets other things wronger tho
FurnaceBoy famously
pmurias the Art of Programming was a good book
davidfetter s/f/inf/
pmurias of UNIX Programming
FurnaceBoy thx
saved me the trouble 17:01
davidfetter always wonders how much of an ESR thing any ESR-claimed thing really is.
take fetchmail. please.
cognominal btw: geekz.co.uk/lovesraymond/archive/vmwhere
xinming merlyn: RMS is a coding guy, and Linus is good at politics, whether you believe or not... Anything RMS do, is want the design of the software best... But Linus doesn't... though, I have to say, Linus give us a good product. But one thing you have to accept, most people don't know anything about gnu while they using Gnu/Linux... 17:02
well, I'll stop. It's too off topic....
FurnaceBoy heh, well, nor while using OS X, which is built by gcc... 17:03
etc
I don't think rms need be concerned about his legacy being forgotten, somehow ;-)
Linux *is* GPL, that's a powerful endorsement of your primary creation.... 17:04
so, in the pantheon of geeks, lwall gives us Perl, rms gives us GPL, and esr gives us ... fetchmail
xinming rms also gives us Emacs. :-)
FurnaceBoy and gcc 1.x
etc, etc, etc, etc, etc
17:05 dvtoo_ joined
cognominal well, I am trapped in emacs, I want to escape :) 17:05
FurnaceBoy I'd stand him a beer any time :)
FurnaceBoy whispers "vi!" "vi!"
xinming But IMO, what RMS gives us most is that the freedom in software area...
cognominal vim is cleaner but does not have shell buffers
FurnaceBoy yes ... nobody else stood up to the plate, xinming ... so GPL will be his most enduring legacy perhaps 17:06
that's one heck of a vision
xinming uses vim for editing config file, and emacs for editing program...
hmm, s/program/source code/ 17:07
KingDillyDilly download.microsoft.com/download/1/e...vation.pdf
Based upon both counts/lifecycles of bugs and the absence/presence of qualitative drivers of security, it appears that Microsoft may have an edge in many environments.
Put another way, looking at the software security factors that each vendor has the ability to directly affect ā€“ software security quality and security response ā€“ the data shows that a web server workload built using Windows Server 2003 has fewer security vulnerabilities requiring customer mitigation or patching than a similar workload built on Red Hat Enterprise Linux.
From a company called SecurityInnovation.
FurnaceBoy print it out and wipe your ass with it
xinming lol... 17:08
FurnaceBoy you clearly don't know what you're talking about
you're the perfect audience for such 'studies'
xinming me? 17:09
FurnaceBoy no
KingDillyDilly So Security Innovation is corrupt?
FurnaceBoy very likely. but principally, WRONG.
jeez.
go RUN a web server and find out for yourself.
17:10 justatheory joined
pmurias we've got windows in our school library 17:10
KingDillyDilly I don't think they mentioned web servers as opposed to other servers.
FurnaceBoy alright:
Run ANY kind of server.
go get some experience before quoting 'studies'
and you'll see that you're being led up the garden path -- or your checkbook is, in particular. 17:11
KingDillyDilly A study is a better indicator than one persons experience.
FurnaceBoy ........
it ain't ONE person's experience.
PLONK.
KingDillyDilly Ok, more than one could count as a study. I'll compare SecurityInnovation's methodology with yours when yours is complete. 17:12
FurnaceBoy windows is crap -- if you'd ever tried anything else, this would be self evident.
I don't know why I bother with this conversation.
xinming FurnaceBoy: as game box... windows is perfect... :-) 17:13
pmurias got a friend who prefers linux for gaming
dispite having a dual boot 17:14
KingDillyDilly Maybe there are more free games. 17:15
xinming pmurias: for normal people... windows is better, this is why windows rules.... Warcraft III is really a good game... :-)
pmurias: wesnoth is good. :-)
pmurias he just play Enemy Territory
i like wesnoth
xinming wesnoth is too hard for me... my pawns are always experience for enemy... 17:16
Enemy Territory in Gentoo... 17:17
gentoo++
pmurias gentoo++
KingDillyDilly Gentoo is one of the distros I heard was difficult.
SUSE, Mandriva, and those African named ones are easy. 17:18
xinming KingDillyDilly: well, if you are tired of upgrade system, try community-based distributions... :-) 17:19
pmurias the installation requires CLI experience, otherwise nothing too dificult for a 16 old
what i can't get to work with it is hardware accleration 17:20
wolverian I can recommend Ubuntu, myself.
xinming KingDillyDilly: by the way ubuntu is good too. It's debian based.
pmurias i have bad experience with it 17:21
KingDillyDilly I think that's the one that strives to have as much language support as possible. I don't like that priority. And it's new.
wolverian well, I can say that the upcoming release is looking very good. :) maybe try it again then. it's always fun.
17:21 davidfetter joined
xinming pmurias: if you know debian, ubuntoo isn't that hard as you think. 17:21
wolverian KingDillyDilly, do note that language support doesn't affect the system itself, as specific languages are separate language-support-* packages. 17:22
xinming though, /me doesn't try ubuntoo,
pmurias it wasn't hard
what pissed me off, it didn't include compilers in the default install
wolverian install build-essential :)
xinming I used gentoo for maybe 40 days... It's good except lack some software, the major ones are there, but not as much as debian... 17:23
KingDillyDilly Ubuntoo was one of the distros recommended to me by www.zegeniestudios.net/ldc/
xinming BTW, why I switch too gentoo is all because I prefer the debian testing instead of sid. :-)
pmurias KingDillyDilly: what distro do you have now?
KingDillyDilly None. I don't have a writable CDROM, so my choice was too limited. Mainly to Slackware, which may be the most difficult distro, so I just didn't bother. 17:24
xinming and in testing, Ghc is always 6.2, and I have to install package from sid.. that's a pain, so I switch to gentoo. compile the system myself, and use newest ghc. :-)
pmurias xinming:have you tried changing the compiler
xinming pmichaud: yes, a fully optmized os here. :-) 17:25
wolverian xinming, ubuntu dapper has ghc 6.5 as a binary package. compiling takes time. :)
pmurias xinming: i'm pmurias :)
wolverian KingDillyDilly, Ubuntu ships CDs for free each release.
cognominal mandriva has ghc and parrot too, packaged by respectively by rgs and misc 17:26
xinming wolverian: and another reason I don't like debian is because it's community... in #debian. I sometimes see people being kicked out by hammer. :-)
wolverian xinming, I don't deal with debian myself, much, besides feather.
xinming wolverian: how does the company make money?
wolverian xinming, support.
(to companies) 17:27
KingDillyDilly I wanted a free version because I didn't really need Linux. I got a new external hard drive that I wanted to dual boot with my internal one. That's too hard, so I lowered my requirements a couple of times, getting more weary of the search with each iteration, and I finally gave up.
xinming wolverian: and I have to say, If I need manage many servers, I'd like choose debian.
wolverian xinming, aye, me too. 17:28
pmurias xinming: if you change your compiler do you have to recompile your system
xinming wolverian: how much a year?
wolverian xinming, sorry, how much what?
xinming wolverian: I mean how much will ubuntoo ask for tech support?
wolverian xinming, www.ubuntu.com/support/supportoptio...aidsupport if you really want to pay :) 17:29
xinming pmurias: Yes, we have, but, if you just switch 3.4.5 to 3.4.6, I don't think recompile is needed
KingDillyDilly eats
17:29 KingDillyDilly left
xinming pmurias: and If you like to try the compiler which is not in testing, I'd suggest you leave it out. I ever tried gcc-4.1.0 and there are many packages can't pass the compile. 17:30
wolverian xinming, note that ubuntu provides free community support and several canonical employees support the packages in 'main' without cost to the community. 17:31
xinming, www.ubuntu.com/support/supportoptio...reesupport
xinming wolverian: If that's true, It's really a bit hard to make money IMO. :-/
wolverian xinming, apparently it works for them. :) 17:32
pmurias two languahes i wanted to try didn't want to compile with my archaic gcc 3.3.5
s/languahes/languages
17:33 mako132_ joined
xinming pmurias: you can use gcc-config to switch the compiler, and then, after compilation, switch the compiler back. :-) 17:33
pmurias: that's what I do, I think there is another way to do this. :-)
pmurias: by the way, If you got some problems, I'm not good at gentoo, so try #gentoo... :-) 17:35
pmurias thanks for the tip 17:36
17:43 larsen joined 17:48 mako132_ joined 18:13 BooK joined 18:16 mako132_ joined 18:36 davidfetter joined 18:41 larsen joined 18:50 mago joined
svnbot6 r10055 | pmurias++ | Inline-Parrot: 18:54
r10055 | pmurias++ | * moved Inline-Parrot to Common
r10055 | pmurias++ | * some commit encouragment in README
r10055 | pmurias++ | * some initial contact with parrot established
pmurias how should the pmc the perl5 code resives be manipulated? 19:06
what would be better keeping the list of macros in Inline-Parrot or parsing vtable.h everytime?
any wishes for the PMC manipulation api? 19:08
19:21 mako132_ joined
TimToady * audreyt ponders the @array[{$_ < 3}] overhuffmanization for 19:36
@array.grep:{$_ <3}
19:36 pdcawley joined
TimToady audreyt: doesn't work for two reasons 19:37
.[] allows optimizer to assume integer slices.
and {$_ < 3} would probably select indices from the current dimension 19:38
or we couldn't generalize to multidims.
I think if we install a generalized index selector, then it should go in via .{} or .() instead. 19:39
wolverian @array{ $_ < 3 }; # hey, it's inside { }s.. 19:40
TimToady since .{} doesn't give any special instructions to the optimizer
@array{ {$_ < 3} }; it would have to be
or @array( {$_ < 3} ) maybe 19:41
in any event bare .[] probably shouldn't support that kind of generality. Maybe overload .?[] or .*[] for that, if we don't swipe it for slice forcing. 19:43
but it's probably best to prototype with some kind of .foo( {$_ < 3} ) first. 19:44
later we can talk about sugar if it's deemed necessary.
wolverian .grep:{ <3 } would be nice.. :)
19:44 dvtoo joined
TimToady no, it'd be a syntax error. 19:45
wolverian dang, no automatic currying.
TimToady sometimes syntax errors are the nicest thing you can do.
cognominal .grep:{ .<3 } ?
TimToady that's no better. 19:46
how bout jsut .grep: ^3, ...
first arg to grep is just a smart match 19:47
and ^3 is 0..^3
(differs for negative, I realize)
wolverian .grep(^3) ?
TimToady just a Range object. 19:48
wolverian yeah, just unclear on what .grep: ^3 means
TimToady : is Haskell's $ there, more or less
stands in for a left paren with no corresponding right paren.
wolverian ah. 19:49
TimToady .grep: ^3... is the same as .grep(^3...
)
wolverian I hadn't realised that's generalised
nice.
theorbtwo Wouldn't @arr.grep(...3) grep against the values, not the indeces? ...or was that what was meant? 19:53
wolverian that's equivalent to .grep:{ $_ < 3 }, yes 19:54
which is what audrey was talking about
TimToady yes, grep is on values
theorbtwo Right.
TimToady by the way, I'm thinking of destroying ... in favor of something more general. 19:55
merlyn .... ? :)
TimToady that is, ... meaning ..Inf
theorbtwo It seems like overhufmanization.
TimToady it's problematic in several ways.
first, it parses as an infix that is missing its right argument.
rather than as a postfix. 19:56
theorbtwo Why?
TimToady so you can put a space before it like .. can have a space before it.
theorbtwo Surely it's longest token, and ... is longer then ..?
TimToady we never allow postfix with a space in front nowadays.
theorbtwo Ah. 19:57
TimToady another problem is the visual clash with the yada operator.
19:57 macroron joined
TimToady a third problem turned up when I decided that maybe we should have xxx to go along with xx. 19:57
theorbtwo Not really any more then !3 and .3 clash...
TimToady yes it's a minor problem, at least to the computer. 19:58
theorbtwo 3xxx being 3 xx Inf ?
Juerd theorbtwo: than
theorbtwo: if/then, more than.
TimToady except you can't write $fooxxx 3
theorbtwo D'oh.
Well, yes, but you can't write $foox 3 either...
TimToady and 3xxx will get you funny looks even if the computer groks it
but that's just another reason it has to be a weird infix rather than a postfix. 19:59
or we force people to write .xxx
theorbtwo Now that'd be odd.
TimToady so I think what we want here is some generalization that inserts Inf on the right side.
theorbtwo 3xxx does look odd, so don't write it.
TimToady and I think it's the fact that * with no argument means "Whatever".
3 xx * 0..* take Whatever to mean positive Infinity (and Beyond!) 20:00
Juerd Doesn't that clash with prefix *?
TimToady *..* would then possibly mean -Inf..+Inf. 20:01
is no term starting with ..
theorbtwo It still seems like overhufmanization.
Juerd 3 .. *$foo
aufrank 0 .. ^*
TimToady is the same operator that means Any in [*;0..5;*]
aufrank: if you want to exclude Inf, sure.
aufrank =P 20:02
TimToady except that ^ has to be contiguous with ..
or you've just said 0 .. 0..^Inf
wolverian TimToady, does 0..Any equal 0..Inf semantically, then?
Juerd Are ranges really important enough to have a lot of complexity surround them?
aufrank good catch, I hadn't thought through that part of it
Juerd Inclusive, exclusive, inclusive/exclusive, exclusive/inclusive, infinity written as something other than "Inf", a special ^ operator, ... 20:03
Really, I think I much prefer Perl 5's simple ..
TimToady I think this is a simplfication over ...
Juerd Yes, and I still think ... is silly.
TimToady fine, it's dead
aufrank basketball perl and haskell are so much more interesting than this paper I'm supposed to be concentrating on
Juerd :)
wolverian Juerd++ # convincing argumentation 20:04
theorbtwo Indeed.
Juerd I'm not sure * is great, though. Have to think about it.
xerox How's pugs, people? (-:
Juerd xerox: Cute and sweet.
aufrank hey xerox
TimToady
.oO(baskerlell)
xerox I have a creepy proposal for you puggers.
TimToady people are so used to * meaning Whatever in globbing. 20:05
aufrank this should be good =)
TimToady copy us, xerox
Juerd TimToady: I'm used to * playing three other roles in Perl 6 already.
TimToady this is a role that * is already being used for.
xerox Seems like Haskell.org is going to partecipate to the Google Summer of Code as mentoring organization this year!! Would pugs offer chances to publish some Haskell project? What do you think?
aufrank xerox: audreyt was thinking of submitting pugs as a mentoring organization 20:06
Juerd Splat (is it still called that?), multiply, slurpy
TimToady: But in the other use, it's encosed in brackets
theorbtwo I thought splat and slurpy were the same thing.
aufrank and they're actually capture interpolation now 20:07
Juerd theorbtwo: Different sides, different features. They are related, though.
TimToady generalize that to "behavior selected by the associated operator"
Juerd TimToady: But there's already prefix *
xerox We're going to get some wiki to put the proposal on, the discussion is going on on [email@hidden.address] mailinglist. I think it would be fun :-)
TimToady argumentless * is just a Capture of the Whatever idea.
Juerd And after .., a term is expected
TimToady indeed.
Juerd TimToady: So, * is Whatever, only if no other term follows? 20:08
aufrank xerox: I reckon audreyt will backlog this when she's back among the waking
TimToady that's how it already works in subscript slices
Juerd I see
xerox aufrank: hope so.
theorbtwo I thought we were moving to backtracklessness?
Juerd That could work.
theorbtwo: One can prevent backtracking by looking ahead instead :) 20:09
theorbtwo I suppose.
TimToady It is backtrackless if you ignore whitespace.
Juerd TimToady: I don't see how Whatever means Inf, though.
TimToady 0..Whatever means Inf
theorbtwo Because the .. operator treats it as +Inf on the right side, or -Inf on the left. 20:10
Juerd It's neither 0..Everything nor 0..AnythingAtAll
theorbtwo Is Inf case-sensitive, BTW?
TimToady yes
Juerd It's 0..SomethingVerySpecific, namely (+)Inf
avar inf is the native machine representation of infinity>;)
TimToady No, it's really 0..ArbitrarilyLarge
aufrank well said Juerd
TimToady but we can translate that to +Inf for practical purposes. 20:11
Juerd TimToady: Well, then this boils down to a very different perception of infinity.
TimToady Computers can't understand infinity any better than we do.
xerox There are perceptions, and there are formalizations.
Juerd I don't think the concept of infinity is close to the concept of anything arbitrary. 20:12
TimToady on the right side of .. it is.
Juerd I think 9.5e12 is already arbitrarily large.
:)
xerox Maybe it is close to the thought that the concept of infinity isn't close to the concept of anything arbitrary ;-) Goedel++
TimToady Okay, how about ArbitrarilyLargeEnough instead? :) 20:13
avar 0 .. OmgHuge
TimToady Maybe define it as the first uninteresting number...
oh wait...
Juerd TimToady: Do you have other meanings for * in mind yet? 20:14
TimToady "foo" xx *
my ($a, $b, $c) = 1 xx *;
Juerd TimToady: I meant, other, as in: not Inf.
theorbtwo Juerd: On the right side of $_ ~~ $b..$a, the question is "is $_ bigger then $b", and the salient point of Inf is that it's bigger then anything else.
TimToady $x[*;0..5;*]
there Whatever means whatever the domain of the key type 20:15
%x{*;'a'..'z';*}
see S09
Juerd One is a globlike match-all, one is infinity, any others?
TimToady rand * :)
theorbtwo TimToady: Which returns any random number in the range of floats? 20:16
20:16 SamB joined
TimToady for * {...} 20:16
for Whatever {...}
Juerd theorbtwo: Or Inf. If * can mean Inf, it should certainly include it when it means Whatever :)
TimToady could be the new =<> if we go with Audrey's new idea. 20:17
Juerd .* # .pick
(Nice for golfers :P)
I understand the idea, but doubt it's worth having for the same reason I didn't like ... 20:18
TimToady /foo/ ff *
Juerd What's ff?
aufrank my Dog $fido .= new; $fido.* # unpredictable mutt
TimToady flipflop
in this case it means "false"
Juerd This may be a bit too much context sensitivity. 20:19
A term that changes meaning depending on the operator it's an operand of
TimToady It doesn't--it always means Whatever. :) 20:20
but that's sophistry...
theorbtwo Juerd: It just returns an object of type Whatever. The thing it's passed can do whatever it wants with it.
Juerd Of which Whatever cannot, and Inf, can be represented in a different way.
TimToady you mean like @foo changes meaning under + vs say
theorbtwo It does, though, seem that * buys us nothing new. 20:21
Juerd theorbtwo: That does not change what I said, though. It still means different things in different contexts, regardless of implementation.
theorbtwo It's a whole two keypresses longer then Inf.
Er, shorter then.
Juerd TimToady: Yes, but this goes far beyond normal Perl contexts
theorbtwo: than
TimToady I don't think so.
theorbtwo slaps himself on the head again.
What is * when you aren't mindful of it? 20:22
Juerd TimToady: *'s (semantic) meaning doesn't depend on void/list/item context, or type context.
theorbtwo What does +(*) do, or ~(*), or ?(*).
aufrank can we use ^* as a formal parameter in a Sig? 20:23
sorry, $^*
theorbtwo That seems like a really long way to say Any, aufrank.
IIRC, we already have Any as a type.
TimToady to2: I'd expect it to do much the same as +(Any), which is to say, 20:24
probably throw an exception.
Juerd I can see why it's nice to have * generalized beyond .[]
TimToady which certainly falls under the rubric of "Whatever
"
Juerd But my style rule list will probably contain "Do not use * outside of subscripts"
I find *, when it means Inf, unnecessary obfuscation. 20:25
TimToady In general the * prefix just means "splat something in here that is not directly specified"
Juerd I do like the Whatever-ness.
TimToady I don't think anyone can look at 0..* and not grok it. 20:26
Juerd There may be very practical uses for it. Just not for a number, I think.
TimToady: My mind still translates that to 0.+
TimToady s/anyone/anyone not seriously damaged by earlier exposure to computer culture. :)/ 20:27
pmurias 0..* looks like blow up operator to me
Juerd pmurias: It's not as bad as *..*
Which fortunately has no practical uses :) 20:28
TimToady Make me one with *..*
aufrank we need merlyn to name that one
Juerd Or, possibly, *..* means none()
theorbtwo Blink?
Why none()?
avar The-man-who-witnessed-goatse-operator *ducks*
pmurias 0..Inf looks better, and is 2 char's more
Juerd theorbtwo: any(*..*) == none(undef) # :) 20:29
pmurias: Agreed (if that wasn't obvious yet)
theorbtwo I should think it'd mean -Inf..Inf, pretty obviously.
Of course, I can't think of where you'd use that...
avar But I like 0 .. Inf better.
TimToady In a selector when you're too lazy to say Num.
aufrank I like * in ranges for a..*
theorbtwo Trying to iterate over it just gives you -Inf a lot, and if you want to match anything, ~~ing with 1 is simpiler.
aufrank keep going to the end of the current character class
TimToady that's another reason for it. 'a'..* 20:30
aufrank yeah, that's the ticket
TimToady the endpoint is *not* Inf.
Juerd Hmmm
TimToady It's...its...er...
aufrank right, that's a good Whatever endpoint
TimToady Whatever.
aufrank "I just want it all" 20:31
Juerd It's a nice precedent too.
Now we can re-use every other prefix operator as a term too :)
aufrank dibs on :
I called it
TimToady Sorry, I already called the colon.
aufrank =P 20:32
we could have a nice short hand for indifference in the channel
Juerd Maybe a lone . could mean .self, so that it becomes an alias for $_
aufrank says * 20:33
TimToady Whatever...
aufrank no, that is Whatever..*
TimToady right.
aufrank :)
TimToady "Whatever" xx *
aufrank I went through that stage around the age of 14 or so 20:34
Juerd * xx 4 # (*, *, *, *)?
aufrank '*' xx 4 # <* * * *>
pmurias * xx *
Juerd TimToady: Any news on XX yet?
TimToady It googles for Whatever and starts replicated the I-feel-lucky page 20:35
s/ted/ting/
FurnaceBoy googles for Whatever
TimToady was just wondering about XXishness
aufrank what are the ideas for XX ?
TimToady not to have it. 20:36
:)
Juerd aufrank: Evaluate left side n times instead of once.
TimToady I think we can just get away with recognizing a closure on the left to mean that.
avar so basically EXPR for 0 .. $n ?
TimToady { say "Whatever" } x * 20:37
Juerd aufrank: my $password = { any("a" .. "z").pick } X 8;
aufrank int(6 * rand) XX 3 # roll for D&D ability scores?
Juerd aufrank: Yes, though I think I wanted a closure on the LHS
theorbtwo TimToady: So how do you write a list of a repeated subs?
Juerd Since we no longer have map EXPR, LIST either.
TimToady and you want that because... 20:38
aufrank Juerd: I don't know what you mean with the connection to map
what did we lose and why does this fix it?
TimToady Juerd, actually, we do have map EXPR, LIST now. That's *all* we have.
map {...}, LIST is just a selector in the first arg.
Juerd TimToady: Sure, but it doesn't do much if EXPR isn't Code, right?
TimToady "selector" 20:39
Juerd aufrank: There is no connection, except for wanting {} on the LHS instead of a bare expression.
aufrank oh, ok
TimToady about an hour ago we just through talking about grep(0..3, @nums)
Juerd TimToady: What would that do?
TimToady pick the entries that match the selector. 20:40
20:40 DaGo joined
TimToady a selector is smart matched. 20:40
a smart match against a range checks to see if something is in that range.
Juerd But the same makes little sense for map?
TimToady selectors return boolean.
theorbtwo do {my @result; for (@nums) {push @result, $_ if $_ ~~ 0..3}; @result}
TimToady right, sorry 20:41
I mentally translated your map to grep
but it's still the case that the syntax is map EXPR, LIST.
Juerd grep X, LIST; is like grep { $_ ~~ X }, LIST?
But then not recursive :P
TimToady: Syntax, but not use.
TimToady it's just map does something different. 20:42
you could probably use anthing that maps though, like a hash.
map %xlate, @values
Juerd I hope documentation won't use "EXPR" anymore, especially when as specific type is wanted :)
theorbtwo TT: Isn't that just %xlate{@values}?
Juerd theorbtwo: You're quick.
TimToady how can you tell what type is wanted in the presence of ubiquitous MMD? 20:43
I guess there's a return sig anyway
aufrank by my book he is-- I was still typing it!
Juerd I'm talking about documentation, the realm of EXPR.
TimToady Item --> Boolean for instance
theorbtwo grep SmartMatchable, Array seems like reasonable documentation.
TimToady We'ver already named those Selectors 20:44
theorbtwo Hm, OK.
TimToady I agree that EXPR is not specific enough. 20:45
Juerd theorbtwo: Well chosen signatures are great documentation =item's by themselves. 20:46
Though I'd like to step away from pod, TBH
To some kind of property of which the value is a string.
is documented(q[ ... ]) 20:47
TimToady If you have opinions on that subject you should help Damian and Ingy with the revised S26, whatever it's called these days...
Juerd I think it will be very hard to align our opinions. 20:48
aufrank Juerd: couldn't that just be a macro that got expanded to POD?
Juerd aufrank: I think it'd be scary if POD processors would have to parse macros.
TimToady pugs/docs/Perl6/Spec/Documentation.pod or some such.
on the other hand, the document structure will be availabe to the surrounding code. 20:49
avar $=section, right? 20:50
TimToady so anything that is naturally code goes in as code, and anything that is naturally doc goes in as doc, but is still available as if you'd put it in as code.
Juerd My thoughts are class Foo does Bar is documented(q[]) { has $.foo is documented(q[]); method foo($bar, $baz, @quux) is documented(q[]) { ... } ... }
TimToady is documented--
%=DOC++ 20:51
Juerd The first would be the semi-equivalent of DESCRIPTION, the second and third of PROPERTIES and METHODS
theorbtwo Juerd, the problem is when one of those is documented q[]s are several screenfuls, and you forget where you were by the time you're done. 20:52
TimToady the document model will even give you the nearby comments if you want smart comments
avar forsees stuff like multi sub factorial is documented "This function takes ... and returns" { ...
Juerd The more I document code, the more I think something/someone else should structure it. I just want to document methods, not add text that happens to have a heading with the same name.
TimToady so just use the shiney new #{...} for your inline docs.
Juerd theorbtwo: I'm against pagefuls of documentation for single items anyway. 20:53
theorbtwo What I would like is the combination of the inline is documented, and a very good system for setting it later.
Juerd theorbtwo: And, if these are strings, you can interpolate :)
TimToady how...literate...
avar TimToady: #{} ?, comments starting / ending at arbitary points?
TimToady yes, except they can't start in the leftmost column.
Juerd theorbtwo: You're right, though, that "is documented" (though that syntax sucks) isn't enough.
TimToady happened a week or two ago 20:54
see S2
theorbtwo Thus, you should be able to get at an element in the signature of a purticular method, and set it's is documented property later.
Juerd TimToady: I've always had a nice difference between documentation and comments, and I think using #{} would mess that up.
pmurias sleep& #i'll be away from #perl6 for two weeks school exchange(east germant), and an alogrithmic camp so have fun
TimToady cool. 20:55
Juerd Avalon-- # boring movie.
theorbtwo Juerd: More then a screenful is probably too much, but several lines seems like it'd be quite common.
pmurias: "eastern Germany" is a region of Germany. East Germany is a country that doesn't exist anymore.
Juerd s/(using '#{}')/$0 for documentation/
theorbtwo: It's common, but not a style of documentation that I like or write. 20:56
TimToady you get to pick your delimiter with #{}, so you can pick something distinctive.
Juerd TimToady: How does that work? #<> and such?
pmurias theorbtwo: sorry, eastern Gemany
TimToady try again. :)
merlyn how do you hunt IRC? 20:57
aufrank Juerd: I think you have to use things that are matched pairs in unicode
merlyn Oops ... please ignore that.
aufrank and <> are nto?
TimToady all defined in S2
aufrank merlyn: I know this one! with an IRC-gun? carefully?
TimToady nto? 20:58
aufrank s/nto/not/
sorry =\
TimToady defined such as to include <>
despite not being Ps/Pe
avar On POD... 20:59
Juerd <> are the texas ā€¹ā€ŗ
TimToady basically, "bracketing characters" in Perl 6 are now defined to be either Ps/Pe pairs or bidirectional mirror pairs.
:) 21:00
aufrank good to know
Juerd TimToady: Does the definition include <<>>, the texas Ā«Ā»?
Juerd should really reread the synopses (and such) again
aufrank any stacked openers have to be matched by an equal number of stacked closers covers that I think
TimToady Yes, multiples are consistently supported, though the semantics of <<>> are special in some places.
aufrank [[[bracketed]]] 21:01
Juerd But I'm wasting my saturday of tuits on movies and irc :(
TimToady [[[*]]]
avar Since I began writing pod for Perl 5 code a few things have annoyed me, but the biggest one is probably that documenting a given file with POD is not as straightforward as Javadoc or phpdoc (although you get more in return), basically you can't tell if a pod section above a sub describes it or just happens to live there
TimToady we're fixing that.
avar there's no standard section name like METHODS (correct me if I'm wrong),
TimToady: good;)
TimToady get involved in the Documentation.pod rewrite if you like. 21:02
Juerd #怌In item context, returns a Tuit怍
TimToady legal
Juerd Hm, I may be using unicode in my sources after all then :)
TimToady Hey, Unicode has to be good for something... 21:03
Juerd avar: There are no standard section names. Only de-facto ones. Methods are often under DESCRIPTION, as a =head2 Methods
TimToady: How about ā€œthisā€ and ā€žthisā€? :)
Is "" just the texas ā€œā€? :P
TimToady those don't match. 21:04
avar Juerd: Yeah, that was kind of my point, I'm not saying that the system should enforce it, merely that the equivalent of perldoc perlpod should "lay down the law" as it were;)
Juerd TimToady: Why not?
TimToady I think you've mixed different quote types.
aufrank the first set was mirrored and bidirectional...
Juerd My Compose file thinks they match
And my font does too :)
TimToady Okay, the first set match--my font is screwed up. 21:06
Juerd The second is Afrikaans, Dutch, Hungarian, Norwegian, Polish, Romanian
TimToady the second can't match unless they're defined as a Ps/Pe pair.
Juerd I know them from my childhood, when I still read non-electronic dutch texts :) 21:07
avar ā€žā€œ is a german quote pair
also used by other locales..
Juerd I've never seen them ever since, except in some ASCII attempts to emulate them (,,''), and in the wikipedia article Quotation_mark
aufrank you can tell how much of a rube I am-- this is the most unicode I've ever seen in one buffer 21:08
Juerd avar: Yea, the second glyph is different there indeed. We use ā€žā€, Germans use ā€žā€œ
ayrnieu I like chinese quotation.
Juerd ayrnieu: So do I.
avar Juerd: fleh;)
ayrnieu aufrank - I've seen whole pages of unicode -- but I can't read any of this.
Juerd I can see my documentation be enclosed in 怎怏 21:09
avar ayrnieu: yeah, it rocks;)
Juerd #怎The maximum number of Tuits怏
afk # hurts 21:10
aufrank OT: it's a good day to be a Cleveland Cavaliers fan
ayrnieu avar - the difference between POD and langdoc isn't that you have some things not as straightforward and get other things more in return, it's that the former is meant for human consumption and the latter for mechanical consumption. (And the latter never really stops being for mechanical consumption) 21:11
svnbot6 r10056 | pmurias++ | removed too unused functions 21:14
21:14 xinming joined
aufrank TimToady: re: PDL bait in S09 21:15
TimToady yes?
aufrank do you think design is far enough along that I could propose a PDL in p6 SoC project?
pmurias is there a way to fix typo's in commit msg's?
TimToady pmurias: I don't think anyone cares about typos there. 21:16
pmurias *typos,msgs
aufrank pmurias: commit again ;)
TimToady aufrank: have to bounce that off of Audrey
aufrank ok, I'll keep an eye out
ayrnieu | deleted some stuff OH AND THAT WAS 'TWO'
TimToady I'm not sure where multidim arrays are currently, implementation-wise 21:17
aufrank | gratuitous commit, me-- to keep karma fair
;)
TimToady: well heck, maybe that's something to work on :) 21:18
s/something to/something I could/
TimToady issues aufrank a duplicate commit bit 21:20
ayrnieu www.selectparks.net/modules.php?nam...mp;sid=442 # unrelatedly, this is a really awesome video
21:21 lidden joined
aufrank TimToady: gathering ideas for the time in a few weeks when my shipment of tuits comes in 21:21
but yes, I should produce more
21:24 mako132_ joined
TimToady my gut level feeling is that PDLness probably *would* make a good SoC project. 21:28
aufrank good to hear :) 21:29
TimToady at worst, it'd be kludged in the way it's kludged into Perl 5, but integration is sufficiently open-ended that one wouldn't run out of things to do quickly, yet one could declare success at any point. 21:30
aufrank that's an especially encouraging way to think about it :) 21:31
TimToady Plus it's something that is likely to be useful in whatever state it comes out, so people can build on it.
And it would be good to flesh out that part now rather than later, since it's one part of the design where I'm doing more guessing than usual. (Hard, I know.) 21:32
aufrank ok, I'll try to talk to audreyt later today and if things look promising I'll probably solicit comments from p6c 21:33
TimToady I'm behind you 100% at least until the shooting starts... 21:34
aufrank we're making a movie?
TimToady playing marbles
aufrank I've got a killer aggie 21:35
TimToady I used to have a nice set *cough* years agol. 21:36
*ago
aufrank WhatevercoughWhatever
TimToady well, I'd better curl up in a corner and contemplate what's happening to the fish operator. 21:37
aufrank I've always thought we should do something with squiggly arrows
TimToady =<> for those following along at home...
aufrank they're so cute!
~>
TimToady that looks like a bird about to eat a catapillar 21:38
21:38 fglock joined
TimToady Hmm. I wonder what unary string rightshift would mean... 21:39
aufrank for @foo ~> / (\d+) / { say $0 }
or is there already a way to do selectors in pointy subs? 21:40
TimToady Unfortunately we already have infix:{'~>'}
aufrank really?
which Syn is it in?
TimToady S03
string right shift 21:41
aufrank goes to check
TimToady for @foo -> $_ where / (\d+) / { say $0 } might work
xinming perl 5 used all the punctuations in a normal keyboard... and perl 6 used all 2 key sequence composition in punctuations... :-) 21:42
aufrank oh come on, we could still poach haskell's {- and -}
there are plenty of 2-grams left
obra nah. we need multiline ascii art sigils 21:43
: ^ ^
: o o 21:44
TimToady I think you're looking for Befunge or some such.
obra : ---
obra grins
and is no good at ascii art in a linemode editor
TimToady I recognized it...
actually, I think my interpolation helped...
coming between the eyes and the mouth 21:45
obra I need a bit of unicode to do whiskers correctly. and the eyes were offset
TimToady what about the little chevronny things?
obra ah, yeah. 21:46
"I need an irc client that can display utf8 or latin1"
I fall back to >> and <<
merlyn Ā«fall backĀ»
obra wonders what the neko operator would do.
aufrank obra, rcirc in cvs emacs is working nicely for me
obra merlyn: was that sent as latin1 or utf8? It worked fine 21:47
merlyn utf8
obra aufrank: I use irssi in screen.
merlyn and from emacs
obra ah. excellent.
TimToady anyway, if we make =<> only ever read one line from @ARGS, then we end up with a special case on * if we want
for *<> {...}
merlyn actually. Terminal.app in utf8 mode -> ssh -> screen -U -> emacs -> irc.el -> sockets -> ircd
I'm amazed it works
obra nice. 21:48
merlyn ā€¢bulletā€¢
TimToady to fill that role now. As long as it's a special case...
merlyn your 2Ā¢
Ā»spaceship_dockĀ«
OK - time to go to Yet Another BBQ in Brazil 21:49
TimToady then for * {...} is just a slightly specialler case...
aufrank merlyn, do you have a name for the *..* range ?
TimToady I was actually a bit serious earlier when I said
for Whatever {...}
aufrank TimToady: you want for Whatever rather than for * ? 21:50
TimToady no, Whatever is what it means.
aufrank oh oh
ok
TimToady surface syntax is still *
just in that context means *<> or *$ARGS or some such
aufrank what does * search over in that context? 21:51
seems like there a lot of things that could appear in first position to for 21:52
TimToady dunno.
Juerd Oh no. * is the second default :|
aufrank Juerd: I'm not familiar with the :| term. Can you explain it? ;) 21:53
TimToady if empty postfix <> still means ARGS though, and if we ignore @<foo> from Match objects
then @<> could mean all the lines from ARGS
but @@<> would mean to keep the separate file's lines as a separate dimension.
aufrank I like the last bit
TimToady but it depends on swiping empty <> from @() 21:54
which we could conceivably do, since the empty key doesn't mean anything anymore to $/ 21:55
but it's a little confusing that @<foo> means $/<foo> when @<> means *$ARGS 21:57
aufrank it's not that bad: $/<foo> is a Capture and @<> is a Capture, right? 21:59
TimToady mmmm 22:00
explain that to a five-year old
aufrank heck, I wasn't even sure I was right when I said it 22:01
avar Maybe you should declare that Perl 6 will look like python 2.8 if you want it to be 5 year old explainable;)
TimToady 'Course a 5 year old will simply take on faith that "for * {...}" works and run with it.
aufrank but I would say something like @<*> is a way to get at groups that have been bound together previously in the program 22:02
TimToady groups?
aufrank and that sometimes they were bound by a Match, and sometimes they came in pre-bound in a file
I was trying not to say Capture
five year olds don't call you out on vagueness!
TimToady yeah, tell me about it... :/ 22:03
aufrank (did you notice my Whatever? @<*> )
TimToady yes, I did
aufrank =D
the reason Whatever parses for me is that that's pretty much how I read the Kleene star in regex anyway 22:05
well, I guess that's how I read m/.*/
of course, that makes me think that if * is Whatever, + is Something 22:07
TimToady for + {...}
aufrank for + -> { say $_ } # won't try to say undef?
s/->//
TimToady for ? {...} 22:08
for **{0..10} {...}
that...almost works... 22:09
aufrank ? is qbit or something
TimToady for "do" | "do not" {...} 22:10
aufrank I don't know if I understand what the Whatever loops buy us
I don't think I get the use case
TimToady for "better" | "worse" {...}
aufrank chuckles 22:11
TimToady It's probably too cute, mostly because the context is too diffuse
I could more easily believe that * is the ARGS iterator if it were used like =* or @*
aufrank *..'b'|!'b'
TimToady ... 22:12
aufrank yeah, I botched that one
TimToady ?('b'|!'b') maybe
aufrank *..'b' | !*..'b' 22:13
TimToady hmm *..'x'
aufrank I was trying to riff on *..$foo ranges as being "to $foo"
TimToady I wonder what a negative string looks like?
aufrank I had to write on my forehead to figure it out 22:14
TimToady /foo$/
aufrank oof
TimToady or would that be /oof$/
bingo
aufrank and I think it would be \oof$\
TimToady surly \$foo\
\$oof\ I mean 22:15
22:16 larsen joined
TimToady pity f doesn't have a bidi mirror... 22:17
aufrank yes, it's the only thing keeping this from being a totally practical discussion ;) 22:19
anyway, I was going for "to be or not to be" trying to use ranges
^'b' | !^'b' 22:20
TimToady I'm not sure you can ! a range... 22:21
though I suppose it could be useful. 22:22
Oddly, $a..$b is contiguous, but !($a..$b) wouldn't be...
aufrank right 22:23
but you could want to check that a value is outside of a range
is that just negating the smart match?
TimToady that would generally be clearer, i suspect.
On the other hand, as a general selector...
aufrank oh, right
TimToady I guess you could always pass { $_ !~ $range } 22:24
say not $a .. $b # -Inf, -Inf,-Inf,-Inf,-Inf,-Inf,-Inf,-Inf,... 22:25
YetAnotherEric what's a junction?
aufrank YetAnotherEric: examples include any(@foo) and none(@foo) 22:27
TimToady It's a set of data values along with a hint about their logical relationship 22:28
YetAnotherEric sorry, I thought a negated range could be a junction
aufrank if 'foo' ~~ none(@bar) { say "no foo here" }
junctions also guarantee that operations on the junction spawn new threads, right? 22:29
TimToady Currently junctions are only discrete values, whereas ranges are (in the abstract) continuous.
rather, use of a junction is a promise that the "legs" of it can be calculated in parallel without interference. 22:30
aufrank much better. it sounded off as I wrote it.
TimToady Unlike hyperops, even ordering is lost.
YetAnotherEric returns to lurk mode
TimToady even completeness is lost, in the sense that a hyper goes to completion 22:31
while a junction is free to short-circuit any way it likes
as long as the logical relationship can be proven.
so $a ~~ 1 | 2 | 3
can quit as soon as it finds any match. 22:32
aufrank right, if 'x' ~~ one(@foo) { say } can short circuit as soon as it's got one match
TimToady no
it can quit as soon as it finds two matches. :)
aufrank you got me
TimToady if 'x' ~~ any(@foo) { say } can quit on one match 22:33
aufrank yup
TimToady as can all(@foo) if it's false
or none(@foo) if it's true 22:34
aufrank are there two(@foo), three(@foo), etc, or is there a general junction form to say "exactly n"?
TimToady nothing like that 22:35
Juerd TimToady: If a StrLen object hangs on two StrPos objects, which in turn are Str dependent, then why not have a SubStr instead of StrLen? 22:36
TimToady: Also, do $strpos2 - $strpos1 and $strpos1 .. $strpos2 mean the same thing? 22:37
TimToady well, that's exactly what $0 is...
I doubt .. would know what to do with StrPos, but StrPos might figure out what to do with .. 22:38
Juerd A range makes more sense to me than substraction, actually.
TimToady and .. could exclude the endpoints. :) 22:39
Juerd And when working with times, I prefer periods to differences. (The difference between times A and B is the length of the equally shaped period)
TimToady I once had a font with square periods... 22:40
Juerd Don't make fun of my bad English please :)
TimToady i wasn't making fun of your bad English
Juerd Oh
TimToady I was making a pun.
I do that sometimes...
unfortunately... 22:41
Juerd Disregard my last statement then :)
TimToady Fortunately, time is kinda uniform (to the first approximation), Unfortunately, string lengths have multipathing problems. 22:42
Juerd Personally, I think integers are fine, and some pragma can select which integers are wanted. I'm not likely to ever want anything else than character boundaries anyway. 22:43
TimToady but it certainly the case that we should prefer APIs that deal with the strings themselves rather than indirectly referring to them via their locations 22:44
Juerd Someone working with languages a lot will probably disagree with me that you need only one kind of position at a time.
(no pun intended)
TimToady Well, and byte boundaries are likely to be the internal form a StrPos in many cases.
but you might have a pos in a string that doesn't even *have* bytes. 22:45
Juerd Perl 5's strings also work fine for me. They give me characters, which typically is exactly what I want :)
How does a byteless string work?
TimToady espcially now that we can do things like @foo ~~ /stuff/
you get handed a string with its minimum abstraction level set to, say, codepoints, and you aren't allowed to know it's repr internally. 22:46
Juerd I see.
22:46 Khisanth joined
Juerd Would it make sense to make strings much simpler by default, and enabling all these non-character operations only if explicitly requested through a pragma? 22:47
22:47 xinming joined
TimToady Or you are matching an array of token objects. 22:47
Juerd It would take a lot of complexity out of the language, without making anything less possible.
TimToady That's the Str vs Buf distinction.
Juerd Bufs don't do unicode 22:48
TimToady that's correct.
Unicode doesn't do integers.
Juerd It does in Perl 5, and that happens to work well in most applications
TimToady Even UTF-16 is not a fixed-width representation. 22:49
Juerd already knows much more about unicode/utf-8 than he would have liked to
TimToady And at grapheme level, even shoving everything into UTF-32 doesn't help
Juerd For many programmers, it'd be nice if there were just a sane default, instead of a forced choice. "length" may not make sense to unicode, it does make sense to most users... 22:50
TimToady no, they just think it makes sense...
And it does make sense, but not in the way they think it does.
Juerd That hasn't bothered them before... 22:51
TimToady They weren't using Unicode before.
The reason the default level is graphemes is because that's closest to their intuition of what was happening before, even though that's harder for us. 22:52
You can use integers at grapheme level, just as you can use integers in Perl 5 at codepoint level, but you have to do tricks to deal with variable length characters in any case. 22:53
Juerd I wonder what the most often used application of string length is 22:54
Could be %s-like stuff.
TimToady that's yet another definition of length.
Juerd In which case it's futile anyway, if someone should use ļ½†ļ½•ļ½Œļ½Œļ½—ļ½‰ļ½„ļ½”ļ½ˆ characters :) 22:55
TimToady which has nothing to do with any of bytes, codepoint, graphemes, or characters...
it's just a definition that depends on knowing your output device.
or not caring.
you'll note that HTML gets along fine without %s. 22:56
Juerd Not caring, is my guess from what I've seen :)
I use HTML almost always in combination with %s, but never witch character counts in between % and s :)
TimToady basically, for interpolation, not sizing.
22:56 coumbes joined
Juerd sprintf(q[<a href="%s">%s</a>], uri_escape($url), encode_entities($url)) 22:57
TimToady interpolation
Juerd Yes.
Juerd wonders what he would use in Perl 6
Juerd still wants a generic encoding thing, that works for every encoding. Probably not doable. 22:58
TimToady q[<a href="{uri_escape($url)}">{encode_entities($url)}</a>]
Juerd I think that's very ugly.
TimToady don't deny it.
Juerd Wouldn't you need qq, by the way?
TimToady yeah
Juerd Or q:c (?)
avar print CGI->a($url, href => $url); 22:59
TimToady q:url($rul)/.../
s/ru/ur 23:00
Juerd qq[<a href="{ $url.enc: <URI> }">{ $url.enc: <HTML> }</a>] # dreaming
avar you shouldn't be manually generating html in the first place;)
Juerd avar: EEWWWWWwww, no. Please, no. No CGI->a.
Or CGI.a
Or anything generating a single tag with 1:1 translations.
TimToady Didn't we tell you? Perl 6 is an attempt to re-invent PHP...
xinming Juerd: CGI.new.a IMO. :-)
avar yay php 23:01
FurnaceBoy it's best to warn him now
Juerd If you have to know "a", you have to know HTML. If you know HTML, you're better off writing it yourself than letting code do it for you.
avar Juerd: Whatever you're using it sucks less than manual HTML
Juerd: no you're not
Juerd If I have to learn a second syntax, please let it be DIFFERENT, so it doesn't feel like I'm wasting my time.
avar Well actually your main code should probably not know of HTML at all;) 23:02
TimToady I think we should write it all in lisp...
Juerd Also, HTML <a> tags have nothing to do with CGI, at all. Please let this mistake stay out of Perl 6 world.
avar: That's a better one already.
avar: If if you have to abstract, let it be templates, not tag generation methods. Ew.
avar Juerd: Indeed, html generation should not be in CGI
TimToady declarative programming++ 23:03
as long as it's all imperative underneath :)
Juerd imperative++ # Makes me feel I'm in control. 23:04
TimToady feelingsĀ±
Juerd Ā±Ā± :) 23:05
Ā«'does $this interpolate'Ā» the variable $this? 23:06
TimToady hmm, statistical range objects... say $x ~~ $yĀ±3 # "maybe"
avar Juerd: yes
?eval my $x = 5; Ā«$xĀ» 23:07
bleh
TimToady no it doesn't
23:07 evalbot_10054 is now known as evalbot_10056
evalbot_10056 *** Undeclared variable: "$x" at -e line 15, column 7-43 23:07
TimToady <<..>> do shellish quoting syntax
23:07 larsen joined
avar I thought it was just like " ' $foo ' " 23:07
Juerd avar: It was the '' within Ā«Ā» that I was curious about, as Ā«Ā» does interpolate, but shellish '' doesn't 23:08
I like Ā«Ā».
TimToady why would we want to duplicate " ' $foo ' "
Juerd I've even taught my environment utf-8 for it.
23:08 marmic__ joined 23:09 marmic__ is now known as marmic
Juerd TimToady: This doesn't glob, I hope? :) 23:09
TimToady good gad no
just the quoting 23:10
and that not including backticks.
Juerd Great
23:11 Alya joined, axarob joined
theorbtwo likes $x plusorminus $y as equiv to $x-$y .. $x+$y. 23:25
(My compose key isn't set up to work in the console...) 23:26
?eval 1.1 ~~ 1..2 23:27
evalbot_10056 bool::false 23:28
theorbtwo Hm. Is that correct?
(I'd prefer it be incorrect...)
avar ?eval 1.1 == any(1,2) 23:30
evalbot_10056 bool::false
avar ?eval [1..2]
evalbot_10056 [1, 2]
avar ?eval 1 <= 1.1 <= 2
evalbot_10056 bool::true 23:31
avar so you see it all makes perfect sense
theorbtwo Yeah, avar, I know... hm, I suppose it doesn't make terrible amounts of sense for it to mean 1,2 in list context, but match anything between 1 and 2 as a smart-matcher.
...but writing {1<=$_<=2} when you want something to match against seems a bit of a false hufmanization.
Juerd ?eval 1..2 :by(.1) 23:32
evalbot_10056 Error: unexpected ":" expecting comment, operator, "does", "but", "is", "^till", "till^", "^..^", "till", "..^", "<=>", "^..", "cmp", "..", postfix conditional, postfix loop, postfix iteration, ";" or end of input
theorbtwo Juerd: pugs doesn't parse adverbs on ... 23:33
I wonder...
?eval infix:<..>(1, 2, :by(.1))
evalbot_10056 Error: No such sub: "&infix:.."
23:36 FurnaceBoy_ joined