Skip to main content



      Home
Home » Modeling » TMF (Xtext) » Xtext tracing
Xtext tracing [message #1858475] Tue, 04 April 2023 09:20 Go to next message
Eclipse UserFriend
Hi

I want to test tracing with Xtext, from the example found here:
https://www.typefox.io/blog/generate-traced-code-with-xtext

When I do use the @TracedAccessors annotations with my ecore factory, I get hundreds of warning:
Quote:

The generated method '....ImTemplate.MyDslTraceExtensions._generateName(ImStructType,
Function<String, String>)' is not associated with a source element.
The producing active annotation should use 'setPrimarySourceElement'.


One big difference of my model vs. the example model is, that it is no having a Xtext grammar, just a ecore file.
Is this related to the warnings?

regards
Frank
Re: Xtext tracing [message #1858477 is a reply to message #1858475] Tue, 04 April 2023 09:27 Go to previous messageGo to next message
Eclipse UserFriend
no, this looks more like an issue with the impl of the aa.
if this is ignored, a warning or an error can be configured in the projects xtend compiler settings
Re: Xtext tracing [message #1858478 is a reply to message #1858477] Tue, 04 April 2023 09:31 Go to previous message
Eclipse UserFriend
=> add

context.setPrimarySourceElement(it, context.getPrimarySourceElement(annotatedClass));

to all 3 addMethod bodies in the processor might solved it
Previous Topic:Create a jar/war file in xtext with websupport
Next Topic:Identation in xtend template with tracing
Goto Forum:
  


Current Time: Tue Jul 08 22:52:54 EDT 2025

Powered by FUDForum. Page generated in 0.03927 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top