Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 119435

Summary: [compiler] FileSystem.findClass operates / to \ transformation on type names in specific cases only
Product: [Eclipse Project] JDT Reporter: Maxime Daniel <maxime_daniel>
Component: CoreAssignee: Maxime Daniel <maxime_daniel>
Status: CLOSED WORKSFORME QA Contact:
Severity: normal    
Priority: P3    
Version: 3.2   
Target Milestone: ---   
Hardware: PC   
OS: Windows All   
Whiteboard:

Description Maxime Daniel CLA 2005-12-06 11:31:13 EST
I20051129-1200
Namely, p/X.class is unchanged while p/q/X.class is transformed into p\q\X.class.
Moreover, the remainder of the code expects the forward slash, which questions the use of the transformation. 
The transformation only happens under Windows.
Bug 119430 is impacted as well (in that if no conversion happened, ClasspathLocation.fetchAccessRestriction would not have to convert back to /).
Comment 1 Maxime Daniel CLA 2006-01-06 11:03:07 EST
That transformation is only one of a few that adapt our behavior to the underlying filesystem. Especially, quite a few defensive 'replace / by \ or the other way round depending on java.io.File.separator' exist in the code.
The approach of bug 119430, which maps whichever file separator to the '/' that we use in access rules hence seems sound.
The current code addresses the needs of Windows/non Windows filesystems impedence in a satisfactory way and no refactoring is needed.
Comment 2 Maxime Daniel CLA 2006-10-11 03:55:12 EDT
Tidying.