mirror of
https://github.com/Z3Prover/z3
synced 2026-07-15 11:35:42 +00:00
* Initial plan * Modernize C++ constructors to use C++11 default member initialization - Phase 1 Co-authored-by: nunoplopes <2998477+nunoplopes@users.noreply.github.com> * Fix theory_pb.h struct definition - move reset() back inside struct Co-authored-by: nunoplopes <2998477+nunoplopes@users.noreply.github.com> * Modernize C++ constructors to use C++11 default member initialization - Phase 2 Co-authored-by: nunoplopes <2998477+nunoplopes@users.noreply.github.com> * Fix opt_solver.h - revert rational initialization (complex type) Co-authored-by: nunoplopes <2998477+nunoplopes@users.noreply.github.com> * Modernize C++ constructors to use C++11 default member initialization - Phase 3 Co-authored-by: nunoplopes <2998477+nunoplopes@users.noreply.github.com> * Fix sparse_matrix.h - explicitly initialize union member in default constructor Co-authored-by: nunoplopes <2998477+nunoplopes@users.noreply.github.com> * Remove unnecessary default constructors when they're the only constructor Co-authored-by: nunoplopes <2998477+nunoplopes@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: nunoplopes <2998477+nunoplopes@users.noreply.github.com>
42 lines
773 B
C++
42 lines
773 B
C++
/*++
|
|
Copyright (c) 2012 Microsoft Corporation
|
|
|
|
Module Name:
|
|
|
|
model2expr.h
|
|
|
|
Abstract:
|
|
|
|
Convert model to logical formula that forces it.
|
|
|
|
Author:
|
|
|
|
Nikolaj Bjorner (nbjorner) 2012-09-17
|
|
|
|
Revision History:
|
|
|
|
--*/
|
|
#pragma once
|
|
|
|
#include "model/model.h"
|
|
|
|
void model2expr(model& m, expr_ref& result);
|
|
|
|
inline void model2expr(model_ref& md, expr_ref& result) { model2expr(*md.get(), result); }
|
|
|
|
// TODO: move
|
|
typedef hashtable<symbol, symbol_hash_proc, symbol_eq_proc> symbol_set;
|
|
|
|
class mk_fresh_name {
|
|
symbol_set m_symbols;
|
|
char m_char = 'A';
|
|
unsigned m_num = 0;
|
|
public:
|
|
void add(ast* a);
|
|
void add(symbol const& s) { m_symbols.insert(s); }
|
|
symbol next();
|
|
bool contains(symbol const& s) const { return m_symbols.contains(s); }
|
|
};
|
|
|
|
|
|
|