| Summary: | [evaluation] Evaluations are not working on intermediate frames for lambda variables | ||
|---|---|---|---|
| Product: | [Eclipse Project] JDT | Reporter: | Gayan Perera <gayanper> |
| Component: | Debug | Assignee: | Gayan Perera <gayanper> |
| Status: | VERIFIED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | CC: | sarika.sinha |
| Version: | 4.21 | ||
| Target Milestone: | 4.23 M2 | ||
| Hardware: | All | ||
| OS: | All | ||
| See Also: |
https://git.eclipse.org/r/c/jdt/eclipse.jdt.debug/+/189357 https://git.eclipse.org/r/c/jdt/eclipse.jdt.debug/+/189415 https://git.eclipse.org/c/jdt/eclipse.jdt.debug.git/commit/?id=0a20bdb9a62333eb8cde7b16e801fbb5246da79d https://git.eclipse.org/c/jdt/eclipse.jdt.debug.git/commit/?id=530846db516280ca88dbc80e098107ce37501477 |
||
| Whiteboard: | |||
| Bug Depends on: | |||
| Bug Blocks: | 578069 | ||
Any plans for M2? Working on some completions issues Sarika, I will try if i can work on this for M3, otherwise we have to push this into next release. New Gerrit change created: https://git.eclipse.org/r/c/jdt/eclipse.jdt.debug/+/189357 New Gerrit change created: https://git.eclipse.org/r/c/jdt/eclipse.jdt.debug/+/189415 Gerrit change https://git.eclipse.org/r/c/jdt/eclipse.jdt.debug/+/189415 was merged to [master]. Commit: http://git.eclipse.org/c/jdt/eclipse.jdt.debug.git/commit/?id=0a20bdb9a62333eb8cde7b16e801fbb5246da79d Gerrit change https://git.eclipse.org/r/c/jdt/eclipse.jdt.debug/+/189357 was merged to [master]. Commit: http://git.eclipse.org/c/jdt/eclipse.jdt.debug.git/commit/?id=530846db516280ca88dbc80e098107ce37501477 Thanks Gayan. I20220126-1800 |
Take import java.util.List; import java.util.concurrent.CompletableFuture; import java.util.concurrent.ExecutionException; import java.util.stream.Collectors; import java.util.stream.Stream; public class Inspect { public void hoverOverLocal(String[] names) throws InterruptedException, ExecutionException { CompletableFuture<List<String>> future = CompletableFuture.supplyAsync(() -> { return Stream.of(names).filter(s -> { try { return CompletableFuture.supplyAsync(() -> { return containsDigit(s.codePointAt(0), names.length); }).get(); } catch (Exception e) { return false; } }).collect(Collectors.toList()); }); future.get(); } private boolean containsDigit(int c, int length) { return Character.isDigit(c) && c == length; } public static void main(String[] args) throws InterruptedException, ExecutionException { new Inspect().hoverOverLocal(new String[] {"name"}); } } Place a line breakpoing at java.lang.CharacterDataLatin1.isDigit(int) and debug the code. Now move debug frame selection to Inspect.lambda$2(String, String[]) in the debug view. And try to evaluate "names" variable in the editor or in Debug shell. It says name cannot be resolved. But hovering over the names variable works. probably it is fixed by Bug 573547.