:e should not show subscripted variables
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Mars |
Fix Released
|
Low
|
Matt Giuca |
Bug Description
The :e (show environment) display currently shows all local variables with subscripts (such as x:0:1). This means that it shows temporaries (a side-effect of bug #553758) and if a variable is assigned multiple times, it also shows all values the variable has ever had. For example:
?> x = 4
?> :e
Locals:
x:0 = 4
?> x = 5
?> :e
Locals:
x:0 = 4
x:0:1 = 5
Arguably, this is a good thing, because a) :e is supposed to be a developer-level output (sort of a debug feature), and b) it would help with diagnosing bugs like #553758 -- we probably want to delete temporaries as well as historical values for variables, and this would show if we had succeeded. But since the typedicts branch will require :e to use the existing evaluator (taking AST-level expression objects, which cannot have subscripts), my hand is forced. Change it so it shows user-level (un-annotated) variables from the non-SSA localtable:
?> x = 4
?> :e
Locals:
x = 4
?> x = 5
?> :e
Locals:
x = 5
Related branches
Changed in mars: | |
status: | Fix Committed → Fix Released |
Fixed in trunk r1194.