Bug 3198 - Caller of Signature.toString(String) should be aware that it won't work for '$' separated top-level types (1G4QB2S)
Summary: Caller of Signature.toString(String) should be aware that it won't work for '...
Status: RESOLVED WONTFIX
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 2.0   Edit
Hardware: All Windows NT
: P3 normal (vote)
Target Milestone: 2.0 M6   Edit
Assignee: Olivier Thomann CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2001-10-10 22:51 EDT by Jerome Lanneluc CLA
Modified: 2002-05-10 15:04 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jerome Lanneluc CLA 2001-10-10 22:51:09 EDT
Signature.toString(String) has been changed to handle '$' in inner types signatures. However it means that
	this would not work for top-level types that contains a '$' in their names (which the language allows).

	So callers of Signature.toString(String) should be aware of this limitation.

NOTES:

PM (11/20/00 3:42:30 PM)
	Indeed, binary signatures are ambiguous in presence of $ names. They could denote either a member type (likely) or
	a toplevel type with a dollar name (this is legal but hopefully not frequent). The distinction cannot be done until
	resolving signatures, which is not done by the model in general, and would be really expensive.

	Maybe this could be done, in case the name contains a $ ?

JBL (11/21/00 11:10:18 AM)
	Note from MA:
		The class and interface wizards now discourage names containing '$'

DA (6/20/01 1:29:16 PM)
	Problem still exist in build 0.125.
Comment 1 DJ Houghton CLA 2001-10-23 23:51:15 EDT
PRODUCT VERSION:
	VAME 013

Comment 2 Olivier Thomann CLA 2002-03-07 17:35:33 EST
This note has been added to the javadoc of this method:
 * Note: This method assumes that a type 
signature containing a <code>'$'</code>
 * is an inner type signature. While this is correct in 
most cases, someone could 
 * define a non-inner type name containing a <code>'$'</code>. 
Handling this 
 * correctly in all cases would have required resolving the signature, which 
 * 
generally not feasible.

I consider this as enough to close this PR. We cannot do more than 
this.
Ok to close?
Comment 3 Jerome Lanneluc CLA 2002-03-08 09:12:17 EST
Adding the comment is good, but the problem is still there.
The fix would require to do a lookup to know if the type is an inner type or 
not. This would be too expensive.
So the bug should not be closed: it's going to be a known problem (in case 
someone runs into it, which is less likely to happen).
Comment 4 Olivier Thomann CLA 2002-03-26 13:27:35 EST
Then this problem should be closed as WONTFIX. There is no need to keep it open if we don't intend to 
fix it.
Comment 5 Olivier Thomann CLA 2002-05-10 15:02:26 EDT
As this problem is not intended to be fixed, we can close this PR as WONTFIX. There is absolutely no 
need to keep it open.