Integration with Eclipse Ganymede
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   JJ_Treadway
Posted On:   Sunday, January 29, 2012 07:12 PM

I am having trouble integrating ANTLR with Eclipse. I've tried two approaches, both of which have failed. First approach: I followed the instructions in this video and got to the point of being able to create a *.g file in my Eclipse project, but Eclipse got stuck on "building workspace" forever and anything I tried to do (i.e. save, run, exit) would just bring up a window saying "waiting for operation 'building workspace' to complete". It wouldn't let me cancel the building workspace operation either. I would end up having to force quit Eclipse in the Task Manager. Second approach: I downloaded ANTLRWorks and used it to make a simple grammar called "test2". I then us   More>>

I am having trouble integrating ANTLR with Eclipse. I've tried two approaches, both of which have failed.



First approach:

I followed the instructions in this video and got to the point of being able to create a *.g file in my Eclipse project, but Eclipse got stuck on "building workspace" forever and anything I tried to do (i.e. save, run, exit) would just bring up a window saying "waiting for operation 'building workspace' to complete". It wouldn't let me cancel the building workspace operation either. I would end up having to force quit Eclipse in the Task Manager.



Second approach:

I downloaded ANTLRWorks and used it to make a simple grammar called "test2". I then used ANTLRWorks to generate the files "test2Lexer.java" and "test2Parser.java". I put those two files into a new Eclipse project, but there are errors on the line "import org.antlr.runtime.*;" and on all references to classes within that package. I then right click on "default package" (where the two source files are stored in Eclipse) and select "Import" and import the file "antlr-3.4-complete-no-antlrv2.jar" that I downloaded from antlr.org. Eclipse no longer marks the "import org.antlr.runtime.*;" line as an error, but it still marks all references to classes in that package as errors.



Can anybody tell me what's wrong with either of these approaches and how to fix it?

   <<Less

Re: Integration with Eclipse Ganymede

Posted By:   hushcat_asdf  
Posted On:   Friday, February 17, 2012 07:22 AM

Thank you for the sensible critique. Me and my neighbor were just preparing to do some research about this. We got a grab a book from our local library but I think I learned more from this post. I am very glad to see such great information being shared freely out there. Canyons Real Estate
About | Sitemap | Contact