Our `DefineFunctionCommand` was binding the string representation of the
function symbol including the `|` quotes instead of the symbol without
the quotes. This commit fixes the issue.
api::Term Smt2::parseOpToExpr(ParseOp& p)
{
- Debug("parser") << "parseOpToExpr: " << p << std::endl;
+ Trace("parser") << "parseOpToExpr: " << p << std::endl;
api::Term expr;
if (p.d_kind != api::NULL_EXPR || !p.d_type.isNull())
{
bool global = sm->getGlobalDeclarations();
api::Term fun =
solver->defineFun(d_symbol, d_formals, d_sort, d_formula, global);
- sm->getSymbolTable()->bind(fun.toString(), fun, global);
+ sm->getSymbolTable()->bind(d_symbol, fun, global);
d_commandStatus = CommandSuccess::instance();
}
catch (exception& e)
regress0/parser/linear_arithmetic_err3.smt2
regress0/parser/named-attr-error.smt2
regress0/parser/named-attr.smt2
+ regress0/parser/quoted-define-fun.smt2
regress0/parser/shadow_fun_symbol_all.smt2
regress0/parser/shadow_fun_symbol_nirat.smt2
regress0/parser/strings20.smt2
--- /dev/null
+(set-logic QF_BV)
+(define-fun |def_B definitions| () Bool true)
+(assert |def_B definitions|)
+(set-info :status sat)
+(check-sat)