in reply to Re^2: Subroutines not working right
in thread Subroutines not working right

I notice you had an argument. If you need a "reference with arguments", create a small anon routine
$func = \&foo; -vs- $func = sub { foo(1) };