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

Bug 469769

Summary: [otdre] NPE when base guard calls isExecutingCallin()
Product: [Tools] Objectteams Reporter: Stephan Herrmann <stephan.herrmann>
Component: OTJAssignee: Stephan Herrmann <stephan.herrmann>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: stephan.herrmann
Version: 2.4   
Target Milestone: 2.5 RC   
Hardware: All   
OS: All   
Whiteboard:
Bug Depends on:    
Bug Blocks: 484164    

Description Stephan Herrmann CLA 2015-06-09 14:25:48 EDT
Test org.eclipse.objectteams.otdt.tests.otjld.api.Reflection.test924_isExecutingCallinCalled5() still fails under OTDRE.

I suspect that the team instance may not be properly in place when invoking isExecutingCallin(). If I remove this call we instead fail with StackOverflowError (since .equals() is intercepted which is used by the lifting infrastructure).
Comment 1 Stephan Herrmann CLA 2016-05-24 16:33:27 EDT
Turned out to be related to bug 493717 after all: where in the type hierarchy do we insert which code, and how are call chains constructed?

In particular: in that test we are binding to Object.equals(), which of course is not weavable. Instead, we insert a new dispatch method as T924iecc5.equals(), which starts off the call chain. But when we return from the team, _OT$callOrig() could not correctly dispatch. After bug 493717 we actually tried to call Object._OT$callOrig(), which - of course - does not exist.

Fixed by a new CreateSpecificSuperCallInCallOrigAdapter, which inserts an invokespecial towards the inherited unweavable method, wrapped between arg-unpacking and return boxing.

Released via commit f8337c36848c19866deb04d3d4124f6bba59ed7d
Comment 2 Stephan Herrmann CLA 2016-05-24 16:38:17 EDT
*** Bug 459269 has been marked as a duplicate of this bug. ***