Dumb doc question...

2006-08-16 Thread Mark J. Reed
...which I would have thought was a faq; maybe I just haven't found the right faq list... Where can I find a pod2html that groks the p6 version of POD? I want to format my fresh-from-svn copies of the doc... -- Mark J. Reed <[EMAIL PROTECTED]>

Re: === and array-refs

2006-08-17 Thread Mark J. Reed
eferencing as long as the referent is anonymous, and no dereferencing if the referent is a named variable? That doesn't seem like a common enough case to warrant sugar to me; what am I missing? -- Mark J. Reed <[EMAIL PROTECTED]>

Invocant name in S12

2006-08-17 Thread Mark J. Reed
tional; and then later on in the context of attributes it uses "self" as if it's already been talked about, but I can't find an introduction of the term anywhere... -- Mark J. Reed <[EMAIL PROTECTED]>

Re: multi-line comments, C macros, & Pod abuse

2006-08-20 Thread Mark J. Reed
; it's treated as a single-line comment. You need to put something before the # on the line. -- Mark J. Reed <[EMAIL PROTECTED]>

Pair of lists => list of pairs?

2006-08-23 Thread Mark J. Reed
= @k [=>] @v; -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Pair of lists => list of pairs?

2006-08-23 Thread Mark J. Reed
he "any old" kind.) -- Mark J. Reed <[EMAIL PROTECTED]>

My first functional perl6 program

2006-08-23 Thread Mark J. Reed
friendly strings out of it. This was much more natural. (Speaking of which, pugs apparently doesn't have C as a global function, only the .trans method) It does sadden me somewhat that the say() requires the parens (or an explicit $_ etc). But I'll live. :) (The key above is for today's Order of the Stick, btw.) -- Mark J. Reed <[EMAIL PROTECTED]>

Re: My first functional perl6 program

2006-08-23 Thread Mark J. Reed
On 8/23/06, Mark J. Reed <[EMAIL PROTECTED]> wrote: my %trans = ('a'..'z') »=>« ('?' xx 26); Also, correct me if I'm wrong, but I should theoretically be able to use xx * there, thus creating a lazily-evaluated infinitely-long list of question marks? -- Mark J. Reed <[EMAIL PROTECTED]>

Re: My first functional perl6 program

2006-08-23 Thread Mark J. Reed
output. And if I try .trans: $ pugs -e '$_ = "foo"; say .trans(o=>0)' *** No compatible subrountine found: "&trans" at -e line 1, column 13-31 But in any clase I'm glad it's merely an implementation bug rather than specced behavior. -- Mark J. Reed <[EMAIL PROTECTED]>

Re: My first functional perl6 program

2006-08-24 Thread Mark J. Reed
erfectly clear what that means. Fpr example, $foo xx * creates a(n infinite) list which contains $foo at every position no matter how high a position you ask for . . . -- Mark J. Reed <[EMAIL PROTECTED]>

Re: My first functional perl6 program

2006-08-24 Thread Mark J. Reed
On 8/24/06, Mark J. Reed <[EMAIL PROTECTED]> wrote: e.g. q(a b) >>=><< (1,2,3,4) would return (a=>1, b=>2, undef=>3, undef=>4). or rather, it would if I'd typed qw(a b) as I intended. One other point: while I agree that we should shield the programmer a

Re: clarifying the spec for 'ref'

2006-08-24 Thread Mark J. Reed
rt matching with ~~ would be the usual way to go, I suppose you could also do an explicit equality check with .^/.META... -- Mark J. Reed <[EMAIL PROTECTED]>

Re: clarifying the spec for 'ref'

2006-08-25 Thread Mark J. Reed
*. I think the justification for Luke's POV is the number of operations each class provides. But my perspective agrees with Juerd - subclasses can remove functionality as well as adding it, and I definitely view "constant" as an add-on modifier, not a default that has to be overr

Re: clarifying the spec for 'ref'

2006-08-25 Thread Mark J. Reed
able expectations. You can be paranoid about it if you want, but it's not a very Perlish form of paranoia. (Yes, there are Perlish forms of paranoia. Taintedness checking, for instance...) -- Mark J. Reed <[EMAIL PROTECTED]>

Re: clarifying the spec for 'ref'

2006-08-25 Thread Mark J. Reed
OK, I admit I wasn't thinking about things from a DBC perspective, and misunderstood "DBC" to be a reference to some database module. I here am new and I didn't have context. My bad. But if we're talking design-by-contract, I don't see how "Array is Array::Const" can work, either, since I consi

Re: clarifying the spec for 'ref'

2006-08-25 Thread Mark J. Reed
On 8/25/06, Mark J. Reed <[EMAIL PROTECTED]> wrote: I here am new and I didn't have context. Well, technically, I here am not new; I've been here since before Apoc 1. But I hadn't been paying close attention for a while until recently. :) Either way, I didn't get

Re: Same-named arguments

2006-08-27 Thread Mark J. Reed
o support perl5 calling semantics, I'd prefer a mechanism for asking for that explicitly in the signature rather than jumping through hoops to support it by default. Perhaps there could be a rule that, in the absence of a slurpy hash declaration, any trailing Pairs are scanned for matches to named parameters? -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Classes / roles as sets / subsets

2006-08-29 Thread Mark J. Reed
;m American; make that "executable math". ) I think it's certainly closer than Perl6 will be. And yet, for all the talk about "line noise", APL makes even the worst perl3 code look positively legible by comparison. :) -- Mark J. Reed <[EMAIL PROTECTED]>

