Community
Participate
Working Groups
Please have a look at this example code: public class StepIntoLambda { public static void main(String[] args) { Runnable r = () -> { doSomething(); }; r.run(); } public static void doSomething() { System.out.println("Hello World"); } } First Issue =========== I was assuming that no step filtering applies when "Use Step Filters" is disabled. But when stepping into r.run() the behavior depends on the check state of the "Step through filters" checkbox, even though that checkbox is *disabled* together with the "Use Step Filters" setting and, hence, the entire preference page. This is very confusing and seems inconsistent. Second Issue ============ The help description of the hard to understand "Step through filters" checkbox says: "This option controls step filters to always return from a filtered location or step through to a non-filtered location. For example, if java.util is a filtered location, stepping into code in HashMap could result in a call-back to your application code to check the equality of an object. If you choose to Step through filters a step into would end up in your application code. However, when the Step through filters option is disabled, a step into HashMap would behave like a step over." In my code above, I think there's nothing that should be filtered out by any of the default filters, whether Step Filtering is enabled or not. So, why should this weird "Step through filters" checkbox make any difference at all in my case? Third Issue =========== If "Step through filters" is checked and I step into the r.run() call, why is the debugger's first stop *in* the doSomething() method and not in the lambda body where doSomething() is being called? Fourth Issue ============ When I change the lambda to this: Runnable r = () -> { System.out.println(); doSomething(); }; I.e., when I insert a call *before* the method call that was ignored by the debugger (see issue three), only then the debugger stops on that inserted call, and then, when stepping further, stops on the doSomething() *call*. === What's the reason for all this? Is this a combination of bugs? Or is it complete misunderstanding on my end?
Is it possible that you triage this bug and give some feedback? Thank you ;-)
(In reply to Eike Stepper from comment #1) > Is it possible that you triage this bug and give some feedback? > > Thank you ;-) Will investigate!
Thanks! Please don't hesitate to ask if you find my description unclear...
(In reply to Eike Stepper from comment #0) > Too many issues here :) Answering some of them for which I could find the answer quickly - Yes, ideally only the top filter section should be shown as disabled. I don't see this filter preference being used for below check boxes in code. As the first sentence is method call it just goes inside and as stated in fourth issue it stops if there is any other statement there.
If you enable "Use Step Filters", Uncheck "Step through Filters" and disbale "Use Step Filters" , it does not stop at doSomething(), so something in java base itself is getting filtered and hence it comes back to the next executable statement inside doSomething or sysout inside run.
No time to work on this right now.
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant. -- The automated Eclipse Genie.
None of the reported issues is resolved!