@@ -62,6 +62,27 @@ static std::ostream &format_rec(std::ostream &os, const multi_ary_exprt &src)
62
62
{
63
63
bool first = true ;
64
64
65
+ std::string operator_str;
66
+
67
+ if (src.id () == ID_and)
68
+ operator_str = u8" \u2227 " ; // wedge, U+2227
69
+ else if (src.id () == ID_or)
70
+ operator_str = u8" \u2228 " ; // vee, U+2228
71
+ else if (src.id () == ID_xor)
72
+ operator_str = u8" \u2295 " ; // + in circle, U+2295
73
+ else if (src.id () == ID_le)
74
+ operator_str = u8" \u2264 " ; // <=, U+2264
75
+ else if (src.id () == ID_ge)
76
+ operator_str = u8" \u2265 " ; // >=, U+2265
77
+ else if (src.id () == ID_notequal)
78
+ operator_str = u8" \u2260 " ; // /=, U+2260
79
+ else if (src.id () == ID_implies)
80
+ operator_str = u8" \u21d2 " ; // =>, U+21D2
81
+ else if (src.id () == ID_iff)
82
+ operator_str = u8" \u21d4 " ; // <=>, U+21D4
83
+ else
84
+ operator_str = id2string (src.id ());
85
+
65
86
for (const auto &op : src.operands ())
66
87
{
67
88
if (first)
@@ -95,7 +116,7 @@ static std::ostream &format_rec(std::ostream &os, const binary_exprt &src)
95
116
static std::ostream &format_rec (std::ostream &os, const unary_exprt &src)
96
117
{
97
118
if (src.id () == ID_not)
98
- os << ' ! ' ;
119
+ os << u8" \u00ac " ; // neg, U+00AC
99
120
else if (src.id () == ID_unary_minus)
100
121
os << ' -' ;
101
122
else
@@ -197,8 +218,12 @@ std::ostream &format_rec(std::ostream &os, const exprt &expr)
197
218
}
198
219
else if (id == ID_type)
199
220
return format_rec (os, expr.type ());
200
- else if (id == ID_forall || id == ID_exists)
201
- return os << id << ' ' << format (to_quantifier_expr (expr).symbol ()) << " : "
221
+ else if (id == ID_forall)
222
+ return os << id << u8" \u2200 : "
223
+ << format (to_quantifier_expr (expr).symbol ().type ()) << " . "
224
+ << format (to_quantifier_expr (expr).where ());
225
+ else if (id == ID_exists)
226
+ return os << id << u8" \u2203 : "
202
227
<< format (to_quantifier_expr (expr).symbol ().type ()) << " . "
203
228
<< format (to_quantifier_expr (expr).where ());
204
229
else if (id == ID_let)
0 commit comments