0

I am running some program through StepRequest with following code.

EventRequestManager mgr = vm.eventRequestManager();
StepRequest st=mgr.createStepRequest(event.thread(),StepRequest.STEP_LINE,StepRequest.STEP_OVER);            
st.setSuspendPolicy(EventRequest.SUSPEND_ALL);
st.enable(); 

On StepEvent I am getting location of StepEvent using event.location().lineNumber().But the problem is, I am getting same line number for multiple StepEvents which should not be possible as I have given STEP_LINE as parameter for creation of StepRequest. But I can see those StepEvents with same line number differ on calling event.location().codeIndex() I want to know why I am getting such unusual results.

rainyday
  • 353
  • 3
  • 17
  • To answer your question, we would need to see the implementation of at least `mgr.createStepRequest(...)`. Please provide a [MCVE]. – Turing85 Jun 09 '18 at 22:04
  • @Turing85 Its defined in java api https://docs.oracle.com/javase/7/docs/jdk/api/jpda/jdi/com/sun/jdi/request/EventRequestManager.html#createStepRequest(com.sun.jdi.ThreadReference,%20int,%20int) – rainyday Jun 09 '18 at 22:09

0 Answers0