Skip to main content

z3_sys/generated/
functions.rs

1// Auto-generated by z3-sys bindgen feature — do not edit manually.
2
3unsafe extern "C" {
4    /// Set a global (or module) parameter.
5    /// This setting is shared by all Z3 contexts.
6    ///
7    /// When a Z3 module is initialized it will use the value of these parameters
8    /// when Z3_params objects are not provided.
9    ///
10    /// The name of parameter can be composed of characters \[a-z]\[A-Z], digits \[0-9], '-' and '_'.
11    /// The character '.' is a delimiter (more later).
12    ///
13    /// The parameter names are case-insensitive. The character '-' should be viewed as an "alias" for '_'.
14    /// Thus, the following parameter names are considered equivalent: "pp.decimal-precision"  and "PP.DECIMAL_PRECISION".
15    ///
16    /// This function can be used to set parameters for a specific Z3 module.
17    /// This can be done by using `<module-name>.<parameter-name>`.
18    /// For example:
19    /// Z3_global_param_set('pp.decimal', 'true')
20    /// will set the parameter "decimal" in the module "pp" to true.
21    ///
22    /// # See also
23    ///
24    /// - [`Z3_global_param_get`]
25    /// - [`Z3_global_param_reset_all`]
26    pub fn Z3_global_param_set(param_id: Z3_string, param_value: Z3_string);
27    /// Restore the value of all global (and module) parameters.
28    /// This command will not affect already created objects (such as tactics and solvers).
29    ///
30    /// # See also
31    ///
32    /// - [`Z3_global_param_get`]
33    /// - [`Z3_global_param_set`]
34    pub fn Z3_global_param_reset_all();
35    /// Get a global (or module) parameter.
36    ///
37    /// Returns `false` if the parameter value does not exist.
38    ///
39    ///
40    /// **Remark:** This function cannot be invoked simultaneously from different threads without synchronization.
41    /// The result string stored in param_value is stored in shared location.
42    ///
43    /// # See also
44    ///
45    /// - [`Z3_global_param_reset_all`]
46    /// - [`Z3_global_param_set`]
47    pub fn Z3_global_param_get(param_id: Z3_string, param_value: Z3_string_ptr) -> bool;
48    /// Create a configuration object for the Z3 context object.
49    ///
50    /// Configurations are created in order to assign parameters prior to creating
51    /// contexts for Z3 interaction. For example, if the users wishes to use proof
52    /// generation, then call:
53    ///
54    /// `Z3_set_param_value(cfg, "proof", "true")`
55    ///
56    /// **Remark:** In previous versions of Z3, the `Z3_config` was used to store
57    /// global and module configurations. Now, we should use `Z3_global_param_set`.
58    ///
59    /// The following parameters can be set:
60    ///
61    /// - proof  (Boolean)           Enable proof generation
62    /// - debug_ref_count (Boolean)  Enable debug support for Z3_ast reference counting
63    /// - trace  (Boolean)           Tracing support for VCC
64    /// - trace_file_name (String)   Trace out file for VCC traces
65    /// - timeout (unsigned)         default timeout (in milliseconds) used for solvers
66    /// - well_sorted_check          type checker
67    /// - auto_config                use heuristics to automatically select solver and configure it
68    /// - model                      model generation for solvers, this parameter can be overwritten when creating a solver
69    /// - model_validate             validate models produced by solvers
70    /// - unsat_core                 unsat-core generation for solvers, this parameter can be overwritten when creating a solver
71    /// - encoding                   the string encoding used internally (must be either "unicode" - 18 bit, "bmp" - 16 bit or "ascii" - 8 bit)
72    ///
73    /// # See also
74    ///
75    /// - [`Z3_set_param_value`]
76    /// - [`Z3_del_config`]
77    pub fn Z3_mk_config() -> Option<Z3_config>;
78    /// Delete the given configuration object.
79    ///
80    /// # See also
81    ///
82    /// - [`Z3_mk_config`]
83    pub fn Z3_del_config(c: Z3_config);
84    /// Set a configuration parameter.
85    ///
86    /// The following parameters can be set for
87    ///
88    /// # See also
89    ///
90    /// - [`Z3_mk_config`]
91    pub fn Z3_set_param_value(c: Z3_config, param_id: Z3_string, param_value: Z3_string);
92    /// Create a context using the given configuration.
93    ///
94    /// After a context is created, the configuration cannot be changed,
95    /// although some parameters can be changed using [`Z3_update_param_value`].
96    /// All main interaction with Z3 happens in the context of a `Z3_context`.
97    ///
98    /// In contrast to `Z3_mk_context_rc` the life time of `Z3_ast` objects
99    /// persists with the life time of the context.
100    ///
101    /// Note that all other reference counted objects, including `Z3_model`,
102    /// `Z3_solver`, `Z3_func_interp` have to be managed by the caller.
103    /// Their reference counts are not handled by the context.
104    ///
105    /// **Remark:** Thread safety: objects created using a given context should not be
106    /// accessed from different threads without synchronization. In other words,
107    /// operations on a context are not thread safe. To use Z3 from different threads
108    /// create separate context objects. The `Z3_translate`, `Z3_solver_translate`,
109    /// `Z3_model_translate`, `Z3_goal_translate`
110    /// methods are exposed to allow copying state from one context to another.
111    ///
112    /// **Remark:**
113    /// - `Z3_sort`, `Z3_func_decl`, `Z3_app`, `Z3_pattern` are `Z3_ast`'s.
114    /// - Z3 uses hash-consing, i.e., when the same `Z3_ast` is created twice,
115    /// Z3 will return the same pointer twice.
116    ///
117    /// # See also
118    ///
119    /// - [`Z3_del_context`]
120    pub fn Z3_mk_context(c: Z3_config) -> Option<Z3_context>;
121    /// Create a context using the given configuration.
122    /// This function is similar to [`Z3_mk_context`]. However,
123    /// in the context returned by this function, the user
124    /// is responsible for managing `Z3_ast` reference counters.
125    /// Managing reference counters is a burden and error-prone,
126    /// but allows the user to use the memory more efficiently.
127    /// The user must invoke [`Z3_inc_ref`] for any `Z3_ast` returned
128    /// by Z3, and [`Z3_dec_ref`] whenever the `Z3_ast` is not needed
129    /// anymore. This idiom is similar to the one used in
130    /// BDD (binary decision diagrams) packages such as CUDD.
131    ///
132    /// Remarks:
133    ///
134    /// - `Z3_sort`, `Z3_func_decl`, `Z3_app`, `Z3_pattern` are `Z3_ast`'s.
135    /// - After a context is created, the configuration cannot be changed.
136    /// - All main interaction with Z3 happens in the context of a `Z3_context`.
137    /// - Z3 uses hash-consing, i.e., when the same `Z3_ast` is created twice,
138    /// Z3 will return the same pointer twice.
139    pub fn Z3_mk_context_rc(c: Z3_config) -> Option<Z3_context>;
140    /// Delete the given logical context.
141    ///
142    /// # See also
143    ///
144    /// - [`Z3_mk_context`]
145    pub fn Z3_del_context(c: Z3_context);
146    /// Increment the reference counter of the given AST.
147    /// The context `c` should have been created using [`Z3_mk_context_rc`].
148    /// This function is a NOOP if `c` was created using [`Z3_mk_context`].
149    pub fn Z3_inc_ref(c: Z3_context, a: Z3_ast);
150    /// Decrement the reference counter of the given AST.
151    /// The context `c` should have been created using [`Z3_mk_context_rc`].
152    /// This function is a NOOP if `c` was created using [`Z3_mk_context`].
153    pub fn Z3_dec_ref(c: Z3_context, a: Z3_ast);
154    /// Set a value of a context parameter.
155    ///
156    /// # See also
157    ///
158    /// - [`Z3_global_param_set`]
159    pub fn Z3_update_param_value(
160        c: Z3_context,
161        param_id: Z3_string,
162        param_value: Z3_string,
163    );
164    /// Retrieve description of global parameters.
165    pub fn Z3_get_global_param_descrs(c: Z3_context) -> Option<Z3_param_descrs>;
166    /// Interrupt the execution of a Z3 procedure.
167    /// This procedure can be used to interrupt: solvers, simplifiers and tactics.
168    pub fn Z3_interrupt(c: Z3_context);
169    /// use concurrency control for dec-ref.
170    /// Reference counting decrements are allowed in separate threads from the context.
171    /// If this setting is not invoked, reference counting decrements are not going to be thread safe.
172    pub fn Z3_enable_concurrent_dec_ref(c: Z3_context);
173    /// Create a Z3 (empty) parameter set.
174    /// Starting at Z3 4.0, parameter sets are used to configure many components such as:
175    /// simplifiers, tactics, solvers, etc.
176    ///
177    /// **Remark:** Reference counting must be used to manage parameter sets, even when the `Z3_context` was
178    /// created using [`Z3_mk_context`] instead of [`Z3_mk_context_rc`].
179    pub fn Z3_mk_params(c: Z3_context) -> Option<Z3_params>;
180    /// Increment the reference counter of the given parameter set.
181    pub fn Z3_params_inc_ref(c: Z3_context, p: Z3_params);
182    /// Decrement the reference counter of the given parameter set.
183    pub fn Z3_params_dec_ref(c: Z3_context, p: Z3_params);
184    /// Add a Boolean parameter `k` with value `v` to the parameter set `p`.
185    pub fn Z3_params_set_bool(c: Z3_context, p: Z3_params, k: Z3_symbol, v: bool);
186    /// Add a unsigned parameter `k` with value `v` to the parameter set `p`.
187    pub fn Z3_params_set_uint(
188        c: Z3_context,
189        p: Z3_params,
190        k: Z3_symbol,
191        v: ::core::ffi::c_uint,
192    );
193    /// Add a double parameter `k` with value `v` to the parameter set `p`.
194    pub fn Z3_params_set_double(c: Z3_context, p: Z3_params, k: Z3_symbol, v: f64);
195    /// Add a symbol parameter `k` with value `v` to the parameter set `p`.
196    pub fn Z3_params_set_symbol(c: Z3_context, p: Z3_params, k: Z3_symbol, v: Z3_symbol);
197    /// Convert a parameter set into a string. This function is mainly used for printing the
198    /// contents of a parameter set.
199    pub fn Z3_params_to_string(c: Z3_context, p: Z3_params) -> Z3_string;
200    /// Validate the parameter set `p` against the parameter description set `d`.
201    ///
202    /// The procedure invokes the error handler if `p` is invalid.
203    pub fn Z3_params_validate(c: Z3_context, p: Z3_params, d: Z3_param_descrs);
204    /// Increment the reference counter of the given parameter description set.
205    pub fn Z3_param_descrs_inc_ref(c: Z3_context, p: Z3_param_descrs);
206    /// Decrement the reference counter of the given parameter description set.
207    pub fn Z3_param_descrs_dec_ref(c: Z3_context, p: Z3_param_descrs);
208    /// Return the kind associated with the given parameter name `n`.
209    pub fn Z3_param_descrs_get_kind(
210        c: Z3_context,
211        p: Z3_param_descrs,
212        n: Z3_symbol,
213    ) -> Z3_param_kind;
214    /// Return the number of parameters in the given parameter description set.
215    pub fn Z3_param_descrs_size(
216        c: Z3_context,
217        p: Z3_param_descrs,
218    ) -> ::core::ffi::c_uint;
219    /// Return the name of the parameter at given index `i`.
220    ///
221    /// # Preconditions
222    ///
223    /// - `i < Z3_param_descrs_size(c, p)`
224    pub fn Z3_param_descrs_get_name(
225        c: Z3_context,
226        p: Z3_param_descrs,
227        i: ::core::ffi::c_uint,
228    ) -> Option<Z3_symbol>;
229    /// Retrieve documentation string corresponding to parameter name `s`.
230    pub fn Z3_param_descrs_get_documentation(
231        c: Z3_context,
232        p: Z3_param_descrs,
233        s: Z3_symbol,
234    ) -> Z3_string;
235    /// Convert a parameter description set into a string. This function is mainly used for printing the
236    /// contents of a parameter description set.
237    pub fn Z3_param_descrs_to_string(c: Z3_context, p: Z3_param_descrs) -> Z3_string;
238    /// Create a Z3 symbol using an integer.
239    ///
240    /// Symbols are used to name several term and type constructors.
241    ///
242    /// NB. Not all integers can be passed to this function.
243    /// The legal range of unsigned integers is 0 to 2^30-1.
244    ///
245    /// # See also
246    ///
247    /// - [`Z3_get_symbol_int`]
248    /// - [`Z3_mk_string_symbol`]
249    pub fn Z3_mk_int_symbol(c: Z3_context, i: ::core::ffi::c_int) -> Option<Z3_symbol>;
250    /// Create a Z3 symbol using a C string.
251    ///
252    /// Symbols are used to name several term and type constructors.
253    ///
254    /// # See also
255    ///
256    /// - [`Z3_get_symbol_string`]
257    /// - [`Z3_mk_int_symbol`]
258    pub fn Z3_mk_string_symbol(c: Z3_context, s: Z3_string) -> Option<Z3_symbol>;
259    /// Create a free (uninterpreted) type using the given name (symbol).
260    ///
261    /// Two free types are considered the same iff the have the same name.
262    pub fn Z3_mk_uninterpreted_sort(c: Z3_context, s: Z3_symbol) -> Option<Z3_sort>;
263    /// Create a type variable.
264    ///
265    /// Functions using type variables can be applied to instantiations that match the signature
266    /// of the function. Assertions using type variables correspond to assertions over all possible
267    /// instantiations.
268    pub fn Z3_mk_type_variable(c: Z3_context, s: Z3_symbol) -> Option<Z3_sort>;
269    /// Create the Boolean type.
270    ///
271    /// This type is used to create propositional variables and predicates.
272    pub fn Z3_mk_bool_sort(c: Z3_context) -> Option<Z3_sort>;
273    /// Create the integer type.
274    ///
275    /// This type is not the int type found in programming languages.
276    /// A machine integer can be represented using bit-vectors. The function
277    /// [`Z3_mk_bv_sort`] creates a bit-vector type.
278    ///
279    /// # See also
280    ///
281    /// - [`Z3_mk_bv_sort`]
282    pub fn Z3_mk_int_sort(c: Z3_context) -> Option<Z3_sort>;
283    /// Create the real type.
284    ///
285    /// Note that this type is not a floating point number.
286    pub fn Z3_mk_real_sort(c: Z3_context) -> Option<Z3_sort>;
287    /// Create a bit-vector type of the given size.
288    ///
289    /// This type can also be seen as a machine integer.
290    ///
291    /// **Remark:** The size of the bit-vector type must be greater than zero.
292    pub fn Z3_mk_bv_sort(c: Z3_context, sz: ::core::ffi::c_uint) -> Option<Z3_sort>;
293    /// Create a named finite domain sort.
294    ///
295    /// To create constants that belong to the finite domain,
296    /// use the APIs for creating numerals and pass a numeric
297    /// constant together with the sort returned by this call.
298    /// The numeric constant should be between 0 and the less
299    /// than the size of the domain.
300    ///
301    /// # See also
302    ///
303    /// - [`Z3_get_finite_domain_sort_size`]
304    pub fn Z3_mk_finite_domain_sort(
305        c: Z3_context,
306        name: Z3_symbol,
307        size: u64,
308    ) -> Option<Z3_sort>;
309    /// Create an array type.
310    ///
311    /// We usually represent the array type as: `[domain -> range]`.
312    /// Arrays are usually used to model the heap/memory in software verification.
313    ///
314    /// # See also
315    ///
316    /// - [`Z3_mk_select`]
317    /// - [`Z3_mk_store`]
318    pub fn Z3_mk_array_sort(
319        c: Z3_context,
320        domain: Z3_sort,
321        range: Z3_sort,
322    ) -> Option<Z3_sort>;
323    /// Create an array type with N arguments
324    ///
325    /// # See also
326    ///
327    /// - [`Z3_mk_select_n`]
328    /// - [`Z3_mk_store_n`]
329    pub fn Z3_mk_array_sort_n(
330        c: Z3_context,
331        n: ::core::ffi::c_uint,
332        domain: *const Z3_sort,
333        range: Z3_sort,
334    ) -> Option<Z3_sort>;
335    /// Create a tuple type.
336    ///
337    /// A tuple with `n` fields has a constructor and `n` projections.
338    /// This function will also declare the constructor and projection functions.
339    ///
340    /// - `c`: logical context
341    /// - `mk_tuple_name`: name of the constructor function associated with the tuple type.
342    /// - `num_fields`: number of fields in the tuple type.
343    /// - `field_names`: name of the projection functions.
344    /// - `field_sorts`: type of the tuple fields.
345    /// - `mk_tuple_decl`: output parameter that will contain the constructor declaration.
346    /// - `proj_decl`: output parameter that will contain the projection function declarations. This field must be a buffer of size `num_fields` allocated by the user.
347    pub fn Z3_mk_tuple_sort(
348        c: Z3_context,
349        mk_tuple_name: Z3_symbol,
350        num_fields: ::core::ffi::c_uint,
351        field_names: *const Z3_symbol,
352        field_sorts: *const Z3_sort,
353        mk_tuple_decl: *mut Z3_func_decl,
354        proj_decl: *mut Z3_func_decl,
355    ) -> Option<Z3_sort>;
356    /// Create a enumeration sort.
357    ///
358    /// An enumeration sort with `n` elements.
359    /// This function will also declare the functions corresponding to the enumerations.
360    ///
361    /// - `c`: logical context
362    /// - `name`: name of the enumeration sort.
363    /// - `n`: number of elements in enumeration sort.
364    /// - `enum_names`: names of the enumerated elements.
365    /// - `enum_consts`: constants corresponding to the enumerated elements.
366    /// - `enum_testers`: predicates testing if terms of the enumeration sort correspond to an enumeration.
367    ///
368    /// For example, if this function is called with three symbols A, B, C and the name S, then
369    /// `s` is a sort whose name is S, and the function returns three terms corresponding to A, B, C in
370    /// `enum_consts`. The array `enum_testers` has three predicates of type `(s -> Bool)`.
371    /// The first predicate (corresponding to A) is true when applied to A, and false otherwise.
372    /// Similarly for the other predicates.
373    pub fn Z3_mk_enumeration_sort(
374        c: Z3_context,
375        name: Z3_symbol,
376        n: ::core::ffi::c_uint,
377        enum_names: *const Z3_symbol,
378        enum_consts: *mut Z3_func_decl,
379        enum_testers: *mut Z3_func_decl,
380    ) -> Option<Z3_sort>;
381    /// Create a list sort
382    ///
383    /// A list sort over `elem_sort`
384    /// This function declares the corresponding constructors and testers for lists.
385    ///
386    /// - `c`: logical context
387    /// - `name`: name of the list sort.
388    /// - `elem_sort`: sort of list elements.
389    /// - `nil_decl`: declaration for the empty list.
390    /// - `is_nil_decl`: test for the empty list.
391    /// - `cons_decl`: declaration for a cons cell.
392    /// - `is_cons_decl`: cons cell test.
393    /// - `head_decl`: list head.
394    /// - `tail_decl`: list tail.
395    pub fn Z3_mk_list_sort(
396        c: Z3_context,
397        name: Z3_symbol,
398        elem_sort: Z3_sort,
399        nil_decl: *mut Z3_func_decl,
400        is_nil_decl: *mut Z3_func_decl,
401        cons_decl: *mut Z3_func_decl,
402        is_cons_decl: *mut Z3_func_decl,
403        head_decl: *mut Z3_func_decl,
404        tail_decl: *mut Z3_func_decl,
405    ) -> Option<Z3_sort>;
406    /// Retrieve the number of fields of a constructor
407    ///
408    /// - `c`: logical context.
409    /// - `constr`: constructor.
410    pub fn Z3_constructor_num_fields(
411        c: Z3_context,
412        constr: Z3_constructor,
413    ) -> ::core::ffi::c_uint;
414    /// Reclaim memory allocated to constructor.
415    ///
416    /// - `c`: logical context.
417    /// - `constr`: constructor.
418    ///
419    /// # See also
420    ///
421    /// - [`Z3_mk_constructor`]
422    pub fn Z3_del_constructor(c: Z3_context, constr: Z3_constructor);
423    /// Create datatype, such as lists, trees, records, enumerations or unions of records.
424    /// The datatype may be recursive. Return the datatype sort.
425    ///
426    /// - `c`: logical context.
427    /// - `name`: name of datatype.
428    /// - `num_constructors`: number of constructors passed in.
429    /// - `constructors`: array of constructor containers.
430    ///
431    /// # See also
432    ///
433    /// - [`Z3_mk_constructor`]
434    /// - [`Z3_mk_constructor_list`]
435    /// - [`Z3_mk_datatypes`]
436    pub fn Z3_mk_datatype(
437        c: Z3_context,
438        name: Z3_symbol,
439        num_constructors: ::core::ffi::c_uint,
440        constructors: *mut Z3_constructor,
441    ) -> Option<Z3_sort>;
442    /// Create a parametric datatype with explicit type parameters.
443    ///
444    /// This function is similar to [`Z3_mk_datatype`], except it takes an explicit set of type parameters.
445    /// The parameters can be type variables created with [`Z3_mk_type_variable`], allowing the definition
446    /// of polymorphic datatypes that can be instantiated with different concrete types.
447    ///
448    /// - `c`: logical context
449    /// - `name`: name of the datatype
450    /// - `num_parameters`: number of type parameters (can be 0)
451    /// - `parameters`: array of type parameters (type variables or concrete sorts)
452    /// - `num_constructors`: number of constructors
453    /// - `constructors`: array of constructor specifications
454    ///
455    /// # See also
456    ///
457    /// - [`Z3_mk_datatype`]
458    /// - [`Z3_mk_type_variable`]
459    /// - [`Z3_mk_datatype_sort`]
460    pub fn Z3_mk_polymorphic_datatype(
461        c: Z3_context,
462        name: Z3_symbol,
463        num_parameters: ::core::ffi::c_uint,
464        parameters: *mut Z3_sort,
465        num_constructors: ::core::ffi::c_uint,
466        constructors: *mut Z3_constructor,
467    ) -> Option<Z3_sort>;
468    /// create a forward reference to a recursive datatype being declared.
469    /// The forward reference can be used in a nested occurrence: the range of an array
470    /// or as element sort of a sequence. The forward reference should only be used when
471    /// used in an accessor for a recursive datatype that gets declared.
472    ///
473    /// Forward references can replace the use sort references, that are unsigned integers
474    /// in the `Z3_mk_constructor` call
475    ///
476    /// - `c`: logical context
477    /// - `name`: name of the datatype
478    /// - `num_params`: number of sort parameters
479    /// - `params`: array of sort parameters
480    pub fn Z3_mk_datatype_sort(
481        c: Z3_context,
482        name: Z3_symbol,
483        num_params: ::core::ffi::c_uint,
484        params: *const Z3_sort,
485    ) -> Option<Z3_sort>;
486    /// Create list of constructors.
487    ///
488    /// - `c`: logical context.
489    /// - `num_constructors`: number of constructors in list.
490    /// - `constructors`: list of constructors.
491    ///
492    /// # See also
493    ///
494    /// - [`Z3_del_constructor_list`]
495    /// - [`Z3_mk_constructor`]
496    pub fn Z3_mk_constructor_list(
497        c: Z3_context,
498        num_constructors: ::core::ffi::c_uint,
499        constructors: *const Z3_constructor,
500    ) -> Option<Z3_constructor_list>;
501    /// Reclaim memory allocated for constructor list.
502    ///
503    /// Each constructor inside the constructor list must be independently reclaimed using [`Z3_del_constructor`].
504    ///
505    /// - `c`: logical context.
506    /// - `clist`: constructor list container.
507    ///
508    /// # See also
509    ///
510    /// - [`Z3_mk_constructor_list`]
511    pub fn Z3_del_constructor_list(c: Z3_context, clist: Z3_constructor_list);
512    /// Create mutually recursive datatypes.
513    ///
514    /// - `c`: logical context.
515    /// - `num_sorts`: number of datatype sorts.
516    /// - `sort_names`: names of datatype sorts.
517    /// - `sorts`: array of datatype sorts.
518    /// - `constructor_lists`: list of constructors, one list per sort.
519    ///
520    /// # See also
521    ///
522    /// - [`Z3_mk_constructor`]
523    /// - [`Z3_mk_constructor_list`]
524    /// - [`Z3_mk_datatype`]
525    pub fn Z3_mk_datatypes(
526        c: Z3_context,
527        num_sorts: ::core::ffi::c_uint,
528        sort_names: *const Z3_symbol,
529        sorts: *mut Z3_sort,
530        constructor_lists: *mut Z3_constructor_list,
531    );
532    /// Query constructor for declared functions.
533    ///
534    /// - `c`: logical context.
535    /// - `constr`: constructor container. The container must have been passed into a [`Z3_mk_datatype`] call.
536    /// - `num_fields`: number of accessor fields in the constructor.
537    /// - `constructor`: constructor function declaration, allocated by user.
538    /// - `tester`: constructor test function declaration, allocated by user.
539    /// - `accessors`: array of accessor function declarations allocated by user. The array must contain num_fields elements.
540    ///
541    /// # See also
542    ///
543    /// - [`Z3_mk_constructor`]
544    pub fn Z3_query_constructor(
545        c: Z3_context,
546        constr: Z3_constructor,
547        num_fields: ::core::ffi::c_uint,
548        constructor: *mut Z3_func_decl,
549        tester: *mut Z3_func_decl,
550        accessors: *mut Z3_func_decl,
551    );
552    /// Declare a constant or function.
553    ///
554    /// - `c`: logical context.
555    /// - `s`: name of the constant or function.
556    /// - `domain_size`: number of arguments. It is 0 when declaring a constant.
557    /// - `domain`: array containing the sort of each argument. The array must contain domain_size elements. It is 0 when declaring a constant.
558    /// - `range`: sort of the constant or the return sort of the function.
559    ///
560    /// After declaring a constant or function, the function
561    /// [`Z3_mk_app`] can be used to create a constant or function
562    /// application.
563    ///
564    /// # See also
565    ///
566    /// - [`Z3_mk_app`]
567    /// - [`Z3_mk_fresh_func_decl`]
568    /// - [`Z3_mk_rec_func_decl`]
569    pub fn Z3_mk_func_decl(
570        c: Z3_context,
571        s: Z3_symbol,
572        domain_size: ::core::ffi::c_uint,
573        domain: *const Z3_sort,
574        range: Z3_sort,
575    ) -> Option<Z3_func_decl>;
576    /// Create a constant or function application.
577    ///
578    /// # See also
579    ///
580    /// - [`Z3_mk_fresh_func_decl`]
581    /// - [`Z3_mk_func_decl`]
582    /// - [`Z3_mk_rec_func_decl`]
583    pub fn Z3_mk_app(
584        c: Z3_context,
585        d: Z3_func_decl,
586        num_args: ::core::ffi::c_uint,
587        args: *const Z3_ast,
588    ) -> Option<Z3_ast>;
589    /// Declare and create a constant.
590    ///
591    /// This function is a shorthand for:
592    /// ```c
593    /// Z3_func_decl d = Z3_mk_func_decl(c, s, 0, 0, ty);
594    /// Z3_ast n            = Z3_mk_app(c, d, 0, 0);
595    /// ```
596    ///
597    /// # See also
598    ///
599    /// - [`Z3_mk_app`]
600    /// - [`Z3_mk_fresh_const`]
601    /// - [`Z3_mk_func_decl`]
602    pub fn Z3_mk_const(c: Z3_context, s: Z3_symbol, ty: Z3_sort) -> Option<Z3_ast>;
603    /// Declare a fresh constant or function.
604    ///
605    /// Z3 will generate an unique name for this function declaration.
606    /// If prefix is different from `NULL`, then the name generate by Z3 will start with `prefix`.
607    ///
608    /// **Remark:** If `prefix` is `NULL`, then it is assumed to be the empty string.
609    ///
610    /// # See also
611    ///
612    /// - [`Z3_mk_func_decl`]
613    pub fn Z3_mk_fresh_func_decl(
614        c: Z3_context,
615        prefix: Z3_string,
616        domain_size: ::core::ffi::c_uint,
617        domain: *const Z3_sort,
618        range: Z3_sort,
619    ) -> Option<Z3_func_decl>;
620    /// Declare and create a fresh constant.
621    ///
622    /// This function is a shorthand for:
623    /// `Z3_func_decl d = Z3_mk_fresh_func_decl(c, prefix, 0, 0, ty); Z3_ast n = Z3_mk_app(c, d, 0, 0);`
624    ///
625    /// **Remark:** If `prefix` is `NULL`, then it is assumed to be the empty string.
626    ///
627    /// # See also
628    ///
629    /// - [`Z3_mk_app`]
630    /// - [`Z3_mk_const`]
631    /// - [`Z3_mk_fresh_func_decl`]
632    /// - [`Z3_mk_func_decl`]
633    pub fn Z3_mk_fresh_const(
634        c: Z3_context,
635        prefix: Z3_string,
636        ty: Z3_sort,
637    ) -> Option<Z3_ast>;
638    /// Declare a recursive function
639    ///
640    /// - `c`: logical context.
641    /// - `s`: name of the function.
642    /// - `domain_size`: number of arguments. It should be greater than 0.
643    /// - `domain`: array containing the sort of each argument. The array must contain domain_size elements.
644    /// - `range`: sort of the constant or the return sort of the function.
645    ///
646    /// After declaring recursive function, it should be associated with a recursive definition [`Z3_add_rec_def`].
647    /// The function [`Z3_mk_app`] can be used to create a constant or function
648    /// application.
649    ///
650    /// # See also
651    ///
652    /// - [`Z3_add_rec_def`]
653    /// - [`Z3_mk_app`]
654    /// - [`Z3_mk_func_decl`]
655    pub fn Z3_mk_rec_func_decl(
656        c: Z3_context,
657        s: Z3_symbol,
658        domain_size: ::core::ffi::c_uint,
659        domain: *const Z3_sort,
660        range: Z3_sort,
661    ) -> Option<Z3_func_decl>;
662    /// Define the body of a recursive function.
663    ///
664    /// - `c`: logical context.
665    /// - `f`: function declaration.
666    /// - `n`: number of arguments to the function
667    /// - `args`: constants that are used as arguments to the recursive function in the definition.
668    /// - `body`: body of the recursive function
669    ///
670    /// After declaring a recursive function or a collection of mutually recursive functions, use
671    /// this function to provide the definition for the recursive function.
672    ///
673    /// # See also
674    ///
675    /// - [`Z3_mk_rec_func_decl`]
676    pub fn Z3_add_rec_def(
677        c: Z3_context,
678        f: Z3_func_decl,
679        n: ::core::ffi::c_uint,
680        args: *mut Z3_ast,
681        body: Z3_ast,
682    );
683    /// Create an AST node representing `true`.
684    pub fn Z3_mk_true(c: Z3_context) -> Option<Z3_ast>;
685    /// Create an AST node representing `false`.
686    pub fn Z3_mk_false(c: Z3_context) -> Option<Z3_ast>;
687    /// Create an AST node representing `l = r`.
688    ///
689    /// The nodes `l` and `r` must have the same type.
690    pub fn Z3_mk_eq(c: Z3_context, l: Z3_ast, r: Z3_ast) -> Option<Z3_ast>;
691    /// Create an AST node representing `distinct(args[0], ..., args[num_args-1])`.
692    ///
693    /// The `distinct` construct is used for declaring the arguments pairwise distinct.
694    /// That is, `Forall 0 <= i < j < num_args. not args[i] = args[j]`.
695    ///
696    /// All arguments must have the same sort.
697    ///
698    /// **Remark:** The number of arguments of a distinct construct must be greater than one.
699    pub fn Z3_mk_distinct(
700        c: Z3_context,
701        num_args: ::core::ffi::c_uint,
702        args: *const Z3_ast,
703    ) -> Option<Z3_ast>;
704    /// Create an AST node representing `not(a)`.
705    ///
706    /// The node `a` must have Boolean sort.
707    pub fn Z3_mk_not(c: Z3_context, a: Z3_ast) -> Option<Z3_ast>;
708    /// Create an AST node representing an if-then-else: `ite(t1, t2, t3)`.
709    ///
710    /// The node `t1` must have Boolean sort, `t2` and `t3` must have the same sort.
711    /// The sort of the new node is equal to the sort of `t2` and `t3`.
712    pub fn Z3_mk_ite(
713        c: Z3_context,
714        t1: Z3_ast,
715        t2: Z3_ast,
716        t3: Z3_ast,
717    ) -> Option<Z3_ast>;
718    /// Create an AST node representing `t1 iff t2`.
719    ///
720    /// The nodes `t1` and `t2` must have Boolean sort.
721    pub fn Z3_mk_iff(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
722    /// Create an AST node representing `t1 implies t2`.
723    ///
724    /// The nodes `t1` and `t2` must have Boolean sort.
725    pub fn Z3_mk_implies(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
726    /// Create an AST node representing `t1 xor t2`.
727    ///
728    /// The nodes `t1` and `t2` must have Boolean sort.
729    pub fn Z3_mk_xor(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
730    /// Create an AST node representing `args[0] and ... and args[num_args-1]`.
731    ///
732    /// The array `args` must have `num_args` elements.
733    /// All arguments must have Boolean sort.
734    ///
735    /// **Remark:** The number of arguments must be greater than zero.
736    pub fn Z3_mk_and(
737        c: Z3_context,
738        num_args: ::core::ffi::c_uint,
739        args: *const Z3_ast,
740    ) -> Option<Z3_ast>;
741    /// Create an AST node representing `args[0] or ... or args[num_args-1]`.
742    ///
743    /// The array `args` must have `num_args` elements.
744    /// All arguments must have Boolean sort.
745    ///
746    /// **Remark:** The number of arguments must be greater than zero.
747    pub fn Z3_mk_or(
748        c: Z3_context,
749        num_args: ::core::ffi::c_uint,
750        args: *const Z3_ast,
751    ) -> Option<Z3_ast>;
752    /// Create an AST node representing `args[0] + ... + args[num_args-1]`.
753    ///
754    /// The array `args` must have `num_args` elements.
755    /// All arguments must have int or real sort.
756    ///
757    /// **Remark:** The number of arguments must be greater than zero.
758    pub fn Z3_mk_add(
759        c: Z3_context,
760        num_args: ::core::ffi::c_uint,
761        args: *const Z3_ast,
762    ) -> Option<Z3_ast>;
763    /// Create an AST node representing `args[0] * ... * args[num_args-1]`.
764    ///
765    /// The array `args` must have `num_args` elements.
766    /// All arguments must have int or real sort.
767    ///
768    /// **Remark:** Z3 has limited support for non-linear arithmetic.
769    /// **Remark:** The number of arguments must be greater than zero.
770    pub fn Z3_mk_mul(
771        c: Z3_context,
772        num_args: ::core::ffi::c_uint,
773        args: *const Z3_ast,
774    ) -> Option<Z3_ast>;
775    /// Create an AST node representing `args[0] - ... - args[num_args - 1]`.
776    ///
777    /// The array `args` must have `num_args` elements.
778    /// All arguments must have int or real sort.
779    ///
780    /// **Remark:** The number of arguments must be greater than zero.
781    pub fn Z3_mk_sub(
782        c: Z3_context,
783        num_args: ::core::ffi::c_uint,
784        args: *const Z3_ast,
785    ) -> Option<Z3_ast>;
786    /// Create an AST node representing `- arg`.
787    ///
788    /// The arguments must have int or real type.
789    pub fn Z3_mk_unary_minus(c: Z3_context, arg: Z3_ast) -> Option<Z3_ast>;
790    /// Create an AST node representing `arg1 div arg2`.
791    ///
792    /// The arguments must either both have int type or both have real type.
793    /// If the arguments have int type, then the result type is an int type, otherwise the
794    /// the result type is real.
795    pub fn Z3_mk_div(c: Z3_context, arg1: Z3_ast, arg2: Z3_ast) -> Option<Z3_ast>;
796    /// Create an AST node representing `arg1 mod arg2`.
797    ///
798    /// The arguments must have int type.
799    pub fn Z3_mk_mod(c: Z3_context, arg1: Z3_ast, arg2: Z3_ast) -> Option<Z3_ast>;
800    /// Create an AST node representing `arg1 rem arg2`.
801    ///
802    /// The arguments must have int type.
803    pub fn Z3_mk_rem(c: Z3_context, arg1: Z3_ast, arg2: Z3_ast) -> Option<Z3_ast>;
804    /// Create an AST node representing `arg1 ^ arg2`.
805    ///
806    /// The arguments must have int or real type.
807    pub fn Z3_mk_power(c: Z3_context, arg1: Z3_ast, arg2: Z3_ast) -> Option<Z3_ast>;
808    /// Take the absolute value of an integer
809    pub fn Z3_mk_abs(c: Z3_context, arg: Z3_ast) -> Option<Z3_ast>;
810    /// Create less than.
811    ///
812    /// The nodes `t1` and `t2` must have the same sort, and must be int or real.
813    pub fn Z3_mk_lt(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
814    /// Create less than or equal to.
815    ///
816    /// The nodes `t1` and `t2` must have the same sort, and must be int or real.
817    pub fn Z3_mk_le(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
818    /// Create greater than.
819    ///
820    /// The nodes `t1` and `t2` must have the same sort, and must be int or real.
821    pub fn Z3_mk_gt(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
822    /// Create greater than or equal to.
823    ///
824    /// The nodes `t1` and `t2` must have the same sort, and must be int or real.
825    pub fn Z3_mk_ge(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
826    /// Create division predicate.
827    ///
828    /// The nodes `t1` and `t2` must be of integer sort.
829    /// The predicate is true when `t1` divides `t2`. For the predicate to be part of
830    /// linear integer arithmetic, the first argument `t1` must be a non-zero integer.
831    pub fn Z3_mk_divides(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
832    /// Coerce an integer to a real.
833    ///
834    /// There is also a converse operation exposed.
835    /// It follows the semantics prescribed by the SMT-LIB standard.
836    ///
837    /// You can take the floor of a real by
838    /// creating an auxiliary integer constant `k` and
839    /// and asserting `mk_int2real(k) <= t1 < mk_int2real(k)+1`.
840    ///
841    /// The node `t1` must have sort integer.
842    ///
843    /// # See also
844    ///
845    /// - [`Z3_mk_real2int`]
846    /// - [`Z3_mk_is_int`]
847    pub fn Z3_mk_int2real(c: Z3_context, t1: Z3_ast) -> Option<Z3_ast>;
848    /// Coerce a real to an integer.
849    ///
850    /// The semantics of this function follows the SMT-LIB standard
851    /// for the function to_int
852    ///
853    /// # See also
854    ///
855    /// - [`Z3_mk_int2real`]
856    /// - [`Z3_mk_is_int`]
857    pub fn Z3_mk_real2int(c: Z3_context, t1: Z3_ast) -> Option<Z3_ast>;
858    /// Check if a real number is an integer.
859    ///
860    /// # See also
861    ///
862    /// - [`Z3_mk_int2real`]
863    /// - [`Z3_mk_real2int`]
864    pub fn Z3_mk_is_int(c: Z3_context, t1: Z3_ast) -> Option<Z3_ast>;
865    /// Bitwise negation.
866    ///
867    /// The node `t1` must have a bit-vector sort.
868    pub fn Z3_mk_bvnot(c: Z3_context, t1: Z3_ast) -> Option<Z3_ast>;
869    /// Take conjunction of bits in vector, return vector of length 1.
870    ///
871    /// The node `t1` must have a bit-vector sort.
872    pub fn Z3_mk_bvredand(c: Z3_context, t1: Z3_ast) -> Option<Z3_ast>;
873    /// Take disjunction of bits in vector, return vector of length 1.
874    ///
875    /// The node `t1` must have a bit-vector sort.
876    pub fn Z3_mk_bvredor(c: Z3_context, t1: Z3_ast) -> Option<Z3_ast>;
877    /// Bitwise and.
878    ///
879    /// The nodes `t1` and `t2` must have the same bit-vector sort.
880    pub fn Z3_mk_bvand(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
881    /// Bitwise or.
882    ///
883    /// The nodes `t1` and `t2` must have the same bit-vector sort.
884    pub fn Z3_mk_bvor(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
885    /// Bitwise exclusive-or.
886    ///
887    /// The nodes `t1` and `t2` must have the same bit-vector sort.
888    pub fn Z3_mk_bvxor(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
889    /// Bitwise nand.
890    ///
891    /// The nodes `t1` and `t2` must have the same bit-vector sort.
892    pub fn Z3_mk_bvnand(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
893    /// Bitwise nor.
894    ///
895    /// The nodes `t1` and `t2` must have the same bit-vector sort.
896    pub fn Z3_mk_bvnor(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
897    /// Bitwise xnor.
898    ///
899    /// The nodes `t1` and `t2` must have the same bit-vector sort.
900    pub fn Z3_mk_bvxnor(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
901    /// Standard two's complement unary minus.
902    ///
903    /// The node `t1` must have bit-vector sort.
904    pub fn Z3_mk_bvneg(c: Z3_context, t1: Z3_ast) -> Option<Z3_ast>;
905    /// Standard two's complement addition.
906    ///
907    /// The nodes `t1` and `t2` must have the same bit-vector sort.
908    pub fn Z3_mk_bvadd(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
909    /// Standard two's complement subtraction.
910    ///
911    /// The nodes `t1` and `t2` must have the same bit-vector sort.
912    pub fn Z3_mk_bvsub(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
913    /// Standard two's complement multiplication.
914    ///
915    /// The nodes `t1` and `t2` must have the same bit-vector sort.
916    pub fn Z3_mk_bvmul(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
917    /// Unsigned division.
918    ///
919    /// It is defined as the `floor` of `t1/t2` if `t2` is
920    /// different from zero. If `t2` is zero, then the result
921    /// is undefined.
922    ///
923    /// The nodes `t1` and `t2` must have the same bit-vector sort.
924    pub fn Z3_mk_bvudiv(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
925    /// Two's complement signed division.
926    ///
927    /// It is defined in the following way:
928    ///
929    /// - The `floor` of `t1/t2` if `t2` is different from zero, and `t1*t2 >= 0`.
930    ///
931    /// - The `ceiling` of `t1/t2` if `t2` is different from zero, and `t1*t2 < 0`.
932    ///
933    /// If `t2` is zero, then the result is undefined.
934    ///
935    /// The nodes `t1` and `t2` must have the same bit-vector sort.
936    pub fn Z3_mk_bvsdiv(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
937    /// Unsigned remainder.
938    ///
939    /// It is defined as `t1 - (t1 /u t2) * t2`, where `/u` represents unsigned division.
940    ///
941    /// If `t2` is zero, then the result is undefined.
942    ///
943    /// The nodes `t1` and `t2` must have the same bit-vector sort.
944    pub fn Z3_mk_bvurem(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
945    /// Two's complement signed remainder (sign follows dividend).
946    ///
947    /// It is defined as `t1 - (t1 /s t2) * t2`, where `/s` represents signed division.
948    /// The most significant bit (sign) of the result is equal to the most significant bit of `t1`.
949    ///
950    /// If `t2` is zero, then the result is undefined.
951    ///
952    /// The nodes `t1` and `t2` must have the same bit-vector sort.
953    ///
954    /// # See also
955    ///
956    /// - [`Z3_mk_bvsmod`]
957    pub fn Z3_mk_bvsrem(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
958    /// Two's complement signed remainder (sign follows divisor).
959    ///
960    /// If `t2` is zero, then the result is undefined.
961    ///
962    /// The nodes `t1` and `t2` must have the same bit-vector sort.
963    ///
964    /// # See also
965    ///
966    /// - [`Z3_mk_bvsrem`]
967    pub fn Z3_mk_bvsmod(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
968    /// Unsigned less than.
969    ///
970    /// The nodes `t1` and `t2` must have the same bit-vector sort.
971    pub fn Z3_mk_bvult(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
972    /// Two's complement signed less than.
973    ///
974    /// It abbreviates:
975    /// ```c
976    /// (or (and (= (extract[|m-1|:|m-1|] t1) bit1)
977    /// (= (extract[|m-1|:|m-1|] t2) bit0))
978    /// (and (= (extract[|m-1|:|m-1|] t1) (extract[|m-1|:|m-1|] t2))
979    /// (bvult t1 t2)))
980    /// ```
981    ///
982    /// The nodes `t1` and `t2` must have the same bit-vector sort.
983    pub fn Z3_mk_bvslt(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
984    /// Unsigned less than or equal to.
985    ///
986    /// The nodes `t1` and `t2` must have the same bit-vector sort.
987    pub fn Z3_mk_bvule(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
988    /// Two's complement signed less than or equal to.
989    ///
990    /// The nodes `t1` and `t2` must have the same bit-vector sort.
991    pub fn Z3_mk_bvsle(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
992    /// Unsigned greater than or equal to.
993    ///
994    /// The nodes `t1` and `t2` must have the same bit-vector sort.
995    pub fn Z3_mk_bvuge(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
996    /// Two's complement signed greater than or equal to.
997    ///
998    /// The nodes `t1` and `t2` must have the same bit-vector sort.
999    pub fn Z3_mk_bvsge(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
1000    /// Unsigned greater than.
1001    ///
1002    /// The nodes `t1` and `t2` must have the same bit-vector sort.
1003    pub fn Z3_mk_bvugt(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
1004    /// Two's complement signed greater than.
1005    ///
1006    /// The nodes `t1` and `t2` must have the same bit-vector sort.
1007    pub fn Z3_mk_bvsgt(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
1008    /// Concatenate the given bit-vectors.
1009    ///
1010    /// The nodes `t1` and `t2` must have (possibly different) bit-vector sorts
1011    ///
1012    /// The result is a bit-vector of size `n1+n2`, where `n1` (`n2`) is the size
1013    /// of `t1` (`t2`).
1014    pub fn Z3_mk_concat(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
1015    /// Extract the bits `high` down to `low` from a bit-vector of
1016    /// size `m` to yield a new bit-vector of size `n`, where `n = high - low + 1`.
1017    ///
1018    /// The node `t1` must have a bit-vector sort.
1019    pub fn Z3_mk_extract(
1020        c: Z3_context,
1021        high: ::core::ffi::c_uint,
1022        low: ::core::ffi::c_uint,
1023        t1: Z3_ast,
1024    ) -> Option<Z3_ast>;
1025    /// Sign-extend of the given bit-vector to the (signed) equivalent bit-vector of
1026    /// size `m+i`, where `m` is the size of the given
1027    /// bit-vector.
1028    ///
1029    /// The node `t1` must have a bit-vector sort.
1030    pub fn Z3_mk_sign_ext(
1031        c: Z3_context,
1032        i: ::core::ffi::c_uint,
1033        t1: Z3_ast,
1034    ) -> Option<Z3_ast>;
1035    /// Extend the given bit-vector with zeros to the (unsigned) equivalent
1036    /// bit-vector of size `m+i`, where `m` is the size of the
1037    /// given bit-vector.
1038    ///
1039    /// The node `t1` must have a bit-vector sort.
1040    pub fn Z3_mk_zero_ext(
1041        c: Z3_context,
1042        i: ::core::ffi::c_uint,
1043        t1: Z3_ast,
1044    ) -> Option<Z3_ast>;
1045    /// Repeat the given bit-vector up length `i`.
1046    ///
1047    /// The node `t1` must have a bit-vector sort.
1048    pub fn Z3_mk_repeat(
1049        c: Z3_context,
1050        i: ::core::ffi::c_uint,
1051        t1: Z3_ast,
1052    ) -> Option<Z3_ast>;
1053    /// Extracts the bit at position `i` of a bit-vector and
1054    /// yields a boolean.
1055    ///
1056    /// The node `t1` must have a bit-vector sort.
1057    pub fn Z3_mk_bit2bool(
1058        c: Z3_context,
1059        i: ::core::ffi::c_uint,
1060        t1: Z3_ast,
1061    ) -> Option<Z3_ast>;
1062    /// Shift left.
1063    ///
1064    /// It is equivalent to multiplication by `2^x` where `x` is the value of the
1065    /// third argument.
1066    ///
1067    /// NB. The semantics of shift operations varies between environments. This
1068    /// definition does not necessarily capture directly the semantics of the
1069    /// programming language or assembly architecture you are modeling.
1070    ///
1071    /// The nodes `t1` and `t2` must have the same bit-vector sort.
1072    pub fn Z3_mk_bvshl(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
1073    /// Logical shift right.
1074    ///
1075    /// It is equivalent to unsigned division by `2^x` where `x` is the
1076    /// value of the third argument.
1077    ///
1078    /// NB. The semantics of shift operations varies between environments. This
1079    /// definition does not necessarily capture directly the semantics of the
1080    /// programming language or assembly architecture you are modeling.
1081    ///
1082    /// The nodes `t1` and `t2` must have the same bit-vector sort.
1083    pub fn Z3_mk_bvlshr(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
1084    /// Arithmetic shift right.
1085    ///
1086    /// It is like logical shift right except that the most significant
1087    /// bits of the result always copy the most significant bit of the
1088    /// second argument.
1089    ///
1090    /// The semantics of shift operations varies between environments. This
1091    /// definition does not necessarily capture directly the semantics of the
1092    /// programming language or assembly architecture you are modeling.
1093    ///
1094    /// The nodes `t1` and `t2` must have the same bit-vector sort.
1095    pub fn Z3_mk_bvashr(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
1096    /// Rotate bits of `t1` to the left `i` times.
1097    ///
1098    /// The node `t1` must have a bit-vector sort.
1099    pub fn Z3_mk_rotate_left(
1100        c: Z3_context,
1101        i: ::core::ffi::c_uint,
1102        t1: Z3_ast,
1103    ) -> Option<Z3_ast>;
1104    /// Rotate bits of `t1` to the right `i` times.
1105    ///
1106    /// The node `t1` must have a bit-vector sort.
1107    pub fn Z3_mk_rotate_right(
1108        c: Z3_context,
1109        i: ::core::ffi::c_uint,
1110        t1: Z3_ast,
1111    ) -> Option<Z3_ast>;
1112    /// Rotate bits of `t1` to the left `t2` times.
1113    ///
1114    /// The nodes `t1` and `t2` must have the same bit-vector sort.
1115    pub fn Z3_mk_ext_rotate_left(
1116        c: Z3_context,
1117        t1: Z3_ast,
1118        t2: Z3_ast,
1119    ) -> Option<Z3_ast>;
1120    /// Rotate bits of `t1` to the right `t2` times.
1121    ///
1122    /// The nodes `t1` and `t2` must have the same bit-vector sort.
1123    pub fn Z3_mk_ext_rotate_right(
1124        c: Z3_context,
1125        t1: Z3_ast,
1126        t2: Z3_ast,
1127    ) -> Option<Z3_ast>;
1128    /// Create an `n` bit bit-vector from the integer argument `t1`.
1129    ///
1130    /// The resulting bit-vector has `n` bits, where the i'th bit (counting
1131    /// from 0 to `n`-1) is 1 if `(t1 div 2^i)` mod 2 is 1.
1132    ///
1133    /// The node `t1` must have integer sort.
1134    pub fn Z3_mk_int2bv(
1135        c: Z3_context,
1136        n: ::core::ffi::c_uint,
1137        t1: Z3_ast,
1138    ) -> Option<Z3_ast>;
1139    /// Create an integer from the bit-vector argument `t1`.
1140    /// If `is_signed` is false, then the bit-vector `t1` is treated as unsigned.
1141    /// So the result is non-negative
1142    /// and in the range `[0..2^N-1]`, where N are the number of bits in `t1`.
1143    /// If `is_signed` is true, `t1` is treated as a signed bit-vector.
1144    ///
1145    ///
1146    /// The node `t1` must have a bit-vector sort.
1147    pub fn Z3_mk_bv2int(c: Z3_context, t1: Z3_ast, is_signed: bool) -> Option<Z3_ast>;
1148    /// Create a predicate that checks that the bit-wise addition
1149    /// of `t1` and `t2` does not overflow.
1150    ///
1151    /// The nodes `t1` and `t2` must have the same bit-vector sort.
1152    /// The returned node is of sort Bool.
1153    pub fn Z3_mk_bvadd_no_overflow(
1154        c: Z3_context,
1155        t1: Z3_ast,
1156        t2: Z3_ast,
1157        is_signed: bool,
1158    ) -> Option<Z3_ast>;
1159    /// Create a predicate that checks that the bit-wise signed addition
1160    /// of `t1` and `t2` does not underflow.
1161    ///
1162    /// The nodes `t1` and `t2` must have the same bit-vector sort.
1163    /// The returned node is of sort Bool.
1164    pub fn Z3_mk_bvadd_no_underflow(
1165        c: Z3_context,
1166        t1: Z3_ast,
1167        t2: Z3_ast,
1168    ) -> Option<Z3_ast>;
1169    /// Create a predicate that checks that the bit-wise signed subtraction
1170    /// of `t1` and `t2` does not overflow.
1171    ///
1172    /// The nodes `t1` and `t2` must have the same bit-vector sort.
1173    /// The returned node is of sort Bool.
1174    pub fn Z3_mk_bvsub_no_overflow(
1175        c: Z3_context,
1176        t1: Z3_ast,
1177        t2: Z3_ast,
1178    ) -> Option<Z3_ast>;
1179    /// Create a predicate that checks that the bit-wise subtraction
1180    /// of `t1` and `t2` does not underflow.
1181    ///
1182    /// The nodes `t1` and `t2` must have the same bit-vector sort.
1183    /// The returned node is of sort Bool.
1184    pub fn Z3_mk_bvsub_no_underflow(
1185        c: Z3_context,
1186        t1: Z3_ast,
1187        t2: Z3_ast,
1188        is_signed: bool,
1189    ) -> Option<Z3_ast>;
1190    /// Create a predicate that checks that the bit-wise signed division
1191    /// of `t1` and `t2` does not overflow.
1192    ///
1193    /// The nodes `t1` and `t2` must have the same bit-vector sort.
1194    /// The returned node is of sort Bool.
1195    pub fn Z3_mk_bvsdiv_no_overflow(
1196        c: Z3_context,
1197        t1: Z3_ast,
1198        t2: Z3_ast,
1199    ) -> Option<Z3_ast>;
1200    /// Check that bit-wise negation does not overflow when
1201    /// `t1` is interpreted as a signed bit-vector.
1202    ///
1203    /// The node `t1` must have bit-vector sort.
1204    /// The returned node is of sort Bool.
1205    pub fn Z3_mk_bvneg_no_overflow(c: Z3_context, t1: Z3_ast) -> Option<Z3_ast>;
1206    /// Create a predicate that checks that the bit-wise multiplication
1207    /// of `t1` and `t2` does not overflow.
1208    ///
1209    /// The nodes `t1` and `t2` must have the same bit-vector sort.
1210    /// The returned node is of sort Bool.
1211    pub fn Z3_mk_bvmul_no_overflow(
1212        c: Z3_context,
1213        t1: Z3_ast,
1214        t2: Z3_ast,
1215        is_signed: bool,
1216    ) -> Option<Z3_ast>;
1217    /// Create a predicate that checks that the bit-wise signed multiplication
1218    /// of `t1` and `t2` does not underflow.
1219    ///
1220    /// The nodes `t1` and `t2` must have the same bit-vector sort.
1221    /// The returned node is of sort Bool.
1222    pub fn Z3_mk_bvmul_no_underflow(
1223        c: Z3_context,
1224        t1: Z3_ast,
1225        t2: Z3_ast,
1226    ) -> Option<Z3_ast>;
1227    /// Array read.
1228    /// The argument `a` is the array and `i` is the index of the array that gets read.
1229    ///
1230    /// The node `a` must have an array sort `[domain -> range]`,
1231    /// and `i` must have the sort `domain`.
1232    /// The sort of the result is `range`.
1233    ///
1234    /// # See also
1235    ///
1236    /// - [`Z3_mk_array_sort`]
1237    /// - [`Z3_mk_store`]
1238    pub fn Z3_mk_select(c: Z3_context, a: Z3_ast, i: Z3_ast) -> Option<Z3_ast>;
1239    /// n-ary Array read.
1240    /// The argument `a` is the array and `idxs` are the indices of the array that gets read.
1241    pub fn Z3_mk_select_n(
1242        c: Z3_context,
1243        a: Z3_ast,
1244        n: ::core::ffi::c_uint,
1245        idxs: *const Z3_ast,
1246    ) -> Option<Z3_ast>;
1247    /// Array update.
1248    ///
1249    /// The node `a` must have an array sort `[domain -> range]`, `i` must have sort `domain`,
1250    /// `v` must have sort range. The sort of the result is `[domain -> range]`.
1251    /// The semantics of this function is given by the theory of arrays described in the SMT-LIB
1252    /// standard. See <http://smtlib.org> for more details.
1253    /// The result of this function is an array that is equal to `a` (with respect to `select`)
1254    /// on all indices except for `i`, where it maps to `v` (and the `select` of `a` with
1255    /// respect to `i` may be a different value).
1256    ///
1257    /// # See also
1258    ///
1259    /// - [`Z3_mk_array_sort`]
1260    /// - [`Z3_mk_select`]
1261    pub fn Z3_mk_store(c: Z3_context, a: Z3_ast, i: Z3_ast, v: Z3_ast) -> Option<Z3_ast>;
1262    /// n-ary Array update.
1263    pub fn Z3_mk_store_n(
1264        c: Z3_context,
1265        a: Z3_ast,
1266        n: ::core::ffi::c_uint,
1267        idxs: *const Z3_ast,
1268        v: Z3_ast,
1269    ) -> Option<Z3_ast>;
1270    /// Create the constant array.
1271    ///
1272    /// The resulting term is an array, such that a `select` on an arbitrary index
1273    /// produces the value `v`.
1274    ///
1275    /// - `c`: logical context.
1276    /// - `domain`: domain sort for the array.
1277    /// - `v`: value that the array maps to.
1278    pub fn Z3_mk_const_array(
1279        c: Z3_context,
1280        domain: Z3_sort,
1281        v: Z3_ast,
1282    ) -> Option<Z3_ast>;
1283    /// Map f on the argument arrays.
1284    ///
1285    /// The `n` nodes `args` must be of array sorts `[domain_i -> range_i]`.
1286    /// The function declaration `f` must have type ` range_1 .. range_n -> range`.
1287    /// `v` must have sort range. The sort of the result is `[domain_i -> range]`.
1288    ///
1289    /// # See also
1290    ///
1291    /// - [`Z3_mk_array_sort`]
1292    /// - [`Z3_mk_store`]
1293    /// - [`Z3_mk_select`]
1294    pub fn Z3_mk_map(
1295        c: Z3_context,
1296        f: Z3_func_decl,
1297        n: ::core::ffi::c_uint,
1298        args: *const Z3_ast,
1299    ) -> Option<Z3_ast>;
1300    /// Access the array default value.
1301    /// Produces the default range value, for arrays that can be represented as
1302    /// finite maps with a default range value.
1303    ///
1304    /// - `c`: logical context.
1305    /// - `array`: array value whose default range value is accessed.
1306    pub fn Z3_mk_array_default(c: Z3_context, array: Z3_ast) -> Option<Z3_ast>;
1307    /// Create array with the same interpretation as a function.
1308    /// The array satisfies the property (f x) = (select (_ as-array f) x)
1309    /// for every argument x.
1310    pub fn Z3_mk_as_array(c: Z3_context, f: Z3_func_decl) -> Option<Z3_ast>;
1311    /// Create Set type.
1312    pub fn Z3_mk_set_sort(c: Z3_context, ty: Z3_sort) -> Option<Z3_sort>;
1313    /// Create the empty set.
1314    pub fn Z3_mk_empty_set(c: Z3_context, domain: Z3_sort) -> Option<Z3_ast>;
1315    /// Create the full set.
1316    pub fn Z3_mk_full_set(c: Z3_context, domain: Z3_sort) -> Option<Z3_ast>;
1317    /// Add an element to a set.
1318    ///
1319    /// The first argument must be a set, the second an element.
1320    pub fn Z3_mk_set_add(c: Z3_context, set: Z3_ast, elem: Z3_ast) -> Option<Z3_ast>;
1321    /// Remove an element to a set.
1322    ///
1323    /// The first argument must be a set, the second an element.
1324    pub fn Z3_mk_set_del(c: Z3_context, set: Z3_ast, elem: Z3_ast) -> Option<Z3_ast>;
1325    /// Take the union of a list of sets.
1326    pub fn Z3_mk_set_union(
1327        c: Z3_context,
1328        num_args: ::core::ffi::c_uint,
1329        args: *const Z3_ast,
1330    ) -> Option<Z3_ast>;
1331    /// Take the intersection of a list of sets.
1332    pub fn Z3_mk_set_intersect(
1333        c: Z3_context,
1334        num_args: ::core::ffi::c_uint,
1335        args: *const Z3_ast,
1336    ) -> Option<Z3_ast>;
1337    /// Take the set difference between two sets.
1338    pub fn Z3_mk_set_difference(
1339        c: Z3_context,
1340        arg1: Z3_ast,
1341        arg2: Z3_ast,
1342    ) -> Option<Z3_ast>;
1343    /// Take the complement of a set.
1344    pub fn Z3_mk_set_complement(c: Z3_context, arg: Z3_ast) -> Option<Z3_ast>;
1345    /// Check for set membership.
1346    ///
1347    /// The first argument should be an element type of the set.
1348    pub fn Z3_mk_set_member(c: Z3_context, elem: Z3_ast, set: Z3_ast) -> Option<Z3_ast>;
1349    /// Check for subsetness of sets.
1350    pub fn Z3_mk_set_subset(c: Z3_context, arg1: Z3_ast, arg2: Z3_ast) -> Option<Z3_ast>;
1351    /// Create array extensionality index given two arrays with the same sort.
1352    /// The meaning is given by the axiom:
1353    /// (=> (= (select A (array-ext A B)) (select B (array-ext A B))) (= A B))
1354    pub fn Z3_mk_array_ext(c: Z3_context, arg1: Z3_ast, arg2: Z3_ast) -> Option<Z3_ast>;
1355    /// Create a finite set sort.
1356    pub fn Z3_mk_finite_set_sort(c: Z3_context, elem_sort: Z3_sort) -> Option<Z3_sort>;
1357    /// Check if a sort is a finite set sort.
1358    pub fn Z3_is_finite_set_sort(c: Z3_context, s: Z3_sort) -> bool;
1359    /// Get the element sort of a finite set sort.
1360    pub fn Z3_get_finite_set_sort_basis(c: Z3_context, s: Z3_sort) -> Option<Z3_sort>;
1361    /// Create an empty finite set of the given sort.
1362    pub fn Z3_mk_finite_set_empty(c: Z3_context, set_sort: Z3_sort) -> Option<Z3_ast>;
1363    /// Create a singleton finite set.
1364    pub fn Z3_mk_finite_set_singleton(c: Z3_context, elem: Z3_ast) -> Option<Z3_ast>;
1365    /// Create the union of two finite sets.
1366    pub fn Z3_mk_finite_set_union(
1367        c: Z3_context,
1368        s1: Z3_ast,
1369        s2: Z3_ast,
1370    ) -> Option<Z3_ast>;
1371    /// Create the intersection of two finite sets.
1372    pub fn Z3_mk_finite_set_intersect(
1373        c: Z3_context,
1374        s1: Z3_ast,
1375        s2: Z3_ast,
1376    ) -> Option<Z3_ast>;
1377    /// Create the set difference of two finite sets.
1378    pub fn Z3_mk_finite_set_difference(
1379        c: Z3_context,
1380        s1: Z3_ast,
1381        s2: Z3_ast,
1382    ) -> Option<Z3_ast>;
1383    /// Check if an element is a member of a finite set.
1384    pub fn Z3_mk_finite_set_member(
1385        c: Z3_context,
1386        elem: Z3_ast,
1387        set: Z3_ast,
1388    ) -> Option<Z3_ast>;
1389    /// Get the size (cardinality) of a finite set.
1390    pub fn Z3_mk_finite_set_size(c: Z3_context, set: Z3_ast) -> Option<Z3_ast>;
1391    /// Check if one finite set is a subset of another.
1392    pub fn Z3_mk_finite_set_subset(
1393        c: Z3_context,
1394        s1: Z3_ast,
1395        s2: Z3_ast,
1396    ) -> Option<Z3_ast>;
1397    /// Apply a function to all elements of a finite set.
1398    pub fn Z3_mk_finite_set_map(c: Z3_context, f: Z3_ast, set: Z3_ast) -> Option<Z3_ast>;
1399    /// Filter a finite set using a predicate.
1400    pub fn Z3_mk_finite_set_filter(
1401        c: Z3_context,
1402        f: Z3_ast,
1403        set: Z3_ast,
1404    ) -> Option<Z3_ast>;
1405    /// Create a finite set of integers in the range [low, high].
1406    pub fn Z3_mk_finite_set_range(
1407        c: Z3_context,
1408        low: Z3_ast,
1409        high: Z3_ast,
1410    ) -> Option<Z3_ast>;
1411    /// Create a numeral of a given sort.
1412    ///
1413    /// - `c`: logical context.
1414    /// - `numeral`: A string representing the numeral value in decimal notation. The string may be of the form `[num]*[.[num]*][E[+|-][num]+]`.
1415    /// If the given sort is a real, then the numeral can be a rational, that is, a string of the form `[num]* / [num]*` .
1416    /// - `ty`: The sort of the numeral. In the current implementation, the given sort can be an int, real, finite-domain, or bit-vectors of arbitrary size.
1417    ///
1418    /// # See also
1419    ///
1420    /// - [`Z3_mk_int`]
1421    /// - [`Z3_mk_unsigned_int`]
1422    pub fn Z3_mk_numeral(
1423        c: Z3_context,
1424        numeral: Z3_string,
1425        ty: Z3_sort,
1426    ) -> Option<Z3_ast>;
1427    /// Create a real from a fraction.
1428    ///
1429    /// - `c`: logical context.
1430    /// - `num`: numerator of rational.
1431    /// - `den`: denominator of rational.
1432    ///
1433    /// # Preconditions
1434    ///
1435    /// - `den != 0`
1436    ///
1437    /// # See also
1438    ///
1439    /// - [`Z3_mk_numeral`]
1440    /// - [`Z3_mk_int`]
1441    /// - [`Z3_mk_real_int64`]
1442    /// - [`Z3_mk_unsigned_int`]
1443    pub fn Z3_mk_real(
1444        c: Z3_context,
1445        num: ::core::ffi::c_int,
1446        den: ::core::ffi::c_int,
1447    ) -> Option<Z3_ast>;
1448    /// Create a real from a fraction of int64.
1449    ///
1450    /// # See also
1451    ///
1452    /// - [`Z3_mk_real`]
1453    pub fn Z3_mk_real_int64(c: Z3_context, num: i64, den: i64) -> Option<Z3_ast>;
1454    /// Create a numeral of an int, bit-vector, or finite-domain sort.
1455    ///
1456    /// This function can be used to create numerals that fit in a machine integer.
1457    /// It is slightly faster than [`Z3_mk_numeral`] since it is not necessary to parse a string.
1458    ///
1459    /// # See also
1460    ///
1461    /// - [`Z3_mk_numeral`]
1462    pub fn Z3_mk_int(
1463        c: Z3_context,
1464        v: ::core::ffi::c_int,
1465        ty: Z3_sort,
1466    ) -> Option<Z3_ast>;
1467    /// Create a numeral of a int, bit-vector, or finite-domain sort.
1468    ///
1469    /// This function can be used to create numerals that fit in a machine unsigned integer.
1470    /// It is slightly faster than [`Z3_mk_numeral`] since it is not necessary to parse a string.
1471    ///
1472    /// # See also
1473    ///
1474    /// - [`Z3_mk_numeral`]
1475    pub fn Z3_mk_unsigned_int(
1476        c: Z3_context,
1477        v: ::core::ffi::c_uint,
1478        ty: Z3_sort,
1479    ) -> Option<Z3_ast>;
1480    /// Create a numeral of a int, bit-vector, or finite-domain sort.
1481    ///
1482    /// This function can be used to create numerals that fit in a machine `int64_t` integer.
1483    /// It is slightly faster than [`Z3_mk_numeral`] since it is not necessary to parse a string.
1484    ///
1485    /// # See also
1486    ///
1487    /// - [`Z3_mk_numeral`]
1488    pub fn Z3_mk_int64(c: Z3_context, v: i64, ty: Z3_sort) -> Option<Z3_ast>;
1489    /// Create a numeral of a int, bit-vector, or finite-domain sort.
1490    ///
1491    /// This function can be used to create numerals that fit in a machine `uint64_t` integer.
1492    /// It is slightly faster than [`Z3_mk_numeral`] since it is not necessary to parse a string.
1493    ///
1494    /// # See also
1495    ///
1496    /// - [`Z3_mk_numeral`]
1497    pub fn Z3_mk_unsigned_int64(c: Z3_context, v: u64, ty: Z3_sort) -> Option<Z3_ast>;
1498    /// create a bit-vector numeral from a vector of Booleans.
1499    ///
1500    /// # See also
1501    ///
1502    /// - [`Z3_mk_numeral`]
1503    pub fn Z3_mk_bv_numeral(
1504        c: Z3_context,
1505        sz: ::core::ffi::c_uint,
1506        bits: *const bool,
1507    ) -> Option<Z3_ast>;
1508    /// Create a sequence sort out of the sort for the elements.
1509    pub fn Z3_mk_seq_sort(c: Z3_context, s: Z3_sort) -> Option<Z3_sort>;
1510    /// Check if `s` is a sequence sort.
1511    pub fn Z3_is_seq_sort(c: Z3_context, s: Z3_sort) -> bool;
1512    /// Retrieve basis sort for sequence sort.
1513    pub fn Z3_get_seq_sort_basis(c: Z3_context, s: Z3_sort) -> Option<Z3_sort>;
1514    /// Create a regular expression sort out of a sequence sort.
1515    pub fn Z3_mk_re_sort(c: Z3_context, seq: Z3_sort) -> Option<Z3_sort>;
1516    /// Check if `s` is a regular expression sort.
1517    pub fn Z3_is_re_sort(c: Z3_context, s: Z3_sort) -> bool;
1518    /// Retrieve basis sort for regex sort.
1519    pub fn Z3_get_re_sort_basis(c: Z3_context, s: Z3_sort) -> Option<Z3_sort>;
1520    /// Create a sort for unicode strings.
1521    ///
1522    /// The sort for characters can be changed to ASCII by setting
1523    /// the global parameter `encoding` to `ascii`, or alternative
1524    /// to 16 bit characters by setting `encoding` to `bmp`.
1525    pub fn Z3_mk_string_sort(c: Z3_context) -> Option<Z3_sort>;
1526    /// Create a sort for unicode characters.
1527    ///
1528    /// The sort for characters can be changed to ASCII by setting
1529    /// the global parameter `encoding` to `ascii`, or alternative
1530    /// to 16 bit characters by setting `encoding` to `bmp`.
1531    pub fn Z3_mk_char_sort(c: Z3_context) -> Option<Z3_sort>;
1532    /// Check if `s` is a string sort.
1533    pub fn Z3_is_string_sort(c: Z3_context, s: Z3_sort) -> bool;
1534    /// Check if `s` is a character sort.
1535    pub fn Z3_is_char_sort(c: Z3_context, s: Z3_sort) -> bool;
1536    /// Create a string constant out of the string that is passed in
1537    /// The string may contain escape encoding for non-printable characters
1538    /// or characters outside of the basic printable ASCII range. For example,
1539    /// the escape encoding \\u{0} represents the character 0 and the encoding
1540    /// \\u{100} represents the character 256.
1541    pub fn Z3_mk_string(c: Z3_context, s: Z3_string) -> Option<Z3_ast>;
1542    /// Create a string constant out of the string that is passed in
1543    /// It takes the length of the string as well to take into account
1544    /// 0 characters. The string is treated as if it is unescaped so a sequence
1545    /// of characters \\u{0} is treated as 5 characters and not the character 0.
1546    pub fn Z3_mk_lstring(
1547        c: Z3_context,
1548        len: ::core::ffi::c_uint,
1549        s: Z3_string,
1550    ) -> Option<Z3_ast>;
1551    /// Create a string constant out of the string that is passed in
1552    /// It takes the length of the string as well to take into account
1553    /// 0 characters. The string is unescaped.
1554    pub fn Z3_mk_u32string(
1555        c: Z3_context,
1556        len: ::core::ffi::c_uint,
1557        chars: *const ::core::ffi::c_uint,
1558    ) -> Option<Z3_ast>;
1559    /// Determine if `s` is a string constant.
1560    pub fn Z3_is_string(c: Z3_context, s: Z3_ast) -> bool;
1561    /// Retrieve the string constant stored in `s`.
1562    /// Characters outside the basic printable ASCII range are escaped.
1563    ///
1564    /// # Preconditions
1565    ///
1566    /// - ` Z3_is_string(c, s)`
1567    pub fn Z3_get_string(c: Z3_context, s: Z3_ast) -> Z3_string;
1568    /// Retrieve the string constant stored in `s`. The string can contain escape sequences.
1569    /// Characters in the range 1 to 255 are literal.
1570    /// Characters in the range 0, and 256 above are escaped.
1571    ///
1572    /// # Preconditions
1573    ///
1574    /// - ` Z3_is_string(c, s)`
1575    pub fn Z3_get_lstring(
1576        c: Z3_context,
1577        s: Z3_ast,
1578        length: *mut ::core::ffi::c_uint,
1579    ) -> Z3_char_ptr;
1580    /// Retrieve the length of the unescaped string constant stored in `s`.
1581    ///
1582    /// # Preconditions
1583    ///
1584    /// - ` Z3_is_string(c, s)`
1585    pub fn Z3_get_string_length(c: Z3_context, s: Z3_ast) -> ::core::ffi::c_uint;
1586    /// Retrieve the unescaped string constant stored in `s`.
1587    ///
1588    /// # Preconditions
1589    ///
1590    /// - ` Z3_is_string(c, s)`
1591    /// - `length contains the number of characters in s`
1592    pub fn Z3_get_string_contents(
1593        c: Z3_context,
1594        s: Z3_ast,
1595        length: ::core::ffi::c_uint,
1596        contents: *mut ::core::ffi::c_uint,
1597    );
1598    /// Create an empty sequence of the sequence sort `seq`.
1599    ///
1600    /// # Preconditions
1601    ///
1602    /// - `s is a sequence sort.`
1603    pub fn Z3_mk_seq_empty(c: Z3_context, seq: Z3_sort) -> Option<Z3_ast>;
1604    /// Create a unit sequence of `a`.
1605    pub fn Z3_mk_seq_unit(c: Z3_context, a: Z3_ast) -> Option<Z3_ast>;
1606    /// Concatenate sequences.
1607    ///
1608    /// # Preconditions
1609    ///
1610    /// - `n > 0`
1611    pub fn Z3_mk_seq_concat(
1612        c: Z3_context,
1613        n: ::core::ffi::c_uint,
1614        args: *const Z3_ast,
1615    ) -> Option<Z3_ast>;
1616    /// Check if `prefix` is a prefix of `s`.
1617    ///
1618    /// # Preconditions
1619    ///
1620    /// - `prefix and s are the same sequence sorts.`
1621    pub fn Z3_mk_seq_prefix(c: Z3_context, prefix: Z3_ast, s: Z3_ast) -> Option<Z3_ast>;
1622    /// Check if `suffix` is a suffix of `s`.
1623    ///
1624    /// # Preconditions
1625    ///
1626    /// - ``suffix` and `s` are the same sequence sorts.`
1627    pub fn Z3_mk_seq_suffix(c: Z3_context, suffix: Z3_ast, s: Z3_ast) -> Option<Z3_ast>;
1628    /// Check if `container` contains `containee`.
1629    ///
1630    /// # Preconditions
1631    ///
1632    /// - ``container` and `containee` are the same sequence sorts.`
1633    pub fn Z3_mk_seq_contains(
1634        c: Z3_context,
1635        container: Z3_ast,
1636        containee: Z3_ast,
1637    ) -> Option<Z3_ast>;
1638    /// Check if `s1` is lexicographically strictly less than `s2`.
1639    ///
1640    /// # Preconditions
1641    ///
1642    /// - ``s1` and `s2` are strings`
1643    pub fn Z3_mk_str_lt(c: Z3_context, prefix: Z3_ast, s: Z3_ast) -> Option<Z3_ast>;
1644    /// Check if `s1` is equal or lexicographically strictly less than `s2`.
1645    ///
1646    /// # Preconditions
1647    ///
1648    /// - ``s1` and `s2` are strings`
1649    pub fn Z3_mk_str_le(c: Z3_context, prefix: Z3_ast, s: Z3_ast) -> Option<Z3_ast>;
1650    /// Extract subsequence starting at `offset` of `length`.
1651    pub fn Z3_mk_seq_extract(
1652        c: Z3_context,
1653        s: Z3_ast,
1654        offset: Z3_ast,
1655        length: Z3_ast,
1656    ) -> Option<Z3_ast>;
1657    /// Replace the first occurrence of `src` with `dst` in `s`.
1658    pub fn Z3_mk_seq_replace(
1659        c: Z3_context,
1660        s: Z3_ast,
1661        src: Z3_ast,
1662        dst: Z3_ast,
1663    ) -> Option<Z3_ast>;
1664    /// Replace all occurrences of `src` with `dst` in `s`.
1665    pub fn Z3_mk_seq_replace_all(
1666        c: Z3_context,
1667        s: Z3_ast,
1668        src: Z3_ast,
1669        dst: Z3_ast,
1670    ) -> Option<Z3_ast>;
1671    /// Replace the first occurrence of regular expression `re` with `dst` in `s`.
1672    pub fn Z3_mk_seq_replace_re(
1673        c: Z3_context,
1674        s: Z3_ast,
1675        re: Z3_ast,
1676        dst: Z3_ast,
1677    ) -> Option<Z3_ast>;
1678    /// Replace all occurrences of regular expression `re` with `dst` in `s`.
1679    pub fn Z3_mk_seq_replace_re_all(
1680        c: Z3_context,
1681        s: Z3_ast,
1682        re: Z3_ast,
1683        dst: Z3_ast,
1684    ) -> Option<Z3_ast>;
1685    /// Retrieve from `s` the unit sequence positioned at position `index`.
1686    /// The sequence is empty if the index is out of bounds.
1687    pub fn Z3_mk_seq_at(c: Z3_context, s: Z3_ast, index: Z3_ast) -> Option<Z3_ast>;
1688    /// Retrieve from `s` the element positioned at position `index`.
1689    /// The function is under-specified if the index is out of bounds.
1690    pub fn Z3_mk_seq_nth(c: Z3_context, s: Z3_ast, index: Z3_ast) -> Option<Z3_ast>;
1691    /// Return the length of the sequence `s`.
1692    pub fn Z3_mk_seq_length(c: Z3_context, s: Z3_ast) -> Option<Z3_ast>;
1693    /// Return index of the first occurrence of `substr` in `s` starting from offset `offset`.
1694    /// If `s` does not contain `substr`, then the value is -1, if `offset` is the length of `s`, then the value is -1 as well.
1695    /// The value is -1 if `offset` is negative or larger than the length of `s`.
1696    pub fn Z3_mk_seq_index(
1697        c: Z3_context,
1698        s: Z3_ast,
1699        substr: Z3_ast,
1700        offset: Z3_ast,
1701    ) -> Option<Z3_ast>;
1702    /// Return index of the last occurrence of `substr` in `s`.
1703    /// If `s` does not contain `substr`, then the value is -1,
1704    pub fn Z3_mk_seq_last_index(
1705        c: Z3_context,
1706        s: Z3_ast,
1707        substr: Z3_ast,
1708    ) -> Option<Z3_ast>;
1709    /// Create a map of the function `f` over the sequence `s`.
1710    pub fn Z3_mk_seq_map(c: Z3_context, f: Z3_ast, s: Z3_ast) -> Option<Z3_ast>;
1711    /// Create a map of the function `f` over the sequence `s` starting at index `i`.
1712    pub fn Z3_mk_seq_mapi(
1713        c: Z3_context,
1714        f: Z3_ast,
1715        i: Z3_ast,
1716        s: Z3_ast,
1717    ) -> Option<Z3_ast>;
1718    /// Create a fold of the function `f` over the sequence `s` with accumulator a.
1719    pub fn Z3_mk_seq_foldl(
1720        c: Z3_context,
1721        f: Z3_ast,
1722        a: Z3_ast,
1723        s: Z3_ast,
1724    ) -> Option<Z3_ast>;
1725    /// Create a fold with index tracking of the function `f` over the sequence `s` with accumulator `a` starting at index `i`.
1726    pub fn Z3_mk_seq_foldli(
1727        c: Z3_context,
1728        f: Z3_ast,
1729        i: Z3_ast,
1730        a: Z3_ast,
1731        s: Z3_ast,
1732    ) -> Option<Z3_ast>;
1733    /// Convert string to integer.
1734    pub fn Z3_mk_str_to_int(c: Z3_context, s: Z3_ast) -> Option<Z3_ast>;
1735    /// Integer to string conversion.
1736    pub fn Z3_mk_int_to_str(c: Z3_context, s: Z3_ast) -> Option<Z3_ast>;
1737    /// String to code conversion.
1738    pub fn Z3_mk_string_to_code(c: Z3_context, a: Z3_ast) -> Option<Z3_ast>;
1739    /// Code to string conversion.
1740    pub fn Z3_mk_string_from_code(c: Z3_context, a: Z3_ast) -> Option<Z3_ast>;
1741    /// Unsigned bit-vector to string conversion.
1742    pub fn Z3_mk_ubv_to_str(c: Z3_context, s: Z3_ast) -> Option<Z3_ast>;
1743    /// Signed bit-vector to string conversion.
1744    pub fn Z3_mk_sbv_to_str(c: Z3_context, s: Z3_ast) -> Option<Z3_ast>;
1745    /// Create a regular expression that accepts the sequence `seq`.
1746    pub fn Z3_mk_seq_to_re(c: Z3_context, seq: Z3_ast) -> Option<Z3_ast>;
1747    /// Check if `seq` is in the language generated by the regular expression `re`.
1748    pub fn Z3_mk_seq_in_re(c: Z3_context, seq: Z3_ast, re: Z3_ast) -> Option<Z3_ast>;
1749    /// Create the regular language `re`+.
1750    pub fn Z3_mk_re_plus(c: Z3_context, re: Z3_ast) -> Option<Z3_ast>;
1751    /// Create the regular language `re`*.
1752    pub fn Z3_mk_re_star(c: Z3_context, re: Z3_ast) -> Option<Z3_ast>;
1753    /// Create the regular language `[re]`.
1754    pub fn Z3_mk_re_option(c: Z3_context, re: Z3_ast) -> Option<Z3_ast>;
1755    /// Create the union of the regular languages.
1756    ///
1757    /// # Preconditions
1758    ///
1759    /// - `n > 0`
1760    pub fn Z3_mk_re_union(
1761        c: Z3_context,
1762        n: ::core::ffi::c_uint,
1763        args: *const Z3_ast,
1764    ) -> Option<Z3_ast>;
1765    /// Create the concatenation of the regular languages.
1766    ///
1767    /// # Preconditions
1768    ///
1769    /// - `n > 0`
1770    pub fn Z3_mk_re_concat(
1771        c: Z3_context,
1772        n: ::core::ffi::c_uint,
1773        args: *const Z3_ast,
1774    ) -> Option<Z3_ast>;
1775    /// Create the range regular expression over two sequences of length 1.
1776    pub fn Z3_mk_re_range(c: Z3_context, lo: Z3_ast, hi: Z3_ast) -> Option<Z3_ast>;
1777    /// Create a regular expression that accepts all singleton sequences of the regular expression sort
1778    pub fn Z3_mk_re_allchar(c: Z3_context, regex_sort: Z3_sort) -> Option<Z3_ast>;
1779    /// Create a regular expression loop. The supplied regular expression `r` is repeated
1780    /// between `lo` and `hi` times. The `lo` should be below `hi` with one exception: when
1781    /// supplying the value `hi` as 0, the meaning is to repeat the argument `r` at least
1782    /// `lo` number of times, and with an unbounded upper bound.
1783    pub fn Z3_mk_re_loop(
1784        c: Z3_context,
1785        r: Z3_ast,
1786        lo: ::core::ffi::c_uint,
1787        hi: ::core::ffi::c_uint,
1788    ) -> Option<Z3_ast>;
1789    /// Create a power regular expression.
1790    pub fn Z3_mk_re_power(
1791        c: Z3_context,
1792        re: Z3_ast,
1793        n: ::core::ffi::c_uint,
1794    ) -> Option<Z3_ast>;
1795    /// Create the intersection of the regular languages.
1796    ///
1797    /// # Preconditions
1798    ///
1799    /// - `n > 0`
1800    pub fn Z3_mk_re_intersect(
1801        c: Z3_context,
1802        n: ::core::ffi::c_uint,
1803        args: *const Z3_ast,
1804    ) -> Option<Z3_ast>;
1805    /// Create the complement of the regular language `re`.
1806    pub fn Z3_mk_re_complement(c: Z3_context, re: Z3_ast) -> Option<Z3_ast>;
1807    /// Create the difference of regular expressions.
1808    pub fn Z3_mk_re_diff(c: Z3_context, re1: Z3_ast, re2: Z3_ast) -> Option<Z3_ast>;
1809    /// Create an empty regular expression of sort `re`.
1810    ///
1811    /// # Preconditions
1812    ///
1813    /// - `re is a regular expression sort.`
1814    pub fn Z3_mk_re_empty(c: Z3_context, re: Z3_sort) -> Option<Z3_ast>;
1815    /// Create an universal regular expression of sort `re`.
1816    ///
1817    /// # Preconditions
1818    ///
1819    /// - `re is a regular expression sort.`
1820    pub fn Z3_mk_re_full(c: Z3_context, re: Z3_sort) -> Option<Z3_ast>;
1821    /// Create a character literal
1822    pub fn Z3_mk_char(c: Z3_context, ch: ::core::ffi::c_uint) -> Option<Z3_ast>;
1823    /// Create less than or equal to between two characters.
1824    pub fn Z3_mk_char_le(c: Z3_context, ch1: Z3_ast, ch2: Z3_ast) -> Option<Z3_ast>;
1825    /// Create an integer (code point) from character.
1826    pub fn Z3_mk_char_to_int(c: Z3_context, ch: Z3_ast) -> Option<Z3_ast>;
1827    /// Create a bit-vector (code point) from character.
1828    pub fn Z3_mk_char_to_bv(c: Z3_context, ch: Z3_ast) -> Option<Z3_ast>;
1829    /// Create a character from a bit-vector (code point).
1830    pub fn Z3_mk_char_from_bv(c: Z3_context, bv: Z3_ast) -> Option<Z3_ast>;
1831    /// Create a check if the character is a digit.
1832    pub fn Z3_mk_char_is_digit(c: Z3_context, ch: Z3_ast) -> Option<Z3_ast>;
1833    /// create a linear ordering relation over signature `a`.
1834    /// The relation is identified by the index `id`.
1835    pub fn Z3_mk_linear_order(
1836        c: Z3_context,
1837        a: Z3_sort,
1838        id: ::core::ffi::c_uint,
1839    ) -> Option<Z3_func_decl>;
1840    /// create a partial ordering relation over signature `a` and index `id`.
1841    pub fn Z3_mk_partial_order(
1842        c: Z3_context,
1843        a: Z3_sort,
1844        id: ::core::ffi::c_uint,
1845    ) -> Option<Z3_func_decl>;
1846    /// create a piecewise linear ordering relation over signature `a` and index `id`.
1847    pub fn Z3_mk_piecewise_linear_order(
1848        c: Z3_context,
1849        a: Z3_sort,
1850        id: ::core::ffi::c_uint,
1851    ) -> Option<Z3_func_decl>;
1852    /// create a tree ordering relation over signature `a` identified using index `id`.
1853    pub fn Z3_mk_tree_order(
1854        c: Z3_context,
1855        a: Z3_sort,
1856        id: ::core::ffi::c_uint,
1857    ) -> Option<Z3_func_decl>;
1858    /// create transitive closure of binary relation.
1859    ///
1860    ///
1861    /// The resulting relation f+ represents the transitive closure of f.
1862    ///
1863    /// # Preconditions
1864    ///
1865    /// - `f is a binary relation, such that the two arguments have the same sorts.`
1866    pub fn Z3_mk_transitive_closure(
1867        c: Z3_context,
1868        f: Z3_func_decl,
1869    ) -> Option<Z3_func_decl>;
1870    /// Create a pattern for quantifier instantiation.
1871    ///
1872    /// Z3 uses pattern matching to instantiate quantifiers. If a
1873    /// pattern is not provided for a quantifier, then Z3 will
1874    /// automatically compute a set of patterns for it. However, for
1875    /// optimal performance, the user should provide the patterns.
1876    ///
1877    /// Patterns comprise a list of terms. The list should be
1878    /// non-empty.  If the list comprises of more than one term, it is
1879    /// a called a multi-pattern.
1880    ///
1881    /// In general, one can pass in a list of (multi-)patterns in the
1882    /// quantifier constructor.
1883    ///
1884    /// # See also
1885    ///
1886    /// - [`Z3_mk_forall`]
1887    /// - [`Z3_mk_exists`]
1888    pub fn Z3_mk_pattern(
1889        c: Z3_context,
1890        num_patterns: ::core::ffi::c_uint,
1891        terms: *const Z3_ast,
1892    ) -> Option<Z3_pattern>;
1893    /// Create a variable.
1894    ///
1895    /// Variables are intended to be bound by a scope created by a quantifier. So we call them bound variables
1896    /// even if they appear as free variables in the expression produced by `Z3_mk_bound`.
1897    ///
1898    /// Bound variables are indexed by de-Bruijn indices. It is perhaps easiest to explain
1899    /// the meaning of de-Bruijn indices by indicating the compilation process from
1900    /// non-de-Bruijn formulas to de-Bruijn format.
1901    ///
1902    /// ```text
1903    /// abs(forall (x1) phi) = forall (x1) abs1(phi, x1, 0)
1904    /// abs(forall (x1, x2) phi) = abs(forall (x1) abs(forall (x2) phi))
1905    /// abs1(x, x, n) = b_n
1906    /// abs1(y, x, n) = y
1907    /// abs1(f(t1,...,tn), x, n) = f(abs1(t1,x,n), ..., abs1(tn,x,n))
1908    /// abs1(forall (x1) phi, x, n) = forall (x1) (abs1(phi, x, n+1))
1909    /// ```
1910    ///
1911    /// The last line is significant: the index of a bound variable is different depending
1912    /// on the scope in which it appears. The deeper x appears, the higher is its
1913    /// index.
1914    ///
1915    /// - `c`: logical context
1916    /// - `index`: de-Bruijn index
1917    /// - `ty`: sort of the bound variable
1918    ///
1919    /// # See also
1920    ///
1921    /// - [`Z3_mk_forall`]
1922    /// - [`Z3_mk_exists`]
1923    pub fn Z3_mk_bound(
1924        c: Z3_context,
1925        index: ::core::ffi::c_uint,
1926        ty: Z3_sort,
1927    ) -> Option<Z3_ast>;
1928    /// Create a forall formula. It takes an expression `body` that contains bound variables
1929    /// of the same sorts as the sorts listed in the array `sorts`. The bound variables are de-Bruijn indices created
1930    /// using [`Z3_mk_bound`]. The array `decl_names` contains the names that the quantified formula uses for the
1931    /// bound variables. Z3 applies the convention that the last element in the `decl_names` and `sorts` array
1932    /// refers to the variable with index 0, the second to last element of `decl_names` and `sorts` refers
1933    /// to the variable with index 1, etc.
1934    ///
1935    /// - `c`: logical context.
1936    /// - `weight`: quantifiers are associated with weights indicating the importance of using the quantifier during instantiation. By default, pass the weight 0.
1937    /// - `num_patterns`: number of patterns.
1938    /// - `patterns`: array containing the patterns created using [`Z3_mk_pattern`].
1939    /// - `num_decls`: number of variables to be bound.
1940    /// - `sorts`: the sorts of the bound variables.
1941    /// - `decl_names`: names of the bound variables
1942    /// - `body`: the body of the quantifier.
1943    ///
1944    /// # See also
1945    ///
1946    /// - [`Z3_mk_pattern`]
1947    /// - [`Z3_mk_bound`]
1948    /// - [`Z3_mk_exists`]
1949    pub fn Z3_mk_forall(
1950        c: Z3_context,
1951        weight: ::core::ffi::c_uint,
1952        num_patterns: ::core::ffi::c_uint,
1953        patterns: *const Z3_pattern,
1954        num_decls: ::core::ffi::c_uint,
1955        sorts: *const Z3_sort,
1956        decl_names: *const Z3_symbol,
1957        body: Z3_ast,
1958    ) -> Option<Z3_ast>;
1959    /// Create an exists formula. Similar to [`Z3_mk_forall`].
1960    ///
1961    /// # See also
1962    ///
1963    /// - [`Z3_mk_pattern`]
1964    /// - [`Z3_mk_bound`]
1965    /// - [`Z3_mk_forall`]
1966    /// - [`Z3_mk_quantifier`]
1967    pub fn Z3_mk_exists(
1968        c: Z3_context,
1969        weight: ::core::ffi::c_uint,
1970        num_patterns: ::core::ffi::c_uint,
1971        patterns: *const Z3_pattern,
1972        num_decls: ::core::ffi::c_uint,
1973        sorts: *const Z3_sort,
1974        decl_names: *const Z3_symbol,
1975        body: Z3_ast,
1976    ) -> Option<Z3_ast>;
1977    /// Create a quantifier - universal or existential, with pattern hints.
1978    /// See the documentation for [`Z3_mk_forall`] for an explanation of the parameters.
1979    ///
1980    /// - `c`: logical context.
1981    /// - `is_forall`: flag to indicate if this is a universal or existential quantifier.
1982    /// - `weight`: quantifiers are associated with weights indicating the importance of using the quantifier during instantiation. By default, pass the weight 0.
1983    /// - `num_patterns`: number of patterns.
1984    /// - `patterns`: array containing the patterns created using [`Z3_mk_pattern`].
1985    /// - `num_decls`: number of variables to be bound.
1986    /// - `sorts`: array of sorts of the bound variables.
1987    /// - `decl_names`: names of the bound variables.
1988    /// - `body`: the body of the quantifier.
1989    ///
1990    /// # See also
1991    ///
1992    /// - [`Z3_mk_pattern`]
1993    /// - [`Z3_mk_bound`]
1994    /// - [`Z3_mk_forall`]
1995    /// - [`Z3_mk_exists`]
1996    pub fn Z3_mk_quantifier(
1997        c: Z3_context,
1998        is_forall: bool,
1999        weight: ::core::ffi::c_uint,
2000        num_patterns: ::core::ffi::c_uint,
2001        patterns: *const Z3_pattern,
2002        num_decls: ::core::ffi::c_uint,
2003        sorts: *const Z3_sort,
2004        decl_names: *const Z3_symbol,
2005        body: Z3_ast,
2006    ) -> Option<Z3_ast>;
2007    /// Create a quantifier - universal or existential, with pattern hints, no patterns, and attributes
2008    ///
2009    /// - `c`: logical context.
2010    /// - `is_forall`: flag to indicate if this is a universal or existential quantifier.
2011    /// - `quantifier_id`: identifier to identify quantifier
2012    /// - `skolem_id`: identifier to identify skolem constants introduced by quantifier.
2013    /// - `weight`: quantifiers are associated with weights indicating the importance of using the quantifier during instantiation. By default, pass the weight 0.
2014    /// - `num_patterns`: number of patterns.
2015    /// - `patterns`: array containing the patterns created using [`Z3_mk_pattern`].
2016    /// - `num_no_patterns`: number of no_patterns.
2017    /// - `no_patterns`: array containing subexpressions to be excluded from inferred patterns.
2018    /// - `num_decls`: number of variables to be bound.
2019    /// - `sorts`: array of sorts of the bound variables.
2020    /// - `decl_names`: names of the bound variables.
2021    /// - `body`: the body of the quantifier.
2022    ///
2023    /// # See also
2024    ///
2025    /// - [`Z3_mk_pattern`]
2026    /// - [`Z3_mk_bound`]
2027    /// - [`Z3_mk_forall`]
2028    /// - [`Z3_mk_exists`]
2029    pub fn Z3_mk_quantifier_ex(
2030        c: Z3_context,
2031        is_forall: bool,
2032        weight: ::core::ffi::c_uint,
2033        quantifier_id: Z3_symbol,
2034        skolem_id: Z3_symbol,
2035        num_patterns: ::core::ffi::c_uint,
2036        patterns: *const Z3_pattern,
2037        num_no_patterns: ::core::ffi::c_uint,
2038        no_patterns: *const Z3_ast,
2039        num_decls: ::core::ffi::c_uint,
2040        sorts: *const Z3_sort,
2041        decl_names: *const Z3_symbol,
2042        body: Z3_ast,
2043    ) -> Option<Z3_ast>;
2044    /// Create a universal quantifier using a list of constants that
2045    /// will form the set of bound variables.
2046    ///
2047    /// - `c`: logical context.
2048    /// - `weight`: quantifiers are associated with weights indicating the importance of using
2049    /// the quantifier during instantiation. By default, pass the weight 0.
2050    /// - `num_bound`: number of constants to be abstracted into bound variables.
2051    /// - `bound`: array of constants to be abstracted into bound variables.
2052    /// - `num_patterns`: number of patterns.
2053    /// - `patterns`: array containing the patterns created using [`Z3_mk_pattern`].
2054    /// - `body`: the body of the quantifier.
2055    ///
2056    /// # See also
2057    ///
2058    /// - [`Z3_mk_pattern`]
2059    /// - [`Z3_mk_exists_const`]
2060    pub fn Z3_mk_forall_const(
2061        c: Z3_context,
2062        weight: ::core::ffi::c_uint,
2063        num_bound: ::core::ffi::c_uint,
2064        bound: *const Z3_app,
2065        num_patterns: ::core::ffi::c_uint,
2066        patterns: *const Z3_pattern,
2067        body: Z3_ast,
2068    ) -> Option<Z3_ast>;
2069    /// Similar to [`Z3_mk_forall_const`].
2070    ///
2071    /// Create an existential quantifier using a list of constants that
2072    /// will form the set of bound variables.
2073    ///
2074    /// - `c`: logical context.
2075    /// - `weight`: quantifiers are associated with weights indicating the importance of using
2076    /// the quantifier during instantiation. By default, pass the weight 0.
2077    /// - `num_bound`: number of constants to be abstracted into bound variables.
2078    /// - `bound`: array of constants to be abstracted into bound variables.
2079    /// - `num_patterns`: number of patterns.
2080    /// - `patterns`: array containing the patterns created using [`Z3_mk_pattern`].
2081    /// - `body`: the body of the quantifier.
2082    ///
2083    /// # See also
2084    ///
2085    /// - [`Z3_mk_pattern`]
2086    /// - [`Z3_mk_forall_const`]
2087    pub fn Z3_mk_exists_const(
2088        c: Z3_context,
2089        weight: ::core::ffi::c_uint,
2090        num_bound: ::core::ffi::c_uint,
2091        bound: *const Z3_app,
2092        num_patterns: ::core::ffi::c_uint,
2093        patterns: *const Z3_pattern,
2094        body: Z3_ast,
2095    ) -> Option<Z3_ast>;
2096    /// Create a universal or existential quantifier using a list of
2097    /// constants that will form the set of bound variables.
2098    pub fn Z3_mk_quantifier_const(
2099        c: Z3_context,
2100        is_forall: bool,
2101        weight: ::core::ffi::c_uint,
2102        num_bound: ::core::ffi::c_uint,
2103        bound: *const Z3_app,
2104        num_patterns: ::core::ffi::c_uint,
2105        patterns: *const Z3_pattern,
2106        body: Z3_ast,
2107    ) -> Option<Z3_ast>;
2108    /// Create a universal or existential quantifier using a list of
2109    /// constants that will form the set of bound variables.
2110    pub fn Z3_mk_quantifier_const_ex(
2111        c: Z3_context,
2112        is_forall: bool,
2113        weight: ::core::ffi::c_uint,
2114        quantifier_id: Z3_symbol,
2115        skolem_id: Z3_symbol,
2116        num_bound: ::core::ffi::c_uint,
2117        bound: *const Z3_app,
2118        num_patterns: ::core::ffi::c_uint,
2119        patterns: *const Z3_pattern,
2120        num_no_patterns: ::core::ffi::c_uint,
2121        no_patterns: *const Z3_ast,
2122        body: Z3_ast,
2123    ) -> Option<Z3_ast>;
2124    /// Create a lambda expression. It takes an expression `body` that contains bound variables
2125    /// of the same sorts as the sorts listed in the array `sorts`. The bound variables are de-Bruijn indices created
2126    /// using [`Z3_mk_bound`]. The array `decl_names` contains the names that the quantified formula uses for the
2127    /// bound variables. Z3 applies the convention that the last element in the `decl_names` and `sorts` array
2128    /// refers to the variable with index 0, the second to last element of `decl_names` and `sorts` refers
2129    /// to the variable with index 1, etc.
2130    /// The sort of the resulting expression is `(Array sorts range)` where `range` is the sort of `body`.
2131    /// For example, if the lambda binds two variables of sort `Int` and `Bool`, and the `body` has sort `Real`,
2132    /// the sort of the expression is `(Array Int Bool Real)`.
2133    ///
2134    /// - `c`: logical context
2135    /// - `num_decls`: number of variables to be bound.
2136    /// - `sorts`: the sorts of the bound variables.
2137    /// - `decl_names`: names of the bound variables
2138    /// - `body`: the body of the lambda expression.
2139    ///
2140    /// # See also
2141    ///
2142    /// - [`Z3_mk_bound`]
2143    /// - [`Z3_mk_forall`]
2144    /// - [`Z3_mk_lambda_const`]
2145    pub fn Z3_mk_lambda(
2146        c: Z3_context,
2147        num_decls: ::core::ffi::c_uint,
2148        sorts: *const Z3_sort,
2149        decl_names: *const Z3_symbol,
2150        body: Z3_ast,
2151    ) -> Option<Z3_ast>;
2152    /// Create a lambda expression using a list of constants that form the set
2153    /// of bound variables
2154    ///
2155    /// - `c`: logical context.
2156    /// - `num_bound`: number of constants to be abstracted into bound variables.
2157    /// - `bound`: array of constants to be abstracted into bound variables.
2158    /// - `body`: the body of the lambda expression.
2159    ///
2160    /// # See also
2161    ///
2162    /// - [`Z3_mk_bound`]
2163    /// - [`Z3_mk_forall`]
2164    /// - [`Z3_mk_lambda`]
2165    pub fn Z3_mk_lambda_const(
2166        c: Z3_context,
2167        num_bound: ::core::ffi::c_uint,
2168        bound: *const Z3_app,
2169        body: Z3_ast,
2170    ) -> Option<Z3_ast>;
2171    /// Return `Z3_INT_SYMBOL` if the symbol was constructed
2172    /// using [`Z3_mk_int_symbol`], and `Z3_STRING_SYMBOL` if the symbol
2173    /// was constructed using [`Z3_mk_string_symbol`].
2174    pub fn Z3_get_symbol_kind(c: Z3_context, s: Z3_symbol) -> Z3_symbol_kind;
2175    /// Return the symbol int value.
2176    ///
2177    /// # Preconditions
2178    ///
2179    /// - `Z3_get_symbol_kind(s) == Z3_INT_SYMBOL`
2180    ///
2181    /// # See also
2182    ///
2183    /// - [`Z3_mk_int_symbol`]
2184    pub fn Z3_get_symbol_int(c: Z3_context, s: Z3_symbol) -> ::core::ffi::c_int;
2185    /// Return the symbol name.
2186    ///
2187    ///
2188    /// \warning The returned buffer is statically allocated by Z3. It will
2189    /// be automatically deallocated when [`Z3_del_context`] is invoked.
2190    /// So, the buffer is invalidated in the next call to `Z3_get_symbol_string`.
2191    ///
2192    /// # Preconditions
2193    ///
2194    /// - `Z3_get_symbol_kind(s) == Z3_STRING_SYMBOL`
2195    ///
2196    /// # See also
2197    ///
2198    /// - [`Z3_mk_string_symbol`]
2199    pub fn Z3_get_symbol_string(c: Z3_context, s: Z3_symbol) -> Z3_string;
2200    /// Return the sort name as a symbol.
2201    pub fn Z3_get_sort_name(c: Z3_context, d: Z3_sort) -> Option<Z3_symbol>;
2202    /// Return a unique identifier for `s`.
2203    pub fn Z3_get_sort_id(c: Z3_context, s: Z3_sort) -> ::core::ffi::c_uint;
2204    /// Convert a `Z3_sort` into `Z3_ast`. This is just type casting.
2205    pub fn Z3_sort_to_ast(c: Z3_context, s: Z3_sort) -> Option<Z3_ast>;
2206    /// compare sorts.
2207    pub fn Z3_is_eq_sort(c: Z3_context, s1: Z3_sort, s2: Z3_sort) -> bool;
2208    /// Return the sort kind (e.g., array, tuple, int, bool, etc).
2209    ///
2210    /// # See also
2211    ///
2212    /// - [`Z3_sort_kind`]
2213    pub fn Z3_get_sort_kind(c: Z3_context, t: Z3_sort) -> Z3_sort_kind;
2214    /// Return the size of the given bit-vector sort.
2215    ///
2216    /// # Preconditions
2217    ///
2218    /// - `Z3_get_sort_kind(c, t) == Z3_BV_SORT`
2219    ///
2220    /// # See also
2221    ///
2222    /// - [`Z3_mk_bv_sort`]
2223    /// - [`Z3_get_sort_kind`]
2224    pub fn Z3_get_bv_sort_size(c: Z3_context, t: Z3_sort) -> ::core::ffi::c_uint;
2225    /// Store the size of the sort in `r`. Return `false` if the call failed.
2226    /// That is, Z3_get_sort_kind(s) == Z3_FINITE_DOMAIN_SORT
2227    pub fn Z3_get_finite_domain_sort_size(
2228        c: Z3_context,
2229        s: Z3_sort,
2230        r: *mut u64,
2231    ) -> bool;
2232    /// Return the arity (number of dimensions) of the given array sort.
2233    ///
2234    /// # Preconditions
2235    ///
2236    /// - `Z3_get_sort_kind(s) == Z3_ARRAY_SORT`
2237    ///
2238    /// # See also
2239    ///
2240    /// - [`Z3_get_array_sort_domain_n`]
2241    pub fn Z3_get_array_arity(c: Z3_context, s: Z3_sort) -> ::core::ffi::c_uint;
2242    /// Return the domain of the given array sort.
2243    /// In the case of a multi-dimensional array, this function returns the sort of the first dimension.
2244    ///
2245    /// # Preconditions
2246    ///
2247    /// - `Z3_get_sort_kind(c, t) == Z3_ARRAY_SORT`
2248    ///
2249    /// # See also
2250    ///
2251    /// - [`Z3_mk_array_sort`]
2252    /// - [`Z3_get_sort_kind`]
2253    /// - [`Z3_get_array_sort_domain_n`]
2254    pub fn Z3_get_array_sort_domain(c: Z3_context, t: Z3_sort) -> Option<Z3_sort>;
2255    /// Return the i'th domain sort of an n-dimensional array.
2256    ///
2257    /// # Preconditions
2258    ///
2259    /// - `Z3_get_sort_kind(c, t) == Z3_ARRAY_SORT`
2260    ///
2261    /// # See also
2262    ///
2263    /// - [`Z3_mk_array_sort`]
2264    /// - [`Z3_get_sort_kind`]
2265    /// - [`Z3_get_array_sort_domain`]
2266    pub fn Z3_get_array_sort_domain_n(
2267        c: Z3_context,
2268        t: Z3_sort,
2269        idx: ::core::ffi::c_uint,
2270    ) -> Option<Z3_sort>;
2271    /// Return the range of the given array sort.
2272    ///
2273    /// # Preconditions
2274    ///
2275    /// - `Z3_get_sort_kind(c, t) == Z3_ARRAY_SORT`
2276    ///
2277    /// # See also
2278    ///
2279    /// - [`Z3_mk_array_sort`]
2280    /// - [`Z3_get_sort_kind`]
2281    pub fn Z3_get_array_sort_range(c: Z3_context, t: Z3_sort) -> Option<Z3_sort>;
2282    /// Return the constructor declaration of the given tuple
2283    /// sort.
2284    ///
2285    /// # Preconditions
2286    ///
2287    /// - `Z3_get_sort_kind(c, t) == Z3_DATATYPE_SORT`
2288    ///
2289    /// # See also
2290    ///
2291    /// - [`Z3_mk_tuple_sort`]
2292    /// - [`Z3_get_sort_kind`]
2293    pub fn Z3_get_tuple_sort_mk_decl(c: Z3_context, t: Z3_sort) -> Option<Z3_func_decl>;
2294    /// Return the number of fields of the given tuple sort.
2295    ///
2296    /// # Preconditions
2297    ///
2298    /// - `Z3_get_sort_kind(c, t) == Z3_DATATYPE_SORT`
2299    ///
2300    /// # See also
2301    ///
2302    /// - [`Z3_mk_tuple_sort`]
2303    /// - [`Z3_get_sort_kind`]
2304    pub fn Z3_get_tuple_sort_num_fields(
2305        c: Z3_context,
2306        t: Z3_sort,
2307    ) -> ::core::ffi::c_uint;
2308    /// Return the i-th field declaration (i.e., projection function declaration)
2309    /// of the given tuple sort.
2310    ///
2311    /// # Preconditions
2312    ///
2313    /// - `Z3_get_sort_kind(t) == Z3_DATATYPE_SORT`
2314    /// - `i < Z3_get_tuple_sort_num_fields(c, t)`
2315    ///
2316    /// # See also
2317    ///
2318    /// - [`Z3_mk_tuple_sort`]
2319    /// - [`Z3_get_sort_kind`]
2320    pub fn Z3_get_tuple_sort_field_decl(
2321        c: Z3_context,
2322        t: Z3_sort,
2323        i: ::core::ffi::c_uint,
2324    ) -> Option<Z3_func_decl>;
2325    /// Check if `s` is a recursive datatype sort.
2326    pub fn Z3_is_recursive_datatype_sort(c: Z3_context, s: Z3_sort) -> bool;
2327    /// Return number of constructors for datatype.
2328    ///
2329    /// # Preconditions
2330    ///
2331    /// - `Z3_get_sort_kind(t) == Z3_DATATYPE_SORT`
2332    ///
2333    /// # See also
2334    ///
2335    /// - [`Z3_get_datatype_sort_constructor`]
2336    /// - [`Z3_get_datatype_sort_recognizer`]
2337    /// - [`Z3_get_datatype_sort_constructor_accessor`]
2338    pub fn Z3_get_datatype_sort_num_constructors(
2339        c: Z3_context,
2340        t: Z3_sort,
2341    ) -> ::core::ffi::c_uint;
2342    /// Return idx'th constructor.
2343    ///
2344    /// # Preconditions
2345    ///
2346    /// - `Z3_get_sort_kind(t) == Z3_DATATYPE_SORT`
2347    /// - `idx < Z3_get_datatype_sort_num_constructors(c, t)`
2348    ///
2349    /// # See also
2350    ///
2351    /// - [`Z3_get_datatype_sort_num_constructors`]
2352    /// - [`Z3_get_datatype_sort_recognizer`]
2353    /// - [`Z3_get_datatype_sort_constructor_accessor`]
2354    pub fn Z3_get_datatype_sort_constructor(
2355        c: Z3_context,
2356        t: Z3_sort,
2357        idx: ::core::ffi::c_uint,
2358    ) -> Option<Z3_func_decl>;
2359    /// Return idx'th recognizer.
2360    ///
2361    /// # Preconditions
2362    ///
2363    /// - `Z3_get_sort_kind(t) == Z3_DATATYPE_SORT`
2364    /// - `idx < Z3_get_datatype_sort_num_constructors(c, t)`
2365    ///
2366    /// # See also
2367    ///
2368    /// - [`Z3_get_datatype_sort_num_constructors`]
2369    /// - [`Z3_get_datatype_sort_constructor`]
2370    /// - [`Z3_get_datatype_sort_constructor_accessor`]
2371    pub fn Z3_get_datatype_sort_recognizer(
2372        c: Z3_context,
2373        t: Z3_sort,
2374        idx: ::core::ffi::c_uint,
2375    ) -> Option<Z3_func_decl>;
2376    /// Return idx_a'th accessor for the idx_c'th constructor.
2377    ///
2378    /// # Preconditions
2379    ///
2380    /// - `Z3_get_sort_kind(t) == Z3_DATATYPE_SORT`
2381    /// - `idx_c < Z3_get_datatype_sort_num_constructors(c, t)`
2382    /// - `idx_a < Z3_get_domain_size(c, Z3_get_datatype_sort_constructor(c, idx_c))`
2383    ///
2384    /// # See also
2385    ///
2386    /// - [`Z3_get_datatype_sort_num_constructors`]
2387    /// - [`Z3_get_datatype_sort_constructor`]
2388    /// - [`Z3_get_datatype_sort_recognizer`]
2389    pub fn Z3_get_datatype_sort_constructor_accessor(
2390        c: Z3_context,
2391        t: Z3_sort,
2392        idx_c: ::core::ffi::c_uint,
2393        idx_a: ::core::ffi::c_uint,
2394    ) -> Option<Z3_func_decl>;
2395    /// Update record field with a value.
2396    ///
2397    /// This corresponds to the 'with' construct in OCaml.
2398    /// It has the effect of updating a record field with a given value.
2399    /// The remaining fields are left unchanged. It is the record
2400    /// equivalent of an array store (see \sa Z3_mk_store).
2401    /// If the datatype has more than one constructor, then the update function
2402    /// behaves as identity if there is a mismatch between the accessor and
2403    /// constructor. For example ((_ update-field car) nil 1) is nil,
2404    /// while ((_ update-field car) (cons 2 nil) 1) is (cons 1 nil).
2405    ///
2406    /// # Preconditions
2407    ///
2408    /// - `Z3_get_sort_kind(Z3_get_sort(c, t)) == Z3_get_domain(c, field_access, 1) == Z3_DATATYPE_SORT`
2409    /// - `Z3_get_sort(c, value) == Z3_get_range(c, field_access)`
2410    pub fn Z3_datatype_update_field(
2411        c: Z3_context,
2412        field_access: Z3_func_decl,
2413        t: Z3_ast,
2414        value: Z3_ast,
2415    ) -> Option<Z3_ast>;
2416    /// Return arity of relation.
2417    ///
2418    /// # Preconditions
2419    ///
2420    /// - `Z3_get_sort_kind(s) == Z3_RELATION_SORT`
2421    ///
2422    /// # See also
2423    ///
2424    /// - [`Z3_get_relation_column`]
2425    pub fn Z3_get_relation_arity(c: Z3_context, s: Z3_sort) -> ::core::ffi::c_uint;
2426    /// Return sort at i'th column of relation sort.
2427    ///
2428    /// # Preconditions
2429    ///
2430    /// - `Z3_get_sort_kind(c, s) == Z3_RELATION_SORT`
2431    /// - `col < Z3_get_relation_arity(c, s)`
2432    ///
2433    /// # See also
2434    ///
2435    /// - [`Z3_get_relation_arity`]
2436    pub fn Z3_get_relation_column(
2437        c: Z3_context,
2438        s: Z3_sort,
2439        col: ::core::ffi::c_uint,
2440    ) -> Option<Z3_sort>;
2441    /// Pseudo-Boolean relations.
2442    ///
2443    /// Encode p1 + p2 + ... + pn <= k
2444    pub fn Z3_mk_atmost(
2445        c: Z3_context,
2446        num_args: ::core::ffi::c_uint,
2447        args: *const Z3_ast,
2448        k: ::core::ffi::c_uint,
2449    ) -> Option<Z3_ast>;
2450    /// Pseudo-Boolean relations.
2451    ///
2452    /// Encode p1 + p2 + ... + pn >= k
2453    pub fn Z3_mk_atleast(
2454        c: Z3_context,
2455        num_args: ::core::ffi::c_uint,
2456        args: *const Z3_ast,
2457        k: ::core::ffi::c_uint,
2458    ) -> Option<Z3_ast>;
2459    /// Pseudo-Boolean relations.
2460    ///
2461    /// Encode k1*p1 + k2*p2 + ... + kn*pn <= k
2462    pub fn Z3_mk_pble(
2463        c: Z3_context,
2464        num_args: ::core::ffi::c_uint,
2465        args: *const Z3_ast,
2466        coeffs: *const ::core::ffi::c_int,
2467        k: ::core::ffi::c_int,
2468    ) -> Option<Z3_ast>;
2469    /// Pseudo-Boolean relations.
2470    ///
2471    /// Encode k1*p1 + k2*p2 + ... + kn*pn >= k
2472    pub fn Z3_mk_pbge(
2473        c: Z3_context,
2474        num_args: ::core::ffi::c_uint,
2475        args: *const Z3_ast,
2476        coeffs: *const ::core::ffi::c_int,
2477        k: ::core::ffi::c_int,
2478    ) -> Option<Z3_ast>;
2479    /// Pseudo-Boolean relations.
2480    ///
2481    /// Encode k1*p1 + k2*p2 + ... + kn*pn = k
2482    pub fn Z3_mk_pbeq(
2483        c: Z3_context,
2484        num_args: ::core::ffi::c_uint,
2485        args: *const Z3_ast,
2486        coeffs: *const ::core::ffi::c_int,
2487        k: ::core::ffi::c_int,
2488    ) -> Option<Z3_ast>;
2489    /// Convert a `Z3_func_decl` into `Z3_ast`. This is just type casting.
2490    pub fn Z3_func_decl_to_ast(c: Z3_context, f: Z3_func_decl) -> Option<Z3_ast>;
2491    /// Compare terms.
2492    pub fn Z3_is_eq_func_decl(c: Z3_context, f1: Z3_func_decl, f2: Z3_func_decl) -> bool;
2493    /// Return a unique identifier for `f`.
2494    pub fn Z3_get_func_decl_id(c: Z3_context, f: Z3_func_decl) -> ::core::ffi::c_uint;
2495    /// Return the constant declaration name as a symbol.
2496    pub fn Z3_get_decl_name(c: Z3_context, d: Z3_func_decl) -> Option<Z3_symbol>;
2497    /// Return declaration kind corresponding to declaration.
2498    pub fn Z3_get_decl_kind(c: Z3_context, d: Z3_func_decl) -> Z3_decl_kind;
2499    /// Return the number of parameters of the given declaration.
2500    ///
2501    /// # See also
2502    ///
2503    /// - [`Z3_get_arity`]
2504    pub fn Z3_get_domain_size(c: Z3_context, d: Z3_func_decl) -> ::core::ffi::c_uint;
2505    /// Alias for `Z3_get_domain_size`.
2506    ///
2507    /// # See also
2508    ///
2509    /// - [`Z3_get_domain_size`]
2510    pub fn Z3_get_arity(c: Z3_context, d: Z3_func_decl) -> ::core::ffi::c_uint;
2511    /// Return the sort of the i-th parameter of the given function declaration.
2512    ///
2513    /// # Preconditions
2514    ///
2515    /// - `i < Z3_get_domain_size(d)`
2516    ///
2517    /// # See also
2518    ///
2519    /// - [`Z3_get_domain_size`]
2520    pub fn Z3_get_domain(
2521        c: Z3_context,
2522        d: Z3_func_decl,
2523        i: ::core::ffi::c_uint,
2524    ) -> Option<Z3_sort>;
2525    /// Return the range of the given declaration.
2526    ///
2527    /// If `d` is a constant (i.e., has zero arguments), then this
2528    /// function returns the sort of the constant.
2529    pub fn Z3_get_range(c: Z3_context, d: Z3_func_decl) -> Option<Z3_sort>;
2530    /// Return the number of parameters associated with a declaration.
2531    pub fn Z3_get_decl_num_parameters(
2532        c: Z3_context,
2533        d: Z3_func_decl,
2534    ) -> ::core::ffi::c_uint;
2535    /// Return the parameter type associated with a declaration.
2536    ///
2537    /// - `c`: the context
2538    /// - `d`: the function declaration
2539    /// - `idx`: is the index of the named parameter it should be between 0 and the number of parameters.
2540    pub fn Z3_get_decl_parameter_kind(
2541        c: Z3_context,
2542        d: Z3_func_decl,
2543        idx: ::core::ffi::c_uint,
2544    ) -> Z3_parameter_kind;
2545    /// Return the integer value associated with an integer parameter.
2546    ///
2547    /// # Preconditions
2548    ///
2549    /// - `Z3_get_decl_parameter_kind(c, d, idx) == Z3_PARAMETER_INT`
2550    pub fn Z3_get_decl_int_parameter(
2551        c: Z3_context,
2552        d: Z3_func_decl,
2553        idx: ::core::ffi::c_uint,
2554    ) -> ::core::ffi::c_int;
2555    /// Return the double value associated with an double parameter.
2556    ///
2557    /// # Preconditions
2558    ///
2559    /// - `Z3_get_decl_parameter_kind(c, d, idx) == Z3_PARAMETER_DOUBLE`
2560    pub fn Z3_get_decl_double_parameter(
2561        c: Z3_context,
2562        d: Z3_func_decl,
2563        idx: ::core::ffi::c_uint,
2564    ) -> f64;
2565    /// Return the double value associated with an double parameter.
2566    ///
2567    /// # Preconditions
2568    ///
2569    /// - `Z3_get_decl_parameter_kind(c, d, idx) == Z3_PARAMETER_SYMBOL`
2570    pub fn Z3_get_decl_symbol_parameter(
2571        c: Z3_context,
2572        d: Z3_func_decl,
2573        idx: ::core::ffi::c_uint,
2574    ) -> Option<Z3_symbol>;
2575    /// Return the sort value associated with a sort parameter.
2576    ///
2577    /// # Preconditions
2578    ///
2579    /// - `Z3_get_decl_parameter_kind(c, d, idx) == Z3_PARAMETER_SORT`
2580    pub fn Z3_get_decl_sort_parameter(
2581        c: Z3_context,
2582        d: Z3_func_decl,
2583        idx: ::core::ffi::c_uint,
2584    ) -> Option<Z3_sort>;
2585    /// Return the expression value associated with an expression parameter.
2586    ///
2587    /// # Preconditions
2588    ///
2589    /// - `Z3_get_decl_parameter_kind(c, d, idx) == Z3_PARAMETER_AST`
2590    pub fn Z3_get_decl_ast_parameter(
2591        c: Z3_context,
2592        d: Z3_func_decl,
2593        idx: ::core::ffi::c_uint,
2594    ) -> Option<Z3_ast>;
2595    /// Return the expression value associated with an expression parameter.
2596    ///
2597    /// # Preconditions
2598    ///
2599    /// - `Z3_get_decl_parameter_kind(c, d, idx) == Z3_PARAMETER_FUNC_DECL`
2600    pub fn Z3_get_decl_func_decl_parameter(
2601        c: Z3_context,
2602        d: Z3_func_decl,
2603        idx: ::core::ffi::c_uint,
2604    ) -> Option<Z3_func_decl>;
2605    /// Return the rational value, as a string, associated with a rational parameter.
2606    ///
2607    /// # Preconditions
2608    ///
2609    /// - `Z3_get_decl_parameter_kind(c, d, idx) == Z3_PARAMETER_RATIONAL`
2610    pub fn Z3_get_decl_rational_parameter(
2611        c: Z3_context,
2612        d: Z3_func_decl,
2613        idx: ::core::ffi::c_uint,
2614    ) -> Z3_string;
2615    /// Convert a `Z3_app` into `Z3_ast`. This is just type casting.
2616    pub fn Z3_app_to_ast(c: Z3_context, a: Z3_app) -> Option<Z3_ast>;
2617    /// Return the declaration of a constant or function application.
2618    pub fn Z3_get_app_decl(c: Z3_context, a: Z3_app) -> Option<Z3_func_decl>;
2619    /// Return the number of argument of an application. If `t`
2620    /// is an constant, then the number of arguments is 0.
2621    ///
2622    /// # See also
2623    ///
2624    /// - [`Z3_get_app_arg`]
2625    pub fn Z3_get_app_num_args(c: Z3_context, a: Z3_app) -> ::core::ffi::c_uint;
2626    /// Return the i-th argument of the given application.
2627    ///
2628    /// # Preconditions
2629    ///
2630    /// - `i < Z3_get_app_num_args(c, a)`
2631    ///
2632    /// # See also
2633    ///
2634    /// - [`Z3_get_app_num_args`]
2635    pub fn Z3_get_app_arg(
2636        c: Z3_context,
2637        a: Z3_app,
2638        i: ::core::ffi::c_uint,
2639    ) -> Option<Z3_ast>;
2640    /// Compare terms.
2641    pub fn Z3_is_eq_ast(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> bool;
2642    /// Return a unique identifier for `t`.
2643    /// The identifier is unique up to structural equality. Thus, two ast nodes
2644    /// created by the same context and having the same children and same function symbols
2645    /// have the same identifiers. Ast nodes created in the same context, but having
2646    /// different children or different functions have different identifiers.
2647    /// Variables and quantifiers are also assigned different identifiers according to
2648    /// their structure.
2649    pub fn Z3_get_ast_id(c: Z3_context, t: Z3_ast) -> ::core::ffi::c_uint;
2650    /// Return a hash code for the given AST.
2651    /// The hash code is structural but two different AST objects can map to the same hash.
2652    /// The result of `Z3_get_ast_id` returns an identifier that is unique over the
2653    /// set of live AST objects.
2654    pub fn Z3_get_ast_hash(c: Z3_context, a: Z3_ast) -> ::core::ffi::c_uint;
2655    /// Return the sort of an AST node.
2656    ///
2657    /// The AST node must be a constant, application, numeral, bound variable, or quantifier.
2658    pub fn Z3_get_sort(c: Z3_context, a: Z3_ast) -> Option<Z3_sort>;
2659    /// Return `true` if the given expression `t` is well sorted.
2660    pub fn Z3_is_well_sorted(c: Z3_context, t: Z3_ast) -> bool;
2661    /// Return `Z3_L_TRUE` if `a` is true, `Z3_L_FALSE` if it is false, and `Z3_L_UNDEF` otherwise.
2662    pub fn Z3_get_bool_value(c: Z3_context, a: Z3_ast) -> Z3_lbool;
2663    /// Return the kind of the given AST.
2664    pub fn Z3_get_ast_kind(c: Z3_context, a: Z3_ast) -> Z3_ast_kind;
2665    pub fn Z3_is_app(c: Z3_context, a: Z3_ast) -> bool;
2666    pub fn Z3_is_ground(c: Z3_context, a: Z3_ast) -> bool;
2667    pub fn Z3_get_depth(c: Z3_context, a: Z3_ast) -> ::core::ffi::c_uint;
2668    pub fn Z3_is_numeral_ast(c: Z3_context, a: Z3_ast) -> bool;
2669    /// Return `true` if the given AST is a real algebraic number.
2670    pub fn Z3_is_algebraic_number(c: Z3_context, a: Z3_ast) -> bool;
2671    /// Convert an `ast` into an `APP_AST`. This is just type casting.
2672    ///
2673    /// # Preconditions
2674    ///
2675    /// - ``Z3_get_ast_kind(c, a) == `Z3_APP_AST```
2676    pub fn Z3_to_app(c: Z3_context, a: Z3_ast) -> Option<Z3_app>;
2677    /// Convert an AST into a FUNC_DECL_AST. This is just type casting.
2678    ///
2679    /// # Preconditions
2680    ///
2681    /// - ``Z3_get_ast_kind(c, a) == Z3_FUNC_DECL_AST``
2682    pub fn Z3_to_func_decl(c: Z3_context, a: Z3_ast) -> Option<Z3_func_decl>;
2683    /// Return numeral value, as a decimal string of a numeric constant term
2684    ///
2685    /// # Preconditions
2686    ///
2687    /// - `Z3_get_ast_kind(c, a) == Z3_NUMERAL_AST`
2688    pub fn Z3_get_numeral_string(c: Z3_context, a: Z3_ast) -> Z3_string;
2689    /// Return numeral value, as a binary string of a numeric constant term
2690    ///
2691    /// # Preconditions
2692    ///
2693    /// - `Z3_get_ast_kind(c, a) == Z3_NUMERAL_AST`
2694    /// - `a represents a non-negative integer`
2695    pub fn Z3_get_numeral_binary_string(c: Z3_context, a: Z3_ast) -> Z3_string;
2696    /// Return numeral as a string in decimal notation.
2697    /// The result has at most `precision` decimal places.
2698    ///
2699    /// # Preconditions
2700    ///
2701    /// - `Z3_get_ast_kind(c, a) == Z3_NUMERAL_AST || Z3_is_algebraic_number(c, a)`
2702    pub fn Z3_get_numeral_decimal_string(
2703        c: Z3_context,
2704        a: Z3_ast,
2705        precision: ::core::ffi::c_uint,
2706    ) -> Z3_string;
2707    /// Return numeral as a double.
2708    ///
2709    /// # Preconditions
2710    ///
2711    /// - `Z3_get_ast_kind(c, a) == Z3_NUMERAL_AST || Z3_is_algebraic_number(c, a)`
2712    pub fn Z3_get_numeral_double(c: Z3_context, a: Z3_ast) -> f64;
2713    /// Return the numerator (as a numeral AST) of a numeral AST of sort Real.
2714    ///
2715    /// # Preconditions
2716    ///
2717    /// - `Z3_get_ast_kind(c, a) == Z3_NUMERAL_AST`
2718    pub fn Z3_get_numerator(c: Z3_context, a: Z3_ast) -> Option<Z3_ast>;
2719    /// Return the denominator (as a numeral AST) of a numeral AST of sort Real.
2720    ///
2721    /// # Preconditions
2722    ///
2723    /// - `Z3_get_ast_kind(c, a) == Z3_NUMERAL_AST`
2724    pub fn Z3_get_denominator(c: Z3_context, a: Z3_ast) -> Option<Z3_ast>;
2725    /// Return numeral value, as a pair of 64 bit numbers if the representation fits.
2726    ///
2727    /// - `c`: logical context.
2728    /// - `a`: term.
2729    /// - `num`: numerator.
2730    /// - `den`: denominator.
2731    ///
2732    /// Return `true` if the numeral value fits in 64 bit numerals, `false` otherwise.
2733    ///
2734    /// Equivalent to `Z3_get_numeral_rational_int64` except that for unsupported expression arguments `Z3_get_numeral_small` signals an error while `Z3_get_numeral_rational_int64` returns `false`.
2735    ///
2736    /// # Preconditions
2737    ///
2738    /// - `Z3_get_ast_kind(a) == Z3_NUMERAL_AST`
2739    pub fn Z3_get_numeral_small(
2740        c: Z3_context,
2741        a: Z3_ast,
2742        num: *mut i64,
2743        den: *mut i64,
2744    ) -> bool;
2745    /// Similar to [`Z3_get_numeral_string`], but only succeeds if
2746    /// the value can fit in a machine int. Return `true` if the call succeeded.
2747    ///
2748    /// # Preconditions
2749    ///
2750    /// - `Z3_get_ast_kind(c, v) == Z3_NUMERAL_AST`
2751    ///
2752    /// # See also
2753    ///
2754    /// - [`Z3_get_numeral_string`]
2755    pub fn Z3_get_numeral_int(
2756        c: Z3_context,
2757        v: Z3_ast,
2758        i: *mut ::core::ffi::c_int,
2759    ) -> bool;
2760    /// Similar to [`Z3_get_numeral_string`], but only succeeds if
2761    /// the value can fit in a machine unsigned int. Return `true` if the call succeeded.
2762    ///
2763    /// # Preconditions
2764    ///
2765    /// - `Z3_get_ast_kind(c, v) == Z3_NUMERAL_AST`
2766    ///
2767    /// # See also
2768    ///
2769    /// - [`Z3_get_numeral_string`]
2770    pub fn Z3_get_numeral_uint(
2771        c: Z3_context,
2772        v: Z3_ast,
2773        u: *mut ::core::ffi::c_uint,
2774    ) -> bool;
2775    /// Similar to [`Z3_get_numeral_string`], but only succeeds if
2776    /// the value can fit in a machine `uint64_t` int. Return `true` if the call succeeded.
2777    ///
2778    /// # Preconditions
2779    ///
2780    /// - `Z3_get_ast_kind(c, v) == Z3_NUMERAL_AST`
2781    ///
2782    /// # See also
2783    ///
2784    /// - [`Z3_get_numeral_string`]
2785    pub fn Z3_get_numeral_uint64(c: Z3_context, v: Z3_ast, u: *mut u64) -> bool;
2786    /// Similar to [`Z3_get_numeral_string`], but only succeeds if
2787    /// the value can fit in a machine `int64_t` int. Return `true` if the call succeeded.
2788    ///
2789    /// # Preconditions
2790    ///
2791    /// - `Z3_get_ast_kind(c, v) == Z3_NUMERAL_AST`
2792    ///
2793    /// # See also
2794    ///
2795    /// - [`Z3_get_numeral_string`]
2796    pub fn Z3_get_numeral_int64(c: Z3_context, v: Z3_ast, i: *mut i64) -> bool;
2797    /// Similar to [`Z3_get_numeral_string`], but only succeeds if
2798    /// the value can fit as a rational number as machine `int64_t` int. Return `true` if the call succeeded.
2799    ///
2800    /// # Preconditions
2801    ///
2802    /// - `Z3_get_ast_kind(c, v) == Z3_NUMERAL_AST`
2803    ///
2804    /// # See also
2805    ///
2806    /// - [`Z3_get_numeral_string`]
2807    pub fn Z3_get_numeral_rational_int64(
2808        c: Z3_context,
2809        v: Z3_ast,
2810        num: *mut i64,
2811        den: *mut i64,
2812    ) -> bool;
2813    /// Return a lower bound for the given real algebraic number.
2814    /// The interval isolating the number is smaller than 1/10^precision.
2815    /// The result is a numeral AST of sort Real.
2816    ///
2817    /// # Preconditions
2818    ///
2819    /// - `Z3_is_algebraic_number(c, a)`
2820    pub fn Z3_get_algebraic_number_lower(
2821        c: Z3_context,
2822        a: Z3_ast,
2823        precision: ::core::ffi::c_uint,
2824    ) -> Option<Z3_ast>;
2825    /// Return a upper bound for the given real algebraic number.
2826    /// The interval isolating the number is smaller than 1/10^precision.
2827    /// The result is a numeral AST of sort Real.
2828    ///
2829    /// # Preconditions
2830    ///
2831    /// - `Z3_is_algebraic_number(c, a)`
2832    pub fn Z3_get_algebraic_number_upper(
2833        c: Z3_context,
2834        a: Z3_ast,
2835        precision: ::core::ffi::c_uint,
2836    ) -> Option<Z3_ast>;
2837    /// Convert a Z3_pattern into Z3_ast. This is just type casting.
2838    pub fn Z3_pattern_to_ast(c: Z3_context, p: Z3_pattern) -> Option<Z3_ast>;
2839    /// Return number of terms in pattern.
2840    pub fn Z3_get_pattern_num_terms(c: Z3_context, p: Z3_pattern) -> ::core::ffi::c_uint;
2841    /// Return i'th ast in pattern.
2842    pub fn Z3_get_pattern(
2843        c: Z3_context,
2844        p: Z3_pattern,
2845        idx: ::core::ffi::c_uint,
2846    ) -> Option<Z3_ast>;
2847    /// Return index of de-Bruijn bound variable.
2848    ///
2849    /// # Preconditions
2850    ///
2851    /// - `Z3_get_ast_kind(a) == Z3_VAR_AST`
2852    pub fn Z3_get_index_value(c: Z3_context, a: Z3_ast) -> ::core::ffi::c_uint;
2853    /// Determine if an ast is a universal quantifier.
2854    pub fn Z3_is_quantifier_forall(c: Z3_context, a: Z3_ast) -> bool;
2855    /// Determine if ast is an existential quantifier.
2856    pub fn Z3_is_quantifier_exists(c: Z3_context, a: Z3_ast) -> bool;
2857    /// Determine if ast is a lambda expression.
2858    ///
2859    /// # Preconditions
2860    ///
2861    /// - `Z3_get_ast_kind(a) == Z3_QUANTIFIER_AST`
2862    pub fn Z3_is_lambda(c: Z3_context, a: Z3_ast) -> bool;
2863    /// Obtain weight of quantifier.
2864    ///
2865    /// # Preconditions
2866    ///
2867    /// - `Z3_get_ast_kind(a) == Z3_QUANTIFIER_AST`
2868    pub fn Z3_get_quantifier_weight(c: Z3_context, a: Z3_ast) -> ::core::ffi::c_uint;
2869    /// Obtain skolem id of quantifier.
2870    ///
2871    /// # Preconditions
2872    ///
2873    /// - `Z3_get_ast_kind(a) == Z3_QUANTIFIER_AST`
2874    pub fn Z3_get_quantifier_skolem_id(c: Z3_context, a: Z3_ast) -> Option<Z3_symbol>;
2875    /// Obtain id of quantifier.
2876    ///
2877    /// # Preconditions
2878    ///
2879    /// - `Z3_get_ast_kind(a) == Z3_QUANTIFIER_AST`
2880    pub fn Z3_get_quantifier_id(c: Z3_context, a: Z3_ast) -> Option<Z3_symbol>;
2881    /// Return number of patterns used in quantifier.
2882    ///
2883    /// # Preconditions
2884    ///
2885    /// - `Z3_get_ast_kind(a) == Z3_QUANTIFIER_AST`
2886    pub fn Z3_get_quantifier_num_patterns(
2887        c: Z3_context,
2888        a: Z3_ast,
2889    ) -> ::core::ffi::c_uint;
2890    /// Return i'th pattern.
2891    ///
2892    /// # Preconditions
2893    ///
2894    /// - `Z3_get_ast_kind(a) == Z3_QUANTIFIER_AST`
2895    pub fn Z3_get_quantifier_pattern_ast(
2896        c: Z3_context,
2897        a: Z3_ast,
2898        i: ::core::ffi::c_uint,
2899    ) -> Option<Z3_pattern>;
2900    /// Return number of no_patterns used in quantifier.
2901    ///
2902    /// # Preconditions
2903    ///
2904    /// - `Z3_get_ast_kind(a) == Z3_QUANTIFIER_AST`
2905    pub fn Z3_get_quantifier_num_no_patterns(
2906        c: Z3_context,
2907        a: Z3_ast,
2908    ) -> ::core::ffi::c_uint;
2909    /// Return i'th no_pattern.
2910    ///
2911    /// # Preconditions
2912    ///
2913    /// - `Z3_get_ast_kind(a) == Z3_QUANTIFIER_AST`
2914    pub fn Z3_get_quantifier_no_pattern_ast(
2915        c: Z3_context,
2916        a: Z3_ast,
2917        i: ::core::ffi::c_uint,
2918    ) -> Option<Z3_ast>;
2919    /// Return number of bound variables of quantifier.
2920    ///
2921    /// # Preconditions
2922    ///
2923    /// - `Z3_get_ast_kind(a) == Z3_QUANTIFIER_AST`
2924    pub fn Z3_get_quantifier_num_bound(c: Z3_context, a: Z3_ast) -> ::core::ffi::c_uint;
2925    /// Return symbol of the i'th bound variable.
2926    ///
2927    /// # Preconditions
2928    ///
2929    /// - `Z3_get_ast_kind(a) == Z3_QUANTIFIER_AST`
2930    pub fn Z3_get_quantifier_bound_name(
2931        c: Z3_context,
2932        a: Z3_ast,
2933        i: ::core::ffi::c_uint,
2934    ) -> Option<Z3_symbol>;
2935    /// Return sort of the i'th bound variable.
2936    ///
2937    /// # Preconditions
2938    ///
2939    /// - `Z3_get_ast_kind(a) == Z3_QUANTIFIER_AST`
2940    pub fn Z3_get_quantifier_bound_sort(
2941        c: Z3_context,
2942        a: Z3_ast,
2943        i: ::core::ffi::c_uint,
2944    ) -> Option<Z3_sort>;
2945    /// Return body of quantifier.
2946    ///
2947    /// # Preconditions
2948    ///
2949    /// - `Z3_get_ast_kind(a) == Z3_QUANTIFIER_AST`
2950    pub fn Z3_get_quantifier_body(c: Z3_context, a: Z3_ast) -> Option<Z3_ast>;
2951    /// Interface to simplifier.
2952    ///
2953    /// Provides an interface to the AST simplifier used by Z3.
2954    /// It returns an AST object which is equal to the argument.
2955    /// The returned AST is simplified using algebraic simplification rules,
2956    /// such as constant propagation (propagating true/false over logical connectives).
2957    ///
2958    /// # See also
2959    ///
2960    /// - [`Z3_simplify_ex`]
2961    pub fn Z3_simplify(c: Z3_context, a: Z3_ast) -> Option<Z3_ast>;
2962    /// Interface to simplifier.
2963    ///
2964    /// Provides an interface to the AST simplifier used by Z3.
2965    /// This procedure is similar to [`Z3_simplify`], but the behavior of the simplifier
2966    /// can be configured using the given parameter set.
2967    ///
2968    /// # See also
2969    ///
2970    /// - [`Z3_simplify`]
2971    /// - [`Z3_simplify_get_help`]
2972    /// - [`Z3_simplify_get_param_descrs`]
2973    pub fn Z3_simplify_ex(c: Z3_context, a: Z3_ast, p: Z3_params) -> Option<Z3_ast>;
2974    /// Return a string describing all available parameters.
2975    ///
2976    /// # See also
2977    ///
2978    /// - [`Z3_simplify_ex`]
2979    /// - [`Z3_simplify_get_param_descrs`]
2980    pub fn Z3_simplify_get_help(c: Z3_context) -> Z3_string;
2981    /// Return the parameter description set for the simplify procedure.
2982    ///
2983    /// # See also
2984    ///
2985    /// - [`Z3_simplify_ex`]
2986    /// - [`Z3_simplify_get_help`]
2987    pub fn Z3_simplify_get_param_descrs(c: Z3_context) -> Option<Z3_param_descrs>;
2988    /// Update the arguments of term `a` using the arguments `args`.
2989    /// The number of arguments `num_args` should coincide
2990    /// with the number of arguments to `a`.
2991    /// If `a` is a quantifier, then num_args has to be 1.
2992    pub fn Z3_update_term(
2993        c: Z3_context,
2994        a: Z3_ast,
2995        num_args: ::core::ffi::c_uint,
2996        args: *const Z3_ast,
2997    ) -> Option<Z3_ast>;
2998    /// Substitute every occurrence of `from[i]` in `a` with `to[i]`, for `i` smaller than `num_exprs`.
2999    /// The result is the new AST. The arrays `from` and `to` must have size `num_exprs`.
3000    /// For every `i` smaller than `num_exprs`, we must have that sort of `from[i]` must be equal to sort of `to[i]`.
3001    pub fn Z3_substitute(
3002        c: Z3_context,
3003        a: Z3_ast,
3004        num_exprs: ::core::ffi::c_uint,
3005        from: *const Z3_ast,
3006        to: *const Z3_ast,
3007    ) -> Option<Z3_ast>;
3008    /// Substitute the variables in `a` with the expressions in `to`.
3009    /// For every `i` smaller than `num_exprs`, the variable with de-Bruijn index `i` is replaced with term `to[i]`.
3010    /// Note that a variable is created using the function \ref Z3_mk_bound.
3011    pub fn Z3_substitute_vars(
3012        c: Z3_context,
3013        a: Z3_ast,
3014        num_exprs: ::core::ffi::c_uint,
3015        to: *const Z3_ast,
3016    ) -> Option<Z3_ast>;
3017    /// Substitute functions in `from` with new expressions in `to`.
3018    ///
3019    /// The expressions in `to` can have free variables. The free variable in `to` at index 0
3020    /// refers to the first argument of `from`, the free variable at index 1 corresponds to the second argument.
3021    pub fn Z3_substitute_funs(
3022        c: Z3_context,
3023        a: Z3_ast,
3024        num_funs: ::core::ffi::c_uint,
3025        from: *const Z3_func_decl,
3026        to: *const Z3_ast,
3027    ) -> Option<Z3_ast>;
3028    /// Translate/Copy the AST `a` from context `source` to context `target`.
3029    /// AST `a` must have been created using context `source`.
3030    ///
3031    /// # Preconditions
3032    ///
3033    /// - `source != target`
3034    pub fn Z3_translate(
3035        source: Z3_context,
3036        a: Z3_ast,
3037        target: Z3_context,
3038    ) -> Option<Z3_ast>;
3039    /// Create a fresh model object. It has reference count 0.
3040    pub fn Z3_mk_model(c: Z3_context) -> Option<Z3_model>;
3041    /// Increment the reference counter of the given model.
3042    pub fn Z3_model_inc_ref(c: Z3_context, m: Z3_model);
3043    /// Decrement the reference counter of the given model.
3044    pub fn Z3_model_dec_ref(c: Z3_context, m: Z3_model);
3045    /// Evaluate the AST node `t` in the given model.
3046    /// Return `true` if succeeded, and store the result in `v`.
3047    ///
3048    /// If `model_completion` is `true`, then Z3 will assign an interpretation for any constant or function that does
3049    /// not have an interpretation in `m`. These constants and functions were essentially don't cares.
3050    ///
3051    /// If `model_completion` is `false`, then Z3 will not assign interpretations to constants for functions that do
3052    /// not have interpretations in `m`. Evaluation behaves as the identify function in this case.
3053    ///
3054    /// The evaluation may fail for the following reasons:
3055    ///
3056    /// - `t` contains a quantifier.
3057    ///
3058    /// - the model `m` is partial, that is, it doesn't have a complete interpretation for uninterpreted functions.
3059    /// That is, the option `MODEL_PARTIAL=true` was used.
3060    ///
3061    /// - `t` is type incorrect.
3062    ///
3063    /// - `Z3_interrupt` was invoked during evaluation.
3064    pub fn Z3_model_eval(
3065        c: Z3_context,
3066        m: Z3_model,
3067        t: Z3_ast,
3068        model_completion: bool,
3069        v: *mut Z3_ast,
3070    ) -> bool;
3071    /// Return the interpretation (i.e., assignment) of constant `a` in the model `m`.
3072    /// Return `NULL`, if the model does not assign an interpretation for `a`.
3073    /// That should be interpreted as: the value of `a` does not matter.
3074    ///
3075    /// # Preconditions
3076    ///
3077    /// - `Z3_get_arity(c, a) == 0`
3078    pub fn Z3_model_get_const_interp(
3079        c: Z3_context,
3080        m: Z3_model,
3081        a: Z3_func_decl,
3082    ) -> Option<Z3_ast>;
3083    /// Test if there exists an interpretation (i.e., assignment) for `a` in the model `m`.
3084    pub fn Z3_model_has_interp(c: Z3_context, m: Z3_model, a: Z3_func_decl) -> bool;
3085    /// Return the interpretation of the function `f` in the model `m`.
3086    /// Return `NULL`, if the model does not assign an interpretation for `f`.
3087    /// That should be interpreted as: the `f` does not matter.
3088    ///
3089    ///
3090    /// **Remark:** Reference counting must be used to manage Z3_func_interp objects, even when the Z3_context was
3091    /// created using [`Z3_mk_context`] instead of [`Z3_mk_context_rc`].
3092    ///
3093    /// # Preconditions
3094    ///
3095    /// - `Z3_get_arity(c, f) > 0`
3096    pub fn Z3_model_get_func_interp(
3097        c: Z3_context,
3098        m: Z3_model,
3099        f: Z3_func_decl,
3100    ) -> Option<Z3_func_interp>;
3101    /// Return the number of constants assigned by the given model.
3102    ///
3103    /// # See also
3104    ///
3105    /// - [`Z3_model_get_const_decl`]
3106    pub fn Z3_model_get_num_consts(c: Z3_context, m: Z3_model) -> ::core::ffi::c_uint;
3107    /// Return the i-th constant in the given model.
3108    ///
3109    /// # Preconditions
3110    ///
3111    /// - `i < Z3_model_get_num_consts(c, m)`
3112    ///
3113    /// # See also
3114    ///
3115    /// - [`Z3_model_eval`]
3116    /// - [`Z3_model_get_num_consts`]
3117    pub fn Z3_model_get_const_decl(
3118        c: Z3_context,
3119        m: Z3_model,
3120        i: ::core::ffi::c_uint,
3121    ) -> Option<Z3_func_decl>;
3122    /// Return the number of function interpretations in the given model.
3123    ///
3124    /// A function interpretation is represented as a finite map and an 'else' value.
3125    /// Each entry in the finite map represents the value of a function given a set of arguments.
3126    ///
3127    /// # See also
3128    ///
3129    /// - [`Z3_model_get_func_decl`]
3130    pub fn Z3_model_get_num_funcs(c: Z3_context, m: Z3_model) -> ::core::ffi::c_uint;
3131    /// Return the declaration of the i-th function in the given model.
3132    ///
3133    /// # Preconditions
3134    ///
3135    /// - `i < Z3_model_get_num_funcs(c, m)`
3136    ///
3137    /// # See also
3138    ///
3139    /// - [`Z3_model_get_num_funcs`]
3140    pub fn Z3_model_get_func_decl(
3141        c: Z3_context,
3142        m: Z3_model,
3143        i: ::core::ffi::c_uint,
3144    ) -> Option<Z3_func_decl>;
3145    /// Return the number of uninterpreted sorts that `m` assigns an interpretation to.
3146    ///
3147    /// Z3 also provides an interpretation for uninterpreted sorts used in a formula.
3148    /// The interpretation for a sort `s` is a finite set of distinct values. We say this finite set is
3149    /// the "universe" of `s`.
3150    ///
3151    /// # See also
3152    ///
3153    /// - [`Z3_model_get_sort`]
3154    /// - [`Z3_model_get_sort_universe`]
3155    pub fn Z3_model_get_num_sorts(c: Z3_context, m: Z3_model) -> ::core::ffi::c_uint;
3156    /// Return a uninterpreted sort that `m` assigns an interpretation.
3157    ///
3158    /// # Preconditions
3159    ///
3160    /// - `i < Z3_model_get_num_sorts(c, m)`
3161    ///
3162    /// # See also
3163    ///
3164    /// - [`Z3_model_get_num_sorts`]
3165    /// - [`Z3_model_get_sort_universe`]
3166    pub fn Z3_model_get_sort(
3167        c: Z3_context,
3168        m: Z3_model,
3169        i: ::core::ffi::c_uint,
3170    ) -> Option<Z3_sort>;
3171    /// Return the finite set of distinct values that represent the interpretation for sort `s`.
3172    ///
3173    /// # See also
3174    ///
3175    /// - [`Z3_model_get_num_sorts`]
3176    /// - [`Z3_model_get_sort`]
3177    pub fn Z3_model_get_sort_universe(
3178        c: Z3_context,
3179        m: Z3_model,
3180        s: Z3_sort,
3181    ) -> Option<Z3_ast_vector>;
3182    /// translate model from context `c` to context `dst`.
3183    ///
3184    /// **Remark:** Use this method for cloning state between contexts. Note that
3185    /// operations on contexts are not thread safe and therefore all operations
3186    /// that related to a given context have to be synchronized (or run in the same thread).
3187    pub fn Z3_model_translate(
3188        c: Z3_context,
3189        m: Z3_model,
3190        dst: Z3_context,
3191    ) -> Option<Z3_model>;
3192    /// The `(_ as-array f)` AST node is a construct for assigning interpretations for arrays in Z3.
3193    /// It is the array such that forall indices `i` we have that `(select (_ as-array f) i)` is equal to `(f i)`.
3194    /// This procedure returns `true` if the `a` is an `as`-array AST node.
3195    ///
3196    /// Z3 current solvers have minimal support for `as_array` nodes.
3197    ///
3198    /// # See also
3199    ///
3200    /// - [`Z3_get_as_array_func_decl`]
3201    pub fn Z3_is_as_array(c: Z3_context, a: Z3_ast) -> bool;
3202    /// Return the function declaration `f` associated with a `(_ as_array f)` node.
3203    ///
3204    /// # See also
3205    ///
3206    /// - [`Z3_is_as_array`]
3207    pub fn Z3_get_as_array_func_decl(c: Z3_context, a: Z3_ast) -> Option<Z3_func_decl>;
3208    /// Create a fresh func_interp object, add it to a model for a specified function.
3209    /// It has reference count 0.
3210    ///
3211    /// - `c`: context
3212    /// - `m`: model
3213    /// - `f`: function declaration
3214    /// - `default_value`: default value for function interpretation
3215    pub fn Z3_add_func_interp(
3216        c: Z3_context,
3217        m: Z3_model,
3218        f: Z3_func_decl,
3219        default_value: Z3_ast,
3220    ) -> Option<Z3_func_interp>;
3221    /// Add a constant interpretation.
3222    pub fn Z3_add_const_interp(c: Z3_context, m: Z3_model, f: Z3_func_decl, a: Z3_ast);
3223    /// Increment the reference counter of the given `Z3_func_interp` object.
3224    pub fn Z3_func_interp_inc_ref(c: Z3_context, f: Z3_func_interp);
3225    /// Decrement the reference counter of the given `Z3_func_interp` object.
3226    pub fn Z3_func_interp_dec_ref(c: Z3_context, f: Z3_func_interp);
3227    /// Return the number of entries in the given function interpretation.
3228    ///
3229    /// A function interpretation is represented as a finite map and an 'else' value.
3230    /// Each entry in the finite map represents the value of a function given a set of arguments.
3231    /// This procedure return the number of element in the finite map of `f`.
3232    ///
3233    /// # See also
3234    ///
3235    /// - [`Z3_func_interp_get_entry`]
3236    pub fn Z3_func_interp_get_num_entries(
3237        c: Z3_context,
3238        f: Z3_func_interp,
3239    ) -> ::core::ffi::c_uint;
3240    /// Return a "point" of the given function interpretation. It represents the
3241    /// value of `f` in a particular point.
3242    ///
3243    /// # Preconditions
3244    ///
3245    /// - `i < Z3_func_interp_get_num_entries(c, f)`
3246    ///
3247    /// # See also
3248    ///
3249    /// - [`Z3_func_interp_get_num_entries`]
3250    pub fn Z3_func_interp_get_entry(
3251        c: Z3_context,
3252        f: Z3_func_interp,
3253        i: ::core::ffi::c_uint,
3254    ) -> Option<Z3_func_entry>;
3255    /// Return the 'else' value of the given function interpretation.
3256    ///
3257    /// A function interpretation is represented as a finite map and an 'else' value.
3258    /// This procedure returns the 'else' value.
3259    pub fn Z3_func_interp_get_else(c: Z3_context, f: Z3_func_interp) -> Option<Z3_ast>;
3260    /// Return the 'else' value of the given function interpretation.
3261    ///
3262    /// A function interpretation is represented as a finite map and an 'else' value.
3263    /// This procedure can be used to update the 'else' value.
3264    pub fn Z3_func_interp_set_else(c: Z3_context, f: Z3_func_interp, else_value: Z3_ast);
3265    /// Return the arity (number of arguments) of the given function interpretation.
3266    pub fn Z3_func_interp_get_arity(
3267        c: Z3_context,
3268        f: Z3_func_interp,
3269    ) -> ::core::ffi::c_uint;
3270    /// add a function entry to a function interpretation.
3271    ///
3272    /// - `c`: logical context
3273    /// - `fi`: a function interpretation to be updated.
3274    /// - `args`: list of arguments. They should be constant values (such as integers) and be of the same types as the domain of the function.
3275    /// - `value`: value of the function when the parameters match args.
3276    ///
3277    /// It is assumed that entries added to a function cover disjoint arguments.
3278    /// If an two entries are added with the same arguments, only the second insertion survives and the
3279    /// first inserted entry is removed.
3280    pub fn Z3_func_interp_add_entry(
3281        c: Z3_context,
3282        fi: Z3_func_interp,
3283        args: Z3_ast_vector,
3284        value: Z3_ast,
3285    );
3286    /// Increment the reference counter of the given `Z3_func_entry` object.
3287    pub fn Z3_func_entry_inc_ref(c: Z3_context, e: Z3_func_entry);
3288    /// Decrement the reference counter of the given `Z3_func_entry` object.
3289    pub fn Z3_func_entry_dec_ref(c: Z3_context, e: Z3_func_entry);
3290    /// Return the value of this point.
3291    ///
3292    /// A `Z3_func_entry` object represents an element in the finite map used to encode
3293    /// a function interpretation.
3294    ///
3295    /// # See also
3296    ///
3297    /// - [`Z3_func_interp_get_entry`]
3298    pub fn Z3_func_entry_get_value(c: Z3_context, e: Z3_func_entry) -> Option<Z3_ast>;
3299    /// Return the number of arguments in a `Z3_func_entry` object.
3300    ///
3301    /// # See also
3302    ///
3303    /// - [`Z3_func_entry_get_arg`]
3304    /// - [`Z3_func_interp_get_entry`]
3305    pub fn Z3_func_entry_get_num_args(
3306        c: Z3_context,
3307        e: Z3_func_entry,
3308    ) -> ::core::ffi::c_uint;
3309    /// Return an argument of a `Z3_func_entry` object.
3310    ///
3311    /// # Preconditions
3312    ///
3313    /// - `i < Z3_func_entry_get_num_args(c, e)`
3314    ///
3315    /// # See also
3316    ///
3317    /// - [`Z3_func_entry_get_num_args`]
3318    /// - [`Z3_func_interp_get_entry`]
3319    pub fn Z3_func_entry_get_arg(
3320        c: Z3_context,
3321        e: Z3_func_entry,
3322        i: ::core::ffi::c_uint,
3323    ) -> Option<Z3_ast>;
3324    /// Log interaction to a file.
3325    ///
3326    ///
3327    /// extra_API('Z3_open_log', BOOL, (_in(STRING),))
3328    ///
3329    /// # See also
3330    ///
3331    /// - [`Z3_append_log`]
3332    /// - [`Z3_close_log`]
3333    pub fn Z3_open_log(filename: Z3_string) -> bool;
3334    /// Append user-defined string to interaction log.
3335    ///
3336    /// The interaction log is opened using [`Z3_open_log`].
3337    /// It contains the formulas that are checked using Z3.
3338    /// You can use this command to append comments, for instance.
3339    ///
3340    ///
3341    /// extra_API('Z3_append_log', VOID, (_in(STRING),))
3342    ///
3343    /// # See also
3344    ///
3345    /// - [`Z3_open_log`]
3346    /// - [`Z3_close_log`]
3347    pub fn Z3_append_log(string: Z3_string);
3348    /// Close interaction log.
3349    ///
3350    ///
3351    /// extra_API('Z3_close_log', VOID, ())
3352    ///
3353    /// # See also
3354    ///
3355    /// - [`Z3_open_log`]
3356    /// - [`Z3_append_log`]
3357    pub fn Z3_close_log();
3358    /// Enable/disable printing warning messages to the console.
3359    ///
3360    /// Warnings are printed after passing `true`, warning messages are
3361    /// suppressed after calling this method with `false`.
3362    pub fn Z3_toggle_warning_messages(enabled: bool);
3363    /// Select mode for the format used for pretty-printing AST nodes.
3364    ///
3365    /// The default mode for pretty printing AST nodes is to produce
3366    /// SMT-LIB style output where common subexpressions are printed
3367    /// at each occurrence. The mode is called `Z3_PRINT_SMTLIB_FULL`.
3368    /// To print shared common subexpressions only once,
3369    /// use the `Z3_PRINT_LOW_LEVEL` mode.
3370    /// To print in way that conforms to SMT-LIB standards and uses let
3371    /// expressions to share common sub-expressions use `Z3_PRINT_SMTLIB2_COMPLIANT`.
3372    ///
3373    /// # See also
3374    ///
3375    /// - [`Z3_ast_to_string`]
3376    /// - [`Z3_pattern_to_string`]
3377    /// - [`Z3_func_decl_to_string`]
3378    pub fn Z3_set_ast_print_mode(c: Z3_context, mode: Z3_ast_print_mode);
3379    /// Convert the given AST node into a string.
3380    ///
3381    /// \warning The result buffer is statically allocated by Z3. It will
3382    /// be automatically deallocated when [`Z3_del_context`] is invoked.
3383    /// So, the buffer is invalidated in the next call to `Z3_ast_to_string`.
3384    ///
3385    /// # See also
3386    ///
3387    /// - [`Z3_pattern_to_string`]
3388    /// - [`Z3_sort_to_string`]
3389    pub fn Z3_ast_to_string(c: Z3_context, a: Z3_ast) -> Z3_string;
3390    pub fn Z3_pattern_to_string(c: Z3_context, p: Z3_pattern) -> Z3_string;
3391    pub fn Z3_sort_to_string(c: Z3_context, s: Z3_sort) -> Z3_string;
3392    pub fn Z3_func_decl_to_string(c: Z3_context, d: Z3_func_decl) -> Z3_string;
3393    /// Convert the given model into a string.
3394    ///
3395    /// \warning The result buffer is statically allocated by Z3. It will
3396    /// be automatically deallocated when [`Z3_del_context`] is invoked.
3397    /// So, the buffer is invalidated in the next call to `Z3_model_to_string`.
3398    pub fn Z3_model_to_string(c: Z3_context, m: Z3_model) -> Z3_string;
3399    /// Convert the given benchmark into SMT-LIB formatted string.
3400    ///
3401    /// \warning The result buffer is statically allocated by Z3. It will
3402    /// be automatically deallocated when [`Z3_del_context`] is invoked.
3403    /// So, the buffer is invalidated in the next call to `Z3_benchmark_to_smtlib_string`.
3404    ///
3405    /// - `c`: - context.
3406    /// - `name`: - name of benchmark. The argument is optional.
3407    /// - `logic`: - the benchmark logic.
3408    /// - `status`: - the status string (sat, unsat, or unknown)
3409    /// - `attributes`: - other attributes, such as source, difficulty or category.
3410    /// - `num_assumptions`: - number of assumptions.
3411    /// - `assumptions`: - auxiliary assumptions.
3412    /// - `formula`: - formula to be checked for consistency in conjunction with assumptions.
3413    pub fn Z3_benchmark_to_smtlib_string(
3414        c: Z3_context,
3415        name: Z3_string,
3416        logic: Z3_string,
3417        status: Z3_string,
3418        attributes: Z3_string,
3419        num_assumptions: ::core::ffi::c_uint,
3420        assumptions: *const Z3_ast,
3421        formula: Z3_ast,
3422    ) -> Z3_string;
3423    /// Parse the given string using the SMT-LIB2 parser.
3424    ///
3425    /// It returns a formula comprising of the conjunction of assertions in the scope
3426    /// (up to push/pop) at the end of the string.
3427    pub fn Z3_parse_smtlib2_string(
3428        c: Z3_context,
3429        str_: Z3_string,
3430        num_sorts: ::core::ffi::c_uint,
3431        sort_names: *const Z3_symbol,
3432        sorts: *const Z3_sort,
3433        num_decls: ::core::ffi::c_uint,
3434        decl_names: *const Z3_symbol,
3435        decls: *const Z3_func_decl,
3436    ) -> Option<Z3_ast_vector>;
3437    /// Similar to [`Z3_parse_smtlib2_string`], but reads the benchmark from a file.
3438    pub fn Z3_parse_smtlib2_file(
3439        c: Z3_context,
3440        file_name: Z3_string,
3441        num_sorts: ::core::ffi::c_uint,
3442        sort_names: *const Z3_symbol,
3443        sorts: *const Z3_sort,
3444        num_decls: ::core::ffi::c_uint,
3445        decl_names: *const Z3_symbol,
3446        decls: *const Z3_func_decl,
3447    ) -> Option<Z3_ast_vector>;
3448    /// Parse and evaluate and SMT-LIB2 command sequence. The state from a previous call is saved so the next
3449    /// evaluation builds on top of the previous call.
3450    ///
3451    ///
3452    /// **Returns:** output generated from processing commands.
3453    pub fn Z3_eval_smtlib2_string(c: Z3_context, str_: Z3_string) -> Z3_string;
3454    /// Create a parser context.
3455    ///
3456    /// A parser context maintains state between calls to `Z3_parser_context_parse_string`
3457    /// where the caller can pass in a set of SMTLIB2 commands.
3458    /// It maintains all the declarations from previous calls together with
3459    /// of sorts and function declarations (including 0-ary) that are added directly to the context.
3460    pub fn Z3_mk_parser_context(c: Z3_context) -> Option<Z3_parser_context>;
3461    /// Increment the reference counter of the given `Z3_parser_context` object.
3462    pub fn Z3_parser_context_inc_ref(c: Z3_context, pc: Z3_parser_context);
3463    /// Decrement the reference counter of the given `Z3_parser_context` object.
3464    pub fn Z3_parser_context_dec_ref(c: Z3_context, pc: Z3_parser_context);
3465    /// Add a sort declaration.
3466    pub fn Z3_parser_context_add_sort(c: Z3_context, pc: Z3_parser_context, s: Z3_sort);
3467    /// Add a function declaration.
3468    pub fn Z3_parser_context_add_decl(
3469        c: Z3_context,
3470        pc: Z3_parser_context,
3471        f: Z3_func_decl,
3472    );
3473    /// Parse a string of SMTLIB2 commands. Return assertions.
3474    pub fn Z3_parser_context_from_string(
3475        c: Z3_context,
3476        pc: Z3_parser_context,
3477        s: Z3_string,
3478    ) -> Option<Z3_ast_vector>;
3479    /// Return the error code for the last API call.
3480    ///
3481    /// A call to a Z3 function may return a non Z3_OK error code,
3482    /// when it is not used correctly.
3483    ///
3484    /// # See also
3485    ///
3486    /// - [`Z3_set_error_handler`]
3487    pub fn Z3_get_error_code(c: Z3_context) -> Z3_error_code;
3488    /// Register a Z3 error handler.
3489    ///
3490    /// A call to a Z3 function may return a non `Z3_OK` error code, when
3491    /// it is not used correctly.  An error handler can be registered
3492    /// and will be called in this case.  To disable the use of the
3493    /// error handler, simply register with `h`=NULL.
3494    ///
3495    /// \warning Log files, created using [`Z3_open_log`], may be potentially incomplete/incorrect if error handlers are used.
3496    ///
3497    /// # See also
3498    ///
3499    /// - [`Z3_get_error_code`]
3500    pub fn Z3_set_error_handler(c: Z3_context, h: Z3_error_handler);
3501    /// Set an error.
3502    pub fn Z3_set_error(c: Z3_context, e: Z3_error_code);
3503    /// Return a string describing the given error code.
3504    pub fn Z3_get_error_msg(c: Z3_context, err: Z3_error_code) -> Z3_string;
3505    /// Return Z3 version number information.
3506    ///
3507    /// # See also
3508    ///
3509    /// - [`Z3_get_full_version`]
3510    pub fn Z3_get_version(
3511        major: *mut ::core::ffi::c_uint,
3512        minor: *mut ::core::ffi::c_uint,
3513        build_number: *mut ::core::ffi::c_uint,
3514        revision_number: *mut ::core::ffi::c_uint,
3515    );
3516    /// Return a string that fully describes the version of Z3 in use.
3517    ///
3518    /// # See also
3519    ///
3520    /// - [`Z3_get_version`]
3521    pub fn Z3_get_full_version() -> Z3_string;
3522    /// Enable tracing messages tagged as `tag` when Z3 is compiled in debug mode.
3523    /// It is a NOOP otherwise
3524    ///
3525    /// # See also
3526    ///
3527    /// - [`Z3_disable_trace`]
3528    pub fn Z3_enable_trace(tag: Z3_string);
3529    /// Disable tracing messages tagged as `tag` when Z3 is compiled in debug mode.
3530    /// It is a NOOP otherwise
3531    ///
3532    /// # See also
3533    ///
3534    /// - [`Z3_enable_trace`]
3535    pub fn Z3_disable_trace(tag: Z3_string);
3536    /// Reset all allocated resources.
3537    ///
3538    /// Use this facility on out-of memory errors.
3539    /// It allows discharging the previous state and resuming afresh.
3540    /// Any pointers previously returned by the API
3541    /// become invalid.
3542    pub fn Z3_reset_memory();
3543    /// Destroy all allocated resources.
3544    ///
3545    /// Any pointers previously returned by the API become invalid.
3546    /// Can be used for memory leak detection.
3547    pub fn Z3_finalize_memory();
3548    /// Create a goal (aka problem). A goal is essentially a set
3549    /// of formulas, that can be solved and/or transformed using
3550    /// tactics and solvers.
3551    ///
3552    /// If `models` is `true`, then model generation is enabled for the new goal.
3553    ///
3554    /// If `unsat_cores` is `true`, then unsat core generation is enabled for the new goal.
3555    ///
3556    /// If `proofs` is `true`, then proof generation is enabled for the new goal. Remark, the
3557    /// Z3 context `c` must have been created with proof generation support.
3558    ///
3559    /// **Remark:** Reference counting must be used to manage goals, even when the `Z3_context` was
3560    /// created using [`Z3_mk_context`] instead of [`Z3_mk_context_rc`].
3561    pub fn Z3_mk_goal(
3562        c: Z3_context,
3563        models: bool,
3564        unsat_cores: bool,
3565        proofs: bool,
3566    ) -> Option<Z3_goal>;
3567    /// Increment the reference counter of the given goal.
3568    pub fn Z3_goal_inc_ref(c: Z3_context, g: Z3_goal);
3569    /// Decrement the reference counter of the given goal.
3570    pub fn Z3_goal_dec_ref(c: Z3_context, g: Z3_goal);
3571    /// Return the "precision" of the given goal. Goals can be transformed using over and under approximations.
3572    /// A under approximation is applied when the objective is to find a model for a given goal.
3573    /// An over approximation is applied when the objective is to find a proof for a given goal.
3574    pub fn Z3_goal_precision(c: Z3_context, g: Z3_goal) -> Z3_goal_prec;
3575    /// Add a new formula `a` to the given goal.
3576    /// The formula is split according to the following procedure that is applied
3577    /// until a fixed-point:
3578    /// Conjunctions are split into separate formulas.
3579    /// Negations are distributed over disjunctions, resulting in separate formulas.
3580    /// If the goal is `false`, adding new formulas is a no-op.
3581    /// If the formula `a` is `true`, then nothing is added.
3582    /// If the formula `a` is `false`, then the entire goal is replaced by the formula `false`.
3583    pub fn Z3_goal_assert(c: Z3_context, g: Z3_goal, a: Z3_ast);
3584    /// Return `true` if the given goal contains the formula `false`.
3585    pub fn Z3_goal_inconsistent(c: Z3_context, g: Z3_goal) -> bool;
3586    /// Return the depth of the given goal. It tracks how many transformations were applied to it.
3587    pub fn Z3_goal_depth(c: Z3_context, g: Z3_goal) -> ::core::ffi::c_uint;
3588    /// Erase all formulas from the given goal.
3589    pub fn Z3_goal_reset(c: Z3_context, g: Z3_goal);
3590    /// Return the number of formulas in the given goal.
3591    pub fn Z3_goal_size(c: Z3_context, g: Z3_goal) -> ::core::ffi::c_uint;
3592    /// Return a formula from the given goal.
3593    ///
3594    /// # Preconditions
3595    ///
3596    /// - `idx < Z3_goal_size(c, g)`
3597    pub fn Z3_goal_formula(
3598        c: Z3_context,
3599        g: Z3_goal,
3600        idx: ::core::ffi::c_uint,
3601    ) -> Option<Z3_ast>;
3602    /// Return the number of formulas, subformulas and terms in the given goal.
3603    pub fn Z3_goal_num_exprs(c: Z3_context, g: Z3_goal) -> ::core::ffi::c_uint;
3604    /// Return `true` if the goal is empty, and it is precise or the product of a under approximation.
3605    pub fn Z3_goal_is_decided_sat(c: Z3_context, g: Z3_goal) -> bool;
3606    /// Return `true` if the goal contains false, and it is precise or the product of an over approximation.
3607    pub fn Z3_goal_is_decided_unsat(c: Z3_context, g: Z3_goal) -> bool;
3608    /// Copy a goal `g` from the context `source` to the context `target`.
3609    pub fn Z3_goal_translate(
3610        source: Z3_context,
3611        g: Z3_goal,
3612        target: Z3_context,
3613    ) -> Option<Z3_goal>;
3614    /// Convert a model of the formulas of a goal to a model of an original goal.
3615    /// The model may be null, in which case the returned model is valid if the goal was
3616    /// established satisfiable.
3617    ///
3618    /// When using this feature it is advisable to set the parameter `model`.compact to `false`.
3619    /// It is by default true, which erases variables created by the solver from models.
3620    /// Without access to model values for intermediary variables, values of other variables
3621    /// may end up having the wrong values.
3622    pub fn Z3_goal_convert_model(
3623        c: Z3_context,
3624        g: Z3_goal,
3625        m: Z3_model,
3626    ) -> Option<Z3_model>;
3627    /// Convert a goal into a string.
3628    pub fn Z3_goal_to_string(c: Z3_context, g: Z3_goal) -> Z3_string;
3629    /// Convert a goal into a DIMACS formatted string.
3630    /// The goal must be in CNF. You can convert a goal to CNF
3631    /// by applying the tseitin-cnf tactic. Bit-vectors are not automatically
3632    /// converted to Booleans either, so if the caller intends to
3633    /// preserve satisfiability, it should apply bit-blasting tactics.
3634    /// Quantifiers and theory atoms will not be encoded.
3635    pub fn Z3_goal_to_dimacs_string(
3636        c: Z3_context,
3637        g: Z3_goal,
3638        include_names: bool,
3639    ) -> Z3_string;
3640    /// Return a tactic associated with the given name.
3641    /// The complete list of tactics may be obtained using the procedures [`Z3_get_num_tactics`] and [`Z3_get_tactic_name`].
3642    /// It may also be obtained using the command `(help-tactic)` in the SMT 2.0 front-end.
3643    ///
3644    /// Tactics are the basic building block for creating custom solvers for specific problem domains.
3645    pub fn Z3_mk_tactic(c: Z3_context, name: Z3_string) -> Option<Z3_tactic>;
3646    /// Increment the reference counter of the given tactic.
3647    pub fn Z3_tactic_inc_ref(c: Z3_context, t: Z3_tactic);
3648    /// Decrement the reference counter of the given tactic.
3649    pub fn Z3_tactic_dec_ref(c: Z3_context, g: Z3_tactic);
3650    /// Return a probe associated with the given name.
3651    /// The complete list of probes may be obtained using the procedures [`Z3_get_num_probes`] and [`Z3_get_probe_name`].
3652    /// It may also be obtained using the command `(help-tactic)` in the SMT 2.0 front-end.
3653    ///
3654    /// Probes are used to inspect a goal (aka problem) and collect information that may be used to decide
3655    /// which solver and/or preprocessing step will be used.
3656    pub fn Z3_mk_probe(c: Z3_context, name: Z3_string) -> Option<Z3_probe>;
3657    /// Increment the reference counter of the given probe.
3658    pub fn Z3_probe_inc_ref(c: Z3_context, p: Z3_probe);
3659    /// Decrement the reference counter of the given probe.
3660    pub fn Z3_probe_dec_ref(c: Z3_context, p: Z3_probe);
3661    /// Return a tactic that applies `t1` to a given goal and `t2`
3662    /// to every subgoal produced by `t1`.
3663    pub fn Z3_tactic_and_then(
3664        c: Z3_context,
3665        t1: Z3_tactic,
3666        t2: Z3_tactic,
3667    ) -> Option<Z3_tactic>;
3668    /// Return a tactic that first applies `t1` to a given goal,
3669    /// if it fails then returns the result of `t2` applied to the given goal.
3670    pub fn Z3_tactic_or_else(
3671        c: Z3_context,
3672        t1: Z3_tactic,
3673        t2: Z3_tactic,
3674    ) -> Option<Z3_tactic>;
3675    /// Return a tactic that applies the given tactics in parallel.
3676    pub fn Z3_tactic_par_or(
3677        c: Z3_context,
3678        num: ::core::ffi::c_uint,
3679        ts: *const Z3_tactic,
3680    ) -> Option<Z3_tactic>;
3681    /// Return a tactic that applies `t1` to a given goal and then `t2`
3682    /// to every subgoal produced by `t1`. The subgoals are processed in parallel.
3683    pub fn Z3_tactic_par_and_then(
3684        c: Z3_context,
3685        t1: Z3_tactic,
3686        t2: Z3_tactic,
3687    ) -> Option<Z3_tactic>;
3688    /// Return a tactic that applies `t` to a given goal for `ms` milliseconds.
3689    /// If `t` does not terminate in `ms` milliseconds, then it fails.
3690    pub fn Z3_tactic_try_for(
3691        c: Z3_context,
3692        t: Z3_tactic,
3693        ms: ::core::ffi::c_uint,
3694    ) -> Option<Z3_tactic>;
3695    /// Return a tactic that applies `t` to a given goal is the probe `p` evaluates to true.
3696    /// If `p` evaluates to false, then the new tactic behaves like the skip tactic.
3697    pub fn Z3_tactic_when(c: Z3_context, p: Z3_probe, t: Z3_tactic) -> Option<Z3_tactic>;
3698    /// Return a tactic that applies `t1` to a given goal if the probe `p` evaluates to true,
3699    /// and `t2` if `p` evaluates to false.
3700    pub fn Z3_tactic_cond(
3701        c: Z3_context,
3702        p: Z3_probe,
3703        t1: Z3_tactic,
3704        t2: Z3_tactic,
3705    ) -> Option<Z3_tactic>;
3706    /// Return a tactic that keeps applying `t` until the goal is not modified anymore or the maximum
3707    /// number of iterations `max` is reached.
3708    pub fn Z3_tactic_repeat(
3709        c: Z3_context,
3710        t: Z3_tactic,
3711        max: ::core::ffi::c_uint,
3712    ) -> Option<Z3_tactic>;
3713    /// Return a tactic that just return the given goal.
3714    pub fn Z3_tactic_skip(c: Z3_context) -> Option<Z3_tactic>;
3715    /// Return a tactic that always fails.
3716    pub fn Z3_tactic_fail(c: Z3_context) -> Option<Z3_tactic>;
3717    /// Return a tactic that fails if the probe `p` evaluates to false.
3718    pub fn Z3_tactic_fail_if(c: Z3_context, p: Z3_probe) -> Option<Z3_tactic>;
3719    /// Return a tactic that fails if the goal is not trivially satisfiable (i.e., empty) or
3720    /// trivially unsatisfiable (i.e., contains false).
3721    pub fn Z3_tactic_fail_if_not_decided(c: Z3_context) -> Option<Z3_tactic>;
3722    /// Return a tactic that applies `t` using the given set of parameters.
3723    pub fn Z3_tactic_using_params(
3724        c: Z3_context,
3725        t: Z3_tactic,
3726        p: Z3_params,
3727    ) -> Option<Z3_tactic>;
3728    /// Return a simplifier associated with the given name.
3729    /// The complete list of simplifiers may be obtained using the procedures [`Z3_get_num_simplifiers`] and [`Z3_get_simplifier_name`].
3730    /// It may also be obtained using the command `(help-simplifier)` in the SMT 2.0 front-end.
3731    ///
3732    /// Simplifiers are the basic building block for creating custom solvers for specific problem domains.
3733    pub fn Z3_mk_simplifier(c: Z3_context, name: Z3_string) -> Option<Z3_simplifier>;
3734    /// Increment the reference counter of the given simplifier.
3735    pub fn Z3_simplifier_inc_ref(c: Z3_context, t: Z3_simplifier);
3736    /// Decrement the reference counter of the given simplifier.
3737    pub fn Z3_simplifier_dec_ref(c: Z3_context, g: Z3_simplifier);
3738    /// Attach simplifier to a solver. The solver will use the simplifier for incremental pre-processing.
3739    pub fn Z3_solver_add_simplifier(
3740        c: Z3_context,
3741        solver: Z3_solver,
3742        simplifier: Z3_simplifier,
3743    ) -> Option<Z3_solver>;
3744    /// Return a simplifier that applies `t1` to a given goal and `t2`
3745    /// to every subgoal produced by `t1`.
3746    pub fn Z3_simplifier_and_then(
3747        c: Z3_context,
3748        t1: Z3_simplifier,
3749        t2: Z3_simplifier,
3750    ) -> Option<Z3_simplifier>;
3751    /// Return a simplifier that applies `t` using the given set of parameters.
3752    pub fn Z3_simplifier_using_params(
3753        c: Z3_context,
3754        t: Z3_simplifier,
3755        p: Z3_params,
3756    ) -> Option<Z3_simplifier>;
3757    /// Return the number of builtin simplifiers available in Z3.
3758    ///
3759    /// # See also
3760    ///
3761    /// - [`Z3_get_simplifier_name`]
3762    pub fn Z3_get_num_simplifiers(c: Z3_context) -> ::core::ffi::c_uint;
3763    /// Return the name of the idx simplifier.
3764    ///
3765    /// # Preconditions
3766    ///
3767    /// - `i < Z3_get_num_simplifiers(c)`
3768    ///
3769    /// # See also
3770    ///
3771    /// - [`Z3_get_num_simplifiers`]
3772    pub fn Z3_get_simplifier_name(c: Z3_context, i: ::core::ffi::c_uint) -> Z3_string;
3773    /// Return a string containing a description of parameters accepted by the given simplifier.
3774    pub fn Z3_simplifier_get_help(c: Z3_context, t: Z3_simplifier) -> Z3_string;
3775    /// Return the parameter description set for the given simplifier object.
3776    pub fn Z3_simplifier_get_param_descrs(
3777        c: Z3_context,
3778        t: Z3_simplifier,
3779    ) -> Option<Z3_param_descrs>;
3780    /// Return a string containing a description of the simplifier with the given name.
3781    pub fn Z3_simplifier_get_descr(c: Z3_context, name: Z3_string) -> Z3_string;
3782    /// Return a probe that always evaluates to val.
3783    pub fn Z3_probe_const(x: Z3_context, val: f64) -> Option<Z3_probe>;
3784    /// Return a probe that evaluates to "true" when the value returned by `p1` is less than the value returned by `p2`.
3785    ///
3786    /// **Remark:** For probes, "true" is any value different from 0.0.
3787    pub fn Z3_probe_lt(x: Z3_context, p1: Z3_probe, p2: Z3_probe) -> Option<Z3_probe>;
3788    /// Return a probe that evaluates to "true" when the value returned by `p1` is greater than the value returned by `p2`.
3789    ///
3790    /// **Remark:** For probes, "true" is any value different from 0.0.
3791    pub fn Z3_probe_gt(x: Z3_context, p1: Z3_probe, p2: Z3_probe) -> Option<Z3_probe>;
3792    /// Return a probe that evaluates to "true" when the value returned by `p1` is less than or equal to the value returned by `p2`.
3793    ///
3794    /// **Remark:** For probes, "true" is any value different from 0.0.
3795    pub fn Z3_probe_le(x: Z3_context, p1: Z3_probe, p2: Z3_probe) -> Option<Z3_probe>;
3796    /// Return a probe that evaluates to "true" when the value returned by `p1` is greater than or equal to the value returned by `p2`.
3797    ///
3798    /// **Remark:** For probes, "true" is any value different from 0.0.
3799    pub fn Z3_probe_ge(x: Z3_context, p1: Z3_probe, p2: Z3_probe) -> Option<Z3_probe>;
3800    /// Return a probe that evaluates to "true" when the value returned by `p1` is equal to the value returned by `p2`.
3801    ///
3802    /// **Remark:** For probes, "true" is any value different from 0.0.
3803    pub fn Z3_probe_eq(x: Z3_context, p1: Z3_probe, p2: Z3_probe) -> Option<Z3_probe>;
3804    /// Return a probe that evaluates to "true" when `p1` and `p2` evaluates to true.
3805    ///
3806    /// **Remark:** For probes, "true" is any value different from 0.0.
3807    pub fn Z3_probe_and(x: Z3_context, p1: Z3_probe, p2: Z3_probe) -> Option<Z3_probe>;
3808    /// Return a probe that evaluates to "true" when `p1` or `p2` evaluates to true.
3809    ///
3810    /// **Remark:** For probes, "true" is any value different from 0.0.
3811    pub fn Z3_probe_or(x: Z3_context, p1: Z3_probe, p2: Z3_probe) -> Option<Z3_probe>;
3812    /// Return a probe that evaluates to "true" when `p` does not evaluate to true.
3813    ///
3814    /// **Remark:** For probes, "true" is any value different from 0.0.
3815    pub fn Z3_probe_not(x: Z3_context, p: Z3_probe) -> Option<Z3_probe>;
3816    /// Return the number of builtin tactics available in Z3.
3817    ///
3818    /// # See also
3819    ///
3820    /// - [`Z3_get_tactic_name`]
3821    pub fn Z3_get_num_tactics(c: Z3_context) -> ::core::ffi::c_uint;
3822    /// Return the name of the idx tactic.
3823    ///
3824    /// # Preconditions
3825    ///
3826    /// - `i < Z3_get_num_tactics(c)`
3827    ///
3828    /// # See also
3829    ///
3830    /// - [`Z3_get_num_tactics`]
3831    pub fn Z3_get_tactic_name(c: Z3_context, i: ::core::ffi::c_uint) -> Z3_string;
3832    /// Return the number of builtin probes available in Z3.
3833    ///
3834    /// # See also
3835    ///
3836    /// - [`Z3_get_probe_name`]
3837    pub fn Z3_get_num_probes(c: Z3_context) -> ::core::ffi::c_uint;
3838    /// Return the name of the `i` probe.
3839    ///
3840    /// # Preconditions
3841    ///
3842    /// - `i < Z3_get_num_probes(c)`
3843    ///
3844    /// # See also
3845    ///
3846    /// - [`Z3_get_num_probes`]
3847    pub fn Z3_get_probe_name(c: Z3_context, i: ::core::ffi::c_uint) -> Z3_string;
3848    /// Return a string containing a description of parameters accepted by the given tactic.
3849    pub fn Z3_tactic_get_help(c: Z3_context, t: Z3_tactic) -> Z3_string;
3850    /// Return the parameter description set for the given tactic object.
3851    pub fn Z3_tactic_get_param_descrs(
3852        c: Z3_context,
3853        t: Z3_tactic,
3854    ) -> Option<Z3_param_descrs>;
3855    /// Return a string containing a description of the tactic with the given name.
3856    pub fn Z3_tactic_get_descr(c: Z3_context, name: Z3_string) -> Z3_string;
3857    /// Return a string containing a description of the probe with the given name.
3858    pub fn Z3_probe_get_descr(c: Z3_context, name: Z3_string) -> Z3_string;
3859    /// Execute the probe over the goal. The probe always produce a double value.
3860    /// "Boolean" probes return 0.0 for false, and a value different from 0.0 for true.
3861    pub fn Z3_probe_apply(c: Z3_context, p: Z3_probe, g: Z3_goal) -> f64;
3862    /// Apply tactic `t` to the goal `g`.
3863    ///
3864    /// # See also
3865    ///
3866    /// - [`Z3_tactic_apply_ex`]
3867    pub fn Z3_tactic_apply(
3868        c: Z3_context,
3869        t: Z3_tactic,
3870        g: Z3_goal,
3871    ) -> Option<Z3_apply_result>;
3872    /// Apply tactic `t` to the goal `g` using the parameter set `p`.
3873    ///
3874    /// # See also
3875    ///
3876    /// - [`Z3_tactic_apply`]
3877    pub fn Z3_tactic_apply_ex(
3878        c: Z3_context,
3879        t: Z3_tactic,
3880        g: Z3_goal,
3881        p: Z3_params,
3882    ) -> Option<Z3_apply_result>;
3883    /// Increment the reference counter of the given `Z3_apply_result` object.
3884    pub fn Z3_apply_result_inc_ref(c: Z3_context, r: Z3_apply_result);
3885    /// Decrement the reference counter of the given `Z3_apply_result` object.
3886    pub fn Z3_apply_result_dec_ref(c: Z3_context, r: Z3_apply_result);
3887    /// Convert the `Z3_apply_result` object returned by [`Z3_tactic_apply`] into a string.
3888    pub fn Z3_apply_result_to_string(c: Z3_context, r: Z3_apply_result) -> Z3_string;
3889    /// Return the number of subgoals in the `Z3_apply_result` object returned by [`Z3_tactic_apply`].
3890    ///
3891    /// # See also
3892    ///
3893    /// - [`Z3_apply_result_get_subgoal`]
3894    pub fn Z3_apply_result_get_num_subgoals(
3895        c: Z3_context,
3896        r: Z3_apply_result,
3897    ) -> ::core::ffi::c_uint;
3898    /// Return one of the subgoals in the `Z3_apply_result` object returned by [`Z3_tactic_apply`].
3899    ///
3900    /// # Preconditions
3901    ///
3902    /// - `i < Z3_apply_result_get_num_subgoals(c, r)`
3903    ///
3904    /// # See also
3905    ///
3906    /// - [`Z3_apply_result_get_num_subgoals`]
3907    pub fn Z3_apply_result_get_subgoal(
3908        c: Z3_context,
3909        r: Z3_apply_result,
3910        i: ::core::ffi::c_uint,
3911    ) -> Option<Z3_goal>;
3912    /// Create a new solver. This solver is a "combined solver" (see
3913    /// combined_solver module) that internally uses a non-incremental (solver1) and an
3914    /// incremental solver (solver2). This combined solver changes its behaviour based
3915    /// on how it is used and how its parameters are set.
3916    ///
3917    /// If the solver is used in a non incremental way (i.e. no calls to
3918    /// [`Z3_solver_push`] or [`Z3_solver_pop`], and no calls to
3919    /// [`Z3_solver_assert`] or [`Z3_solver_assert_and_track`] after checking
3920    /// satisfiability without an intervening [`Z3_solver_reset`]) then solver1
3921    /// will be used. This solver will apply Z3's "default" tactic.
3922    ///
3923    /// The "default" tactic will attempt to probe the logic used by the
3924    /// assertions and will apply a specialized tactic if one is supported.
3925    /// Otherwise the general `(and-then simplify smt)` tactic will be used.
3926    ///
3927    /// If the solver is used in an incremental way then the combined solver
3928    /// will switch to using solver2 (which behaves similarly to the general
3929    /// "smt" tactic).
3930    ///
3931    /// Note however it is possible to set the `solver2_timeout`,
3932    /// `solver2_unknown`, and `ignore_solver1` parameters of the combined
3933    /// solver to change its behaviour.
3934    ///
3935    /// The function [`Z3_solver_get_model`] retrieves a model if the
3936    /// assertions is satisfiable (i.e., the result is `Z3_L_TRUE`) and model construction is enabled.
3937    /// The function [`Z3_solver_get_model`] can also be used even
3938    /// if the result is `Z3_L_UNDEF`, but the returned model
3939    /// is not guaranteed to satisfy quantified assertions.
3940    ///
3941    /// **Remark:** User must use [`Z3_solver_inc_ref`] and [`Z3_solver_dec_ref`] to manage solver objects.
3942    /// Even if the context was created using [`Z3_mk_context`] instead of [`Z3_mk_context_rc`].
3943    ///
3944    /// # See also
3945    ///
3946    /// - [`Z3_mk_simple_solver`]
3947    /// - [`Z3_mk_solver_for_logic`]
3948    /// - [`Z3_mk_solver_from_tactic`]
3949    pub fn Z3_mk_solver(c: Z3_context) -> Option<Z3_solver>;
3950    /// Create a new incremental solver.
3951    ///
3952    /// This is equivalent to applying the "smt" tactic.
3953    ///
3954    /// Unlike [`Z3_mk_solver`] this solver
3955    /// - Does not attempt to apply any logic specific tactics.
3956    /// - Does not change its behaviour based on whether it used
3957    /// incrementally/non-incrementally.
3958    ///
3959    /// Note that these differences can result in very different performance
3960    /// compared to [`Z3_mk_solver`].
3961    ///
3962    /// The function [`Z3_solver_get_model`] retrieves a model if the
3963    /// assertions is satisfiable (i.e., the result is `Z3_L_TRUE`) and model construction is enabled.
3964    /// The function [`Z3_solver_get_model`] can also be used even
3965    /// if the result is `Z3_L_UNDEF`, but the returned model
3966    /// is not guaranteed to satisfy quantified assertions.
3967    ///
3968    /// **Remark:** User must use [`Z3_solver_inc_ref`] and [`Z3_solver_dec_ref`] to manage solver objects.
3969    /// Even if the context was created using [`Z3_mk_context`] instead of [`Z3_mk_context_rc`].
3970    ///
3971    /// # See also
3972    ///
3973    /// - [`Z3_mk_solver`]
3974    /// - [`Z3_mk_solver_for_logic`]
3975    /// - [`Z3_mk_solver_from_tactic`]
3976    pub fn Z3_mk_simple_solver(c: Z3_context) -> Option<Z3_solver>;
3977    /// Create a new solver customized for the given logic.
3978    /// It behaves like [`Z3_mk_solver`] if the logic is unknown or unsupported.
3979    ///
3980    /// **Remark:** User must use [`Z3_solver_inc_ref`] and [`Z3_solver_dec_ref`] to manage solver objects.
3981    /// Even if the context was created using [`Z3_mk_context`] instead of [`Z3_mk_context_rc`].
3982    ///
3983    /// # See also
3984    ///
3985    /// - [`Z3_mk_solver`]
3986    /// - [`Z3_mk_simple_solver`]
3987    /// - [`Z3_mk_solver_from_tactic`]
3988    pub fn Z3_mk_solver_for_logic(c: Z3_context, logic: Z3_symbol) -> Option<Z3_solver>;
3989    /// Create a new solver that is implemented using the given tactic.
3990    /// The solver supports the commands [`Z3_solver_push`] and [`Z3_solver_pop`], but it
3991    /// will always solve each [`Z3_solver_check`] from scratch.
3992    ///
3993    /// **Remark:** User must use [`Z3_solver_inc_ref`] and [`Z3_solver_dec_ref`] to manage solver objects.
3994    /// Even if the context was created using [`Z3_mk_context`] instead of [`Z3_mk_context_rc`].
3995    ///
3996    /// # See also
3997    ///
3998    /// - [`Z3_mk_solver`]
3999    /// - [`Z3_mk_simple_solver`]
4000    /// - [`Z3_mk_solver_for_logic`]
4001    pub fn Z3_mk_solver_from_tactic(c: Z3_context, t: Z3_tactic) -> Option<Z3_solver>;
4002    /// Copy a solver `s` from the context `source` to the context `target`.
4003    pub fn Z3_solver_translate(
4004        source: Z3_context,
4005        s: Z3_solver,
4006        target: Z3_context,
4007    ) -> Option<Z3_solver>;
4008    /// Ad-hoc method for importing model conversion from solver.
4009    ///
4010    /// This method is used for scenarios where `src` has been used to solve a set
4011    /// of formulas and was interrupted. The `dst` solver may be a strengthening of `src`
4012    /// obtained from cubing (assigning a subset of literals or adding constraints over the
4013    /// assertions available in `src`). If `dst` ends up being satisfiable, the model for `dst`
4014    /// may not correspond to a model of the original formula due to inprocessing in `src`.
4015    /// This method is used to take the side-effect of inprocessing into account when returning
4016    /// a model for `dst`.
4017    pub fn Z3_solver_import_model_converter(
4018        ctx: Z3_context,
4019        src: Z3_solver,
4020        dst: Z3_solver,
4021    );
4022    /// Return a string describing all solver available parameters.
4023    ///
4024    /// # See also
4025    ///
4026    /// - [`Z3_solver_get_param_descrs`]
4027    /// - [`Z3_solver_set_params`]
4028    pub fn Z3_solver_get_help(c: Z3_context, s: Z3_solver) -> Z3_string;
4029    /// Return the parameter description set for the given solver object.
4030    ///
4031    /// # See also
4032    ///
4033    /// - [`Z3_solver_get_help`]
4034    /// - [`Z3_solver_set_params`]
4035    pub fn Z3_solver_get_param_descrs(
4036        c: Z3_context,
4037        s: Z3_solver,
4038    ) -> Option<Z3_param_descrs>;
4039    /// Set the given solver using the given parameters.
4040    ///
4041    /// # See also
4042    ///
4043    /// - [`Z3_solver_get_help`]
4044    /// - [`Z3_solver_get_param_descrs`]
4045    pub fn Z3_solver_set_params(c: Z3_context, s: Z3_solver, p: Z3_params);
4046    /// Increment the reference counter of the given solver.
4047    pub fn Z3_solver_inc_ref(c: Z3_context, s: Z3_solver);
4048    /// Decrement the reference counter of the given solver.
4049    pub fn Z3_solver_dec_ref(c: Z3_context, s: Z3_solver);
4050    /// Solver local interrupt.
4051    /// Normally you should use Z3_interrupt to cancel solvers because only
4052    /// one solver is enabled concurrently per context.
4053    /// However, per GitHub issue #1006, there are use cases where
4054    /// it is more convenient to cancel a specific solver. Solvers
4055    /// that are not selected for interrupts are left alone.
4056    pub fn Z3_solver_interrupt(c: Z3_context, s: Z3_solver);
4057    /// Create a backtracking point.
4058    ///
4059    /// The solver contains a stack of assertions.
4060    ///
4061    /// # See also
4062    ///
4063    /// - [`Z3_solver_get_num_scopes`]
4064    /// - [`Z3_solver_pop`]
4065    pub fn Z3_solver_push(c: Z3_context, s: Z3_solver);
4066    /// Backtrack `n` backtracking points.
4067    ///
4068    /// # Preconditions
4069    ///
4070    /// - `n <= Z3_solver_get_num_scopes(c, s)`
4071    ///
4072    /// # See also
4073    ///
4074    /// - [`Z3_solver_get_num_scopes`]
4075    /// - [`Z3_solver_push`]
4076    pub fn Z3_solver_pop(c: Z3_context, s: Z3_solver, n: ::core::ffi::c_uint);
4077    /// Remove all assertions from the solver.
4078    ///
4079    /// # See also
4080    ///
4081    /// - [`Z3_solver_assert`]
4082    /// - [`Z3_solver_assert_and_track`]
4083    pub fn Z3_solver_reset(c: Z3_context, s: Z3_solver);
4084    /// Return the number of backtracking points.
4085    ///
4086    /// # See also
4087    ///
4088    /// - [`Z3_solver_push`]
4089    /// - [`Z3_solver_pop`]
4090    pub fn Z3_solver_get_num_scopes(c: Z3_context, s: Z3_solver) -> ::core::ffi::c_uint;
4091    /// Assert a constraint into the solver.
4092    ///
4093    /// The functions [`Z3_solver_check`] and [`Z3_solver_check_assumptions`] should be
4094    /// used to check whether the logical context is consistent or not.
4095    ///
4096    /// # See also
4097    ///
4098    /// - [`Z3_solver_assert_and_track`]
4099    /// - [`Z3_solver_reset`]
4100    pub fn Z3_solver_assert(c: Z3_context, s: Z3_solver, a: Z3_ast);
4101    /// Assert a constraint `a` into the solver, and track it (in the unsat) core using
4102    /// the Boolean constant `p`.
4103    ///
4104    /// This API is an alternative to [`Z3_solver_check_assumptions`] for extracting unsat cores.
4105    /// Both APIs can be used in the same solver. The unsat core will contain a combination
4106    /// of the Boolean variables provided using Z3_solver_assert_and_track and the Boolean literals
4107    /// provided using [`Z3_solver_check_assumptions`].
4108    ///
4109    /// # Preconditions
4110    ///
4111    /// - ``a` must be a Boolean expression`
4112    /// - ``p` must be a Boolean constant (aka variable).`
4113    ///
4114    /// # See also
4115    ///
4116    /// - [`Z3_solver_assert`]
4117    /// - [`Z3_solver_reset`]
4118    pub fn Z3_solver_assert_and_track(c: Z3_context, s: Z3_solver, a: Z3_ast, p: Z3_ast);
4119    /// load solver assertions from a file.
4120    ///
4121    /// # See also
4122    ///
4123    /// - [`Z3_solver_from_string`]
4124    /// - [`Z3_solver_to_string`]
4125    pub fn Z3_solver_from_file(c: Z3_context, s: Z3_solver, file_name: Z3_string);
4126    /// load solver assertions from a string.
4127    ///
4128    /// # See also
4129    ///
4130    /// - [`Z3_solver_from_file`]
4131    /// - [`Z3_solver_to_string`]
4132    pub fn Z3_solver_from_string(c: Z3_context, s: Z3_solver, str_: Z3_string);
4133    /// Return the set of asserted formulas on the solver.
4134    pub fn Z3_solver_get_assertions(
4135        c: Z3_context,
4136        s: Z3_solver,
4137    ) -> Option<Z3_ast_vector>;
4138    /// Return the set of units modulo model conversion.
4139    pub fn Z3_solver_get_units(c: Z3_context, s: Z3_solver) -> Option<Z3_ast_vector>;
4140    /// Return the trail modulo model conversion, in order of decision level
4141    /// The decision level can be retrieved using `Z3_solver_get_level` based on the trail.
4142    pub fn Z3_solver_get_trail(c: Z3_context, s: Z3_solver) -> Option<Z3_ast_vector>;
4143    /// Return the set of non units in the solver state.
4144    pub fn Z3_solver_get_non_units(c: Z3_context, s: Z3_solver) -> Option<Z3_ast_vector>;
4145    /// retrieve the decision depth of Boolean literals (variables or their negations).
4146    /// Assumes a check-sat call and no other calls (to extract models) have been invoked.
4147    pub fn Z3_solver_get_levels(
4148        c: Z3_context,
4149        s: Z3_solver,
4150        literals: Z3_ast_vector,
4151        sz: ::core::ffi::c_uint,
4152        levels: *mut ::core::ffi::c_uint,
4153    );
4154    /// retrieve the congruence closure root of an expression.
4155    /// The root is retrieved relative to the state where the solver was in when it completed.
4156    /// If it completed during a set of case splits, the congruence roots are relative to these case splits.
4157    /// That is, the congruences are not consequences but they are true under the current state.
4158    pub fn Z3_solver_congruence_root(
4159        c: Z3_context,
4160        s: Z3_solver,
4161        a: Z3_ast,
4162    ) -> Option<Z3_ast>;
4163    /// retrieve the next expression in the congruence class. The set of congruent siblings form a cyclic list.
4164    /// Repeated calls on the siblings will result in returning to the original expression.
4165    pub fn Z3_solver_congruence_next(
4166        c: Z3_context,
4167        s: Z3_solver,
4168        a: Z3_ast,
4169    ) -> Option<Z3_ast>;
4170    /// retrieve explanation for congruence.
4171    ///
4172    /// # Preconditions
4173    ///
4174    /// - `root(a) = root(b)`
4175    pub fn Z3_solver_congruence_explain(
4176        c: Z3_context,
4177        s: Z3_solver,
4178        a: Z3_ast,
4179        b: Z3_ast,
4180    ) -> Option<Z3_ast>;
4181    /// retrieve a 'solution' for `variables` as defined by equalities in maintained by solvers.
4182    /// At this point, only linear solution are supported.
4183    /// The solution to `variables` may be presented in triangular form, such that
4184    /// variables used in solutions themselves have solutions.
4185    pub fn Z3_solver_solve_for(
4186        c: Z3_context,
4187        s: Z3_solver,
4188        variables: Z3_ast_vector,
4189        terms: Z3_ast_vector,
4190        guards: Z3_ast_vector,
4191    );
4192    /// register a callback to that retrieves assumed, inferred and deleted clauses during search.
4193    ///
4194    /// - `c`: - context.
4195    /// - `s`: - solver object.
4196    /// - `user_context`: - a context used to maintain state for callbacks.
4197    /// - `on_clause_eh`: - a callback that is invoked by when a clause is
4198    /// - asserted to the CDCL engine (corresponding to an input clause after pre-processing)
4199    /// - inferred by CDCL(T) using either a SAT or theory conflict/propagation
4200    /// - deleted by the CDCL(T) engine
4201    pub fn Z3_solver_register_on_clause(
4202        c: Z3_context,
4203        s: Z3_solver,
4204        user_context: *mut ::core::ffi::c_void,
4205        on_clause_eh: Z3_on_clause_eh,
4206    );
4207    /// register a user-propagator with the solver.
4208    ///
4209    /// - `c`: - context.
4210    /// - `s`: - solver object.
4211    /// - `user_context`: - a context used to maintain state for callbacks.
4212    /// - `push_eh`: - a callback invoked when scopes are pushed
4213    /// - `pop_eh`: - a callback invoked when scopes are popped
4214    /// - `fresh_eh`: - a solver may spawn new solvers internally. This callback is used to produce a fresh user_context to be associated with fresh solvers.
4215    pub fn Z3_solver_propagate_init(
4216        c: Z3_context,
4217        s: Z3_solver,
4218        user_context: *mut ::core::ffi::c_void,
4219        push_eh: Z3_push_eh,
4220        pop_eh: Z3_pop_eh,
4221        fresh_eh: Z3_fresh_eh,
4222    );
4223    /// register a callback for when an expression is bound to a fixed value.
4224    /// The supported expression types are
4225    /// - Booleans
4226    /// - Bit-vectors
4227    pub fn Z3_solver_propagate_fixed(c: Z3_context, s: Z3_solver, fixed_eh: Z3_fixed_eh);
4228    /// register a callback on final check.
4229    /// This provides freedom to the propagator to delay actions or implement a branch-and bound solver.
4230    /// The final check is invoked when all decision variables have been assigned by the solver.
4231    ///
4232    /// The `final_eh` callback takes as argument the original user_context that was used
4233    /// when calling `Z3_solver_propagate_init`, and it takes a callback context with the
4234    /// opaque type `Z3_solver_callback`.
4235    /// The callback context is passed as argument to invoke the `Z3_solver_propagate_consequence` function.
4236    /// The callback context can only be accessed (for propagation and for dynamically registering expressions) within a callback.
4237    /// If the callback context gets used for propagation or conflicts, those propagations take effect and
4238    /// may trigger new decision variables to be set.
4239    pub fn Z3_solver_propagate_final(c: Z3_context, s: Z3_solver, final_eh: Z3_final_eh);
4240    /// register a callback on expression equalities.
4241    pub fn Z3_solver_propagate_eq(c: Z3_context, s: Z3_solver, eq_eh: Z3_eq_eh);
4242    /// register a callback on expression dis-equalities.
4243    pub fn Z3_solver_propagate_diseq(c: Z3_context, s: Z3_solver, eq_eh: Z3_eq_eh);
4244    /// register a callback when a new expression with a registered function is used by the solver
4245    /// The registered function appears at the top level and is created using \ref Z3_solver_propagate_declare.
4246    pub fn Z3_solver_propagate_created(
4247        c: Z3_context,
4248        s: Z3_solver,
4249        created_eh: Z3_created_eh,
4250    );
4251    /// register a callback when the solver decides to split on a registered expression.
4252    /// The callback may change the arguments by providing other values by calling \ref Z3_solver_next_split
4253    pub fn Z3_solver_propagate_decide(
4254        c: Z3_context,
4255        s: Z3_solver,
4256        decide_eh: Z3_decide_eh,
4257    );
4258    /// register a callback when the solver instantiates a quantifier.
4259    /// If the callback returns false, the actual instantiation of the quantifier is blocked.
4260    /// This allows the user propagator selectively prioritize instantiations without relying on default
4261    /// or configured weights.
4262    pub fn Z3_solver_propagate_on_binding(
4263        c: Z3_context,
4264        s: Z3_solver,
4265        on_binding_eh: Z3_on_binding_eh,
4266    );
4267    /// Sets the next (registered) expression to split on.
4268    /// The function returns false and ignores the given expression in case the expression is already assigned internally
4269    /// (due to relevancy propagation, this assignments might not have been reported yet by the fixed callback).
4270    /// In case the function is called in the decide callback, it overrides the currently selected variable and phase.
4271    pub fn Z3_solver_next_split(
4272        c: Z3_context,
4273        cb: Z3_solver_callback,
4274        t: Z3_ast,
4275        idx: ::core::ffi::c_uint,
4276        phase: Z3_lbool,
4277    ) -> bool;
4278    /// Create uninterpreted function declaration for the user propagator.
4279    /// When expressions using the function are created by the solver invoke a callback
4280    /// to \ref Z3_solver_propagate_created with arguments
4281    /// 1. context and callback solve
4282    /// 2. declared_expr: expression using function that was used as the top-level symbol
4283    /// 3. declared_id: a unique identifier (unique within the current scope) to track the expression.
4284    pub fn Z3_solver_propagate_declare(
4285        c: Z3_context,
4286        name: Z3_symbol,
4287        n: ::core::ffi::c_uint,
4288        domain: *mut Z3_sort,
4289        range: Z3_sort,
4290    ) -> Option<Z3_func_decl>;
4291    /// register an expression to propagate on with the solver.
4292    /// Only expressions of type Bool and type Bit-Vector can be registered for propagation.
4293    pub fn Z3_solver_propagate_register(c: Z3_context, s: Z3_solver, e: Z3_ast);
4294    /// register an expression to propagate on with the solver.
4295    /// Only expressions of type Bool and type Bit-Vector can be registered for propagation.
4296    /// Unlike \ref Z3_solver_propagate_register, this function takes a solver callback context
4297    /// as argument. It can be invoked during a callback to register new expressions.
4298    pub fn Z3_solver_propagate_register_cb(
4299        c: Z3_context,
4300        cb: Z3_solver_callback,
4301        e: Z3_ast,
4302    );
4303    /// propagate a consequence based on fixed values and equalities.
4304    /// A client may invoke it during the `propagate_fixed`, `propagate_eq`, `propagate_diseq`, and `propagate_final` callbacks.
4305    /// The callback adds a propagation consequence based on the fixed values passed `ids` and equalities `eqs` based on parameters `lhs`, `rhs`.
4306    ///
4307    /// The solver might discard the propagation in case it is true in the current state.
4308    /// The function returns false in this case; otw. the function returns true.
4309    /// At least one propagation in the final callback has to return true in order to
4310    /// prevent the solver from finishing.
4311    ///
4312    /// Assume the callback has the signature: `propagate_consequence_eh`(context, solver_cb, num_ids, ids, num_eqs, lhs, rhs, consequence).
4313    /// - `c`: - context
4314    /// - `solver_cb`: - solver callback
4315    /// - `num_ids`: - number of fixed terms used as premise to propagation
4316    /// - `ids`: - array of length `num_ids` containing terms that are fixed in the current scope
4317    /// - `num_eqs`: - number of equalities used as premise to propagation
4318    /// - `lhs`: - left side of equalities
4319    /// - `rhs`: - right side of equalities
4320    /// - `consequence`: - consequence to propagate. It is typically an atomic formula, but it can be an arbitrary formula.
4321    pub fn Z3_solver_propagate_consequence(
4322        c: Z3_context,
4323        cb: Z3_solver_callback,
4324        num_fixed: ::core::ffi::c_uint,
4325        fixed: *const Z3_ast,
4326        num_eqs: ::core::ffi::c_uint,
4327        eq_lhs: *const Z3_ast,
4328        eq_rhs: *const Z3_ast,
4329        conseq: Z3_ast,
4330    ) -> bool;
4331    /// provide an initialization hint to the solver. The initialization hint is used to calibrate an initial value of the expression that
4332    /// represents a variable. If the variable is Boolean, the initial phase is set according to `value`. If the variable is an integer or real,
4333    /// the initial Simplex tableau is recalibrated to attempt to follow the value assignment.
4334    pub fn Z3_solver_set_initial_value(
4335        c: Z3_context,
4336        s: Z3_solver,
4337        v: Z3_ast,
4338        val: Z3_ast,
4339    );
4340    /// Check whether the assertions in a given solver are consistent or not.
4341    ///
4342    /// The function [`Z3_solver_get_model`] retrieves a model if the
4343    /// assertions is satisfiable (i.e., the result is `Z3_L_TRUE`) and model construction is enabled.
4344    /// Note that if the call returns `Z3_L_UNDEF`, Z3 does not
4345    /// ensure that calls to [`Z3_solver_get_model`] succeed and any models
4346    /// produced in this case are not guaranteed to satisfy the assertions.
4347    ///
4348    /// The function [`Z3_solver_get_proof`] retrieves a proof if proof
4349    /// generation was enabled when the context was created, and the
4350    /// assertions are unsatisfiable (i.e., the result is `Z3_L_FALSE`).
4351    ///
4352    /// # See also
4353    ///
4354    /// - [`Z3_solver_check_assumptions`]
4355    pub fn Z3_solver_check(c: Z3_context, s: Z3_solver) -> Z3_lbool;
4356    /// Check whether the assertions in the given solver and
4357    /// optional assumptions are consistent or not.
4358    ///
4359    /// The function [`Z3_solver_get_unsat_core`] retrieves the subset of the
4360    /// assumptions used in the unsatisfiability proof produced by Z3.
4361    ///
4362    /// # See also
4363    ///
4364    /// - [`Z3_solver_check`]
4365    pub fn Z3_solver_check_assumptions(
4366        c: Z3_context,
4367        s: Z3_solver,
4368        num_assumptions: ::core::ffi::c_uint,
4369        assumptions: *const Z3_ast,
4370    ) -> Z3_lbool;
4371    /// Retrieve congruence class representatives for terms.
4372    ///
4373    /// The function can be used for relying on Z3 to identify equal terms under the current
4374    /// set of assumptions. The array of terms and array of class identifiers should have
4375    /// the same length. The class identifiers are numerals that are assigned to the same
4376    /// value for their corresponding terms if the current context forces the terms to be
4377    /// equal. You cannot deduce that terms corresponding to different numerals must be all different,
4378    /// (especially when using non-convex theories).
4379    /// All implied equalities are returned by this call.
4380    /// This means that two terms map to the same class identifier if and only if
4381    /// the current context implies that they are equal.
4382    ///
4383    /// A side-effect of the function is a satisfiability check on the assertions on the solver that is passed in.
4384    /// The function return `Z3_L_FALSE` if the current assertions are not satisfiable.
4385    pub fn Z3_get_implied_equalities(
4386        c: Z3_context,
4387        s: Z3_solver,
4388        num_terms: ::core::ffi::c_uint,
4389        terms: *const Z3_ast,
4390        class_ids: *mut ::core::ffi::c_uint,
4391    ) -> Z3_lbool;
4392    /// retrieve consequences from solver that determine values of the supplied function symbols.
4393    pub fn Z3_solver_get_consequences(
4394        c: Z3_context,
4395        s: Z3_solver,
4396        assumptions: Z3_ast_vector,
4397        variables: Z3_ast_vector,
4398        consequences: Z3_ast_vector,
4399    ) -> Z3_lbool;
4400    /// extract a next cube for a solver. The last cube is the constant `true` or `false`.
4401    /// The number of (non-constant) cubes is by default 1. For the sat solver cubing is controlled
4402    /// using parameters sat.lookahead.cube.cutoff and sat.lookahead.cube.fraction.
4403    ///
4404    /// The third argument is a vector of variables that may be used for cubing.
4405    /// The contents of the vector is only used in the first call. The initial list of variables
4406    /// is used in subsequent calls until it returns the unsatisfiable cube.
4407    /// The vector is modified to contain a set of Autarky variables that occur in clauses that
4408    /// are affected by the (last literal in the) cube. These variables could be used by a different
4409    /// cuber (on a different solver object) for further recursive cubing.
4410    ///
4411    /// The last argument is a backtracking level. It instructs the cube process to backtrack below
4412    /// the indicated level for the next cube.
4413    pub fn Z3_solver_cube(
4414        c: Z3_context,
4415        s: Z3_solver,
4416        vars: Z3_ast_vector,
4417        backtrack_level: ::core::ffi::c_uint,
4418    ) -> Option<Z3_ast_vector>;
4419    /// Retrieve the model for the last [`Z3_solver_check`] or [`Z3_solver_check_assumptions`]
4420    ///
4421    /// The error handler is invoked if a model is not available because
4422    /// the commands above were not invoked for the given solver, or if the result was `Z3_L_FALSE`.
4423    pub fn Z3_solver_get_model(c: Z3_context, s: Z3_solver) -> Option<Z3_model>;
4424    /// Retrieve the proof for the last [`Z3_solver_check`] or [`Z3_solver_check_assumptions`]
4425    ///
4426    /// The error handler is invoked if proof generation is not enabled,
4427    /// or if the commands above were not invoked for the given solver,
4428    /// or if the result was different from `Z3_L_FALSE`.
4429    pub fn Z3_solver_get_proof(c: Z3_context, s: Z3_solver) -> Option<Z3_ast>;
4430    /// Retrieve the unsat core for the last [`Z3_solver_check_assumptions`]
4431    /// The unsat core is a subset of the assumptions `a`.
4432    ///
4433    /// By default, the unsat core will not be minimized. Generation of a minimized
4434    /// unsat core can be enabled via the `"sat.core.minimize"` and `"smt.core.minimize"`
4435    /// settings for SAT and SMT cores respectively. Generation of minimized unsat cores
4436    /// will be more expensive.
4437    pub fn Z3_solver_get_unsat_core(
4438        c: Z3_context,
4439        s: Z3_solver,
4440    ) -> Option<Z3_ast_vector>;
4441    /// Return a brief justification for an "unknown" result (i.e., `Z3_L_UNDEF`) for
4442    /// the commands [`Z3_solver_check`] and [`Z3_solver_check_assumptions`]
4443    pub fn Z3_solver_get_reason_unknown(c: Z3_context, s: Z3_solver) -> Z3_string;
4444    /// Return statistics for the given solver.
4445    ///
4446    /// **Remark:** User must use [`Z3_stats_inc_ref`] and [`Z3_stats_dec_ref`] to manage Z3_stats objects.
4447    pub fn Z3_solver_get_statistics(c: Z3_context, s: Z3_solver) -> Option<Z3_stats>;
4448    /// Convert a solver into a string.
4449    ///
4450    /// # See also
4451    ///
4452    /// - [`Z3_solver_from_file`]
4453    /// - [`Z3_solver_from_string`]
4454    pub fn Z3_solver_to_string(c: Z3_context, s: Z3_solver) -> Z3_string;
4455    /// Convert a solver into a DIMACS formatted string.
4456    ///
4457    /// # See also
4458    ///
4459    /// - [`Z3_goal_to_dimacs_string`]
4460    pub fn Z3_solver_to_dimacs_string(
4461        c: Z3_context,
4462        s: Z3_solver,
4463        include_names: bool,
4464    ) -> Z3_string;
4465    /// Convert a statistics into a string.
4466    pub fn Z3_stats_to_string(c: Z3_context, s: Z3_stats) -> Z3_string;
4467    /// Increment the reference counter of the given statistics object.
4468    pub fn Z3_stats_inc_ref(c: Z3_context, s: Z3_stats);
4469    /// Decrement the reference counter of the given statistics object.
4470    pub fn Z3_stats_dec_ref(c: Z3_context, s: Z3_stats);
4471    /// Return the number of statistical data in `s`.
4472    pub fn Z3_stats_size(c: Z3_context, s: Z3_stats) -> ::core::ffi::c_uint;
4473    /// Return the key (a string) for a particular statistical data.
4474    ///
4475    /// # Preconditions
4476    ///
4477    /// - `idx < Z3_stats_size(c, s)`
4478    pub fn Z3_stats_get_key(
4479        c: Z3_context,
4480        s: Z3_stats,
4481        idx: ::core::ffi::c_uint,
4482    ) -> Z3_string;
4483    /// Return `true` if the given statistical data is a unsigned integer.
4484    ///
4485    /// # Preconditions
4486    ///
4487    /// - `idx < Z3_stats_size(c, s)`
4488    pub fn Z3_stats_is_uint(
4489        c: Z3_context,
4490        s: Z3_stats,
4491        idx: ::core::ffi::c_uint,
4492    ) -> bool;
4493    /// Return `true` if the given statistical data is a double.
4494    ///
4495    /// # Preconditions
4496    ///
4497    /// - `idx < Z3_stats_size(c, s)`
4498    pub fn Z3_stats_is_double(
4499        c: Z3_context,
4500        s: Z3_stats,
4501        idx: ::core::ffi::c_uint,
4502    ) -> bool;
4503    /// Return the unsigned value of the given statistical data.
4504    ///
4505    /// # Preconditions
4506    ///
4507    /// - `idx < Z3_stats_size(c, s) && Z3_stats_is_uint(c, s)`
4508    pub fn Z3_stats_get_uint_value(
4509        c: Z3_context,
4510        s: Z3_stats,
4511        idx: ::core::ffi::c_uint,
4512    ) -> ::core::ffi::c_uint;
4513    /// Return the double value of the given statistical data.
4514    ///
4515    /// # Preconditions
4516    ///
4517    /// - `idx < Z3_stats_size(c, s) && Z3_stats_is_double(c, s)`
4518    pub fn Z3_stats_get_double_value(
4519        c: Z3_context,
4520        s: Z3_stats,
4521        idx: ::core::ffi::c_uint,
4522    ) -> f64;
4523    /// Return the estimated allocated memory in bytes.
4524    pub fn Z3_get_estimated_alloc_size() -> u64;
4525    /// Return an empty AST vector.
4526    ///
4527    /// **Remark:** Reference counting must be used to manage AST vectors, even when the Z3_context was
4528    /// created using [`Z3_mk_context`] instead of [`Z3_mk_context_rc`].
4529    pub fn Z3_mk_ast_vector(c: Z3_context) -> Option<Z3_ast_vector>;
4530    /// Increment the reference counter of the given AST vector.
4531    pub fn Z3_ast_vector_inc_ref(c: Z3_context, v: Z3_ast_vector);
4532    /// Decrement the reference counter of the given AST vector.
4533    pub fn Z3_ast_vector_dec_ref(c: Z3_context, v: Z3_ast_vector);
4534    /// Return the size of the given AST vector.
4535    pub fn Z3_ast_vector_size(c: Z3_context, v: Z3_ast_vector) -> ::core::ffi::c_uint;
4536    /// Return the AST at position `i` in the AST vector `v`.
4537    ///
4538    /// # Preconditions
4539    ///
4540    /// - `i < Z3_ast_vector_size(c, v)`
4541    pub fn Z3_ast_vector_get(
4542        c: Z3_context,
4543        v: Z3_ast_vector,
4544        i: ::core::ffi::c_uint,
4545    ) -> Option<Z3_ast>;
4546    /// Update position `i` of the AST vector `v` with the AST `a`.
4547    ///
4548    /// # Preconditions
4549    ///
4550    /// - `i < Z3_ast_vector_size(c, v)`
4551    pub fn Z3_ast_vector_set(
4552        c: Z3_context,
4553        v: Z3_ast_vector,
4554        i: ::core::ffi::c_uint,
4555        a: Z3_ast,
4556    );
4557    /// Resize the AST vector `v`.
4558    pub fn Z3_ast_vector_resize(c: Z3_context, v: Z3_ast_vector, n: ::core::ffi::c_uint);
4559    /// Add the AST `a` in the end of the AST vector `v`. The size of `v` is increased by one.
4560    pub fn Z3_ast_vector_push(c: Z3_context, v: Z3_ast_vector, a: Z3_ast);
4561    /// Translate the AST vector `v` from context `s` into an AST vector in context `t`.
4562    pub fn Z3_ast_vector_translate(
4563        s: Z3_context,
4564        v: Z3_ast_vector,
4565        t: Z3_context,
4566    ) -> Option<Z3_ast_vector>;
4567    /// Convert AST vector into a string.
4568    pub fn Z3_ast_vector_to_string(c: Z3_context, v: Z3_ast_vector) -> Z3_string;
4569    /// Return an empty mapping from AST to AST
4570    ///
4571    /// **Remark:** Reference counting must be used to manage AST maps, even when the Z3_context was
4572    /// created using [`Z3_mk_context`] instead of [`Z3_mk_context_rc`].
4573    pub fn Z3_mk_ast_map(c: Z3_context) -> Option<Z3_ast_map>;
4574    /// Increment the reference counter of the given AST map.
4575    pub fn Z3_ast_map_inc_ref(c: Z3_context, m: Z3_ast_map);
4576    /// Decrement the reference counter of the given AST map.
4577    pub fn Z3_ast_map_dec_ref(c: Z3_context, m: Z3_ast_map);
4578    /// Return true if the map `m` contains the AST key `k`.
4579    pub fn Z3_ast_map_contains(c: Z3_context, m: Z3_ast_map, k: Z3_ast) -> bool;
4580    /// Return the value associated with the key `k`.
4581    ///
4582    /// The procedure invokes the error handler if `k` is not in the map.
4583    pub fn Z3_ast_map_find(c: Z3_context, m: Z3_ast_map, k: Z3_ast) -> Option<Z3_ast>;
4584    /// Store/Replace a new key, value pair in the given map.
4585    pub fn Z3_ast_map_insert(c: Z3_context, m: Z3_ast_map, k: Z3_ast, v: Z3_ast);
4586    /// Erase a key from the map.
4587    pub fn Z3_ast_map_erase(c: Z3_context, m: Z3_ast_map, k: Z3_ast);
4588    /// Remove all keys from the given map.
4589    pub fn Z3_ast_map_reset(c: Z3_context, m: Z3_ast_map);
4590    /// Return the size of the given map.
4591    pub fn Z3_ast_map_size(c: Z3_context, m: Z3_ast_map) -> ::core::ffi::c_uint;
4592    /// Return the keys stored in the given map.
4593    pub fn Z3_ast_map_keys(c: Z3_context, m: Z3_ast_map) -> Option<Z3_ast_vector>;
4594    /// Convert the given map into a string.
4595    pub fn Z3_ast_map_to_string(c: Z3_context, m: Z3_ast_map) -> Z3_string;
4596    /// Return `true` if `a` can be used as value in the Z3 real algebraic
4597    /// number package.
4598    pub fn Z3_algebraic_is_value(c: Z3_context, a: Z3_ast) -> bool;
4599    /// Return `true` if `a` is positive, and `false` otherwise.
4600    ///
4601    /// # Preconditions
4602    ///
4603    /// - `Z3_algebraic_is_value(c, a)`
4604    pub fn Z3_algebraic_is_pos(c: Z3_context, a: Z3_ast) -> bool;
4605    /// Return `true` if `a` is negative, and `false` otherwise.
4606    ///
4607    /// # Preconditions
4608    ///
4609    /// - `Z3_algebraic_is_value(c, a)`
4610    pub fn Z3_algebraic_is_neg(c: Z3_context, a: Z3_ast) -> bool;
4611    /// Return `true` if `a` is zero, and `false` otherwise.
4612    ///
4613    /// # Preconditions
4614    ///
4615    /// - `Z3_algebraic_is_value(c, a)`
4616    pub fn Z3_algebraic_is_zero(c: Z3_context, a: Z3_ast) -> bool;
4617    /// Return 1 if `a` is positive, 0 if `a` is zero, and -1 if `a` is negative.
4618    ///
4619    /// # Preconditions
4620    ///
4621    /// - `Z3_algebraic_is_value(c, a)`
4622    pub fn Z3_algebraic_sign(c: Z3_context, a: Z3_ast) -> ::core::ffi::c_int;
4623    /// Return the value a + b.
4624    ///
4625    /// \post Z3_algebraic_is_value(c, result)
4626    ///
4627    /// # Preconditions
4628    ///
4629    /// - `Z3_algebraic_is_value(c, a)`
4630    /// - `Z3_algebraic_is_value(c, b)`
4631    pub fn Z3_algebraic_add(c: Z3_context, a: Z3_ast, b: Z3_ast) -> Option<Z3_ast>;
4632    /// Return the value a - b.
4633    ///
4634    /// \post Z3_algebraic_is_value(c, result)
4635    ///
4636    /// # Preconditions
4637    ///
4638    /// - `Z3_algebraic_is_value(c, a)`
4639    /// - `Z3_algebraic_is_value(c, b)`
4640    pub fn Z3_algebraic_sub(c: Z3_context, a: Z3_ast, b: Z3_ast) -> Option<Z3_ast>;
4641    /// Return the value a * b.
4642    ///
4643    /// \post Z3_algebraic_is_value(c, result)
4644    ///
4645    /// # Preconditions
4646    ///
4647    /// - `Z3_algebraic_is_value(c, a)`
4648    /// - `Z3_algebraic_is_value(c, b)`
4649    pub fn Z3_algebraic_mul(c: Z3_context, a: Z3_ast, b: Z3_ast) -> Option<Z3_ast>;
4650    /// Return the value a / b.
4651    ///
4652    /// \post Z3_algebraic_is_value(c, result)
4653    ///
4654    /// # Preconditions
4655    ///
4656    /// - `Z3_algebraic_is_value(c, a)`
4657    /// - `Z3_algebraic_is_value(c, b)`
4658    /// - `!Z3_algebraic_is_zero(c, b)`
4659    pub fn Z3_algebraic_div(c: Z3_context, a: Z3_ast, b: Z3_ast) -> Option<Z3_ast>;
4660    /// Return the a^(1/k)
4661    ///
4662    /// \post Z3_algebraic_is_value(c, result)
4663    ///
4664    /// # Preconditions
4665    ///
4666    /// - `Z3_algebraic_is_value(c, a)`
4667    /// - `k is even => !Z3_algebraic_is_neg(c, a)`
4668    pub fn Z3_algebraic_root(
4669        c: Z3_context,
4670        a: Z3_ast,
4671        k: ::core::ffi::c_uint,
4672    ) -> Option<Z3_ast>;
4673    /// Return the a^k
4674    ///
4675    /// \post Z3_algebraic_is_value(c, result)
4676    ///
4677    /// # Preconditions
4678    ///
4679    /// - `Z3_algebraic_is_value(c, a)`
4680    pub fn Z3_algebraic_power(
4681        c: Z3_context,
4682        a: Z3_ast,
4683        k: ::core::ffi::c_uint,
4684    ) -> Option<Z3_ast>;
4685    /// Return `true` if a < b, and `false` otherwise.
4686    ///
4687    /// # Preconditions
4688    ///
4689    /// - `Z3_algebraic_is_value(c, a)`
4690    /// - `Z3_algebraic_is_value(c, b)`
4691    pub fn Z3_algebraic_lt(c: Z3_context, a: Z3_ast, b: Z3_ast) -> bool;
4692    /// Return `true` if a > b, and `false` otherwise.
4693    ///
4694    /// # Preconditions
4695    ///
4696    /// - `Z3_algebraic_is_value(c, a)`
4697    /// - `Z3_algebraic_is_value(c, b)`
4698    pub fn Z3_algebraic_gt(c: Z3_context, a: Z3_ast, b: Z3_ast) -> bool;
4699    /// Return `true` if a <= b, and `false` otherwise.
4700    ///
4701    /// # Preconditions
4702    ///
4703    /// - `Z3_algebraic_is_value(c, a)`
4704    /// - `Z3_algebraic_is_value(c, b)`
4705    pub fn Z3_algebraic_le(c: Z3_context, a: Z3_ast, b: Z3_ast) -> bool;
4706    /// Return `true` if a >= b, and `false` otherwise.
4707    ///
4708    /// # Preconditions
4709    ///
4710    /// - `Z3_algebraic_is_value(c, a)`
4711    /// - `Z3_algebraic_is_value(c, b)`
4712    pub fn Z3_algebraic_ge(c: Z3_context, a: Z3_ast, b: Z3_ast) -> bool;
4713    /// Return `true` if a == b, and `false` otherwise.
4714    ///
4715    /// # Preconditions
4716    ///
4717    /// - `Z3_algebraic_is_value(c, a)`
4718    /// - `Z3_algebraic_is_value(c, b)`
4719    pub fn Z3_algebraic_eq(c: Z3_context, a: Z3_ast, b: Z3_ast) -> bool;
4720    /// Return `true` if a != b, and `false` otherwise.
4721    ///
4722    /// # Preconditions
4723    ///
4724    /// - `Z3_algebraic_is_value(c, a)`
4725    /// - `Z3_algebraic_is_value(c, b)`
4726    pub fn Z3_algebraic_neq(c: Z3_context, a: Z3_ast, b: Z3_ast) -> bool;
4727    /// Given a multivariate polynomial p(x_0, ..., x_{n-1}, x_n), returns the
4728    /// roots of the univariate polynomial p(a\[0], ..., a\[n-1], x_n).
4729    ///
4730    /// \post forall r in result Z3_algebraic_is_value(c, result)
4731    ///
4732    /// # Preconditions
4733    ///
4734    /// - `p is a Z3 expression that contains only arithmetic terms and free variables.`
4735    /// - `forall i in [0, n) Z3_algebraic_is_value(c, a\[i])`
4736    pub fn Z3_algebraic_roots(
4737        c: Z3_context,
4738        p: Z3_ast,
4739        n: ::core::ffi::c_uint,
4740        a: *mut Z3_ast,
4741    ) -> Option<Z3_ast_vector>;
4742    /// Given a multivariate polynomial p(x_0, ..., x_{n-1}), return the
4743    /// sign of p(a\[0], ..., a\[n-1]).
4744    ///
4745    /// # Preconditions
4746    ///
4747    /// - `p is a Z3 expression that contains only arithmetic terms and free variables.`
4748    /// - `forall i in [0, n) Z3_algebraic_is_value(c, a\[i])`
4749    pub fn Z3_algebraic_eval(
4750        c: Z3_context,
4751        p: Z3_ast,
4752        n: ::core::ffi::c_uint,
4753        a: *mut Z3_ast,
4754    ) -> ::core::ffi::c_int;
4755    /// Return the coefficients of the defining polynomial.
4756    ///
4757    /// # Preconditions
4758    ///
4759    /// - `Z3_algebraic_is_value(c, a)`
4760    pub fn Z3_algebraic_get_poly(c: Z3_context, a: Z3_ast) -> Option<Z3_ast_vector>;
4761    /// Return which root of the polynomial the algebraic number represents.
4762    ///
4763    /// # Preconditions
4764    ///
4765    /// - `Z3_algebraic_is_value(c, a)`
4766    pub fn Z3_algebraic_get_i(c: Z3_context, a: Z3_ast) -> ::core::ffi::c_uint;
4767    /// Return the nonzero subresultants of `p` and `q` with respect to the "variable" `x`.
4768    ///
4769    /// Note that, any subterm that cannot be viewed as a polynomial is assumed to be a variable.
4770    /// Example: `f(a)` is a considered to be a variable in the polynomial \ccode{
4771    /// f(a)*f(a) + 2*f(a) + 1}
4772    ///
4773    /// # Preconditions
4774    ///
4775    /// - ``p`, `q` and `x` are Z3 expressions where `p` and `q` are arithmetic terms.`
4776    pub fn Z3_polynomial_subresultants(
4777        c: Z3_context,
4778        p: Z3_ast,
4779        q: Z3_ast,
4780        x: Z3_ast,
4781    ) -> Option<Z3_ast_vector>;
4782    /// Delete a RCF numeral created using the RCF API.
4783    pub fn Z3_rcf_del(c: Z3_context, a: Z3_rcf_num);
4784    /// Return a RCF rational using the given string.
4785    pub fn Z3_rcf_mk_rational(c: Z3_context, val: Z3_string) -> Option<Z3_rcf_num>;
4786    /// Return a RCF small integer.
4787    pub fn Z3_rcf_mk_small_int(
4788        c: Z3_context,
4789        val: ::core::ffi::c_int,
4790    ) -> Option<Z3_rcf_num>;
4791    /// Return Pi
4792    pub fn Z3_rcf_mk_pi(c: Z3_context) -> Option<Z3_rcf_num>;
4793    /// Return e (Euler's constant)
4794    pub fn Z3_rcf_mk_e(c: Z3_context) -> Option<Z3_rcf_num>;
4795    /// Return a new infinitesimal that is smaller than all elements in the Z3 field.
4796    pub fn Z3_rcf_mk_infinitesimal(c: Z3_context) -> Option<Z3_rcf_num>;
4797    /// Store in roots the roots of the polynomial `a[n-1]*x^{n-1` + ... + a\[0]}.
4798    /// The output vector `roots` must have size `n`.
4799    /// It returns the number of roots of the polynomial.
4800    ///
4801    /// # Preconditions
4802    ///
4803    /// - `The input polynomial is not the zero polynomial.`
4804    pub fn Z3_rcf_mk_roots(
4805        c: Z3_context,
4806        n: ::core::ffi::c_uint,
4807        a: *const Z3_rcf_num,
4808        roots: *mut Z3_rcf_num,
4809    ) -> ::core::ffi::c_uint;
4810    /// Return the value `a + b`.
4811    pub fn Z3_rcf_add(c: Z3_context, a: Z3_rcf_num, b: Z3_rcf_num) -> Option<Z3_rcf_num>;
4812    /// Return the value `a - b`.
4813    pub fn Z3_rcf_sub(c: Z3_context, a: Z3_rcf_num, b: Z3_rcf_num) -> Option<Z3_rcf_num>;
4814    /// Return the value `a * b`.
4815    pub fn Z3_rcf_mul(c: Z3_context, a: Z3_rcf_num, b: Z3_rcf_num) -> Option<Z3_rcf_num>;
4816    /// Return the value `a / b`.
4817    pub fn Z3_rcf_div(c: Z3_context, a: Z3_rcf_num, b: Z3_rcf_num) -> Option<Z3_rcf_num>;
4818    /// Return the value `-a`.
4819    pub fn Z3_rcf_neg(c: Z3_context, a: Z3_rcf_num) -> Option<Z3_rcf_num>;
4820    /// Return the value `1/a`.
4821    pub fn Z3_rcf_inv(c: Z3_context, a: Z3_rcf_num) -> Option<Z3_rcf_num>;
4822    /// Return the value `a^k`.
4823    pub fn Z3_rcf_power(
4824        c: Z3_context,
4825        a: Z3_rcf_num,
4826        k: ::core::ffi::c_uint,
4827    ) -> Option<Z3_rcf_num>;
4828    /// Return `true` if `a < b`.
4829    pub fn Z3_rcf_lt(c: Z3_context, a: Z3_rcf_num, b: Z3_rcf_num) -> bool;
4830    /// Return `true` if `a > b`.
4831    pub fn Z3_rcf_gt(c: Z3_context, a: Z3_rcf_num, b: Z3_rcf_num) -> bool;
4832    /// Return `true` if `a <= b`.
4833    pub fn Z3_rcf_le(c: Z3_context, a: Z3_rcf_num, b: Z3_rcf_num) -> bool;
4834    /// Return `true` if `a >= b`.
4835    pub fn Z3_rcf_ge(c: Z3_context, a: Z3_rcf_num, b: Z3_rcf_num) -> bool;
4836    /// Return `true` if `a == b`.
4837    pub fn Z3_rcf_eq(c: Z3_context, a: Z3_rcf_num, b: Z3_rcf_num) -> bool;
4838    /// Return `true` if `a != b`.
4839    pub fn Z3_rcf_neq(c: Z3_context, a: Z3_rcf_num, b: Z3_rcf_num) -> bool;
4840    /// Convert the RCF numeral into a string.
4841    pub fn Z3_rcf_num_to_string(
4842        c: Z3_context,
4843        a: Z3_rcf_num,
4844        compact: bool,
4845        html: bool,
4846    ) -> Z3_string;
4847    /// Convert the RCF numeral into a string in decimal notation.
4848    pub fn Z3_rcf_num_to_decimal_string(
4849        c: Z3_context,
4850        a: Z3_rcf_num,
4851        prec: ::core::ffi::c_uint,
4852    ) -> Z3_string;
4853    /// Extract the "numerator" and "denominator" of the given RCF numeral.
4854    /// We have that `a = n/d`, moreover `n` and `d` are not represented using rational functions.
4855    pub fn Z3_rcf_get_numerator_denominator(
4856        c: Z3_context,
4857        a: Z3_rcf_num,
4858        n: *mut Z3_rcf_num,
4859        d: *mut Z3_rcf_num,
4860    );
4861    /// Return `true` if `a` represents a rational number.
4862    pub fn Z3_rcf_is_rational(c: Z3_context, a: Z3_rcf_num) -> bool;
4863    /// Return `true` if `a` represents an algebraic number.
4864    pub fn Z3_rcf_is_algebraic(c: Z3_context, a: Z3_rcf_num) -> bool;
4865    /// Return `true` if `a` represents an infinitesimal.
4866    pub fn Z3_rcf_is_infinitesimal(c: Z3_context, a: Z3_rcf_num) -> bool;
4867    /// Return `true` if `a` represents a transcendental number.
4868    pub fn Z3_rcf_is_transcendental(c: Z3_context, a: Z3_rcf_num) -> bool;
4869    /// Return the index of a field extension.
4870    pub fn Z3_rcf_extension_index(c: Z3_context, a: Z3_rcf_num) -> ::core::ffi::c_uint;
4871    /// Return the name of a transcendental.
4872    ///
4873    /// # Preconditions
4874    ///
4875    /// - `Z3_rcf_is_transcendtal(ctx, a);`
4876    pub fn Z3_rcf_transcendental_name(c: Z3_context, a: Z3_rcf_num) -> Option<Z3_symbol>;
4877    /// Return the name of an infinitesimal.
4878    ///
4879    /// # Preconditions
4880    ///
4881    /// - `Z3_rcf_is_infinitesimal(ctx, a);`
4882    pub fn Z3_rcf_infinitesimal_name(c: Z3_context, a: Z3_rcf_num) -> Option<Z3_symbol>;
4883    /// Return the number of coefficients in an algebraic number.
4884    ///
4885    /// # Preconditions
4886    ///
4887    /// - `Z3_rcf_is_algebraic(ctx, a);`
4888    pub fn Z3_rcf_num_coefficients(c: Z3_context, a: Z3_rcf_num) -> ::core::ffi::c_uint;
4889    /// Extract a coefficient from an algebraic number.
4890    ///
4891    /// # Preconditions
4892    ///
4893    /// - `Z3_rcf_is_algebraic(ctx, a);`
4894    pub fn Z3_rcf_coefficient(
4895        c: Z3_context,
4896        a: Z3_rcf_num,
4897        i: ::core::ffi::c_uint,
4898    ) -> Option<Z3_rcf_num>;
4899    /// Extract an interval from an algebraic number.
4900    ///
4901    /// # Preconditions
4902    ///
4903    /// - `Z3_rcf_is_algebraic(ctx, a);`
4904    pub fn Z3_rcf_interval(
4905        c: Z3_context,
4906        a: Z3_rcf_num,
4907        lower_is_inf: *mut bool,
4908        lower_is_open: *mut bool,
4909        lower: *mut Z3_rcf_num,
4910        upper_is_inf: *mut bool,
4911        upper_is_open: *mut bool,
4912        upper: *mut Z3_rcf_num,
4913    ) -> ::core::ffi::c_int;
4914    /// Return the number of sign conditions of an algebraic number.
4915    ///
4916    /// # Preconditions
4917    ///
4918    /// - `Z3_rcf_is_algebraic(ctx, a);`
4919    pub fn Z3_rcf_num_sign_conditions(
4920        c: Z3_context,
4921        a: Z3_rcf_num,
4922    ) -> ::core::ffi::c_uint;
4923    /// Extract the sign of a sign condition from an algebraic number.
4924    ///
4925    /// # Preconditions
4926    ///
4927    /// - `Z3_rcf_is_algebraic(ctx, a);`
4928    pub fn Z3_rcf_sign_condition_sign(
4929        c: Z3_context,
4930        a: Z3_rcf_num,
4931        i: ::core::ffi::c_uint,
4932    ) -> ::core::ffi::c_int;
4933    /// Return the number of sign condition polynomial coefficients of an algebraic number.
4934    ///
4935    /// # Preconditions
4936    ///
4937    /// - `Z3_rcf_is_algebraic(ctx, a);`
4938    pub fn Z3_rcf_num_sign_condition_coefficients(
4939        c: Z3_context,
4940        a: Z3_rcf_num,
4941        i: ::core::ffi::c_uint,
4942    ) -> ::core::ffi::c_uint;
4943    /// Extract the j-th polynomial coefficient of the i-th sign condition.
4944    ///
4945    /// # Preconditions
4946    ///
4947    /// - `Z3_rcf_is_algebraic(ctx, a);`
4948    pub fn Z3_rcf_sign_condition_coefficient(
4949        c: Z3_context,
4950        a: Z3_rcf_num,
4951        i: ::core::ffi::c_uint,
4952        j: ::core::ffi::c_uint,
4953    ) -> Option<Z3_rcf_num>;
4954    /// Create a new fixedpoint context.
4955    ///
4956    /// **Remark:** User must use [`Z3_fixedpoint_inc_ref`] and [`Z3_fixedpoint_dec_ref`] to manage fixedpoint objects.
4957    /// Even if the context was created using [`Z3_mk_context`] instead of [`Z3_mk_context_rc`].
4958    pub fn Z3_mk_fixedpoint(c: Z3_context) -> Option<Z3_fixedpoint>;
4959    /// Increment the reference counter of the given fixedpoint context
4960    pub fn Z3_fixedpoint_inc_ref(c: Z3_context, d: Z3_fixedpoint);
4961    /// Decrement the reference counter of the given fixedpoint context.
4962    pub fn Z3_fixedpoint_dec_ref(c: Z3_context, d: Z3_fixedpoint);
4963    /// Add a Database fact.
4964    ///
4965    /// - `c`: - context
4966    /// - `d`: - fixed point context
4967    /// - `r`: - relation signature for the row.
4968    /// - `num_args`: - number of columns for the given row.
4969    /// - `args`: - array of the row elements.
4970    ///
4971    /// The number of arguments `num_args` should be equal to the number
4972    /// of sorts in the domain of `r`. Each sort in the domain should be an integral
4973    /// (bit-vector, Boolean or or finite domain sort).
4974    ///
4975    /// The call has the same effect as adding a rule where `r` is applied to the arguments.
4976    pub fn Z3_fixedpoint_add_fact(
4977        c: Z3_context,
4978        d: Z3_fixedpoint,
4979        r: Z3_func_decl,
4980        num_args: ::core::ffi::c_uint,
4981        args: *mut ::core::ffi::c_uint,
4982    );
4983    /// Assert a constraint to the fixedpoint context.
4984    ///
4985    /// The constraints are used as background axioms when the fixedpoint engine uses the PDR mode.
4986    /// They are ignored for standard Datalog mode.
4987    pub fn Z3_fixedpoint_assert(c: Z3_context, d: Z3_fixedpoint, axiom: Z3_ast);
4988    /// Pose a query against the asserted rules.
4989    ///
4990    /// ```c
4991    /// query ::= (exists (bound-vars) query)
4992    /// |  literals
4993    /// ```
4994    ///
4995    /// query returns
4996    /// - `Z3_L_FALSE` if the query is unsatisfiable.
4997    /// - `Z3_L_TRUE` if the query is satisfiable. Obtain the answer by calling [`Z3_fixedpoint_get_answer`].
4998    /// - `Z3_L_UNDEF` if the query was interrupted, timed out or otherwise failed.
4999    pub fn Z3_fixedpoint_query(
5000        c: Z3_context,
5001        d: Z3_fixedpoint,
5002        query: Z3_ast,
5003    ) -> Z3_lbool;
5004    /// Pose multiple queries against the asserted rules.
5005    ///
5006    /// The queries are encoded as relations (function declarations).
5007    ///
5008    /// query returns
5009    /// - `Z3_L_FALSE` if the query is unsatisfiable.
5010    /// - `Z3_L_TRUE` if the query is satisfiable. Obtain the answer by calling [`Z3_fixedpoint_get_answer`].
5011    /// - `Z3_L_UNDEF` if the query was interrupted, timed out or otherwise failed.
5012    pub fn Z3_fixedpoint_query_relations(
5013        c: Z3_context,
5014        d: Z3_fixedpoint,
5015        num_relations: ::core::ffi::c_uint,
5016        relations: *const Z3_func_decl,
5017    ) -> Z3_lbool;
5018    /// Retrieve a formula that encodes satisfying answers to the query.
5019    ///
5020    ///
5021    /// When used in Datalog mode, the returned answer is a disjunction of conjuncts.
5022    /// Each conjunct encodes values of the bound variables of the query that are satisfied.
5023    /// In PDR mode, the returned answer is a single conjunction.
5024    ///
5025    /// When used in Datalog mode the previous call to [`Z3_fixedpoint_query`] must have returned `Z3_L_TRUE`.
5026    /// When used with the PDR engine, the previous call must have been either `Z3_L_TRUE` or `Z3_L_FALSE`.
5027    pub fn Z3_fixedpoint_get_answer(c: Z3_context, d: Z3_fixedpoint) -> Option<Z3_ast>;
5028    /// Retrieve a string that describes the last status returned by [`Z3_fixedpoint_query`].
5029    ///
5030    /// Use this method when [`Z3_fixedpoint_query`] returns `Z3_L_UNDEF`.
5031    pub fn Z3_fixedpoint_get_reason_unknown(
5032        c: Z3_context,
5033        d: Z3_fixedpoint,
5034    ) -> Z3_string;
5035    /// Update a named rule.
5036    /// A rule with the same name must have been previously created.
5037    pub fn Z3_fixedpoint_update_rule(
5038        c: Z3_context,
5039        d: Z3_fixedpoint,
5040        a: Z3_ast,
5041        name: Z3_symbol,
5042    );
5043    /// Query the PDR engine for the maximal levels properties are known about predicate.
5044    ///
5045    /// This call retrieves the maximal number of relevant unfoldings
5046    /// of `pred` with respect to the current exploration state.
5047    /// Note: this functionality is PDR specific.
5048    pub fn Z3_fixedpoint_get_num_levels(
5049        c: Z3_context,
5050        d: Z3_fixedpoint,
5051        pred: Z3_func_decl,
5052    ) -> ::core::ffi::c_uint;
5053    /// Retrieve the current cover of `pred` up to `level` unfoldings.
5054    /// Return just the delta that is known at `level`. To
5055    /// obtain the full set of properties of `pred` one should query
5056    /// at `level`+1 , `level`+2 etc, and include `level`=-1.
5057    ///
5058    /// Note: this functionality is PDR specific.
5059    pub fn Z3_fixedpoint_get_cover_delta(
5060        c: Z3_context,
5061        d: Z3_fixedpoint,
5062        level: ::core::ffi::c_int,
5063        pred: Z3_func_decl,
5064    ) -> Option<Z3_ast>;
5065    /// Add property about the predicate `pred`.
5066    /// Add a property of predicate `pred` at `level`.
5067    /// It gets pushed forward when possible.
5068    ///
5069    /// Note: level = -1 is treated as the fixedpoint. So passing -1 for the `level`
5070    /// means that the property is true of the fixed-point unfolding with respect to `pred`.
5071    ///
5072    /// Note: this functionality is PDR specific.
5073    pub fn Z3_fixedpoint_add_cover(
5074        c: Z3_context,
5075        d: Z3_fixedpoint,
5076        level: ::core::ffi::c_int,
5077        pred: Z3_func_decl,
5078        property: Z3_ast,
5079    );
5080    /// Retrieve statistics information from the last call to [`Z3_fixedpoint_query`].
5081    pub fn Z3_fixedpoint_get_statistics(
5082        c: Z3_context,
5083        d: Z3_fixedpoint,
5084    ) -> Option<Z3_stats>;
5085    /// Register relation as Fixedpoint defined.
5086    /// Fixedpoint defined relations have least-fixedpoint semantics.
5087    /// For example, the relation is empty if it does not occur
5088    /// in a head or a fact.
5089    pub fn Z3_fixedpoint_register_relation(
5090        c: Z3_context,
5091        d: Z3_fixedpoint,
5092        f: Z3_func_decl,
5093    );
5094    /// Configure the predicate representation.
5095    ///
5096    /// It sets the predicate to use a set of domains given by the list of symbols.
5097    /// The domains given by the list of symbols must belong to a set
5098    /// of built-in domains.
5099    pub fn Z3_fixedpoint_set_predicate_representation(
5100        c: Z3_context,
5101        d: Z3_fixedpoint,
5102        f: Z3_func_decl,
5103        num_relations: ::core::ffi::c_uint,
5104        relation_kinds: *const Z3_symbol,
5105    );
5106    /// Retrieve set of rules from fixedpoint context.
5107    pub fn Z3_fixedpoint_get_rules(
5108        c: Z3_context,
5109        f: Z3_fixedpoint,
5110    ) -> Option<Z3_ast_vector>;
5111    /// Retrieve set of background assertions from fixedpoint context.
5112    pub fn Z3_fixedpoint_get_assertions(
5113        c: Z3_context,
5114        f: Z3_fixedpoint,
5115    ) -> Option<Z3_ast_vector>;
5116    /// Set parameters on fixedpoint context.
5117    ///
5118    /// # See also
5119    ///
5120    /// - [`Z3_fixedpoint_get_help`]
5121    /// - [`Z3_fixedpoint_get_param_descrs`]
5122    pub fn Z3_fixedpoint_set_params(c: Z3_context, f: Z3_fixedpoint, p: Z3_params);
5123    /// Return a string describing all fixedpoint available parameters.
5124    ///
5125    /// # See also
5126    ///
5127    /// - [`Z3_fixedpoint_get_param_descrs`]
5128    /// - [`Z3_fixedpoint_set_params`]
5129    pub fn Z3_fixedpoint_get_help(c: Z3_context, f: Z3_fixedpoint) -> Z3_string;
5130    /// Return the parameter description set for the given fixedpoint object.
5131    ///
5132    /// # See also
5133    ///
5134    /// - [`Z3_fixedpoint_get_help`]
5135    /// - [`Z3_fixedpoint_set_params`]
5136    pub fn Z3_fixedpoint_get_param_descrs(
5137        c: Z3_context,
5138        f: Z3_fixedpoint,
5139    ) -> Option<Z3_param_descrs>;
5140    /// Print the current rules and background axioms as a string.
5141    /// - `c`: - context.
5142    /// - `f`: - fixedpoint context.
5143    /// - `num_queries`: - number of additional queries to print.
5144    /// - `queries`: - additional queries.
5145    ///
5146    /// # See also
5147    ///
5148    /// - [`Z3_fixedpoint_from_file`]
5149    /// - [`Z3_fixedpoint_from_string`]
5150    pub fn Z3_fixedpoint_to_string(
5151        c: Z3_context,
5152        f: Z3_fixedpoint,
5153        num_queries: ::core::ffi::c_uint,
5154        queries: *mut Z3_ast,
5155    ) -> Z3_string;
5156    /// Parse an SMT-LIB2 string with fixedpoint rules.
5157    /// Add the rules to the current fixedpoint context.
5158    /// Return the set of queries in the string.
5159    ///
5160    /// - `c`: - context.
5161    /// - `f`: - fixedpoint context.
5162    /// - `s`: - string containing SMT2 specification.
5163    ///
5164    /// # See also
5165    ///
5166    /// - [`Z3_fixedpoint_from_file`]
5167    /// - [`Z3_fixedpoint_to_string`]
5168    pub fn Z3_fixedpoint_from_string(
5169        c: Z3_context,
5170        f: Z3_fixedpoint,
5171        s: Z3_string,
5172    ) -> Option<Z3_ast_vector>;
5173    /// Parse an SMT-LIB2 file with fixedpoint rules.
5174    /// Add the rules to the current fixedpoint context.
5175    /// Return the set of queries in the file.
5176    ///
5177    /// - `c`: - context.
5178    /// - `f`: - fixedpoint context.
5179    /// - `s`: - path to file containing SMT2 specification.
5180    ///
5181    /// # See also
5182    ///
5183    /// - [`Z3_fixedpoint_from_string`]
5184    /// - [`Z3_fixedpoint_to_string`]
5185    pub fn Z3_fixedpoint_from_file(
5186        c: Z3_context,
5187        f: Z3_fixedpoint,
5188        s: Z3_string,
5189    ) -> Option<Z3_ast_vector>;
5190    /// Initialize the context with a user-defined state.
5191    pub fn Z3_fixedpoint_init(
5192        c: Z3_context,
5193        d: Z3_fixedpoint,
5194        state: *mut ::core::ffi::c_void,
5195    );
5196    /// Register a callback to destructive updates.
5197    ///
5198    /// Registers are identified with terms encoded as fresh constants,
5199    pub fn Z3_fixedpoint_set_reduce_assign_callback(
5200        c: Z3_context,
5201        d: Z3_fixedpoint,
5202        cb: Z3_fixedpoint_reduce_assign_callback_fptr,
5203    );
5204    /// Register a callback for building terms based on the relational operators.
5205    pub fn Z3_fixedpoint_set_reduce_app_callback(
5206        c: Z3_context,
5207        d: Z3_fixedpoint,
5208        cb: Z3_fixedpoint_reduce_app_callback_fptr,
5209    );
5210    /// set export callback for lemmas
5211    pub fn Z3_fixedpoint_add_callback(
5212        ctx: Z3_context,
5213        f: Z3_fixedpoint,
5214        state: *mut ::core::ffi::c_void,
5215        new_lemma_eh: Z3_fixedpoint_new_lemma_eh,
5216        predecessor_eh: Z3_fixedpoint_predecessor_eh,
5217        unfold_eh: Z3_fixedpoint_unfold_eh,
5218    );
5219    pub fn Z3_fixedpoint_add_constraint(
5220        c: Z3_context,
5221        d: Z3_fixedpoint,
5222        e: Z3_ast,
5223        lvl: ::core::ffi::c_uint,
5224    );
5225    /// Create a new optimize context.
5226    ///
5227    /// **Remark:** User must use [`Z3_optimize_inc_ref`] and [`Z3_optimize_dec_ref`] to manage optimize objects.
5228    /// Even if the context was created using [`Z3_mk_context`] instead of [`Z3_mk_context_rc`].
5229    pub fn Z3_mk_optimize(c: Z3_context) -> Option<Z3_optimize>;
5230    /// Increment the reference counter of the given optimize context
5231    pub fn Z3_optimize_inc_ref(c: Z3_context, d: Z3_optimize);
5232    /// Decrement the reference counter of the given optimize context.
5233    pub fn Z3_optimize_dec_ref(c: Z3_context, d: Z3_optimize);
5234    /// Assert hard constraint to the optimization context.
5235    ///
5236    /// # See also
5237    ///
5238    /// - [`Z3_optimize_assert_soft`]
5239    /// - [`Z3_optimize_assert_and_track`]
5240    pub fn Z3_optimize_assert(c: Z3_context, o: Z3_optimize, a: Z3_ast);
5241    /// Assert tracked hard constraint to the optimization context.
5242    ///
5243    /// # See also
5244    ///
5245    /// - [`Z3_optimize_assert`]
5246    /// - [`Z3_optimize_assert_soft`]
5247    pub fn Z3_optimize_assert_and_track(
5248        c: Z3_context,
5249        o: Z3_optimize,
5250        a: Z3_ast,
5251        t: Z3_ast,
5252    );
5253    /// Add a maximization constraint.
5254    /// - `c`: - context
5255    /// - `o`: - optimization context
5256    /// - `t`: - arithmetical term
5257    ///
5258    /// # See also
5259    ///
5260    /// - [`Z3_optimize_minimize`]
5261    pub fn Z3_optimize_maximize(
5262        c: Z3_context,
5263        o: Z3_optimize,
5264        t: Z3_ast,
5265    ) -> ::core::ffi::c_uint;
5266    /// Add a minimization constraint.
5267    /// - `c`: - context
5268    /// - `o`: - optimization context
5269    /// - `t`: - arithmetical term
5270    ///
5271    /// # See also
5272    ///
5273    /// - [`Z3_optimize_maximize`]
5274    pub fn Z3_optimize_minimize(
5275        c: Z3_context,
5276        o: Z3_optimize,
5277        t: Z3_ast,
5278    ) -> ::core::ffi::c_uint;
5279    /// Create a backtracking point.
5280    ///
5281    /// The optimize solver contains a set of rules, added facts and assertions.
5282    /// The set of rules, facts and assertions are restored upon calling [`Z3_optimize_pop`].
5283    ///
5284    /// # See also
5285    ///
5286    /// - [`Z3_optimize_pop`]
5287    pub fn Z3_optimize_push(c: Z3_context, d: Z3_optimize);
5288    /// Backtrack one level.
5289    ///
5290    /// # Preconditions
5291    ///
5292    /// - `The number of calls to pop cannot exceed calls to push.`
5293    ///
5294    /// # See also
5295    ///
5296    /// - [`Z3_optimize_push`]
5297    pub fn Z3_optimize_pop(c: Z3_context, d: Z3_optimize);
5298    /// provide an initialization hint to the solver.
5299    /// The initialization hint is used to calibrate an initial value of the expression that
5300    /// represents a variable. If the variable is Boolean, the initial phase is set
5301    /// according to `value`. If the variable is an integer or real,
5302    /// the initial Simplex tableau is recalibrated to attempt to follow the value assignment.
5303    pub fn Z3_optimize_set_initial_value(
5304        c: Z3_context,
5305        o: Z3_optimize,
5306        v: Z3_ast,
5307        val: Z3_ast,
5308    );
5309    /// Check consistency and produce optimal values.
5310    /// - `c`: - context
5311    /// - `o`: - optimization context
5312    /// - `num_assumptions`: - number of additional assumptions
5313    /// - `assumptions`: - the additional assumptions
5314    ///
5315    /// # See also
5316    ///
5317    /// - [`Z3_optimize_get_reason_unknown`]
5318    /// - [`Z3_optimize_get_model`]
5319    /// - [`Z3_optimize_get_statistics`]
5320    /// - [`Z3_optimize_get_unsat_core`]
5321    pub fn Z3_optimize_check(
5322        c: Z3_context,
5323        o: Z3_optimize,
5324        num_assumptions: ::core::ffi::c_uint,
5325        assumptions: *const Z3_ast,
5326    ) -> Z3_lbool;
5327    /// Retrieve a string that describes the last status returned by [`Z3_optimize_check`].
5328    ///
5329    /// Use this method when [`Z3_optimize_check`] returns `Z3_L_UNDEF`.
5330    pub fn Z3_optimize_get_reason_unknown(c: Z3_context, d: Z3_optimize) -> Z3_string;
5331    /// Retrieve the model for the last [`Z3_optimize_check`]
5332    ///
5333    /// The error handler is invoked if a model is not available because
5334    /// the commands above were not invoked for the given optimization
5335    /// solver, or if the result was `Z3_L_FALSE`.
5336    pub fn Z3_optimize_get_model(c: Z3_context, o: Z3_optimize) -> Option<Z3_model>;
5337    /// Retrieve the unsat core for the last [`Z3_optimize_check`]
5338    /// The unsat core is a subset of the assumptions `a`.
5339    pub fn Z3_optimize_get_unsat_core(
5340        c: Z3_context,
5341        o: Z3_optimize,
5342    ) -> Option<Z3_ast_vector>;
5343    /// Set parameters on optimization context.
5344    ///
5345    /// - `c`: - context
5346    /// - `o`: - optimization context
5347    /// - `p`: - parameters
5348    ///
5349    /// # See also
5350    ///
5351    /// - [`Z3_optimize_get_help`]
5352    /// - [`Z3_optimize_get_param_descrs`]
5353    pub fn Z3_optimize_set_params(c: Z3_context, o: Z3_optimize, p: Z3_params);
5354    /// Return the parameter description set for the given optimize object.
5355    ///
5356    /// - `c`: - context
5357    /// - `o`: - optimization context
5358    ///
5359    /// # See also
5360    ///
5361    /// - [`Z3_optimize_get_help`]
5362    /// - [`Z3_optimize_set_params`]
5363    pub fn Z3_optimize_get_param_descrs(
5364        c: Z3_context,
5365        o: Z3_optimize,
5366    ) -> Option<Z3_param_descrs>;
5367    /// Retrieve lower bound value or approximation for the i'th optimization objective.
5368    ///
5369    /// - `c`: - context
5370    /// - `o`: - optimization context
5371    /// - `idx`: - index of optimization objective
5372    ///
5373    /// # See also
5374    ///
5375    /// - [`Z3_optimize_get_upper`]
5376    /// - [`Z3_optimize_get_lower_as_vector`]
5377    /// - [`Z3_optimize_get_upper_as_vector`]
5378    pub fn Z3_optimize_get_lower(
5379        c: Z3_context,
5380        o: Z3_optimize,
5381        idx: ::core::ffi::c_uint,
5382    ) -> Option<Z3_ast>;
5383    /// Retrieve upper bound value or approximation for the i'th optimization objective.
5384    ///
5385    /// - `c`: - context
5386    /// - `o`: - optimization context
5387    /// - `idx`: - index of optimization objective
5388    ///
5389    /// # See also
5390    ///
5391    /// - [`Z3_optimize_get_lower`]
5392    /// - [`Z3_optimize_get_lower_as_vector`]
5393    /// - [`Z3_optimize_get_upper_as_vector`]
5394    pub fn Z3_optimize_get_upper(
5395        c: Z3_context,
5396        o: Z3_optimize,
5397        idx: ::core::ffi::c_uint,
5398    ) -> Option<Z3_ast>;
5399    /// Retrieve lower bound value or approximation for the i'th optimization objective.
5400    /// The returned vector is of length 3. It always contains numerals.
5401    /// The three numerals are coefficients `a`, `b`, `c` and encode the result of
5402    /// [`Z3_optimize_get_lower`] `a * infinity + b + c * epsilon`.
5403    ///
5404    /// - `c`: - context
5405    /// - `o`: - optimization context
5406    /// - `idx`: - index of optimization objective
5407    ///
5408    /// # See also
5409    ///
5410    /// - [`Z3_optimize_get_lower`]
5411    /// - [`Z3_optimize_get_upper`]
5412    /// - [`Z3_optimize_get_upper_as_vector`]
5413    pub fn Z3_optimize_get_lower_as_vector(
5414        c: Z3_context,
5415        o: Z3_optimize,
5416        idx: ::core::ffi::c_uint,
5417    ) -> Option<Z3_ast_vector>;
5418    /// Retrieve upper bound value or approximation for the i'th optimization objective.
5419    ///
5420    /// - `c`: - context
5421    /// - `o`: - optimization context
5422    /// - `idx`: - index of optimization objective
5423    ///
5424    /// # See also
5425    ///
5426    /// - [`Z3_optimize_get_lower`]
5427    /// - [`Z3_optimize_get_upper`]
5428    /// - [`Z3_optimize_get_lower_as_vector`]
5429    pub fn Z3_optimize_get_upper_as_vector(
5430        c: Z3_context,
5431        o: Z3_optimize,
5432        idx: ::core::ffi::c_uint,
5433    ) -> Option<Z3_ast_vector>;
5434    /// Print the current context as a string.
5435    /// - `c`: - context.
5436    /// - `o`: - optimization context.
5437    ///
5438    /// # See also
5439    ///
5440    /// - [`Z3_optimize_from_file`]
5441    /// - [`Z3_optimize_from_string`]
5442    pub fn Z3_optimize_to_string(c: Z3_context, o: Z3_optimize) -> Z3_string;
5443    /// Parse an SMT-LIB2 string with assertions,
5444    /// soft constraints and optimization objectives.
5445    /// Add the parsed constraints and objectives to the optimization context.
5446    ///
5447    /// - `c`: - context.
5448    /// - `o`: - optimize context.
5449    /// - `s`: - string containing SMT2 specification.
5450    ///
5451    /// # See also
5452    ///
5453    /// - [`Z3_optimize_from_file`]
5454    /// - [`Z3_optimize_to_string`]
5455    pub fn Z3_optimize_from_string(c: Z3_context, o: Z3_optimize, s: Z3_string);
5456    /// Parse an SMT-LIB2 file with assertions,
5457    /// soft constraints and optimization objectives.
5458    /// Add the parsed constraints and objectives to the optimization context.
5459    ///
5460    /// - `c`: - context.
5461    /// - `o`: - optimize context.
5462    /// - `s`: - path to file containing SMT2 specification.
5463    ///
5464    /// # See also
5465    ///
5466    /// - [`Z3_optimize_from_string`]
5467    /// - [`Z3_optimize_to_string`]
5468    pub fn Z3_optimize_from_file(c: Z3_context, o: Z3_optimize, s: Z3_string);
5469    /// Return a string containing a description of parameters accepted by optimize.
5470    ///
5471    /// # See also
5472    ///
5473    /// - [`Z3_optimize_get_param_descrs`]
5474    /// - [`Z3_optimize_set_params`]
5475    pub fn Z3_optimize_get_help(c: Z3_context, t: Z3_optimize) -> Z3_string;
5476    /// Retrieve statistics information from the last call to [`Z3_optimize_check`]
5477    pub fn Z3_optimize_get_statistics(c: Z3_context, d: Z3_optimize) -> Option<Z3_stats>;
5478    /// Return the set of asserted formulas on the optimization context.
5479    pub fn Z3_optimize_get_assertions(
5480        c: Z3_context,
5481        o: Z3_optimize,
5482    ) -> Option<Z3_ast_vector>;
5483    /// Return objectives on the optimization context.
5484    /// If the objective function is a max-sat objective it is returned
5485    /// as a Pseudo-Boolean (minimization) sum of the form `(+ (if f1 w1 0) (if f2 w2 0) ...)`
5486    /// If the objective function is entered as a maximization objective, then return
5487    /// the corresponding minimization objective. In this way the resulting objective
5488    /// function is always returned as a minimization objective.
5489    pub fn Z3_optimize_get_objectives(
5490        c: Z3_context,
5491        o: Z3_optimize,
5492    ) -> Option<Z3_ast_vector>;
5493    /// register a model event handler for new models.
5494    pub fn Z3_optimize_register_model_eh(
5495        c: Z3_context,
5496        o: Z3_optimize,
5497        m: Z3_model,
5498        ctx: *mut ::core::ffi::c_void,
5499        model_eh: Z3_model_eh,
5500    );
5501    /// Copy an optimization context from a source to a target context.
5502    ///
5503    /// This function allows translating an optimization context from one Z3_context
5504    /// to another. This is useful when working with multiple contexts and needing to
5505    /// transfer optimization problems between them.
5506    ///
5507    /// - `c`: Source context containing the optimization context to translate
5508    /// - `o`: The optimization context to translate from the source context
5509    /// - `target`: Target context where the optimization context will be created
5510    ///
5511    /// \return A new optimization context in the target context with the same state
5512    pub fn Z3_optimize_translate(
5513        c: Z3_context,
5514        o: Z3_optimize,
5515        target: Z3_context,
5516    ) -> Option<Z3_optimize>;
5517    /// Create the RoundingMode sort.
5518    ///
5519    /// - `c`: logical context
5520    ///
5521    /// # See also
5522    ///
5523    /// - [`Z3_mk_fpa_round_nearest_ties_to_away`]
5524    /// - [`Z3_mk_fpa_rna`]
5525    /// - [`Z3_mk_fpa_round_nearest_ties_to_even`]
5526    /// - [`Z3_mk_fpa_rne`]
5527    /// - [`Z3_mk_fpa_round_toward_negative`]
5528    /// - [`Z3_mk_fpa_rtn`]
5529    /// - [`Z3_mk_fpa_round_toward_positive`]
5530    /// - [`Z3_mk_fpa_rtp`]
5531    /// - [`Z3_mk_fpa_round_toward_zero`]
5532    /// - [`Z3_mk_fpa_rtz`]
5533    pub fn Z3_mk_fpa_rounding_mode_sort(c: Z3_context) -> Option<Z3_sort>;
5534    /// Create a numeral of RoundingMode sort which represents the NearestTiesToEven rounding mode.
5535    ///
5536    /// This is the same as [`Z3_mk_fpa_rne`].
5537    ///
5538    /// - `c`: logical context
5539    ///
5540    /// # See also
5541    ///
5542    /// - [`Z3_mk_fpa_rounding_mode_sort`]
5543    /// - [`Z3_mk_fpa_round_nearest_ties_to_away`]
5544    /// - [`Z3_mk_fpa_round_toward_negative`]
5545    /// - [`Z3_mk_fpa_round_toward_positive`]
5546    /// - [`Z3_mk_fpa_round_toward_zero`]
5547    pub fn Z3_mk_fpa_round_nearest_ties_to_even(c: Z3_context) -> Option<Z3_ast>;
5548    /// Create a numeral of RoundingMode sort which represents the NearestTiesToEven rounding mode.
5549    ///
5550    /// This is the same as [`Z3_mk_fpa_round_nearest_ties_to_even`].
5551    ///
5552    /// - `c`: logical context
5553    ///
5554    /// # See also
5555    ///
5556    /// - [`Z3_mk_fpa_rounding_mode_sort`]
5557    /// - [`Z3_mk_fpa_rna`]
5558    /// - [`Z3_mk_fpa_rtn`]
5559    /// - [`Z3_mk_fpa_rtp`]
5560    /// - [`Z3_mk_fpa_rtz`]
5561    pub fn Z3_mk_fpa_rne(c: Z3_context) -> Option<Z3_ast>;
5562    /// Create a numeral of RoundingMode sort which represents the NearestTiesToAway rounding mode.
5563    ///
5564    /// This is the same as [`Z3_mk_fpa_rna`].
5565    ///
5566    /// - `c`: logical context
5567    ///
5568    /// # See also
5569    ///
5570    /// - [`Z3_mk_fpa_rounding_mode_sort`]
5571    /// - [`Z3_mk_fpa_round_nearest_ties_to_even`]
5572    /// - [`Z3_mk_fpa_round_toward_negative`]
5573    /// - [`Z3_mk_fpa_round_toward_positive`]
5574    /// - [`Z3_mk_fpa_round_toward_zero`]
5575    pub fn Z3_mk_fpa_round_nearest_ties_to_away(c: Z3_context) -> Option<Z3_ast>;
5576    /// Create a numeral of RoundingMode sort which represents the NearestTiesToAway rounding mode.
5577    ///
5578    /// This is the same as [`Z3_mk_fpa_round_nearest_ties_to_away`].
5579    ///
5580    /// - `c`: logical context
5581    ///
5582    /// # See also
5583    ///
5584    /// - [`Z3_mk_fpa_rounding_mode_sort`]
5585    /// - [`Z3_mk_fpa_rne`]
5586    /// - [`Z3_mk_fpa_rtn`]
5587    /// - [`Z3_mk_fpa_rtp`]
5588    /// - [`Z3_mk_fpa_rtz`]
5589    pub fn Z3_mk_fpa_rna(c: Z3_context) -> Option<Z3_ast>;
5590    /// Create a numeral of RoundingMode sort which represents the TowardPositive rounding mode.
5591    ///
5592    /// This is the same as [`Z3_mk_fpa_rtp`].
5593    ///
5594    /// - `c`: logical context
5595    ///
5596    /// # See also
5597    ///
5598    /// - [`Z3_mk_fpa_rounding_mode_sort`]
5599    /// - [`Z3_mk_fpa_round_nearest_ties_to_away`]
5600    /// - [`Z3_mk_fpa_round_nearest_ties_to_even`]
5601    /// - [`Z3_mk_fpa_round_toward_negative`]
5602    /// - [`Z3_mk_fpa_round_toward_zero`]
5603    pub fn Z3_mk_fpa_round_toward_positive(c: Z3_context) -> Option<Z3_ast>;
5604    /// Create a numeral of RoundingMode sort which represents the TowardPositive rounding mode.
5605    ///
5606    /// This is the same as [`Z3_mk_fpa_round_toward_positive`].
5607    ///
5608    /// - `c`: logical context
5609    ///
5610    /// # See also
5611    ///
5612    /// - [`Z3_mk_fpa_rounding_mode_sort`]
5613    /// - [`Z3_mk_fpa_rna`]
5614    /// - [`Z3_mk_fpa_rne`]
5615    /// - [`Z3_mk_fpa_rtn`]
5616    /// - [`Z3_mk_fpa_rtz`]
5617    pub fn Z3_mk_fpa_rtp(c: Z3_context) -> Option<Z3_ast>;
5618    /// Create a numeral of RoundingMode sort which represents the TowardNegative rounding mode.
5619    ///
5620    /// This is the same as [`Z3_mk_fpa_rtn`].
5621    ///
5622    /// - `c`: logical context
5623    ///
5624    /// # See also
5625    ///
5626    /// - [`Z3_mk_fpa_rounding_mode_sort`]
5627    /// - [`Z3_mk_fpa_round_nearest_ties_to_away`]
5628    /// - [`Z3_mk_fpa_round_nearest_ties_to_even`]
5629    /// - [`Z3_mk_fpa_round_toward_positive`]
5630    /// - [`Z3_mk_fpa_round_toward_zero`]
5631    pub fn Z3_mk_fpa_round_toward_negative(c: Z3_context) -> Option<Z3_ast>;
5632    /// Create a numeral of RoundingMode sort which represents the TowardNegative rounding mode.
5633    ///
5634    /// This is the same as [`Z3_mk_fpa_round_toward_negative`].
5635    ///
5636    /// - `c`: logical context
5637    ///
5638    /// # See also
5639    ///
5640    /// - [`Z3_mk_fpa_rounding_mode_sort`]
5641    /// - [`Z3_mk_fpa_rna`]
5642    /// - [`Z3_mk_fpa_rne`]
5643    /// - [`Z3_mk_fpa_rtp`]
5644    /// - [`Z3_mk_fpa_rtz`]
5645    pub fn Z3_mk_fpa_rtn(c: Z3_context) -> Option<Z3_ast>;
5646    /// Create a numeral of RoundingMode sort which represents the TowardZero rounding mode.
5647    ///
5648    /// This is the same as [`Z3_mk_fpa_rtz`].
5649    ///
5650    /// - `c`: logical context
5651    ///
5652    /// # See also
5653    ///
5654    /// - [`Z3_mk_fpa_rounding_mode_sort`]
5655    /// - [`Z3_mk_fpa_round_nearest_ties_to_away`]
5656    /// - [`Z3_mk_fpa_round_nearest_ties_to_even`]
5657    /// - [`Z3_mk_fpa_round_toward_negative`]
5658    /// - [`Z3_mk_fpa_round_toward_positive`]
5659    pub fn Z3_mk_fpa_round_toward_zero(c: Z3_context) -> Option<Z3_ast>;
5660    /// Create a numeral of RoundingMode sort which represents the TowardZero rounding mode.
5661    ///
5662    /// This is the same as [`Z3_mk_fpa_round_toward_zero`].
5663    ///
5664    /// - `c`: logical context
5665    ///
5666    /// # See also
5667    ///
5668    /// - [`Z3_mk_fpa_rounding_mode_sort`]
5669    /// - [`Z3_mk_fpa_rna`]
5670    /// - [`Z3_mk_fpa_rne`]
5671    /// - [`Z3_mk_fpa_rtn`]
5672    /// - [`Z3_mk_fpa_rtp`]
5673    pub fn Z3_mk_fpa_rtz(c: Z3_context) -> Option<Z3_ast>;
5674    /// Create a FloatingPoint sort.
5675    ///
5676    /// - `c`: logical context
5677    /// - `ebits`: number of exponent bits
5678    /// - `sbits`: number of significand bits
5679    ///
5680    /// **Remark:** `ebits` must be larger than 1 and `sbits` must be larger than 2.
5681    ///
5682    /// # See also
5683    ///
5684    /// - [`Z3_mk_fpa_sort_half`]
5685    /// - [`Z3_mk_fpa_sort_16`]
5686    /// - [`Z3_mk_fpa_sort_single`]
5687    /// - [`Z3_mk_fpa_sort_32`]
5688    /// - [`Z3_mk_fpa_sort_double`]
5689    /// - [`Z3_mk_fpa_sort_64`]
5690    /// - [`Z3_mk_fpa_sort_quadruple`]
5691    /// - [`Z3_mk_fpa_sort_128`]
5692    pub fn Z3_mk_fpa_sort(
5693        c: Z3_context,
5694        ebits: ::core::ffi::c_uint,
5695        sbits: ::core::ffi::c_uint,
5696    ) -> Option<Z3_sort>;
5697    /// Create the half-precision (16-bit) FloatingPoint sort.
5698    ///
5699    /// This is the same as [`Z3_mk_fpa_sort_16`].
5700    ///
5701    /// - `c`: logical context
5702    ///
5703    /// # See also
5704    ///
5705    /// - [`Z3_mk_fpa_sort`]
5706    /// - [`Z3_mk_fpa_sort_single`]
5707    /// - [`Z3_mk_fpa_sort_double`]
5708    /// - [`Z3_mk_fpa_sort_quadruple`]
5709    pub fn Z3_mk_fpa_sort_half(c: Z3_context) -> Option<Z3_sort>;
5710    /// Create the half-precision (16-bit) FloatingPoint sort.
5711    ///
5712    /// This is the same as [`Z3_mk_fpa_sort_half`].
5713    ///
5714    /// - `c`: logical context
5715    ///
5716    /// # See also
5717    ///
5718    /// - [`Z3_mk_fpa_sort`]
5719    /// - [`Z3_mk_fpa_sort_32`]
5720    /// - [`Z3_mk_fpa_sort_64`]
5721    /// - [`Z3_mk_fpa_sort_128`]
5722    pub fn Z3_mk_fpa_sort_16(c: Z3_context) -> Option<Z3_sort>;
5723    /// Create the single-precision (32-bit) FloatingPoint sort.
5724    ///
5725    /// This is the same as [`Z3_mk_fpa_sort_32`].
5726    ///
5727    /// - `c`: logical context.
5728    ///
5729    /// # See also
5730    ///
5731    /// - [`Z3_mk_fpa_sort`]
5732    /// - [`Z3_mk_fpa_sort_half`]
5733    /// - [`Z3_mk_fpa_sort_double`]
5734    /// - [`Z3_mk_fpa_sort_quadruple`]
5735    pub fn Z3_mk_fpa_sort_single(c: Z3_context) -> Option<Z3_sort>;
5736    /// Create the single-precision (32-bit) FloatingPoint sort.
5737    ///
5738    /// This is the same as [`Z3_mk_fpa_sort_single`].
5739    ///
5740    /// - `c`: logical context
5741    ///
5742    /// # See also
5743    ///
5744    /// - [`Z3_mk_fpa_sort`]
5745    /// - [`Z3_mk_fpa_sort_16`]
5746    /// - [`Z3_mk_fpa_sort_64`]
5747    /// - [`Z3_mk_fpa_sort_128`]
5748    pub fn Z3_mk_fpa_sort_32(c: Z3_context) -> Option<Z3_sort>;
5749    /// Create the double-precision (64-bit) FloatingPoint sort.
5750    ///
5751    /// This is the same as [`Z3_mk_fpa_sort_64`].
5752    ///
5753    /// - `c`: logical context
5754    ///
5755    /// # See also
5756    ///
5757    /// - [`Z3_mk_fpa_sort`]
5758    /// - [`Z3_mk_fpa_sort_half`]
5759    /// - [`Z3_mk_fpa_sort_single`]
5760    /// - [`Z3_mk_fpa_sort_quadruple`]
5761    pub fn Z3_mk_fpa_sort_double(c: Z3_context) -> Option<Z3_sort>;
5762    /// Create the double-precision (64-bit) FloatingPoint sort.
5763    ///
5764    /// This is the same as [`Z3_mk_fpa_sort_double`].
5765    ///
5766    /// - `c`: logical context
5767    ///
5768    /// # See also
5769    ///
5770    /// - [`Z3_mk_fpa_sort`]
5771    /// - [`Z3_mk_fpa_sort_16`]
5772    /// - [`Z3_mk_fpa_sort_32`]
5773    /// - [`Z3_mk_fpa_sort_128`]
5774    pub fn Z3_mk_fpa_sort_64(c: Z3_context) -> Option<Z3_sort>;
5775    /// Create the quadruple-precision (128-bit) FloatingPoint sort.
5776    ///
5777    /// This is the same as [`Z3_mk_fpa_sort_128`].
5778    ///
5779    /// - `c`: logical context
5780    ///
5781    /// # See also
5782    ///
5783    /// - [`Z3_mk_fpa_sort`]
5784    /// - [`Z3_mk_fpa_sort_half`]
5785    /// - [`Z3_mk_fpa_sort_single`]
5786    /// - [`Z3_mk_fpa_sort_double`]
5787    pub fn Z3_mk_fpa_sort_quadruple(c: Z3_context) -> Option<Z3_sort>;
5788    /// Create the quadruple-precision (128-bit) FloatingPoint sort.
5789    ///
5790    /// This is the same as [`Z3_mk_fpa_sort_quadruple`].
5791    ///
5792    /// - `c`: logical context
5793    ///
5794    /// # See also
5795    ///
5796    /// - [`Z3_mk_fpa_sort`]
5797    /// - [`Z3_mk_fpa_sort_16`]
5798    /// - [`Z3_mk_fpa_sort_32`]
5799    /// - [`Z3_mk_fpa_sort_64`]
5800    pub fn Z3_mk_fpa_sort_128(c: Z3_context) -> Option<Z3_sort>;
5801    /// Create a floating-point NaN of sort `s`.
5802    ///
5803    /// - `c`: logical context
5804    /// - `s`: target sort
5805    ///
5806    /// # See also
5807    ///
5808    /// - [`Z3_mk_fpa_inf`]
5809    /// - [`Z3_mk_fpa_is_nan`]
5810    /// - [`Z3_mk_fpa_zero`]
5811    pub fn Z3_mk_fpa_nan(c: Z3_context, s: Z3_sort) -> Option<Z3_ast>;
5812    /// Create a floating-point infinity of sort `s`.
5813    ///
5814    /// - `c`: logical context
5815    /// - `s`: target sort
5816    /// - `negative`: indicates whether the result should be negative
5817    ///
5818    /// When `negative` is `true`, -oo will be generated instead of +oo.
5819    ///
5820    /// # See also
5821    ///
5822    /// - [`Z3_mk_fpa_is_infinite`]
5823    /// - [`Z3_mk_fpa_nan`]
5824    /// - [`Z3_mk_fpa_zero`]
5825    pub fn Z3_mk_fpa_inf(c: Z3_context, s: Z3_sort, negative: bool) -> Option<Z3_ast>;
5826    /// Create a floating-point zero of sort `s`.
5827    ///
5828    /// - `c`: logical context
5829    /// - `s`: target sort
5830    /// - `negative`: indicates whether the result should be negative
5831    ///
5832    /// When `negative` is `true`, -zero will be generated instead of +zero.
5833    ///
5834    /// # See also
5835    ///
5836    /// - [`Z3_mk_fpa_inf`]
5837    /// - [`Z3_mk_fpa_is_zero`]
5838    /// - [`Z3_mk_fpa_nan`]
5839    pub fn Z3_mk_fpa_zero(c: Z3_context, s: Z3_sort, negative: bool) -> Option<Z3_ast>;
5840    /// Create an expression of FloatingPoint sort from three bit-vector expressions.
5841    ///
5842    /// This is the operator named `fp' in the SMT FP theory definition.
5843    /// Note that `sgn` is required to be a bit-vector of size 1. Significand and exponent
5844    /// are required to be longer than 1 and 2 respectively. The FloatingPoint sort
5845    /// of the resulting expression is automatically determined from the bit-vector sizes
5846    /// of the arguments. The exponent is assumed to be in IEEE-754 biased representation.
5847    ///
5848    /// - `c`: logical context
5849    /// - `sgn`: sign
5850    /// - `exp`: exponent
5851    /// - `sig`: significand
5852    ///
5853    /// # See also
5854    ///
5855    /// - [`Z3_mk_fpa_numeral_double`]
5856    /// - [`Z3_mk_fpa_numeral_float`]
5857    /// - [`Z3_mk_fpa_numeral_int`]
5858    /// - [`Z3_mk_fpa_numeral_int_uint`]
5859    /// - [`Z3_mk_fpa_numeral_int64_uint64`]
5860    /// - [`Z3_mk_numeral`]
5861    pub fn Z3_mk_fpa_fp(
5862        c: Z3_context,
5863        sgn: Z3_ast,
5864        exp: Z3_ast,
5865        sig: Z3_ast,
5866    ) -> Option<Z3_ast>;
5867    /// Create a numeral of FloatingPoint sort from a float.
5868    ///
5869    /// This function is used to create numerals that fit in a float value.
5870    /// It is slightly faster than [`Z3_mk_numeral`] since it is not necessary to parse a string.
5871    ///
5872    /// - `c`: logical context
5873    /// - `v`: value
5874    /// - `ty`: sort
5875    ///
5876    /// `ty` must be a FloatingPoint sort
5877    ///
5878    /// # See also
5879    ///
5880    /// - [`Z3_mk_fpa_fp`]
5881    /// - [`Z3_mk_fpa_numeral_double`]
5882    /// - [`Z3_mk_fpa_numeral_int`]
5883    /// - [`Z3_mk_fpa_numeral_int_uint`]
5884    /// - [`Z3_mk_fpa_numeral_int64_uint64`]
5885    /// - [`Z3_mk_numeral`]
5886    pub fn Z3_mk_fpa_numeral_float(c: Z3_context, v: f32, ty: Z3_sort) -> Option<Z3_ast>;
5887    /// Create a numeral of FloatingPoint sort from a double.
5888    ///
5889    /// This function is used to create numerals that fit in a double value.
5890    /// It is slightly faster than [`Z3_mk_numeral`] since it is not necessary to parse a string.
5891    ///
5892    /// - `c`: logical context
5893    /// - `v`: value
5894    /// - `ty`: sort
5895    ///
5896    /// `ty` must be a FloatingPoint sort
5897    ///
5898    /// # See also
5899    ///
5900    /// - [`Z3_mk_fpa_fp`]
5901    /// - [`Z3_mk_fpa_numeral_float`]
5902    /// - [`Z3_mk_fpa_numeral_int`]
5903    /// - [`Z3_mk_fpa_numeral_int_uint`]
5904    /// - [`Z3_mk_fpa_numeral_int64_uint64`]
5905    /// - [`Z3_mk_numeral`]
5906    pub fn Z3_mk_fpa_numeral_double(
5907        c: Z3_context,
5908        v: f64,
5909        ty: Z3_sort,
5910    ) -> Option<Z3_ast>;
5911    /// Create a numeral of FloatingPoint sort from a signed integer.
5912    ///
5913    /// - `c`: logical context
5914    /// - `v`: value
5915    /// - `ty`: result sort
5916    ///
5917    /// `ty` must be a FloatingPoint sort
5918    ///
5919    /// # See also
5920    ///
5921    /// - [`Z3_mk_fpa_fp`]
5922    /// - [`Z3_mk_fpa_numeral_double`]
5923    /// - [`Z3_mk_fpa_numeral_float`]
5924    /// - [`Z3_mk_fpa_numeral_int_uint`]
5925    /// - [`Z3_mk_fpa_numeral_int64_uint64`]
5926    /// - [`Z3_mk_numeral`]
5927    pub fn Z3_mk_fpa_numeral_int(
5928        c: Z3_context,
5929        v: ::core::ffi::c_int,
5930        ty: Z3_sort,
5931    ) -> Option<Z3_ast>;
5932    /// Create a numeral of FloatingPoint sort from a sign bit and two integers.
5933    ///
5934    /// - `c`: logical context
5935    /// - `sgn`: sign bit (true == negative)
5936    /// - `sig`: significand
5937    /// - `exp`: exponent
5938    /// - `ty`: result sort
5939    ///
5940    /// `ty` must be a FloatingPoint sort
5941    ///
5942    /// # See also
5943    ///
5944    /// - [`Z3_mk_fpa_fp`]
5945    /// - [`Z3_mk_fpa_numeral_double`]
5946    /// - [`Z3_mk_fpa_numeral_float`]
5947    /// - [`Z3_mk_fpa_numeral_int`]
5948    /// - [`Z3_mk_fpa_numeral_int64_uint64`]
5949    /// - [`Z3_mk_numeral`]
5950    pub fn Z3_mk_fpa_numeral_int_uint(
5951        c: Z3_context,
5952        sgn: bool,
5953        exp: ::core::ffi::c_int,
5954        sig: ::core::ffi::c_uint,
5955        ty: Z3_sort,
5956    ) -> Option<Z3_ast>;
5957    /// Create a numeral of FloatingPoint sort from a sign bit and two 64-bit integers.
5958    ///
5959    /// - `c`: logical context
5960    /// - `sgn`: sign bit (true == negative)
5961    /// - `sig`: significand
5962    /// - `exp`: exponent
5963    /// - `ty`: result sort
5964    ///
5965    /// `ty` must be a FloatingPoint sort
5966    ///
5967    /// # See also
5968    ///
5969    /// - [`Z3_mk_fpa_fp`]
5970    /// - [`Z3_mk_fpa_numeral_double`]
5971    /// - [`Z3_mk_fpa_numeral_float`]
5972    /// - [`Z3_mk_fpa_numeral_int`]
5973    /// - [`Z3_mk_fpa_numeral_int_uint`]
5974    /// - [`Z3_mk_numeral`]
5975    pub fn Z3_mk_fpa_numeral_int64_uint64(
5976        c: Z3_context,
5977        sgn: bool,
5978        exp: i64,
5979        sig: u64,
5980        ty: Z3_sort,
5981    ) -> Option<Z3_ast>;
5982    /// Floating-point absolute value
5983    ///
5984    /// - `c`: logical context
5985    /// - `t`: term of FloatingPoint sort
5986    ///
5987    /// # See also
5988    ///
5989    /// - [`Z3_mk_fpa_is_negative`]
5990    /// - [`Z3_mk_fpa_is_positive`]
5991    /// - [`Z3_mk_fpa_neg`]
5992    pub fn Z3_mk_fpa_abs(c: Z3_context, t: Z3_ast) -> Option<Z3_ast>;
5993    /// Floating-point negation
5994    ///
5995    /// - `c`: logical context
5996    /// - `t`: term of FloatingPoint sort
5997    ///
5998    /// # See also
5999    ///
6000    /// - [`Z3_mk_fpa_abs`]
6001    /// - [`Z3_mk_fpa_is_negative`]
6002    /// - [`Z3_mk_fpa_is_positive`]
6003    pub fn Z3_mk_fpa_neg(c: Z3_context, t: Z3_ast) -> Option<Z3_ast>;
6004    /// Floating-point addition
6005    ///
6006    /// - `c`: logical context
6007    /// - `rm`: term of RoundingMode sort
6008    /// - `t1`: term of FloatingPoint sort
6009    /// - `t2`: term of FloatingPoint sort
6010    ///
6011    /// `rm` must be of RoundingMode sort, `t1` and `t2` must have the same FloatingPoint sort.
6012    pub fn Z3_mk_fpa_add(
6013        c: Z3_context,
6014        rm: Z3_ast,
6015        t1: Z3_ast,
6016        t2: Z3_ast,
6017    ) -> Option<Z3_ast>;
6018    /// Floating-point subtraction
6019    ///
6020    /// - `c`: logical context
6021    /// - `rm`: term of RoundingMode sort
6022    /// - `t1`: term of FloatingPoint sort
6023    /// - `t2`: term of FloatingPoint sort
6024    ///
6025    /// `rm` must be of RoundingMode sort, `t1` and `t2` must have the same FloatingPoint sort.
6026    pub fn Z3_mk_fpa_sub(
6027        c: Z3_context,
6028        rm: Z3_ast,
6029        t1: Z3_ast,
6030        t2: Z3_ast,
6031    ) -> Option<Z3_ast>;
6032    /// Floating-point multiplication
6033    ///
6034    /// - `c`: logical context
6035    /// - `rm`: term of RoundingMode sort
6036    /// - `t1`: term of FloatingPoint sort
6037    /// - `t2`: term of FloatingPoint sort
6038    ///
6039    /// `rm` must be of RoundingMode sort, `t1` and `t2` must have the same FloatingPoint sort.
6040    pub fn Z3_mk_fpa_mul(
6041        c: Z3_context,
6042        rm: Z3_ast,
6043        t1: Z3_ast,
6044        t2: Z3_ast,
6045    ) -> Option<Z3_ast>;
6046    /// Floating-point division
6047    ///
6048    /// - `c`: logical context
6049    /// - `rm`: term of RoundingMode sort
6050    /// - `t1`: term of FloatingPoint sort.
6051    /// - `t2`: term of FloatingPoint sort
6052    ///
6053    /// The nodes `rm` must be of RoundingMode sort, `t1` and `t2` must have the same FloatingPoint sort.
6054    pub fn Z3_mk_fpa_div(
6055        c: Z3_context,
6056        rm: Z3_ast,
6057        t1: Z3_ast,
6058        t2: Z3_ast,
6059    ) -> Option<Z3_ast>;
6060    /// Floating-point fused multiply-add.
6061    ///
6062    /// - `c`: logical context
6063    /// - `rm`: term of RoundingMode sort
6064    /// - `t1`: term of FloatingPoint sort
6065    /// - `t2`: term of FloatingPoint sort
6066    /// - `t3`: term of FloatingPoint sort
6067    ///
6068    /// The result is `round((t1 * t2) + t3)`.
6069    ///
6070    /// `rm` must be of RoundingMode sort, `t1`, `t2`, and `t3` must have the same FloatingPoint sort.
6071    pub fn Z3_mk_fpa_fma(
6072        c: Z3_context,
6073        rm: Z3_ast,
6074        t1: Z3_ast,
6075        t2: Z3_ast,
6076        t3: Z3_ast,
6077    ) -> Option<Z3_ast>;
6078    /// Floating-point square root
6079    ///
6080    /// - `c`: logical context
6081    /// - `rm`: term of RoundingMode sort
6082    /// - `t`: term of FloatingPoint sort
6083    ///
6084    /// `rm` must be of RoundingMode sort, `t` must have FloatingPoint sort.
6085    pub fn Z3_mk_fpa_sqrt(c: Z3_context, rm: Z3_ast, t: Z3_ast) -> Option<Z3_ast>;
6086    /// Floating-point remainder
6087    ///
6088    /// - `c`: logical context
6089    /// - `t1`: term of FloatingPoint sort
6090    /// - `t2`: term of FloatingPoint sort
6091    ///
6092    /// `t1` and `t2` must have the same FloatingPoint sort.
6093    pub fn Z3_mk_fpa_rem(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
6094    /// Floating-point roundToIntegral. Rounds a floating-point number to
6095    /// the closest integer, again represented as a floating-point number.
6096    ///
6097    /// - `c`: logical context
6098    /// - `rm`: term of RoundingMode sort
6099    /// - `t`: term of FloatingPoint sort
6100    ///
6101    /// `t` must be of FloatingPoint sort.
6102    pub fn Z3_mk_fpa_round_to_integral(
6103        c: Z3_context,
6104        rm: Z3_ast,
6105        t: Z3_ast,
6106    ) -> Option<Z3_ast>;
6107    /// Minimum of floating-point numbers.
6108    ///
6109    /// - `c`: logical context
6110    /// - `t1`: term of FloatingPoint sort
6111    /// - `t2`: term of FloatingPoint sort
6112    ///
6113    /// `t1`, `t2` must have the same FloatingPoint sort.
6114    ///
6115    /// # See also
6116    ///
6117    /// - [`Z3_mk_fpa_max`]
6118    pub fn Z3_mk_fpa_min(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
6119    /// Maximum of floating-point numbers.
6120    ///
6121    /// - `c`: logical context
6122    /// - `t1`: term of FloatingPoint sort
6123    /// - `t2`: term of FloatingPoint sort
6124    ///
6125    /// `t1`, `t2` must have the same FloatingPoint sort.
6126    ///
6127    /// # See also
6128    ///
6129    /// - [`Z3_mk_fpa_min`]
6130    pub fn Z3_mk_fpa_max(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
6131    /// Floating-point less than or equal.
6132    ///
6133    /// - `c`: logical context
6134    /// - `t1`: term of FloatingPoint sort
6135    /// - `t2`: term of FloatingPoint sort
6136    ///
6137    /// `t1` and `t2` must have the same FloatingPoint sort.
6138    ///
6139    /// # See also
6140    ///
6141    /// - [`Z3_mk_fpa_eq`]
6142    /// - [`Z3_mk_fpa_geq`]
6143    /// - [`Z3_mk_fpa_gt`]
6144    /// - [`Z3_mk_fpa_lt`]
6145    pub fn Z3_mk_fpa_leq(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
6146    /// Floating-point less than.
6147    ///
6148    /// - `c`: logical context
6149    /// - `t1`: term of FloatingPoint sort
6150    /// - `t2`: term of FloatingPoint sort
6151    ///
6152    /// `t1` and `t2` must have the same FloatingPoint sort.
6153    ///
6154    /// # See also
6155    ///
6156    /// - [`Z3_mk_fpa_eq`]
6157    /// - [`Z3_mk_fpa_geq`]
6158    /// - [`Z3_mk_fpa_gt`]
6159    /// - [`Z3_mk_fpa_leq`]
6160    pub fn Z3_mk_fpa_lt(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
6161    /// Floating-point greater than or equal.
6162    ///
6163    /// - `c`: logical context
6164    /// - `t1`: term of FloatingPoint sort
6165    /// - `t2`: term of FloatingPoint sort
6166    ///
6167    /// `t1` and `t2` must have the same FloatingPoint sort.
6168    ///
6169    /// # See also
6170    ///
6171    /// - [`Z3_mk_fpa_eq`]
6172    /// - [`Z3_mk_fpa_gt`]
6173    /// - [`Z3_mk_fpa_leq`]
6174    /// - [`Z3_mk_fpa_lt`]
6175    pub fn Z3_mk_fpa_geq(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
6176    /// Floating-point greater than.
6177    ///
6178    /// - `c`: logical context
6179    /// - `t1`: term of FloatingPoint sort
6180    /// - `t2`: term of FloatingPoint sort
6181    ///
6182    /// `t1` and `t2` must have the same FloatingPoint sort.
6183    ///
6184    /// # See also
6185    ///
6186    /// - [`Z3_mk_fpa_eq`]
6187    /// - [`Z3_mk_fpa_geq`]
6188    /// - [`Z3_mk_fpa_leq`]
6189    /// - [`Z3_mk_fpa_lt`]
6190    pub fn Z3_mk_fpa_gt(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
6191    /// Floating-point equality.
6192    ///
6193    /// - `c`: logical context
6194    /// - `t1`: term of FloatingPoint sort
6195    /// - `t2`: term of FloatingPoint sort
6196    ///
6197    /// Note that this is IEEE 754 equality (as opposed to SMT-LIB `=`).
6198    ///
6199    /// `t1` and `t2` must have the same FloatingPoint sort.
6200    ///
6201    /// # See also
6202    ///
6203    /// - [`Z3_mk_fpa_geq`]
6204    /// - [`Z3_mk_fpa_gt`]
6205    /// - [`Z3_mk_fpa_leq`]
6206    /// - [`Z3_mk_fpa_lt`]
6207    pub fn Z3_mk_fpa_eq(c: Z3_context, t1: Z3_ast, t2: Z3_ast) -> Option<Z3_ast>;
6208    /// Predicate indicating whether `t` is a normal floating-point number.
6209    ///
6210    /// - `c`: logical context
6211    /// - `t`: term of FloatingPoint sort
6212    ///
6213    /// `t` must have FloatingPoint sort.
6214    ///
6215    /// # See also
6216    ///
6217    /// - [`Z3_mk_fpa_is_infinite`]
6218    /// - [`Z3_mk_fpa_is_nan`]
6219    /// - [`Z3_mk_fpa_is_subnormal`]
6220    /// - [`Z3_mk_fpa_is_zero`]
6221    pub fn Z3_mk_fpa_is_normal(c: Z3_context, t: Z3_ast) -> Option<Z3_ast>;
6222    /// Predicate indicating whether `t` is a subnormal floating-point number.
6223    ///
6224    /// - `c`: logical context
6225    /// - `t`: term of FloatingPoint sort
6226    ///
6227    /// `t` must have FloatingPoint sort.
6228    ///
6229    /// # See also
6230    ///
6231    /// - [`Z3_mk_fpa_is_infinite`]
6232    /// - [`Z3_mk_fpa_is_nan`]
6233    /// - [`Z3_mk_fpa_is_normal`]
6234    /// - [`Z3_mk_fpa_is_zero`]
6235    pub fn Z3_mk_fpa_is_subnormal(c: Z3_context, t: Z3_ast) -> Option<Z3_ast>;
6236    /// Predicate indicating whether `t` is a floating-point number with zero value, i.e., +zero or -zero.
6237    ///
6238    /// - `c`: logical context
6239    /// - `t`: term of FloatingPoint sort
6240    ///
6241    /// `t` must have FloatingPoint sort.
6242    ///
6243    /// # See also
6244    ///
6245    /// - [`Z3_mk_fpa_is_infinite`]
6246    /// - [`Z3_mk_fpa_is_nan`]
6247    /// - [`Z3_mk_fpa_is_normal`]
6248    /// - [`Z3_mk_fpa_is_subnormal`]
6249    /// - [`Z3_mk_fpa_zero`]
6250    pub fn Z3_mk_fpa_is_zero(c: Z3_context, t: Z3_ast) -> Option<Z3_ast>;
6251    /// Predicate indicating whether `t` is a floating-point number representing +oo or -oo.
6252    ///
6253    /// - `c`: logical context
6254    /// - `t`: term of FloatingPoint sort
6255    ///
6256    /// `t` must have FloatingPoint sort.
6257    ///
6258    /// # See also
6259    ///
6260    /// - [`Z3_mk_fpa_inf`]
6261    /// - [`Z3_mk_fpa_is_nan`]
6262    /// - [`Z3_mk_fpa_is_normal`]
6263    /// - [`Z3_mk_fpa_is_subnormal`]
6264    /// - [`Z3_mk_fpa_is_zero`]
6265    pub fn Z3_mk_fpa_is_infinite(c: Z3_context, t: Z3_ast) -> Option<Z3_ast>;
6266    /// Predicate indicating whether `t` is a NaN.
6267    ///
6268    /// - `c`: logical context
6269    /// - `t`: term of FloatingPoint sort
6270    ///
6271    /// `t` must have FloatingPoint sort.
6272    ///
6273    /// # See also
6274    ///
6275    /// - [`Z3_mk_fpa_is_infinite`]
6276    /// - [`Z3_mk_fpa_is_normal`]
6277    /// - [`Z3_mk_fpa_is_subnormal`]
6278    /// - [`Z3_mk_fpa_is_zero`]
6279    /// - [`Z3_mk_fpa_nan`]
6280    pub fn Z3_mk_fpa_is_nan(c: Z3_context, t: Z3_ast) -> Option<Z3_ast>;
6281    /// Predicate indicating whether `t` is a negative floating-point number.
6282    ///
6283    /// - `c`: logical context
6284    /// - `t`: term of FloatingPoint sort
6285    ///
6286    /// `t` must have FloatingPoint sort.
6287    ///
6288    /// # See also
6289    ///
6290    /// - [`Z3_mk_fpa_abs`]
6291    /// - [`Z3_mk_fpa_is_positive`]
6292    /// - [`Z3_mk_fpa_neg`]
6293    pub fn Z3_mk_fpa_is_negative(c: Z3_context, t: Z3_ast) -> Option<Z3_ast>;
6294    /// Predicate indicating whether `t` is a positive floating-point number.
6295    ///
6296    /// - `c`: logical context
6297    /// - `t`: term of FloatingPoint sort
6298    ///
6299    /// `t` must have FloatingPoint sort.
6300    ///
6301    /// # See also
6302    ///
6303    /// - [`Z3_mk_fpa_abs`]
6304    /// - [`Z3_mk_fpa_is_negative`]
6305    /// - [`Z3_mk_fpa_neg`]
6306    pub fn Z3_mk_fpa_is_positive(c: Z3_context, t: Z3_ast) -> Option<Z3_ast>;
6307    /// Conversion of a single IEEE 754-2008 bit-vector into a floating-point number.
6308    ///
6309    /// Produces a term that represents the conversion of a bit-vector term `bv` to a
6310    /// floating-point term of sort `s`.
6311    ///
6312    /// - `c`: logical context
6313    /// - `bv`: a bit-vector term
6314    /// - `s`: floating-point sort
6315    ///
6316    /// `s` must be a FloatingPoint sort, `t` must be of bit-vector sort, and the bit-vector
6317    /// size of `bv` must be equal to `ebits+sbits` of `s`. The format of the bit-vector is
6318    /// as defined by the IEEE 754-2008 interchange format.
6319    pub fn Z3_mk_fpa_to_fp_bv(c: Z3_context, bv: Z3_ast, s: Z3_sort) -> Option<Z3_ast>;
6320    /// Conversion of a FloatingPoint term into another term of different FloatingPoint sort.
6321    ///
6322    /// Produces a term that represents the conversion of a floating-point term `t` to a
6323    /// floating-point term of sort `s`. If necessary, the result will be rounded according
6324    /// to rounding mode `rm`.
6325    ///
6326    /// - `c`: logical context
6327    /// - `rm`: term of RoundingMode sort
6328    /// - `t`: term of FloatingPoint sort
6329    /// - `s`: floating-point sort
6330    ///
6331    /// `s` must be a FloatingPoint sort, `rm` must be of RoundingMode sort, `t` must be of floating-point sort.
6332    pub fn Z3_mk_fpa_to_fp_float(
6333        c: Z3_context,
6334        rm: Z3_ast,
6335        t: Z3_ast,
6336        s: Z3_sort,
6337    ) -> Option<Z3_ast>;
6338    /// Conversion of a term of real sort into a term of FloatingPoint sort.
6339    ///
6340    /// Produces a term that represents the conversion of term `t` of real sort into a
6341    /// floating-point term of sort `s`. If necessary, the result will be rounded according
6342    /// to rounding mode `rm`.
6343    ///
6344    /// - `c`: logical context
6345    /// - `rm`: term of RoundingMode sort
6346    /// - `t`: term of Real sort
6347    /// - `s`: floating-point sort
6348    ///
6349    /// `s` must be a FloatingPoint sort, `rm` must be of RoundingMode sort, `t` must be of real sort.
6350    pub fn Z3_mk_fpa_to_fp_real(
6351        c: Z3_context,
6352        rm: Z3_ast,
6353        t: Z3_ast,
6354        s: Z3_sort,
6355    ) -> Option<Z3_ast>;
6356    /// Conversion of a 2's complement signed bit-vector term into a term of FloatingPoint sort.
6357    ///
6358    /// Produces a term that represents the conversion of the bit-vector term `t` into a
6359    /// floating-point term of sort `s`. The bit-vector `t` is taken to be in signed
6360    /// 2's complement format. If necessary, the result will be rounded according
6361    /// to rounding mode `rm`.
6362    ///
6363    /// - `c`: logical context
6364    /// - `rm`: term of RoundingMode sort
6365    /// - `t`: term of bit-vector sort
6366    /// - `s`: floating-point sort
6367    ///
6368    /// `s` must be a FloatingPoint sort, `rm` must be of RoundingMode sort, `t` must be of bit-vector sort.
6369    pub fn Z3_mk_fpa_to_fp_signed(
6370        c: Z3_context,
6371        rm: Z3_ast,
6372        t: Z3_ast,
6373        s: Z3_sort,
6374    ) -> Option<Z3_ast>;
6375    /// Conversion of a 2's complement unsigned bit-vector term into a term of FloatingPoint sort.
6376    ///
6377    /// Produces a term that represents the conversion of the bit-vector term `t` into a
6378    /// floating-point term of sort `s`. The bit-vector `t` is taken to be in unsigned
6379    /// 2's complement format. If necessary, the result will be rounded according
6380    /// to rounding mode `rm`.
6381    ///
6382    /// - `c`: logical context
6383    /// - `rm`: term of RoundingMode sort
6384    /// - `t`: term of bit-vector sort
6385    /// - `s`: floating-point sort
6386    ///
6387    /// `s` must be a FloatingPoint sort, `rm` must be of RoundingMode sort, `t` must be of bit-vector sort.
6388    pub fn Z3_mk_fpa_to_fp_unsigned(
6389        c: Z3_context,
6390        rm: Z3_ast,
6391        t: Z3_ast,
6392        s: Z3_sort,
6393    ) -> Option<Z3_ast>;
6394    /// Conversion of a floating-point term into an unsigned bit-vector.
6395    ///
6396    /// Produces a term that represents the conversion of the floating-point term `t` into a
6397    /// bit-vector term of size `sz` in unsigned 2's complement format. If necessary, the result
6398    /// will be rounded according to rounding mode `rm`.
6399    ///
6400    /// - `c`: logical context
6401    /// - `rm`: term of RoundingMode sort
6402    /// - `t`: term of FloatingPoint sort
6403    /// - `sz`: size of the resulting bit-vector
6404    pub fn Z3_mk_fpa_to_ubv(
6405        c: Z3_context,
6406        rm: Z3_ast,
6407        t: Z3_ast,
6408        sz: ::core::ffi::c_uint,
6409    ) -> Option<Z3_ast>;
6410    /// Conversion of a floating-point term into a signed bit-vector.
6411    ///
6412    /// Produces a term that represents the conversion of the floating-point term `t` into a
6413    /// bit-vector term of size `sz` in signed 2's complement format. If necessary, the result
6414    /// will be rounded according to rounding mode `rm`.
6415    ///
6416    /// - `c`: logical context
6417    /// - `rm`: term of RoundingMode sort
6418    /// - `t`: term of FloatingPoint sort
6419    /// - `sz`: size of the resulting bit-vector
6420    pub fn Z3_mk_fpa_to_sbv(
6421        c: Z3_context,
6422        rm: Z3_ast,
6423        t: Z3_ast,
6424        sz: ::core::ffi::c_uint,
6425    ) -> Option<Z3_ast>;
6426    /// Conversion of a floating-point term into a real-numbered term.
6427    ///
6428    /// Produces a term that represents the conversion of the floating-point term `t` into a
6429    /// real number. Note that this type of conversion will often result in non-linear
6430    /// constraints over real terms.
6431    ///
6432    /// - `c`: logical context
6433    /// - `t`: term of FloatingPoint sort
6434    pub fn Z3_mk_fpa_to_real(c: Z3_context, t: Z3_ast) -> Option<Z3_ast>;
6435    /// Retrieves the number of bits reserved for the exponent in a FloatingPoint sort.
6436    ///
6437    /// - `c`: logical context
6438    /// - `s`: FloatingPoint sort
6439    ///
6440    /// # See also
6441    ///
6442    /// - [`Z3_fpa_get_sbits`]
6443    pub fn Z3_fpa_get_ebits(c: Z3_context, s: Z3_sort) -> ::core::ffi::c_uint;
6444    /// Retrieves the number of bits reserved for the significand in a FloatingPoint sort.
6445    ///
6446    /// - `c`: logical context
6447    /// - `s`: FloatingPoint sort
6448    ///
6449    /// # See also
6450    ///
6451    /// - [`Z3_fpa_get_ebits`]
6452    pub fn Z3_fpa_get_sbits(c: Z3_context, s: Z3_sort) -> ::core::ffi::c_uint;
6453    /// Checks whether a given ast is a floating-point numeral.
6454    ///
6455    /// - `c`: logical context
6456    /// - `t`: an ast
6457    ///
6458    /// # See also
6459    ///
6460    /// - [`Z3_fpa_is_numeral_nan`]
6461    /// - [`Z3_fpa_is_numeral_inf`]
6462    /// - [`Z3_fpa_is_numeral_normal`]
6463    /// - [`Z3_fpa_is_numeral_subnormal`]
6464    /// - [`Z3_fpa_is_numeral_zero`]
6465    pub fn Z3_fpa_is_numeral(c: Z3_context, t: Z3_ast) -> bool;
6466    /// Checks whether a given floating-point numeral is a NaN.
6467    ///
6468    /// - `c`: logical context
6469    /// - `t`: a floating-point numeral
6470    ///
6471    /// # See also
6472    ///
6473    /// - [`Z3_fpa_is_numeral_inf`]
6474    /// - [`Z3_fpa_is_numeral_normal`]
6475    /// - [`Z3_fpa_is_numeral_subnormal`]
6476    /// - [`Z3_fpa_is_numeral_zero`]
6477    pub fn Z3_fpa_is_numeral_nan(c: Z3_context, t: Z3_ast) -> bool;
6478    /// Checks whether a given floating-point numeral is a +oo or -oo.
6479    ///
6480    /// - `c`: logical context
6481    /// - `t`: a floating-point numeral
6482    ///
6483    /// # See also
6484    ///
6485    /// - [`Z3_fpa_is_numeral_nan`]
6486    /// - [`Z3_fpa_is_numeral_normal`]
6487    /// - [`Z3_fpa_is_numeral_subnormal`]
6488    /// - [`Z3_fpa_is_numeral_zero`]
6489    pub fn Z3_fpa_is_numeral_inf(c: Z3_context, t: Z3_ast) -> bool;
6490    /// Checks whether a given floating-point numeral is +zero or -zero.
6491    ///
6492    /// - `c`: logical context
6493    /// - `t`: a floating-point numeral
6494    ///
6495    /// # See also
6496    ///
6497    /// - [`Z3_fpa_is_numeral_inf`]
6498    /// - [`Z3_fpa_is_numeral_nan`]
6499    /// - [`Z3_fpa_is_numeral_normal`]
6500    /// - [`Z3_fpa_is_numeral_subnormal`]
6501    pub fn Z3_fpa_is_numeral_zero(c: Z3_context, t: Z3_ast) -> bool;
6502    /// Checks whether a given floating-point numeral is normal.
6503    ///
6504    /// - `c`: logical context
6505    /// - `t`: a floating-point numeral
6506    ///
6507    /// # See also
6508    ///
6509    /// - [`Z3_fpa_is_numeral_inf`]
6510    /// - [`Z3_fpa_is_numeral_nan`]
6511    /// - [`Z3_fpa_is_numeral_subnormal`]
6512    /// - [`Z3_fpa_is_numeral_zero`]
6513    pub fn Z3_fpa_is_numeral_normal(c: Z3_context, t: Z3_ast) -> bool;
6514    /// Checks whether a given floating-point numeral is subnormal.
6515    ///
6516    /// - `c`: logical context
6517    /// - `t`: a floating-point numeral
6518    ///
6519    /// # See also
6520    ///
6521    /// - [`Z3_fpa_is_numeral_inf`]
6522    /// - [`Z3_fpa_is_numeral_nan`]
6523    /// - [`Z3_fpa_is_numeral_normal`]
6524    /// - [`Z3_fpa_is_numeral_zero`]
6525    pub fn Z3_fpa_is_numeral_subnormal(c: Z3_context, t: Z3_ast) -> bool;
6526    /// Checks whether a given floating-point numeral is positive.
6527    ///
6528    /// - `c`: logical context
6529    /// - `t`: a floating-point numeral
6530    ///
6531    /// # See also
6532    ///
6533    /// - [`Z3_fpa_is_numeral_negative`]
6534    pub fn Z3_fpa_is_numeral_positive(c: Z3_context, t: Z3_ast) -> bool;
6535    /// Checks whether a given floating-point numeral is negative.
6536    ///
6537    /// - `c`: logical context
6538    /// - `t`: a floating-point numeral
6539    ///
6540    /// # See also
6541    ///
6542    /// - [`Z3_fpa_is_numeral_positive`]
6543    pub fn Z3_fpa_is_numeral_negative(c: Z3_context, t: Z3_ast) -> bool;
6544    /// Retrieves the sign of a floating-point literal as a bit-vector expression.
6545    ///
6546    /// - `c`: logical context
6547    /// - `t`: a floating-point numeral
6548    ///
6549    /// Remarks: NaN is an invalid argument.
6550    pub fn Z3_fpa_get_numeral_sign_bv(c: Z3_context, t: Z3_ast) -> Option<Z3_ast>;
6551    /// Retrieves the significand of a floating-point literal as a bit-vector expression.
6552    ///
6553    /// - `c`: logical context
6554    /// - `t`: a floating-point numeral
6555    ///
6556    /// Remarks: NaN is an invalid argument.
6557    pub fn Z3_fpa_get_numeral_significand_bv(c: Z3_context, t: Z3_ast) -> Option<Z3_ast>;
6558    /// Retrieves the sign of a floating-point literal.
6559    ///
6560    /// - `c`: logical context
6561    /// - `t`: a floating-point numeral
6562    /// - `sgn`: the retrieved sign
6563    ///
6564    /// **Returns:** true if `t` corresponds to a floating point numeral, otherwise invokes exception handler or returns false
6565    ///
6566    /// Remarks: sets `sgn` to `false` if `t' is positive and to `true` otherwise, except for
6567    /// NaN, which is an invalid argument.
6568    pub fn Z3_fpa_get_numeral_sign(c: Z3_context, t: Z3_ast, sgn: *mut bool) -> bool;
6569    /// Return the significand value of a floating-point numeral as a string.
6570    ///
6571    /// - `c`: logical context
6572    /// - `t`: a floating-point numeral
6573    ///
6574    /// **Returns:** true if `t` corresponds to a floating point numeral, otherwise invokes exception handler or returns false
6575    ///
6576    /// Remarks: The significand `s` is always `0.0 <= s < 2.0`; the resulting string is long
6577    /// enough to represent the real significand precisely.
6578    pub fn Z3_fpa_get_numeral_significand_string(c: Z3_context, t: Z3_ast) -> Z3_string;
6579    /// Return the significand value of a floating-point numeral as a uint64.
6580    ///
6581    /// - `c`: logical context
6582    /// - `t`: a floating-point numeral
6583    /// - `n`: pointer to output uint64
6584    ///
6585    /// Remarks: This function extracts the significand bits in `t`, without the
6586    /// hidden bit or normalization. Sets the `Z3_INVALID_ARG` error code if the
6587    /// significand does not fit into a `uint64`. NaN is an invalid argument.
6588    pub fn Z3_fpa_get_numeral_significand_uint64(
6589        c: Z3_context,
6590        t: Z3_ast,
6591        n: *mut u64,
6592    ) -> bool;
6593    /// Return the exponent value of a floating-point numeral as a string.
6594    ///
6595    /// - `c`: logical context
6596    /// - `t`: a floating-point numeral
6597    /// - `biased`: flag to indicate whether the result is in biased representation
6598    ///
6599    /// **Returns:** true if `t` corresponds to a floating point numeral, otherwise invokes exception handler or returns false
6600    ///
6601    /// Remarks: This function extracts the exponent in `t`, without normalization.
6602    /// NaN is an invalid argument.
6603    pub fn Z3_fpa_get_numeral_exponent_string(
6604        c: Z3_context,
6605        t: Z3_ast,
6606        biased: bool,
6607    ) -> Z3_string;
6608    /// Return the exponent value of a floating-point numeral as a signed 64-bit integer
6609    ///
6610    /// - `c`: logical context
6611    /// - `t`: a floating-point numeral
6612    /// - `n`: exponent
6613    /// - `biased`: flag to indicate whether the result is in biased representation
6614    ///
6615    /// **Returns:** true if `t` corresponds to a floating point numeral, otherwise invokes exception handler or returns false
6616    ///
6617    /// Remarks: This function extracts the exponent in `t`, without normalization.
6618    /// NaN is an invalid argument.
6619    pub fn Z3_fpa_get_numeral_exponent_int64(
6620        c: Z3_context,
6621        t: Z3_ast,
6622        n: *mut i64,
6623        biased: bool,
6624    ) -> bool;
6625    /// Retrieves the exponent of a floating-point literal as a bit-vector expression.
6626    ///
6627    /// - `c`: logical context
6628    /// - `t`: a floating-point numeral
6629    /// - `biased`: flag to indicate whether the result is in biased representation
6630    ///
6631    /// Remarks: This function extracts the exponent in `t`, without normalization.
6632    /// NaN is an invalid arguments.
6633    pub fn Z3_fpa_get_numeral_exponent_bv(
6634        c: Z3_context,
6635        t: Z3_ast,
6636        biased: bool,
6637    ) -> Option<Z3_ast>;
6638    /// Conversion of a floating-point term into a bit-vector term in IEEE 754-2008 format.
6639    ///
6640    /// - `c`: logical context
6641    /// - `t`: term of FloatingPoint sort
6642    ///
6643    /// `t` must have FloatingPoint sort. The size of the resulting bit-vector is automatically
6644    /// determined.
6645    ///
6646    /// Note that IEEE 754-2008 allows multiple different representations of NaN. This conversion
6647    /// knows only one NaN and it will always produce the same bit-vector representation of
6648    /// that NaN.
6649    pub fn Z3_mk_fpa_to_ieee_bv(c: Z3_context, t: Z3_ast) -> Option<Z3_ast>;
6650    /// Conversion of a real-sorted significand and an integer-sorted exponent into a term of FloatingPoint sort.
6651    ///
6652    /// Produces a term that represents the conversion of `sig * 2^exp` into a
6653    /// floating-point term of sort `s`. If necessary, the result will be rounded
6654    /// according to rounding mode `rm`.
6655    ///
6656    /// - `c`: logical context
6657    /// - `rm`: term of RoundingMode sort
6658    /// - `exp`: exponent term of Int sort
6659    /// - `sig`: significand term of Real sort
6660    /// - `s`: FloatingPoint sort
6661    ///
6662    /// `s` must be a FloatingPoint sort, `rm` must be of RoundingMode sort, `exp` must be of int sort, `sig` must be of real sort.
6663    pub fn Z3_mk_fpa_to_fp_int_real(
6664        c: Z3_context,
6665        rm: Z3_ast,
6666        exp: Z3_ast,
6667        sig: Z3_ast,
6668        s: Z3_sort,
6669    ) -> Option<Z3_ast>;
6670    /// Pose a query against the asserted rules at the given level.
6671    ///
6672    /// ```c
6673    /// query ::= (exists (bound-vars) query)
6674    /// |  literals
6675    /// ```
6676    ///
6677    /// query returns
6678    /// - `Z3_L_FALSE` if the query is unsatisfiable.
6679    /// - `Z3_L_TRUE` if the query is satisfiable. Obtain the answer by calling [`Z3_fixedpoint_get_answer`].
6680    /// - `Z3_L_UNDEF` if the query was interrupted, timed out or otherwise failed.
6681    pub fn Z3_fixedpoint_query_from_lvl(
6682        c: Z3_context,
6683        d: Z3_fixedpoint,
6684        query: Z3_ast,
6685        lvl: ::core::ffi::c_uint,
6686    ) -> Z3_lbool;
6687    /// Retrieve a bottom-up (from query) sequence of ground facts
6688    ///
6689    /// The previous call to [`Z3_fixedpoint_query`] must have returned `Z3_L_TRUE`.
6690    pub fn Z3_fixedpoint_get_ground_sat_answer(
6691        c: Z3_context,
6692        d: Z3_fixedpoint,
6693    ) -> Option<Z3_ast>;
6694    /// Obtain the list of rules along the counterexample trace.
6695    pub fn Z3_fixedpoint_get_rules_along_trace(
6696        c: Z3_context,
6697        d: Z3_fixedpoint,
6698    ) -> Option<Z3_ast_vector>;
6699    /// Obtain the list of rules along the counterexample trace.
6700    pub fn Z3_fixedpoint_get_rule_names_along_trace(
6701        c: Z3_context,
6702        d: Z3_fixedpoint,
6703    ) -> Option<Z3_symbol>;
6704    /// Add an invariant for the predicate `pred`.
6705    /// Add an assumed invariant of predicate `pred`.
6706    ///
6707    /// Note: this functionality is Spacer specific.
6708    pub fn Z3_fixedpoint_add_invariant(
6709        c: Z3_context,
6710        d: Z3_fixedpoint,
6711        pred: Z3_func_decl,
6712        property: Z3_ast,
6713    );
6714    /// Retrieve reachable states of a predicate.
6715    /// Note: this functionality is Spacer specific.
6716    pub fn Z3_fixedpoint_get_reachable(
6717        c: Z3_context,
6718        d: Z3_fixedpoint,
6719        pred: Z3_func_decl,
6720    ) -> Option<Z3_ast>;
6721    /// Project variables given a model
6722    pub fn Z3_qe_model_project(
6723        c: Z3_context,
6724        m: Z3_model,
6725        num_bounds: ::core::ffi::c_uint,
6726        bound: *const Z3_app,
6727        body: Z3_ast,
6728    ) -> Option<Z3_ast>;
6729    /// Project variables given a model
6730    pub fn Z3_qe_model_project_skolem(
6731        c: Z3_context,
6732        m: Z3_model,
6733        num_bounds: ::core::ffi::c_uint,
6734        bound: *const Z3_app,
6735        body: Z3_ast,
6736        map: Z3_ast_map,
6737    ) -> Option<Z3_ast>;
6738    /// Project with witness extraction.
6739    ///
6740    /// The returned map contains a binding of variables to terms that such that when the binding
6741    /// is used for the formula, it remains true within the model.
6742    pub fn Z3_qe_model_project_with_witness(
6743        c: Z3_context,
6744        m: Z3_model,
6745        num_bounds: ::core::ffi::c_uint,
6746        bound: *const Z3_app,
6747        body: Z3_ast,
6748        map: Z3_ast_map,
6749    ) -> Option<Z3_ast>;
6750    /// Extrapolates a model of a formula
6751    pub fn Z3_model_extrapolate(
6752        c: Z3_context,
6753        m: Z3_model,
6754        fml: Z3_ast,
6755    ) -> Option<Z3_ast>;
6756    /// Best-effort quantifier elimination
6757    pub fn Z3_qe_lite(
6758        c: Z3_context,
6759        vars: Z3_ast_vector,
6760        body: Z3_ast,
6761    ) -> Option<Z3_ast>;
6762}