<?xml version="1.0" encoding="windows-1252"?>
<node id="69946" title="Re: References quick reference" created="2001-04-04 23:46:14" updated="2005-08-15 08:25:27">
<type id="11">
note</type>
<author id="27402">
lachoy</author>
<data>
<field name="doctext">
&lt;p&gt;Great summary. Personally, I find the following:&lt;/p&gt;

&lt;code&gt;
@{$aRefs[0]}   @{$aRefs{key}}   @{getArrayRef()}
%{$hRefs[0]}   %{$hRefs{key}}   %{getHashRef()}
&lt;/code&gt;

&lt;p&gt;&lt;b&gt;much&lt;/b&gt; cleaner and easier to read than:&lt;/p&gt;

&lt;code&gt;
@array       @$aRef
%hash        %$hRef
$array[0]    $$aref[0]
$hash{KEY}   $$href{KEY}
&lt;/code&gt;

&lt;p&gt;Maybe it's just me, but I've been using perl for 4+ 
years and I have never liked stringing the variable 
characters one after the other (&lt;code&gt;%$&lt;/code&gt;). 
Particularly epxressions like the third and fourth 
line in the second group above.&lt;/p&gt; 

&lt;p&gt;I've always thought that using the &lt;code&gt;@{ } %{ }&lt;/code&gt;
syntax more clearly and consistently evoked what I'm 
trying to say -- you can use it with variables, method
calls/subroutines, etc. I'm interested if other folks feel
differently -- it seems to be a matter of taste rather than
an opportunity to define yet another One True Way :-) &lt;/p&gt;

&lt;p&gt;Chris&lt;br&gt;
M-x auto-bs-mode&lt;/p&gt;</field>
<field name="root_node">
69927</field>
<field name="parent_node">
69927</field>
</data>
</node>
