Skip to content

Commit 990f33e

Browse files
Initialize at declaration instead of construction
Should another constructor be added in the future (copy, move, default, overload of existing constructor), one set of default arguments will already be present.
1 parent c1a93b3 commit 990f33e

File tree

1 file changed

+4
-8
lines changed

1 file changed

+4
-8
lines changed

src/solvers/prop/prop_conv.h

+4-8
Original file line numberDiff line numberDiff line change
@@ -72,10 +72,6 @@ class prop_conv_solvert:public prop_convt
7272
public:
7373
prop_conv_solvert(const namespacet &_ns, propt &_prop):
7474
prop_convt(_ns),
75-
use_cache(true),
76-
equality_propagation(true),
77-
freeze_all(false),
78-
post_processing_done(false),
7975
prop(_prop) { }
8076

8177
virtual ~prop_conv_solvert() { }
@@ -106,9 +102,9 @@ class prop_conv_solvert:public prop_convt
106102
// get literal for expression, if available
107103
virtual bool literal(const exprt &expr, literalt &literal) const;
108104

109-
bool use_cache;
110-
bool equality_propagation;
111-
bool freeze_all; // freezing variables (for incremental solving)
105+
bool use_cache = true;
106+
bool equality_propagation = true;
107+
bool freeze_all = false; // freezing variables (for incremental solving)
112108

113109
virtual void clear_cache() { cache.clear();}
114110

@@ -126,7 +122,7 @@ class prop_conv_solvert:public prop_convt
126122
protected:
127123
virtual void post_process();
128124

129-
bool post_processing_done;
125+
bool post_processing_done = false;
130126

131127
// get a _boolean_ value from counterexample if not valid
132128
virtual bool get_bool(const exprt &expr, tvt &value) const;

0 commit comments

Comments
 (0)