use feature qw( current_sub ); my $fetch = sub { ... __SUB__->(); ... }; ... $fetch->(); ...