Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 355412 - Debug stops on breakpoint showing wrong EGL source file
Summary: Debug stops on breakpoint showing wrong EGL source file
Status: CLOSED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: EDT (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Justin Spadea CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-08-22 12:23 EDT by Kathy Carroll CLA
Modified: 2017-02-23 14:16 EST (History)
1 user (show)

See Also:


Attachments
Projects exported to archive file (511.87 KB, application/x-zip-compressed)
2011-08-22 12:23 EDT, Kathy Carroll CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Kathy Carroll CLA 2011-08-22 12:23:04 EDT
Created attachment 201936 [details]
Projects exported to archive file

I have two projects and each has a library named EString009.  I have the breakpoint set in the first project.  Debugging stops on the breakpoint indicating the correct line number; however, the source of the second project library is in the editor. 

Load the attached projects and set a breakpoint on line 92 of api.eglx_lang.EString009.egl.  

Debug eunitgen.RunAllTests_pgms
Comment 1 Justin Spadea CLA 2011-08-22 15:24:45 EDT
This is actually caused by JDT - they provide all the source lookup, and what's happening is for resource that do not end in .java they search if the path to the file can be found in the project, then they check the folders, and folders within folders, etc; if the file is not found it then does this check on dependent projects. So the problem is that the path "api/eglx_lang/EString009.egl" gets found when it checks "ECK.eunit.java/EGLSource/eunitgen". For .java files it only checks inside source folders, which is why it's not an issue with non-SMAP debugging.

Rather than open a defect on JDT and wait who knows how long for a fix (a fix that wouldn't be part of 3.6), I found a way to work around this. I now override the source director on the launch configuration when wrapping the debug target, which puts an EGL source lookup routine ahead of the Java routines, which checks the package fragment roots (EGLSource & eglars) along the EGL path of the originating project.

Fortunately this code was already written for RUI debugging, I just had to do some refactoring so that it gets shared between Java and RUI debugging.
Comment 2 Kathy Carroll CLA 2011-08-23 09:26:19 EDT
verified
Comment 3 Lisa Lasher CLA 2011-10-11 16:25:06 EDT
Closing this defect.