[antlr-interest] Getting Started -> NoClassDefFoundError: Main/class

Terence Parr parrt at cs.usfca.edu
Wed Dec 28 14:43:19 PST 2005


On Dec 28, 2005, at 2:42 PM, Kenny Tilton wrote:
>   java Main
>  Exception in thread "main" java.lang.NoClassDefFoundError: Main/class
>
> Of course there /is/ a class called Main in the code geenrated by  
> antlr, so I am at a loss. Unfortunately I have barely done a  
> thousand lines of Java (ten years ago) so I am stuck on what I am  
> sure is just a simple mistake.

Your classpath has to have the dir in it that has Main.class  
file. :)  Make sure it has '.' (dot) for example.

Ter



More information about the antlr-interest mailing list