1 The TPTP parser is generated using ML-Yacc and relies on the ML-Yacc |
1 The TPTP parser is generated using ML-Yacc and relies on the ML-Yacc |
2 library to function. The ML-Yacc library is an external piece of |
2 library to function. The ML-Yacc library is an external piece of |
3 software that needs a small modification for use in Isabelle. The |
3 software that needs a small modification for use in Isabelle. The |
4 file "make_tptp_parser" patches the ML-Yacc library, generates the |
4 relationship between Isabelle and ML-Yacc is similar to that with |
5 TPTP parser, and patches that to conform to Isabelle's naming |
5 Metis (see src/Tools/Metis). |
6 conventions. |
6 |
|
7 The file "make_tptp_parser" generates the TPTP parser and patches it |
|
8 to conform to Isabelle's naming conventions. |
7 |
9 |
8 In order to generate the parser from its lex/yacc definition you need |
10 In order to generate the parser from its lex/yacc definition you need |
9 to have the ML-Yacc binaries. The sources can be downloaded via SVN as |
11 to have the ML-Yacc binaries. The sources can be downloaded via SVN as |
10 follows: |
12 follows: |
11 |
13 |
12 svn co --username anonsvn \ |
14 svn co --username anonsvn \ |
13 https://smlnj-gforge.cs.uchicago.edu/svn/smlnj/ml-yacc/trunk ml-yacc |
15 https://smlnj-gforge.cs.uchicago.edu/svn/smlnj/ml-yacc/trunk ml-yacc |
14 |
16 |
15 ML-Yacc is usually distributed with Standard ML of New Jersey, and its |
17 ML-Yacc is usually distributed with Standard ML of New Jersey, and its |
16 binaries can also be obtained as packages for some distributions of |
18 binaries can also be obtained as packages for some distributions of |
17 Linux. |
19 Linux. The script "make_tptp_parser" will produce a file called |
|
20 tptp_lexyacc.ML -- this is a compilation of the SML files (generated |
|
21 by ML-Yacc) making up the TPTP parser. |
18 |
22 |
19 The generated parser needs ML-Yacc's library. This is distributed with |
23 The generated parser needs ML-Yacc's library. This is distributed with |
20 ML-Yacc's source code, in the lib/ directory. |
24 ML-Yacc's source code, in the lib/ directory. The ML-Yacc library |
21 |
25 cannot be used directly and must be patched. The script |
22 Assuming that you've got the ml-lex and ml-yacc binaries, and have a |
26 "make_mlyacclib" takes the ML-Yacc library (for instance, as |
23 copy of the ML-Yacc sources in this directory, then running |
27 downloaded from the ML-Yacc repo) and produces the file ml_yacc_lib.ML |
24 "make_tptp_parser" will generate two files: |
28 -- this is a compilation of slightly modified files making up |
25 |
29 ML-Yacc's library. |
26 ml_yacc_lib.ML -- this is a compilation of slightly modified files |
|
27 making up ML-Yacc's library. |
|
28 |
|
29 tptp_lexyacc.ML -- this is a compilation of the SML files making up |
|
30 the TPTP parser. |
|
31 |
30 |
32 Nik Sultana |
31 Nik Sultana |
33 8th March 2012 |
32 9th March 2012 |