summaryrefslogtreecommitdiff
path: root/examples/translator.cpp
diff options
context:
space:
mode:
authorTim King <taking@google.com>2015-12-18 17:19:07 -0800
committerTim King <taking@google.com>2015-12-18 17:19:07 -0800
commit5f207ba01302c3245e169bfbe2ed91ad0cd659cd (patch)
treee1131e8c2891e283ab028fba6a7a677bb4ac9f5f /examples/translator.cpp
parent7e4468ba0aa0b08eeb4ba1a86b1fdd839ae169d6 (diff)
Modifying emptyset.h and sexpr. Adding SetLanguage.
- Modifies expr/emptyset.h to use SetType only as an incomplete type within expr/emptyset.h. This breaks the include cycle between expr/emptyset.h, expr/expr.h and expr/type.h. - Refactors SExpr to avoid a potentially infinite cycle. This is likely overkill, but it works. - Moving Expr::setlanguage and related utilities out of the Expr class and into their own file. This allows files in util/ to know the output language set on an ostream.
Diffstat (limited to 'examples/translator.cpp')
-rw-r--r--examples/translator.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/examples/translator.cpp b/examples/translator.cpp
index 522d88573..7d5e912e7 100644
--- a/examples/translator.cpp
+++ b/examples/translator.cpp
@@ -24,6 +24,7 @@
#include "expr/expr.h"
#include "options/language.h"
+#include "options/set_language.h"
#include "parser/parser.h"
#include "parser/parser_builder.h"
#include "smt/smt_engine.h"
@@ -97,7 +98,7 @@ static void readFile(const char* filename, InputLanguage fromLang, OutputLanguag
toLang = toOutputLanguage(fromLang);
}
- *out << Expr::setlanguage(toLang);
+ *out << language::SetLanguage(toLang);
Options opts;
opts.set(options::inputLanguage, fromLang);
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback