# For single inheritance. sub new { if (@ISA && $ISA [0] -> can ("new")) { return shift -> SUPER::new (@_) } else { return bless \(my $foo) => shift; } }