in reply to trouble with packages/eval/variable-scoping
I don't have your problems, but only tested on my mobile with termux.
use v5.12; use warnings; say $]; my $t = 42; sub foo { say eval $_[0] } foo('$t'); -UUU:----F1 t_dyna_scope.pl All L4 (Perl) ---- -*- mode: compilation; default-directory: "~/perl/" \ -*- Compilation started at Thu Aug 29 18:00:33 perl t_dyna_scope.pl 5.036000 42 Compilation finished at Thu Aug 29 18:00:33
Cheers Rolf
(addicted to the Perl Programming Language :)
see Wikisyntax for the Monastery
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: trouble with packages/eval/variable-scoping (caller's scope)
by LanX (Saint) on Aug 30, 2024 at 09:22 UTC |