1sig lyaccshares.
2
3% Predicates required by grammar files
4kind gs type.     % grammar symbol type.
5type iconst int -> gs.
6type sconst string -> gs.
7type id string -> gs.    % universal identifier
8type rule decl -> o -> decl.  % rule clause.  The first param. is the
9type ==> gs -> (list gs) -> decl.   % The |- symbol for grammars
10infixl ==> 10.
11type binaryop gs -> gs -> gs -> string -> int -> o.  % precedence and type
12type implicitop gs -> gs -> string -> int -> o.      % juxtaposition
13type unaryop gs -> gs -> int -> o.
14type terminal gs -> o.
15type non_terminal gs -> o.
16type start_symbol gs -> o.
17type cfg (list decl) -> o.   % grammar rules
18type test int -> gs -> o.
19type ntnum int -> o.
20type first gs -> gs -> o.
21type letter, letnum, alltyp string -> o.
22type terminal_list (list gs) -> o.
23type nonterm_list (list gs) -> o.
24type comment_list (list string) -> o.
25type ary0 gs -> gs.
26type ary1 (A -> gs) -> gs.
27type ary2 (A -> B -> gs) -> gs.
28type ary3 (A -> B -> C -> gs) -> gs.
29type ary4 (A -> B -> C -> D -> gs) -> gs.
30type freshcopy gs -> gs -> o.   % avoids instantiating nonterminals!
31type comment string -> o.
32
33% Predicates required for internal parser generating
34type bofs, eofs, sprime,bols,eols   gs.   % beginning and end of file, beginning and end of line, extra start symbol.
35type eof_symbol string -> o.
36type linenum int -> gs.
37kind decl type.	  % declaration type for grammar rules.
38kind ch type.   % candidate handle type
39type printname A -> string -> gs -> o.
40type finderrline (list gs) -> (list gs) -> o.
41type print_tokens int -> (list gs) -> o.
42type tokchar string -> o.
43
44% Predicates needed at the top level
45type genparser A -> B -> o.
46type parseline gs -> A -> o.
47type parsefile string -> A -> o.
48type parse (list gs) -> (list gs) -> gs -> string -> o.
49type startparse gs -> (list gs) -> (list gs) -> gs -> string -> o.
50type generate_fc A -> o.
51type output_fcs out_stream -> (list gs) -> o.