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

Bug 355441

Summary: illegal bytecode for team constructor with declared lifting and field access
Product: [Tools] Objectteams Reporter: Stephan Herrmann <stephan.herrmann>
Component: OTJAssignee: Project Inbox <objectteams.otj-inbox>
Status: NEW --- QA Contact:
Severity: normal    
Priority: P3    
Version: 2.0   
Target Milestone: ---   
Hardware: Other   
OS: Linux   
Whiteboard:
Attachments:
Description Flags
Test none

Description Stephan Herrmann CLA 2011-08-22 16:51:41 EDT
The following teams:

team class T1 {
    protected class R playedBy B {}
    private R f;
    T1(R r) { this.f = r; }
}
team class T2 extends T1 {
    T1(B as R r) { super(b); }
}

produce ilegal bytecode causing an IllegalAccessError at runtime.
Apparently we try to access field f from a contructor that has
been copied from T1 to T2.

Even if the field has default visibility the compiler has problems
with generating a valid stack map attribute.
Comment 1 Stephan Herrmann CLA 2011-08-22 17:02:35 EDT
Created attachment 201957 [details]
Test

Here are two tests to witness the issues at hand.