use Types::Standard qw(Int); use Devel::StrictMode qw(STRICT); my @array_of_ints; tie @array_of_ints, Int if STRICT; ...; # do stuff here