Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » Subset of Xtext grammar
Subset of Xtext grammar [message #1856153] Wed, 23 November 2022 13:52 Go to next message
Klarise Hund is currently offline Klarise HundFriend
Messages: 22
Registered: October 2022
Junior Member
Hello,

I am considering the possibility of automatically generating Xtext grammar subsets. Starting from an Xtext grammar and some input (it could be a model, configuration file, etc.) that specifies the elements of the Xtext grammar I wish to include in the subset, I can use transformations to generate an Xtext grammar subset.
Based on your knowledge of Xtext and EBNF grammar, do you think this solution would be feasible, or would it be erroneous?

Thanks!
Re: Subset of Xtext grammar [message #1856160 is a reply to message #1856153] Wed, 23 November 2022 17:06 Go to previous message
Ed Willink is currently offline Ed WillinkFriend
Messages: 7655
Registered: July 2009
Senior Member
Hi

An Xtext grammar has an equivalent EMF model behind the scenes so you can certainly do transformations on one. (org.eclipse.ocl.examples.xtext2lpg uses MWE2 to sequence a cascade of 3 QVTo transformations to transform from an Xtext model to an LPG representation.)

Whether creating subsets is appropriate is another matter; it would require much more information to comment usefully.

Regards

Ed Willink
Previous Topic:Xtext 2.29.0 is released
Next Topic:Grammar: operation with optional left argument
Goto Forum:
  


Current Time: Fri Apr 19 07:14:01 GMT 2024

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

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

Back to the top