mirror of
https://github.com/Z3Prover/z3
synced 2025-07-19 10:52:02 +00:00
include path to thread and guard by SINGLE_THREAD
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
parent
ac4bcb9034
commit
c07cfc0e69
1 changed files with 7 additions and 0 deletions
|
@ -21,6 +21,9 @@ Revision History:
|
||||||
#include "ast/ast_pp.h"
|
#include "ast/ast_pp.h"
|
||||||
#include "ast/ast_pp_util.h"
|
#include "ast/ast_pp_util.h"
|
||||||
#include "util/stats.h"
|
#include "util/stats.h"
|
||||||
|
#ifndef SINGLE_THREAD
|
||||||
|
#include <thread>
|
||||||
|
#endif
|
||||||
|
|
||||||
namespace smt {
|
namespace smt {
|
||||||
|
|
||||||
|
@ -471,8 +474,12 @@ namespace smt {
|
||||||
|
|
||||||
std::string context::mk_lemma_name() const {
|
std::string context::mk_lemma_name() const {
|
||||||
std::stringstream strm;
|
std::stringstream strm;
|
||||||
|
#ifndef SINGLE_THREAD
|
||||||
std::thread::id this_id = std::this_thread::get_id();
|
std::thread::id this_id = std::this_thread::get_id();
|
||||||
strm << "lemma_" << this_id << "." << (++m_lemma_id) << ".smt2";
|
strm << "lemma_" << this_id << "." << (++m_lemma_id) << ".smt2";
|
||||||
|
#else
|
||||||
|
strm << "lemma_" << (++m_lemma_id) << ".smt2";
|
||||||
|
#endif
|
||||||
return strm.str();
|
return strm.str();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue