Skip to content

Commit 86e0f59

Browse files
author
Joel Allred
committed
Move string_constraintt constructor to cpp
Allows to add functionality to constructor without overcharging the header file.
1 parent 12de9a4 commit 86e0f59

File tree

3 files changed

+23
-7
lines changed

3 files changed

+23
-7
lines changed

src/solvers/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,7 @@ SRC = $(BOOLEFORCE_SRC) \
166166
refinement/string_builtin_function.cpp \
167167
refinement/string_refinement.cpp \
168168
refinement/string_refinement_util.cpp \
169+
refinement/string_constraint.cpp \
169170
refinement/string_constraint_generator_code_points.cpp \
170171
refinement/string_constraint_generator_comparison.cpp \
171172
refinement/string_constraint_generator_concat.cpp \
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
/*******************************************************************\
2+
3+
Module: String solver
4+
5+
Author: Diffblue Ltd.
6+
7+
\*******************************************************************/
8+
9+
#include "string_constraint.h"
10+
11+
string_constraintt::string_constraintt(
12+
symbol_exprt _univ_var,
13+
exprt lower_bound,
14+
exprt upper_bound,
15+
exprt body)
16+
: univ_var(_univ_var),
17+
lower_bound(lower_bound),
18+
upper_bound(upper_bound),
19+
body(body)
20+
{
21+
}

src/solvers/refinement/string_constraint.h

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -71,13 +71,7 @@ class string_constraintt final
7171
symbol_exprt _univ_var,
7272
exprt lower_bound,
7373
exprt upper_bound,
74-
exprt body)
75-
: univ_var(_univ_var),
76-
lower_bound(lower_bound),
77-
upper_bound(upper_bound),
78-
body(body)
79-
{
80-
}
74+
exprt body);
8175

8276
// Default bound inferior is 0
8377
string_constraintt(symbol_exprt univ_var, exprt upper_bound, exprt body)

0 commit comments

Comments
 (0)