From 6b553f3ee59749f74475ee5c88b06ac04c16b3c6 Mon Sep 17 00:00:00 2001 From: Kshitij Bansal Date: Tue, 30 Jun 2015 01:47:10 -0400 Subject: [PATCH] fix sets-translate --- examples/sets-translate/sets_translate.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/examples/sets-translate/sets_translate.cpp b/examples/sets-translate/sets_translate.cpp index fbec42829..acf0fcafe 100644 --- a/examples/sets-translate/sets_translate.cpp +++ b/examples/sets-translate/sets_translate.cpp @@ -94,8 +94,13 @@ class Mapper { setTypes.insert(t); Type elementType = t.getElementType(); - string elementTypeAsString = elementType.toString(); - remove_if(elementTypeAsString.begin(), elementTypeAsString.end(), nonsense); + ostringstream oss_type; + oss_type << Expr::setlanguage(language::output::LANG_SMTLIB_V2) + << elementType; + string elementTypeAsString = oss_type.str(); + elementTypeAsString.erase( + remove_if(elementTypeAsString.begin(), elementTypeAsString.end(), nonsense), + elementTypeAsString.end()); // define-sort ostringstream oss_name; -- 2.30.2