Last change
on this file since 25584 was 25584, checked in by davidb, 12 years ago |
Initial cut an a text edit area for GLI that supports color syntax highlighting
|
File size:
1.1 KB
|
Line | |
---|
1 | This directory contains a scanner and parser for the Java programming language.
|
---|
2 |
|
---|
3 | You need the parser generator CUP v0.10j (or newer) for the parser to work.
|
---|
4 | Use the Makefile to generate the lexer and parser, or type:
|
---|
5 |
|
---|
6 | jflex unicode.flex
|
---|
7 | jflex java.flex
|
---|
8 | java java_cup.Main -interface < java12.cup
|
---|
9 | javac JavaParser.java TestLexer.java
|
---|
10 |
|
---|
11 |
|
---|
12 | The parser can be tested with:
|
---|
13 | java JavaParser <inputfiles>
|
---|
14 |
|
---|
15 | The scanner (without parser attached) can be test with:
|
---|
16 | java TestLexer <inputfiles>
|
---|
17 |
|
---|
18 |
|
---|
19 | files:
|
---|
20 |
|
---|
21 | unicode.flex
|
---|
22 | JFlex specification for the Unicode preprocessing phase
|
---|
23 | (see section 3.3 of the Java Language Specification).
|
---|
24 | Demonstrates how to implement a FilterReader with JFlex.
|
---|
25 |
|
---|
26 | java.flex
|
---|
27 | JFlex specification for the "real" Java 1.2 lexer.
|
---|
28 |
|
---|
29 | java12.cup
|
---|
30 | CUP specification for the Java 1.2 parser
|
---|
31 | Copyright (C) 1998 by C. Scott Ananian <[email protected]>
|
---|
32 | (with small modifications to interface with the Lexer)
|
---|
33 |
|
---|
34 | JavaParser.java
|
---|
35 | a simple main class to run the parser (no other useful output though)
|
---|
36 |
|
---|
37 | TestLexer.java
|
---|
38 | a simple test driver for the scanner, produces debug output
|
---|
39 |
|
---|
40 | lexer-output.good
|
---|
41 | lexer output for input file TestLexer.java for testing
|
---|
Note:
See
TracBrowser
for help on using the repository browser.