Skip to content

Commit

Permalink
Move string_constraintt constructor to cpp
Browse files Browse the repository at this point in the history
Allows to add functionality to constructor without overcharging the
header file.
  • Loading branch information
Joel Allred committed Jul 18, 2018
1 parent f01c03c commit 16052f8
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 7 deletions.
1 change: 1 addition & 0 deletions src/solvers/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,7 @@ SRC = $(BOOLEFORCE_SRC) \
refinement/string_builtin_function.cpp \
refinement/string_refinement.cpp \
refinement/string_refinement_util.cpp \
refinement/string_constraint.cpp \
refinement/string_constraint_generator_code_points.cpp \
refinement/string_constraint_generator_comparison.cpp \
refinement/string_constraint_generator_concat.cpp \
Expand Down
21 changes: 21 additions & 0 deletions src/solvers/refinement/string_constraint.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
/*******************************************************************\
Module: String solver
Author: Diffblue Ltd.
\*******************************************************************/

#include "string_constraint.h"

string_constraintt::string_constraintt(
symbol_exprt _univ_var,
exprt lower_bound,
exprt upper_bound,
exprt body)
: univ_var(_univ_var),
lower_bound(lower_bound),
upper_bound(upper_bound),
body(body)
{
}
8 changes: 1 addition & 7 deletions src/solvers/refinement/string_constraint.h
Original file line number Diff line number Diff line change
Expand Up @@ -71,13 +71,7 @@ class string_constraintt final
symbol_exprt _univ_var,
exprt lower_bound,
exprt upper_bound,
exprt body)
: univ_var(_univ_var),
lower_bound(lower_bound),
upper_bound(upper_bound),
body(body)
{
}
exprt body);

// Default bound inferior is 0
string_constraintt(symbol_exprt univ_var, exprt upper_bound, exprt body)
Expand Down

0 comments on commit 16052f8

Please sign in to comment.