<?xml version="1.0" encoding="windows-1252"?>
<node id="1007788" title="Re: Passing a reference from a subroutine." created="2012-12-07 11:42:36" updated="2012-12-07 11:42:36">
<type id="11">
note</type>
<author id="622051">
toolic</author>
<data>
<field name="doctext">
This works:

&lt;c&gt;
use warnings;
use strict;
use Data::Dumper;

sub get_data {
    my @AoA;
    @AoA = (
        [(1, 2)],
        [(3, 4)],
    );
    #print Dumper(\@AoA);
    return \@AoA;  
}

my $alldata = get_data();
print Dumper($alldata);

__END__

$VAR1 = [
          [
            1,
            2
          ],
          [
            3,
            4
          ]
        ];
&lt;/c&gt;



&lt;ul&gt;
&lt;li&gt;[doc://perldsc]
&lt;li&gt;[http://sscce.org]
&lt;/ul&gt;
</field>
<field name="root_node">
1007775</field>
<field name="parent_node">
1007775</field>
</data>
</node>