Naming the method form of s///

2006-08-31 Thread Mark J. Reed
ot;replace" would be a better name, even though it breaks the mnemonic association with s///? -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Naming the method form of s///

2006-08-31 Thread Mark J. Reed
n't think substitution belongs in a smart match op. Well, that's the reason for the method version in perl6. Which, AFAICT, returns the new string instead of the Match object, which is as it should be. The only thing I don't like is the name. :) -- Mark J. Reed <[EMAIL PROTECTED]>

Re: C outside of C

2006-09-07 Thread Mark J. Reed
tically at least). So I don't see a need for a specific restriction on the use of "when". -- Mark J. Reed <[EMAIL PROTECTED]>

Re: renaming "grep" to "where"

2006-09-19 Thread Mark J. Reed
also happens to use map and closures. There's nothing terribly confusing or intimidating about grep itself apart from the name; "find all items in this list matching blah" is pretty straightforward functionality. -- Mark J. Reed <[EMAIL PROTECTED]>

Re: renaming "grep" to "where"

2006-09-19 Thread Mark J. Reed
ot; to do a "grep -v" (cf. "if !" vs "unless"). But I'd accept "filter", too. I definitely vote C, though. No aliases in the core, but no reason not to include modules in the standard set that provide some. -- Mark J. Reed <[EMAIL PROTECTED]>

Re: renaming "grep" to "where"

2006-09-19 Thread Mark J. Reed
ed. Indeed. Ruby also has "select" (an alias for "find_all"); as indicated in my last message, that's my new favorite name for this method (second only to keeping "grep"). -- Mark J. Reed <[EMAIL PROTECTED]>

Re: renaming "grep" to "where"

2006-09-19 Thread Mark J. Reed
s in to grep can have other side effects, which may not have an "opposite", but that's to me a separate issue). Also, how is grep intended to work in P6? I had just sort of assumed that it took any sort of value as a criterion and smart-matched against it, but pugs currently requires a block... -- Mark J. Reed <[EMAIL PROTECTED]>

Dumb list-flattening question.

2006-09-21 Thread Mark J. Reed
TECTED], [EMAIL PROTECTED]), then what do we call what the \ is doing there, now that references are supposed to be a behind-the-scenes automagical thing? -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Dumb list-flattening question.

2006-09-21 Thread Mark J. Reed
Mark J. Reed wrote: > Ok, I dkimmed through the synopses again and didn't see this offhand. That's what I get for dkimming instead of reading. Or even skimming. OK, so "Capture objects fill the ecological niche of references in Perl 6." Got it. Perhaps we should

Re: Captures: Synopsis update

2006-09-21 Thread Mark J. Reed
you have exactly the same ambiguity there: $o.a%$b $o.a % $b $o.a %$b -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Captures: Synopsis update

