Skip to main content



      Home
Home » Modeling » TMF (Xtext) » How to visualize grammar generated from Xtext in AntlrWorks
How to visualize grammar generated from Xtext in AntlrWorks [message #948566] Thu, 18 October 2012 02:34 Go to next message
Eclipse UserFriend
Hi,
we have a system with custom language (which hasn't any relationship with Java, it uses its own parser etc.) and I would like to use Eclipse as an editor for this language.

So I created model in Xtext for that language (it is called Majic, but please don't ask me who "invented" this name :-). There were neither errors nor warnings in model so I started Eclipse application with Majic language support and opened one valid file. But there were errors, so I can see my Xtext model is wrong.

My question is how to visualize or debug my Xtext model. Which is the best practice how to looking for errors in model? I tried to open it in AntlrWorks and start debugging, but I hanged, because it needs DebugAbstractInternalAntlrParser. Of course I tried to create it, but without success.

Please, is there any article or hints, how to debug model created in Xtext? I haven't found anything.

Thank you.

[Updated on: Fri, 19 October 2012 03:05] by Moderator

Re: How to visualize grammar generated from Xtext in AntlrWorks [message #948873 is a reply to message #948566] Thu, 18 October 2012 09:15 Go to previous messageGo to next message
Eclipse UserFriend
I hope, this post helps: http://blog.dietmar-stoll.de/2011/08/xtext-grammar-visualization.html
Re: How to visualize grammar generated from Xtext in AntlrWorks [message #949663 is a reply to message #948873] Fri, 19 October 2012 03:08 Go to previous message
Eclipse UserFriend
Thank you Michael. But I've already read it and this is not what I'm looking for.

If I follow the article and run Check Grammar in AntlrWorks everything is OK. So from syntactical point of view it is OK. But if I run my project in Eclipse and open valid Majic file, it will show me somewhere in the middle of the file that semicolon is missing. But semicolon is required by several rules and I don't have any clue where is a bug in my model file.

Maybe there is another way how to debug models, but I don't know it. I found that AntlrWorks can draw Parser Trees, so I thought it may help to solve my problem.

But I'm completely open to other best practices how to "debug" Xtext models.
Previous Topic:Generating enums with methods (and fields)
Next Topic:Customizing Serializer
Goto Forum:
  


Current Time: Wed Jul 23 16:24:10 EDT 2025

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

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

Back to the top