Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Periodic Table of the Operators

13 views
Skip to first unread message

Mark Lentczner

unread,
May 26, 2004, 6:30:25 PM5/26/04
to perl6-l...@perl.org
All -

Awhile back, I saw Larry Wall give a short talk about the current
design of Perl 6. At some point he put up a list of all the operators -
well over a hundred of them! I had a sudden inspiration, but it took a
few months to get around to drawing it...

http://www.ozonehouse.com/mark/blog/code/PeriodicTable.html

- Mark

Mark Lentczner
http://www.ozonehouse.com/mark/
markl (at) glyphic (dot) com

Luke Palmer

unread,
May 26, 2004, 6:50:38 PM5/26/04
to Mark Lentczner, perl6-l...@perl.org
Mark Lentczner writes:
> All -
>
> Awhile back, I saw Larry Wall give a short talk about the current
> design of Perl 6. At some point he put up a list of all the operators -
> well over a hundred of them! I had a sudden inspiration, but it took a
> few months to get around to drawing it...
>
> http://www.ozonehouse.com/mark/blog/code/PeriodicTable.html

LOL! That's fantastic! We _must_ put it on dev.perl.org.

I can't help myself but to correct it, though :-)

The shiftoids: >> , << , >>= , and <<= are actually spelled
+>> , +<< , +>>= , and +<<= .

You're of course missing many textaveries. We'll just call them
"undiscovered."

What you call "adverbial", ":", should actually be named "everything
else" :-).

The "derefables", &{…}, &{…}, @{…}, and ${…} don't actually
exist. They are actually contextegens, &(…), %(…), @(…), and
$(…), and let's not forget ::(…).

The quotables probably shouldn't be written, e.g. q(…), since
parentheses are no longer valid delimiters.

You're missing "zip" (the operator is ¦ ), though I don't know what
class that falls in.

What do the numbers in the upper-right mean?

This is great stuff. :-)

Luke

Luke Palmer

unread,
May 26, 2004, 6:53:11 PM5/26/04
to Mark Lentczner, perl6-l...@perl.org
Luke Palmer writes:
> Mark Lentczner writes:
> > All -
> >
> > Awhile back, I saw Larry Wall give a short talk about the current
> > design of Perl 6. At some point he put up a list of all the operators -
> > well over a hundred of them! I had a sudden inspiration, but it took a
> > few months to get around to drawing it...
> >
> > http://www.ozonehouse.com/mark/blog/code/PeriodicTable.html

Oh, right, and the noble vectors are wrong, unless something's changed
under my nose. It's really:

»op« hyper-operator
«list of words» synonym for qw

So there's really only one noble vector, and we're not even calling it
"vector" anymore. :-)

Luke

Mark Lentczner

unread,
May 26, 2004, 7:00:49 PM5/26/04
to perl6-l...@perl.org, Luke Palmer
> LOL! That's fantastic! We _must_ put it on dev.perl.org.
Thank you. You are welcome to put it on dev.perl.org.

> I can't help myself but to correct it, though :-)

Please do. It was clear that many discussions happened after the TAKE
6 list, my primary reference. I will be happy to update it in a few
days.

> What do the numbers in the upper-right mean?

Relative precedence: See the key in the lower left corner.

- Mark

Uri Guttman

unread,
May 26, 2004, 7:15:11 PM5/26/04
to Mark Lentczner, perl6-l...@perl.org
>>>>> "ML" == Mark Lentczner <ma...@glyphic.com> writes:

ML> http://www.ozonehouse.com/mark/blog/code/PeriodicTable.html

very cool!

bugs: <, lt say greater. same in reverse for >, gt

the fonts for the little things in the corners could be a bit larger or
clearer.

s/anonamizer/anonymizer/

a few other words like 'termplars' don't make much sense to me.

~ (and friends) is either unary or binary but not prefix. i would keep
prefix for those operators than can also be postfix (which limits it to
++ and --). (almost ?) all unary operators are prefix (this week).

so the upper left thingy could be B(inary), U(nary), T(rinary),
Pr(efix), Po(stfix)

this will be very nice when it is debugged and fleshed out some more. i
am sure there will be interesting arguments on how to put them in the
columns. are you going to predict any new operators based on missing
boxes as mendeleev did? :)

can't wait to see larry and damian's take on it. :)

uri

--
Uri Guttman ------ u...@stemsystems.com -------- http://www.stemsystems.com
--Perl Consulting, Stem Development, Systems Architecture, Design and Coding-
Search or Offer Perl Jobs ---------------------------- http://jobs.perl.org

David Landgren

unread,
May 27, 2004, 3:40:07 AM5/27/04
to perl6-l...@perl.org
Mark Lentczner wrote:
> All -
>
> Awhile back, I saw Larry Wall give a short talk about the current design
> of Perl 6. At some point he put up a list of all the operators - well
> over a hundred of them! I had a sudden inspiration, but it took a few
> months to get around to drawing it...
>
> http://www.ozonehouse.com/mark/blog/code/PeriodicTable.html