2006-09-21 Thread Mark J. Reed
f that particular ambiguity in Perl 6. Thank you, design team. -- Mark J. Reed <[EMAIL PROTECTED]>

Re: RFC: multi assertions/prototypes: a step toward programming by contract

2006-09-29 Thread Mark J. Reed
way around. "package" is Perl 5, because that's the P5 keyword, and seeing a "package" declaration is an indicator to Perl6 that the file it's processing is written in P5. In P6, there are both "module"s and "class"es, but no "package"s other than those inherited from P5 code.. -- Mark J. Reed <[EMAIL PROTECTED]>

Re: RFC: multi assertions/prototypes: a step toward programming by contract

2006-09-29 Thread Mark J. Reed
On 9/29/06, Jonathan Lang <[EMAIL PROTECTED]> wrote: And here I thought you were a responsible, law-abiding citizen... :P And so it begins. I daresay there will be no shortage of jokes among P6ers about "does Hash" ... -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Hash composers and code blocks

2006-10-05 Thread Mark J. Reed
something go awry in the email encoding (possibly on my end)? -- Mark J. Reed <[EMAIL PROTECTED]>

Re: named sub-expressions, n-ary functions, things and stuff

2006-11-13 Thread Mark J. Reed
On 11/13/06, Darren Duncan <[EMAIL PROTECTED]> wrote: - There are no Undef or NaN etc values or variables. A RDBMS language with no "null" would seem to be problematic.. although i guess you could just use 1-tuples where the empty tuple is treated as null. -- Mark J. Reed <[EMAIL PROTECTED]>

Re: List assignment question

2006-11-15 Thread Mark J. Reed
On 11/14/06, Vincent Foley <[EMAIL PROTECTED]> wrote: I was toying around with Pugs and I tried the following Perl 5 list assignment my ($a, undef, $b) = 1..3; Huh. I didn't think that worked in Perl 5, either. What am I misremembering? I distinctly recall having to do things like (my $a,

Re: List assignment question

2006-11-15 Thread Mark J. Reed
On 11/15/06, Ævar Arnfjörð Bjarmason <[EMAIL PROTECTED]> wrote: On 11/15/06, Mark J. Reed <[EMAIL PROTECTED]> wrote: > On 11/14/06, Vincent Foley <[EMAIL PROTECTED]> wrote: > > I was toying around with Pugs and I tried the following Perl 5 list assignment > >

Re: List assignment question

2006-11-15 Thread Mark J. Reed
ah! So I'm not crazy! Necessarily, anyway. Just behind the times. Thanks, Dave! -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Numeric Semantics

2007-01-09 Thread Mark J. Reed
I believe mod should be defined in the conventional way: x mod y = x - floor(x/y) * y, which does yield 0.8 for 3.2 mod 2.4. However, for 3.2 mod - 2.4 it yields -1.6. To get 0.8 you would have to round toward zero instead of taking the floor, and that complicates any computation that crosses ze

Re: What should file test operators return?

2007-04-13 Thread Mark J. Reed
re stat, but maybe this answer is a good end-of-chapter sorta thing. I'll also have to think about using given {} merely as a topicalizer too, I guess, although showing it next to an explicit assignment to $_. :) -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Default filehandles, or topicalizing filehandles, or something

2007-05-01 Thread Mark J. Reed
ing global variables initialized to named constants, e.g. $stderr starts out as equal to STDERR but can be reassigned... -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Default filehandles, or topicalizing filehandles, or something

2007-05-01 Thread Mark J. Reed
*DEFERR would be kinder to embedding systems that want to intercept such messages and log them. Right. Something akin to P5's $SIG{__WARN__} and $SIG{__DIE__} would also work, but that never seemed to be quite the right way to do that, to me. -- Mark J. Reed <[EMAIL PROTECTED]>

In(tro)spection and line counting

2007-05-02 Thread Mark J. Reed
is a method on the filehandle object, but called what? Should it keep the P5 IO::Handle name (input_line_number)? Or something else perhaps a little less unwieldy (lineno, recno, ...) I don't see any reference to $. in the Synopses, so I assume this is not yet defined. Apologies if I just

Re: In(tro)spection and line counting

