3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-14 21:08:46 +00:00

Fix translation of FPA numerals in ast_smt_pp. Fixes #2145.

This commit is contained in:
Christoph M. Wintersteiger 2019-02-22 12:55:01 +00:00
parent bceff4b3fa
commit 699834261e
No known key found for this signature in database
GPG key ID: BCF6360F86294467

View file

@ -24,6 +24,7 @@ Revision History:
#include "util/vector.h"
#include "util/smt2_util.h"
#include "ast/ast_smt_pp.h"
#include "ast/ast_smt2_pp.h"
#include "ast/arith_decl_plugin.h"
#include "ast/bv_decl_plugin.h"
#include "ast/array_decl_plugin.h"
@ -388,10 +389,7 @@ class smt_printer {
m_out << "(_ bv" << val << " " << bv_size << ")";
}
else if (m_futil.is_numeral(n, float_val)) {
m_out << "((_ to_fp " <<
float_val.get().get_ebits() << " " <<
float_val.get().get_sbits() << ") RTZ " <<
m_futil.fm().to_string(float_val).c_str() << ")";
m_out << mk_ismt2_pp(n, m_manager);
}
else if (m_bvutil.is_bit2bool(n)) {
unsigned bit = n->get_decl()->get_parameter(0).get_int();