sub frobnicate { my ($ref) = @_; $$ref =~ s/foo/bar/g; return; }