2007-05-08 Thread Mark J. Reed
t's still pretty rudimentary. Ah, thanks! Missed that. As for $. itself as a variable, it's dead. Yeah, kinda figured. there are very, very few punctuational variables in Perl 6 compared to Perl 5. Most of 'em are just gone. And a cheer went up from the multitude... :) Thanks again for the reply. -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Is Perl 6 too late?

2007-05-14 Thread Mark J. Reed
not steal them? BTW: Why do so much people say "go away if you don't like it" instead of being open for ideas and discussing them from a neutral point of view? -- Thomas Wittek http://gedankenkonstrukt.de/ Jabber: [EMAIL PROTECTED] -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Sigils by example (was: Re: Is Perl 6 too late?)

2007-05-14 Thread Mark J. Reed
s the hash to have a single element whose key is the hash reference provided and whose value is undef... but in P6 that does the right thing.) -- Mark J. Reed <[EMAIL PROTECTED]>

x, xx, and negative counts

2007-05-29 Thread Mark J. Reed
', 'a'); I don't know why I think that makes sense, but it was honestly my first thought. Does it make sense to anyone else? Is there a compelling reason I'm missing for having negative values behave as if they were zero rather than adding some other potentially useful functionality? -- Mark J. Reed <[EMAIL PROTECTED]>

Re: x, xx, and negative counts

2007-05-29 Thread Mark J. Reed
odded to see what was going on in @larry.brain. Your explanation is all I needed to shush the little grumbles in my head. Thanks again! -- Mark J. Reed <[EMAIL PROTECTED]>

Re: [svn:perl6-synopsis] r14407 - doc/trunk/design/syn

2007-05-29 Thread Mark J. Reed
ing namespace +Any Perl 6 object (default parameter type, excludes Junction) +Object Perl 6 object (either Any or Junction) A C differs from a normal C in how it handles default values. If the value of a C element is set to the default -- Mark J. Reed <[EMAIL PROTECTED]>

Re: [svn:perl6-synopsis] r14407 - doc/trunk/design/syn

2007-05-29 Thread Mark J. Reed
of candidates: Indeed. Something shorter might be nice, but I wasn't proposing a rename. Besides, "Top" just reeks of LDAP. Oh, and you left out "Root". It being the root of the type hierarchy and all. Life::Universe::Everything ...which no doubt numifies to 42. Thanks again for answering my silly questions. -- Mark J. Reed <[EMAIL PROTECTED]>

Re: propose renaming Hash to Dict

2007-06-01 Thread Mark J. Reed
English" pragma? :) Are you the one who originally came up with "hash" for %vars? IIRC, they were officially called just "associative arrays" through Perl4, but "hash" was a well-understood community nickname for them for some time before you canonized it wi

Re: propose renaming Hash to Dict

2007-06-01 Thread Mark J. Reed
nce a random rearrangement of the inputs. Hence, a hash. -- Mark J. Reed <[EMAIL PROTECTED]>

Re: propose renaming Hash to Dict

2007-06-01 Thread Mark J. Reed
French "hache", but you have to go back to Norman times to get there. The word "hash" has been an English word for almost a millennium, and "hashed browns" are simply browns (browned potatoes) that have been hashed... -- Mark J. Reed <[EMAIL PROTECTED]>

Re: 'x' vs. 'xx'

2007-06-03 Thread Mark J. Reed
ot;~cat($n xx *)" might work. Personally, I would tend to favor the notion that infix: always produces a single string. With this in mind, I'm now leaning toward "~cat($a xx $n)" as the more verbose equivalent of "$a x $n". You always produce a single string, and you do so lazily (according to the way that 'cat' works in item context). -- Jonathan "Dataweaver" Lang -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Generalizing ?? !!

2007-06-11 Thread Mark J. Reed
s > > to true or false. > > Can we *please* keep simple things simple? Agreed. I'm in favor of this proposal to the extent that it breaks a simple trinary operator down into equally simple binary operators (with the trinary form continuing to exist as an emergent property of the interaction of the binaries); if those binary operators become more complex than the trinary form, or if you lose the ability to recover the trinary form from them, there's no point in pursuing this proposal. -- Jonathan "Dataweaver" Lang -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Indirect objects, adverbial arguments and whitespace

