#!/usr/bin/perl package main; use strict; use warnings; use Data::Dumper; my $foo = Foo->new; print Dumper $foo; # $VAR1 = bless( [], 'Foo' ); package Foo; use strict; use warnings; sub new{ my $class = shift; return bless [], $class; } 1;