Skip to content

Commit 7d88f07

Browse files
authored
Merge branch 'master' into fix-iss-414
2 parents 1570909 + ed9086a commit 7d88f07

File tree

103 files changed

+1878
-1846
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

103 files changed

+1878
-1846
lines changed

Makefile.build

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ srcsubdirs = mt io terms utils solvers solvers/floyd_warshall \
8989
solvers/funs solvers/bv solvers/egraph solvers/cdcl solvers/simplex solvers/quant \
9090
parser_utils model api frontend frontend/common \
9191
frontend/smt1 frontend/yices frontend/smt2 context exists_forall \
92-
mcsat mcsat/eq mcsat/weq mcsat/uf mcsat/bool mcsat/ite mcsat/nra mcsat/ff mcsat/bv \
92+
mcsat mcsat/eq mcsat/weq mcsat/uf mcsat/bool mcsat/ite mcsat/na mcsat/ff mcsat/bv \
9393
mcsat/bv/explain mcsat/utils
9494

9595
testdir = tests/unit

doc/sphinx/source/_static/example1.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ static void simple_test(void) {
8686
}
8787

8888
switch (yices_check_context(ctx, NULL)) { // call check_context, NULL means 'use default heuristics'
89-
case STATUS_SAT:
89+
case YICES_STATUS_SAT:
9090
printf("The formula is satisfiable\n");
9191
model_t* model = yices_get_model(ctx, true); // get the model
9292
if (model == NULL) {
@@ -117,18 +117,18 @@ static void simple_test(void) {
117117
}
118118
break;
119119

120-
case STATUS_UNSAT:
120+
case YICES_STATUS_UNSAT:
121121
printf("The formula is not satisfiable\n");
122122
break;
123123

124-
case STATUS_UNKNOWN:
124+
case YICES_STATUS_UNKNOWN:
125125
printf("The status is unknown\n");
126126
break;
127127

128-
case STATUS_IDLE:
129-
case STATUS_SEARCHING:
128+
case YICES_STATUS_IDLE:
129+
case YICES_STATUS_SEARCHING:
130130
case YICES_STATUS_INTERRUPTED:
131-
case STATUS_ERROR:
131+
case YICES_STATUS_ERROR:
132132
fprintf(stderr, "Error in check_context\n");
133133
yices_print_error(stderr);
134134
break;

doc/sphinx/source/_static/example1b.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ static void simple_test(void) {
9393
}
9494

9595
switch (yices_check_context(ctx, NULL)) { // call check_context, NULL means 'use default heuristics'
96-
case STATUS_SAT:
96+
case YICES_STATUS_SAT:
9797
printf("The formula is satisfiable\n");
9898
model = yices_get_model(ctx, 1); // get the model
9999
if (model == NULL) {
@@ -125,18 +125,18 @@ static void simple_test(void) {
125125
}
126126
break;
127127

128-
case STATUS_UNSAT:
128+
case YICES_STATUS_UNSAT:
129129
printf("The formula is not satisfiable\n");
130130
break;
131131

132-
case STATUS_UNKNOWN:
132+
case YICES_STATUS_UNKNOWN:
133133
printf("The status is unknown\n");
134134
break;
135135

136-
case STATUS_IDLE:
137-
case STATUS_SEARCHING:
136+
case YICES_STATUS_IDLE:
137+
case YICES_STATUS_SEARCHING:
138138
case YICES_STATUS_INTERRUPTED:
139-
case STATUS_ERROR:
139+
case YICES_STATUS_ERROR:
140140
fprintf(stderr, "Error in check_context\n");
141141
yices_print_error(stderr);
142142
break;

doc/sphinx/source/api-types.rst

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -421,48 +421,48 @@ Contexts
421421
Context state::
422422

423423
typedef enum smt_status {
424-
STATUS_IDLE,
425-
STATUS_SEARCHING,
426-
STATUS_UNKNOWN,
427-
STATUS_SAT,
428-
STATUS_UNSAT,
424+
YICES_STATUS_IDLE,
425+
YICES_STATUS_SEARCHING,
426+
YICES_STATUS_UNKNOWN,
427+
YICES_STATUS_SAT,
428+
YICES_STATUS_UNSAT,
429429
YICES_STATUS_INTERRUPTED,
430-
STATUS_ERROR
430+
YICES_STATUS_ERROR
431431
} smt_status_t;
432432

433433
The type :c:type:`smt_status_t` enumerates the possible states of a
434434
context. It is also the type returned by the function that checks
435435
whether a context is satisfiable. The following codes are defined:
436436

437-
.. c:enum:: STATUS_IDLE
437+
.. c:enum:: YICES_STATUS_IDLE
438438
439439
Initial context state.
440440

441441
In this state, it is possible to assert formulas in the context.
442-
After assertions, the state may change to :c:enum:`STATUS_UNSAT` if
442+
After assertions, the state may change to :c:enum:`YICES_STATUS_UNSAT` if
443443
the assertions are trivially unsatisfiable. Otherwise, the state
444-
remains :c:enum:`STATUS_IDLE`.
444+
remains :c:enum:`YICES_STATUS_IDLE`.
445445

446-
.. c:enum:: STATUS_SEARCHING
446+
.. c:enum:: YICES_STATUS_SEARCHING
447447
448448
State during search.
449449

450450
A context enters this state after a call function
451451
:c:func:`yices_check_context`. It remains in this state until
452452
either the solver completes or the search is interrupted.
453453

454-
.. c:enum:: STATUS_UNKNOWN
454+
.. c:enum:: YICES_STATUS_UNKNOWN
455455
456456
State entered when the search terminates but is inconclusive.
457457

458458
This may happen if the context's solver is not complete for the specific
459459
logic used. For example, the logic may have quantifiers.
460460

461-
.. c:enum:: STATUS_SAT
461+
.. c:enum:: YICES_STATUS_SAT
462462
463463
State entered when the search terminates and the assertions are satisfiable.
464464

465-
.. c:enum:: STATUS_UNSAT
465+
.. c:enum:: YICES_STATUS_UNSAT
466466
467467
State entered when the assertions are known to be unsatisfiable.
468468

@@ -474,11 +474,11 @@ Contexts
474474
475475
State entered when the search is interrupted.
476476

477-
When a context is in the state :c:enum:`STATUS_SEARCHING` then the search
477+
When a context is in the state :c:enum:`YICES_STATUS_SEARCHING` then the search
478478
can be interrupted through a call to :c:func:`yices_stop_search`. This
479479
moves the context's state to :c:enum:`YICES_STATUS_INTERRUPTED`.
480480

481-
.. c:enum:: STATUS_ERROR
481+
.. c:enum:: YICES_STATUS_ERROR
482482
483483
This is an error code. It is returned by functions that operate on a
484484
context when the operation cannot be performed.
@@ -674,7 +674,7 @@ Error Reports
674674

675675
The following error codes are defined:
676676

677-
.. c:enum:: NO_ERROR
677+
.. c:enum:: YICES_NO_ERROR
678678
679679
Everything is fine.
680680

doc/sphinx/source/basic-usage.rst

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -139,23 +139,23 @@ context, assert ``f`` in this context, then call function :c:func:`yices_check_c
139139
}
140140

141141
switch (yices_check_context(ctx, NULL)) {
142-
case STATUS_SAT:
142+
case YICES_STATUS_SAT:
143143
printf("The formula is satisfiable\n");
144144
...
145145
break;
146146

147-
case STATUS_UNSAT:
147+
case YICES_STATUS_UNSAT:
148148
printf("The formula is not satisfiable\n");
149149
break;
150150

151-
case STATUS_UNKNOWN:
151+
case YICES_STATUS_UNKNOWN:
152152
printf("The status is unknown\n");
153153
break;
154154

155-
case STATUS_IDLE:
156-
case STATUS_SEARCHING:
155+
case YICES_STATUS_IDLE:
156+
case YICES_STATUS_SEARCHING:
157157
case YICES_STATUS_INTERRUPTED:
158-
case STATUS_ERROR:
158+
case YICES_STATUS_ERROR:
159159
fprintf(stderr, "Error in check_context\n");
160160
yices_print_error(stderr);
161161
break;
@@ -167,11 +167,11 @@ function :c:func:`yices_assert_formula` asserts a formula in the
167167
context. Function :c:func:`yices_check_context` returns a code of type
168168
:c:type:`smt_status_t`:
169169

170-
- :c:enum:`STATUS_SAT` means that the context is satisfiable.
170+
- :c:enum:`YICES_STATUS_SAT` means that the context is satisfiable.
171171

172-
- :c:enum:`STATUS_UNSAT` means that the context is not satisfiable.
172+
- :c:enum:`YICES_STATUS_UNSAT` means that the context is not satisfiable.
173173

174-
- :c:enum:`STATUS_UNKNOWN` means that the context's status could
174+
- :c:enum:`YICES_STATUS_UNKNOWN` means that the context's status could
175175
not be determined.
176176

177177
Other codes are error conditions.
@@ -183,8 +183,8 @@ Once the context ``ctx`` is no longer needed, we delete it using :c:func:`yices_
183183
Building and Querying a Model
184184
-----------------------------
185185

186-
If :c:func:`yices_check_context` returns :c:data:`STATUS_SAT` (or
187-
:c:data:`STATUS_UNKNOWN`), we can construct a model of the asserted
186+
If :c:func:`yices_check_context` returns :c:data:`YICES_STATUS_SAT` (or
187+
:c:data:`YICES_STATUS_UNKNOWN`), we can construct a model of the asserted
188188
formulas by calling :c:func:`yices_get_model`. We then display the
189189
model using :c:func:`yices_pp_model`::
190190

0 commit comments

Comments
 (0)