Nice. Now to find a large enough printer to be able to pin it up on the
wall. One minor quibble, in the "Quasi Operators" section there's a
typo: s/Anonamizer/Anonymizer/

David

> - Mark
>
> Mark Lentczner
> http://www.ozonehouse.com/mark/
> markl (at) glyphic (dot) com
>


--
Commercial OS breeds commerce, whereas free OS breeds freedom,
the only thing more dangerous and confusing than commerce.
-- Michael R. Jinks, redhat-list, circa 1997

Matthew Walton

unread,
May 27, 2004, 4:37:37 AM5/27/04
to Mark Lentczner, perl6-l...@perl.org
Mark Lentczner wrote:

> All -
>
> Awhile back, I saw Larry Wall give a short talk about the current design
> of Perl 6. At some point he put up a list of all the operators - well
> over a hundred of them! I had a sudden inspiration, but it took a few
> months to get around to drawing it...
>
> http://www.ozonehouse.com/mark/blog/code/PeriodicTable.html

Now that is truly a work of art. I look forward to seeing it evolve (and
the corrections already suggested being made). And I can also see myself
printing it out and putting it on the wall for use the moment I can get
my hands on a Perl 6 compiler. Finally a use for the colour laser
printer in the office...

Well done.

Gabriel Ebner

unread,
May 26, 2004, 6:34:32 PM5/26/04
to perl6-l...@perl.org
Hello,

Mark Lentczner wrote:
> http://www.ozonehouse.com/mark/blog/code/PeriodicTable.html

What's periodic about it?
Otherwise, _nice_ table.

Gabriel.

--
Gabriel Ebner - reverse "ta.renbeleirbag@eg"

Stéphane Payrard

unread,
May 27, 2004, 6:30:02 AM5/27/04
to perl6-l...@perl.org
Le Thu, May 27, 2004 at 12:34:32AM +0200, le valeureux mongueur Gabriel Ebner a dit:

> Hello,
>
> Mark Lentczner wrote:
> > http://www.ozonehouse.com/mark/blog/code/PeriodicTable.html
>
> What's periodic about it?

We hope it will be periodically updated. :)

> Otherwise, _nice_ table.

indee.d

>
> Gabriel.

--
stef

Mark Lentczner

unread,
May 28, 2004, 2:26:27 AM5/28/04
to perl6-l...@perl.org
Thanks for all the comments. I started this thing as a goof, but I can
already see that it will serve dual purposes. Presenting information
in such a form can lead people to further insights and questions.
Deborah Pickett's comments in this thread are an example. (For some
real inspiring examples, see Edward Tufte's "Visual Explanations".)

To answer some comments:

> What's periodic about it?

and


> We hope it will be periodically updated. :)

I am preparing a second edition incorporating the corrections. While I
don't anticipate updating the chart this frequently in general, I would
like it to be mostly accurate at the start. Thereafter I'd be happy to
update it when Michael Lazzaro publishes the next version of the
operator list. (Perhaps he can give me a heads up and we'll strive for
a simultaneous release!)

> I'd like to have this on a big poster, once it's up to date. Perhaps
> you can set up a Cafepress store for this?
I will just as soon as the second edition is complete.

> a few other words like 'termplars' don't make much sense to me.

The group names are, admittedly, flights of fancy. Not all of them
make sense, some are deliberate jokes, and many just sound funny to me.
"Declars" seems to be a term in use 'round these parts. Some of the
items in Michael's list were named "terms". The "Templars" were
crusading monks in the Middle Ages. And so I arrived at "Termplars".
Then "Bazaars" just came naturally. You weren't expecting any logic to
this, were you?

- Mark

Mark Lentczner
http://www.ozonehouse.com/mark/
ma...@glyphic.com

Mark Lentczner

unread,
May 28, 2004, 7:18:16 PM5/28/04
to perl6-l...@perl.org
Not to beat a dead horse, but....

I've updated the Periodic table with almost all the changes that people
here sent me, as well as reading a few more threads and references.
This will be the last update for some time. I'll be uploading a
version to cafepress so people can get posters, tee-shirts and mouse
pads since so many people have asked for it. Check back on the chart's
blog page ( http://www.ozonehouse.com/mark/blog/code/PeriodicTable.html
) in a few days for the details. (I won't post that info here - I
don't mean to clog this mailing list with my frivolity.)

Lastly, in Apocalypse 3, Larry says:

"Operator precedence should be as simple as possible. Perl's precedence
table currently has 24 levels in it. This might or might not be too
many. We could probably reduce it to about 18 levels, if we abandon
strict C compatibility of the C-like operators."

The chart currently has 29 precedence levels (from left to right in the
chart) - which was based on various writings about the operators,
inferences drawn from examples (such as 1|2|3 + 4), any my own guesses.
I can't wait to see how this gets down to 18! Or even back to Perl
5's 24...

- Mark

0 new messages