Commit Graph

25 Commits

Author SHA1 Message Date
Aina Niemetz
0647c4c107 Update copyright headers. (#11561)
Co-authored-by: Daniel Larraz <daniel-larraz@users.noreply.github.com>
2025-01-23 17:54:20 +00:00
Andrew Reynolds
ad76979329 Disable support for experimental theories when safe-options is set (#11162)
This adds options that guard the usage of "experimental" theories or
extensions thereof when `--safe-options` is enabled.

This includes bags, finite fields, separation logic, higher-order logic,
and extensions of arithmetic (including transcendentals, iand and pow2).

The options `--sets-exp` (renamed from `--sets-ext` in this PR) and
`--fp-exp` continue to be disabled by default, thus do not need to
change.

Similar to other expert options, these theories can still be used with
`safe-options` if they are enabled prior to setting `safe-options`, e.g.
`--ho-exp --safe-options ...` allows HOL to be used. The options
configuration will only override the setting of `*-exp` options if not
set by user.

This does not impact the behavior of cvc5 when `--safe-options` is not
set.

FYI @alex-ozdemir @mudathirmahgoub @yoni206 .
2024-09-27 15:07:07 +00:00
Daniel Larraz
6f32ee5ca0 doc: Pass TermManager to Solver in Java examples (#11232)
It also replaces calls to deprecated functions of `Solver` with the
corresponding function of `TermManager`.

---------

Co-authored-by: mudathirmahgoub <mudathirmahgoub@gmail.com>
2024-09-26 21:00:25 +00:00
Aina Niemetz
fdf9ce7138 Update copyright headers. (#10459) 2024-03-12 09:35:09 -07:00
mudathirmahgoub
7ff15aa749 Refctor Solver.java to extend AbstractPointer (#10064)
This refactors the Solver class in the java API to extend AbstractPointer similar to other cvc5 classes.
It also cleans up redundant code for Abstract pointers. and adds Context.deletePointers to java examples as mentioned in issue #10052.
2023-10-02 06:20:26 +00:00
Andrew Reynolds
2e41f64d47 Simplify API for constructing tuple values (#9766)
In preparation for 1.1.
2023-06-12 17:28:05 +00:00
mudathirmahgoub
590af04a10 Remove reference to solver from java objects (#9147) 2022-10-04 17:06:02 +00:00
mudathirmahgoub
12293a35d5 Add Relation and Table types to SMTLib parser (#8605) 2022-04-13 13:54:27 -05:00
Mathias Preiner
d01e59c13b Update copyright headers for release 1.0 (#8539) 2022-04-05 20:38:57 +00:00
mudathirmahgoub
6c421a8221 Add examples/bags.cpp (#8463) 2022-03-31 15:17:22 +00:00
Andres Noetzli
c93de62d8b Move Java package to io.github.cvc5 (#8469)
Previously, we were using io.github.cvc5.api to mirror the C++
namespace that the API was in. The namespace of the C++ API changed to
simply cvc5 and so this commit updates the Java package accordingly.
2022-03-31 04:09:03 +00:00
mudathirmahgoub
437c346559 Add relations.cpp, relations.py examples (#7801) 2021-12-17 19:23:16 +00:00
mudathirmahgoub
b7164b4592 Update Relations.java (#7796) 2021-12-13 17:47:40 +00:00
mudathirmahgoub
1a79f9534c Fix compile errors with java examples (#7646)
Fix compile errors with java examples
2021-11-16 18:13:19 +00:00
Aina Niemetz
e8c0874f92 api: Rename BOUND_VAR_LIST to VARIABLE_LIST. (#7632) 2021-11-15 16:10:26 +00:00
mudathirmahgoub
690a392656 Enable CI for Junit tests (#7436)
This PR enables CI for java tests by adding --java-bindings to ci.yml.
It also replaces the unreliable finalize method and instead uses AutoCloseable and explicit close method to clean up dynamic memory allocated by java native interface.
The PR fixes compile errors for SolverTest.java and runtime errors for Solver.defineFun.
2021-11-03 21:32:10 +00:00
mudathirmahgoub
60c9b49809 Refactor java package name from cvc5 to io.github.cvc5.api (#7340)
This PR refactors java package name from cvc5 to io.github.cvc5.api.
It also refactor the names of cpp and java files.
2021-10-22 23:00:06 +00:00
mudathirmahgoub
98e884a740 Update java examples using the new Java API (#7225)
This PRs updates java examples using the new Java API, by converting C++ examples to Java.
Examples CVC4Streams.java and PipedInput.java are removed since they are not longer supported by the API.
All examples are not included in the build which would be added in a future PR.
2021-10-01 23:21:02 +00:00
Aina Niemetz
7ec3005875 Refactor and update copyright headers. (#6316) 2021-04-12 19:31:43 +00:00
Aina Niemetz
b302cb1f92 Update copyright headers to 2021. (#6081) 2021-03-09 07:27:03 +00:00
Mathias Preiner
e3cd4670a0 Update copyright header script to support CMake and Python files (#5067)
This PR updates the update-copyright.pl script to also update/add copyright headers to CMake specific files. It further fixes a small typo in the header.
2020-09-22 09:51:56 -07:00
Andres Noetzli
7d16d25dc9 Improve memory management in Java bindings (#4629)
Fixes #2846. One of the challenges of the Java bindings is that the
garbage collector can delete unused objects at any time in any order.
This is an issue with CVC4's API because we require all `Expr`s to be
deleted before the corresponding `ExprManager`. In the past, we were
using `NewGlobalRef`/`DeleteGlobalRef` on the wrapper object of
`ExprManager`. The problem is that we can have multiple instances of the
wrapper that internally all refer to the same `ExprManager`. This commit
implements a different approach where the Java wrappers hold an explicit
reference to the `ExprManager`. The commit also removes some unused or
unimportant API bits from the bindings.
2020-06-18 12:21:02 -07:00
Aina Niemetz
e37d0c385d Update copyright headers. 2020-06-16 13:48:05 -07:00
Andres Noetzli
84c72e3c37 Fix Java target and Relations example (#4583)
Currently, our CVC4Config file is never including the CVC4 Java targets
because of a typo in `cmake/CVC4Config.cmake.in`. For this reason, our
build system for the examples would never actually build the examples.
Fixing this issue brought up another issue in our Relations Java example
that was using an outdated `System.loadLibrary()` call. This commit
fixes the typo and the example.

Note: Most changes in `Relations.java` were caused by ClangFormat.
2020-06-08 21:20:25 -07:00
mudathirmahgoub
0a5f22c98c Sets & Relations Java example (#3816) 2020-02-25 11:47:24 -06:00