On 5/6/05, Juerd <[EMAIL PROTECTED]> wrote: > To try and make it easier to pick (ASCII) operators, a simple table of > what's given away and what's available. Please let me know if there are > any mistakes.
Thanks! Here's an annotated bit for each ?. > If anyone knows how to fill in the "???" parts, be my guest! > ! not none() ??? Nope. In order to create those, you just need to say none(). There is no operator form. > !! AVAILABLE? AVAILABLE? Given prefix:<?>, I suppose that is available. > @@ AVAILABLE? AVAILABLE Yep. > $$ AVAILABLE? AVAILABLE Nope. Not in term position. I hardly think it would be a good idea to make an operator out of it (or even a single $), however. > % hash mod > %% AVAILABLE? AVAILABLE? Yes. > \\ AVAILABLE? AVAILABLE Uh huh. > == AVAILABLE? num eq Fortunately yes. Let's keep it that way. > --> AVAILABLE AVAILABLE? I suppose it is. That would destroy Damian's favorite little idiom: while ($x --> 0) {...} But I don't think that's a huge loss. :-) > <-> don't touch it, I'm going to use this for -> is rw :) In operator position. In term position it is a single-quoted -. > ?? AVAILABLE? ternary Yep. > :: namespace ternary That's "class sigil" in term position. Separating namespaces never have preceding whitespace, so they're always part of some larger term. > \w+ infix only > x passive repeat > xx passive repeat > X active repeat ??? > XX active repeat ??? Those two haven't been blessed, and, though I don't have the message, I think I remember Larry being a little hesitant about adding those. > Y zip() > many still available! > > With double characters (like ~~), "AVAILABLE?" means that if we start > using that, stacking of the single thing will start requiring > whitespace, as with = and == in $foo = =$fh) > > "ws?" means that whitespace may be needed for disambiguation. > > I left out colon and semicolon because they're too special to fit in a > term|op table. I think it's more than safe to assume they're taken :) Um, yes. > <> is more flexible than {}, [] and () because it's a quoting operator > (the inside is not an expression). > > I think it's best to ignore entirely the fact that we can use more > triple character proper operators :) Why the %!@ would you ignore that!? :-) Luke