LCOV - code coverage report
Current view: top level - buildbot/coverage/build/test/api/cpp/issues - issue7000.cpp (source / functions) Hit Total Coverage
Test: coverage.info Lines: 16 17 94.1 %
Date: 2025-02-28 11:47:17 Functions: 1 1 100.0 %
Branches: 0 0 -

           Branch data     Line data    Source code
       1                 :            : /******************************************************************************
       2                 :            :  * Top contributors (to current version):
       3                 :            :  *   Aina Niemetz, Andrew Reynolds
       4                 :            :  *
       5                 :            :  * This file is part of the cvc5 project.
       6                 :            :  *
       7                 :            :  * Copyright (c) 2009-2025 by the authors listed in the file AUTHORS
       8                 :            :  * in the top-level source directory and their institutional affiliations.
       9                 :            :  * All rights reserved.  See the file COPYING in the top-level source
      10                 :            :  * directory for licensing information.
      11                 :            :  * ****************************************************************************
      12                 :            :  *
      13                 :            :  * Test for issue #7000.
      14                 :            :  */
      15                 :            : #include <cvc5/cvc5.h>
      16                 :            : 
      17                 :            : #include <cassert>
      18                 :            : 
      19                 :            : using namespace cvc5;
      20                 :            : 
      21                 :          1 : int main(void)
      22                 :            : {
      23                 :          2 :   TermManager tm;
      24                 :          2 :   Solver solver(tm);
      25                 :          2 :   Sort s1 = tm.getIntegerSort();
      26                 :          4 :   Sort s2 = tm.mkFunctionSort({s1}, s1);
      27                 :          2 :   Sort s3 = tm.getRealSort();
      28                 :          2 :   Term t4 = tm.mkPi();
      29                 :          2 :   Term t7 = tm.mkConst(s3, "_x5");
      30                 :          2 :   Term t37 = tm.mkConst(s2, "_x32");
      31                 :          2 :   Term t59 = tm.mkConst(s2, "_x51");
      32                 :          5 :   Term t72 = tm.mkTerm(Kind::EQUAL, {t37, t59});
      33                 :          5 :   Term t74 = tm.mkTerm(Kind::GT, {t4, t7});
      34                 :          7 :   Term query = tm.mkTerm(Kind::AND, {t72, t74, t72, t72});
      35                 :            :   // throws logic exception since logic is not higher order by default
      36                 :            :   try
      37                 :            :   {
      38                 :          2 :     solver.checkSatAssuming(query.notTerm());
      39                 :            :   }
      40                 :          1 :   catch (CVC5ApiException& e)
      41                 :            :   {
      42                 :          1 :     return 0;
      43                 :            :   }
      44                 :          0 :   assert(false);
      45                 :            : }

Generated by: LCOV version 1.14