use typename
[prop.git] / app / willard / parser.h
blob73e36f7969046574d52861e9e0d8941b79ae1598
1 ///////////////////////////////////////////////////////////////////////////////
2 // This file is generated automatically using Prop (version 2.3.5),
3 // last updated on Jun 18, 1997.
4 // The original source file is "parser.ph".
5 ///////////////////////////////////////////////////////////////////////////////
7 #define PROP_REWRITING_USED
8 #define PROP_STRCMP_USED
9 #define PROP_PARSER_USED
10 #define PROP_QUARK_USED
11 #include <propdefs.h>
12 #line 1 "parser.ph"
13 #ifndef parser_h
14 #define parser_h
16 #include <AD/automata/iolexerbuf.h>
17 #include "willard-ast.h"
20 // This is the interface of the relation calculus parser.
22 #line 10 "parser.ph"
23 #line 20 "parser.ph"
24 class QueryParser : public LR1Parser {
25 public:
26 ////////////////////////////////////////////////////////////////////////////
27 // Parser table type definitions
28 ////////////////////////////////////////////////////////////////////////////
29 typedef LR1Parser Super;
30 typedef Super::Offset Offset;
31 typedef Super::State State;
32 typedef Super::Rule Rule;
33 typedef Super::Symbol Symbol;
34 typedef Super::ProductionLength ProductionLength;
35 typedef Super::ShortSymbol ShortSymbol;
36 typedef Super::EquivMap EquivMap;
37 enum { INITIAL_STACK_SIZE_ = 256,
38 MAX_STACK_SIZE_ = 8192
40 protected:
41 ////////////////////////////////////////////////////////////////////////////
42 // Semantic value stack
43 ////////////////////////////////////////////////////////////////////////////
44 union QueryParser_semantic_stack_type * t__, * bot__;
45 int stack_size__;
46 int heap_allocated__;
47 public:
48 ////////////////////////////////////////////////////////////////////////////
49 // Constructor and parsing method
50 ////////////////////////////////////////////////////////////////////////////
51 QueryParser();
52 virtual void parse();
53 void action_driver(const Rule);
54 private:
55 void adjust_stack(int);
56 void grow_semantic_stack();
57 #line 11 "parser.ph"
58 QueryParser(const QueryParser&);
59 int line_no;
60 Exp query;
62 ErrorAction error_report(const char * message); // error reporting
63 public:
64 IOLexerBuffer lexbuf; // a lexer stream buffer
65 int get_token(); // method generated by Prop
66 Exp read(); // method to a read a query
67 #line 20 "parser.ph"
69 #line 20 "parser.ph"
70 #line 20 "parser.ph"
73 #endif
74 #line 23 "parser.ph"
76 ------------------------------- Statistics -------------------------------
77 Merge matching rules = yes
78 Number of DFA nodes merged = 0
79 Number of ifs generated = 0
80 Number of switches generated = 0
81 Number of labels = 0
82 Number of gotos = 0
83 Adaptive matching = disabled
84 Fast string matching = disabled
85 Inline downcasts = disabled
86 --------------------------------------------------------------------------