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

Bug 362787

Summary: [Grammar][Editor] Cannot find compatible type for features although everything should be clear
Product: [Modeling] TMF Reporter: Christian Dietrich <christian.dietrich.opensource>
Component: XtextAssignee: Project Inbox <tmf.xtext-inbox>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: benjamin.schwertfeger, sebastian.zarnekow
Version: unspecifiedFlags: sebastian.zarnekow: juno+
Target Milestone: M4   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Christian Dietrich CLA 2011-11-03 08:45:36 EDT
Build Identifier: 2.1.0

We have a base grammar like this one

grammar org.xtext.example.otherdsl.OtherDsl with org.eclipse.xtext.common.Terminals

generate otherDsl "http://www.xtext.org/example/otherdsl/OtherDsl"

NamedElement:
	name=ID
;


and a grammar like

grammar org.xtext.example.mydsl.MyDsl with org.eclipse.xtext.common.Terminals

import "platform:/resource/org.xtext.example.otherdsl/src-gen/org/xtext/example/otherdsl/OtherDsl.ecore" as OTHER

generate myDsl "http://www.xtext.org/example/mydsl/MyDsl"

Model:
	A | B | C;
	
A:
	"a" name=ID
;

B:
	"b" name=ID
;

C:
	"c" name=ID
;

Dummy returns OTHER::NamedElement:
	A | B | C
;

This worked without any problems in 2.0.0
In 2.1.0 the Editor shows error markers for the three names
with the error message Cannot find compatible type for features

The workflow runs anyway. the content assist suggests name as a feature too.
The generated ecore is how i want int to be

Reproducible: Always
Comment 1 Sebastian Zarnekow CLA 2011-11-03 11:08:31 EDT
Does it work if you use the nsURI to import the EPackage?
Comment 2 Christian Dietrich CLA 2011-11-03 11:29:54 EDT
Same problem using the nsURI
Comment 3 Sebastian Zarnekow CLA 2011-11-10 15:36:50 EST
Fixed in master and maintenance.