vscode-perl-debug icon indicating copy to clipboard operation
vscode-perl-debug copied to clipboard

local variables not showing up correctly

Open rmesser opened this issue 6 years ago • 1 comments

When debugging it seems that variables from the calling function show up, not the variables that are available in the current scope. For example, suppose I have a simple script like this:

my $test1 = 29;
my $test2 = 30;

my $result = Foo::add($test1, $test2);
say "result is $result";

When I am debugging in the main body of the script, Variables -> Local shows nothing. But then when I step into Foo::add, all of a sudden $test1 and $test2 do show up under Variables -> Local. It seems that the call to fetch the variables is using the wrong level, or something along those lines.

I also recorded a 40 second video to illustrate what I mean: https://vimeo.com/282946315

Thanks for your efforts by the way, it is handy to debug under VS Code.

rmesser avatar Aug 03 '18 00:08 rmesser

do you have padwalker installed? What OS + perl version and distribution + padwalker version? (I've added a test matrix to cover most of the platfor/perl versions - but padwalker is a yet a version)

raix avatar Dec 13 '18 20:12 raix