forked from daveagp/java_visualize
-
Notifications
You must be signed in to change notification settings - Fork 0
/
TODO
44 lines (34 loc) · 2.05 KB
/
TODO
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
graphics! either encode primitive operations as text, or send frames
short hashes for urls
caches for past visualizations (probably don't cache 10 times to see if randomized/time-dependent)
figure out suspend/resume (e.g. for exception handling, data structures)
allow selective visualization of contents of some built-in classes
(suggested by Jeff Kang)
When the slider has focus, press "j" (for jump), or another key, and follow that with a number.
That would teleport you to the line of code that corresponds to that number.
The difficulty is that multiple Frames-Objects pair images can belong to 1 line of code.
If it's possible, perhaps show a list of all the pairs.
The pairs could be shortened, compacted, and/or summarized to fit on the screen.
Maybe it just lists the step numbers that correspond to that line number.
Then, a person would be allowed to choose the Frames-Objects pair to skip to.
Or, just pick the earliest Frames-Objects pair that will appear from the current step.
That is, "what's the next step that will take me to this line of code?".
(suggested by James Vanderhyde)
improve flow when a return statement is followed by an assignment of that value:
the value disappears and then comes back
(suggested by Brad Vander Zanden)
If a statement modifies the value of a variable/object, it would be helpful to highlight that value/object so that the student can instantly see what has been modified.
inner classes, local classes, anonymous classes, lambdas, captured final variables, this$ ...
- right now we show things exactly from JDWP, like Eclipse or NetBeans
- no way to recover all lambda arg names given current bytecode
- could desugar 2 frames into one and pass "this" to nicen a bit
- here's a class that throws a JWDP exception in both java 7 and 8
public class JWDP32 {
public static void main(String[] args) {
// x needs to be final, but not a compile-time constant
final int x = Math.random() < 2 ? 42 : -42;
Object anon = new Object(){int f(){return x;}};
class Local{int g(){return x;}}
Local loc = new Local();
}
}