2007-10-07 Thread Mark J. Reed
adverbial colon needs whitespace before but not after? > > The reason I ask is that I'm knocking up an intro to Perl 6 for C and C++ > programmers. I expect some of Perl 6's whitespace rules to trip up people > used to C++ (as they have me, in my clumsy attempts with Pugs), and I'd > like to summarise all the whitespace dwimmery in one place. > > Many thanks, > > Markus > -- Mark J. Reed <[EMAIL PROTECTED]>

Re: xml and perl 6

2007-11-29 Thread Mark J. Reed
On Nov 29, 2007 10:07 AM, James Fuller <[EMAIL PROTECTED]> wrote: > Once again, the point is that I would like to manage and process XML > using native types, structures and xml aware operators, from within > perl. If I inherit XPATH, then I get 90% of everything I need. But what do you mean "nat

Re: perl 6 and web open source projects

2007-12-07 Thread Mark J. Reed
nted out, this sort of discussion belongs somewhere else. > Note that no language really shines on the web: it's something that > someone makes with the language (e.g. Catalyst, Rails, Seaside, Django) > that shines on the web :) > -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Switch/Given and English, Was perl 6 grammar

2007-12-09 Thread Mark J. Reed
idioms, words a good idea? > There're bunch of words that could describe the same idea > in a sligtly different manner. > Perhaps writting a la smallTalk could be the solution. > getting rid off all shortcuts and change them into explicit description > entities and write english sentences, not programs. > This could be nice but I will first have to learn English. > Anyway, I will write my own 'Lingua::Given::Francais' with avec ... > lorsque^^: > (well, if I can - ^^; xx 1000 ) > > > > -- > シリル・デュモン(Cyrille Dumont) > [EMAIL PROTECTED] > our work is the portrait of ourselves > tel: 03-5690-0230 fax: 03-5690-7366 > http://www.comquest.co.jp > > > -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Concerns about "{...code...}"

2007-12-20 Thread Mark J. Reed
braces (which is consistent to how they are used in other > expressions of the language). > > It is all there somewhere in Section "Literals" of Synopsis 02 > (http://perlcabal.org/syn/S02.html#Literals). More specifically, look > for the item that starts with "In addition to q and qq, there is now > the base form Q". > > Kind regards, > Adriano Ferreira > > > -- > > ...they shared one last kiss that left a bitter yet sweet taste in her > > mouth--kind of like throwing up after eating a junior mint. > > -- Dishonorable Mention, 2005 Bulwer-Lytton Fiction Contest > >by Tami Farmer > > > > > -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Concerns about "{...code...}"

2007-12-20 Thread Mark J. Reed
t use quotes in interpolated array indexes, just like Perl5): "The value is {$array['a key']}" or"The value is ${array['a key']}" But: "The value is {1 + 2 - 3}" - no interpolation "The value is {$x +$y - $z}" - syntax error because it expects the string starting with $x to be a dereference. -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Concerns about "{...code...}"

2007-12-20 Thread Mark J. Reed
> down. > -- Vaarsuvius, "Order of the Stick" >http://www.giantitp.com/comics/oots0107.html > -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Concerns about "{...code...}"

2007-12-20 Thread Mark J. Reed
6:01:53PM -0500, Mark J. Reed wrote: > >On Dec 20, 2007 4:30 PM, Patrick R. Michaud <[EMAIL PROTECTED]> wrote: > > > > Just to add another perspective, PHP uses curlies inside of > > double-quoted strings to indicate various forms of > > interpolati

Re: Concerns about "{...code...}"

2007-12-21 Thread Mark J. Reed
otation marks to make the character/string distinction. -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Official Perl 6 and Parrot wikis

2007-12-29 Thread Mark J. Reed
5 wiki. > > http://www.perlfoundation.org/perl5/index.cgi > > Best regards, > Conrad Schneiker > > www.AthenaLab.com > > > > -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Official Perl 6 and Parrot wikis

2007-12-29 Thread Mark J. Reed
Ok, consider me duly chastised. Sorry for the sidetracking. On 12/29/07, chromatic <[EMAIL PROTECTED]> wrote: > On Saturday 29 December 2007 06:56:45 Mark J. Reed wrote: > > > Maybe it's just me, but it > > seems like it will just feed the all-too-common percep

