Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » M2T (model-to-text transformation) » [Acceleo 3.X] JMerge not used when generated code contains Java 5 annotations
[Acceleo 3.X] JMerge not used when generated code contains Java 5 annotations [message #755962] Thu, 10 November 2011 05:40 Go to next message
Sebastien GABEL is currently offline Sebastien GABEL
Messages: 6
Registered: July 2009
Location: Toulouse
Junior Member
Hello,

I would like to enforce the possibilities offered by my generated code.
For this purpose, I already use the protected area mechanism that works fine.
Now, I would like to introduce the JMerge @generated tags but I'm facing a problem : my generated code contains Java 5 annotations.

My generated code is :

/**
* @generated
*/
@SimpleMapping(InputType="object1", OutputType="object2")
public boolean myMethod(Object pInput, Object pOutput) {
.....
}

During a generation, I get two warnings :
The first comes from emf codegen :
A problem was detected while parsing a Java file Line 43: Syntax error, annotations are only available if source level is 1.5

The second from acceleo :
There seem to be some errors in one of the file 'MyClass.java', therefore JMerge can not be used.

JMerge fails in this case and has no effect as indicated by the warnings. My project compliance settings are OK for the generated project.

How can I solve this JMerge problem in Acceleo ? Maybe something to do before launching the generation ? Any advice would be appreciated.

Thanks in advance,

Sebastien

[Updated on: Thu, 10 November 2011 05:40]

Report message to a moderator

Re: [Acceleo 3.X] JMerge not used when generated code contains Java 5 annotations [message #756068 is a reply to message #755962] Thu, 10 November 2011 13:20 Go to previous message
Ed Willink is currently offline Ed Willink
Messages: 3844
Registered: July 2009
Senior Member
Hi

You might want to look at
https://bugs.eclipse.org/bugs/show_bug.cgi?id=308069.

Regards

Ed Willink
> Hello,
> I would like to enforce the possibilities offered by my generated code.
> For this purpose, I already use the protected area mechanism that
> works fine.
> Now, I would like to introduce the JMerge @generated tags but I'm
> facing a problem : my generated code contains Java 5 annotations.
Previous Topic:[Acceleo] Standalone application running error
Next Topic:[Xpand/Xtend 1] What future can Xpand/Xtend expect?
Goto Forum:
  


Current Time: Sat Apr 19 16:12:00 EDT 2014

Powered by FUDForum. Page generated in 0.11311 seconds