summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAina Niemetz <aina.niemetz@gmail.com>2019-02-12 20:16:24 -0800
committerAndres Noetzli <andres.noetzli@gmail.com>2019-02-12 20:16:24 -0800
commit6eb492f636d2c950a6064389dfba297baff8e08e (patch)
tree7c5aabc01a6403c334e3f9f837c166e27d92ae50
parent6b07347b4964ff79dc6a17f22ab4be29aa489196 (diff)
New C++ API: Remove redundant mkTerm function. (#2836)
-rw-r--r--src/api/cvc4cpp.cpp15
-rw-r--r--src/api/cvc4cpp.h8
-rw-r--r--src/api/cvc4cppkind.h1
-rw-r--r--test/unit/api/solver_black.h5
4 files changed, 0 insertions, 29 deletions
diff --git a/src/api/cvc4cpp.cpp b/src/api/cvc4cpp.cpp
index ea70fc056..5d1f853e0 100644
--- a/src/api/cvc4cpp.cpp
+++ b/src/api/cvc4cpp.cpp
@@ -2531,21 +2531,6 @@ Term Solver::mkTerm(Kind kind) const
}
}
-Term Solver::mkTerm(Kind kind, Sort sort) const
-{
- try
- {
- CVC4_API_KIND_CHECK_EXPECTED(kind == SEP_NIL, kind) << "SEP_NIL";
- Term res = d_exprMgr->mkNullaryOperator(*sort.d_type, extToIntKind(kind));
- (void)res.d_expr->getType(true); /* kick off type checking */
- return res;
- }
- catch (const CVC4::TypeCheckingException& e)
- {
- throw CVC4ApiException(e.getMessage());
- }
-}
-
Term Solver::mkTerm(Kind kind, Term child) const
{
try
diff --git a/src/api/cvc4cpp.h b/src/api/cvc4cpp.h
index 955aff21a..2ac762b3e 100644
--- a/src/api/cvc4cpp.h
+++ b/src/api/cvc4cpp.h
@@ -1703,14 +1703,6 @@ class CVC4_PUBLIC Solver
Term mkTerm(Kind kind) const;
/**
- * Create 0-ary term of given kind and sort.
- * @param kind the kind of the term
- * @param sort the sort argument to this kind
- * @return the Term
- */
- Term mkTerm(Kind kind, Sort sort) const;
-
- /**
* Create a unary term of given kind.
* @param kind the kind of the term
* @param child the child of the term
diff --git a/src/api/cvc4cppkind.h b/src/api/cvc4cppkind.h
index 4e69ddfe1..3184da78e 100644
--- a/src/api/cvc4cppkind.h
+++ b/src/api/cvc4cppkind.h
@@ -1755,7 +1755,6 @@ enum CVC4_PUBLIC Kind : int32_t
* Parameters: 0
* Create with:
* mkSepNil(Sort sort)
- * mkTerm(Kind kind, Sort sort)
*/
SEP_NIL,
/**
diff --git a/test/unit/api/solver_black.h b/test/unit/api/solver_black.h
index 169a9948d..0a3eb46c3 100644
--- a/test/unit/api/solver_black.h
+++ b/test/unit/api/solver_black.h
@@ -550,11 +550,6 @@ void SolverBlack::testMkTerm()
TS_ASSERT_THROWS_NOTHING(d_solver->mkTerm(REGEXP_SIGMA));
TS_ASSERT_THROWS(d_solver->mkTerm(CONST_BITVECTOR), CVC4ApiException&);
- // mkTerm(Kind kind, Sort sort) const
- TS_ASSERT_THROWS_NOTHING(
- d_solver->mkTerm(SEP_NIL, d_solver->getBooleanSort()));
- TS_ASSERT_THROWS_NOTHING(d_solver->mkTerm(SEP_NIL, Sort()));
-
// mkTerm(Kind kind, Term child) const
TS_ASSERT_THROWS_NOTHING(d_solver->mkTerm(NOT, d_solver->mkTrue()));
TS_ASSERT_THROWS(d_solver->mkTerm(NOT, Term()), CVC4ApiException&);
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback