Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 362214 - [Xtend] Xtend name conflicts in generated Java classes extending class with same name but from different package
Summary: [Xtend] Xtend name conflicts in generated Java classes extending class with s...
Status: CLOSED FIXED
Alias: None
Product: TMF
Classification: Modeling
Component: Xtext (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows 7
: P3 major (vote)
Target Milestone: SR2   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-10-27 11:48 EDT by Ingo Meyer CLA
Modified: 2017-09-19 17:58 EDT (History)
2 users (show)

See Also:
jan: indigo+


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ingo Meyer CLA 2011-10-27 11:48:28 EDT
Build Identifier: 20110609-2236

In Xtend 2.0.1.v201108151710 I have a similar error then bug https://bugs.eclipse.org/bugs/show_bug.cgi?id=345722.

When class a.Test extends class b.Test the fqn is removed in the generated java class and gives and cycle error.

Maybe there is a Unit test missing for that case? ;-)

Reproducible: Always

Steps to Reproduce:
1. make two classes

package org.eclipse.xtext.example.domainmodel.test1
class Test {}

package org.eclipse.xtext.example.domainmodel.test2
class Test extends org.eclipse.xtext.example.domainmodel.test1.Test {}

2. the generated "...test2.Test.java" will look like:

package org.eclipse.xtext.example.domainmodel.test2;

import org.eclipse.xtext.example.domainmodel.test1.Test;

@SuppressWarnings("all")
public class Test extends Test {
}

3. bamm... :)
Comment 1 Jan Koehnlein CLA 2011-10-27 13:07:39 EDT
I've just checked in some change to the ImportManager that should deal with this situation. Could not reproduce this any more: I now get a cyclic dependency error marker and no code is built. Please reopen if the problem remains.
Comment 2 Sebastian Zarnekow CLA 2011-10-28 02:17:52 EDT
Marked as fixed (see last comment)
Comment 3 Ingo Meyer CLA 2011-10-28 03:32:31 EDT
(In reply to comment #1)
> I've just checked in some change to the ImportManager that should deal with
> this situation. Could not reproduce this any more: I now get a cyclic
> dependency error marker and no code is built. Please reopen if the problem
> remains.

yes, now it works. Thanks a lot.
Comment 4 Karsten Thoms CLA 2017-09-19 17:47:03 EDT
Closing all bugs that were set to RESOLVED before Neon.0
Comment 5 Karsten Thoms CLA 2017-09-19 17:58:08 EDT
Closing all bugs that were set to RESOLVED before Neon.0