Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 326689 - [compiler] inferred callout not working with overloads and same-named callin method
Summary: [compiler] inferred callout not working with overloads and same-named callin ...
Status: VERIFIED FIXED
Alias: None
Product: Objectteams
Classification: Tools
Component: OTJ (show other bugs)
Version: 0.7.1   Edit
Hardware: Other Linux
: P3 normal (vote)
Target Milestone: 0.8 M3   Edit
Assignee: Stephan Herrmann CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-09-30 11:50 EDT by Stephan Herrmann CLA
Modified: 2010-11-10 19:06 EST (History)
0 users

See Also:


Attachments
fix (2.51 KB, patch)
2010-09-30 12:13 EDT, Stephan Herrmann CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Stephan Herrmann CLA 2010-09-30 11:50:39 EDT
From http://www.eclipse.org/forums/index.php?t=msg&th=197535&start=0&S=406fa41b7995a015a0d146c658fb332a

When a base class has two methods with the same name, a bound role cannot
callin bind one overload and also use inferred callout to the other overload.

The compiler wrongly flags
Method askForType(char[][]) cannot be called explicitly; is a callin method (OTJLD 4.2(d)).

At seems that the check for the 'callin' modifier does not respect overloading
and prematurely aborts callout inference.
Comment 1 Stephan Herrmann CLA 2010-09-30 12:13:30 EDT
Created attachment 179978 [details]
fix

This patch fixes the issue basically by just swapping the order
of callout inference and checking the 'callin' flag.

See witness in test3117_inferredCallout10()
Comment 2 Stephan Herrmann CLA 2010-09-30 12:15:01 EDT
Fix has been committed as r923.
Comment 3 Stephan Herrmann CLA 2010-11-10 18:37:17 EST
Verified for 0.8 M3 using build 201011100445