title: Can this "Modern Perl" Data:Dumper example be fixed?
body: <p>The code is from "Modern Perl Fourth Edition", "Book version P1.0--October 2015".<br>
  It's in chapter 3 - page 81 of the paper version, under the heading "Debugging Nested Data Structures".  The book is also available in a PDF version that can be downloaded at no cost.</p>
  
  <pre><code>use Data::Dumper;
  
  my $complex_structure = {
     numbers =&gt; [ 1 .. 3 ];
     letters =&gt; [ 'a' .. 'c' ],
     objects =&gt; {
     breakfast =&gt; $continental,
     lunch =&gt; $late_tea,
     dinner =&gt; $banquet,
     },
  };
  
  print Dumper( $my_complex_structure );
  </code></pre>
  
  <p>"This might produce something like the following:"</p>
  
  <pre><code>$VAR1 = {
     'numbers' =&gt; [
                   1,
                   2,
                   3
                  ],
    'letters' =&gt; [
                  'a',
                  'b',
                   'c'
                 ],
    'meals' =&gt; {
        'dinner' =&gt; bless({...}, 'Dinner'),
        'lunch' =&gt; bless({...}, 'Lunch'),
        'breakfast' =&gt; bless({...}, 'Breakfast'),
    },
  };
  </code></pre>
  
  <p>First, there are errors in the "$complex_structure" code.<br>
  There should be a comma, not a semicolon after the "numbers" line.<br>
  The variables $continental, $late_tea, and $banquet are not declared or initialized.<br>
  Dumper() is called with a wrong name : "$my_complex_structure".<br><br>
  The variable $objects in the code somehow becomes 'meals'in the output.<br></p>
  
  <p>I'm not sure this is wrong, but wonder where the "bless"es come from.<br> Due to the errors, I can't really determine what the author meant to demonstrate, but "Objects" aren't covered until chapter 7 of the book<br></p>
  
  <p>Here is what I wrote as an attempt to fix the (simplified) example, considering material in earlier examples about hash references and anonymous hashes:</p>
  
  <pre><code>use Data::Dumper;
  
  my $continental = {entree =&gt; 'eggs', side =&gt; 'hash browns'};
  
  
  my $complex_structure =
  {
     numbers =&gt; [1 .. 3],
     letters =&gt; ['a' .. 'c'],
     objects =&gt; {
                    breakfast =&gt; $continental,          
                },
  };
  
  print Dumper($complex_structure);
  </code></pre>
  
  <p>I had an error in the previous call, and, after fixing it, this new code "works" in producing output as expected, but I'm still puzzled - especially about the "bless"es seen in the book's output.</p>
  
  <p>I have no experience with Data::Dumper.<br> 
  Does the original example make enough sense so that it can somehow be modified to run and produce what the author expected?   Should there be any "bless"es expected when something like "$complex_structure" in the book's example is dumped?</p>