I wonder if it might be appropriate for the precedence table to mention this unexpected (by me) interaction?
No, I don't think so. The ':' isn't an operator, so it has nothing to do with precedence. It doesn't belong in a precedence table. Determining whether something is an operator (or part of an operator) or not isn't dealt with with the operator precedence table.
Since the word ‘attribute’ does not occur in perlop or perlsyn, and since no other punctuation mark requires a visit to perlfunc to figure out how it parses
But you only find something about attributes in perlfunc because my was specially added to perlfunc
; my isn't a function. The details are in perlsub
, where you would also go for punctuation as prototypes and some cases of parenthesis.
Is there any unified list of officially undefined things?
Not that I know of. But by all means, feel free to write up a list and submit is as a patch. Writing documentation doesn't require any coding language, which means most people can do it.
Are you posting in the right place? Check out Where do I post X? to know for sure.
Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
<code> <a> <b> <big>
<blockquote> <br /> <dd>
<dl> <dt> <em> <font>
<h1> <h2> <h3> <h4>
<h5> <h6> <hr /> <i>
<li> <nbsp> <ol> <p>
<small> <strike> <strong>
<sub> <sup> <table>
<td> <th> <tr> <tt>
Snippets of code should be wrapped in
<code> tags not
<pre> tags. In fact, <pre>
tags should generally be avoided. If they must
be used, extreme care should be
taken to ensure that their contents do not
have long lines (<70 chars), in order to prevent
horizontal scrolling (and possible editor
Want more info? How to link
or How to display code and escape characters
are good places to start.