G'day purnak,

Years ago, when working on 32-bit systems, I used to get hexidecimal numbers (such as you posted: 9458b48) that would fit into 32 bits. Now, on a 64-bit system, I get hexidecimal numbers that won't fit into 32 bits (but will fit into 64 bits):

$ perl -E 'say []' ARRAY(0x7fd8278040b0)

Of course, 9458b48 will also fit into 64 bits. I'd be very wary of making any inferences regarding the system architecture based on the hexidecimal number.

Although you only asked about array references, there are many other types of references, that follow the same pattern. Here's some examples:

$ perl -E 'say for [], {}, \"", sub {}' ARRAY(0x7ff6d60040b0) HASH(0x7ff6d602bf70) SCALAR(0x7ff6d602c948) CODE(0x7ff6d602c960)

The ref function has a more complete list; perlref has, in its own words, "complete documentation about all aspects of references".

Finally, as an adjunct to ++Eily's reply, here's a recent post where the equality of references was used.

— Ken


In reply to Re: what do you infer from an array reference? by kcott
in thread what do you infer from an array reference? by purnak

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.