Bug 22783

Summary: Unexpected null in compiler error message
Product: [Eclipse Project] JDT Reporter: Peter Burka <peter_burka>
Component: CoreAssignee: Olivier Thomann <Olivier_Thomann>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: 2.0   
Target Milestone: 2.1 M5   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Peter Burka CLA 2002-08-23 12:13:39 EDT
I changed the visibility of a method, and the following error message appeared 
in my task list:

Kind	Status	Priority	Description	Resource	In Folder
	Location
Error			The method init(null) from the type 
com.ibm.etools.ctc.flow.ui.OperationPicker is not visible
	FlowImplEventPropertyPage.java
	com.ibm.etools.ctc.flow.ui/src/com/ibm/etools/ctc/flow/ui/properties
	line 821 in FlowImplEventPropertyPage.tableSelectionChanged()

This looks like there was some sort of error in constructing the method 
signature for the error message.
Comment 1 Peter Burka CLA 2002-08-23 12:15:31 EDT
Note that the sender was actually sending init(null).
Comment 2 Philipe Mulet CLA 2002-08-24 08:22:36 EDT
Seems we are reconstructing the signature from the argument types instead of 
the parameter types.
Comment 3 Olivier Thomann CLA 2002-09-06 14:49:24 EDT
I think the problem is more that the NullBinding readable name is null. When you
use null as a parameter, the corresponding binding is the NullBinding. This
would explain why null is displayed in the method signature.
Comment 4 Philipe Mulet CLA 2002-10-11 11:42:31 EDT
null is used as an argument, but the method declared parameter isn't of type 
NullBinding. This is what my comment was meaning.

So I am wondering why we seem to be recreating a signature using the invocation 
argument types as opposed presenting the declared method signature.
Comment 5 Olivier Thomann CLA 2003-01-13 11:34:14 EST
Indeed the problem method binding was created using the parameter types. We
should instead use the methodBinding.parameters.
I check the fix.
Comment 6 Olivier Thomann CLA 2003-01-13 13:06:30 EST
Changes reviewed by Kent.
Fixes and released in 2.1 stream.
Tests updated.
Comment 7 David Audel CLA 2003-02-11 10:24:29 EST
Verified.