]> git.unchartedbackwaters.co.uk Git - francis/stp.git/commitdiff
removed symbol table from AST
authorvijay_ganesh <vijay_ganesh@e59a4935-1847-0410-ae03-e826735625c1>
Fri, 2 Oct 2009 22:27:30 +0000 (22:27 +0000)
committervijay_ganesh <vijay_ganesh@e59a4935-1847-0410-ae03-e826735625c1>
Fri, 2 Oct 2009 22:27:30 +0000 (22:27 +0000)
git-svn-id: https://stp-fast-prover.svn.sourceforge.net/svnroot/stp-fast-prover/trunk/stp@275 e59a4935-1847-0410-ae03-e826735625c1

src/AST/AST.h
src/parser/CVC.lex
src/parser/CVC.y
src/parser/parser.h [new file with mode: 0644]
src/parser/smtlib.lex
src/parser/smtlib.y

index c73525d9901da8e1fed8e8728048238a206983ec..d305ff19d29ecc9d30e65d263127c91a3e042f8c 100644 (file)
@@ -59,9 +59,6 @@ namespace BEEV
                         ASTNode::ASTNodeHasher, 
                         ASTNode::ASTNodeEqual> ASTNodeMultiSet;
 
-  //external parser table for declared symbols.
-  //FIXME: move to a more appropriate place
-  extern ASTNodeSet _parser_symbol_table;
 
   /***************************************************************************
    * Class BeevMgr.  This holds all "global" variables for the system, such as
index 30954d79ec2616002005656596d63b440e7d56ce..594a19a7a45c5896d12a739f2ddecf424fab875b 100644 (file)
@@ -8,7 +8,7 @@
  ********************************************************************/
 
 #include <iostream>
-#include "../AST/AST.h"
+#include "parser.h"
 #include "parseCVC_defs.h"
 
   using namespace std;
index 96ab73016e755e7fd2607f589bac79990995705a..90cdae10ddac264854551b1811b66d7cb9a9f6c8 100644 (file)
@@ -1,21 +1,22 @@
 %{
-/********************************************************************
- * AUTHORS: Vijay Ganesh
- *
- * BEGIN DATE: November, 2005
- *
- * LICENSE: Please view LICENSE file in the home dir of this Program
- ********************************************************************/
-// -*- c++ -*-
-
-#include "../AST/AST.h"
+  // -*- c++ -*-
+  /********************************************************************
+   * AUTHORS: Vijay Ganesh
+   *
+   * BEGIN DATE: November, 2005
+   *
+   * LICENSE: Please view LICENSE file in the home dir of this Program
+   ********************************************************************/
+  
+#include "parser.h"
+
   using namespace std; 
   using namespace BEEV;
 
   // Suppress the bogus warning suppression in bison (it generates
   // compile error)
 #undef __GNUC_MINOR__
-
+  
 #define YYLTYPE_IS_TRIVIAL 1
 #define YYMAXDEPTH 10485760
 #define YYERROR_VERBOSE 1
 #define YYPARSE_PARAM AssertsQuery
 
 
 extern int cvclex(void);
 extern char* yytext;
 extern int cvclineno;
 int yyerror(const char *s) {
-    cout << "syntax error: line " << cvclineno << "\n" << s << endl;    
-    FatalError("");
-    return YY_EXIT_FAILURE;
 };
-%}
+ extern int cvclex(void);
+ extern char* yytext;
+ extern int cvclineno;
+ int yyerror(const char *s) {
+   cout << "syntax error: line " << cvclineno << "\n" << s << endl;    
+   FatalError("");
+   return YY_EXIT_FAILURE;
+ };
+ %}
 
 %union {
 
diff --git a/src/parser/parser.h b/src/parser/parser.h
new file mode 100644 (file)
index 0000000..1f4cdf8
--- /dev/null
@@ -0,0 +1,19 @@
+// -*- c++ -*-
+/********************************************************************
+ * AUTHORS: Vijay Ganesh
+ *
+ * BEGIN DATE: November, 2005
+ *
+ * LICENSE: Please view LICENSE file in the home dir of this Program
+ ********************************************************************/
+
+#ifndef PARSER_H
+#define PARSER_H
+#include "../AST/AST.h"
+namespace BEEV 
+{
+  //external parser table for declared symbols.
+  extern ASTNodeSet _parser_symbol_table;
+
+}; //end of namespace
+#endif
index 4544673586e0aaeee97363615666bbccffc9216f..171cf24a51d90cc924d4f70069a534dde1ae94da 100644 (file)
@@ -34,7 +34,7 @@
    ********************************************************************/
   // -*- c++ -*-
 #include <iostream>
-#include "../AST/AST.h"
+#include "parser.h"
 #include "parseSMT_defs.h"
 
   using namespace std;
index 964ef6f3112ccf8e41429359c6be9bd3361a7e61..e532ebafad93ff38ab1c5f25adefb1e381017b15 100644 (file)
@@ -35,7 +35,8 @@
    ********************************************************************/
   // -*- c++ -*-
 
-#include "../AST/AST.h"
+#include "parser.h"
+
   using namespace std; 
   using namespace BEEV;