Bug 15423

Summary: JRE_LIB source attachment via properties does not work
Product: [Eclipse Project] JDT Reporter: Claude Knaus <Claude_Knaus>
Component: CoreAssignee: Philipe Mulet <philippe_mulet>
Status: RESOLVED WONTFIX QA Contact:
Severity: normal    
Priority: P3 CC: jerome_lanneluc
Version: 2.0   
Target Milestone: 2.0 M6   
Hardware: PC   
OS: Windows 2000   
Whiteboard:
Bug Depends on:    
Bug Blocks: 13581, 14113    

Description Claude Knaus CLA 2002-05-07 10:35:46 EDT
tested with 20020502 latest workspace:

  1) Make sure JRE_SRC is empty.
  2) Create a Java project.
  3) Open properties page on the rt.jar of the project.
  4) Create a new variable JRE_TEST_SRC and set it to some valid src.jar
  5) Open a class file in the rt.jar.
  6) Observe that the editor remains empty.

This blocks me to fully test a feature in M6: bug 13581
Comment 1 Claude Knaus CLA 2002-05-07 10:42:02 EDT
This seems not be specific to rt.jar. I just tried to detach a valid source 
(bootsrc.zip from boot.jar in org.eclipse.core.boot) and to reattach it.
The source stays detached.
Comment 2 Jerome Lanneluc CLA 2002-05-13 06:50:19 EDT
This works for me in build 20020508. For rt.jar, I had to make sure that the 
root path was not empty (this was not specified in the steps you gave).
For boot.jar, I was able to detach then reattach its source and then open a 
class and see its source.
Comment 3 Claude Knaus CLA 2002-05-13 11:33:14 EDT
I tried it in 20020508 on w2k:

Attaching seems to work now (tried with boot.jar) but when I detach,
the sources are remembered.

  1) Open VM.class from org.eclipse.core.boot.
  2) Verify that you can see the source.
  3) Close VM.class and remove the source attachment from boot.jar
  4) Open VM class again.
  5) Observe that the source is visible.
Comment 4 Claude Knaus CLA 2002-05-14 13:33:59 EDT
On linux-motif 20020508, attaching/detaching seems to work.
Comment 5 Claude Knaus CLA 2002-05-15 11:16:42 EDT
with 20020514-I and jdt.core patch on w2k and Linux-Motif:

SWT sources cannot be found (IClassFile.getSourceRange() always returns null).
However, with other jars like org.eclipse.boot/boot.jar or rt.jar, it works.
I suspect it must have to do with the specific location of the jar and/or the 
source of SWT.
Comment 6 Jerome Lanneluc CLA 2002-05-15 13:14:34 EDT
No, the problem is the swt classes were compiled without the source attribute.
Comment 7 Philipe Mulet CLA 2002-05-16 11:30:31 EDT
Closing