Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer

Re: Derive a variable name from a variable?

by Laurent_R (Canon)
on Dec 17, 2015 at 07:18 UTC ( #1150590=note: print w/replies, xml ) Need Help??

in reply to Derive a variable name from a variable?

Don't write Perl code that computes variable names. It can be done (it is called symbolic references), but it is bad practice, it is frowned upon for several good reasons, and it is bad enough that it will trigger a warning.

Use a hash instead.

Update: Just as you can shoot a bullet into your own foot or put your cat into the microwave oven, but you should not do it.

  • Comment on Re: Derive a variable name from a variable?

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1150590]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (5)
As of 2023-01-27 15:27 GMT
Find Nodes?
    Voting Booth?

    No recent polls found