use strict; use warnings; use BaseModule qw( function1 function2 ); { no warnings 'overriden'; # I think that's the right one. my $old_function1 = \&function1; *function1 = sub { print "I am the overriden function\n"; $old_function1->( @_ ); }; }