perldebuggingpadre

Padre: how to view/examine Perl's special variables?


Sorry if this is a newbie question. I can't seem to find a response for this question:

In Padre, how do I view/examine the values of Perl "special variables" (like $_, or $/, for example?)

It seems that the "view" button lists a variable's value only if you highlight that variable in the editor. But Perl's special variables are not part of the explicit program code.

TIA - Helen


Solution

  • Have you tried highlighting them in the parts that matter to your code? The thing is that the special vars change all the time depending on the context so it'll be hard to understand what they mean.

    Example:

    sub Something
    {
    $_; <<< highlight this
    @_; <<<< or this
    #do something
    $value = shift;
    
    }