Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 353455 - DeclarationExpressions with wrong qualifiers in IR
Summary: DeclarationExpressions with wrong qualifiers in IR
Status: CLOSED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: EDT (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 blocker (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 352125
  Show dependency tree
 
Reported: 2011-07-30 14:08 EDT by Scott Greer CLA
Modified: 2017-02-23 14:17 EST (History)
3 users (show)

See Also:


Attachments
Box.egl (4.65 KB, text/plain)
2011-07-30 14:08 EDT, Scott Greer CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Scott Greer CLA 2011-07-30 14:08:15 EDT
Created attachment 200623 [details]
Box.egl

In Box.egl (attached), there is a function with a local field declared as follows:

td Widget { tagName="td", children = [child] };

In the IR, this is expanded out into a series of AssignmentStatements, one of which has no qualifier and the other which has a ThisExpression qualifier.

I'm writing this up on the assumption that's an IR problem, however, I suppose it may be a problem with the generator(s).
Comment 1 Scott Greer CLA 2011-07-30 14:11:04 EDT
This problem manifests as the following code in JavaScript:

	var td = null;
	td = new egl.egl.ui.rui.Widget();
	this.setTagName("td");
        this.setChildren([child].setType("Tegl/ui/rui/Widget;"));

As it happens, both td and the local part are both Widgets, so the resulting code winds up invoking the setTagName, setChildren methods on the part rather than the td variable.
Comment 2 Paul Harmon CLA 2011-08-18 13:28:39 EDT
This has been fixed with an update to MemberAccessImpl
Comment 3 Scott Greer CLA 2011-09-12 09:13:01 EDT
Verified.