http://qs321.pair.com?node_id=405066


in reply to Re: Dynamically constructed function calls
in thread Dynamically constructed function calls

It has to be a scalar, but it doesn't need to be a variable. You can say
$f->${\("prefix_$key")}($atr);
However, using a variable is probably clearer.

Update: added the missing '$' pointed out by ikegami

--Dave
Opinions my own; statements of fact may be in error.