Re: Multiline comments in Perl6

2007-12-30 Thread Mark J. Reed
Whitespace is significant in many places. Even in some of the corners of Perl 5. Perl 6 has a different set of rules, and it will take some getting used to, but the rules are designed to let you do things as naturally as possible.This, for instance, works fine: my @values = # (1,2,3) # old

Re: Sequential bias in S04 (and Perl6 in general)

2008-01-04 Thread Mark J. Reed
Am I the only one having bad flashbacks to Occam, here? (Transputing Will Change Everything!) My $0.02, FWIW: Concurrency is surprising. Humans don't think that way. And programs aren't written that way - any program represented as a byte stream is inherently sequential in nature. Where the s

Re: [svn:perl6-synopsis] r14494 - doc/trunk/design/syn

2008-01-22 Thread Mark J. Reed
t a static variable, > +the old Perl 5 trick of "C" to get a static variable, > because a C variable starts out uninitialized every time through > -in Perl 6 rather than retaining its previous value.) Native integer > +in Perl 6 rather than retaining its previous value.) Native integer > containers that do not support the concept of undefined should be > initialized to 0 instead. (Native floating-point containers are > by default initialized to C.) Typed object containers start > -- Mark J. Reed <[EMAIL PROTECTED]>

Re: [svn:perl6-synopsis] r14500 - doc/trunk/design/syn

2008-02-05 Thread Mark J. Reed
7;d say. But is there a LET* analogue to do it the old way if we want to? -- Mark J. Reed <[EMAIL PROTECTED]>

Re: [svn:perl6-synopsis] r14500 - doc/trunk/design/syn

2008-02-05 Thread Mark J. Reed
s there no problem you can't solve? :) Thanks! -- Mark J. Reed <[EMAIL PROTECTED]>

Re: [svn:perl6-synopsis] r14500 - doc/trunk/design/syn

2008-02-08 Thread Mark J. Reed
On Feb 8, 2008 4:31 PM, chromatic <[EMAIL PROTECTED]> wrote: > On Tuesday 05 February 2008 20:02:53 Mark J. Reed wrote: > > > Ah, macros, is there no problem you can't solve? :) > > If my experience with the Perl 5 core is any guide, the problem of too many > ma

Re: question about twigil ?

2008-03-14 Thread Mark J. Reed
able comes from a different place than the $? constants. > > > thatswhy they are written uppercase. > You know $*IN is also internal var bat e.g. $*my is user defined. So i > see there no difference > if i define a $?var. > > herbert > -- Mark J. Reed <[EMAIL PROTECTED]>

Re: question about twigil ?

2008-03-14 Thread Mark J. Reed
On Fri, Mar 14, 2008 at 7:18 AM, Mark J. Reed <[EMAIL PROTECTED]> wrote: > Even if we were to have a "constant" twigil, I dont much like "$?" for it. > No mnemomic value. For the builtins, it's not the constancy but the fact > that they let you quey t

Re: Musings on operator overloading

2008-03-19 Thread Mark J. Reed
is dropped in > scope-bound overloading. In other words $x is then always converted > into the suitable form. But how is that performed in general? IIRC, > the only generically available form is stringification. > > Hmm, thinking twice, the above optimization is admissible only if > multiplication is commutative irrespective of the type of $x. > > > Regards, TSa. > -- > > The Angel of Geometry and the Devil of Algebra fight for the soul > of any mathematical being. -- Attributed to Hermann Weyl > -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Musings on operator overloading

2008-03-19 Thread Mark J. Reed
ciently different, that's not a requirement. Again, nobody's going to think you're dividing pathnames. > Perl is about linguistics, and hence is more concerned with successful > communication than with pure mathematical platonics. Which is why I like it so much more than certain of its brethren with their Orthogonality Ueber Alles attitude. I just don't want to see that sort of prescriptivity creep in to Perl. -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Musings on operator overloading

2008-03-20 Thread Mark J. Reed
Object to a numeric Object wll in some cases convert the string to a number and add instead of concatenating!), but + still works. -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Musings on operator overloading

