Skip to content

Commit 2e6d2ce

Browse files
Using warning() for warning messages in string solver
1 parent 30306f1 commit 2e6d2ce

File tree

1 file changed

+6
-9
lines changed

1 file changed

+6
-9
lines changed

src/solvers/refinement/string_refinement.cpp

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -231,8 +231,7 @@ bool string_refinementt::add_axioms_for_string_assigns(
231231
}
232232
else
233233
{
234-
debug() << "string_refinement warning: not handling char_array: "
235-
<< from_expr(ns, "", rhs) << eom;
234+
warning() << "ignoring char array " << from_expr(ns, "", rhs) << eom;
236235
return true;
237236
}
238237
}
@@ -375,8 +374,8 @@ void string_refinementt::set_to(const exprt &expr, bool value)
375374

376375
if(eq_expr.lhs().type()!=eq_expr.rhs().type())
377376
{
378-
debug() << "(sr::set_to) WARNING: ignoring "
379-
<< from_expr(ns, "", expr) << " [inconsistent types]" << eom;
377+
warning() << "ignoring " << from_expr(ns, "", expr)
378+
<< " [inconsistent types]" << eom;
380379
debug() << "lhs has type: " << eq_expr.lhs().type().pretty(12) << eom;
381380
debug() << "rhs has type: " << eq_expr.rhs().type().pretty(12) << eom;
382381
return;
@@ -397,8 +396,7 @@ void string_refinementt::set_to(const exprt &expr, bool value)
397396
// TODO: See if this happens at all.
398397
if(lhs.id()!=ID_symbol)
399398
{
400-
debug() << "(sr::set_to) WARNING: ignoring "
401-
<< from_expr(ns, "", expr) << eom;
399+
warning() << "ignoring " << from_expr(ns, "", expr) << eom;
402400
return;
403401
}
404402

@@ -409,9 +407,8 @@ void string_refinementt::set_to(const exprt &expr, bool value)
409407
subst_rhs.type().id() != ID_array ||
410408
eq_expr.lhs().type().subtype() != subst_rhs.type().subtype())
411409
{
412-
debug() << "(sr::set_to) WARNING: ignoring "
413-
<< from_expr(ns, "", expr) << " [inconsistent types after substitution]"
414-
<< eom;
410+
warning() << "ignoring " << from_expr(ns, "", expr)
411+
<< " [inconsistent types after substitution]" << eom;
415412
return;
416413
}
417414
else

0 commit comments

Comments
 (0)