modify( \$val ); sub modify { my $ref = shift; $$ref ++; # or whatever } #### modify( $val ); sub modify { $_[0] ++; # or whatever. }