Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 360419 - The constructor Delegate() is undefined
Summary: The constructor Delegate() is undefined
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: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-10-10 05:59 EDT by pf yu CLA
Modified: 2017-02-23 14:19 EST (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description pf yu CLA 2011-10-10 05:59:28 EDT
Build Identifier: 201110090901

The constructor Delegate() is undefined

Reproducible: Always

Steps to Reproduce:
1. Check out project "org.eclipse.edt.eunit.test" from kan-cvs.
2. Add java generator to the project.
3. Clean the whole workspace.
4. The error exists in:
fvt.delegates.TestDelegate01Lib.java
Comment 1 Brian Svihovec CLA 2011-10-10 14:17:57 EDT
The TestDelegate01Lib library seems to have issues with JavaGen for 2 variations:

1) testDelegateAsINParameter1a - 
generates:
AnyBoxedObject<org.eclipse.edt.javart.Delegate> eze$Temp3 = EAny.ezeWrap(new org.eclipse.edt.javart.Delegate());
		
with the error:
the constructor is undefined

2) testDelegateAsINOUTParameter - 
generates:
new org.eclipse.edt.javart.Delegate("testerForINOUT", this, String.class) = EString.ezeCast(eze$Temp1.ezeUnbox());

with the error:
The left-hand side of an assignment must be a variable

Commenting out these two variations should make the rest of the library usable, so I am lowering this to a Normal Severity and changing the priority to P1.
Comment 2 Jing Qian CLA 2011-10-10 17:32:00 EDT
PengFei,

Please do NOT comment out the test case, as it will be hard to find it later

please use LogResult.skip("Bug360419") instead for these 2 test cases.
Comment 3 Jeff Douglas CLA 2011-10-20 16:58:21 EDT
I have updated javagen to handle delegates, HOWEVER ... this testcase is invalid because it is trying to pass the name of a function as an inout (and out) delegate parameter. This is not allowed and validation needs to prevent this.

Think about it. How can the name of a function be modified by inout or out?
Comment 4 Paul Harmon CLA 2011-11-07 15:15:51 EST
This was fixed indirectly by Bug 362587. The function is now considered to be a value type and so cannot be passed to the inout/out reference parm (delegate).
Comment 5 pf yu CLA 2011-11-18 00:04:54 EST
Verified in build 201111170946 & closed.