2008-03-20 Thread Mark J. Reed
can do that... > > The P in Perl stands for Practical, not Pedantic. > > I consider well designed interfaces as practical not pedantic ;) Of course, good design is extremely practical. Just not necessarily objectively measurable. :) -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Musings on operator overloading

2008-03-20 Thread Mark J. Reed
gative result, while Apple and Atari return a positive one. I find it particularly interesting that not even all of the BASICs from the same codebase (Microsoft's original Altair release) agree with each other... We now return you to your regularly scheduled Perl 6 mailing list, already in progress. -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Musings on operator overloading

2008-03-21 Thread Mark J. Reed
; if you're completely changing the meaning of an operator, the reader should > have > nearby indication of what is really going on. Ah, so you want the types of typed vars to be apparent where those vars are used. Well, there's an easy solution there: Hungarian notation! (ducks und

Re: local $@ has an unwanted side effect

2008-03-22 Thread Mark J. Reed
erl6, which has a real "try" instead. If the eval'ed code fails, the eval itself just fails right along with it; so there's no need for a split along the lines of $! vs [EMAIL PROTECTED] -- Mark J. Reed <[EMAIL PROTECTED]>

What's the current state of the onion?

2008-03-22 Thread Mark J. Reed
), and some chunks of p6 have been backported into 5.10 via "use features". So, is there a consensus recommendation on the current best way to play around with something approximating the current state of the design? -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Musings on operator overloading

2008-03-26 Thread Mark J. Reed
uot; is just shorthand for "x + -y". -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Musings on operator overloading

2008-03-26 Thread Mark J. Reed
On Wed, Mar 26, 2008 at 1:06 PM, TSa <[EMAIL PROTECTED]> wrote: > > 1 + a(x)²! Seems like a mathematician would be inclined to write that one as this instead: 1 + a²(x)! But I'm not suggesting that you try to make (a**2)(x) work for (a(x))**2 in Perl. :) -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Musings on operator overloading

2008-03-26 Thread Mark J. Reed
nd leave the rest of us alone? :) Oh, and I've always mentally filed -x as shorthand for (-1*x); of course, that's an infinitely recursive definition unless -1 is its own token rather than '-' applied to '1'. Maybe I should have adopted dc(1)ese and spelled it _1. -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Musings on operator overloading

2008-03-27 Thread Mark J. Reed
Is it just me, or is all this talk about precedence and functions vs operators vs methods creating a niggling sensation in anyone else's head? It feels like we're in the vicinity of another one of them Big Simplifying Idea things. Unfortunately, I don't have the actual Big Idea, so it could just

Re: Integerizing a rat involves truncating its tail

2008-03-28 Thread Mark J. Reed
to be generalized to non-integers, since there is nothing in the above formulae that requires integral inputs. f mod 1 would then return the fractional part of a number, for instance. -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Integerizing a rat involves truncating its tail

2008-03-28 Thread Mark J. Reed
... If you have a rational number and need to turn it into an integer, best be explicit about how you want the conversion done. I'd almost be tempted to have no default coercion there, but that'd break too much ported code. -- Mark J. Reed <[EMAIL PROTECTED]>

Query re: duction and precedence.

2008-03-29 Thread Mark J. Reed
In general, is [op] (p1,p2,p3,p4...) expected to return the same result as p1 op p2 op p3 op p4... including precedence considerations? That is, should [**](2,3,4) return 2^(3^4)=2^81, or (2^3)^4 = 4096? -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Query re: duction and precedence.

2008-03-29 Thread Mark J. Reed
You anticipated me. So, is there a core method for foldl/foldr/inject/reduce, or do you have to roll your own as in p5? On 3/29/08, Larry Wall <[EMAIL PROTECTED]> wrote: > On Sat, Mar 29, 2008 at 10:18:53PM -0400, Mark J. Reed wrote: > : In general, is > : > :

Re: Query re: duction and precedence.

2008-03-30 Thread Mark J. Reed
seful, so I've never been swayed by arguments from "what is it good for?"... On 3/30/08, Darren Duncan <[EMAIL PROTECTED]> wrote: > Mark J. Reed wrote: > > You anticipated me. So, is there a core method for > > foldl/foldr/inject/reduce, or do you have to roll y

