use warnings FATAL => 'all'; use strict; my $VERSION = '0.01'; my $program = $0; my $system = `hostname`; my $count = 1; print STDERR "Version $VERSION of $program, running on $system\n"; test_subroutine(); exit; sub test_subroutine { my $subroutine = (caller(0))[3]; if ($count < 2 ) { print "one\n"; } elsif ($count = 2) { # ERROR HERE print "HA!\n"; } else { print "three!\n"; } }