mirror of
https://github.com/Z3Prover/z3
synced 2025-08-09 12:50:32 +00:00
remove '#include <iostream>' from headers and from unneeded places
It's harmful to have iostream everywhere as it injects functions in the compiled files
This commit is contained in:
parent
70bcf0b51d
commit
73a24ca0a9
90 changed files with 99 additions and 95 deletions
|
@ -30,6 +30,7 @@ Revision History:
|
|||
#include "ast/arith_decl_plugin.h"
|
||||
#include "ast/ast_translation.h"
|
||||
#include "util/z3_version.h"
|
||||
#include <iostream>
|
||||
|
||||
|
||||
// -----------------------------------
|
||||
|
|
|
@ -17,7 +17,7 @@ Revision History:
|
|||
|
||||
--*/
|
||||
|
||||
#include<iostream>
|
||||
#include "ast/ast_ll_pp.h"
|
||||
#include "ast/for_each_ast.h"
|
||||
#include "ast/arith_decl_plugin.h"
|
||||
#include "ast/datatype_decl_plugin.h"
|
||||
|
|
|
@ -19,7 +19,7 @@ Revision History:
|
|||
#pragma once
|
||||
|
||||
#include "ast/ast.h"
|
||||
#include<iostream>
|
||||
#include<ostream>
|
||||
|
||||
void ast_ll_pp(std::ostream & out, ast_manager & m, ast * n, bool only_exprs=true, bool compact=true);
|
||||
void ast_ll_pp(std::ostream & out, ast_manager & m, ast * n, ast_mark & visited, bool only_exprs=true, bool compact=true);
|
||||
|
|
|
@ -6,7 +6,7 @@ Abstract: Pretty-printer for proofs in Graphviz format
|
|||
|
||||
#pragma once
|
||||
|
||||
#include <iostream>
|
||||
#include <ostream>
|
||||
#include "ast/ast_pp.h"
|
||||
|
||||
class ast_pp_dot {
|
||||
|
|
|
@ -18,6 +18,7 @@ Revision History:
|
|||
--*/
|
||||
#include "ast/ast_printer.h"
|
||||
#include "ast/pp.h"
|
||||
#include <iostream>
|
||||
|
||||
class simple_ast_printer_context : public ast_printer_context {
|
||||
ast_manager & m_manager;
|
||||
|
@ -51,3 +52,6 @@ public:
|
|||
ast_printer_context * mk_simple_ast_printer_context(ast_manager & m) {
|
||||
return alloc(simple_ast_printer_context, m);
|
||||
}
|
||||
|
||||
std::ostream & ast_printer_context::regular_stream() { return std::cout; }
|
||||
std::ostream & ast_printer_context::diagnostic_stream() { return std::cerr; }
|
||||
|
|
|
@ -20,6 +20,7 @@ Revision History:
|
|||
|
||||
#include "ast/ast.h"
|
||||
#include "ast/ast_smt2_pp.h"
|
||||
#include <ostream>
|
||||
|
||||
class ast_printer {
|
||||
public:
|
||||
|
@ -46,8 +47,8 @@ class ast_printer_context : public ast_printer {
|
|||
public:
|
||||
~ast_printer_context() override {}
|
||||
virtual ast_manager & get_ast_manager() = 0;
|
||||
virtual std::ostream & regular_stream() { return std::cout; }
|
||||
virtual std::ostream & diagnostic_stream() { return std::cerr; }
|
||||
virtual std::ostream & regular_stream();
|
||||
virtual std::ostream & diagnostic_stream();
|
||||
};
|
||||
|
||||
|
||||
|
|
|
@ -20,7 +20,7 @@ Revision History:
|
|||
--*/
|
||||
|
||||
#include<sstream>
|
||||
#include<iostream>
|
||||
#include<ostream>
|
||||
#include "util/vector.h"
|
||||
#include "util/smt2_util.h"
|
||||
#include "ast/ast_smt_pp.h"
|
||||
|
|
|
@ -162,7 +162,7 @@ expr_ref bv2fpa_converter::convert_bv2rm(expr * bv_rm) {
|
|||
}
|
||||
}
|
||||
else {
|
||||
std::cout << expr_ref(bv_rm, m) << " not converted\n";
|
||||
//std::cout << expr_ref(bv_rm, m) << " not converted\n";
|
||||
}
|
||||
|
||||
return res;
|
||||
|
|
|
@ -124,7 +124,7 @@ void fpa2bv_converter::mk_ite(expr * c, expr * t, expr * f, expr_ref & result) {
|
|||
result = m_util.mk_bv2rm(result);
|
||||
}
|
||||
else {
|
||||
std::cout << mk_pp(t, m) << " " << mk_pp(f, m) << "\n";
|
||||
//std::cout << mk_pp(t, m) << " " << mk_pp(f, m) << "\n";
|
||||
UNREACHABLE();
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue