-
Enhancement
-
Resolution: Fixed
-
P3
-
None
-
None
Since we can’t reasonably hide/transform the generated name, the only approach I could see for aligning temp var names with tool-ids is to add a callback to the API to generate the temp var name. Maybe:
void setTempVariableNameGenerator(BiFunction<Integer, Integer, String> generator);
Update: the id is visible to StackTraceElement.getFileName() queries so must also be internal and thus configurable.
void setTempVariableNameGenerator(BiFunction<Integer, Integer, String> generator);
Update: the id is visible to StackTraceElement.getFileName() queries so must also be internal and thus configurable.
- blocks
-
JDK-8130451 JShell API: add temp variable short-cut for last expression value
- Open
- relates to
-
JDK-8130452 JShell tool: create tool-ids for snippets with keyspaces for start-up, normal, and errors
- Resolved