Re: Query re: duction and precedence.

2008-03-31 Thread Mark J. Reed
, i.e., (2^(3^4)) > > Etc. > > - > Hugh Miller > e-mail: [EMAIL PROTECTED] > > > -Original Message- > From: Darren Duncan [mailto:[EMAIL PROTECTED] > Sent: Sunday, March 30, 2008 2:00 AM > To: p6l > Subject: Re: Query re: duction and precedence.

Re: question on max | min op

2008-04-01 Thread Mark J. Reed
On Tue, Apr 1, 2008 at 5:39 AM, Mark J. Reed <[EMAIL PROTECTED]> wrote: > Perl5, all the builtin "functions" are really defiend as operators, "defined", even. (However fiendishly.) Anyway, "function" vs "operator" is mostly a difference in termin

Re: question on max | min op

2008-04-01 Thread Mark J. Reed
all the builtin "functions" are really defiend as operators, including "print" etc. But you can always call an operator as if it were a function/method, and in most cases you will. pugs> [1,2,3].max 3 pugs> min(1,2,3) 1 -- Mark J. Reed <[EMAIL PROTECTED]>

Re: question on max | min op

2008-04-01 Thread Mark J. Reed
I sit corrected. Guess that's one of the places pugs is out of date. On 4/1/08, Patrick R. Michaud <[EMAIL PROTECTED]> wrote: > On Tue, Apr 01, 2008 at 05:39:36AM -0400, Mark J. Reed wrote: > > On Tue, Apr 1, 2008 at 1:44 AM, Xiao Yafeng <[EMAIL PROTECTED]> wrote: &g

Re: cross operator and empty list

2008-04-04 Thread Mark J. Reed
h X basically is with preserved > order. > > Regards, TSa. > -- > > The Angel of Geometry and the Devil of Algebra fight for the soul > of any mathematical being. -- Attributed to Hermann Weyl > -- Sent from Gmail for mobile | mobile.google.com Mark J. Reed <[EMAIL PROTECTED]>

Re: Conceptual questions about Objects

2008-04-04 Thread Mark J. Reed
You have completely lost me, John. What the heck are you asking? $obj.foo: calls public method "foo" on the object referenced by $obj. $.foo shorthand for calling "foo" on self (in scalar context). As I understand it, although I could be confused, these have absolutely nothing to do with w

Re: Nomenclature Question - BEGIN etc.

2008-04-09 Thread Mark J. Reed
ocks? CO> They control in what phase of compilation/runtime the code runs in. I don't know, "phase" sounds too specific to me. Does the catching of an exception really bring us into a new phase of execution? What about the LAST time through a loop? etc. -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Nomenclature Question - BEGIN etc.

2008-04-09 Thread Mark J. Reed
e a closure and have traits, which aren't necessarily these particular ones... -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Nomenclature Question - BEGIN etc.

2008-04-10 Thread Mark J. Reed
"traits" is also problematic; it says what they are, but not really > what they do. They're really "come froms" with predefined names that > are automatically called at the appropriate time. So I think perhaps > the best term for them might be something more like "event blocks", > blocks that are called if and when a particular event happens. That's > a more user-oriented definition. > > Larry > -- Sent from Gmail for mobile | mobile.google.com Mark J. Reed <[EMAIL PROTECTED]>

Re: Nomenclature Question - BEGIN etc.

2008-04-10 Thread Mark J. Reed
escription, which fails to convey anything about the semantics. So maybe "event tags" and "event blocks", with the combination of the two constituting an "event handler"? Also: a CB reference? Really? (Y)our age is showing. :) -- Mark J. Reed <[EMAIL PROTECTED]>

Re: Nomenclature Question - BEGIN etc.

2008-04-10 Thread Mark J. Reed
On Thu, Apr 10, 2008 at 7:41 PM, Brandon S. Allbery KF8NH <[EMAIL PROTECTED]> wrote: > On the other hand, that may be the answer right there: "when-blocks". We have those already: given...when. -- Mark J. Reed <[EMAIL PROTECTED]>

  1   2   3   4   5   >