X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=lib%2FZOOM%2FIRSpy%2FNode.pm;h=9d2f5c784fef3cc62eacaf16d7da4ed4c6932002;hb=0106545dd91706b8db717e072e48baf03b151a8f;hp=f912b94217a843c7d62477c3f1d25db8b9fd71c3;hpb=fed17a90a142f7183d556bbe7b8754d0f0ad1a48;p=irspy-moved-to-github.git diff --git a/lib/ZOOM/IRSpy/Node.pm b/lib/ZOOM/IRSpy/Node.pm index f912b94..9d2f5c7 100644 --- a/lib/ZOOM/IRSpy/Node.pm +++ b/lib/ZOOM/IRSpy/Node.pm @@ -6,6 +6,7 @@ use 5.008; use strict; use warnings; +use Scalar::Util; =head1 NAME @@ -57,13 +58,15 @@ changed. sub new { my $class = shift(); my($name, @subnodes) = @_; - return bless { + my $this = bless { name => $name, subnodes => \@subnodes, address => undef, # filled in by resolve() previous => undef, # filled in by resolve() next => undef, # filled in by resolve() }, $class; + + return $this; } =head2 name()