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

Bug 337754

Summary: Xtend2 class overriding a void method generates error
Product: [Modeling] TMF Reporter: Esa Ryhänen <erules>
Component: XtextAssignee: Jan Koehnlein <jan>
Status: CLOSED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: jan, tmf.xtext-inbox
Version: 2.0.0Flags: jan: indigo+
Target Milestone: M6   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Esa Ryhänen CLA 2011-02-21 14:01:37 EST
Build Identifier:  I20100608-0911

Overriding a void method defined in a supertype in a Xtend2 class produces a type error on the return type.

Reproducible: Always

Steps to Reproduce:
1. Create a Java class:

package pkg;
public class ExtendedClass {
	void meth() {}
} 

2. Create a Xend2 class:

package pkg
class MyClass extends ExtendedClass {
	override void meth() {}
}

3. The void return type in the xtend file is error marked with message "The return type is incompatible with void pkg.ExtendedClass.meth()".
Comment 1 Jan Koehnlein CLA 2011-02-23 05:01:37 EST
Fix pushed to MASTER
Comment 2 Karsten Thoms CLA 2017-09-19 17:13:21 EDT
Closing all bugs that were set to RESOLVED before Neon.0
Comment 3 Karsten Thoms CLA 2017-09-19 17:24:51 EDT
Closing all bugs that were set to RESOLVED before Neon.0