in reply to Re: Closure Over Scalar?
in thread Closure Over Scalar?
This doesn't work as you intended. The bareword FIXED_STRING in a hash access will be used as the string 'FIXED_STRING' , not as an expression that would evaluate the constant. To use the constant, you need to prevent it from being treated as a bareword. $persistent{$x}{+FIXED_STRING} is one possibility.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^3: Closure Over Scalar?
by QM (Parson) on Feb 19, 2021 at 14:19 UTC |
In Section
Seekers of Perl Wisdom