Javacc Eclipse Plug-In for Eclipse 3.0 to 3.5

Total Page:16

File Type:pdf, Size:1020Kb

Javacc Eclipse Plug-In for Eclipse 3.0 to 3.5

JavaCC Eclipse Plug-in for Eclipse 3.0 to 3.5 From: http://pagesperso-orange.fr/eclipse_javacc/ Last update 4 October 2009 - version 1.5.16 JavaCC plug-in is designed to help development of JavaCC applications. License : GPL / Cecill

You can download the last version here : EclipseJavaCC-1.5.16.zip (java 1.5) or from sourceforge http://sourceforge.net/projects/eclipse-javacc or use http://eclipse-javacc.sourceforge.net/ as an update site for Eclipse

The plugin needs Java 1.5 to run, sources contain Java 5.0 templates.

To install you must use Eclipse 3.4 Menu "Help" / "Software updates..." with Ganymede and Menu "Help" / "Install New Software..." with Galileo

If you want both a tutorial and a reference for JavaCC, Tom Copeland wrote a very nice book: http://generatingparserswithjavacc.com/ A really good book... this is the only good tutorial/reference on JavaCC.

It could have been a little more detailed on JavaCC internals and parsers theory but otherwise it's great; it has good examples as well as thorough explanations of key concepts.

Old versions : Version 1.5.10 : Work well with Java 1.5 and Eclipse 3.1 Version 1.1 for Eclipse 3.0.2 :rk.eclipse.javacc_1.1.1.zip (17/08/2005) My first version 1.0 was for Eclipse 2.1 :rk.eclipse.javacc_1.0.zip (09/07/2003) This plug-in provides :  Editor  Outline  Format (still to improve)  JavaCC JJTree JJDoc compilation, (see https://javacc.dev.java.net/)  JTB compilation, (You must provide your version of JTB see http://compilers.cs.ucla.edu/jtb/)  JavaCC, JJTree, JJDoc, JTB options  Problems reporting  Console for JavaCC outputs with hyperlinks to Errors and Warnings  Decoration of generated files  Navigation into rules definitions (open declaration)  Support Eclipse 3.1, Java 1.5, JavaCC4.0, JTB 132  Matching bracket highlight  Keyboard shortcuts : Comment lines Ctrl+/, Open declaration Ctrl+clic, Format Ctrl+Shift+F  JavaCC is launched in the same directory as the grammar files (to facilitate package handling)  More help is available with the plug-in via Eclipse menu Help / Help Contents. 04/10/09 New in 1.5.16 : Support Eclipse Variables in Builder and Options, keep jtb jar in preferences, use default jar when no jar is given. 07/09/09 New in 1.5.15 : JavaCC 5.0 new options, Galileo fix, Compiled with Java1.5 to support Mac OS X Change the released zip to be a zipped update site. 23/05/09 New in 1.5.14 Call hierarchy view 25/04/09 25/04/09 New in 1.5.14 (Marc Mazas) Updated JavaCC / JJTree / JTB options, New preferences , Enhanced formatting 13/07/08 New in 1.5.12 : Updated with JavaCC 4.1 Add Folding, Hover, Completion proposals, and project Cleaning. 08/07/07 New in 1.5.10 : Correct JJTREE_OUTPUT_DIRECTORY, NullPointerException 10/06/07 New in 1.5.9 : Correct javacc.jar to handle outputdirectory for JJDoc and bugs corrections 11/03/07 New in 1.5.7 : Correct suppress warnings and preserve unicode escape when formatting 26/11/06 New in 1.5.6 : Restore compatibility with Eclipse 3.1 and handle case where no src/bin dir are defined. 05/11/06 New in 1.5.5 : Java 1.5 and Eclipse 3.2.1, correct bug in console hyperlinks, basic content assistant 01/10/06 New in 1.5.4 : Suppress warnings in generated files, global preferences for colors 24/05/06 New in 1.5.3 : Correct plugin key conflict F3 27/03/06 New in 1.5.2 : Removed "exclude from build" and adopted Eclipse way, ie Build Path. 24/02/06 New in 1.5.1 : French version, ben ouais sauf que je n'ai pas encore traduit l'aide en français. 13/11/05 New in 1.4.0 : Update site, automatic format, java 1.4 .class files compatibility 31/10/05 New in 1.3.0 : JTB, Ctrl+clic, Wizard 28/08/05 New in 1.2.0 : Support Eclipse 3.1,support Java 1.5, matching bracket, comment lines Ctrl + / Launch JavaCC and JJTree from where the .jj or .jjt file are, Removed button on the toolbar (replaced with popup menu) 26/10/04 New in 1.1.0 : Support Eclipse 3., marker hover 28/07/05 New in 1.2.0 : Hyperlinks in Console 25/07/03 Version 1.0.0: First release for Eclipse 2.1 Quick Start 1) Create a new Java project and a package "foo" 2) Select package "foo" and create a new JavaCC file. Just accept all default settings. Beware templates files are for Java 1.5 (you must change in generated file to JDK_VERSION = 1.4 if you use java 1.4)

3) You have now a new JavaCC file, compiled with JavaCC and all generated java files in you project. Note that : - the generated files are decorated with a "G" and a "" to indicate the .jj file they come from, - there may be warnings from the Java Compiler (Eclipse doesn't like JavaCC generated code), - JavaCC console opens automatically.

4) Run the example Select "TestJavaCC" and menu "Run"/ "Run as..." / "Java application" Choose "eg1" for the main type. You can now test your JavaCC application : You can do the same with the template for JJTree : and also with the template for JTB: Feel free to signal any bug or suggest enhancement at [email protected] or at sourceforge.

Recommended publications